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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
38,000 | mysql_stmt_data_seek | eloqsql/libmariadb/libmariadb/mariadb_stmt.c | void STDCALL mysql_stmt_data_seek(MYSQL_STMT *stmt, unsigned long long offset)
{
unsigned long long i= offset;
MYSQL_ROWS *ptr= stmt->result.data;
while(i-- && ptr)
ptr= ptr->next;
stmt->result_cursor= ptr;
stmt->state= MYSQL_STMT_USER_FETCHING;
return;
} | O3 | c | mysql_stmt_data_seek:
pushq %rbp
movq %rsp, %rbp
leaq 0x80(%rdi), %rax
movq (%rax), %rax
addq $-0x1, %rsi
jae 0x20440
testq %rax, %rax
jne 0x20432
movq %rax, 0xe0(%rdi)
movl $0x5, 0x50(%rdi)
popq %rbp
retq
| mysql_stmt_data_seek:
push rbp
mov rbp, rsp
lea rax, [rdi+80h]
loc_20432:
mov rax, [rax]
add rsi, 0FFFFFFFFFFFFFFFFh
jnb short loc_20440
test rax, rax
jnz short loc_20432
loc_20440:
mov [rdi+0E0h], rax
mov dword ptr [rdi+50h], 5
pop rbp
retn
| _QWORD * mysql_stmt_data_seek(long long a1, long long a2)
{
_QWORD *result; // rax
bool v3; // cf
result = (_QWORD *)(a1 + 128);
do
{
result = (_QWORD *)*result;
v3 = a2-- != 0;
}
while ( v3 && result );
*(_QWORD *)(a1 + 224) = result;
*(_DWORD *)(a1 + 80) = 5;
return result;
}
| mysql_stmt_data_seek:
PUSH RBP
MOV RBP,RSP
LEA RAX,[RDI + 0x80]
LAB_00120432:
MOV RAX,qword ptr [RAX]
ADD RSI,-0x1
JNC 0x00120440
TEST RAX,RAX
JNZ 0x00120432
LAB_00120440:
MOV qword ptr [RDI + 0xe0],RAX
MOV dword ptr [RDI + 0x50],0x5
POP RBP
RET
|
void mysql_stmt_data_seek(long param_1,long param_2)
{
long *plVar1;
bool bVar2;
plVar1 = (long *)(param_1 + 0x80);
do {
plVar1 = (long *)*plVar1;
bVar2 = param_2 == 0;
param_2 = param_2 + -1;
if (bVar2) break;
} while (plVar1 != (long *)0x0);
*(long **)(param_1 + 0xe0) = plVar1;
*(int4 *)(param_1 + 0x50) = 5;
return;
}
| |
38,001 | quantize_row_q5_1_ref | llama.cpp/ggml/src/ggml-quants.c | void quantize_row_q5_1_ref(const float * GGML_RESTRICT x, block_q5_1 * GGML_RESTRICT y, int64_t k) {
const int qk = QK5_1;
assert(k % qk == 0);
const int nb = k / qk;
for (int i = 0; i < nb; i++) {
float min = FLT_MAX;
float max = -FLT_MAX;
for (int j = 0; j < qk; j++) {
const float v = x[i*qk + j];
if (v < min) min = v;
if (v > max) max = v;
}
const float d = (max - min) / ((1 << 5) - 1);
const float id = d ? 1.0f/d : 0.0f;
y[i].d = GGML_FP32_TO_FP16(d);
y[i].m = GGML_FP32_TO_FP16(min);
uint32_t qh = 0;
for (int j = 0; j < qk/2; ++j) {
const float x0 = (x[i*qk + 0 + j] - min)*id;
const float x1 = (x[i*qk + qk/2 + j] - min)*id;
const uint8_t xi0 = (uint8_t)(x0 + 0.5f);
const uint8_t xi1 = (uint8_t)(x1 + 0.5f);
y[i].qs[j] = (xi0 & 0x0F) | ((xi1 & 0x0F) << 4);
// get the 5-th bit and store it in qh at the right position
qh |= ((xi0 & 0x10u) >> 4) << (j + 0);
qh |= ((xi1 & 0x10u) >> 4) << (j + qk/2);
}
memcpy(&y[i].qh, &qh, sizeof(y[i].qh));
}
} | O3 | c | quantize_row_q5_1_ref:
leaq 0x1f(%rdx), %rax
testq %rdx, %rdx
cmovnsq %rdx, %rax
sarq $0x5, %rax
testl %eax, %eax
jle 0x2c279
andl $0x7fffffff, %eax # imm = 0x7FFFFFFF
leaq 0x8(%rsi), %rcx
xorl %edx, %edx
movaps 0x1e0bd(%rip), %xmm4 # 0x4a070
pxor %xmm7, %xmm7
movdqa 0x1e081(%rip), %xmm5 # 0x4a040
movdqa 0x22548(%rip), %xmm9 # 0x4e510
movdqa 0x22640(%rip), %xmm1 # 0x4e610
movdqa 0x22617(%rip), %xmm8 # 0x4e5f0
movdqa 0x2261e(%rip), %xmm10 # 0x4e600
xorl %r8d, %r8d
movss 0x22a8a(%rip), %xmm12 # 0x4ea78
movss 0x22a7d(%rip), %xmm11 # 0x4ea74
movaps %xmm11, %xmm0
movaps %xmm12, %xmm2
movss (%rdi,%r8,4), %xmm11
movaps %xmm11, %xmm12
minss %xmm2, %xmm12
maxss %xmm0, %xmm11
incq %r8
cmpq $0x20, %r8
jne 0x2bff7
subss %xmm12, %xmm11
divss 0x22a5e(%rip), %xmm11 # 0x4ea88
movaps %xmm11, %xmm0
unpcklps %xmm12, %xmm0 # xmm0 = xmm0[0],xmm12[0],xmm0[1],xmm12[1]
movaps %xmm0, %xmm3
paddd %xmm0, %xmm3
pxor 0x1e03f(%rip), %xmm3 # 0x4a080
movdqa %xmm3, %xmm2
pcmpgtd 0x224f3(%rip), %xmm2 # 0x4e540
movdqa %xmm0, %xmm13
pand 0x224f5(%rip), %xmm13 # 0x4e550
paddd 0x224fc(%rip), %xmm13 # 0x4e560
pand %xmm2, %xmm13
pandn 0x224ff(%rip), %xmm2 # 0x4e570
por %xmm13, %xmm2
movaps %xmm0, %xmm13
andps 0x1df9e(%rip), %xmm13 # 0x4a020
mulps 0x22496(%rip), %xmm13 # 0x4e520
mulps 0x2249e(%rip), %xmm13 # 0x4e530
addps %xmm13, %xmm2
movaps %xmm2, %xmm13
psrld $0xd, %xmm13
pand 0x224d7(%rip), %xmm13 # 0x4e580
andps 0x224e0(%rip), %xmm2 # 0x4e590
paddd %xmm13, %xmm2
pcmpgtd 0x224f3(%rip), %xmm3 # 0x4e5b0
movdqa %xmm3, %xmm13
pandn %xmm2, %xmm13
leaq (%rdx,%rdx,2), %r8
leaq (%rsi,%r8,8), %r8
psrld $0x10, %xmm0
pand 0x224c4(%rip), %xmm0 # 0x4e5a0
pand 0x224dc(%rip), %xmm3 # 0x4e5c0
por %xmm0, %xmm3
por %xmm13, %xmm3
pshuflw $0xe8, %xmm3, %xmm0 # xmm0 = xmm3[0,2,2,3,4,5,6,7]
movd %xmm0, (%r8)
movss 0x1dff1(%rip), %xmm0 # 0x4a0f0
divss %xmm11, %xmm0
cmpneqss 0x22976(%rip), %xmm11 # 0x4ea84
andps %xmm0, %xmm11
shufps $0x0, %xmm12, %xmm12 # xmm12 = xmm12[0,0,0,0]
shufps $0x0, %xmm11, %xmm11 # xmm11 = xmm11[0,0,0,0]
pxor %xmm13, %xmm13
xorl %r9d, %r9d
movdqa 0x1df03(%rip), %xmm14 # 0x4a030
movdqa %xmm14, %xmm3
movups (%rdi,%r9,4), %xmm0
movups 0x40(%rdi,%r9,4), %xmm15
subps %xmm12, %xmm0
mulps %xmm11, %xmm0
subps %xmm12, %xmm15
mulps %xmm11, %xmm15
addps %xmm4, %xmm0
cvttps2dq %xmm0, %xmm2
packuswb %xmm2, %xmm2
packuswb %xmm2, %xmm2
addps %xmm4, %xmm15
movaps %xmm4, %xmm6
cvttps2dq %xmm15, %xmm4
packuswb %xmm4, %xmm4
packuswb %xmm4, %xmm4
movdqa %xmm2, %xmm15
pand 0x22382(%rip), %xmm15 # 0x4e500
movdqa %xmm4, %xmm0
psllw $0x4, %xmm0
pand %xmm9, %xmm0
por %xmm15, %xmm0
movd %xmm0, (%rcx,%r9)
psrlw $0x4, %xmm2
pand %xmm8, %xmm2
punpcklbw %xmm7, %xmm2 # xmm2 = xmm2[0],xmm7[0],xmm2[1],xmm7[1],xmm2[2],xmm7[2],xmm2[3],xmm7[3],xmm2[4],xmm7[4],xmm2[5],xmm7[5],xmm2[6],xmm7[6],xmm2[7],xmm7[7]
punpcklwd %xmm7, %xmm2 # xmm2 = xmm2[0],xmm7[0],xmm2[1],xmm7[1],xmm2[2],xmm7[2],xmm2[3],xmm7[3]
movdqa %xmm3, %xmm0
pslld $0x17, %xmm0
paddd %xmm10, %xmm0
cvttps2dq %xmm0, %xmm0
pshufd $0xf5, %xmm2, %xmm15 # xmm15 = xmm2[1,1,3,3]
pmuludq %xmm0, %xmm2
pshufd $0xe8, %xmm2, %xmm2 # xmm2 = xmm2[0,2,2,3]
pshufd $0xf5, %xmm0, %xmm0 # xmm0 = xmm0[1,1,3,3]
pmuludq %xmm15, %xmm0
pshufd $0xe8, %xmm0, %xmm0 # xmm0 = xmm0[0,2,2,3]
punpckldq %xmm0, %xmm2 # xmm2 = xmm2[0],xmm0[0],xmm2[1],xmm0[1]
psrlw $0x4, %xmm4
pand %xmm8, %xmm4
punpcklbw %xmm7, %xmm4 # xmm4 = xmm4[0],xmm7[0],xmm4[1],xmm7[1],xmm4[2],xmm7[2],xmm4[3],xmm7[3],xmm4[4],xmm7[4],xmm4[5],xmm7[5],xmm4[6],xmm7[6],xmm4[7],xmm7[7]
punpcklwd %xmm7, %xmm4 # xmm4 = xmm4[0],xmm7[0],xmm4[1],xmm7[1],xmm4[2],xmm7[2],xmm4[3],xmm7[3]
movdqa %xmm14, %xmm0
paddd %xmm1, %xmm0
pslld $0x17, %xmm0
paddd %xmm10, %xmm0
cvttps2dq %xmm0, %xmm0
pshufd $0xf5, %xmm4, %xmm15 # xmm15 = xmm4[1,1,3,3]
pmuludq %xmm0, %xmm4
pshufd $0xf5, %xmm0, %xmm0 # xmm0 = xmm0[1,1,3,3]
pmuludq %xmm15, %xmm0
pshufd $0xe8, %xmm4, %xmm4 # xmm4 = xmm4[0,2,2,3]
pshufd $0xe8, %xmm0, %xmm0 # xmm0 = xmm0[0,2,2,3]
punpckldq %xmm0, %xmm4 # xmm4 = xmm4[0],xmm0[0],xmm4[1],xmm0[1]
paddd %xmm2, %xmm4
por %xmm4, %xmm13
movaps %xmm6, %xmm4
addq $0x4, %r9
paddd %xmm5, %xmm3
paddd %xmm5, %xmm14
cmpq $0x10, %r9
jne 0x2c132
pshufd $0xee, %xmm13, %xmm0 # xmm0 = xmm13[2,3,2,3]
por %xmm13, %xmm0
pshufd $0x55, %xmm0, %xmm2 # xmm2 = xmm0[1,1,1,1]
por %xmm0, %xmm2
movd %xmm2, 0x4(%r8)
incq %rdx
subq $-0x80, %rdi
addq $0x18, %rcx
cmpq %rax, %rdx
jne 0x2bfe2
retq
| quantize_row_q5_1_ref:
lea rax, [rdx+1Fh]
test rdx, rdx
cmovns rax, rdx
sar rax, 5
test eax, eax
jle locret_2C279
and eax, 7FFFFFFFh
lea rcx, [rsi+8]
xor edx, edx
movaps xmm4, cs:xmmword_4A070
pxor xmm7, xmm7
movdqa xmm5, cs:xmmword_4A040
movdqa xmm9, cs:xmmword_4E510
movdqa xmm1, cs:xmmword_4E610
movdqa xmm8, cs:xmmword_4E5F0
movdqa xmm10, cs:xmmword_4E600
loc_2BFE2:
xor r8d, r8d
movss xmm12, cs:dword_4EA78
movss xmm11, cs:dword_4EA74
loc_2BFF7:
movaps xmm0, xmm11
movaps xmm2, xmm12
movss xmm11, dword ptr [rdi+r8*4]
movaps xmm12, xmm11
minss xmm12, xmm2
maxss xmm11, xmm0
inc r8
cmp r8, 20h ; ' '
jnz short loc_2BFF7
subss xmm11, xmm12
divss xmm11, cs:dword_4EA88
movaps xmm0, xmm11
unpcklps xmm0, xmm12
movaps xmm3, xmm0
paddd xmm3, xmm0
pxor xmm3, cs:xmmword_4A080
movdqa xmm2, xmm3
pcmpgtd xmm2, cs:xmmword_4E540
movdqa xmm13, xmm0
pand xmm13, cs:xmmword_4E550
paddd xmm13, cs:xmmword_4E560
pand xmm13, xmm2
pandn xmm2, cs:xmmword_4E570
por xmm2, xmm13
movaps xmm13, xmm0
andps xmm13, cs:xmmword_4A020
mulps xmm13, cs:xmmword_4E520
mulps xmm13, cs:xmmword_4E530
addps xmm2, xmm13
movaps xmm13, xmm2
psrld xmm13, 0Dh
pand xmm13, cs:xmmword_4E580
andps xmm2, cs:xmmword_4E590
paddd xmm2, xmm13
pcmpgtd xmm3, cs:xmmword_4E5B0
movdqa xmm13, xmm3
pandn xmm13, xmm2
lea r8, [rdx+rdx*2]
lea r8, [rsi+r8*8]
psrld xmm0, 10h
pand xmm0, cs:xmmword_4E5A0
pand xmm3, cs:xmmword_4E5C0
por xmm3, xmm0
por xmm3, xmm13
pshuflw xmm0, xmm3, 0E8h
movd dword ptr [r8], xmm0
movss xmm0, cs:dword_4A0F0
divss xmm0, xmm11
cmpneqss xmm11, cs:dword_4EA84
andps xmm11, xmm0
shufps xmm12, xmm12, 0
shufps xmm11, xmm11, 0
pxor xmm13, xmm13
xor r9d, r9d
movdqa xmm14, cs:xmmword_4A030
movdqa xmm3, xmm14
loc_2C132:
movups xmm0, xmmword ptr [rdi+r9*4]
movups xmm15, xmmword ptr [rdi+r9*4+40h]
subps xmm0, xmm12
mulps xmm0, xmm11
subps xmm15, xmm12
mulps xmm15, xmm11
addps xmm0, xmm4
cvttps2dq xmm2, xmm0
packuswb xmm2, xmm2
packuswb xmm2, xmm2
addps xmm15, xmm4
movaps xmm6, xmm4
cvttps2dq xmm4, xmm15
packuswb xmm4, xmm4
packuswb xmm4, xmm4
movdqa xmm15, xmm2
pand xmm15, cs:xmmword_4E500
movdqa xmm0, xmm4
psllw xmm0, 4
pand xmm0, xmm9
por xmm0, xmm15
movd dword ptr [rcx+r9], xmm0
psrlw xmm2, 4
pand xmm2, xmm8
punpcklbw xmm2, xmm7
punpcklwd xmm2, xmm7
movdqa xmm0, xmm3
pslld xmm0, 17h
paddd xmm0, xmm10
cvttps2dq xmm0, xmm0
pshufd xmm15, xmm2, 0F5h
pmuludq xmm2, xmm0
pshufd xmm2, xmm2, 0E8h
pshufd xmm0, xmm0, 0F5h
pmuludq xmm0, xmm15
pshufd xmm0, xmm0, 0E8h
punpckldq xmm2, xmm0
psrlw xmm4, 4
pand xmm4, xmm8
punpcklbw xmm4, xmm7
punpcklwd xmm4, xmm7
movdqa xmm0, xmm14
paddd xmm0, xmm1
pslld xmm0, 17h
paddd xmm0, xmm10
cvttps2dq xmm0, xmm0
pshufd xmm15, xmm4, 0F5h
pmuludq xmm4, xmm0
pshufd xmm0, xmm0, 0F5h
pmuludq xmm0, xmm15
pshufd xmm4, xmm4, 0E8h
pshufd xmm0, xmm0, 0E8h
punpckldq xmm4, xmm0
paddd xmm4, xmm2
por xmm13, xmm4
movaps xmm4, xmm6
add r9, 4
paddd xmm3, xmm5
paddd xmm14, xmm5
cmp r9, 10h
jnz loc_2C132
pshufd xmm0, xmm13, 0EEh
por xmm0, xmm13
pshufd xmm2, xmm0, 55h ; 'U'
por xmm2, xmm0
movd dword ptr [r8+4], xmm2
inc rdx
sub rdi, 0FFFFFFFFFFFFFF80h
add rcx, 18h
cmp rdx, rax
jnz loc_2BFE2
locret_2C279:
retn
| long long quantize_row_q5_1_ref(long long a1, long long a2, long long a3)
{
long long result; // rax
long long v4; // rcx
long long v5; // rdx
__m128 v6; // xmm4
__m128i si128; // xmm5
__m128i v8; // xmm9
__m128i v9; // xmm1
__m128i v10; // xmm8
__m128i v11; // xmm10
long long v12; // r8
__m128 v13; // xmm12
__m128 v14; // xmm11
float v15; // xmm0_4
float v16; // xmm2_4
__m128 v17; // xmm0
__m128i v18; // xmm3
__m128i v19; // xmm2
__m128 v20; // xmm2
__m128i v21; // xmm3
_DWORD *v22; // r8
__m128 v23; // xmm0
__m128 v24; // rt1
__m128 v25; // xmm11
__m128 v26; // xmm12
__m128 v27; // xmm11
__m128i v28; // xmm13
long long v29; // r9
__m128i v30; // xmm14
__m128i v31; // xmm3
__m128i v32; // xmm2
__m128i v33; // xmm2
__m128i v34; // xmm2
__m128 v35; // xmm6
__m128i v36; // xmm4
__m128i v37; // xmm4
__m128i v38; // xmm4
__m128i v39; // xmm2
__m128i v40; // xmm0
__m128i v41; // xmm2
__m128i v42; // xmm4
__m128i v43; // xmm0
__m128i v44; // xmm0
result = a3 / 32;
if ( (int)(a3 / 32) > 0 )
{
result = (a3 / 32) & 0x7FFFFFFF;
v4 = a2 + 8;
v5 = 0LL;
v6 = (__m128)xmmword_4A070;
si128 = _mm_load_si128((const __m128i *)&xmmword_4A040);
v8 = _mm_load_si128((const __m128i *)&xmmword_4E510);
v9 = _mm_load_si128((const __m128i *)&xmmword_4E610);
v10 = _mm_load_si128((const __m128i *)&xmmword_4E5F0);
v11 = _mm_load_si128((const __m128i *)&xmmword_4E600);
do
{
v12 = 0LL;
v13.m128_i32[0] = 2139095039;
v14.m128_i32[0] = -8388609;
do
{
v15 = v14.m128_f32[0];
v16 = v13.m128_f32[0];
v14 = (__m128)*(unsigned int *)(a1 + 4 * v12);
v13 = v14;
v13.m128_f32[0] = fminf(v14.m128_f32[0], v16);
v14.m128_f32[0] = fmaxf(v14.m128_f32[0], v15);
++v12;
}
while ( v12 != 32 );
v14.m128_f32[0] = (float)(v14.m128_f32[0] - v13.m128_f32[0]) / 31.0;
v17 = _mm_unpacklo_ps(v14, v13);
v18 = _mm_xor_si128(_mm_add_epi32((__m128i)v17, (__m128i)v17), (__m128i)xmmword_4A080);
v19 = _mm_cmpgt_epi32(v18, (__m128i)xmmword_4E540);
v20 = _mm_add_ps(
(__m128)_mm_or_si128(
_mm_andnot_si128(v19, (__m128i)xmmword_4E570),
_mm_and_si128(
_mm_add_epi32(_mm_and_si128((__m128i)v17, (__m128i)xmmword_4E550), (__m128i)xmmword_4E560),
v19)),
_mm_mul_ps(
_mm_mul_ps(_mm_and_ps(v17, (__m128)xmmword_4A020), (__m128)xmmword_4E520),
(__m128)xmmword_4E530));
v21 = _mm_cmpgt_epi32(v18, (__m128i)xmmword_4E5B0);
v22 = (_DWORD *)(a2 + 24 * v5);
*v22 = _mm_cvtsi128_si32(
_mm_shufflelo_epi16(
_mm_or_si128(
_mm_or_si128(
_mm_and_si128(v21, (__m128i)xmmword_4E5C0),
_mm_and_si128(_mm_srli_epi32((__m128i)v17, 0x10u), (__m128i)xmmword_4E5A0)),
_mm_andnot_si128(
v21,
_mm_add_epi32(
(__m128i)_mm_and_ps(v20, (__m128)xmmword_4E590),
_mm_and_si128(_mm_srli_epi32((__m128i)v20, 0xDu), (__m128i)xmmword_4E580)))),
232));
v23 = (__m128)0x3F800000u;
v23.m128_f32[0] = 1.0 / v14.m128_f32[0];
v24.m128_i32[0] = 0;
v25 = _mm_and_ps(_mm_cmpneq_ss(v14, v24), v23);
v26 = _mm_shuffle_ps(v13, v13, 0);
v27 = _mm_shuffle_ps(v25, v25, 0);
v28 = 0LL;
v29 = 0LL;
v30 = _mm_load_si128((const __m128i *)&xmmword_4A030);
v31 = v30;
do
{
v32 = _mm_cvttps_epi32(_mm_add_ps(_mm_mul_ps(_mm_sub_ps(*(__m128 *)(a1 + 4 * v29), v26), v27), v6));
v33 = _mm_packus_epi16(v32, v32);
v34 = _mm_packus_epi16(v33, v33);
v35 = v6;
v36 = _mm_cvttps_epi32(_mm_add_ps(_mm_mul_ps(_mm_sub_ps(*(__m128 *)(a1 + 4 * v29 + 64), v26), v27), v6));
v37 = _mm_packus_epi16(v36, v36);
v38 = _mm_packus_epi16(v37, v37);
*(_DWORD *)(v4 + v29) = _mm_cvtsi128_si32(
_mm_or_si128(
_mm_and_si128(_mm_slli_epi16(v38, 4u), v8),
_mm_and_si128(v34, (__m128i)xmmword_4E500)));
v39 = _mm_unpacklo_epi16(
_mm_unpacklo_epi8(_mm_and_si128(_mm_srli_epi16(v34, 4u), v10), (__m128i)0LL),
(__m128i)0LL);
v40 = _mm_cvttps_epi32((__m128)_mm_add_epi32(_mm_slli_epi32(v31, 0x17u), v11));
v41 = _mm_unpacklo_epi32(
_mm_shuffle_epi32(_mm_mul_epu32(v39, v40), 232),
_mm_shuffle_epi32(_mm_mul_epu32(_mm_shuffle_epi32(v40, 245), _mm_shuffle_epi32(v39, 245)), 232));
v42 = _mm_unpacklo_epi16(
_mm_unpacklo_epi8(_mm_and_si128(_mm_srli_epi16(v38, 4u), v10), (__m128i)0LL),
(__m128i)0LL);
v43 = _mm_cvttps_epi32((__m128)_mm_add_epi32(_mm_slli_epi32(_mm_add_epi32(v30, v9), 0x17u), v11));
v28 = _mm_or_si128(
v28,
_mm_add_epi32(
_mm_unpacklo_epi32(
_mm_shuffle_epi32(_mm_mul_epu32(v42, v43), 232),
_mm_shuffle_epi32(_mm_mul_epu32(_mm_shuffle_epi32(v43, 245), _mm_shuffle_epi32(v42, 245)), 232)),
v41));
v6 = v35;
v29 += 4LL;
v31 = _mm_add_epi32(v31, si128);
v30 = _mm_add_epi32(v30, si128);
}
while ( v29 != 16 );
v44 = _mm_or_si128(_mm_shuffle_epi32(v28, 238), v28);
v22[1] = _mm_cvtsi128_si32(_mm_or_si128(_mm_shuffle_epi32(v44, 85), v44));
++v5;
a1 += 128LL;
v4 += 24LL;
}
while ( v5 != result );
}
return result;
}
| quantize_row_q5_1_ref:
LEA RAX,[RDX + 0x1f]
TEST RDX,RDX
CMOVNS RAX,RDX
SAR RAX,0x5
TEST EAX,EAX
JLE 0x0012c279
AND EAX,0x7fffffff
LEA RCX,[RSI + 0x8]
XOR EDX,EDX
MOVAPS XMM4,xmmword ptr [0x0014a070]
PXOR XMM7,XMM7
MOVDQA XMM5,xmmword ptr [0x0014a040]
MOVDQA XMM9,xmmword ptr [0x0014e510]
MOVDQA XMM1,xmmword ptr [0x0014e610]
MOVDQA XMM8,xmmword ptr [0x0014e5f0]
MOVDQA XMM10,xmmword ptr [0x0014e600]
LAB_0012bfe2:
XOR R8D,R8D
MOVSS XMM12,dword ptr [0x0014ea78]
MOVSS XMM11,dword ptr [0x0014ea74]
LAB_0012bff7:
MOVAPS XMM0,XMM11
MOVAPS XMM2,XMM12
MOVSS XMM11,dword ptr [RDI + R8*0x4]
MOVAPS XMM12,XMM11
MINSS XMM12,XMM2
MAXSS XMM11,XMM0
INC R8
CMP R8,0x20
JNZ 0x0012bff7
SUBSS XMM11,XMM12
DIVSS XMM11,dword ptr [0x0014ea88]
MOVAPS XMM0,XMM11
UNPCKLPS XMM0,XMM12
MOVAPS XMM3,XMM0
PADDD XMM3,XMM0
PXOR XMM3,xmmword ptr [0x0014a080]
MOVDQA XMM2,XMM3
PCMPGTD XMM2,xmmword ptr [0x0014e540]
MOVDQA XMM13,XMM0
PAND XMM13,xmmword ptr [0x0014e550]
PADDD XMM13,xmmword ptr [0x0014e560]
PAND XMM13,XMM2
PANDN XMM2,xmmword ptr [0x0014e570]
POR XMM2,XMM13
MOVAPS XMM13,XMM0
ANDPS XMM13,xmmword ptr [0x0014a020]
MULPS XMM13,xmmword ptr [0x0014e520]
MULPS XMM13,xmmword ptr [0x0014e530]
ADDPS XMM2,XMM13
MOVAPS XMM13,XMM2
PSRLD XMM13,0xd
PAND XMM13,xmmword ptr [0x0014e580]
ANDPS XMM2,xmmword ptr [0x0014e590]
PADDD XMM2,XMM13
PCMPGTD XMM3,xmmword ptr [0x0014e5b0]
MOVDQA XMM13,XMM3
PANDN XMM13,XMM2
LEA R8,[RDX + RDX*0x2]
LEA R8,[RSI + R8*0x8]
PSRLD XMM0,0x10
PAND XMM0,xmmword ptr [0x0014e5a0]
PAND XMM3,xmmword ptr [0x0014e5c0]
POR XMM3,XMM0
POR XMM3,XMM13
PSHUFLW XMM0,XMM3,0xe8
MOVD dword ptr [R8],XMM0
MOVSS XMM0,dword ptr [0x0014a0f0]
DIVSS XMM0,XMM11
CMPNEQSS XMM11,dword ptr [0x0014ea84]
ANDPS XMM11,XMM0
SHUFPS XMM12,XMM12,0x0
SHUFPS XMM11,XMM11,0x0
PXOR XMM13,XMM13
XOR R9D,R9D
MOVDQA XMM14,xmmword ptr [0x0014a030]
MOVDQA XMM3,XMM14
LAB_0012c132:
MOVUPS XMM0,xmmword ptr [RDI + R9*0x4]
MOVUPS XMM15,xmmword ptr [RDI + R9*0x4 + 0x40]
SUBPS XMM0,XMM12
MULPS XMM0,XMM11
SUBPS XMM15,XMM12
MULPS XMM15,XMM11
ADDPS XMM0,XMM4
CVTTPS2DQ XMM2,XMM0
PACKUSWB XMM2,XMM2
PACKUSWB XMM2,XMM2
ADDPS XMM15,XMM4
MOVAPS XMM6,XMM4
CVTTPS2DQ XMM4,XMM15
PACKUSWB XMM4,XMM4
PACKUSWB XMM4,XMM4
MOVDQA XMM15,XMM2
PAND XMM15,xmmword ptr [0x0014e500]
MOVDQA XMM0,XMM4
PSLLW XMM0,0x4
PAND XMM0,XMM9
POR XMM0,XMM15
MOVD dword ptr [RCX + R9*0x1],XMM0
PSRLW XMM2,0x4
PAND XMM2,XMM8
PUNPCKLBW XMM2,XMM7
PUNPCKLWD XMM2,XMM7
MOVDQA XMM0,XMM3
PSLLD XMM0,0x17
PADDD XMM0,XMM10
CVTTPS2DQ XMM0,XMM0
PSHUFD XMM15,XMM2,0xf5
PMULUDQ XMM2,XMM0
PSHUFD XMM2,XMM2,0xe8
PSHUFD XMM0,XMM0,0xf5
PMULUDQ XMM0,XMM15
PSHUFD XMM0,XMM0,0xe8
PUNPCKLDQ XMM2,XMM0
PSRLW XMM4,0x4
PAND XMM4,XMM8
PUNPCKLBW XMM4,XMM7
PUNPCKLWD XMM4,XMM7
MOVDQA XMM0,XMM14
PADDD XMM0,XMM1
PSLLD XMM0,0x17
PADDD XMM0,XMM10
CVTTPS2DQ XMM0,XMM0
PSHUFD XMM15,XMM4,0xf5
PMULUDQ XMM4,XMM0
PSHUFD XMM0,XMM0,0xf5
PMULUDQ XMM0,XMM15
PSHUFD XMM4,XMM4,0xe8
PSHUFD XMM0,XMM0,0xe8
PUNPCKLDQ XMM4,XMM0
PADDD XMM4,XMM2
POR XMM13,XMM4
MOVAPS XMM4,XMM6
ADD R9,0x4
PADDD XMM3,XMM5
PADDD XMM14,XMM5
CMP R9,0x10
JNZ 0x0012c132
PSHUFD XMM0,XMM13,0xee
POR XMM0,XMM13
PSHUFD XMM2,XMM0,0x55
POR XMM2,XMM0
MOVD dword ptr [R8 + 0x4],XMM2
INC RDX
SUB RDI,-0x80
ADD RCX,0x18
CMP RDX,RAX
JNZ 0x0012bfe2
LAB_0012c279:
RET
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
void quantize_row_q5_1_ref(long param_1,long param_2,long param_3)
{
int4 *puVar1;
float *pfVar2;
float *pfVar3;
char cVar4;
short sVar9;
short sVar10;
short sVar11;
short sVar12;
short sVar13;
short sVar14;
short sVar15;
short sVar16;
char cVar17;
char cVar18;
char cVar19;
char cVar20;
char cVar21;
int1 auVar22 [14];
int1 auVar23 [14];
int1 auVar24 [15];
int1 auVar25 [15];
int1 auVar26 [15];
int1 auVar27 [15];
int1 auVar28 [15];
int1 auVar29 [14];
int1 auVar30 [15];
int1 auVar31 [15];
int1 auVar32 [15];
int1 auVar33 [15];
int1 auVar34 [15];
int1 auVar35 [15];
int1 auVar36 [15];
unkuint9 Var37;
int1 auVar38 [11];
int1 auVar39 [13];
int1 auVar40 [14];
int1 auVar41 [15];
int1 auVar42 [11];
int1 auVar43 [14];
int1 auVar44 [15];
int1 auVar45 [15];
int1 auVar46 [15];
int1 auVar47 [15];
uint6 uVar48;
uint6 uVar49;
int iVar50;
int iVar51;
int iVar52;
int iVar53;
float fVar54;
float fVar55;
float fVar56;
float fVar57;
uint uVar58;
int1 auVar59 [16];
int iVar60;
int iVar61;
int iVar62;
int iVar63;
int iVar64;
int iVar65;
int iVar66;
int iVar67;
uint uVar68;
long lVar69;
ulong uVar70;
long lVar71;
int1 auVar72 [16];
int1 auVar73 [16];
int1 auVar74 [16];
short sVar75;
ushort uVar76;
int1 auVar88 [15];
uint uVar77;
float fVar78;
uint uVar93;
float fVar94;
float fVar96;
float fVar98;
int1 auVar89 [16];
int iVar79;
int iVar95;
int iVar97;
int iVar99;
int1 auVar92 [16];
int iVar100;
int iVar102;
int iVar103;
int1 auVar101 [16];
int iVar104;
ushort uVar105;
int1 auVar112 [15];
int6 uVar106;
int1 auVar115 [16];
float fVar116;
float fVar117;
uint uVar118;
uint uVar119;
int iVar120;
int iVar121;
int iVar122;
int iVar123;
char cVar5;
char cVar6;
char cVar7;
char cVar8;
int4 uVar80;
uint uVar81;
int6 uVar82;
int8 uVar83;
int1 auVar84 [12];
int1 auVar85 [12];
int1 auVar86 [14];
int1 auVar87 [14];
int1 auVar90 [16];
int1 auVar91 [16];
int8 uVar107;
int1 auVar108 [12];
int1 auVar109 [12];
int1 auVar110 [14];
int1 auVar111 [14];
int1 auVar113 [16];
int1 auVar114 [16];
iVar67 = _UNK_0014e61c;
iVar66 = _UNK_0014e618;
iVar65 = _UNK_0014e614;
iVar64 = _DAT_0014e610;
iVar63 = _UNK_0014e60c;
iVar62 = _UNK_0014e608;
iVar61 = _UNK_0014e604;
iVar60 = _DAT_0014e600;
auVar59 = _DAT_0014e5f0;
uVar58 = _DAT_0014e510;
fVar57 = _UNK_0014a07c;
fVar56 = _UNK_0014a078;
fVar55 = _UNK_0014a074;
fVar54 = _DAT_0014a070;
iVar53 = _UNK_0014a04c;
iVar52 = _UNK_0014a048;
iVar51 = _UNK_0014a044;
iVar50 = _DAT_0014a040;
lVar69 = param_3 + 0x1f;
if (-1 < param_3) {
lVar69 = param_3;
}
uVar68 = (uint)(lVar69 >> 5);
if (0 < (int)uVar68) {
lVar69 = param_2 + 8;
uVar70 = 0;
do {
lVar71 = 0;
fVar78 = DAT_0014ea74;
fVar94 = DAT_0014ea78;
do {
fVar96 = *(float *)(param_1 + lVar71 * 4);
fVar117 = fVar96;
if (fVar94 <= fVar96) {
fVar117 = fVar94;
}
if (fVar96 <= fVar78) {
fVar96 = fVar78;
}
lVar71 = lVar71 + 1;
fVar78 = fVar96;
fVar94 = fVar117;
} while (lVar71 != 0x20);
fVar116 = (fVar96 - fVar117) / _DAT_0014ea88;
uVar118 = (int)fVar116 * 2 ^ _DAT_0014a080;
uVar119 = (int)fVar117 * 2 ^ _UNK_0014a084;
uVar77 = -(uint)(_DAT_0014e540 < (int)uVar118);
uVar93 = -(uint)(_UNK_0014e544 < (int)uVar119);
fVar78 = (float)(~uVar77 & _DAT_0014e570 |
((uint)fVar116 & _DAT_0014e550) + _DAT_0014e560 & uVar77) +
(float)((uint)fVar116 & _DAT_0014a020) * _DAT_0014e520 * _DAT_0014e530;
fVar94 = (float)(~uVar93 & _UNK_0014e574 |
((uint)fVar117 & _UNK_0014e554) + _UNK_0014e564 & uVar93) +
(float)((uint)fVar117 & _UNK_0014a024) * _UNK_0014e524 * _UNK_0014e534;
fVar96 = (float)(~-(uint)(_UNK_0014e548 < _UNK_0014a088) & _UNK_0014e578 |
_UNK_0014e568 & -(uint)(_UNK_0014e548 < _UNK_0014a088)) +
_UNK_0014e528 * 0.0 * _UNK_0014e538;
fVar98 = (float)(~-(uint)(_UNK_0014e54c < _UNK_0014a08c) & _UNK_0014e57c |
_UNK_0014e56c & -(uint)(_UNK_0014e54c < _UNK_0014a08c)) +
_UNK_0014e52c * 0.0 * _UNK_0014e53c;
auVar89._0_4_ = ((uint)fVar78 & _DAT_0014e590) + ((uint)fVar78 >> 0xd & _DAT_0014e580);
auVar89._4_4_ = ((uint)fVar94 & _UNK_0014e594) + ((uint)fVar94 >> 0xd & _UNK_0014e584);
auVar89._8_4_ = ((uint)fVar96 & _UNK_0014e598) + ((uint)fVar96 >> 0xd & _UNK_0014e588);
auVar89._12_4_ = ((uint)fVar98 & _UNK_0014e59c) + ((uint)fVar98 >> 0xd & _UNK_0014e58c);
auVar101._0_4_ = -(uint)(_DAT_0014e5b0 < (int)uVar118);
auVar101._4_4_ = -(uint)(_UNK_0014e5b4 < (int)uVar119);
auVar101._8_4_ = -(uint)(_UNK_0014e5b8 < _UNK_0014a088);
auVar101._12_4_ = -(uint)(_UNK_0014e5bc < _UNK_0014a08c);
puVar1 = (int4 *)(param_2 + uVar70 * 0x18);
auVar72._0_4_ = (uint)fVar116 >> 0x10;
auVar72._4_4_ = (uint)fVar117 >> 0x10;
auVar72._8_8_ = 0;
auVar72 = pshuflw(auVar72 & _DAT_0014e5a0,
auVar101 & _DAT_0014e5c0 | auVar72 & _DAT_0014e5a0 | ~auVar101 & auVar89,
0xe8);
*puVar1 = auVar72._0_4_;
fVar78 = (float)(-(uint)(fVar116 != DAT_0014ea84) & (uint)(DAT_0014a0f0 / fVar116));
uVar77 = 0;
uVar93 = 0;
uVar118 = 0;
uVar119 = 0;
lVar71 = 0;
iVar100 = _DAT_0014a030;
iVar102 = _UNK_0014a034;
iVar103 = _UNK_0014a038;
iVar104 = _UNK_0014a03c;
iVar120 = _DAT_0014a030;
iVar121 = _UNK_0014a034;
iVar122 = _UNK_0014a038;
iVar123 = _UNK_0014a03c;
do {
pfVar2 = (float *)(param_1 + lVar71 * 4);
pfVar3 = (float *)(param_1 + 0x40 + lVar71 * 4);
iVar79 = (int)((*pfVar2 - fVar117) * fVar78 + fVar54);
iVar95 = (int)((pfVar2[1] - fVar117) * fVar78 + fVar55);
iVar97 = (int)((pfVar2[2] - fVar117) * fVar78 + fVar56);
iVar99 = (int)((pfVar2[3] - fVar117) * fVar78 + fVar57);
sVar9 = (short)iVar79;
cVar4 = (0 < sVar9) * (sVar9 < 0x100) * (char)iVar79 - (0xff < sVar9);
sVar10 = (short)((uint)iVar79 >> 0x10);
cVar17 = (char)((uint)iVar79 >> 0x10);
sVar75 = CONCAT11((0 < sVar10) * (sVar10 < 0x100) * cVar17 - (0xff < sVar10),cVar4);
sVar11 = (short)iVar95;
cVar5 = (0 < sVar11) * (sVar11 < 0x100) * (char)iVar95 - (0xff < sVar11);
sVar12 = (short)((uint)iVar95 >> 0x10);
cVar18 = (char)((uint)iVar95 >> 0x10);
uVar80 = CONCAT13((0 < sVar12) * (sVar12 < 0x100) * cVar18 - (0xff < sVar12),
CONCAT12(cVar5,sVar75));
sVar13 = (short)iVar97;
cVar6 = (0 < sVar13) * (sVar13 < 0x100) * (char)iVar97 - (0xff < sVar13);
sVar14 = (short)((uint)iVar97 >> 0x10);
cVar19 = (char)((uint)iVar97 >> 0x10);
uVar82 = CONCAT15((0 < sVar14) * (sVar14 < 0x100) * cVar19 - (0xff < sVar14),
CONCAT14(cVar6,uVar80));
sVar15 = (short)iVar99;
cVar7 = (0 < sVar15) * (sVar15 < 0x100) * (char)iVar99 - (0xff < sVar15);
sVar16 = (short)((uint)iVar99 >> 0x10);
cVar20 = (char)((uint)iVar99 >> 0x10);
uVar83 = CONCAT17((0 < sVar16) * (sVar16 < 0x100) * cVar20 - (0xff < sVar16),
CONCAT16(cVar7,uVar82));
cVar8 = (0 < sVar9) * (sVar9 < 0x100) * (char)iVar79 - (0xff < sVar9);
auVar84._0_10_ =
CONCAT19((0 < sVar10) * (sVar10 < 0x100) * cVar17 - (0xff < sVar10),
CONCAT18(cVar8,uVar83));
cVar17 = (0 < sVar11) * (sVar11 < 0x100) * (char)iVar95 - (0xff < sVar11);
auVar84[10] = cVar17;
auVar84[0xb] = (0 < sVar12) * (sVar12 < 0x100) * cVar18 - (0xff < sVar12);
cVar18 = (0 < sVar13) * (sVar13 < 0x100) * (char)iVar97 - (0xff < sVar13);
auVar86[0xc] = cVar18;
auVar86._0_12_ = auVar84;
auVar86[0xd] = (0 < sVar14) * (sVar14 < 0x100) * cVar19 - (0xff < sVar14);
cVar19 = (0 < sVar15) * (sVar15 < 0x100) * (char)iVar99 - (0xff < sVar15);
auVar90[0xe] = cVar19;
auVar90._0_14_ = auVar86;
auVar90[0xf] = (0 < sVar16) * (sVar16 < 0x100) * cVar20 - (0xff < sVar16);
sVar9 = (short)((uint)uVar80 >> 0x10);
uVar76 = CONCAT11((0 < sVar9) * (sVar9 < 0x100) * cVar5 - (0xff < sVar9),
(0 < sVar75) * (sVar75 < 0x100) * cVar4 - (0xff < sVar75));
sVar10 = (short)((uint6)uVar82 >> 0x20);
sVar11 = (short)((ulong)uVar83 >> 0x30);
uVar81 = CONCAT13((0 < sVar11) * (sVar11 < 0x100) * cVar7 - (0xff < sVar11),
CONCAT12((0 < sVar10) * (sVar10 < 0x100) * cVar6 - (0xff < sVar10),uVar76)
);
sVar12 = (short)((unkuint10)auVar84._0_10_ >> 0x40);
sVar13 = auVar84._10_2_;
uVar82 = CONCAT15((0 < sVar13) * (sVar13 < 0x100) * cVar17 - (0xff < sVar13),
CONCAT14((0 < sVar12) * (sVar12 < 0x100) * cVar8 - (0xff < sVar12),uVar81)
);
sVar14 = auVar86._12_2_;
sVar15 = auVar90._14_2_;
uVar83 = CONCAT17((0 < sVar15) * (sVar15 < 0x100) * cVar19 - (0xff < sVar15),
CONCAT16((0 < sVar14) * (sVar14 < 0x100) * cVar18 - (0xff < sVar14),uVar82
));
auVar85._0_10_ =
CONCAT19((0 < sVar9) * (sVar9 < 0x100) * cVar5 - (0xff < sVar9),
CONCAT18((0 < sVar75) * (sVar75 < 0x100) * cVar4 - (0xff < sVar75),uVar83));
auVar85[10] = (0 < sVar10) * (sVar10 < 0x100) * cVar6 - (0xff < sVar10);
auVar85[0xb] = (0 < sVar11) * (sVar11 < 0x100) * cVar7 - (0xff < sVar11);
auVar87[0xc] = (0 < sVar12) * (sVar12 < 0x100) * cVar8 - (0xff < sVar12);
auVar87._0_12_ = auVar85;
auVar87[0xd] = (0 < sVar13) * (sVar13 < 0x100) * cVar17 - (0xff < sVar13);
auVar91[0xe] = (0 < sVar14) * (sVar14 < 0x100) * cVar18 - (0xff < sVar14);
auVar91._0_14_ = auVar87;
auVar91[0xf] = (0 < sVar15) * (sVar15 < 0x100) * cVar19 - (0xff < sVar15);
iVar79 = (int)((*pfVar3 - fVar117) * fVar78 + fVar54);
iVar95 = (int)((pfVar3[1] - fVar117) * fVar78 + fVar55);
iVar97 = (int)((pfVar3[2] - fVar117) * fVar78 + fVar56);
iVar99 = (int)((pfVar3[3] - fVar117) * fVar78 + fVar57);
sVar9 = (short)iVar79;
cVar4 = (0 < sVar9) * (sVar9 < 0x100) * (char)iVar79 - (0xff < sVar9);
sVar10 = (short)((uint)iVar79 >> 0x10);
cVar6 = (char)((uint)iVar79 >> 0x10);
sVar75 = CONCAT11((0 < sVar10) * (sVar10 < 0x100) * cVar6 - (0xff < sVar10),cVar4);
sVar11 = (short)iVar95;
cVar19 = (0 < sVar11) * (sVar11 < 0x100) * (char)iVar95 - (0xff < sVar11);
sVar12 = (short)((uint)iVar95 >> 0x10);
cVar7 = (char)((uint)iVar95 >> 0x10);
uVar80 = CONCAT13((0 < sVar12) * (sVar12 < 0x100) * cVar7 - (0xff < sVar12),
CONCAT12(cVar19,sVar75));
sVar13 = (short)iVar97;
cVar18 = (0 < sVar13) * (sVar13 < 0x100) * (char)iVar97 - (0xff < sVar13);
sVar14 = (short)((uint)iVar97 >> 0x10);
cVar20 = (char)((uint)iVar97 >> 0x10);
uVar106 = CONCAT15((0 < sVar14) * (sVar14 < 0x100) * cVar20 - (0xff < sVar14),
CONCAT14(cVar18,uVar80));
sVar15 = (short)iVar99;
cVar17 = (0 < sVar15) * (sVar15 < 0x100) * (char)iVar99 - (0xff < sVar15);
sVar16 = (short)((uint)iVar99 >> 0x10);
cVar21 = (char)((uint)iVar99 >> 0x10);
uVar107 = CONCAT17((0 < sVar16) * (sVar16 < 0x100) * cVar21 - (0xff < sVar16),
CONCAT16(cVar17,uVar106));
cVar5 = (0 < sVar9) * (sVar9 < 0x100) * (char)iVar79 - (0xff < sVar9);
auVar108._0_10_ =
CONCAT19((0 < sVar10) * (sVar10 < 0x100) * cVar6 - (0xff < sVar10),
CONCAT18(cVar5,uVar107));
cVar8 = (0 < sVar11) * (sVar11 < 0x100) * (char)iVar95 - (0xff < sVar11);
auVar108[10] = cVar8;
auVar108[0xb] = (0 < sVar12) * (sVar12 < 0x100) * cVar7 - (0xff < sVar12);
cVar7 = (0 < sVar13) * (sVar13 < 0x100) * (char)iVar97 - (0xff < sVar13);
auVar110[0xc] = cVar7;
auVar110._0_12_ = auVar108;
auVar110[0xd] = (0 < sVar14) * (sVar14 < 0x100) * cVar20 - (0xff < sVar14);
cVar6 = (0 < sVar15) * (sVar15 < 0x100) * (char)iVar99 - (0xff < sVar15);
auVar113[0xe] = cVar6;
auVar113._0_14_ = auVar110;
auVar113[0xf] = (0 < sVar16) * (sVar16 < 0x100) * cVar21 - (0xff < sVar16);
sVar9 = (short)((uint)uVar80 >> 0x10);
uVar105 = CONCAT11((0 < sVar9) * (sVar9 < 0x100) * cVar19 - (0xff < sVar9),
(0 < sVar75) * (sVar75 < 0x100) * cVar4 - (0xff < sVar75));
sVar10 = (short)((uint6)uVar106 >> 0x20);
sVar11 = (short)((ulong)uVar107 >> 0x30);
uVar80 = CONCAT13((0 < sVar11) * (sVar11 < 0x100) * cVar17 - (0xff < sVar11),
CONCAT12((0 < sVar10) * (sVar10 < 0x100) * cVar18 - (0xff < sVar10),
uVar105));
sVar12 = (short)((unkuint10)auVar108._0_10_ >> 0x40);
sVar13 = auVar108._10_2_;
uVar106 = CONCAT15((0 < sVar13) * (sVar13 < 0x100) * cVar8 - (0xff < sVar13),
CONCAT14((0 < sVar12) * (sVar12 < 0x100) * cVar5 - (0xff < sVar12),uVar80
));
sVar14 = auVar110._12_2_;
sVar15 = auVar113._14_2_;
uVar107 = CONCAT17((0 < sVar15) * (sVar15 < 0x100) * cVar6 - (0xff < sVar15),
CONCAT16((0 < sVar14) * (sVar14 < 0x100) * cVar7 - (0xff < sVar14),
uVar106));
auVar109._0_10_ =
CONCAT19((0 < sVar9) * (sVar9 < 0x100) * cVar19 - (0xff < sVar9),
CONCAT18((0 < sVar75) * (sVar75 < 0x100) * cVar4 - (0xff < sVar75),uVar107));
auVar109[10] = (0 < sVar10) * (sVar10 < 0x100) * cVar18 - (0xff < sVar10);
auVar109[0xb] = (0 < sVar11) * (sVar11 < 0x100) * cVar17 - (0xff < sVar11);
auVar111[0xc] = (0 < sVar12) * (sVar12 < 0x100) * cVar5 - (0xff < sVar12);
auVar111._0_12_ = auVar109;
auVar111[0xd] = (0 < sVar13) * (sVar13 < 0x100) * cVar8 - (0xff < sVar13);
auVar114[0xe] = (0 < sVar14) * (sVar14 < 0x100) * cVar7 - (0xff < sVar14);
auVar114._0_14_ = auVar111;
auVar114[0xf] = (0 < sVar15) * (sVar15 < 0x100) * cVar6 - (0xff < sVar15);
auVar72 = psllw(auVar114,4);
*(uint *)(lVar69 + lVar71) = auVar72._0_4_ & uVar58 | uVar81 & SUB164(_DAT_0014e500,0);
auVar92._0_2_ = uVar76 >> 4;
auVar92._2_2_ = (ushort)(uVar81 >> 0x14);
auVar92._4_2_ = (ushort)((uint6)uVar82 >> 0x24);
auVar92._6_2_ = (ushort)((ulong)uVar83 >> 0x34);
auVar92._8_2_ = (ushort)((unkuint10)auVar85._0_10_ >> 0x44);
auVar92._10_2_ = auVar85._10_2_ >> 4;
auVar92._12_2_ = auVar87._12_2_ >> 4;
auVar92._14_2_ = auVar91._14_2_ >> 4;
auVar88 = auVar92._0_15_ & auVar59._0_15_;
auVar112[0xd] = 0;
auVar112._0_13_ = auVar88._0_13_;
auVar112[0xe] = auVar88[7];
auVar25[0xc] = auVar88[6];
auVar25._0_12_ = auVar88._0_12_;
auVar25._13_2_ = auVar112._13_2_;
auVar27[0xb] = 0;
auVar27._0_11_ = auVar88._0_11_;
auVar27._12_3_ = auVar25._12_3_;
auVar30[10] = auVar88[5];
auVar30._0_10_ = auVar88._0_10_;
auVar30._11_4_ = auVar27._11_4_;
auVar32[9] = 0;
auVar32._0_9_ = auVar88._0_9_;
auVar32._10_5_ = auVar30._10_5_;
auVar36._1_6_ = auVar32._9_6_;
auVar36[0] = auVar88[4];
auVar36._7_8_ = 0;
Var37 = CONCAT81(SUB158(auVar36 << 0x40,7),auVar88[3]);
auVar44._9_6_ = 0;
auVar44._0_9_ = Var37;
auVar38._1_10_ = SUB1510(auVar44 << 0x30,5);
auVar38[0] = auVar88[2];
auVar45._11_4_ = 0;
auVar45._0_11_ = auVar38;
auVar39._1_12_ = SUB1512(auVar45 << 0x20,3);
auVar39[0] = auVar88[1];
uVar76 = CONCAT11(0,auVar88[0]);
auVar35._2_13_ = auVar39;
auVar35._0_2_ = uVar76;
auVar23._10_2_ = 0;
auVar23._0_10_ = auVar35._0_10_;
auVar23._12_2_ = (short)Var37;
uVar48 = CONCAT42(auVar23._10_4_,auVar38._0_2_);
auVar40._6_8_ = 0;
auVar40._0_6_ = uVar48;
auVar73._4_4_ = (int)(float)(iVar102 * 0x800000 + iVar61);
auVar73._12_4_ = (int)(float)(iVar104 * 0x800000 + iVar63);
auVar73._0_4_ = auVar73._4_4_;
auVar73._8_4_ = auVar73._12_4_;
auVar115._0_2_ = uVar105 >> 4;
auVar115._2_2_ = (ushort)((uint)uVar80 >> 0x14);
auVar115._4_2_ = (ushort)((uint6)uVar106 >> 0x24);
auVar115._6_2_ = (ushort)((ulong)uVar107 >> 0x34);
auVar115._8_2_ = (ushort)((unkuint10)auVar109._0_10_ >> 0x44);
auVar115._10_2_ = auVar109._10_2_ >> 4;
auVar115._12_2_ = auVar111._12_2_ >> 4;
auVar115._14_2_ = auVar114._14_2_ >> 4;
auVar112 = auVar115._0_15_ & auVar59._0_15_;
auVar88[0xd] = 0;
auVar88._0_13_ = auVar112._0_13_;
auVar88[0xe] = auVar112[7];
auVar24[0xc] = auVar112[6];
auVar24._0_12_ = auVar112._0_12_;
auVar24._13_2_ = auVar88._13_2_;
auVar26[0xb] = 0;
auVar26._0_11_ = auVar112._0_11_;
auVar26._12_3_ = auVar24._12_3_;
auVar28[10] = auVar112[5];
auVar28._0_10_ = auVar112._0_10_;
auVar28._11_4_ = auVar26._11_4_;
auVar31[9] = 0;
auVar31._0_9_ = auVar112._0_9_;
auVar31._10_5_ = auVar28._10_5_;
auVar41._1_6_ = auVar31._9_6_;
auVar41[0] = auVar112[4];
auVar41._7_8_ = 0;
Var37 = CONCAT81(SUB158(auVar41 << 0x40,7),auVar112[3]);
auVar46._9_6_ = 0;
auVar46._0_9_ = Var37;
auVar42._1_10_ = SUB1510(auVar46 << 0x30,5);
auVar42[0] = auVar112[2];
auVar47._11_4_ = 0;
auVar47._0_11_ = auVar42;
auVar33[2] = auVar112[1];
auVar33._0_2_ = auVar112._0_2_;
auVar33._3_12_ = SUB1512(auVar47 << 0x20,3);
auVar34._2_13_ = auVar33._2_13_;
auVar34._0_2_ = auVar112._0_2_ & 0xff;
auVar22._10_2_ = 0;
auVar22._0_10_ = auVar34._0_10_;
auVar22._12_2_ = (short)Var37;
uVar49 = CONCAT42(auVar22._10_4_,auVar42._0_2_);
auVar43._6_8_ = 0;
auVar43._0_6_ = uVar49;
auVar29._4_2_ = auVar33._2_2_;
auVar29._0_4_ = auVar34._0_4_;
auVar29._6_8_ = SUB148(auVar43 << 0x40,6);
auVar74._4_4_ = (int)(float)((iVar121 + iVar65) * 0x800000 + iVar61);
auVar74._12_4_ = (int)(float)((iVar123 + iVar67) * 0x800000 + iVar63);
auVar74._0_4_ = auVar74._4_4_;
auVar74._8_4_ = auVar74._12_4_;
uVar77 = uVar77 | (auVar34._0_4_ & 0xffff) *
(int)(float)((iVar120 + iVar64) * 0x800000 + iVar60) +
(uint)uVar76 * (int)(float)(iVar100 * 0x800000 + iVar60);
uVar93 = uVar93 | auVar74._4_4_ * auVar29._4_4_ +
auVar73._4_4_ * (int)CONCAT82(SUB148(auVar40 << 0x40,6),auVar39._0_2_);
uVar118 = uVar118 | (int)(((ulong)uVar49 & 0xffffffff) *
(ulong)(uint)(int)(float)((iVar122 + iVar66) * 0x800000 + iVar62))
+ (int)(((ulong)uVar48 & 0xffffffff) *
(ulong)(uint)(int)(float)(iVar103 * 0x800000 + iVar62));
uVar119 = uVar119 | (int)((auVar74._8_8_ & 0xffffffff) * (ulong)(auVar22._10_4_ >> 0x10)) +
(int)((auVar73._8_8_ & 0xffffffff) * (ulong)(auVar23._10_4_ >> 0x10));
lVar71 = lVar71 + 4;
iVar100 = iVar100 + iVar50;
iVar102 = iVar102 + iVar51;
iVar103 = iVar103 + iVar52;
iVar104 = iVar104 + iVar53;
iVar120 = iVar120 + iVar50;
iVar121 = iVar121 + iVar51;
iVar122 = iVar122 + iVar52;
iVar123 = iVar123 + iVar53;
} while (lVar71 != 0x10);
puVar1[1] = uVar119 | uVar93 | uVar118 | uVar77;
uVar70 = uVar70 + 1;
param_1 = param_1 + 0x80;
lVar69 = lVar69 + 0x18;
} while (uVar70 != (uVar68 & 0x7fffffff));
}
return;
}
| |
38,002 | void nlohmann::json_abi_v3_11_3::detail::get_arithmetic_value<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, double, 0>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, double&) | monkey531[P]llama/common/json.hpp | void get_arithmetic_value(const BasicJsonType& j, ArithmeticType& val)
{
switch (static_cast<value_t>(j))
{
case value_t::number_unsigned:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_unsigned_t*>());
break;
}
case value_t::number_integer:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_integer_t*>());
break;
}
case value_t::number_float:
{
val = static_cast<ArithmeticType>(*j.template get_ptr<const typename BasicJsonType::number_float_t*>());
break;
}
case value_t::null:
case value_t::object:
case value_t::array:
case value_t::string:
case value_t::boolean:
case value_t::binary:
case value_t::discarded:
default:
JSON_THROW(type_error::create(302, concat("type must be number, but is ", j.type_name()), &j));
}
} | O3 | cpp | void nlohmann::json_abi_v3_11_3::detail::get_arithmetic_value<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, double, 0>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, double&):
pushq %rbp
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rdi, %r14
movzbl (%rdi), %eax
cmpl $0x5, %eax
je 0x87437
cmpl $0x7, %eax
je 0x8742f
cmpl $0x6, %eax
jne 0x8744a
movsd 0x8(%r14), %xmm1
unpcklps 0x675e7(%rip), %xmm1 # xmm1 = xmm1[0],mem[0],xmm1[1],mem[1]
subpd 0x675ef(%rip), %xmm1 # 0xeea10
movapd %xmm1, %xmm0
unpckhpd %xmm1, %xmm0 # xmm0 = xmm0[1],xmm1[1]
addsd %xmm1, %xmm0
jmp 0x8743d
movsd 0x8(%r14), %xmm0
jmp 0x8743d
cvtsi2sdq 0x8(%r14), %xmm0
movsd %xmm0, (%rsi)
addq $0x30, %rsp
popq %rbx
popq %r14
popq %rbp
retq
movl $0x20, %edi
callq 0x1a460
movq %rax, %rbx
movq %r14, %rdi
callq 0x5ef2e
leaq 0x8(%rsp), %rdx
movq %rax, (%rdx)
leaq 0x68992(%rip), %rsi # 0xefe00
leaq 0x10(%rsp), %rdi
callq 0x86ad7
movb $0x1, %bpl
leaq 0x10(%rsp), %rdx
movq %rbx, %rdi
movl $0x12e, %esi # imm = 0x12E
movq %r14, %rcx
callq 0x86908
xorl %ebp, %ebp
leaq 0xa2abf(%rip), %rsi # 0x129f58
leaq -0x2c33c(%rip), %rdx # 0x5b164
movq %rbx, %rdi
callq 0x1af40
movq %rax, %r14
leaq 0x20(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x874c6
movq 0x20(%rsp), %rsi
incq %rsi
callq 0x1a900
testb %bpl, %bpl
jne 0x874d0
jmp 0x874d8
movq %rax, %r14
movq %rbx, %rdi
callq 0x1a690
movq %r14, %rdi
callq 0x1afd0
| _ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEdTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_:
push rbp; char
push r14; int
push rbx; __int64
sub rsp, 30h
mov r14, rdi
movzx eax, byte ptr [rdi]
cmp eax, 5
jz short loc_87437
cmp eax, 7
jz short loc_8742F
cmp eax, 6
jnz short loc_8744A
movsd xmm1, qword ptr [r14+8]
unpcklps xmm1, cs:xmmword_EEA00
subpd xmm1, cs:xmmword_EEA10
movapd xmm0, xmm1
unpckhpd xmm0, xmm1
addsd xmm0, xmm1
jmp short loc_8743D
loc_8742F:
movsd xmm0, qword ptr [r14+8]
jmp short loc_8743D
loc_87437:
cvtsi2sd xmm0, qword ptr [r14+8]
loc_8743D:
movsd qword ptr [rsi], xmm0
add rsp, 30h
pop rbx
pop r14
pop rbp
retn
loc_8744A:
mov edi, 20h ; ' '; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
mov rdi, r14
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9type_nameEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::type_name(void)
lea rdx, [rsp+48h+var_40]
mov [rdx], rax
lea rsi, aTypeMustBeNumb; "type must be number, but is "
lea rdi, [rsp+48h+var_38]
call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA29_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(char const(&)[29],char const* &&)
mov bpl, 1
lea rdx, [rsp+48h+var_38]
mov rdi, rbx; this
mov esi, 12Eh; int
mov rcx, r14
call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_
xor ebp, ebp
lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo
lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rax, [rsp+48h+var_28]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_874C6
mov rsi, [rsp+48h+var_28]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_874C6:
test bpl, bpl
jnz short loc_874D0
jmp short loc_874D8
mov r14, rax
loc_874D0:
mov rdi, rbx; void *
call ___cxa_free_exception
loc_874D8:
mov rdi, r14
call __Unwind_Resume
| long long ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEdTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_(
unsigned __int8 *a1,
double *a2)
{
long long result; // rax
__m128d v3; // xmm1
double v4; // xmm0_8
nlohmann::json_abi_v3_11_3::detail::exception *exception; // rbx
const char *v6; // [rsp+8h] [rbp-40h] BYREF
_QWORD v7[2]; // [rsp+10h] [rbp-38h] BYREF
result = *a1;
switch ( (_DWORD)result )
{
case 5:
v4 = (double)(int)*((_QWORD *)a1 + 1);
break;
case 7:
v4 = *((double *)a1 + 1);
break;
case 6:
v3 = _mm_sub_pd(
(__m128d)_mm_unpacklo_ps((__m128)*((unsigned long long *)a1 + 1), (__m128)xmmword_EEA00),
(__m128d)xmmword_EEA10);
v4 = _mm_unpackhi_pd(v3, v3).m128d_f64[0] + v3.m128d_f64[0];
break;
default:
exception = (nlohmann::json_abi_v3_11_3::detail::exception *)__cxa_allocate_exception(0x20uLL);
v6 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::type_name(a1);
nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[29],char const*>(
(long long)v7,
(long long)"type must be number, but is ",
&v6);
ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_(
exception,
302,
v7);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'nlohmann::json_abi_v3_11_3::detail::type_error,
(void (*)(void *))nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
*a2 = v4;
return result;
}
| _ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEdTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x30
MOV R14,RDI
MOVZX EAX,byte ptr [RDI]
CMP EAX,0x5
JZ 0x00187437
CMP EAX,0x7
JZ 0x0018742f
CMP EAX,0x6
JNZ 0x0018744a
MOVSD XMM1,qword ptr [R14 + 0x8]
UNPCKLPS XMM1,xmmword ptr [0x001eea00]
SUBPD XMM1,xmmword ptr [0x001eea10]
MOVAPD XMM0,XMM1
UNPCKHPD XMM0,XMM1
ADDSD XMM0,XMM1
JMP 0x0018743d
LAB_0018742f:
MOVSD XMM0,qword ptr [R14 + 0x8]
JMP 0x0018743d
LAB_00187437:
CVTSI2SD XMM0,qword ptr [R14 + 0x8]
LAB_0018743d:
MOVSD qword ptr [RSI],XMM0
ADD RSP,0x30
POP RBX
POP R14
POP RBP
RET
LAB_0018744a:
MOV EDI,0x20
CALL 0x0011a460
MOV RBX,RAX
MOV RDI,R14
CALL 0x0015ef2e
LEA RDX,[RSP + 0x8]
MOV qword ptr [RDX],RAX
LAB_00187467:
LEA RSI,[0x1efe00]
LEA RDI,[RSP + 0x10]
CALL 0x00186ad7
MOV BPL,0x1
LAB_0018747b:
LEA RDX,[RSP + 0x10]
MOV RDI,RBX
MOV ESI,0x12e
MOV RCX,R14
CALL 0x00186908
XOR EBP,EBP
LEA RSI,[0x229f58]
LEA RDX,[0x15b164]
MOV RDI,RBX
CALL 0x0011af40
|
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
void _ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEdTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_
(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
*param_1,double *param_2)
{
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
bVar1;
int8 uVar2;
double dVar3;
char *local_40;
detail local_38 [32];
bVar1 = *param_1;
if (bVar1 == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x5) {
dVar3 = (double)*(long *)(param_1 + 8);
}
else if (bVar1 == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x7) {
dVar3 = *(double *)(param_1 + 8);
}
else {
if (bVar1 != (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
)0x6) {
uVar2 = __cxa_allocate_exception(0x20);
local_40 = (char *)nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::type_name(param_1);
/* try { // try from 00187467 to 00187477 has its CatchHandler @ 001874cd */
nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string,char_const(&)[29],char_const*>
(local_38,"type must be number, but is ",&local_40);
/* try { // try from 0018747b to 001874a7 has its CatchHandler @ 001874a8 */
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SK_
(uVar2,0x12e,local_38,param_1);
/* WARNING: Subroutine does not return */
__cxa_throw(uVar2,&nlohmann::json_abi_v3_11_3::detail::type_error::typeinfo,
nlohmann::json_abi_v3_11_3::detail::exception::~exception);
}
dVar3 = ((double)CONCAT44(_UNK_001eea04,(int)((ulong)*(int8 *)(param_1 + 8) >> 0x20)) -
_UNK_001eea18) +
((double)CONCAT44(_DAT_001eea00,(int)*(int8 *)(param_1 + 8)) - _DAT_001eea10);
}
*param_2 = dVar3;
return;
}
| |
38,003 | file_input::file_input(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, float) | monkey531[P]llama/examples/export-lora/export-lora.cpp | file_input(std::string & fname, float scale): f_in(fname, std::ios::binary), scale(scale) {
if (!f_in.is_open()) {
throw std::runtime_error("failed to open input gguf from " + fname);
}
ctx_gguf = load_gguf(fname, &ctx_meta);
alpha = get_kv_f32(ctx_gguf, "adapter.lora.alpha");
printf("%s: loaded gguf from %s\n", __func__, fname.c_str());
for (ggml_tensor * cur = ggml_get_first_tensor(ctx_meta); cur; cur = ggml_get_next_tensor(ctx_meta, cur)) {
std::string name(cur->name);
tensors[name] = cur;
if (g_verbose) {
printf("%s: %s\n", __func__, cur->name);
}
}
} | O0 | cpp | file_input::file_input(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, float):
subq $0x118, %rsp # imm = 0x118
movq %rdi, 0x110(%rsp)
movq %rsi, 0x108(%rsp)
movss %xmm0, 0x104(%rsp)
movq 0x110(%rsp), %rdi
movq %rdi, 0x60(%rsp)
movq $0x0, (%rdi)
movq $0x0, 0x8(%rdi)
addq $0x10, %rdi
movq %rdi, 0x68(%rsp)
movq 0x108(%rsp), %rsi
movl $0x4, %edx
callq 0x5c4d0
movq 0x60(%rsp), %rdi
addq $0x218, %rdi # imm = 0x218
movq %rdi, 0x58(%rsp)
callq 0x674e0
movq 0x60(%rsp), %rax
movq 0x68(%rsp), %rdi
movss 0x104(%rsp), %xmm0
movss %xmm0, 0x24c(%rax)
callq 0x5c210
movb %al, 0x76(%rsp)
jmp 0x66843
movb 0x76(%rsp), %al
testb $0x1, %al
jne 0x6692a
jmp 0x66851
movb $0x1, 0xcf(%rsp)
movl $0x10, %edi
callq 0x5b740
movq %rax, 0x50(%rsp)
movq 0x108(%rsp), %rdx
leaq 0x1a6948(%rip), %rsi # 0x20d1bf
leaq 0xd0(%rsp), %rdi
callq 0x674f0
jmp 0x66886
movq 0x50(%rsp), %rdi
leaq 0xd0(%rsp), %rsi
callq 0x5b4f0
jmp 0x6689a
movq 0x50(%rsp), %rdi
movb $0x0, 0xcf(%rsp)
movq 0x244702(%rip), %rsi # 0x2aafb0
movq 0x2446c3(%rip), %rdx # 0x2aaf78
callq 0x5bc30
jmp 0x66bbb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
jmp 0x66b9a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
jmp 0x6690f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
leaq 0xd0(%rsp), %rdi
callq 0x5c7f8
testb $0x1, 0xcf(%rsp)
jne 0x6691b
jmp 0x66925
movq 0x50(%rsp), %rdi
callq 0x5c130
jmp 0x66b9a
movq 0x60(%rsp), %rsi
movq 0x108(%rsp), %rdi
callq 0x601f0
movq %rax, 0x48(%rsp)
jmp 0x66943
movq 0x60(%rsp), %rax
movq 0x48(%rsp), %rcx
movq %rcx, 0x8(%rax)
movq 0x8(%rax), %rax
movq %rax, 0x38(%rsp)
leaq 0xa7(%rsp), %rdi
movq %rdi, 0x40(%rsp)
callq 0x5c2c0
movq 0x40(%rsp), %rdx
leaq 0x1a6867(%rip), %rsi # 0x20d1df
leaq 0xa8(%rsp), %rdi
callq 0x63990
jmp 0x66987
movq 0x38(%rsp), %rdi
leaq 0xa8(%rsp), %rsi
callq 0x60300
movss %xmm0, 0x34(%rsp)
jmp 0x669a1
movq 0x60(%rsp), %rax
movss 0x34(%rsp), %xmm0
movss %xmm0, 0x248(%rax)
leaq 0xa8(%rsp), %rdi
callq 0x5c7f8
leaq 0xa7(%rsp), %rdi
callq 0x5c7d0
movq 0x108(%rsp), %rdi
callq 0x5b1d0
movq %rax, %rdx
leaq 0x1a680d(%rip), %rdi # 0x20d1f2
leaq 0x1a681f(%rip), %rsi # 0x20d20b
xorl %eax, %eax
callq 0x5b100
jmp 0x669f5
movq 0x60(%rsp), %rax
movq (%rax), %rdi
callq 0x5c690
movq %rax, 0x28(%rsp)
jmp 0x66a09
movq 0x28(%rsp), %rax
movq %rax, 0x98(%rsp)
cmpq $0x0, 0x98(%rsp)
je 0x66b92
movq 0x98(%rsp), %rax
addq $0x100, %rax # imm = 0x100
movq %rax, 0x18(%rsp)
leaq 0x77(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0x5c2c0
movq 0x18(%rsp), %rsi
movq 0x20(%rsp), %rdx
leaq 0x78(%rsp), %rdi
callq 0x63990
jmp 0x66a5d
leaq 0x77(%rsp), %rdi
callq 0x5c7d0
movq 0x60(%rsp), %rdi
movq 0x98(%rsp), %rax
movq %rax, 0x8(%rsp)
addq $0x218, %rdi # imm = 0x218
leaq 0x78(%rsp), %rsi
callq 0x67620
movq %rax, 0x10(%rsp)
jmp 0x66a91
movq 0x10(%rsp), %rax
movq 0x8(%rsp), %rcx
movq %rcx, (%rax)
testb $0x1, 0x2455ec(%rip) # 0x2ac091
je 0x66b5c
movq 0x98(%rsp), %rdx
addq $0x100, %rdx # imm = 0x100
leaq 0x1a6755(%rip), %rdi # 0x20d216
leaq 0x1a6743(%rip), %rsi # 0x20d20b
xorl %eax, %eax
callq 0x5b100
jmp 0x66ad1
jmp 0x66b5c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
jmp 0x66b0d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
leaq 0xa8(%rsp), %rdi
callq 0x5c7f8
leaq 0xa7(%rsp), %rdi
callq 0x5c7d0
jmp 0x66b9a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
leaq 0x77(%rsp), %rdi
callq 0x5c7d0
jmp 0x66b9a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xf8(%rsp)
movl %eax, 0xf4(%rsp)
leaq 0x78(%rsp), %rdi
callq 0x5c7f8
jmp 0x66b9a
leaq 0x78(%rsp), %rdi
callq 0x5c7f8
movq 0x60(%rsp), %rax
movq (%rax), %rdi
movq 0x98(%rsp), %rsi
callq 0x5bf90
movq %rax, (%rsp)
jmp 0x66b81
movq (%rsp), %rax
movq %rax, 0x98(%rsp)
jmp 0x66a16
addq $0x118, %rsp # imm = 0x118
retq
movq 0x58(%rsp), %rdi
callq 0x67710
movq 0x68(%rsp), %rdi
callq 0x5b0b0
movq 0xf8(%rsp), %rdi
callq 0x5bd10
nopl (%rax,%rax)
| _ZN10file_inputC2ERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEf:
sub rsp, 118h
mov [rsp+118h+var_8], rdi
mov qword ptr [rsp+118h+var_10], rsi
movss [rsp+118h+var_14], xmm0
mov rdi, [rsp+118h+var_8]
mov qword ptr [rsp+118h+var_B8], rdi
mov qword ptr [rdi], 0
mov qword ptr [rdi+8], 0
add rdi, 10h
mov [rsp+118h+var_B0], rdi
mov rsi, qword ptr [rsp+118h+var_10]
mov edx, 4
call __ZNSt14basic_ifstreamIcSt11char_traitsIcEEC1ERKNSt7__cxx1112basic_stringIcS1_SaIcEEESt13_Ios_Openmode; std::ifstream::basic_ifstream(std::string const&,std::_Ios_Openmode)
mov rdi, qword ptr [rsp+118h+var_B8]
add rdi, 218h
mov [rsp+118h+var_C0], rdi
call _ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP11ggml_tensorSt4lessIS5_ESaISt4pairIKS5_S7_EEEC2Ev; std::map<std::string,ggml_tensor *>::map(void)
mov rax, qword ptr [rsp+118h+var_B8]
mov rdi, [rsp+118h+var_B0]
movss xmm0, [rsp+118h+var_14]
movss dword ptr [rax+24Ch], xmm0
call __ZNSt14basic_ifstreamIcSt11char_traitsIcEE7is_openEv; std::ifstream::is_open(void)
mov [rsp+118h+var_A2], al
jmp short $+2
loc_66843:
mov al, [rsp+118h+var_A2]
test al, 1
jnz loc_6692A
jmp short $+2
loc_66851:
mov [rsp+118h+var_49], 1
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov [rsp+118h+var_C8], rax
mov rdx, qword ptr [rsp+118h+var_10]; int
lea rsi, aFailedToOpenIn; "failed to open input gguf from "
lea rdi, [rsp+118h+var_48]; int
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&)
jmp short $+2
loc_66886:
mov rdi, [rsp+118h+var_C8]
lea rsi, [rsp+118h+var_48]
call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
jmp short $+2
loc_6689A:
mov rdi, [rsp+118h+var_C8]; void *
mov [rsp+118h+var_49], 0
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZNSt13runtime_errorD1Ev_ptr; void (*)(void *)
call ___cxa_throw
jmp loc_66BBB
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
jmp loc_66B9A
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
jmp short loc_6690F
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
lea rdi, [rsp+arg_C8]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_6690F:
test [rsp+arg_C7], 1
jnz short loc_6691B
jmp short loc_66925
loc_6691B:
mov rdi, [rsp+arg_48]; void *
call ___cxa_free_exception
loc_66925:
jmp loc_66B9A
loc_6692A:
mov rsi, qword ptr [rsp+118h+var_B8]; int
mov rdi, qword ptr [rsp+118h+var_10]; int
call _ZL9load_ggufRNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPP12ggml_context; load_gguf(std::string &,ggml_context **)
mov [rsp+118h+var_D0], rax
jmp short $+2
loc_66943:
mov rax, qword ptr [rsp+118h+var_B8]
mov rcx, [rsp+118h+var_D0]
mov [rax+8], rcx
mov rax, [rax+8]
mov [rsp+118h+var_E0], rax
lea rdi, [rsp+118h+var_71]
mov [rsp+118h+var_D8], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rdx, [rsp+118h+var_D8]
lea rsi, aAdapterLoraAlp; "adapter.lora.alpha"
lea rdi, [rsp+118h+var_70]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_66987:
mov rdi, [rsp+118h+var_E0]
lea rsi, [rsp+118h+var_70]
call _ZL10get_kv_f32P12gguf_contextRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; get_kv_f32(gguf_context *,std::string const&)
movss [rsp+118h+var_E4], xmm0
jmp short $+2
loc_669A1:
mov rax, qword ptr [rsp+118h+var_B8]
movss xmm0, [rsp+118h+var_E4]
movss dword ptr [rax+248h], xmm0
lea rdi, [rsp+118h+var_70]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
lea rdi, [rsp+118h+var_71]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov rdi, qword ptr [rsp+118h+var_10]
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void)
mov rdx, rax
lea rdi, aSLoadedGgufFro; "%s: loaded gguf from %s\n"
lea rsi, aFileInput; "file_input"
xor eax, eax
call _printf
jmp short $+2
loc_669F5:
mov rax, qword ptr [rsp+118h+var_B8]
mov rdi, [rax]
call _ggml_get_first_tensor
mov [rsp+118h+var_F0], rax
jmp short $+2
loc_66A09:
mov rax, [rsp+118h+var_F0]
mov [rsp+118h+var_80], rax
loc_66A16:
cmp [rsp+118h+var_80], 0
jz loc_66B92
mov rax, [rsp+118h+var_80]
add rax, 100h
mov [rsp+118h+var_100], rax
lea rdi, [rsp+118h+var_A1]
mov [rsp+118h+var_F8], rdi
call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void)
mov rsi, [rsp+118h+var_100]
mov rdx, [rsp+118h+var_F8]
lea rdi, [rsp+118h+var_A0]
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&)
jmp short $+2
loc_66A5D:
lea rdi, [rsp+118h+var_A1]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
mov rdi, qword ptr [rsp+118h+var_B8]
mov rax, [rsp+118h+var_80]
mov [rsp+118h+var_110], rax
add rdi, 218h
lea rsi, [rsp+118h+var_A0]
call _ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP11ggml_tensorSt4lessIS5_ESaISt4pairIKS5_S7_EEEixERSB_; std::map<std::string,ggml_tensor *>::operator[](std::string const&)
mov [rsp+118h+var_108], rax
jmp short $+2
loc_66A91:
mov rax, [rsp+118h+var_108]
mov rcx, [rsp+118h+var_110]
mov [rax], rcx
test cs:_ZL9g_verbose, 1; g_verbose
jz loc_66B5C
mov rdx, [rsp+118h+var_80]
add rdx, 100h
lea rdi, aSS; "%s: %s\n"
lea rsi, aFileInput; "file_input"
xor eax, eax
call _printf
jmp short $+2
loc_66AD1:
jmp loc_66B5C
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
jmp short loc_66B0D
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
lea rdi, [rsp+arg_A0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_66B0D:
lea rdi, [rsp+arg_9F]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_66B9A
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
lea rdi, [rsp+arg_6F]
call __ZNSaIcED1Ev; std::allocator<char>::~allocator()
jmp short loc_66B9A
mov rcx, rax
mov eax, edx
mov [rsp+arg_F0], rcx
mov [rsp+arg_EC], eax
lea rdi, [rsp+arg_70]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_66B9A
loc_66B5C:
lea rdi, [rsp+118h+var_A0]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
mov rax, qword ptr [rsp+118h+var_B8]
mov rdi, [rax]
mov rsi, [rsp+118h+var_80]
call _ggml_get_next_tensor
mov [rsp+118h+var_118], rax
jmp short $+2
loc_66B81:
mov rax, [rsp+118h+var_118]
mov [rsp+118h+var_80], rax
jmp loc_66A16
loc_66B92:
add rsp, 118h
retn
loc_66B9A:
mov rdi, [rsp+arg_50]
call _ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP11ggml_tensorSt4lessIS5_ESaISt4pairIKS5_S7_EEED2Ev; std::map<std::string,ggml_tensor *>::~map()
mov rdi, [rsp+arg_60]
call __ZNSt14basic_ifstreamIcSt11char_traitsIcEED1Ev; std::ifstream::~ifstream()
mov rdi, [rsp+arg_F0]
call __Unwind_Resume
loc_66BBB:
nop dword ptr [rax+rax+00h]
| long long file_input::file_input(float *a1, long long a2, float a3)
{
int v3; // ecx
int v4; // r8d
int v5; // r9d
const char *v6; // rax
long long result; // rax
int v8; // [rsp+0h] [rbp-118h]
int v9; // [rsp+8h] [rbp-110h]
long long v10; // [rsp+8h] [rbp-110h]
void *v11; // [rsp+10h] [rbp-108h]
int v12; // [rsp+18h] [rbp-100h]
long long v13; // [rsp+18h] [rbp-100h]
int v14; // [rsp+20h] [rbp-F8h]
int v15; // [rsp+28h] [rbp-F0h]
long long v16; // [rsp+30h] [rbp-E8h]
int v17; // [rsp+38h] [rbp-E0h]
long long v18; // [rsp+38h] [rbp-E0h]
void *exception; // [rsp+50h] [rbp-C8h]
char v20; // [rsp+77h] [rbp-A1h] BYREF
_BYTE v21[32]; // [rsp+78h] [rbp-A0h] BYREF
long long i; // [rsp+98h] [rbp-80h]
char v23; // [rsp+A7h] [rbp-71h] BYREF
_BYTE v24[40]; // [rsp+A8h] [rbp-70h] BYREF
int v25[13]; // [rsp+D0h] [rbp-48h] BYREF
float v26; // [rsp+104h] [rbp-14h]
int v27[2]; // [rsp+108h] [rbp-10h]
float *v28; // [rsp+110h] [rbp-8h]
v28 = a1;
*(_QWORD *)v27 = a2;
v26 = a3;
*(_QWORD *)a1 = 0LL;
*((_QWORD *)a1 + 1) = 0LL;
std::ifstream::basic_ifstream(a1 + 4, *(_QWORD *)v27, 4LL);
std::map<std::string,ggml_tensor *>::map();
a1[147] = v26;
if ( (std::ifstream::is_open(a1 + 4) & 1) == 0 )
{
exception = __cxa_allocate_exception(0x10uLL);
std::operator+<char>(
(int)v25,
(int)"failed to open input gguf from ",
v27[0],
v3,
v4,
v5,
v8,
v9,
v11,
v12,
v14,
v15,
v16,
v17);
std::runtime_error::runtime_error(exception, v25);
v24[39] = 0;
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
*((_QWORD *)a1 + 1) = load_gguf(*(long long *)v27, (long long)a1);
v18 = *((_QWORD *)a1 + 1);
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>((long long)v24, (long long)"adapter.lora.alpha", (long long)&v23);
a1[146] = get_kv_f32(v18, (long long)v24);
std::string::~string(v24);
std::allocator<char>::~allocator(&v23);
v6 = (const char *)std::string::c_str(*(_QWORD *)v27);
printf("%s: loaded gguf from %s\n", "file_input", v6);
result = ggml_get_first_tensor(*(_QWORD *)a1);
for ( i = result; i; i = result )
{
v13 = i + 256;
std::allocator<char>::allocator();
std::string::basic_string<std::allocator<char>>((long long)v21, v13, (long long)&v20);
std::allocator<char>::~allocator(&v20);
v10 = i;
*(_QWORD *)std::map<std::string,ggml_tensor *>::operator[](a1 + 134, v21) = v10;
if ( (g_verbose & 1) != 0 )
printf("%s: %s\n", "file_input", (const char *)(i + 256));
std::string::~string(v21);
result = ggml_get_next_tensor(*(_QWORD *)a1, i);
}
return result;
}
| file_input:
SUB RSP,0x118
MOV qword ptr [RSP + 0x110],RDI
MOV qword ptr [RSP + 0x108],RSI
MOVSS dword ptr [RSP + 0x104],XMM0
MOV RDI,qword ptr [RSP + 0x110]
MOV qword ptr [RSP + 0x60],RDI
MOV qword ptr [RDI],0x0
MOV qword ptr [RDI + 0x8],0x0
ADD RDI,0x10
MOV qword ptr [RSP + 0x68],RDI
MOV RSI,qword ptr [RSP + 0x108]
MOV EDX,0x4
CALL 0x0015c4d0
MOV RDI,qword ptr [RSP + 0x60]
ADD RDI,0x218
MOV qword ptr [RSP + 0x58],RDI
CALL 0x001674e0
MOV RAX,qword ptr [RSP + 0x60]
MOV RDI,qword ptr [RSP + 0x68]
MOVSS XMM0,dword ptr [RSP + 0x104]
MOVSS dword ptr [RAX + 0x24c],XMM0
LAB_00166838:
CALL 0x0015c210
LAB_0016683d:
MOV byte ptr [RSP + 0x76],AL
JMP 0x00166843
LAB_00166843:
MOV AL,byte ptr [RSP + 0x76]
TEST AL,0x1
JNZ 0x0016692a
JMP 0x00166851
LAB_00166851:
MOV byte ptr [RSP + 0xcf],0x1
MOV EDI,0x10
CALL 0x0015b740
MOV qword ptr [RSP + 0x50],RAX
MOV RDX,qword ptr [RSP + 0x108]
LAB_00166870:
LEA RSI,[0x30d1bf]
LEA RDI,[RSP + 0xd0]
CALL 0x001674f0
JMP 0x00166886
LAB_00166886:
MOV RDI,qword ptr [RSP + 0x50]
LEA RSI,[RSP + 0xd0]
CALL 0x0015b4f0
JMP 0x0016689a
LAB_0016689a:
MOV RDI,qword ptr [RSP + 0x50]
MOV byte ptr [RSP + 0xcf],0x0
MOV RSI,qword ptr [0x003aafb0]
MOV RDX,qword ptr [0x003aaf78]
CALL 0x0015bc30
LAB_0016692a:
MOV RSI,qword ptr [RSP + 0x60]
MOV RDI,qword ptr [RSP + 0x108]
LAB_00166937:
CALL 0x001601f0
MOV qword ptr [RSP + 0x48],RAX
JMP 0x00166943
LAB_00166943:
MOV RAX,qword ptr [RSP + 0x60]
MOV RCX,qword ptr [RSP + 0x48]
MOV qword ptr [RAX + 0x8],RCX
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x38],RAX
LEA RDI,[RSP + 0xa7]
MOV qword ptr [RSP + 0x40],RDI
CALL 0x0015c2c0
MOV RDX,qword ptr [RSP + 0x40]
LAB_00166971:
LEA RSI,[0x30d1df]
LEA RDI,[RSP + 0xa8]
CALL 0x00163990
JMP 0x00166987
LAB_00166987:
MOV RDI,qword ptr [RSP + 0x38]
LEA RSI,[RSP + 0xa8]
CALL 0x00160300
MOVSS dword ptr [RSP + 0x34],XMM0
JMP 0x001669a1
LAB_001669a1:
MOV RAX,qword ptr [RSP + 0x60]
MOVSS XMM0,dword ptr [RSP + 0x34]
MOVSS dword ptr [RAX + 0x248],XMM0
LEA RDI,[RSP + 0xa8]
CALL 0x0015c7f8
LEA RDI,[RSP + 0xa7]
CALL 0x0015c7d0
MOV RDI,qword ptr [RSP + 0x108]
CALL 0x0015b1d0
MOV RDX,RAX
LAB_001669de:
LEA RDI,[0x30d1f2]
LEA RSI,[0x30d20b]
XOR EAX,EAX
CALL 0x0015b100
JMP 0x001669f5
LAB_001669f5:
MOV RAX,qword ptr [RSP + 0x60]
MOV RDI,qword ptr [RAX]
CALL 0x0015c690
MOV qword ptr [RSP + 0x28],RAX
JMP 0x00166a09
LAB_00166a09:
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x98],RAX
LAB_00166a16:
CMP qword ptr [RSP + 0x98],0x0
JZ 0x00166b92
MOV RAX,qword ptr [RSP + 0x98]
ADD RAX,0x100
MOV qword ptr [RSP + 0x18],RAX
LEA RDI,[RSP + 0x77]
MOV qword ptr [RSP + 0x20],RDI
CALL 0x0015c2c0
MOV RSI,qword ptr [RSP + 0x18]
MOV RDX,qword ptr [RSP + 0x20]
LAB_00166a51:
LEA RDI,[RSP + 0x78]
CALL 0x00163990
JMP 0x00166a5d
LAB_00166a5d:
LEA RDI,[RSP + 0x77]
CALL 0x0015c7d0
MOV RDI,qword ptr [RSP + 0x60]
MOV RAX,qword ptr [RSP + 0x98]
MOV qword ptr [RSP + 0x8],RAX
ADD RDI,0x218
LAB_00166a80:
LEA RSI,[RSP + 0x78]
CALL 0x00167620
MOV qword ptr [RSP + 0x10],RAX
JMP 0x00166a91
LAB_00166a91:
MOV RAX,qword ptr [RSP + 0x10]
MOV RCX,qword ptr [RSP + 0x8]
MOV qword ptr [RAX],RCX
TEST byte ptr [0x003ac091],0x1
JZ 0x00166b5c
MOV RDX,qword ptr [RSP + 0x98]
ADD RDX,0x100
LEA RDI,[0x30d216]
LEA RSI,[0x30d20b]
XOR EAX,EAX
CALL 0x0015b100
JMP 0x00166ad1
LAB_00166ad1:
JMP 0x00166b5c
LAB_00166b5c:
LEA RDI,[RSP + 0x78]
CALL 0x0015c7f8
MOV RAX,qword ptr [RSP + 0x60]
MOV RDI,qword ptr [RAX]
MOV RSI,qword ptr [RSP + 0x98]
LAB_00166b76:
CALL 0x0015bf90
LAB_00166b7b:
MOV qword ptr [RSP],RAX
JMP 0x00166b81
LAB_00166b81:
MOV RAX,qword ptr [RSP]
MOV qword ptr [RSP + 0x98],RAX
JMP 0x00166a16
LAB_00166b92:
ADD RSP,0x118
RET
|
/* file_input::file_input(std::__cxx11::string&, float) */
void __thiscall file_input::file_input(file_input *this,string *param_1,float param_2)
{
gguf_context *pgVar1;
long lVar2;
byte bVar3;
runtime_error *this_00;
int8 uVar4;
char *pcVar5;
long *plVar6;
int4 uVar7;
allocator local_a1;
string local_a0 [32];
long local_80;
allocator local_71;
string local_70 [39];
int1 local_49;
string local_48 [52];
float local_14;
string *local_10;
file_input *local_8;
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
local_14 = param_2;
local_10 = param_1;
local_8 = this;
std::ifstream::ifstream((ifstream *)(this + 0x10),param_1,4);
std::
map<std::__cxx11::string,ggml_tensor*,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,ggml_tensor*>>>
::map((map<std::__cxx11::string,ggml_tensor*,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,ggml_tensor*>>>
*)(this + 0x218));
*(float *)(this + 0x24c) = local_14;
/* try { // try from 00166838 to 0016683c has its CatchHandler @ 001668bf */
bVar3 = std::ifstream::is_open();
if ((bVar3 & 1) == 0) {
local_49 = 1;
this_00 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00166870 to 00166883 has its CatchHandler @ 001668d8 */
std::operator+((char *)local_48,(string *)"failed to open input gguf from ");
/* try { // try from 00166886 to 001668b9 has its CatchHandler @ 001668ee */
std::runtime_error::runtime_error(this_00,local_48);
local_49 = 0;
/* WARNING: Subroutine does not return */
__cxa_throw(this_00,PTR_typeinfo_003aafb0,PTR__runtime_error_003aaf78);
}
/* try { // try from 00166937 to 0016693b has its CatchHandler @ 001668bf */
uVar4 = load_gguf(local_10,(ggml_context **)this);
*(int8 *)(this + 8) = uVar4;
pgVar1 = *(gguf_context **)(this + 8);
std::allocator<char>::allocator();
/* try { // try from 00166971 to 00166984 has its CatchHandler @ 00166ad6 */
std::__cxx11::string::string<std::allocator<char>>(local_70,"adapter.lora.alpha",&local_71);
/* try { // try from 00166987 to 00166998 has its CatchHandler @ 00166aec */
uVar7 = get_kv_f32(pgVar1,local_70);
*(int4 *)(this + 0x248) = uVar7;
std::__cxx11::string::~string(local_70);
std::allocator<char>::~allocator((allocator<char> *)&local_71);
uVar4 = std::__cxx11::string::c_str();
/* try { // try from 001669de to 00166a01 has its CatchHandler @ 001668bf */
printf("%s: loaded gguf from %s\n","file_input",uVar4);
for (local_80 = ggml_get_first_tensor(*(int8 *)this); local_80 != 0;
local_80 = ggml_get_next_tensor(*(int8 *)this,local_80)) {
pcVar5 = (char *)(local_80 + 0x100);
std::allocator<char>::allocator();
/* try { // try from 00166a51 to 00166a5a has its CatchHandler @ 00166b1c */
std::__cxx11::string::string<std::allocator<char>>(local_a0,pcVar5,&local_a1);
std::allocator<char>::~allocator((allocator<char> *)&local_a1);
lVar2 = local_80;
/* try { // try from 00166a80 to 00166ace has its CatchHandler @ 00166b3c */
plVar6 = (long *)std::
map<std::__cxx11::string,ggml_tensor*,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,ggml_tensor*>>>
::operator[]((map<std::__cxx11::string,ggml_tensor*,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,ggml_tensor*>>>
*)(this + 0x218),local_a0);
*plVar6 = lVar2;
if ((g_verbose & 1) != 0) {
printf("%s: %s\n","file_input",local_80 + 0x100);
}
std::__cxx11::string::~string(local_a0);
/* try { // try from 00166b76 to 00166b7a has its CatchHandler @ 001668bf */
}
return;
}
| |
38,004 | file_input::file_input(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, float) | monkey531[P]llama/examples/export-lora/export-lora.cpp | file_input(std::string & fname, float scale): f_in(fname, std::ios::binary), scale(scale) {
if (!f_in.is_open()) {
throw std::runtime_error("failed to open input gguf from " + fname);
}
ctx_gguf = load_gguf(fname, &ctx_meta);
alpha = get_kv_f32(ctx_gguf, "adapter.lora.alpha");
printf("%s: loaded gguf from %s\n", __func__, fname.c_str());
for (ggml_tensor * cur = ggml_get_first_tensor(ctx_meta); cur; cur = ggml_get_next_tensor(ctx_meta, cur)) {
std::string name(cur->name);
tensors[name] = cur;
if (g_verbose) {
printf("%s: %s\n", __func__, cur->name);
}
}
} | O3 | cpp | file_input::file_input(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&, float):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movss %xmm0, 0x24(%rsp)
movq %rsi, %r12
movq %rdi, %r15
addq $0x10, %rdi
xorps %xmm0, %xmm0
movups %xmm0, (%r15)
movq %rdi, 0x30(%rsp)
movl $0x4, %edx
callq 0x1c020
leaq 0x218(%r15), %rax
movq %rax, 0x28(%rsp)
leaq 0x220(%r15), %rax
movl $0x0, 0x220(%r15)
xorl %ecx, %ecx
movq %rcx, 0x228(%r15)
movq %rax, 0x230(%r15)
movq %rax, 0x238(%r15)
movq %rcx, 0x240(%r15)
movss 0x24(%rsp), %xmm0
movss %xmm0, 0x24c(%r15)
leaq 0x88(%r15), %rdi
callq 0x1b200
testb %al, %al
je 0x22e2b
movq (%r12), %rdi
movl $0x1, %esi
movq %r15, %rdx
callq 0x1bd90
movq %rax, %rbx
testq %rax, %rax
je 0x22e6f
movq %rbx, 0x8(%r15)
leaq 0x10(%rsp), %rbp
movq %rbp, -0x10(%rbp)
leaq 0xc5572(%rip), %rsi # 0xe8286
leaq 0xc557d(%rip), %rdx # 0xe8298
movq %rsp, %rdi
callq 0x22b0c
movq (%rsp), %rsi
movq %rbx, %rdi
callq 0x1be00
xorps %xmm0, %xmm0
testl %eax, %eax
js 0x22d46
andl $0x7fffffff, %eax # imm = 0x7FFFFFFF
movq %rbx, %rdi
movq %rax, %rsi
callq 0x1bc60
movss %xmm0, 0x248(%r15)
movq (%rsp), %rdi
cmpq %rbp, %rdi
je 0x22d65
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1ba20
movq (%r12), %rdx
leaq 0xc5529(%rip), %rdi # 0xe8299
leaq 0xc553b(%rip), %rsi # 0xe82b2
xorl %eax, %eax
callq 0x1b070
movq (%r15), %rdi
callq 0x1b370
movq %rax, %r12
movq %rsp, %r13
leaq 0xc551f(%rip), %rbx # 0xe82b2
testq %r12, %r12
je 0x22e1c
leaq 0x100(%r12), %r14
movq %rbp, (%rsp)
movq %r14, %rdi
callq 0x1b460
leaq (%r12,%rax), %rdx
addq $0x100, %rdx # imm = 0x100
movq %r13, %rdi
movq %r14, %rsi
callq 0x22b0c
movq 0x28(%rsp), %rdi
movq %r13, %rsi
callq 0x234c4
movq %r12, (%rax)
cmpb $0x1, 0x10c0d4(%rip) # 0x12eeb1
jne 0x22df3
leaq 0xc54d7(%rip), %rdi # 0xe82bd
movq %rbx, %rsi
movq %r14, %rdx
xorl %eax, %eax
callq 0x1b070
movq (%rsp), %rdi
cmpq %rbp, %rdi
je 0x22e09
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1ba20
movq (%r15), %rdi
movq %r12, %rsi
callq 0x1ba10
movq %rax, %r12
jmp 0x22d93
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x10, %edi
callq 0x1b4f0
movq %rax, %r13
leaq 0xc5427(%rip), %rsi # 0xe8266
movq %rsp, %rdi
movq %r12, %rdx
callq 0x2343c
movb $0x1, %bl
movq %rsp, %rsi
movq %r13, %rdi
callq 0x1c030
xorl %ebx, %ebx
movq 0x10b188(%rip), %rsi # 0x12dfe8
movq 0x10b0f1(%rip), %rdx # 0x12df58
movq %r13, %rdi
callq 0x1c150
movl $0x10, %edi
callq 0x1b4f0
movq %rax, %r13
leaq 0xc5442(%rip), %rsi # 0xe82c5
movq %rsp, %rdi
movq %r12, %rdx
callq 0x2343c
movb $0x1, %bl
movq %rsp, %rsi
movq %r13, %rdi
callq 0x1c030
xorl %ebx, %ebx
movq 0x10b144(%rip), %rsi # 0x12dfe8
movq 0x10b0ad(%rip), %rdx # 0x12df58
movq %r13, %rdi
callq 0x1c150
jmp 0x22eb7
jmp 0x22edb
movq %rax, %r15
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x22ed5
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1ba20
testb %bl, %bl
jne 0x22ede
jmp 0x22f10
movq %rax, %r15
movq %r13, %rdi
callq 0x1b770
jmp 0x22f10
jmp 0x22f0d
jmp 0x22f0d
jmp 0x22f0d
jmp 0x22ef2
jmp 0x22f0d
movq %rax, %r15
movq (%rsp), %rdi
cmpq %rbp, %rdi
je 0x22f10
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1ba20
jmp 0x22f10
movq %rax, %r15
movq 0x28(%rsp), %rdi
callq 0x238c0
movq 0x30(%rsp), %rdi
callq 0x1b230
movq %r15, %rdi
callq 0x1c1e0
| _ZN10file_inputC2ERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEf:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 38h
movss [rsp+68h+var_44], xmm0
mov r12, rsi
mov r15, rdi
add rdi, 10h
xorps xmm0, xmm0
movups xmmword ptr [r15], xmm0
mov [rsp+68h+var_38], rdi
mov edx, 4
call __ZNSt14basic_ifstreamIcSt11char_traitsIcEEC1ERKNSt7__cxx1112basic_stringIcS1_SaIcEEESt13_Ios_Openmode; std::ifstream::basic_ifstream(std::string const&,std::_Ios_Openmode)
lea rax, [r15+218h]
mov [rsp+68h+var_40], rax
lea rax, [r15+220h]
mov dword ptr [r15+220h], 0
xor ecx, ecx
mov [r15+228h], rcx
mov [r15+230h], rax
mov [r15+238h], rax
mov [r15+240h], rcx
movss xmm0, [rsp+68h+var_44]
movss dword ptr [r15+24Ch], xmm0
lea rdi, [r15+88h]
call __ZNKSt12__basic_fileIcE7is_openEv; std::__basic_file<char>::is_open(void)
test al, al
jz loc_22E2B
mov rdi, [r12]
mov esi, 1
mov rdx, r15
call _gguf_init_from_file
mov rbx, rax
test rax, rax
jz loc_22E6F
mov [r15+8], rbx
lea rbp, [rsp+68h+var_58]
mov [rbp-10h], rbp
lea rsi, aAdapterLoraAlp; "adapter.lora.alpha"
lea rdx, aAdapterLoraAlp+12h; ""
mov rdi, rsp
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
mov rsi, [rsp+68h+var_68]
mov rdi, rbx
call _gguf_find_key
xorps xmm0, xmm0
test eax, eax
js short loc_22D46
and eax, 7FFFFFFFh
mov rdi, rbx
mov rsi, rax
call _gguf_get_val_f32
loc_22D46:
movss dword ptr [r15+248h], xmm0
mov rdi, [rsp+68h+var_68]; void *
cmp rdi, rbp
jz short loc_22D65
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_22D65:
mov rdx, [r12]
lea rdi, aSLoadedGgufFro; "%s: loaded gguf from %s\n"
lea rsi, aFileInput; "file_input"
xor eax, eax
call _printf
mov rdi, [r15]
call _ggml_get_first_tensor
mov r12, rax
mov r13, rsp
lea rbx, aFileInput; "file_input"
loc_22D93:
test r12, r12
jz loc_22E1C
lea r14, [r12+100h]
mov [rsp+68h+var_68], rbp
mov rdi, r14
call _strlen
lea rdx, [r12+rax]
add rdx, 100h
mov rdi, r13
mov rsi, r14
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
mov rdi, [rsp+68h+var_40]
mov rsi, r13
call _ZNSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP11ggml_tensorSt4lessIS5_ESaISt4pairIKS5_S7_EEEixERSB_; std::map<std::string,ggml_tensor *>::operator[](std::string const&)
mov [rax], r12
cmp cs:_ZL9g_verbose, 1; g_verbose
jnz short loc_22DF3
lea rdi, aSS; "%s: %s\n"
mov rsi, rbx
mov rdx, r14
xor eax, eax
call _printf
loc_22DF3:
mov rdi, [rsp+68h+var_68]; void *
cmp rdi, rbp
jz short loc_22E09
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_22E09:
mov rdi, [r15]
mov rsi, r12
call _ggml_get_next_tensor
mov r12, rax
jmp loc_22D93
loc_22E1C:
add rsp, 38h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_22E2B:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r13, rax
lea rsi, aFailedToOpenIn; "failed to open input gguf from "
mov rdi, rsp
mov rdx, r12
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&)
mov bl, 1
mov rsi, rsp
mov rdi, r13
call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
xor ebx, ebx
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r13; void *
call ___cxa_throw
loc_22E6F:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r13, rax
lea rsi, aFailedToLoadIn; "failed to load input GGUF from "
mov rdi, rsp
mov rdx, r12
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_; std::operator+<char>(char const*,std::string const&)
mov bl, 1
mov rsi, rsp
mov rdi, r13
call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
xor ebx, ebx
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r13; void *
call ___cxa_throw
jmp short loc_22EB7
jmp short loc_22EDB
loc_22EB7:
mov r15, rax
lea rax, [rsp+68h+var_58]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_22ED5
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_22ED5:
test bl, bl
jnz short loc_22EDE
jmp short loc_22F10
loc_22EDB:
mov r15, rax
loc_22EDE:
mov rdi, r13; void *
call ___cxa_free_exception
jmp short loc_22F10
jmp short loc_22F0D
jmp short loc_22F0D
jmp short loc_22F0D
jmp short loc_22EF2
jmp short loc_22F0D
loc_22EF2:
mov r15, rax
mov rdi, [rsp+68h+var_68]; void *
cmp rdi, rbp
jz short loc_22F10
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_22F10
loc_22F0D:
mov r15, rax
loc_22F10:
mov rdi, [rsp+68h+var_40]
call _ZNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_P11ggml_tensorESt10_Select1stISA_ESt4lessIS5_ESaISA_EED2Ev; std::_Rb_tree<std::string,std::pair<std::string const,ggml_tensor *>,std::_Select1st<std::pair<std::string const,ggml_tensor *>>,std::less<std::string>,std::allocator<std::pair<std::string const,ggml_tensor *>>>::~_Rb_tree()
mov rdi, [rsp+68h+var_38]
call __ZNSt14basic_ifstreamIcSt11char_traitsIcEED1Ev; std::ifstream::~ifstream()
mov rdi, r15
call __Unwind_Resume
| long long file_input::file_input(_QWORD *a1, const char **a2, float a3)
{
long long v3; // rax
long long v4; // rbx
int key; // eax
float val_f32; // xmm0_4
long long result; // rax
long long i; // r12
long long v9; // rax
void *exception; // r13
void *v11; // r13
void *v12[2]; // [rsp+0h] [rbp-68h] BYREF
_QWORD v13[2]; // [rsp+10h] [rbp-58h] BYREF
float v14; // [rsp+24h] [rbp-44h]
_QWORD *v15; // [rsp+28h] [rbp-40h]
_QWORD *v16; // [rsp+30h] [rbp-38h]
v14 = a3;
*(_OWORD *)a1 = 0LL;
v16 = a1 + 2;
std::ifstream::basic_ifstream(a1 + 2, a2, 4LL);
v15 = a1 + 67;
*((_DWORD *)a1 + 136) = 0;
a1[69] = 0LL;
a1[70] = a1 + 68;
a1[71] = a1 + 68;
a1[72] = 0LL;
*((float *)a1 + 147) = v14;
if ( !(unsigned __int8)std::__basic_file<char>::is_open(a1 + 17) )
{
exception = __cxa_allocate_exception(0x10uLL);
std::operator+<char>(v12, "failed to open input gguf from ", a2);
std::runtime_error::runtime_error(exception);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
v3 = gguf_init_from_file(*a2, 1LL, a1);
v4 = v3;
if ( !v3 )
{
v11 = __cxa_allocate_exception(0x10uLL);
std::operator+<char>(v12, "failed to load input GGUF from ", a2);
std::runtime_error::runtime_error(v11);
__cxa_throw(
v11,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
a1[1] = v3;
v12[0] = v13;
std::string::_M_construct<char const*>((long long)v12, "adapter.lora.alpha", (long long)"");
key = gguf_find_key(v4, v12[0]);
val_f32 = 0.0;
if ( key >= 0 )
val_f32 = gguf_get_val_f32(v4, key & 0x7FFFFFFF, 0.0);
*((float *)a1 + 146) = val_f32;
if ( v12[0] != v13 )
operator delete(v12[0], v13[0] + 1LL);
printf("%s: loaded gguf from %s\n", "file_input", *a2);
result = ggml_get_first_tensor(*a1);
for ( i = result; i; i = result )
{
v12[0] = v13;
v9 = strlen(i + 256);
std::string::_M_construct<char const*>((long long)v12, (_BYTE *)(i + 256), i + v9 + 256);
*(_QWORD *)std::map<std::string,ggml_tensor *>::operator[](v15, v12) = i;
if ( g_verbose == 1 )
printf("%s: %s\n", "file_input", (const char *)(i + 256));
if ( v12[0] != v13 )
operator delete(v12[0], v13[0] + 1LL);
result = ggml_get_next_tensor(*a1, i);
}
return result;
}
| file_input:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x38
MOVSS dword ptr [RSP + 0x24],XMM0
MOV R12,RSI
MOV R15,RDI
ADD RDI,0x10
XORPS XMM0,XMM0
MOVUPS xmmword ptr [R15],XMM0
MOV qword ptr [RSP + 0x30],RDI
MOV EDX,0x4
CALL 0x0011c020
LEA RAX,[R15 + 0x218]
MOV qword ptr [RSP + 0x28],RAX
LEA RAX,[R15 + 0x220]
MOV dword ptr [R15 + 0x220],0x0
XOR ECX,ECX
MOV qword ptr [R15 + 0x228],RCX
MOV qword ptr [R15 + 0x230],RAX
MOV qword ptr [R15 + 0x238],RAX
MOV qword ptr [R15 + 0x240],RCX
MOVSS XMM0,dword ptr [RSP + 0x24]
MOVSS dword ptr [R15 + 0x24c],XMM0
LEA RDI,[R15 + 0x88]
CALL 0x0011b200
TEST AL,AL
JZ 0x00122e2b
MOV RDI,qword ptr [R12]
LAB_00122ce7:
MOV ESI,0x1
MOV RDX,R15
CALL 0x0011bd90
MOV RBX,RAX
TEST RAX,RAX
JZ 0x00122e6f
MOV qword ptr [R15 + 0x8],RBX
LEA RBP,[RSP + 0x10]
MOV qword ptr [RBP + -0x10],RBP
LAB_00122d0d:
LEA RSI,[0x1e8286]
LEA RDX,[0x1e8298]
MOV RDI,RSP
CALL 0x00122b0c
MOV RSI,qword ptr [RSP]
LAB_00122d27:
MOV RDI,RBX
CALL 0x0011be00
XORPS XMM0,XMM0
TEST EAX,EAX
JS 0x00122d46
AND EAX,0x7fffffff
MOV RDI,RBX
MOV RSI,RAX
CALL 0x0011bc60
LAB_00122d46:
MOVSS dword ptr [R15 + 0x248],XMM0
MOV RDI,qword ptr [RSP]
CMP RDI,RBP
JZ 0x00122d65
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x0011ba20
LAB_00122d65:
MOV RDX,qword ptr [R12]
LEA RDI,[0x1e8299]
LEA RSI,[0x1e82b2]
XOR EAX,EAX
CALL 0x0011b070
MOV RDI,qword ptr [R15]
LAB_00122d81:
CALL 0x0011b370
MOV R12,RAX
MOV R13,RSP
LEA RBX,[0x1e82b2]
LAB_00122d93:
TEST R12,R12
JZ 0x00122e1c
LEA R14,[R12 + 0x100]
MOV qword ptr [RSP],RBP
MOV RDI,R14
CALL 0x0011b460
LEA RDX,[R12 + RAX*0x1]
ADD RDX,0x100
LAB_00122dbb:
MOV RDI,R13
MOV RSI,R14
CALL 0x00122b0c
LAB_00122dc6:
MOV RDI,qword ptr [RSP + 0x28]
MOV RSI,R13
CALL 0x001234c4
MOV qword ptr [RAX],R12
CMP byte ptr [0x0022eeb1],0x1
JNZ 0x00122df3
LEA RDI,[0x1e82bd]
MOV RSI,RBX
MOV RDX,R14
XOR EAX,EAX
CALL 0x0011b070
LAB_00122df3:
MOV RDI,qword ptr [RSP]
CMP RDI,RBP
JZ 0x00122e09
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x0011ba20
LAB_00122e09:
MOV RDI,qword ptr [R15]
LAB_00122e0c:
MOV RSI,R12
CALL 0x0011ba10
MOV R12,RAX
LAB_00122e17:
JMP 0x00122d93
LAB_00122e1c:
ADD RSP,0x38
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00122e2b:
MOV EDI,0x10
CALL 0x0011b4f0
MOV R13,RAX
LAB_00122e38:
LEA RSI,[0x1e8266]
MOV RDI,RSP
MOV RDX,R12
CALL 0x0012343c
MOV BL,0x1
LAB_00122e4c:
MOV RSI,RSP
MOV RDI,R13
CALL 0x0011c030
XOR EBX,EBX
MOV RSI,qword ptr [0x0022dfe8]
MOV RDX,qword ptr [0x0022df58]
MOV RDI,R13
CALL 0x0011c150
LAB_00122e6f:
MOV EDI,0x10
CALL 0x0011b4f0
MOV R13,RAX
LAB_00122e7c:
LEA RSI,[0x1e82c5]
MOV RDI,RSP
MOV RDX,R12
CALL 0x0012343c
MOV BL,0x1
LAB_00122e90:
MOV RSI,RSP
MOV RDI,R13
CALL 0x0011c030
XOR EBX,EBX
MOV RSI,qword ptr [0x0022dfe8]
MOV RDX,qword ptr [0x0022df58]
MOV RDI,R13
CALL 0x0011c150
|
/* file_input::file_input(std::__cxx11::string&, float) */
void __thiscall file_input::file_input(file_input *this,string *param_1,float param_2)
{
char *__s;
char cVar1;
uint uVar2;
long lVar3;
size_t sVar4;
long *plVar5;
runtime_error *prVar6;
int4 uVar7;
long *local_68 [2];
long local_58 [2];
float local_44;
file_input *local_40;
ifstream *local_38;
local_38 = (ifstream *)(this + 0x10);
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
local_44 = param_2;
std::ifstream::ifstream(local_38,param_1,4);
local_40 = this + 0x218;
*(int4 *)(this + 0x220) = 0;
*(int8 *)(this + 0x228) = 0;
*(file_input **)(this + 0x230) = this + 0x220;
*(file_input **)(this + 0x238) = this + 0x220;
*(int8 *)(this + 0x240) = 0;
*(float *)(this + 0x24c) = local_44;
cVar1 = std::__basic_file<char>::is_open();
if (cVar1 == '\0') {
prVar6 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00122e38 to 00122e49 has its CatchHandler @ 00122edb */
std::operator+((char *)local_68,(string *)"failed to open input gguf from ");
/* try { // try from 00122e4c to 00122e6e has its CatchHandler @ 00122eb7 */
std::runtime_error::runtime_error(prVar6,(string *)local_68);
/* WARNING: Subroutine does not return */
__cxa_throw(prVar6,PTR_typeinfo_0022dfe8,PTR__runtime_error_0022df58);
}
/* try { // try from 00122ce7 to 00122cf3 has its CatchHandler @ 00122eec */
lVar3 = gguf_init_from_file(*(int8 *)param_1,1,this);
if (lVar3 != 0) {
*(long *)(this + 8) = lVar3;
local_68[0] = local_58;
/* try { // try from 00122d0d to 00122d22 has its CatchHandler @ 00122eea */
std::__cxx11::string::_M_construct<char_const*>(local_68,"adapter.lora.alpha","");
/* try { // try from 00122d27 to 00122d45 has its CatchHandler @ 00122eee */
uVar2 = gguf_find_key(lVar3,local_68[0]);
uVar7 = 0;
if (-1 < (int)uVar2) {
uVar7 = gguf_get_val_f32(lVar3,uVar2 & 0x7fffffff);
}
*(int4 *)(this + 0x248) = uVar7;
if (local_68[0] != local_58) {
operator_delete(local_68[0],local_58[0] + 1);
}
printf("%s: loaded gguf from %s\n","file_input",*(int8 *)param_1);
/* try { // try from 00122d81 to 00122d85 has its CatchHandler @ 00122ee8 */
for (lVar3 = ggml_get_first_tensor(*(int8 *)this); lVar3 != 0;
lVar3 = ggml_get_next_tensor(*(int8 *)this,lVar3)) {
__s = (char *)(lVar3 + 0x100);
local_68[0] = local_58;
sVar4 = strlen(__s);
/* try { // try from 00122dbb to 00122dc5 has its CatchHandler @ 00122ef0 */
std::__cxx11::string::_M_construct<char_const*>(local_68,__s,lVar3 + sVar4 + 0x100);
/* try { // try from 00122dc6 to 00122dd2 has its CatchHandler @ 00122ef2 */
plVar5 = (long *)std::
map<std::__cxx11::string,ggml_tensor*,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,ggml_tensor*>>>
::operator[]((map<std::__cxx11::string,ggml_tensor*,std::less<std::__cxx11::string>,std::allocator<std::pair<std::__cxx11::string_const,ggml_tensor*>>>
*)local_40,(string *)local_68);
*plVar5 = lVar3;
if (g_verbose == '\x01') {
printf("%s: %s\n","file_input",__s);
}
if (local_68[0] != local_58) {
operator_delete(local_68[0],local_58[0] + 1);
}
/* try { // try from 00122e0c to 00122e16 has its CatchHandler @ 00122f0d */
}
return;
}
prVar6 = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00122e7c to 00122e8d has its CatchHandler @ 00122eb5 */
std::operator+((char *)local_68,(string *)"failed to load input GGUF from ");
/* try { // try from 00122e90 to 00122eb2 has its CatchHandler @ 00122eb3 */
std::runtime_error::runtime_error(prVar6,(string *)local_68);
/* WARNING: Subroutine does not return */
__cxa_throw(prVar6,PTR_typeinfo_0022dfe8,PTR__runtime_error_0022df58);
}
| |
38,005 | my_strxfrm_pad_unicode | eloqsql/strings/ctype-utf8.c | size_t
my_strxfrm_pad_unicode(uchar *str, uchar *strend)
{
uchar *str0= str;
DBUG_ASSERT(str && str <= strend);
for ( ; str < strend ; )
{
*str++= 0x00;
if (str < strend)
*str++= 0x20;
}
return str - str0;
} | O3 | c | my_strxfrm_pad_unicode:
movq %rdi, %rax
cmpq %rsi, %rdi
jae 0x87164
pushq %rbp
movq %rsp, %rbp
movq %rdi, %rcx
leaq 0x1(%rcx), %rax
movb $0x0, (%rcx)
cmpq %rsi, %rax
jae 0x8715b
movb $0x20, 0x1(%rcx)
addq $0x2, %rcx
movq %rcx, %rax
movq %rax, %rcx
cmpq %rsi, %rax
jb 0x87144
popq %rbp
subq %rdi, %rax
retq
| my_strxfrm_pad_unicode:
mov rax, rdi
cmp rdi, rsi
jnb short loc_87164
push rbp
mov rbp, rsp
mov rcx, rdi
loc_87144:
lea rax, [rcx+1]
mov byte ptr [rcx], 0
cmp rax, rsi
jnb short loc_8715B
mov byte ptr [rcx+1], 20h ; ' '
add rcx, 2
mov rax, rcx
loc_8715B:
mov rcx, rax
cmp rax, rsi
jb short loc_87144
pop rbp
loc_87164:
sub rax, rdi
retn
| long long my_strxfrm_pad_unicode(_BYTE *a1, unsigned long long a2)
{
_BYTE *v2; // rax
_BYTE *v3; // rcx
v2 = a1;
if ( (unsigned long long)a1 < a2 )
{
v3 = a1;
do
{
v2 = v3 + 1;
*v3 = 0;
if ( (unsigned long long)(v3 + 1) < a2 )
{
v3[1] = 32;
v2 = v3 + 2;
}
v3 = v2;
}
while ( (unsigned long long)v2 < a2 );
}
return v2 - a1;
}
| my_strxfrm_pad_unicode:
MOV RAX,RDI
CMP RDI,RSI
JNC 0x00187164
PUSH RBP
MOV RBP,RSP
MOV RCX,RDI
LAB_00187144:
LEA RAX,[RCX + 0x1]
MOV byte ptr [RCX],0x0
CMP RAX,RSI
JNC 0x0018715b
MOV byte ptr [RCX + 0x1],0x20
ADD RCX,0x2
MOV RAX,RCX
LAB_0018715b:
MOV RCX,RAX
CMP RAX,RSI
JC 0x00187144
POP RBP
LAB_00187164:
SUB RAX,RDI
RET
|
long my_strxfrm_pad_unicode(int1 *param_1,int1 *param_2)
{
int1 *puVar1;
int1 *puVar2;
puVar2 = param_1;
puVar1 = param_1;
if (param_1 < param_2) {
do {
puVar2 = puVar1 + 1;
*puVar1 = 0;
if (puVar2 < param_2) {
puVar1[1] = 0x20;
puVar2 = puVar1 + 2;
}
puVar1 = puVar2;
} while (puVar2 < param_2);
}
return (long)puVar2 - (long)param_1;
}
| |
38,006 | minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const | monkey531[P]llama/common/minja.hpp | Value do_evaluate(const std::shared_ptr<Context> & context) const override {
if (!left) throw std::runtime_error("BinaryOpExpr.left is null");
if (!right) throw std::runtime_error("BinaryOpExpr.right is null");
auto l = left->evaluate(context);
auto do_eval = [&](const Value & l) -> Value {
if (op == Op::Is || op == Op::IsNot) {
auto t = dynamic_cast<VariableExpr*>(right.get());
if (!t) throw std::runtime_error("Right side of 'is' operator must be a variable");
auto eval = [&]() {
const auto & name = t->get_name();
if (name == "none") return l.is_null();
if (name == "boolean") return l.is_boolean();
if (name == "integer") return l.is_number_integer();
if (name == "float") return l.is_number_float();
if (name == "number") return l.is_number();
if (name == "string") return l.is_string();
if (name == "mapping") return l.is_object();
if (name == "iterable") return l.is_iterable();
if (name == "sequence") return l.is_array();
if (name == "defined") return !l.is_null();
throw std::runtime_error("Unknown type for 'is' operator: " + name);
};
auto value = eval();
return Value(op == Op::Is ? value : !value);
}
if (op == Op::And) {
if (!l.to_bool()) return Value(false);
return right->evaluate(context).to_bool();
} else if (op == Op::Or) {
if (l.to_bool()) return l;
return right->evaluate(context);
}
auto r = right->evaluate(context);
switch (op) {
case Op::StrConcat: return l.to_str() + r.to_str();
case Op::Add: return l + r;
case Op::Sub: return l - r;
case Op::Mul: return l * r;
case Op::Div: return l / r;
case Op::MulMul: return std::pow(l.get<double>(), r.get<double>());
case Op::DivDiv: return l.get<int64_t>() / r.get<int64_t>();
case Op::Mod: return l.get<int64_t>() % r.get<int64_t>();
case Op::Eq: return l == r;
case Op::Ne: return l != r;
case Op::Lt: return l < r;
case Op::Gt: return l > r;
case Op::Le: return l <= r;
case Op::Ge: return l >= r;
case Op::In: return (r.is_array() || r.is_object()) && r.contains(l);
case Op::NotIn: return !(r.is_array() && r.contains(l));
default: break;
}
throw std::runtime_error("Unknown binary operator");
};
if (l.is_callable()) {
return Value::callable([l, do_eval](const std::shared_ptr<Context> & context, ArgumentsValue & args) {
auto ll = l.call(context, args);
return do_eval(ll); //args[0].second);
});
} else {
return do_eval(l);
}
} | O1 | cpp | minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movq %rsi, %r15
movq 0x20(%rsi), %rsi
testq %rsi, %rsi
je 0x78c47
cmpq $0x0, 0x30(%r15)
je 0x78c65
movq %rdx, %r14
movq %rdi, %rbx
leaq 0x38(%rsp), %r12
movq %r12, %rdi
callq 0x6d5d0
movq %r15, 0x8(%rsp)
movq %r14, 0x10(%rsp)
cmpq $0x0, 0x30(%r12)
je 0x78b93
leaq 0x88(%rsp), %rdi
leaq 0x38(%rsp), %rsi
callq 0x3e204
movups 0x8(%rsp), %xmm0
leaq 0x88(%rsp), %rsi
movups %xmm0, 0x50(%rsi)
leaq 0x18(%rsp), %rdi
callq 0x78d9e
leaq 0x18(%rsp), %rsi
movq %rbx, %rdi
callq 0x3f9f8
movq 0x28(%rsp), %rax
testq %rax, %rax
je 0x78b23
leaq 0x18(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
leaq 0xc8(%rsp), %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x6d806
movq %r14, %rdi
callq 0x2968c
movq -0x8(%r14), %rdi
testq %rdi, %rdi
je 0x78b4b
callq 0x34304
movq 0xb0(%rsp), %rdi
testq %rdi, %rdi
je 0x78b5d
callq 0x34304
movq 0xa0(%rsp), %rdi
testq %rdi, %rdi
je 0x78b6f
callq 0x34304
movq 0x90(%rsp), %rdi
testq %rdi, %rdi
je 0x78bbc
movq 0x7240d(%rip), %rax # 0xeaf90
cmpb $0x0, (%rax)
je 0x78ba7
movl 0xc(%rdi), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0xc(%rdi)
jmp 0x78bb1
leaq 0x8(%rsp), %rsi
leaq 0x38(%rsp), %rdx
movq %rbx, %rdi
callq 0x78e88
jmp 0x78bbc
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
lock
xaddl %eax, 0xc(%rdi)
cmpl $0x1, %eax
jne 0x78bbc
movq (%rdi), %rax
callq *0x18(%rax)
leaq 0x78(%rsp), %r14
movq %r14, %rdi
xorl %esi, %esi
callq 0x6d806
movq %r14, %rdi
callq 0x2968c
movq -0x8(%r14), %rdi
testq %rdi, %rdi
je 0x78be1
callq 0x34304
movq 0x60(%rsp), %rdi
testq %rdi, %rdi
je 0x78bf0
callq 0x34304
movq 0x50(%rsp), %rdi
testq %rdi, %rdi
je 0x78bff
callq 0x34304
movq 0x40(%rsp), %rdi
testq %rdi, %rdi
je 0x78c35
movq 0x72380(%rip), %rax # 0xeaf90
cmpb $0x0, (%rax)
je 0x78c20
movl 0xc(%rdi), %eax
leal -0x1(%rax), %ecx
movl %ecx, 0xc(%rdi)
jmp 0x78c2a
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
lock
xaddl %eax, 0xc(%rdi)
cmpl $0x1, %eax
jne 0x78c35
movq (%rdi), %rax
callq *0x18(%rax)
movq %rbx, %rax
addq $0xe8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movl $0x10, %edi
callq 0x193b0
movq %rax, %r14
leaq 0x404d6(%rip), %rsi # 0xb9131
movq %rax, %rdi
callq 0x192c0
jmp 0x78c81
movl $0x10, %edi
callq 0x193b0
movq %rax, %r14
leaq 0x404d2(%rip), %rsi # 0xb914b
movq %rax, %rdi
callq 0x192c0
movq 0x72368(%rip), %rsi # 0xeaff0
movq 0x722d9(%rip), %rdx # 0xeaf68
movq %r14, %rdi
callq 0x19d90
jmp 0x78ce2
jmp 0x78cc8
jmp 0x78c9d
movq %rax, %rbx
movq %r14, %rdi
callq 0x19560
jmp 0x78cef
movq %rax, %rbx
movq 0x28(%rsp), %rax
testq %rax, %rax
je 0x78cd3
leaq 0x18(%rsp), %rdi
movq %rdi, %rsi
movl $0x3, %edx
callq *%rax
jmp 0x78cd3
movq %rax, %rdi
callq 0x2041f
movq %rax, %rbx
leaq 0x88(%rsp), %rdi
callq 0x78dfc
jmp 0x78ce5
movq %rax, %rbx
leaq 0x38(%rsp), %rdi
callq 0x32700
movq %rbx, %rdi
callq 0x19e00
nop
| _ZNK5minja12BinaryOpExpr11do_evaluateERKSt10shared_ptrINS_7ContextEE:
push r15
push r14
push r12
push rbx
sub rsp, 0E8h
mov r15, rsi
mov rsi, [rsi+20h]
test rsi, rsi
jz loc_78C47
cmp qword ptr [r15+30h], 0
jz loc_78C65
mov r14, rdx
mov rbx, rdi
lea r12, [rsp+108h+var_D0]
mov rdi, r12
call _ZNK5minja10Expression8evaluateERKSt10shared_ptrINS_7ContextEE; minja::Expression::evaluate(std::shared_ptr<minja::Context> const&)
mov qword ptr [rsp+108h+var_100], r15
mov qword ptr [rsp+108h+var_100+8], r14
cmp qword ptr [r12+30h], 0
jz loc_78B93
lea rdi, [rsp+108h+var_80]; this
lea rsi, [rsp+108h+var_D0]; minja::Value *
call _ZN5minja5ValueC2ERKS0_; minja::Value::Value(minja::Value const&)
movups xmm0, [rsp+108h+var_100]
lea rsi, [rsp+108h+var_80]
movups xmmword ptr [rsi+50h], xmm0
lea rdi, [rsp+108h+var_F0]
call _ZNSt8functionIFN5minja5ValueERKSt10shared_ptrINS0_7ContextEERNS0_14ArgumentsValueEEEC2IZNKS0_12BinaryOpExpr11do_evaluateES6_EUlS6_S8_E_vEEOT_; std::function<minja::Value ()(std::shared_ptr<minja::Context> const&,minja::ArgumentsValue &)>::function<minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&)::{lambda(std::shared_ptr<minja::Context> const&,minja::ArgumentsValue &)#1},void>(minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&)::{lambda(std::shared_ptr<minja::Context> const&,minja::ArgumentsValue &)#1} &&)
lea rsi, [rsp+108h+var_F0]
mov rdi, rbx
call _ZN5minja5Value8callableERKSt8functionIFS0_RKSt10shared_ptrINS_7ContextEERNS_14ArgumentsValueEEE; minja::Value::callable(std::function<minja::Value ()(std::shared_ptr<minja::Context> const&,minja::ArgumentsValue &)> const&)
mov rax, [rsp+108h+var_E0]
test rax, rax
jz short loc_78B23
lea rdi, [rsp+108h+var_F0]
mov rsi, rdi
mov edx, 3
call rax
loc_78B23:
lea r14, [rsp+108h+var_40]
mov rdi, r14
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
mov rdi, [r14-8]
test rdi, rdi
jz short loc_78B4B
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_78B4B:
mov rdi, [rsp+108h+var_58]
test rdi, rdi
jz short loc_78B5D
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_78B5D:
mov rdi, [rsp+108h+var_68]
test rdi, rdi
jz short loc_78B6F
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_78B6F:
mov rdi, [rsp+108h+var_78]
test rdi, rdi
jz short loc_78BBC
mov rax, cs:__libc_single_threaded_ptr
cmp byte ptr [rax], 0
jz short loc_78BA7
mov eax, [rdi+0Ch]
lea ecx, [rax-1]
mov [rdi+0Ch], ecx
jmp short loc_78BB1
loc_78B93:
lea rsi, [rsp+108h+var_100]
lea rdx, [rsp+108h+var_D0]
mov rdi, rbx; this
call _ZZNK5minja12BinaryOpExpr11do_evaluateERKSt10shared_ptrINS_7ContextEEENKUlRKNS_5ValueEE_clES8_; minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&)::{lambda(minja::Value const&)#1}::operator()(minja::Value const&)
jmp short loc_78BBC
loc_78BA7:
mov eax, 0FFFFFFFFh
lock xadd [rdi+0Ch], eax
loc_78BB1:
cmp eax, 1
jnz short loc_78BBC
mov rax, [rdi]
call qword ptr [rax+18h]
loc_78BBC:
lea r14, [rsp+108h+var_90]
mov rdi, r14
xor esi, esi
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE16assert_invariantEb; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::assert_invariant(bool)
mov rdi, r14
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
mov rdi, [r14-8]
test rdi, rdi
jz short loc_78BE1
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_78BE1:
mov rdi, [rsp+108h+var_A8]
test rdi, rdi
jz short loc_78BF0
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_78BF0:
mov rdi, [rsp+108h+var_B8]
test rdi, rdi
jz short loc_78BFF
call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void)
loc_78BFF:
mov rdi, [rsp+108h+var_C8]
test rdi, rdi
jz short loc_78C35
mov rax, cs:__libc_single_threaded_ptr
cmp byte ptr [rax], 0
jz short loc_78C20
mov eax, [rdi+0Ch]
lea ecx, [rax-1]
mov [rdi+0Ch], ecx
jmp short loc_78C2A
loc_78C20:
mov eax, 0FFFFFFFFh
lock xadd [rdi+0Ch], eax
loc_78C2A:
cmp eax, 1
jnz short loc_78C35
mov rax, [rdi]
call qword ptr [rax+18h]
loc_78C35:
mov rax, rbx
add rsp, 0E8h
pop rbx
pop r12
pop r14
pop r15
retn
loc_78C47:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r14, rax
lea rsi, aBinaryopexprLe; "BinaryOpExpr.left is null"
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
jmp short loc_78C81
loc_78C65:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov r14, rax
lea rsi, aBinaryopexprRi; "BinaryOpExpr.right is null"
mov rdi, rax; this
call __ZNSt13runtime_errorC1EPKc; std::runtime_error::runtime_error(char const*)
loc_78C81:
mov rsi, cs:lptinfo; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, r14; void *
call ___cxa_throw
jmp short loc_78CE2
jmp short loc_78CC8
jmp short $+2
loc_78C9D:
mov rbx, rax
mov rdi, r14; void *
call ___cxa_free_exception
jmp short loc_78CEF
mov rbx, rax
mov rax, [rsp+108h+var_E0]
test rax, rax
jz short loc_78CD3
lea rdi, [rsp+108h+var_F0]
mov rsi, rdi
mov edx, 3
call rax
jmp short loc_78CD3
loc_78CC8:
mov rdi, rax
call __clang_call_terminate
mov rbx, rax
loc_78CD3:
lea rdi, [rsp+108h+var_80]
call _ZZNK5minja12BinaryOpExpr11do_evaluateERKSt10shared_ptrINS_7ContextEEENUlS5_RNS_14ArgumentsValueEE_D2Ev; minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&)::{lambda(std::shared_ptr<minja::Context> const&,minja::ArgumentsValue &)#1}::~ArgumentsValue()
jmp short loc_78CE5
loc_78CE2:
mov rbx, rax
loc_78CE5:
lea rdi, [rsp+108h+var_D0]; this
call _ZN5minja5ValueD2Ev; minja::Value::~Value()
loc_78CEF:
mov rdi, rbx
call __Unwind_Resume
| minja::Value * minja::BinaryOpExpr::do_evaluate(minja::Value *this, long long a2, long long a3)
{
void (***v4)(void); // rsi
long long v7; // rdi
signed __int32 v8; // eax
long long v9; // rdi
signed __int32 v10; // eax
std::runtime_error *exception; // r14
__int128 v13; // [rsp+8h] [rbp-100h]
_BYTE v14[16]; // [rsp+18h] [rbp-F0h] BYREF
void ( *v15)(_BYTE *, _BYTE *, long long); // [rsp+28h] [rbp-E0h]
_BYTE v16[8]; // [rsp+38h] [rbp-D0h] BYREF
long long v17; // [rsp+40h] [rbp-C8h]
volatile signed __int32 *v18; // [rsp+50h] [rbp-B8h]
volatile signed __int32 *v19; // [rsp+60h] [rbp-A8h]
long long v20; // [rsp+68h] [rbp-A0h]
volatile signed __int32 *v21; // [rsp+70h] [rbp-98h]
char v22[16]; // [rsp+78h] [rbp-90h] BYREF
_BYTE v23[8]; // [rsp+88h] [rbp-80h] BYREF
long long v24; // [rsp+90h] [rbp-78h]
volatile signed __int32 *v25; // [rsp+A0h] [rbp-68h]
volatile signed __int32 *v26; // [rsp+B0h] [rbp-58h]
volatile signed __int32 *v27; // [rsp+C0h] [rbp-48h]
char v28[16]; // [rsp+C8h] [rbp-40h] BYREF
__int128 v29; // [rsp+D8h] [rbp-30h]
v4 = *(void (****)(void))(a2 + 32);
if ( !v4 )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "BinaryOpExpr.left is null");
goto LABEL_34;
}
if ( !*(_QWORD *)(a2 + 48) )
{
exception = (std::runtime_error *)__cxa_allocate_exception(0x10uLL);
std::runtime_error::runtime_error(exception, "BinaryOpExpr.right is null");
LABEL_34:
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
minja::Expression::evaluate((long long)v16, v4);
*(_QWORD *)&v13 = a2;
*((_QWORD *)&v13 + 1) = a3;
if ( v20 )
{
minja::Value::Value((minja::Value *)v23, (const minja::Value *)v16);
v29 = v13;
std::function<minja::Value ()(std::shared_ptr<minja::Context> const&,minja::ArgumentsValue &)>::function<minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&)::{lambda(std::shared_ptr<minja::Context> const&,minja::ArgumentsValue &)#1},void>(v14);
minja::Value::callable((long long)this, (long long)v14);
if ( v15 )
v15(v14, v14, 3LL);
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(v28);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(v28);
if ( v27 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v27);
if ( v26 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v26);
if ( v25 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v25);
v7 = v24;
if ( v24 )
{
if ( _libc_single_threaded )
{
v8 = *(_DWORD *)(v24 + 12);
*(_DWORD *)(v24 + 12) = v8 - 1;
}
else
{
v8 = _InterlockedExchangeAdd((volatile signed __int32 *)(v24 + 12), 0xFFFFFFFF);
}
if ( v8 == 1 )
(*(void ( **)(long long, _QWORD))(*(_QWORD *)v7 + 24LL))(v7, 0LL);
}
}
else
{
minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&)const::{lambda(minja::Value const&)#1}::operator()(this);
}
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(v22);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(v22);
if ( v21 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v21);
if ( v19 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v19);
if ( v18 )
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v18);
v9 = v17;
if ( v17 )
{
if ( _libc_single_threaded )
{
v10 = *(_DWORD *)(v17 + 12);
*(_DWORD *)(v17 + 12) = v10 - 1;
}
else
{
v10 = _InterlockedExchangeAdd((volatile signed __int32 *)(v17 + 12), 0xFFFFFFFF);
}
if ( v10 == 1 )
(*(void ( **)(long long, _QWORD))(*(_QWORD *)v9 + 24LL))(v9, 0LL);
}
return this;
}
| do_evaluate:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0xe8
MOV R15,RSI
MOV RSI,qword ptr [RSI + 0x20]
TEST RSI,RSI
JZ 0x00178c47
CMP qword ptr [R15 + 0x30],0x0
JZ 0x00178c65
MOV R14,RDX
MOV RBX,RDI
LEA R12,[RSP + 0x38]
MOV RDI,R12
CALL 0x0016d5d0
MOV qword ptr [RSP + 0x8],R15
MOV qword ptr [RSP + 0x10],R14
CMP qword ptr [R12 + 0x30],0x0
JZ 0x00178b93
LAB_00178ad0:
LEA RDI,[RSP + 0x88]
LEA RSI,[RSP + 0x38]
CALL 0x0013e204
MOVUPS XMM0,xmmword ptr [RSP + 0x8]
LEA RSI,[RSP + 0x88]
MOVUPS xmmword ptr [RSI + 0x50],XMM0
LAB_00178af3:
LEA RDI,[RSP + 0x18]
CALL 0x00178d9e
LAB_00178afd:
LEA RSI,[RSP + 0x18]
MOV RDI,RBX
CALL 0x0013f9f8
MOV RAX,qword ptr [RSP + 0x28]
TEST RAX,RAX
JZ 0x00178b23
LAB_00178b14:
LEA RDI,[RSP + 0x18]
MOV RSI,RDI
MOV EDX,0x3
CALL RAX
LAB_00178b23:
LEA R14,[RSP + 0xc8]
MOV RDI,R14
XOR ESI,ESI
CALL 0x0016d806
MOV RDI,R14
CALL 0x0012968c
MOV RDI,qword ptr [R14 + -0x8]
TEST RDI,RDI
JZ 0x00178b4b
CALL 0x00134304
LAB_00178b4b:
MOV RDI,qword ptr [RSP + 0xb0]
TEST RDI,RDI
JZ 0x00178b5d
CALL 0x00134304
LAB_00178b5d:
MOV RDI,qword ptr [RSP + 0xa0]
TEST RDI,RDI
JZ 0x00178b6f
CALL 0x00134304
LAB_00178b6f:
MOV RDI,qword ptr [RSP + 0x90]
TEST RDI,RDI
JZ 0x00178bbc
MOV RAX,qword ptr [0x001eaf90]
CMP byte ptr [RAX],0x0
JZ 0x00178ba7
MOV EAX,dword ptr [RDI + 0xc]
LEA ECX,[RAX + -0x1]
MOV dword ptr [RDI + 0xc],ECX
JMP 0x00178bb1
LAB_00178b93:
LEA RSI,[RSP + 0x8]
LEA RDX,[RSP + 0x38]
MOV RDI,RBX
CALL 0x00178e88
LAB_00178ba5:
JMP 0x00178bbc
LAB_00178ba7:
MOV EAX,0xffffffff
XADD.LOCK dword ptr [RDI + 0xc],EAX
LAB_00178bb1:
CMP EAX,0x1
JNZ 0x00178bbc
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x18]
LAB_00178bbc:
LEA R14,[RSP + 0x78]
MOV RDI,R14
XOR ESI,ESI
CALL 0x0016d806
MOV RDI,R14
CALL 0x0012968c
MOV RDI,qword ptr [R14 + -0x8]
TEST RDI,RDI
JZ 0x00178be1
CALL 0x00134304
LAB_00178be1:
MOV RDI,qword ptr [RSP + 0x60]
TEST RDI,RDI
JZ 0x00178bf0
CALL 0x00134304
LAB_00178bf0:
MOV RDI,qword ptr [RSP + 0x50]
TEST RDI,RDI
JZ 0x00178bff
CALL 0x00134304
LAB_00178bff:
MOV RDI,qword ptr [RSP + 0x40]
TEST RDI,RDI
JZ 0x00178c35
MOV RAX,qword ptr [0x001eaf90]
CMP byte ptr [RAX],0x0
JZ 0x00178c20
MOV EAX,dword ptr [RDI + 0xc]
LEA ECX,[RAX + -0x1]
MOV dword ptr [RDI + 0xc],ECX
JMP 0x00178c2a
LAB_00178c20:
MOV EAX,0xffffffff
XADD.LOCK dword ptr [RDI + 0xc],EAX
LAB_00178c2a:
CMP EAX,0x1
JNZ 0x00178c35
MOV RAX,qword ptr [RDI]
CALL qword ptr [RAX + 0x18]
LAB_00178c35:
MOV RAX,RBX
ADD RSP,0xe8
POP RBX
POP R12
POP R14
POP R15
RET
LAB_00178c47:
MOV EDI,0x10
CALL 0x001193b0
MOV R14,RAX
LAB_00178c54:
LEA RSI,[0x1b9131]
MOV RDI,RAX
CALL 0x001192c0
LAB_00178c63:
JMP 0x00178c81
LAB_00178c65:
MOV EDI,0x10
CALL 0x001193b0
MOV R14,RAX
LAB_00178c72:
LEA RSI,[0x1b914b]
MOV RDI,RAX
CALL 0x001192c0
LAB_00178c81:
MOV RSI,qword ptr [0x001eaff0]
MOV RDX,qword ptr [0x001eaf68]
MOV RDI,R14
CALL 0x00119d90
|
/* minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const */
shared_ptr * minja::BinaryOpExpr::do_evaluate(shared_ptr *param_1)
{
int *piVar1;
int iVar2;
runtime_error *this;
int8 in_RDX;
long in_RSI;
long local_100;
int8 uStack_f8;
_lambda_std__shared_ptr<minja::Context>_const__minja__ArgumentsValue___1_ local_f0 [16];
code *local_e0;
Expression local_d0 [8];
long *local_c8;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_b8;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_a8;
long local_a0;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_98;
data local_90 [16];
Value local_80 [8];
long *local_78;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_68;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_58;
_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *local_48;
data local_40 [16];
long local_30;
int8 uStack_28;
if (*(shared_ptr **)(in_RSI + 0x20) == (shared_ptr *)0x0) {
this = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00178c54 to 00178c62 has its CatchHandler @ 00178c9d */
std::runtime_error::runtime_error(this,"BinaryOpExpr.left is null");
}
else {
if (*(long *)(in_RSI + 0x30) != 0) {
Expression::evaluate(local_d0,*(shared_ptr **)(in_RSI + 0x20));
if (local_a0 == 0) {
/* try { // try from 00178b93 to 00178ba4 has its CatchHandler @ 00178c97 */
const::{lambda(minja::Value_const&)#1}::operator()
((_lambda_minja__Value_const___1_ *)param_1,(Value *)&local_100);
}
else {
/* try { // try from 00178ad0 to 00178ae1 has its CatchHandler @ 00178ce2 */
local_100 = in_RSI;
uStack_f8 = in_RDX;
minja::Value::Value(local_80,(Value *)local_d0);
local_30 = local_100;
uStack_28 = uStack_f8;
/* try { // try from 00178af3 to 00178afc has its CatchHandler @ 00178cd0 */
std::function<minja::Value(std::shared_ptr<minja::Context>const&,minja::ArgumentsValue&)>::
function<minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context>const&)const::_lambda(std::shared_ptr<minja::Context>const&,minja::ArgumentsValue&)_1_,void>
(local_f0);
/* try { // try from 00178afd to 00178b09 has its CatchHandler @ 00178caa */
minja::Value::callable((Value *)param_1,local_f0);
if (local_e0 != (code *)0x0) {
/* try { // try from 00178b14 to 00178b22 has its CatchHandler @ 00178c99 */
(*local_e0)(local_f0,local_f0,3);
}
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(local_40,0));
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data(local_40);
if (local_48 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_48);
}
if (local_58 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_58);
}
if (local_68 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_68);
}
if (local_78 != (long *)0x0) {
if (*PTR___libc_single_threaded_001eaf90 == '\0') {
LOCK();
piVar1 = (int *)((long)local_78 + 0xc);
iVar2 = *piVar1;
*piVar1 = *piVar1 + -1;
UNLOCK();
}
else {
iVar2 = *(int *)((long)local_78 + 0xc);
*(int *)((long)local_78 + 0xc) = iVar2 + -1;
}
if (iVar2 == 1) {
(**(code **)(*local_78 + 0x18))();
}
}
}
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant(SUB81(local_90,0));
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::data::~data(local_90);
if (local_98 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_98);
}
if (local_a8 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_a8);
}
if (local_b8 != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) {
std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(local_b8);
}
if (local_c8 != (long *)0x0) {
if (*PTR___libc_single_threaded_001eaf90 == '\0') {
LOCK();
piVar1 = (int *)((long)local_c8 + 0xc);
iVar2 = *piVar1;
*piVar1 = *piVar1 + -1;
UNLOCK();
}
else {
iVar2 = *(int *)((long)local_c8 + 0xc);
*(int *)((long)local_c8 + 0xc) = iVar2 + -1;
}
if (iVar2 == 1) {
(**(code **)(*local_c8 + 0x18))();
}
}
return param_1;
}
this = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00178c72 to 00178c80 has its CatchHandler @ 00178c9b */
std::runtime_error::runtime_error(this,"BinaryOpExpr.right is null");
}
/* WARNING: Subroutine does not return */
__cxa_throw(this,PTR_typeinfo_001eaff0,PTR__runtime_error_001eaf68);
}
| |
38,007 | testing::internal::TestEventRepeater::Release(testing::TestEventListener*) | seiftnesse[P]memoryallocator/build_O0/_deps/googletest-src/googletest/src/gtest.cc | TestEventListener* TestEventRepeater::Release(TestEventListener* listener) {
for (size_t i = 0; i < listeners_.size(); ++i) {
if (listeners_[i] == listener) {
listeners_.erase(listeners_.begin() + static_cast<int>(i));
return listener;
}
}
return nullptr;
} | O0 | cpp | testing::internal::TestEventRepeater::Release(testing::TestEventListener*):
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x48(%rbp)
movq $0x0, -0x20(%rbp)
movq -0x48(%rbp), %rdi
movq -0x20(%rbp), %rax
movq %rax, -0x50(%rbp)
addq $0x10, %rdi
callq 0x51370
movq %rax, %rcx
movq -0x50(%rbp), %rax
cmpq %rcx, %rax
jae 0x36dba
movq -0x48(%rbp), %rdi
addq $0x10, %rdi
movq -0x20(%rbp), %rsi
callq 0x51390
movq (%rax), %rax
cmpq -0x18(%rbp), %rax
jne 0x36da7
movq -0x48(%rbp), %rdi
movq %rdi, %rax
addq $0x10, %rax
movq %rax, -0x58(%rbp)
addq $0x10, %rdi
callq 0x51420
movq %rax, -0x38(%rbp)
movq -0x20(%rbp), %rax
movslq %eax, %rsi
leaq -0x38(%rbp), %rdi
callq 0x51450
movq %rax, -0x30(%rbp)
leaq -0x28(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x51490
movq -0x58(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0x513b0
movq %rax, -0x40(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x36dc2
jmp 0x36da9
movq -0x20(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x20(%rbp)
jmp 0x36d10
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)
| _ZN7testing8internal17TestEventRepeater7ReleaseEPNS_17TestEventListenerE:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov rax, [rbp+var_10]
mov [rbp+var_48], rax
mov [rbp+var_20], 0
loc_36D10:
mov rdi, [rbp+var_48]
mov rax, [rbp+var_20]
mov [rbp+var_50], rax
add rdi, 10h
call _ZNKSt6vectorIPN7testing17TestEventListenerESaIS2_EE4sizeEv; std::vector<testing::TestEventListener *>::size(void)
mov rcx, rax
mov rax, [rbp+var_50]
cmp rax, rcx
jnb loc_36DBA
mov rdi, [rbp+var_48]
add rdi, 10h
mov rsi, [rbp+var_20]
call _ZNSt6vectorIPN7testing17TestEventListenerESaIS2_EEixEm; std::vector<testing::TestEventListener *>::operator[](ulong)
mov rax, [rax]
cmp rax, [rbp+var_18]
jnz short loc_36DA7
mov rdi, [rbp+var_48]
mov rax, rdi
add rax, 10h
mov [rbp+var_58], rax
add rdi, 10h
call _ZNSt6vectorIPN7testing17TestEventListenerESaIS2_EE5beginEv; std::vector<testing::TestEventListener *>::begin(void)
mov [rbp+var_38], rax
mov rax, [rbp+var_20]
movsxd rsi, eax
lea rdi, [rbp+var_38]
call _ZNK9__gnu_cxx17__normal_iteratorIPPN7testing17TestEventListenerESt6vectorIS3_SaIS3_EEEplEl; __gnu_cxx::__normal_iterator<testing::TestEventListener **,std::vector<testing::TestEventListener *>>::operator+(long)
mov [rbp+var_30], rax
lea rdi, [rbp+var_28]
lea rsi, [rbp+var_30]
call _ZN9__gnu_cxx17__normal_iteratorIPKPN7testing17TestEventListenerESt6vectorIS3_SaIS3_EEEC2IPS3_EERKNS0_IT_NS_11__enable_ifIXsr3std10__are_sameISC_SB_EE7__valueES8_E6__typeEEE
mov rdi, [rbp+var_58]
mov rsi, [rbp+var_28]
call _ZNSt6vectorIPN7testing17TestEventListenerESaIS2_EE5eraseEN9__gnu_cxx17__normal_iteratorIPKS2_S4_EE; std::vector<testing::TestEventListener *>::erase(__gnu_cxx::__normal_iterator<testing::TestEventListener * const*,std::vector<testing::TestEventListener *>>)
mov [rbp+var_40], rax
mov rax, [rbp+var_18]
mov [rbp+var_8], rax
jmp short loc_36DC2
loc_36DA7:
jmp short $+2
loc_36DA9:
mov rax, [rbp+var_20]
add rax, 1
mov [rbp+var_20], rax
jmp loc_36D10
loc_36DBA:
mov [rbp+var_8], 0
loc_36DC2:
mov rax, [rbp+var_8]
add rsp, 60h
pop rbp
retn
| testing::TestEventListener * testing::internal::TestEventRepeater::Release(
testing::internal::TestEventRepeater *this,
testing::TestEventListener *a2)
{
long long v3; // [rsp+28h] [rbp-38h] BYREF
long long v4; // [rsp+30h] [rbp-30h] BYREF
long long v5; // [rsp+38h] [rbp-28h] BYREF
unsigned long long i; // [rsp+40h] [rbp-20h]
testing::TestEventListener *v7; // [rsp+48h] [rbp-18h]
testing::internal::TestEventRepeater *v8; // [rsp+50h] [rbp-10h]
v8 = this;
v7 = a2;
for ( i = 0LL; i < std::vector<testing::TestEventListener *>::size((char *)this + 16); ++i )
{
if ( *(testing::TestEventListener **)std::vector<testing::TestEventListener *>::operator[]((char *)this + 16, i) == v7 )
{
v3 = std::vector<testing::TestEventListener *>::begin((char *)this + 16);
v4 = __gnu_cxx::__normal_iterator<testing::TestEventListener **,std::vector<testing::TestEventListener *>>::operator+(
&v3,
(int)i);
__gnu_cxx::__normal_iterator<testing::TestEventListener * const*,std::vector<testing::TestEventListener *>>::__normal_iterator<testing::TestEventListener **>(
&v5,
&v4);
std::vector<testing::TestEventListener *>::erase((char *)this + 16, v5);
return v7;
}
}
return 0LL;
}
| Release:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x48],RAX
MOV qword ptr [RBP + -0x20],0x0
LAB_00136d10:
MOV RDI,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x50],RAX
ADD RDI,0x10
CALL 0x00151370
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x50]
CMP RAX,RCX
JNC 0x00136dba
MOV RDI,qword ptr [RBP + -0x48]
ADD RDI,0x10
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x00151390
MOV RAX,qword ptr [RAX]
CMP RAX,qword ptr [RBP + -0x18]
JNZ 0x00136da7
MOV RDI,qword ptr [RBP + -0x48]
MOV RAX,RDI
ADD RAX,0x10
MOV qword ptr [RBP + -0x58],RAX
ADD RDI,0x10
CALL 0x00151420
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOVSXD RSI,EAX
LEA RDI,[RBP + -0x38]
CALL 0x00151450
MOV qword ptr [RBP + -0x30],RAX
LEA RDI,[RBP + -0x28]
LEA RSI,[RBP + -0x30]
CALL 0x00151490
MOV RDI,qword ptr [RBP + -0x58]
MOV RSI,qword ptr [RBP + -0x28]
CALL 0x001513b0
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x8],RAX
JMP 0x00136dc2
LAB_00136da7:
JMP 0x00136da9
LAB_00136da9:
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x1
MOV qword ptr [RBP + -0x20],RAX
JMP 0x00136d10
LAB_00136dba:
MOV qword ptr [RBP + -0x8],0x0
LAB_00136dc2:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x60
POP RBP
RET
|
/* testing::internal::TestEventRepeater::Release(testing::TestEventListener*) */
TestEventListener * __thiscall
testing::internal::TestEventRepeater::Release(TestEventRepeater *this,TestEventListener *param_1)
{
ulong uVar1;
ulong uVar2;
long *plVar3;
int8 local_40;
int8 local_38;
int8 local_30;
ulong local_28;
TestEventListener *local_20;
TestEventRepeater *local_18;
local_28 = 0;
local_20 = param_1;
local_18 = this;
while( true ) {
uVar1 = local_28;
uVar2 = std::vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>>::
size((vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>> *)
(this + 0x10));
if (uVar2 <= uVar1) {
return (TestEventListener *)0x0;
}
plVar3 = (long *)std::
vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>>
::operator[]((vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>>
*)(this + 0x10),local_28);
if ((TestEventListener *)*plVar3 == local_20) break;
local_28 = local_28 + 1;
}
local_40 = std::vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>>::
begin((vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>>
*)(this + 0x10));
local_38 = __gnu_cxx::
__normal_iterator<testing::TestEventListener**,std::vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>>>
::operator+((__normal_iterator<testing::TestEventListener**,std::vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>>>
*)&local_40,(long)(int)local_28);
__gnu_cxx::
__normal_iterator<testing::TestEventListener*const*,std::vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>>>
::__normal_iterator<testing::TestEventListener**>
((__normal_iterator<testing::TestEventListener*const*,std::vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>>>
*)&local_30,(__normal_iterator *)&local_38);
std::vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>>::erase
((vector<testing::TestEventListener*,std::allocator<testing::TestEventListener*>> *)
(this + 0x10),local_30);
return local_20;
}
| |
38,008 | js_os_mkdir | bluesky950520[P]quickjs/quickjs-libc.c | static JSValue js_os_mkdir(JSContext *ctx, JSValue this_val,
int argc, JSValue *argv)
{
int mode, ret;
const char *path;
if (argc >= 2) {
if (JS_ToInt32(ctx, &mode, argv[1]))
return JS_EXCEPTION;
} else {
mode = 0777;
}
path = JS_ToCString(ctx, argv[0]);
if (!path)
return JS_EXCEPTION;
#if defined(_WIN32)
(void)mode;
ret = js_get_errno(mkdir(path));
#else
ret = js_get_errno(mkdir(path, mode));
#endif
JS_FreeCString(ctx, path);
return JS_NewInt32(ctx, ret);
} | O0 | c | js_os_mkdir:
subq $0x68, %rsp
movq %rsi, 0x28(%rsp)
movq %rdx, 0x30(%rsp)
movq %rdi, 0x20(%rsp)
movl %ecx, 0x1c(%rsp)
movq %r8, 0x10(%rsp)
cmpl $0x2, 0x1c(%rsp)
jl 0x199bc
movq 0x20(%rsp), %rdi
movq 0x10(%rsp), %rax
movq 0x10(%rax), %rdx
movq 0x18(%rax), %rcx
leaq 0xc(%rsp), %rsi
callq 0x38f20
cmpl $0x0, %eax
je 0x199ba
movl $0x0, 0x38(%rsp)
movq $0x6, 0x40(%rsp)
jmp 0x19a56
jmp 0x199c4
movl $0x1ff, 0xc(%rsp) # imm = 0x1FF
movq 0x20(%rsp), %rdi
movq 0x10(%rsp), %rax
movq (%rax), %rsi
movq 0x8(%rax), %rdx
callq 0x147e0
movq %rax, (%rsp)
cmpq $0x0, (%rsp)
jne 0x199f8
movl $0x0, 0x38(%rsp)
movq $0x6, 0x40(%rsp)
jmp 0x19a56
movq (%rsp), %rdi
movl 0xc(%rsp), %esi
callq 0xe130
movslq %eax, %rdi
callq 0x13a50
movl %eax, 0x8(%rsp)
movq 0x20(%rsp), %rdi
movq (%rsp), %rsi
callq 0x29e50
movq 0x20(%rsp), %rcx
movl 0x8(%rsp), %eax
movq %rcx, 0x50(%rsp)
movl %eax, 0x4c(%rsp)
movl 0x4c(%rsp), %eax
movl %eax, 0x58(%rsp)
movq $0x0, 0x60(%rsp)
movq 0x58(%rsp), %rcx
movq 0x60(%rsp), %rax
movq %rcx, 0x38(%rsp)
movq %rax, 0x40(%rsp)
movq 0x38(%rsp), %rax
movq 0x40(%rsp), %rdx
addq $0x68, %rsp
retq
nopw %cs:(%rax,%rax)
| js_os_mkdir:
sub rsp, 68h
mov [rsp+68h+var_40], rsi
mov [rsp+68h+var_38], rdx
mov [rsp+68h+var_48], rdi
mov [rsp+68h+var_4C], ecx
mov [rsp+68h+var_58], r8
cmp [rsp+68h+var_4C], 2
jl short loc_199BC
mov rdi, [rsp+68h+var_48]
mov rax, [rsp+68h+var_58]
mov rdx, [rax+10h]
mov rcx, [rax+18h]
lea rsi, [rsp+68h+var_5C]
call JS_ToInt32
cmp eax, 0
jz short loc_199BA
mov dword ptr [rsp+68h+var_30], 0
mov [rsp+68h+var_28], 6
jmp loc_19A56
loc_199BA:
jmp short loc_199C4
loc_199BC:
mov [rsp+68h+var_5C], 1FFh
loc_199C4:
mov rdi, [rsp+68h+var_48]
mov rax, [rsp+68h+var_58]
mov rsi, [rax]
mov rdx, [rax+8]
call JS_ToCString
mov [rsp+68h+var_68], rax
cmp [rsp+68h+var_68], 0
jnz short loc_199F8
mov dword ptr [rsp+68h+var_30], 0
mov [rsp+68h+var_28], 6
jmp short loc_19A56
loc_199F8:
mov rdi, [rsp+68h+var_68]
mov esi, [rsp+68h+var_5C]
call _mkdir
movsxd rdi, eax
call js_get_errno
mov [rsp+68h+var_60], eax
mov rdi, [rsp+68h+var_48]
mov rsi, [rsp+68h+var_68]
call JS_FreeCString
mov rcx, [rsp+68h+var_48]
mov eax, [rsp+68h+var_60]
mov [rsp+68h+var_18], rcx
mov [rsp+68h+var_1C], eax
mov eax, [rsp+68h+var_1C]
mov dword ptr [rsp+68h+var_10], eax
mov [rsp+68h+var_8], 0
mov rcx, [rsp+68h+var_10]
mov rax, [rsp+68h+var_8]
mov [rsp+68h+var_30], rcx
mov [rsp+68h+var_28], rax
loc_19A56:
mov rax, [rsp+68h+var_30]
mov rdx, [rsp+68h+var_28]
add rsp, 68h
retn
| long long js_os_mkdir(long long a1, long long a2, long long a3, int a4, long long *a5)
{
int v5; // eax
long long v7; // [rsp+0h] [rbp-68h]
int errno; // [rsp+8h] [rbp-60h]
unsigned int v9; // [rsp+Ch] [rbp-5Ch] BYREF
long long *v10; // [rsp+10h] [rbp-58h]
int v11; // [rsp+1Ch] [rbp-4Ch]
long long v12; // [rsp+20h] [rbp-48h]
long long v13; // [rsp+28h] [rbp-40h]
long long v14; // [rsp+30h] [rbp-38h]
long long v15; // [rsp+38h] [rbp-30h]
long long v16; // [rsp+40h] [rbp-28h]
int v17; // [rsp+4Ch] [rbp-1Ch]
long long v18; // [rsp+50h] [rbp-18h]
long long v19; // [rsp+58h] [rbp-10h]
long long v20; // [rsp+60h] [rbp-8h]
v13 = a2;
v14 = a3;
v12 = a1;
v11 = a4;
v10 = a5;
if ( a4 < 2 )
{
v9 = 511;
}
else if ( (unsigned int)JS_ToInt32(v12, &v9, v10[2], v10[3]) )
{
LODWORD(v15) = 0;
v16 = 6LL;
return v15;
}
v7 = JS_ToCString(v12, *v10, v10[1]);
if ( v7 )
{
v5 = mkdir(v7, v9);
errno = js_get_errno(v5);
JS_FreeCString(v12, v7);
v18 = v12;
v17 = errno;
LODWORD(v19) = errno;
v20 = 0LL;
v15 = v19;
v16 = 0LL;
}
else
{
LODWORD(v15) = 0;
v16 = 6LL;
}
return v15;
}
| js_os_mkdir:
SUB RSP,0x68
MOV qword ptr [RSP + 0x28],RSI
MOV qword ptr [RSP + 0x30],RDX
MOV qword ptr [RSP + 0x20],RDI
MOV dword ptr [RSP + 0x1c],ECX
MOV qword ptr [RSP + 0x10],R8
CMP dword ptr [RSP + 0x1c],0x2
JL 0x001199bc
MOV RDI,qword ptr [RSP + 0x20]
MOV RAX,qword ptr [RSP + 0x10]
MOV RDX,qword ptr [RAX + 0x10]
MOV RCX,qword ptr [RAX + 0x18]
LEA RSI,[RSP + 0xc]
CALL 0x00138f20
CMP EAX,0x0
JZ 0x001199ba
MOV dword ptr [RSP + 0x38],0x0
MOV qword ptr [RSP + 0x40],0x6
JMP 0x00119a56
LAB_001199ba:
JMP 0x001199c4
LAB_001199bc:
MOV dword ptr [RSP + 0xc],0x1ff
LAB_001199c4:
MOV RDI,qword ptr [RSP + 0x20]
MOV RAX,qword ptr [RSP + 0x10]
MOV RSI,qword ptr [RAX]
MOV RDX,qword ptr [RAX + 0x8]
CALL 0x001147e0
MOV qword ptr [RSP],RAX
CMP qword ptr [RSP],0x0
JNZ 0x001199f8
MOV dword ptr [RSP + 0x38],0x0
MOV qword ptr [RSP + 0x40],0x6
JMP 0x00119a56
LAB_001199f8:
MOV RDI,qword ptr [RSP]
MOV ESI,dword ptr [RSP + 0xc]
CALL 0x0010e130
MOVSXD RDI,EAX
CALL 0x00113a50
MOV dword ptr [RSP + 0x8],EAX
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP]
CALL 0x00129e50
MOV RCX,qword ptr [RSP + 0x20]
MOV EAX,dword ptr [RSP + 0x8]
MOV qword ptr [RSP + 0x50],RCX
MOV dword ptr [RSP + 0x4c],EAX
MOV EAX,dword ptr [RSP + 0x4c]
MOV dword ptr [RSP + 0x58],EAX
MOV qword ptr [RSP + 0x60],0x0
MOV RCX,qword ptr [RSP + 0x58]
MOV RAX,qword ptr [RSP + 0x60]
MOV qword ptr [RSP + 0x38],RCX
MOV qword ptr [RSP + 0x40],RAX
LAB_00119a56:
MOV RAX,qword ptr [RSP + 0x38]
MOV RDX,qword ptr [RSP + 0x40]
ADD RSP,0x68
RET
|
int1 [16]
js_os_mkdir(int8 param_1,int8 param_2,int8 param_3,int param_4,int8 *param_5
)
{
int1 auVar1 [16];
int iVar2;
int4 uVar3;
char *__path;
__mode_t local_5c;
int8 *local_58;
int local_4c;
int8 local_48;
int8 local_40;
int8 local_38;
int4 local_30;
int4 uStack_2c;
int8 local_28;
int4 uStack_c;
local_58 = param_5;
local_4c = param_4;
local_48 = param_1;
local_40 = param_2;
local_38 = param_3;
if (param_4 < 2) {
local_5c = 0x1ff;
}
else {
iVar2 = JS_ToInt32(param_1,&local_5c,param_5[2],param_5[3]);
if (iVar2 != 0) {
local_30 = 0;
local_28 = 6;
goto LAB_00119a56;
}
}
__path = (char *)JS_ToCString(local_48,*local_58,local_58[1]);
if (__path == (char *)0x0) {
local_30 = 0;
local_28 = 6;
}
else {
iVar2 = mkdir(__path,local_5c);
uVar3 = js_get_errno((long)iVar2);
JS_FreeCString(local_48,__path);
uStack_2c = uStack_c;
local_28 = 0;
local_30 = uVar3;
}
LAB_00119a56:
auVar1._4_4_ = uStack_2c;
auVar1._0_4_ = local_30;
auVar1._8_8_ = local_28;
return auVar1;
}
| |
38,009 | js_os_mkdir | bluesky950520[P]quickjs/quickjs-libc.c | static JSValue js_os_mkdir(JSContext *ctx, JSValue this_val,
int argc, JSValue *argv)
{
int mode, ret;
const char *path;
if (argc >= 2) {
if (JS_ToInt32(ctx, &mode, argv[1]))
return JS_EXCEPTION;
} else {
mode = 0777;
}
path = JS_ToCString(ctx, argv[0]);
if (!path)
return JS_EXCEPTION;
#if defined(_WIN32)
(void)mode;
ret = js_get_errno(mkdir(path));
#else
ret = js_get_errno(mkdir(path, mode));
#endif
JS_FreeCString(ctx, path);
return JS_NewInt32(ctx, ret);
} | O1 | c | js_os_mkdir:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %r8, %r14
movq %rdi, %rbx
cmpl $0x2, %ecx
jl 0x1967a
movq 0x10(%r14), %rdx
movq 0x18(%r14), %rcx
leaq 0x4(%rsp), %rsi
movq %rbx, %rdi
callq 0x279b0
testl %eax, %eax
je 0x19682
movl $0x6, %edx
xorl %r14d, %r14d
jmp 0x196d4
movl $0x1ff, 0x4(%rsp) # imm = 0x1FF
movq (%r14), %rdx
movq 0x8(%r14), %rcx
xorl %r14d, %r14d
movq %rbx, %rdi
xorl %esi, %esi
xorl %r8d, %r8d
callq 0x20bf7
testq %rax, %rax
je 0x196cf
movq %rax, %r15
movl 0x4(%rsp), %esi
movq %rax, %rdi
callq 0xe130
movl %eax, %ebp
cmpl $-0x1, %eax
jne 0x196bd
callq 0xe0b0
xorl %ebp, %ebp
subl (%rax), %ebp
movq %rbx, %rdi
movq %r15, %rsi
callq 0x20edd
movl %ebp, %r14d
xorl %edx, %edx
jmp 0x196d4
movl $0x6, %edx
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| js_os_mkdir:
push rbp
push r15
push r14
push rbx
push rax
mov r14, r8
mov rbx, rdi
cmp ecx, 2
jl short loc_1967A
mov rdx, [r14+10h]
mov rcx, [r14+18h]
lea rsi, [rsp+28h+var_24]
mov rdi, rbx
call JS_ToInt32
test eax, eax
jz short loc_19682
mov edx, 6
xor r14d, r14d
jmp short loc_196D4
loc_1967A:
mov [rsp+28h+var_24], 1FFh
loc_19682:
mov rdx, [r14]
mov rcx, [r14+8]
xor r14d, r14d
mov rdi, rbx
xor esi, esi
xor r8d, r8d
call JS_ToCStringLen2
test rax, rax
jz short loc_196CF
mov r15, rax
mov esi, [rsp+28h+var_24]
mov rdi, rax
call _mkdir
mov ebp, eax
cmp eax, 0FFFFFFFFh
jnz short loc_196BD
call ___errno_location
xor ebp, ebp
sub ebp, [rax]
loc_196BD:
mov rdi, rbx
mov rsi, r15
call JS_FreeCString
mov r14d, ebp
xor edx, edx
jmp short loc_196D4
loc_196CF:
mov edx, 6
loc_196D4:
mov rax, r14
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
| long long js_os_mkdir(long long a1, long long a2, long long a3, int a4, long long *a5)
{
long long v5; // rax
long long v8; // r14
long long v9; // rdx
long long v10; // rcx
long long v11; // rax
long long v12; // r15
long long v13; // rdi
unsigned int v14; // ebp
unsigned int v16[9]; // [rsp+0h] [rbp-24h] BYREF
v16[0] = HIDWORD(v5);
if ( a4 < 2 )
{
v16[0] = 511;
}
else if ( (unsigned int)JS_ToInt32(a1, v16, a5[2], a5[3]) )
{
return 0LL;
}
v9 = *a5;
v10 = a5[1];
v8 = 0LL;
v11 = JS_ToCStringLen2(a1, 0LL, v9, v10, 0LL);
if ( v11 )
{
v12 = v11;
v13 = v11;
v14 = mkdir(v11, v16[0]);
if ( v14 == -1 )
v14 = -*(_DWORD *)__errno_location(v13);
JS_FreeCString(a1, v12);
return v14;
}
return v8;
}
| |||
38,010 | js_typed_array_get_byteLength | bluesky950520[P]quickjs/quickjs.c | static JSValue js_typed_array_get_byteLength(JSContext *ctx, JSValue this_val)
{
uint32_t size_log2;
JSTypedArray *ta;
JSObject *p;
p = get_typed_array(ctx, this_val);
if (!p)
return JS_EXCEPTION;
if (typed_array_is_oob(p))
return js_int32(0);
ta = p->u.typed_array;
if (!ta->track_rab)
return js_uint32(ta->length);
size_log2 = typed_array_size_log2(p->class_id);
return js_int64((int64_t)p->u.array.count << size_log2);
} | O0 | c | js_typed_array_get_byteLength:
subq $0x48, %rsp
movq %rsi, 0x28(%rsp)
movq %rdx, 0x30(%rsp)
movq %rdi, 0x20(%rsp)
movq 0x20(%rsp), %rdi
movq 0x28(%rsp), %rsi
movq 0x30(%rsp), %rdx
callq 0x58940
movq %rax, 0x8(%rsp)
cmpq $0x0, 0x8(%rsp)
jne 0xdf09a
movl $0x0, 0x38(%rsp)
movq $0x6, 0x40(%rsp)
jmp 0xdf12e
movq 0x8(%rsp), %rdi
callq 0x589d0
cmpl $0x0, %eax
je 0xdf0bc
xorl %edi, %edi
callq 0x33cc0
movq %rax, 0x38(%rsp)
movq %rdx, 0x40(%rsp)
jmp 0xdf12e
movq 0x8(%rsp), %rax
movq 0x30(%rax), %rax
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rax
cmpl $0x0, 0x28(%rax)
jne 0xdf0ee
movq 0x10(%rsp), %rax
movl 0x24(%rax), %edi
callq 0x33b60
movq %rax, 0x38(%rsp)
movq %rdx, 0x40(%rsp)
jmp 0xdf12e
movq 0x8(%rsp), %rax
movzwl 0x6(%rax), %eax
subl $0x15, %eax
movslq %eax, %rcx
leaq 0x2d8fb(%rip), %rax # 0x10c9ff
movzbl (%rax,%rcx), %eax
movl %eax, 0x1c(%rsp)
movq 0x8(%rsp), %rax
movl 0x40(%rax), %eax
movl %eax, %edi
movl 0x1c(%rsp), %eax
movl %eax, %ecx
shlq %cl, %rdi
callq 0x37480
movq %rax, 0x38(%rsp)
movq %rdx, 0x40(%rsp)
movq 0x38(%rsp), %rax
movq 0x40(%rsp), %rdx
addq $0x48, %rsp
retq
nopl (%rax)
| js_typed_array_get_byteLength:
sub rsp, 48h
mov [rsp+48h+var_20], rsi
mov [rsp+48h+var_18], rdx
mov [rsp+48h+var_28], rdi
mov rdi, [rsp+48h+var_28]
mov rsi, [rsp+48h+var_20]
mov rdx, [rsp+48h+var_18]
call get_typed_array
mov [rsp+48h+var_40], rax
cmp [rsp+48h+var_40], 0
jnz short loc_DF09A
mov dword ptr [rsp+48h+var_10], 0
mov [rsp+48h+var_8], 6
jmp loc_DF12E
loc_DF09A:
mov rdi, [rsp+48h+var_40]
call typed_array_is_oob
cmp eax, 0
jz short loc_DF0BC
xor edi, edi
call js_int32
mov [rsp+48h+var_10], rax
mov [rsp+48h+var_8], rdx
jmp short loc_DF12E
loc_DF0BC:
mov rax, [rsp+48h+var_40]
mov rax, [rax+30h]
mov [rsp+48h+var_38], rax
mov rax, [rsp+48h+var_38]
cmp dword ptr [rax+28h], 0
jnz short loc_DF0EE
mov rax, [rsp+48h+var_38]
mov edi, [rax+24h]
call js_uint32
mov [rsp+48h+var_10], rax
mov [rsp+48h+var_8], rdx
jmp short loc_DF12E
loc_DF0EE:
mov rax, [rsp+48h+var_40]
movzx eax, word ptr [rax+6]
sub eax, 15h
movsxd rcx, eax
lea rax, typed_array_size_log2
movzx eax, byte ptr [rax+rcx]
mov [rsp+48h+var_2C], eax
mov rax, [rsp+48h+var_40]
mov eax, [rax+40h]
mov edi, eax
mov eax, [rsp+48h+var_2C]
mov ecx, eax
shl rdi, cl
call js_int64
mov [rsp+48h+var_10], rax
mov [rsp+48h+var_8], rdx
loc_DF12E:
mov rax, [rsp+48h+var_10]
mov rdx, [rsp+48h+var_8]
add rsp, 48h
retn
| long long js_typed_array_get_byteLength(
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)
{
long long typed_array; // [rsp+8h] [rbp-40h]
long long v16; // [rsp+10h] [rbp-38h]
long long v17; // [rsp+38h] [rbp-10h]
typed_array = get_typed_array(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14);
if ( typed_array )
{
if ( typed_array_is_oob(typed_array) )
{
return js_int32(0);
}
else
{
v16 = *(_QWORD *)(typed_array + 48);
if ( *(_DWORD *)(v16 + 40) )
return js_int64((unsigned long long)*(unsigned int *)(typed_array + 64) << typed_array_size_log2[*(unsigned __int16 *)(typed_array + 6) - 21]);
else
return js_uint32(*(_DWORD *)(v16 + 36));
}
}
else
{
LODWORD(v17) = 0;
}
return v17;
}
| js_typed_array_get_byteLength:
SUB RSP,0x48
MOV qword ptr [RSP + 0x28],RSI
MOV qword ptr [RSP + 0x30],RDX
MOV qword ptr [RSP + 0x20],RDI
MOV RDI,qword ptr [RSP + 0x20]
MOV RSI,qword ptr [RSP + 0x28]
MOV RDX,qword ptr [RSP + 0x30]
CALL 0x00158940
MOV qword ptr [RSP + 0x8],RAX
CMP qword ptr [RSP + 0x8],0x0
JNZ 0x001df09a
MOV dword ptr [RSP + 0x38],0x0
MOV qword ptr [RSP + 0x40],0x6
JMP 0x001df12e
LAB_001df09a:
MOV RDI,qword ptr [RSP + 0x8]
CALL 0x001589d0
CMP EAX,0x0
JZ 0x001df0bc
XOR EDI,EDI
CALL 0x00133cc0
MOV qword ptr [RSP + 0x38],RAX
MOV qword ptr [RSP + 0x40],RDX
JMP 0x001df12e
LAB_001df0bc:
MOV RAX,qword ptr [RSP + 0x8]
MOV RAX,qword ptr [RAX + 0x30]
MOV qword ptr [RSP + 0x10],RAX
MOV RAX,qword ptr [RSP + 0x10]
CMP dword ptr [RAX + 0x28],0x0
JNZ 0x001df0ee
MOV RAX,qword ptr [RSP + 0x10]
MOV EDI,dword ptr [RAX + 0x24]
CALL 0x00133b60
MOV qword ptr [RSP + 0x38],RAX
MOV qword ptr [RSP + 0x40],RDX
JMP 0x001df12e
LAB_001df0ee:
MOV RAX,qword ptr [RSP + 0x8]
MOVZX EAX,word ptr [RAX + 0x6]
SUB EAX,0x15
MOVSXD RCX,EAX
LEA RAX,[0x20c9ff]
MOVZX EAX,byte ptr [RAX + RCX*0x1]
MOV dword ptr [RSP + 0x1c],EAX
MOV RAX,qword ptr [RSP + 0x8]
MOV EAX,dword ptr [RAX + 0x40]
MOV EDI,EAX
MOV EAX,dword ptr [RSP + 0x1c]
MOV ECX,EAX
SHL RDI,CL
CALL 0x00137480
MOV qword ptr [RSP + 0x38],RAX
MOV qword ptr [RSP + 0x40],RDX
LAB_001df12e:
MOV RAX,qword ptr [RSP + 0x38]
MOV RDX,qword ptr [RSP + 0x40]
ADD RSP,0x48
RET
|
int1 [16]
js_typed_array_get_byteLength(int8 param_1,int8 param_2,int8 param_3)
{
int iVar1;
long lVar2;
int1 auVar3 [16];
int4 local_10;
int4 uStack_c;
int8 local_8;
lVar2 = get_typed_array(param_1,param_2,param_3);
if (lVar2 == 0) {
local_10 = 0;
local_8 = 6;
}
else {
iVar1 = typed_array_is_oob(lVar2);
if (iVar1 == 0) {
if (*(int *)(*(long *)(lVar2 + 0x30) + 0x28) == 0) {
auVar3 = js_uint32(*(int4 *)(*(long *)(lVar2 + 0x30) + 0x24));
local_8 = auVar3._8_8_;
local_10 = auVar3._0_4_;
uStack_c = auVar3._4_4_;
}
else {
auVar3 = js_int64((ulong)*(uint *)(lVar2 + 0x40) <<
((&typed_array_size_log2)[(int)(*(ushort *)(lVar2 + 6) - 0x15)] & 0x3f));
local_8 = auVar3._8_8_;
local_10 = auVar3._0_4_;
uStack_c = auVar3._4_4_;
}
}
else {
auVar3 = js_int32(0);
local_8 = auVar3._8_8_;
local_10 = auVar3._0_4_;
uStack_c = auVar3._4_4_;
}
}
auVar3._4_4_ = uStack_c;
auVar3._0_4_ = local_10;
auVar3._8_8_ = local_8;
return auVar3;
}
| |
38,011 | js_typed_array_get_byteLength | bluesky950520[P]quickjs/quickjs.c | static JSValue js_typed_array_get_byteLength(JSContext *ctx, JSValue this_val)
{
uint32_t size_log2;
JSTypedArray *ta;
JSObject *p;
p = get_typed_array(ctx, this_val);
if (!p)
return JS_EXCEPTION;
if (typed_array_is_oob(p))
return js_int32(0);
ta = p->u.typed_array;
if (!ta->track_rab)
return js_uint32(ta->length);
size_log2 = typed_array_size_log2(p->class_id);
return js_int64((int64_t)p->u.array.count << size_log2);
} | O1 | c | js_typed_array_get_byteLength:
pushq %rbx
subq $0x10, %rsp
movq %rsi, 0x8(%rsp)
cmpl $-0x1, %edx
jne 0x8089b
movq 0x8(%rsp), %rbx
movzwl 0x6(%rbx), %eax
addl $-0x15, %eax
cmpw $0xc, %ax
jb 0x808ab
leaq 0x21b6f(%rip), %rsi # 0xa2411
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x22567
testq %rbx, %rbx
je 0x808c7
movq %rbx, %rdi
callq 0x396c4
testl %eax, %eax
je 0x808d2
xorl %eax, %eax
xorl %ecx, %ecx
xorl %edx, %edx
jmp 0x8094d
movl $0x6, %edx
xorl %eax, %eax
xorl %ecx, %ecx
jmp 0x8094d
movq 0x30(%rbx), %rax
cmpl $0x0, 0x28(%rax)
je 0x8091e
movzwl 0x6(%rbx), %eax
leaq 0x1cff8(%rip), %rcx # 0x9d8df
movb -0x15(%rax,%rcx), %cl
movl 0x40(%rbx), %eax
shlq %cl, %rax
movslq %eax, %rcx
xorl %esi, %esi
cmpq %rax, %rcx
movl %ecx, %ecx
cvtsi2sd %rax, %xmm0
movq %xmm0, %rax
cmoveq %rcx, %rax
movl $0x7, %edx
cmoveq %rsi, %rdx
movabsq $-0x100000000, %rcx # imm = 0xFFFFFFFF00000000
jmp 0x8094a
movslq 0x24(%rax), %rcx
xorl %esi, %esi
testq %rcx, %rcx
movl %ecx, %eax
cvtsi2sd %rax, %xmm0
movq %xmm0, %rax
cmovnsq %rcx, %rax
movl $0x7, %edx
cmovnsq %rsi, %rdx
movabsq $0x7fffffff00000000, %rcx # imm = 0x7FFFFFFF00000000
andq %rax, %rcx
movl %eax, %eax
orq %rcx, %rax
addq $0x10, %rsp
popq %rbx
retq
| js_typed_array_get_byteLength:
push rbx
sub rsp, 10h
mov [rsp+18h+var_10], rsi
cmp edx, 0FFFFFFFFh
jnz short loc_8089B
mov rbx, [rsp+18h+var_10]
movzx eax, word ptr [rbx+6]
add eax, 0FFFFFFEBh
cmp ax, 0Ch
jb short loc_808AB
loc_8089B:
lea rsi, aNotATypedarray; "not a TypedArray"
xor ebx, ebx
xor eax, eax
call JS_ThrowTypeError
loc_808AB:
test rbx, rbx
jz short loc_808C7
mov rdi, rbx
call typed_array_is_oob
test eax, eax
jz short loc_808D2
xor eax, eax
xor ecx, ecx
xor edx, edx
jmp loc_8094D
loc_808C7:
mov edx, 6
xor eax, eax
xor ecx, ecx
jmp short loc_8094D
loc_808D2:
mov rax, [rbx+30h]
cmp dword ptr [rax+28h], 0
jz short loc_8091E
movzx eax, word ptr [rbx+6]
lea rcx, typed_array_size_log2
mov cl, [rax+rcx-15h]
mov eax, [rbx+40h]
shl rax, cl
movsxd rcx, eax
xor esi, esi
cmp rcx, rax
mov ecx, ecx
cvtsi2sd xmm0, rax
movq rax, xmm0
cmovz rax, rcx
mov edx, 7
cmovz rdx, rsi
mov rcx, 0FFFFFFFF00000000h
jmp short loc_8094A
loc_8091E:
movsxd rcx, dword ptr [rax+24h]
xor esi, esi
test rcx, rcx
mov eax, ecx
cvtsi2sd xmm0, rax
movq rax, xmm0
cmovns rax, rcx
mov edx, 7
cmovns rdx, rsi
mov rcx, 7FFFFFFF00000000h
loc_8094A:
and rcx, rax
loc_8094D:
mov eax, eax
or rax, rcx
add rsp, 10h
pop rbx
retn
| unsigned long long js_typed_array_get_byteLength(
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)
{
long long v14; // rbx
double v15; // rax
unsigned long long v16; // rcx
long long v17; // rax
unsigned long long v18; // rax
bool v19; // zf
double v20; // rcx
unsigned long long v21; // rcx
long long v22; // rcx
char v24; // [rsp+0h] [rbp-18h]
if ( (_DWORD)a3 != -1 || (v14 = a2, (unsigned __int16)(*(_WORD *)(a2 + 6) - 21) >= 0xCu) )
{
v14 = 0LL;
JS_ThrowTypeError(a1, (long long)"not a TypedArray", a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, v24);
}
if ( v14 )
{
if ( typed_array_is_oob(v14) )
{
LODWORD(v15) = 0;
v16 = 0LL;
}
else
{
v17 = *(_QWORD *)(v14 + 48);
if ( *(_DWORD *)(v17 + 40) )
{
v18 = (unsigned long long)*(unsigned int *)(v14 + 64) << typed_array_size_log2[*(unsigned __int16 *)(v14 + 6) - 21];
v19 = (int)v18 == v18;
*(_QWORD *)&v20 = (unsigned int)v18;
v15 = (double)(int)v18;
if ( v19 )
v15 = v20;
v21 = 0xFFFFFFFF00000000LL;
}
else
{
v22 = *(int *)(v17 + 36);
v15 = (double)*(int *)(v17 + 36);
if ( v22 >= 0 )
v15 = *(double *)&v22;
v21 = 0x7FFFFFFF00000000LL;
}
v16 = *(_QWORD *)&v15 & v21;
}
}
else
{
LODWORD(v15) = 0;
v16 = 0LL;
}
return v16 | LODWORD(v15);
}
| |||
38,012 | partitioned_key_cache_insert | eloqsql/mysys/mf_keycache.c | static
int partitioned_key_cache_insert(PARTITIONED_KEY_CACHE_CB *keycache,
File file, my_off_t filepos, int level,
uchar *buff, uint length)
{
uint w_length;
uint offset= (uint) (filepos % keycache->key_cache_block_size);
DBUG_ENTER("partitioned_key_cache_insert");
DBUG_PRINT("enter", ("fd: %u pos: %lu length: %u",
(uint) file,(ulong) filepos, length));
/* Write data in key_cache_block_size increments */
do
{
SIMPLE_KEY_CACHE_CB *partition= get_key_cache_partition(keycache,
file, filepos);
w_length= length;
set_if_smaller(w_length, keycache->key_cache_block_size - offset);
if (simple_key_cache_insert((void *) partition,
file, filepos, level,
buff, w_length))
DBUG_RETURN(1);
filepos+= w_length;
buff+= w_length;
offset = 0;
} while ((length-= w_length));
DBUG_RETURN(0);
} | O0 | c | partitioned_key_cache_insert:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq %rdx, -0x20(%rbp)
movl %ecx, -0x24(%rbp)
movq %r8, -0x30(%rbp)
movl %r9d, -0x34(%rbp)
movq -0x20(%rbp), %rax
movq -0x10(%rbp), %rcx
movl 0x18(%rcx), %ecx
xorl %edx, %edx
divq %rcx
movl %edx, %eax
movl %eax, -0x3c(%rbp)
jmp 0xe9505
jmp 0xe9507
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %esi
movq -0x20(%rbp), %rdx
callq 0xe9a30
movq %rax, -0x48(%rbp)
movl -0x34(%rbp), %eax
movl %eax, -0x38(%rbp)
movl -0x38(%rbp), %eax
movq -0x10(%rbp), %rcx
movl 0x18(%rcx), %ecx
subl -0x3c(%rbp), %ecx
cmpl %ecx, %eax
jbe 0xe953f
movq -0x10(%rbp), %rax
movl 0x18(%rax), %eax
subl -0x3c(%rbp), %eax
movl %eax, -0x38(%rbp)
jmp 0xe9541
movq -0x48(%rbp), %rdi
movl -0x14(%rbp), %esi
movq -0x20(%rbp), %rdx
movl -0x24(%rbp), %ecx
movq -0x30(%rbp), %r8
movl -0x38(%rbp), %r9d
callq 0xe7410
cmpl $0x0, %eax
je 0xe956c
jmp 0xe9563
movl $0x1, -0x4(%rbp)
jmp 0xe95ab
movl -0x38(%rbp), %eax
addq -0x20(%rbp), %rax
movq %rax, -0x20(%rbp)
movl -0x38(%rbp), %ecx
movq -0x30(%rbp), %rax
movl %ecx, %ecx
addq %rcx, %rax
movq %rax, -0x30(%rbp)
movl $0x0, -0x3c(%rbp)
movl -0x38(%rbp), %ecx
movl -0x34(%rbp), %eax
subl %ecx, %eax
movl %eax, -0x34(%rbp)
cmpl $0x0, %eax
jne 0xe9507
jmp 0xe95a4
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| partitioned_key_cache_insert:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_20], rdx
mov [rbp+var_24], ecx
mov [rbp+var_30], r8
mov [rbp+var_34], r9d
mov rax, [rbp+var_20]
mov rcx, [rbp+var_10]
mov ecx, [rcx+18h]
xor edx, edx
div rcx
mov eax, edx
mov [rbp+var_3C], eax
jmp short $+2
loc_E9505:
jmp short $+2
loc_E9507:
mov rdi, [rbp+var_10]
mov esi, [rbp+var_14]
mov rdx, [rbp+var_20]
call get_key_cache_partition
mov [rbp+var_48], rax
mov eax, [rbp+var_34]
mov [rbp+var_38], eax
mov eax, [rbp+var_38]
mov rcx, [rbp+var_10]
mov ecx, [rcx+18h]
sub ecx, [rbp+var_3C]
cmp eax, ecx
jbe short loc_E953F
mov rax, [rbp+var_10]
mov eax, [rax+18h]
sub eax, [rbp+var_3C]
mov [rbp+var_38], eax
loc_E953F:
jmp short $+2
loc_E9541:
mov rdi, [rbp+var_48]
mov esi, [rbp+var_14]
mov rdx, [rbp+var_20]
mov ecx, [rbp+var_24]
mov r8, [rbp+var_30]
mov r9d, [rbp+var_38]
call simple_key_cache_insert
cmp eax, 0
jz short loc_E956C
jmp short $+2
loc_E9563:
mov [rbp+var_4], 1
jmp short loc_E95AB
loc_E956C:
mov eax, [rbp+var_38]
add rax, [rbp+var_20]
mov [rbp+var_20], rax
mov ecx, [rbp+var_38]
mov rax, [rbp+var_30]
mov ecx, ecx
add rax, rcx
mov [rbp+var_30], rax
mov [rbp+var_3C], 0
mov ecx, [rbp+var_38]
mov eax, [rbp+var_34]
sub eax, ecx
mov [rbp+var_34], eax
cmp eax, 0
jnz loc_E9507
jmp short $+2
loc_E95A4:
mov [rbp+var_4], 0
loc_E95AB:
mov eax, [rbp+var_4]
add rsp, 50h
pop rbp
retn
| long long partitioned_key_cache_insert(
long long a1,
unsigned int a2,
unsigned long long a3,
int a4,
long long a5,
unsigned int a6)
{
_QWORD *key_cache_partition; // [rsp+8h] [rbp-48h]
int v8; // [rsp+14h] [rbp-3Ch]
unsigned int v9; // [rsp+18h] [rbp-38h]
unsigned long long v13; // [rsp+30h] [rbp-20h]
v13 = a3;
v8 = a3 % *(unsigned int *)(a1 + 24);
do
{
key_cache_partition = (_QWORD *)get_key_cache_partition(a1, a2, v13);
v9 = a6;
if ( a6 > *(_DWORD *)(a1 + 24) - v8 )
v9 = *(_DWORD *)(a1 + 24) - v8;
if ( (unsigned int)simple_key_cache_insert(key_cache_partition, a2, v13, a4, a5, v9) )
return 1;
v13 += v9;
a5 += v9;
v8 = 0;
a6 -= v9;
}
while ( a6 );
return 0;
}
| partitioned_key_cache_insert:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV qword ptr [RBP + -0x20],RDX
MOV dword ptr [RBP + -0x24],ECX
MOV qword ptr [RBP + -0x30],R8
MOV dword ptr [RBP + -0x34],R9D
MOV RAX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RCX + 0x18]
XOR EDX,EDX
DIV RCX
MOV EAX,EDX
MOV dword ptr [RBP + -0x3c],EAX
JMP 0x001e9505
LAB_001e9505:
JMP 0x001e9507
LAB_001e9507:
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RBP + -0x14]
MOV RDX,qword ptr [RBP + -0x20]
CALL 0x001e9a30
MOV qword ptr [RBP + -0x48],RAX
MOV EAX,dword ptr [RBP + -0x34]
MOV dword ptr [RBP + -0x38],EAX
MOV EAX,dword ptr [RBP + -0x38]
MOV RCX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RCX + 0x18]
SUB ECX,dword ptr [RBP + -0x3c]
CMP EAX,ECX
JBE 0x001e953f
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x18]
SUB EAX,dword ptr [RBP + -0x3c]
MOV dword ptr [RBP + -0x38],EAX
LAB_001e953f:
JMP 0x001e9541
LAB_001e9541:
MOV RDI,qword ptr [RBP + -0x48]
MOV ESI,dword ptr [RBP + -0x14]
MOV RDX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RBP + -0x24]
MOV R8,qword ptr [RBP + -0x30]
MOV R9D,dword ptr [RBP + -0x38]
CALL 0x001e7410
CMP EAX,0x0
JZ 0x001e956c
JMP 0x001e9563
LAB_001e9563:
MOV dword ptr [RBP + -0x4],0x1
JMP 0x001e95ab
LAB_001e956c:
MOV EAX,dword ptr [RBP + -0x38]
ADD RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x20],RAX
MOV ECX,dword ptr [RBP + -0x38]
MOV RAX,qword ptr [RBP + -0x30]
MOV ECX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x30],RAX
MOV dword ptr [RBP + -0x3c],0x0
MOV ECX,dword ptr [RBP + -0x38]
MOV EAX,dword ptr [RBP + -0x34]
SUB EAX,ECX
MOV dword ptr [RBP + -0x34],EAX
CMP EAX,0x0
JNZ 0x001e9507
JMP 0x001e95a4
LAB_001e95a4:
MOV dword ptr [RBP + -0x4],0x0
LAB_001e95ab:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x50
POP RBP
RET
|
int4
partitioned_key_cache_insert
(long param_1,int4 param_2,ulong param_3,int4 param_4,long param_5,
uint param_6)
{
int iVar1;
int8 uVar2;
int local_44;
uint local_40;
uint local_3c;
long local_38;
ulong local_28;
local_44 = (int)(param_3 % (ulong)*(uint *)(param_1 + 0x18));
local_3c = param_6;
local_38 = param_5;
local_28 = param_3;
while( true ) {
uVar2 = get_key_cache_partition(param_1,param_2,local_28);
local_40 = local_3c;
if ((uint)(*(int *)(param_1 + 0x18) - local_44) < local_3c) {
local_40 = *(int *)(param_1 + 0x18) - local_44;
}
iVar1 = simple_key_cache_insert(uVar2,param_2,local_28,param_4,local_38,local_40);
if (iVar1 != 0) break;
local_28 = local_40 + local_28;
local_38 = local_38 + (ulong)local_40;
local_44 = 0;
local_3c = local_3c - local_40;
if (local_3c == 0) {
return 0;
}
}
return 1;
}
| |
38,013 | split_maria_rtree_node | eloqsql/storage/maria/ma_rt_split.c | static int split_maria_rtree_node(SplitStruct *node, int n_entries,
int all_size, /* Total key's size */
int key_size,
int min_size, /* Minimal group size */
int size1, int size2 /* initial group sizes */,
double **d_buffer, int n_dim)
{
SplitStruct *cur;
SplitStruct *UNINIT_VAR(a);
SplitStruct *UNINIT_VAR(b);
double *g1= reserve_coords(d_buffer, n_dim);
double *g2= reserve_coords(d_buffer, n_dim);
SplitStruct *UNINIT_VAR(next);
int UNINIT_VAR(next_node);
int i;
SplitStruct *end= node + n_entries;
if (all_size < min_size * 2)
{
return 1;
}
cur= node;
for (; cur < end; cur++)
{
cur->square= count_square(cur->coords, n_dim);
cur->n_node= 0;
}
pick_seeds(node, n_entries, &a, &b, n_dim);
a->n_node= 1;
b->n_node= 2;
copy_coords(g1, a->coords, n_dim);
size1+= key_size;
copy_coords(g2, b->coords, n_dim);
size2+= key_size;
for (i=n_entries - 2; i>0; --i)
{
if (all_size - (size2 + key_size) < min_size) /* Can't write into group 2 */
{
mark_all_entries(node, n_entries, 1);
break;
}
if (all_size - (size1 + key_size) < min_size) /* Can't write into group 1 */
{
mark_all_entries(node, n_entries, 2);
break;
}
pick_next(node, n_entries, g1, g2, &next, &next_node, n_dim);
if (next_node == 1)
{
size1+= key_size;
mbr_join(g1, next->coords, n_dim);
}
else
{
size2+= key_size;
mbr_join(g2, next->coords, n_dim);
}
next->n_node= next_node;
}
return 0;
} | O0 | c | split_maria_rtree_node:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movl 0x20(%rbp), %eax
movq 0x18(%rbp), %rax
movl 0x10(%rbp), %eax
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movl %r8d, -0x20(%rbp)
movl %r9d, -0x24(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x40(%rbp)
movq 0x18(%rbp), %rdi
movl 0x20(%rbp), %esi
callq 0x9b610
movq %rax, -0x48(%rbp)
movq 0x18(%rbp), %rdi
movl 0x20(%rbp), %esi
callq 0x9b610
movq %rax, -0x50(%rbp)
movq -0x58(%rbp), %rax
movq %rax, -0x58(%rbp)
movl -0x5c(%rbp), %eax
movl %eax, -0x5c(%rbp)
movq -0x10(%rbp), %rax
movslq -0x14(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq %rax, -0x68(%rbp)
movl -0x18(%rbp), %eax
movl -0x20(%rbp), %ecx
shll %ecx
cmpl %ecx, %eax
jge 0x9b6e0
movl $0x1, -0x4(%rbp)
jmp 0x9b86a
movq -0x10(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
cmpq -0x68(%rbp), %rax
jae 0x9b723
movq -0x30(%rbp), %rax
movq 0x18(%rax), %rdi
movl 0x20(%rbp), %esi
callq 0x9bb40
movq -0x30(%rbp), %rax
movsd %xmm0, (%rax)
movq -0x30(%rbp), %rax
movl $0x0, 0x8(%rax)
movq -0x30(%rbp), %rax
addq $0x20, %rax
movq %rax, -0x30(%rbp)
jmp 0x9b6e8
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %esi
movl 0x20(%rbp), %r8d
leaq -0x38(%rbp), %rdx
leaq -0x40(%rbp), %rcx
callq 0x9bbb0
movq -0x38(%rbp), %rax
movl $0x1, 0x8(%rax)
movq -0x40(%rbp), %rax
movl $0x2, 0x8(%rax)
movq -0x48(%rbp), %rdi
movq -0x38(%rbp), %rax
movq 0x18(%rax), %rsi
movl 0x20(%rbp), %edx
callq 0x9bcc0
movl -0x1c(%rbp), %eax
addl -0x24(%rbp), %eax
movl %eax, -0x24(%rbp)
movq -0x50(%rbp), %rdi
movq -0x40(%rbp), %rax
movq 0x18(%rax), %rsi
movl 0x20(%rbp), %edx
callq 0x9bcc0
movl -0x1c(%rbp), %eax
addl 0x10(%rbp), %eax
movl %eax, 0x10(%rbp)
movl -0x14(%rbp), %eax
subl $0x2, %eax
movl %eax, -0x60(%rbp)
cmpl $0x0, -0x60(%rbp)
jle 0x9b863
movl -0x18(%rbp), %eax
movl 0x10(%rbp), %ecx
addl -0x1c(%rbp), %ecx
subl %ecx, %eax
cmpl -0x20(%rbp), %eax
jge 0x9b7c4
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %esi
movl $0x1, %edx
callq 0x9bd00
jmp 0x9b863
movl -0x18(%rbp), %eax
movl -0x24(%rbp), %ecx
addl -0x1c(%rbp), %ecx
subl %ecx, %eax
cmpl -0x20(%rbp), %eax
jge 0x9b7e7
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %esi
movl $0x2, %edx
callq 0x9bd00
jmp 0x9b863
movq -0x10(%rbp), %rdi
movl -0x14(%rbp), %esi
movq -0x48(%rbp), %rdx
movq -0x50(%rbp), %rcx
movl 0x20(%rbp), %eax
leaq -0x58(%rbp), %r8
leaq -0x5c(%rbp), %r9
movl %eax, (%rsp)
callq 0x9bd60
cmpl $0x1, -0x5c(%rbp)
jne 0x9b82e
movl -0x1c(%rbp), %eax
addl -0x24(%rbp), %eax
movl %eax, -0x24(%rbp)
movq -0x48(%rbp), %rdi
movq -0x58(%rbp), %rax
movq 0x18(%rax), %rsi
movl 0x20(%rbp), %edx
callq 0x9be80
jmp 0x9b84b
movl -0x1c(%rbp), %eax
addl 0x10(%rbp), %eax
movl %eax, 0x10(%rbp)
movq -0x50(%rbp), %rdi
movq -0x58(%rbp), %rax
movq 0x18(%rax), %rsi
movl 0x20(%rbp), %edx
callq 0x9be80
movl -0x5c(%rbp), %ecx
movq -0x58(%rbp), %rax
movl %ecx, 0x8(%rax)
movl -0x60(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x60(%rbp)
jmp 0x9b794
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x70, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| split_maria_rtree_node:
push rbp
mov rbp, rsp
sub rsp, 70h
mov eax, [rbp+arg_10]
mov rax, [rbp+arg_8]
mov eax, [rbp+arg_0]
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_18], edx
mov [rbp+var_1C], ecx
mov [rbp+var_20], r8d
mov [rbp+var_24], r9d
mov rax, [rbp+var_38]
mov [rbp+var_38], rax
mov rax, [rbp+var_40]
mov [rbp+var_40], rax
mov rdi, [rbp+arg_8]
mov esi, [rbp+arg_10]
call reserve_coords
mov [rbp+var_48], rax
mov rdi, [rbp+arg_8]
mov esi, [rbp+arg_10]
call reserve_coords
mov [rbp+var_50], rax
mov rax, [rbp+var_58]
mov [rbp+var_58], rax
mov eax, [rbp+var_5C]
mov [rbp+var_5C], eax
mov rax, [rbp+var_10]
movsxd rcx, [rbp+var_14]
shl rcx, 5
add rax, rcx
mov [rbp+var_68], rax
mov eax, [rbp+var_18]
mov ecx, [rbp+var_20]
shl ecx, 1
cmp eax, ecx
jge short loc_9B6E0
mov [rbp+var_4], 1
jmp loc_9B86A
loc_9B6E0:
mov rax, [rbp+var_10]
mov [rbp+var_30], rax
loc_9B6E8:
mov rax, [rbp+var_30]
cmp rax, [rbp+var_68]
jnb short loc_9B723
mov rax, [rbp+var_30]
mov rdi, [rax+18h]
mov esi, [rbp+arg_10]
call count_square
mov rax, [rbp+var_30]
movsd qword ptr [rax], xmm0
mov rax, [rbp+var_30]
mov dword ptr [rax+8], 0
mov rax, [rbp+var_30]
add rax, 20h ; ' '
mov [rbp+var_30], rax
jmp short loc_9B6E8
loc_9B723:
mov rdi, [rbp+var_10]
mov esi, [rbp+var_14]
mov r8d, [rbp+arg_10]
lea rdx, [rbp+var_38]
lea rcx, [rbp+var_40]
call pick_seeds
mov rax, [rbp+var_38]
mov dword ptr [rax+8], 1
mov rax, [rbp+var_40]
mov dword ptr [rax+8], 2
mov rdi, [rbp+var_48]
mov rax, [rbp+var_38]
mov rsi, [rax+18h]
mov edx, [rbp+arg_10]
call copy_coords
mov eax, [rbp+var_1C]
add eax, [rbp+var_24]
mov [rbp+var_24], eax
mov rdi, [rbp+var_50]
mov rax, [rbp+var_40]
mov rsi, [rax+18h]
mov edx, [rbp+arg_10]
call copy_coords
mov eax, [rbp+var_1C]
add eax, [rbp+arg_0]
mov [rbp+arg_0], eax
mov eax, [rbp+var_14]
sub eax, 2
mov [rbp+var_60], eax
loc_9B794:
cmp [rbp+var_60], 0
jle loc_9B863
mov eax, [rbp+var_18]
mov ecx, [rbp+arg_0]
add ecx, [rbp+var_1C]
sub eax, ecx
cmp eax, [rbp+var_20]
jge short loc_9B7C4
mov rdi, [rbp+var_10]
mov esi, [rbp+var_14]
mov edx, 1
call mark_all_entries
jmp loc_9B863
loc_9B7C4:
mov eax, [rbp+var_18]
mov ecx, [rbp+var_24]
add ecx, [rbp+var_1C]
sub eax, ecx
cmp eax, [rbp+var_20]
jge short loc_9B7E7
mov rdi, [rbp+var_10]
mov esi, [rbp+var_14]
mov edx, 2
call mark_all_entries
jmp short loc_9B863
loc_9B7E7:
mov rdi, [rbp+var_10]
mov esi, [rbp+var_14]
mov rdx, [rbp+var_48]
mov rcx, [rbp+var_50]
mov eax, [rbp+arg_10]
lea r8, [rbp+var_58]
lea r9, [rbp+var_5C]
mov [rsp+70h+var_70], eax
call pick_next
cmp [rbp+var_5C], 1
jnz short loc_9B82E
mov eax, [rbp+var_1C]
add eax, [rbp+var_24]
mov [rbp+var_24], eax
mov rdi, [rbp+var_48]
mov rax, [rbp+var_58]
mov rsi, [rax+18h]
mov edx, [rbp+arg_10]
call mbr_join
jmp short loc_9B84B
loc_9B82E:
mov eax, [rbp+var_1C]
add eax, [rbp+arg_0]
mov [rbp+arg_0], eax
mov rdi, [rbp+var_50]
mov rax, [rbp+var_58]
mov rsi, [rax+18h]
mov edx, [rbp+arg_10]
call mbr_join
loc_9B84B:
mov ecx, [rbp+var_5C]
mov rax, [rbp+var_58]
mov [rax+8], ecx
mov eax, [rbp+var_60]
add eax, 0FFFFFFFFh
mov [rbp+var_60], eax
jmp loc_9B794
loc_9B863:
mov [rbp+var_4], 0
loc_9B86A:
mov eax, [rbp+var_4]
add rsp, 70h
pop rbp
retn
| long long split_maria_rtree_node(
unsigned long long a1,
unsigned int a2,
int a3,
int a4,
int a5,
int a6,
int a7,
long long *a8,
unsigned int a9)
{
int j; // [rsp+10h] [rbp-60h]
int v11; // [rsp+14h] [rbp-5Ch] BYREF
long long v12; // [rsp+18h] [rbp-58h] BYREF
long long v13; // [rsp+20h] [rbp-50h]
long long v14; // [rsp+28h] [rbp-48h]
long long v15; // [rsp+30h] [rbp-40h] BYREF
long long v16; // [rsp+38h] [rbp-38h] BYREF
unsigned long long i; // [rsp+40h] [rbp-30h]
int v18; // [rsp+4Ch] [rbp-24h]
int v19; // [rsp+50h] [rbp-20h]
int v20; // [rsp+54h] [rbp-1Ch]
int v21; // [rsp+58h] [rbp-18h]
unsigned int v22; // [rsp+5Ch] [rbp-14h]
unsigned long long v23; // [rsp+60h] [rbp-10h]
int v25; // [rsp+80h] [rbp+10h]
v23 = a1;
v22 = a2;
v21 = a3;
v20 = a4;
v19 = a5;
v18 = a6;
v14 = reserve_coords(a8, a9);
v13 = reserve_coords(a8, a9);
if ( v21 >= 2 * v19 )
{
for ( i = v23; i < 32LL * (int)a2 + a1; i += 32LL )
{
*(double *)i = count_square(*(_QWORD *)(i + 24), a9);
*(_DWORD *)(i + 8) = 0;
}
pick_seeds(v23, v22, &v16, &v15, a9);
*(_DWORD *)(v16 + 8) = 1;
*(_DWORD *)(v15 + 8) = 2;
copy_coords(v14, *(_QWORD *)(v16 + 24), a9);
v18 += v20;
copy_coords(v13, *(_QWORD *)(v15 + 24), a9);
v25 = a7 + v20;
for ( j = v22 - 2; j > 0; --j )
{
if ( v21 - (v20 + v25) < v19 )
{
mark_all_entries(v23, v22, 1LL);
break;
}
if ( v21 - (v20 + v18) < v19 )
{
mark_all_entries(v23, v22, 2LL);
break;
}
pick_next(v23, v22, v14, v13, (unsigned int)&v12, (unsigned int)&v11, a9);
if ( v11 == 1 )
{
v18 += v20;
mbr_join(v14, *(_QWORD *)(v12 + 24), a9);
}
else
{
v25 += v20;
mbr_join(v13, *(_QWORD *)(v12 + 24), a9);
}
*(_DWORD *)(v12 + 8) = v11;
}
return 0;
}
else
{
return 1;
}
}
| split_maria_rtree_node:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x70
MOV EAX,dword ptr [RBP + 0x20]
MOV RAX,qword ptr [RBP + 0x18]
MOV EAX,dword ptr [RBP + 0x10]
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV dword ptr [RBP + -0x18],EDX
MOV dword ptr [RBP + -0x1c],ECX
MOV dword ptr [RBP + -0x20],R8D
MOV dword ptr [RBP + -0x24],R9D
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x40]
MOV qword ptr [RBP + -0x40],RAX
MOV RDI,qword ptr [RBP + 0x18]
MOV ESI,dword ptr [RBP + 0x20]
CALL 0x0019b610
MOV qword ptr [RBP + -0x48],RAX
MOV RDI,qword ptr [RBP + 0x18]
MOV ESI,dword ptr [RBP + 0x20]
CALL 0x0019b610
MOV qword ptr [RBP + -0x50],RAX
MOV RAX,qword ptr [RBP + -0x58]
MOV qword ptr [RBP + -0x58],RAX
MOV EAX,dword ptr [RBP + -0x5c]
MOV dword ptr [RBP + -0x5c],EAX
MOV RAX,qword ptr [RBP + -0x10]
MOVSXD RCX,dword ptr [RBP + -0x14]
SHL RCX,0x5
ADD RAX,RCX
MOV qword ptr [RBP + -0x68],RAX
MOV EAX,dword ptr [RBP + -0x18]
MOV ECX,dword ptr [RBP + -0x20]
SHL ECX,0x1
CMP EAX,ECX
JGE 0x0019b6e0
MOV dword ptr [RBP + -0x4],0x1
JMP 0x0019b86a
LAB_0019b6e0:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x30],RAX
LAB_0019b6e8:
MOV RAX,qword ptr [RBP + -0x30]
CMP RAX,qword ptr [RBP + -0x68]
JNC 0x0019b723
MOV RAX,qword ptr [RBP + -0x30]
MOV RDI,qword ptr [RAX + 0x18]
MOV ESI,dword ptr [RBP + 0x20]
CALL 0x0019bb40
MOV RAX,qword ptr [RBP + -0x30]
MOVSD qword ptr [RAX],XMM0
MOV RAX,qword ptr [RBP + -0x30]
MOV dword ptr [RAX + 0x8],0x0
MOV RAX,qword ptr [RBP + -0x30]
ADD RAX,0x20
MOV qword ptr [RBP + -0x30],RAX
JMP 0x0019b6e8
LAB_0019b723:
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RBP + -0x14]
MOV R8D,dword ptr [RBP + 0x20]
LEA RDX,[RBP + -0x38]
LEA RCX,[RBP + -0x40]
CALL 0x0019bbb0
MOV RAX,qword ptr [RBP + -0x38]
MOV dword ptr [RAX + 0x8],0x1
MOV RAX,qword ptr [RBP + -0x40]
MOV dword ptr [RAX + 0x8],0x2
MOV RDI,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RBP + -0x38]
MOV RSI,qword ptr [RAX + 0x18]
MOV EDX,dword ptr [RBP + 0x20]
CALL 0x0019bcc0
MOV EAX,dword ptr [RBP + -0x1c]
ADD EAX,dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0x24],EAX
MOV RDI,qword ptr [RBP + -0x50]
MOV RAX,qword ptr [RBP + -0x40]
MOV RSI,qword ptr [RAX + 0x18]
MOV EDX,dword ptr [RBP + 0x20]
CALL 0x0019bcc0
MOV EAX,dword ptr [RBP + -0x1c]
ADD EAX,dword ptr [RBP + 0x10]
MOV dword ptr [RBP + 0x10],EAX
MOV EAX,dword ptr [RBP + -0x14]
SUB EAX,0x2
MOV dword ptr [RBP + -0x60],EAX
LAB_0019b794:
CMP dword ptr [RBP + -0x60],0x0
JLE 0x0019b863
MOV EAX,dword ptr [RBP + -0x18]
MOV ECX,dword ptr [RBP + 0x10]
ADD ECX,dword ptr [RBP + -0x1c]
SUB EAX,ECX
CMP EAX,dword ptr [RBP + -0x20]
JGE 0x0019b7c4
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RBP + -0x14]
MOV EDX,0x1
CALL 0x0019bd00
JMP 0x0019b863
LAB_0019b7c4:
MOV EAX,dword ptr [RBP + -0x18]
MOV ECX,dword ptr [RBP + -0x24]
ADD ECX,dword ptr [RBP + -0x1c]
SUB EAX,ECX
CMP EAX,dword ptr [RBP + -0x20]
JGE 0x0019b7e7
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RBP + -0x14]
MOV EDX,0x2
CALL 0x0019bd00
JMP 0x0019b863
LAB_0019b7e7:
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RBP + -0x14]
MOV RDX,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBP + -0x50]
MOV EAX,dword ptr [RBP + 0x20]
LEA R8,[RBP + -0x58]
LEA R9,[RBP + -0x5c]
MOV dword ptr [RSP],EAX
CALL 0x0019bd60
CMP dword ptr [RBP + -0x5c],0x1
JNZ 0x0019b82e
MOV EAX,dword ptr [RBP + -0x1c]
ADD EAX,dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0x24],EAX
MOV RDI,qword ptr [RBP + -0x48]
MOV RAX,qword ptr [RBP + -0x58]
MOV RSI,qword ptr [RAX + 0x18]
MOV EDX,dword ptr [RBP + 0x20]
CALL 0x0019be80
JMP 0x0019b84b
LAB_0019b82e:
MOV EAX,dword ptr [RBP + -0x1c]
ADD EAX,dword ptr [RBP + 0x10]
MOV dword ptr [RBP + 0x10],EAX
MOV RDI,qword ptr [RBP + -0x50]
MOV RAX,qword ptr [RBP + -0x58]
MOV RSI,qword ptr [RAX + 0x18]
MOV EDX,dword ptr [RBP + 0x20]
CALL 0x0019be80
LAB_0019b84b:
MOV ECX,dword ptr [RBP + -0x5c]
MOV RAX,qword ptr [RBP + -0x58]
MOV dword ptr [RAX + 0x8],ECX
MOV EAX,dword ptr [RBP + -0x60]
ADD EAX,-0x1
MOV dword ptr [RBP + -0x60],EAX
JMP 0x0019b794
LAB_0019b863:
MOV dword ptr [RBP + -0x4],0x0
LAB_0019b86a:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x70
POP RBP
RET
|
int4
split_maria_rtree_node
(int8 *param_1,int param_2,int param_3,int param_4,int param_5,int param_6,
int param_7,int8 param_8,int4 param_9)
{
int8 *puVar1;
int8 uVar2;
int local_68;
int local_64;
long local_60;
int8 local_58;
int8 local_50;
long local_48;
long local_40;
int8 *local_38;
int local_2c;
int local_28;
int local_24;
int local_20;
int local_1c;
int8 *local_18;
int4 local_c;
local_2c = param_6;
local_28 = param_5;
local_24 = param_4;
local_20 = param_3;
local_1c = param_2;
local_18 = param_1;
local_50 = reserve_coords(param_8,param_9);
local_58 = reserve_coords(param_8,param_9);
puVar1 = local_18 + (long)local_1c * 4;
if (SBORROW4(local_20,local_28 * 2) == local_20 + local_28 * -2 < 0) {
for (local_38 = local_18; local_38 < puVar1; local_38 = local_38 + 4) {
uVar2 = count_square(local_38[3],param_9);
*local_38 = uVar2;
*(int4 *)(local_38 + 1) = 0;
}
pick_seeds(local_18,local_1c,&local_40,&local_48,param_9);
*(int4 *)(local_40 + 8) = 1;
*(int4 *)(local_48 + 8) = 2;
copy_coords(local_50,*(int8 *)(local_40 + 0x18),param_9);
local_2c = local_24 + local_2c;
copy_coords(local_58,*(int8 *)(local_48 + 0x18),param_9);
param_7 = local_24 + param_7;
for (local_68 = local_1c + -2; 0 < local_68; local_68 = local_68 + -1) {
if (local_20 - (param_7 + local_24) < local_28) {
mark_all_entries(local_18,local_1c,1);
break;
}
if (local_20 - (local_2c + local_24) < local_28) {
mark_all_entries(local_18,local_1c,2);
break;
}
pick_next(local_18,local_1c,local_50,local_58,&local_60,&local_64,param_9);
if (local_64 == 1) {
local_2c = local_24 + local_2c;
mbr_join(local_50,*(int8 *)(local_60 + 0x18),param_9);
}
else {
param_7 = local_24 + param_7;
mbr_join(local_58,*(int8 *)(local_60 + 0x18),param_9);
}
*(int *)(local_60 + 8) = local_64;
}
local_c = 0;
}
else {
local_c = 1;
}
return local_c;
}
| |
38,014 | ft_boolean_read_next | eloqsql/storage/myisam/ft_boolean_search.c | int ft_boolean_read_next(FT_INFO *ftb, char *record)
{
FTB_EXPR *ftbe;
FTB_WORD *ftbw;
MI_INFO *info=ftb->info;
my_off_t curdoc;
if (ftb->state != INDEX_SEARCH && ftb->state != INDEX_DONE)
return -1;
/* black magic ON */
if ((int) _mi_check_index(info, ftb->keynr) < 0)
return my_errno;
if (_mi_readinfo(info, F_RDLCK, 1))
return my_errno;
/* black magic OFF */
if (!ftb->queue.elements)
return my_errno=HA_ERR_END_OF_FILE;
/* Attention!!! Address of a local variable is used here! See err: label */
ftb->queue.first_cmp_arg=(void *)&curdoc;
while (ftb->state == INDEX_SEARCH &&
(curdoc=((FTB_WORD *)queue_top(& ftb->queue))->docid[0]) !=
HA_OFFSET_ERROR)
{
while (curdoc == (ftbw=(FTB_WORD *)queue_top(& ftb->queue))->docid[0])
{
if (unlikely(_ftb_climb_the_tree(ftb, ftbw, 0)))
{
my_errno= HA_ERR_OUT_OF_MEM;
goto err;
}
/* update queue */
_ft2_search(ftb, ftbw, 0);
queue_replace_top(&ftb->queue);
}
ftbe=ftb->root;
if (ftbe->docid[0]==curdoc && ftbe->cur_weight>0 &&
ftbe->yesses>=(ftbe->ythresh-ftbe->yweaks) && !ftbe->nos)
{
/* curdoc matched ! */
if (is_tree_inited(&ftb->no_dupes) &&
tree_insert(&ftb->no_dupes, &curdoc, 0,
ftb->no_dupes.custom_arg)->count >1)
/* but it managed already to get past this line once */
continue;
info->lastpos=curdoc;
/* Clear all states, except that the table was updated */
info->update&= (HA_STATE_CHANGED | HA_STATE_ROW_CHANGED);
if (!(*info->read_record)(info,curdoc, (uchar*) record))
{
info->update|= HA_STATE_AKTIV; /* Record is read */
if (ftb->with_scan &&
ft_boolean_find_relevance(ftb,(uchar*) record,0)==0)
continue; /* no match */
my_errno=0;
goto err;
}
goto err;
}
}
ftb->state=INDEX_DONE;
my_errno=HA_ERR_END_OF_FILE;
err:
ftb->queue.first_cmp_arg=(void *)0;
return my_errno;
} | O0 | c | ft_boolean_read_next:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x2, 0x348(%rax)
je 0x9e9b2
movq -0x10(%rbp), %rax
cmpl $0x3, 0x348(%rax)
je 0x9e9b2
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x9ec42
movq -0x30(%rbp), %rdi
movq -0x10(%rbp), %rax
movl 0x340(%rax), %esi
callq 0xbe6c0
cmpl $0x0, %eax
jge 0x9e9d9
callq 0xf60c0
movl (%rax), %eax
movl %eax, -0x4(%rbp)
jmp 0x9ec42
movq -0x30(%rbp), %rdi
xorl %esi, %esi
movl $0x1, %edx
callq 0xb10f0
cmpl $0x0, %eax
je 0x9e9fd
callq 0xf60c0
movl (%rax), %eax
movl %eax, -0x4(%rbp)
jmp 0x9ec42
movq -0x10(%rbp), %rax
cmpl $0x0, 0x80(%rax)
jne 0x9ea21
callq 0xf60c0
movl $0x89, (%rax)
movl $0x89, -0x4(%rbp)
jmp 0x9ec42
movq -0x10(%rbp), %rax
leaq -0x38(%rbp), %rcx
movq %rcx, 0x78(%rax)
movq -0x10(%rbp), %rcx
xorl %eax, %eax
cmpl $0x2, 0x348(%rcx)
movb %al, -0x39(%rbp)
jne 0x9ea5d
movq -0x10(%rbp), %rax
movq 0x70(%rax), %rax
movq 0x8(%rax), %rax
movq 0x10(%rax), %rax
movq %rax, -0x38(%rbp)
cmpq $-0x1, %rax
setne %al
movb %al, -0x39(%rbp)
movb -0x39(%rbp), %al
testb $0x1, %al
jne 0x9ea69
jmp 0x9ec13
jmp 0x9ea6b
movq -0x38(%rbp), %rax
movq -0x10(%rbp), %rcx
movq 0x70(%rcx), %rcx
movq 0x8(%rcx), %rcx
movq %rcx, -0x28(%rbp)
cmpq 0x10(%rcx), %rax
jne 0x9eadc
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rsi
xorl %eax, %eax
movl %eax, %edx
callq 0x9ec50
cmpl $0x0, %eax
setne %al
andb $0x1, %al
movzbl %al, %eax
cltq
cmpq $0x0, %rax
je 0x9eab9
callq 0xf60c0
movl $0x80, (%rax)
jmp 0x9ec2c
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rsi
xorl %edx, %edx
callq 0x9efc0
movq -0x10(%rbp), %rdi
addq $0x70, %rdi
movl $0x1, %esi
callq 0xf75b0
jmp 0x9ea6b
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rax
cmpq -0x38(%rbp), %rax
jne 0x9ec0e
movq -0x20(%rbp), %rax
movss 0x2c(%rax), %xmm0
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm0
jbe 0x9ec0e
movq -0x20(%rbp), %rax
movl 0x40(%rax), %eax
movq -0x20(%rbp), %rcx
movl 0x48(%rcx), %ecx
movq -0x20(%rbp), %rdx
subl 0x4c(%rdx), %ecx
cmpl %ecx, %eax
jb 0x9ec0e
movq -0x20(%rbp), %rax
cmpl $0x0, 0x44(%rax)
jne 0x9ec0e
movq -0x10(%rbp), %rax
cmpq $0x0, 0xa0(%rax)
je 0x9eb7b
movq -0x10(%rbp), %rdi
addq $0xa0, %rdi
movq -0x10(%rbp), %rax
movq 0x2d0(%rax), %rcx
leaq -0x38(%rbp), %rsi
xorl %edx, %edx
callq 0xfa790
movl 0x10(%rax), %eax
andl $0x7fffffff, %eax # imm = 0x7FFFFFFF
cmpl $0x1, %eax
jle 0x9eb7b
jmp 0x9ea2d
movq -0x38(%rbp), %rcx
movq -0x30(%rbp), %rax
movq %rcx, 0x170(%rax)
movq -0x30(%rbp), %rax
movl 0x1d0(%rax), %ecx
andl $0x401, %ecx # imm = 0x401
movl %ecx, 0x1d0(%rax)
movq -0x30(%rbp), %rax
movq 0x140(%rax), %rax
movq -0x30(%rbp), %rdi
movq -0x38(%rbp), %rsi
movq -0x18(%rbp), %rdx
callq *%rax
cmpl $0x0, %eax
jne 0x9ec0c
movq -0x30(%rbp), %rax
movl 0x1d0(%rax), %ecx
orl $0x2, %ecx
movl %ecx, 0x1d0(%rax)
movq -0x10(%rbp), %rax
movzbl 0x344(%rax), %eax
cmpl $0x0, %eax
je 0x9ebff
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
xorl %edx, %edx
callq 0x9f070
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm0
jne 0x9ebff
jp 0x9ebff
jmp 0x9ea2d
callq 0xf60c0
movl $0x0, (%rax)
jmp 0x9ec2c
jmp 0x9ec2c
jmp 0x9ea2d
movq -0x10(%rbp), %rax
movl $0x3, 0x348(%rax)
callq 0xf60c0
movl $0x89, (%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x78(%rax)
callq 0xf60c0
movl (%rax), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| ft_boolean_read_next:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov rax, [rbp+var_10]
mov rax, [rax+8]
mov [rbp+var_30], rax
mov rax, [rbp+var_10]
cmp dword ptr [rax+348h], 2
jz short loc_9E9B2
mov rax, [rbp+var_10]
cmp dword ptr [rax+348h], 3
jz short loc_9E9B2
mov [rbp+var_4], 0FFFFFFFFh
jmp loc_9EC42
loc_9E9B2:
mov rdi, [rbp+var_30]
mov rax, [rbp+var_10]
mov esi, [rax+340h]
call _mi_check_index
cmp eax, 0
jge short loc_9E9D9
call _my_thread_var
mov eax, [rax]
mov [rbp+var_4], eax
jmp loc_9EC42
loc_9E9D9:
mov rdi, [rbp+var_30]
xor esi, esi
mov edx, 1
call _mi_readinfo
cmp eax, 0
jz short loc_9E9FD
call _my_thread_var
mov eax, [rax]
mov [rbp+var_4], eax
jmp loc_9EC42
loc_9E9FD:
mov rax, [rbp+var_10]
cmp dword ptr [rax+80h], 0
jnz short loc_9EA21
call _my_thread_var
mov dword ptr [rax], 89h
mov [rbp+var_4], 89h
jmp loc_9EC42
loc_9EA21:
mov rax, [rbp+var_10]
lea rcx, [rbp+var_38]
mov [rax+78h], rcx
loc_9EA2D:
mov rcx, [rbp+var_10]
xor eax, eax
cmp dword ptr [rcx+348h], 2
mov [rbp+var_39], al
jnz short loc_9EA5D
mov rax, [rbp+var_10]
mov rax, [rax+70h]
mov rax, [rax+8]
mov rax, [rax+10h]
mov [rbp+var_38], rax
cmp rax, 0FFFFFFFFFFFFFFFFh
setnz al
mov [rbp+var_39], al
loc_9EA5D:
mov al, [rbp+var_39]
test al, 1
jnz short loc_9EA69
jmp loc_9EC13
loc_9EA69:
jmp short $+2
loc_9EA6B:
mov rax, [rbp+var_38]
mov rcx, [rbp+var_10]
mov rcx, [rcx+70h]
mov rcx, [rcx+8]
mov [rbp+var_28], rcx
cmp rax, [rcx+10h]
jnz short loc_9EADC
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_28]
xor eax, eax
mov edx, eax
call _ftb_climb_the_tree
cmp eax, 0
setnz al
and al, 1
movzx eax, al
cdqe
cmp rax, 0
jz short loc_9EAB9
call _my_thread_var
mov dword ptr [rax], 80h
jmp loc_9EC2C
loc_9EAB9:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_28]
xor edx, edx
call _ft2_search
mov rdi, [rbp+var_10]
add rdi, 70h ; 'p'
mov esi, 1
call _downheap
jmp short loc_9EA6B
loc_9EADC:
mov rax, [rbp+var_10]
mov rax, [rax+18h]
mov [rbp+var_20], rax
mov rax, [rbp+var_20]
mov rax, [rax+10h]
cmp rax, [rbp+var_38]
jnz loc_9EC0E
mov rax, [rbp+var_20]
movss xmm0, dword ptr [rax+2Ch]
xorps xmm1, xmm1
ucomiss xmm0, xmm1
jbe loc_9EC0E
mov rax, [rbp+var_20]
mov eax, [rax+40h]
mov rcx, [rbp+var_20]
mov ecx, [rcx+48h]
mov rdx, [rbp+var_20]
sub ecx, [rdx+4Ch]
cmp eax, ecx
jb loc_9EC0E
mov rax, [rbp+var_20]
cmp dword ptr [rax+44h], 0
jnz loc_9EC0E
mov rax, [rbp+var_10]
cmp qword ptr [rax+0A0h], 0
jz short loc_9EB7B
mov rdi, [rbp+var_10]
add rdi, 0A0h
mov rax, [rbp+var_10]
mov rcx, [rax+2D0h]
lea rsi, [rbp+var_38]
xor edx, edx
call tree_insert
mov eax, [rax+10h]
and eax, 7FFFFFFFh
cmp eax, 1
jle short loc_9EB7B
jmp loc_9EA2D
loc_9EB7B:
mov rcx, [rbp+var_38]
mov rax, [rbp+var_30]
mov [rax+170h], rcx
mov rax, [rbp+var_30]
mov ecx, [rax+1D0h]
and ecx, 401h
mov [rax+1D0h], ecx
mov rax, [rbp+var_30]
mov rax, [rax+140h]
mov rdi, [rbp+var_30]
mov rsi, [rbp+var_38]
mov rdx, [rbp+var_18]
call rax
cmp eax, 0
jnz short loc_9EC0C
mov rax, [rbp+var_30]
mov ecx, [rax+1D0h]
or ecx, 2
mov [rax+1D0h], ecx
mov rax, [rbp+var_10]
movzx eax, byte ptr [rax+344h]
cmp eax, 0
jz short loc_9EBFF
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
xor edx, edx
call ft_boolean_find_relevance
xorps xmm1, xmm1
ucomiss xmm0, xmm1
jnz short loc_9EBFF
jp short loc_9EBFF
jmp loc_9EA2D
loc_9EBFF:
call _my_thread_var
mov dword ptr [rax], 0
jmp short loc_9EC2C
loc_9EC0C:
jmp short loc_9EC2C
loc_9EC0E:
jmp loc_9EA2D
loc_9EC13:
mov rax, [rbp+var_10]
mov dword ptr [rax+348h], 3
call _my_thread_var
mov dword ptr [rax], 89h
loc_9EC2C:
mov rax, [rbp+var_10]
mov qword ptr [rax+78h], 0
call _my_thread_var
mov eax, [rax]
mov [rbp+var_4], eax
loc_9EC42:
mov eax, [rbp+var_4]
add rsp, 40h
pop rbp
retn
| long long ft_boolean_read_next(long long a1, const char *a2)
{
long long v2; // rdi
const char *v3; // rsi
bool v5; // [rsp+7h] [rbp-39h]
const char *v6; // [rsp+8h] [rbp-38h] BYREF
long long v7; // [rsp+10h] [rbp-30h]
long long v8; // [rsp+18h] [rbp-28h]
long long v9; // [rsp+20h] [rbp-20h]
const char *v10; // [rsp+28h] [rbp-18h]
long long v11; // [rsp+30h] [rbp-10h]
v11 = a1;
v10 = a2;
v7 = *(_QWORD *)(a1 + 8);
if ( *(_DWORD *)(a1 + 840) == 2 || *(_DWORD *)(v11 + 840) == 3 )
{
v2 = v7;
v3 = (const char *)*(unsigned int *)(v11 + 832);
if ( (int)mi_check_index(v7, v3) < 0 )
return *(unsigned int *)my_thread_var(v2, v3);
v2 = v7;
v3 = 0LL;
if ( (unsigned int)mi_readinfo(v7, 0LL, 1LL) )
{
return *(unsigned int *)my_thread_var(v2, v3);
}
else if ( *(_DWORD *)(v11 + 128) )
{
*(_QWORD *)(v11 + 120) = &v6;
while ( 1 )
{
v5 = 0;
if ( *(_DWORD *)(v11 + 840) == 2 )
{
v6 = *(const char **)(*(_QWORD *)(*(_QWORD *)(v11 + 112) + 8LL) + 16LL);
v5 = v6 + 1 != 0LL;
}
if ( !v5 )
break;
while ( 1 )
{
v8 = *(_QWORD *)(*(_QWORD *)(v11 + 112) + 8LL);
if ( v6 != *(const char **)(v8 + 16) )
break;
v2 = v11;
v3 = (const char *)v8;
if ( (unsigned int)ftb_climb_the_tree(v11, v8, 0LL) )
{
*(_DWORD *)my_thread_var(v2, v3) = 128;
goto LABEL_30;
}
ft2_search(v11, v8, 0LL);
v2 = v11 + 112;
v3 = (_BYTE *)(&dword_0 + 1);
downheap(v11 + 112, 1LL);
}
v9 = *(_QWORD *)(v11 + 24);
if ( *(const char **)(v9 + 16) == v6
&& *(float *)(v9 + 44) > 0.0
&& *(_DWORD *)(v9 + 64) >= (unsigned int)(*(_DWORD *)(v9 + 72) - *(_DWORD *)(v9 + 76))
&& !*(_DWORD *)(v9 + 68) )
{
if ( !*(_QWORD *)(v11 + 160)
|| (v2 = v11 + 160,
v3 = (const char *)&v6,
(*(_DWORD *)(tree_insert(v11 + 160, &v6, 0LL, *(_QWORD *)(v11 + 720)) + 16) & 0x7FFFFFFFu) <= 1) )
{
*(_QWORD *)(v7 + 368) = v6;
*(_DWORD *)(v7 + 464) &= 0x401u;
v2 = v7;
v3 = v6;
if ( (*(unsigned int ( **)(long long, const char *, const char *))(v7 + 320))(v7, v6, v10) )
goto LABEL_30;
*(_DWORD *)(v7 + 464) |= 2u;
if ( !*(_BYTE *)(v11 + 836) || (v2 = v11, v3 = v10, ft_boolean_find_relevance(v11, v10, 0LL) != 0.0) )
{
*(_DWORD *)my_thread_var(v2, v3) = 0;
goto LABEL_30;
}
}
}
}
*(_DWORD *)(v11 + 840) = 3;
*(_DWORD *)my_thread_var(v2, v3) = 137;
LABEL_30:
*(_QWORD *)(v11 + 120) = 0LL;
return *(unsigned int *)my_thread_var(v2, v3);
}
else
{
*(_DWORD *)my_thread_var(v7, 0LL) = 137;
return 137;
}
}
else
{
return (unsigned int)-1;
}
}
| ft_boolean_read_next:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x348],0x2
JZ 0x0019e9b2
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x348],0x3
JZ 0x0019e9b2
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x0019ec42
LAB_0019e9b2:
MOV RDI,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RAX + 0x340]
CALL 0x001be6c0
CMP EAX,0x0
JGE 0x0019e9d9
CALL 0x001f60c0
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0019ec42
LAB_0019e9d9:
MOV RDI,qword ptr [RBP + -0x30]
XOR ESI,ESI
MOV EDX,0x1
CALL 0x001b10f0
CMP EAX,0x0
JZ 0x0019e9fd
CALL 0x001f60c0
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0019ec42
LAB_0019e9fd:
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x80],0x0
JNZ 0x0019ea21
CALL 0x001f60c0
MOV dword ptr [RAX],0x89
MOV dword ptr [RBP + -0x4],0x89
JMP 0x0019ec42
LAB_0019ea21:
MOV RAX,qword ptr [RBP + -0x10]
LEA RCX,[RBP + -0x38]
MOV qword ptr [RAX + 0x78],RCX
LAB_0019ea2d:
MOV RCX,qword ptr [RBP + -0x10]
XOR EAX,EAX
CMP dword ptr [RCX + 0x348],0x2
MOV byte ptr [RBP + -0x39],AL
JNZ 0x0019ea5d
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x70]
MOV RAX,qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RAX + 0x10]
MOV qword ptr [RBP + -0x38],RAX
CMP RAX,-0x1
SETNZ AL
MOV byte ptr [RBP + -0x39],AL
LAB_0019ea5d:
MOV AL,byte ptr [RBP + -0x39]
TEST AL,0x1
JNZ 0x0019ea69
JMP 0x0019ec13
LAB_0019ea69:
JMP 0x0019ea6b
LAB_0019ea6b:
MOV RAX,qword ptr [RBP + -0x38]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x70]
MOV RCX,qword ptr [RCX + 0x8]
MOV qword ptr [RBP + -0x28],RCX
CMP RAX,qword ptr [RCX + 0x10]
JNZ 0x0019eadc
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x28]
XOR EAX,EAX
MOV EDX,EAX
CALL 0x0019ec50
CMP EAX,0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
CDQE
CMP RAX,0x0
JZ 0x0019eab9
CALL 0x001f60c0
MOV dword ptr [RAX],0x80
JMP 0x0019ec2c
LAB_0019eab9:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x28]
XOR EDX,EDX
CALL 0x0019efc0
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x70
MOV ESI,0x1
CALL 0x001f75b0
JMP 0x0019ea6b
LAB_0019eadc:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x18]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RAX + 0x10]
CMP RAX,qword ptr [RBP + -0x38]
JNZ 0x0019ec0e
MOV RAX,qword ptr [RBP + -0x20]
MOVSS XMM0,dword ptr [RAX + 0x2c]
XORPS XMM1,XMM1
UCOMISS XMM0,XMM1
JBE 0x0019ec0e
MOV RAX,qword ptr [RBP + -0x20]
MOV EAX,dword ptr [RAX + 0x40]
MOV RCX,qword ptr [RBP + -0x20]
MOV ECX,dword ptr [RCX + 0x48]
MOV RDX,qword ptr [RBP + -0x20]
SUB ECX,dword ptr [RDX + 0x4c]
CMP EAX,ECX
JC 0x0019ec0e
MOV RAX,qword ptr [RBP + -0x20]
CMP dword ptr [RAX + 0x44],0x0
JNZ 0x0019ec0e
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0xa0],0x0
JZ 0x0019eb7b
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0xa0
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX + 0x2d0]
LEA RSI,[RBP + -0x38]
XOR EDX,EDX
CALL 0x001fa790
MOV EAX,dword ptr [RAX + 0x10]
AND EAX,0x7fffffff
CMP EAX,0x1
JLE 0x0019eb7b
JMP 0x0019ea2d
LAB_0019eb7b:
MOV RCX,qword ptr [RBP + -0x38]
MOV RAX,qword ptr [RBP + -0x30]
MOV qword ptr [RAX + 0x170],RCX
MOV RAX,qword ptr [RBP + -0x30]
MOV ECX,dword ptr [RAX + 0x1d0]
AND ECX,0x401
MOV dword ptr [RAX + 0x1d0],ECX
MOV RAX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RAX + 0x140]
MOV RDI,qword ptr [RBP + -0x30]
MOV RSI,qword ptr [RBP + -0x38]
MOV RDX,qword ptr [RBP + -0x18]
CALL RAX
CMP EAX,0x0
JNZ 0x0019ec0c
MOV RAX,qword ptr [RBP + -0x30]
MOV ECX,dword ptr [RAX + 0x1d0]
OR ECX,0x2
MOV dword ptr [RAX + 0x1d0],ECX
MOV RAX,qword ptr [RBP + -0x10]
MOVZX EAX,byte ptr [RAX + 0x344]
CMP EAX,0x0
JZ 0x0019ebff
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
XOR EDX,EDX
CALL 0x0019f070
XORPS XMM1,XMM1
UCOMISS XMM0,XMM1
JNZ 0x0019ebff
JP 0x0019ebff
JMP 0x0019ea2d
LAB_0019ebff:
CALL 0x001f60c0
MOV dword ptr [RAX],0x0
JMP 0x0019ec2c
LAB_0019ec0c:
JMP 0x0019ec2c
LAB_0019ec0e:
JMP 0x0019ea2d
LAB_0019ec13:
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x348],0x3
CALL 0x001f60c0
MOV dword ptr [RAX],0x89
LAB_0019ec2c:
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x78],0x0
CALL 0x001f60c0
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x4],EAX
LAB_0019ec42:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x40
POP RBP
RET
|
int4 ft_boolean_read_next(long param_1,int8 param_2)
{
int iVar1;
int4 *puVar2;
long lVar3;
bool bVar4;
float fVar5;
long local_40;
long local_38;
long local_30;
long local_28;
int8 local_20;
long local_18;
int4 local_c;
local_38 = *(long *)(param_1 + 8);
if ((*(int *)(param_1 + 0x348) == 2) || (*(int *)(param_1 + 0x348) == 3)) {
local_20 = param_2;
local_18 = param_1;
iVar1 = _mi_check_index(local_38,*(int4 *)(param_1 + 0x340));
if (iVar1 < 0) {
puVar2 = (int4 *)_my_thread_var();
local_c = *puVar2;
}
else {
iVar1 = _mi_readinfo(local_38,0,1);
if (iVar1 == 0) {
if (*(int *)(local_18 + 0x80) == 0) {
puVar2 = (int4 *)_my_thread_var();
*puVar2 = 0x89;
local_c = 0x89;
}
else {
*(long **)(local_18 + 0x78) = &local_40;
while( true ) {
do {
bVar4 = false;
if (*(int *)(local_18 + 0x348) == 2) {
local_40 = *(long *)(*(long *)(*(long *)(local_18 + 0x70) + 8) + 0x10);
bVar4 = local_40 != -1;
}
if (!bVar4) {
*(int4 *)(local_18 + 0x348) = 3;
puVar2 = (int4 *)_my_thread_var();
*puVar2 = 0x89;
goto LAB_0019ec2c;
}
while (local_30 = *(long *)(*(long *)(local_18 + 0x70) + 8),
local_40 == *(long *)(local_30 + 0x10)) {
iVar1 = _ftb_climb_the_tree(local_18,local_30,0);
if (iVar1 != 0) {
puVar2 = (int4 *)_my_thread_var();
*puVar2 = 0x80;
goto LAB_0019ec2c;
}
_ft2_search(local_18,local_30,0);
_downheap(local_18 + 0x70,1);
}
local_28 = *(long *)(local_18 + 0x18);
} while (((((*(long *)(local_28 + 0x10) != local_40) ||
(*(float *)(local_28 + 0x2c) <= 0.0)) ||
(*(uint *)(local_28 + 0x40) <
(uint)(*(int *)(local_28 + 0x48) - *(int *)(local_28 + 0x4c)))) ||
(*(int *)(local_28 + 0x44) != 0)) ||
((*(long *)(local_18 + 0xa0) != 0 &&
(lVar3 = tree_insert(local_18 + 0xa0,&local_40,0,
*(int8 *)(local_18 + 0x2d0)),
1 < (*(uint *)(lVar3 + 0x10) & 0x7fffffff)))));
*(long *)(local_38 + 0x170) = local_40;
*(uint *)(local_38 + 0x1d0) = *(uint *)(local_38 + 0x1d0) & 0x401;
iVar1 = (**(code **)(local_38 + 0x140))(local_38,local_40,local_20);
if (iVar1 != 0) goto LAB_0019ec2c;
*(uint *)(local_38 + 0x1d0) = *(uint *)(local_38 + 0x1d0) | 2;
if (*(char *)(local_18 + 0x344) == '\0') break;
fVar5 = (float)ft_boolean_find_relevance(local_18,local_20,0);
if ((fVar5 != 0.0) || (NAN(fVar5))) break;
}
puVar2 = (int4 *)_my_thread_var();
*puVar2 = 0;
LAB_0019ec2c:
*(int8 *)(local_18 + 0x78) = 0;
puVar2 = (int4 *)_my_thread_var();
local_c = *puVar2;
}
}
else {
puVar2 = (int4 *)_my_thread_var();
local_c = *puVar2;
}
}
}
else {
local_c = 0xffffffff;
}
return local_c;
}
| |
38,015 | mi_log | eloqsql/storage/myisam/mi_log.c | int mi_log(int activate_log)
{
int error=0;
char buff[FN_REFLEN];
DBUG_ENTER("mi_log");
log_type=activate_log;
if (activate_log)
{
if (!myisam_pid)
myisam_pid=(ulong) getpid();
if (myisam_log_file < 0)
{
if ((myisam_log_file= mysql_file_create(mi_key_file_log,
fn_format(buff,
myisam_log_filename,
"", ".log", 4),
0,
(O_RDWR | O_BINARY | O_APPEND),
MYF(0))) < 0)
DBUG_RETURN(my_errno);
}
}
else if (myisam_log_file >= 0)
{
error= mysql_file_close(myisam_log_file, MYF(0)) ? my_errno : 0 ;
myisam_log_file= -1;
}
DBUG_RETURN(error);
} | O0 | c | mi_log:
pushq %rbp
movq %rsp, %rbp
subq $0x230, %rsp # imm = 0x230
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movl %edi, -0x218(%rbp)
movl $0x0, -0x21c(%rbp)
movl -0x218(%rbp), %eax
movl %eax, 0xbc8d64(%rip) # 0xc7b8a8
cmpl $0x0, -0x218(%rbp)
je 0xb2c02
cmpq $0x0, 0xbc8d47(%rip) # 0xc7b8a0
jne 0xb2b69
callq 0x2a8b0
cltq
movq %rax, 0xbc8d37(%rip) # 0xc7b8a0
leaq 0x20d6e0(%rip), %rax # 0x2c0250
cmpl $0x0, (%rax)
jge 0xb2c00
leaq 0xbc8d00(%rip), %rax # 0xc7b880
movl (%rax), %eax
movl %eax, -0x220(%rbp)
leaq -0x210(%rbp), %rdi
leaq 0x20d6b2(%rip), %rax # 0x2c0248
movq (%rax), %rsi
leaq 0xa63ed(%rip), %rdx # 0x158f8d
leaq 0xa1ea6(%rip), %rcx # 0x154a4d
movl $0x4, %r8d
callq 0xe0b40
movl -0x220(%rbp), %edi
movq %rax, %rcx
leaq 0xa225e(%rip), %rsi # 0x154e20
movl $0x35, %edx
xorl %r8d, %r8d
movl $0x402, %r9d # imm = 0x402
xorl %eax, %eax
movq $0x0, (%rsp)
callq 0xb2cb0
leaq 0x20d66a(%rip), %rcx # 0x2c0250
movl %eax, (%rcx)
cmpl $0x0, %eax
jge 0xb2bfe
jmp 0xb2bef
callq 0xf7440
movl (%rax), %eax
movl %eax, -0x214(%rbp)
jmp 0xb2c73
jmp 0xb2c00
jmp 0xb2c65
leaq 0x20d647(%rip), %rax # 0x2c0250
cmpl $0x0, (%rax)
jl 0xb2c63
leaq 0x20d63b(%rip), %rax # 0x2c0250
movl (%rax), %edx
leaq 0xa2202(%rip), %rdi # 0x154e20
movl $0x3b, %esi
xorl %eax, %eax
movl %eax, %ecx
callq 0xb2da0
cmpl $0x0, %eax
je 0xb2c40
callq 0xf7440
movl (%rax), %eax
movl %eax, -0x224(%rbp)
jmp 0xb2c4a
xorl %eax, %eax
movl %eax, -0x224(%rbp)
jmp 0xb2c4a
movl -0x224(%rbp), %eax
movl %eax, -0x21c(%rbp)
leaq 0x20d5f3(%rip), %rax # 0x2c0250
movl $0xffffffff, (%rax) # imm = 0xFFFFFFFF
jmp 0xb2c65
jmp 0xb2c67
movl -0x21c(%rbp), %eax
movl %eax, -0x214(%rbp)
movl -0x214(%rbp), %eax
movl %eax, -0x228(%rbp)
movq %fs:0x28, %rax
movq -0x8(%rbp), %rcx
cmpq %rcx, %rax
jne 0xb2ca0
movl -0x228(%rbp), %eax
addq $0x230, %rsp # imm = 0x230
popq %rbp
retq
callq 0x2a270
nopw %cs:(%rax,%rax)
| mi_log:
push rbp
mov rbp, rsp
sub rsp, 230h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_218], edi
mov [rbp+var_21C], 0
mov eax, [rbp+var_218]
mov cs:log_type, eax
cmp [rbp+var_218], 0
jz loc_B2C02
cmp cs:myisam_pid, 0
jnz short loc_B2B69
call _getpid
cdqe
mov cs:myisam_pid, rax
loc_B2B69:
lea rax, myisam_log_file
cmp dword ptr [rax], 0
jge loc_B2C00
lea rax, mi_key_file_log
mov eax, [rax]
mov [rbp+var_220], eax
lea rdi, [rbp+var_210]
lea rax, myisam_log_filename
mov rsi, [rax]
lea rdx, asc_158F89+4; ""
lea rcx, aMyisamLog+6; ".log"
mov r8d, 4
call fn_format
mov edi, [rbp+var_220]
mov rcx, rax
lea rsi, aWorkspaceLlm4b_28; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 35h ; '5'
xor r8d, r8d
mov r9d, 402h
xor eax, eax
mov [rsp+230h+var_230], 0
call inline_mysql_file_create_1
lea rcx, myisam_log_file
mov [rcx], eax
cmp eax, 0
jge short loc_B2BFE
jmp short $+2
loc_B2BEF:
call _my_thread_var
mov eax, [rax]
mov [rbp+var_214], eax
jmp short loc_B2C73
loc_B2BFE:
jmp short $+2
loc_B2C00:
jmp short loc_B2C65
loc_B2C02:
lea rax, myisam_log_file
cmp dword ptr [rax], 0
jl short loc_B2C63
lea rax, myisam_log_file
mov edx, [rax]
lea rdi, aWorkspaceLlm4b_28; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, 3Bh ; ';'
xor eax, eax
mov ecx, eax
call inline_mysql_file_close_5
cmp eax, 0
jz short loc_B2C40
call _my_thread_var
mov eax, [rax]
mov [rbp+var_224], eax
jmp short loc_B2C4A
loc_B2C40:
xor eax, eax
mov [rbp+var_224], eax
jmp short $+2
loc_B2C4A:
mov eax, [rbp+var_224]
mov [rbp+var_21C], eax
lea rax, myisam_log_file
mov dword ptr [rax], 0FFFFFFFFh
loc_B2C63:
jmp short $+2
loc_B2C65:
jmp short $+2
loc_B2C67:
mov eax, [rbp+var_21C]
mov [rbp+var_214], eax
loc_B2C73:
mov eax, [rbp+var_214]
mov [rbp+var_228], eax
mov rax, fs:28h
mov rcx, [rbp+var_8]
cmp rax, rcx
jnz short loc_B2CA0
mov eax, [rbp+var_228]
add rsp, 230h
pop rbp
retn
loc_B2CA0:
call ___stack_chk_fail
| long long mi_log(int a1)
{
int v1; // eax
unsigned int v3; // [rsp+Ch] [rbp-224h]
unsigned int v4; // [rsp+10h] [rbp-220h]
unsigned int v5; // [rsp+14h] [rbp-21Ch]
_BYTE v7[520]; // [rsp+20h] [rbp-210h] BYREF
unsigned long long v8; // [rsp+228h] [rbp-8h]
v8 = __readfsqword(0x28u);
v5 = 0;
log_type = a1;
if ( !a1 )
{
if ( (myisam_log_file & 0x80000000) == 0 )
{
if ( (unsigned int)inline_mysql_file_close_5(
"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_log.c",
59LL,
myisam_log_file,
0LL) )
v3 = *(_DWORD *)my_thread_var(
"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_log.c",
(_BYTE *)&word_3A + 1);
else
v3 = 0;
v5 = v3;
myisam_log_file = -1;
}
return v5;
}
if ( !myisam_pid )
myisam_pid = (int)getpid();
if ( (myisam_log_file & 0x80000000) == 0 )
return v5;
v4 = mi_key_file_log;
v1 = fn_format(v7, myisam_log_filename, "", ".log", 4LL);
myisam_log_file = inline_mysql_file_create_1(
v4,
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_log.c",
53,
v1,
0,
1026,
0LL);
if ( (myisam_log_file & 0x80000000) == 0 )
return v5;
return *(unsigned int *)my_thread_var(v4, "/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_log.c");
}
| mi_log:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x230
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV dword ptr [RBP + -0x218],EDI
MOV dword ptr [RBP + -0x21c],0x0
MOV EAX,dword ptr [RBP + -0x218]
MOV dword ptr [0x00d7b8a8],EAX
CMP dword ptr [RBP + -0x218],0x0
JZ 0x001b2c02
CMP qword ptr [0x00d7b8a0],0x0
JNZ 0x001b2b69
CALL 0x0012a8b0
CDQE
MOV qword ptr [0x00d7b8a0],RAX
LAB_001b2b69:
LEA RAX,[0x3c0250]
CMP dword ptr [RAX],0x0
JGE 0x001b2c00
LEA RAX,[0xd7b880]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x220],EAX
LEA RDI,[RBP + -0x210]
LEA RAX,[0x3c0248]
MOV RSI,qword ptr [RAX]
LEA RDX,[0x258f8d]
LEA RCX,[0x254a4d]
MOV R8D,0x4
CALL 0x001e0b40
MOV EDI,dword ptr [RBP + -0x220]
MOV RCX,RAX
LEA RSI,[0x254e20]
MOV EDX,0x35
XOR R8D,R8D
MOV R9D,0x402
XOR EAX,EAX
MOV qword ptr [RSP],0x0
CALL 0x001b2cb0
LEA RCX,[0x3c0250]
MOV dword ptr [RCX],EAX
CMP EAX,0x0
JGE 0x001b2bfe
JMP 0x001b2bef
LAB_001b2bef:
CALL 0x001f7440
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x214],EAX
JMP 0x001b2c73
LAB_001b2bfe:
JMP 0x001b2c00
LAB_001b2c00:
JMP 0x001b2c65
LAB_001b2c02:
LEA RAX,[0x3c0250]
CMP dword ptr [RAX],0x0
JL 0x001b2c63
LEA RAX,[0x3c0250]
MOV EDX,dword ptr [RAX]
LEA RDI,[0x254e20]
MOV ESI,0x3b
XOR EAX,EAX
MOV ECX,EAX
CALL 0x001b2da0
CMP EAX,0x0
JZ 0x001b2c40
CALL 0x001f7440
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x224],EAX
JMP 0x001b2c4a
LAB_001b2c40:
XOR EAX,EAX
MOV dword ptr [RBP + -0x224],EAX
JMP 0x001b2c4a
LAB_001b2c4a:
MOV EAX,dword ptr [RBP + -0x224]
MOV dword ptr [RBP + -0x21c],EAX
LEA RAX,[0x3c0250]
MOV dword ptr [RAX],0xffffffff
LAB_001b2c63:
JMP 0x001b2c65
LAB_001b2c65:
JMP 0x001b2c67
LAB_001b2c67:
MOV EAX,dword ptr [RBP + -0x21c]
MOV dword ptr [RBP + -0x214],EAX
LAB_001b2c73:
MOV EAX,dword ptr [RBP + -0x214]
MOV dword ptr [RBP + -0x228],EAX
MOV RAX,qword ptr FS:[0x28]
MOV RCX,qword ptr [RBP + -0x8]
CMP RAX,RCX
JNZ 0x001b2ca0
MOV EAX,dword ptr [RBP + -0x228]
ADD RSP,0x230
POP RBP
RET
LAB_001b2ca0:
CALL 0x0012a270
|
int4 mi_log(int param_1)
{
int4 uVar1;
__pid_t _Var2;
int iVar3;
int8 uVar4;
int4 *puVar5;
long in_FS_OFFSET;
int4 local_22c;
int4 local_224;
int4 local_21c;
int1 local_218 [520];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
local_224 = 0;
log_type = param_1;
if (param_1 == 0) {
if (-1 < myisam_log_file) {
iVar3 = inline_mysql_file_close
("/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_log.c",0x3b,
myisam_log_file,0);
if (iVar3 == 0) {
local_22c = 0;
}
else {
puVar5 = (int4 *)_my_thread_var();
local_22c = *puVar5;
}
local_224 = local_22c;
myisam_log_file = -1;
}
}
else {
if (myisam_pid == 0) {
_Var2 = getpid();
myisam_pid = (long)_Var2;
}
uVar1 = mi_key_file_log;
if (myisam_log_file < 0) {
uVar4 = fn_format(local_218,myisam_log_filename,&DAT_00258f8d,".log",4);
myisam_log_file =
inline_mysql_file_create
(uVar1,"/workspace/llm4binary/github2025/eloqsql/storage/myisam/mi_log.c",0x35,
uVar4,0,0x402,0);
if (myisam_log_file < 0) {
puVar5 = (int4 *)_my_thread_var();
local_21c = *puVar5;
goto LAB_001b2c73;
}
}
}
local_21c = local_224;
LAB_001b2c73:
if (*(long *)(in_FS_OFFSET + 0x28) != local_10) {
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
return local_21c;
}
| |
38,016 | common_sampler_clone(common_sampler*) | monkey531[P]llama/common/sampling.cpp | struct common_sampler * common_sampler_clone(common_sampler * gsmpl) {
return new common_sampler {
/* .params = */ gsmpl->params,
/* .grmr = */ llama_sampler_clone(gsmpl->grmr),
/* .chain = */ llama_sampler_clone(gsmpl->chain),
/* .prev = */ gsmpl->prev,
/* .cur = */ gsmpl->cur,
/* .cur_p = */ gsmpl->cur_p,
};
} | O1 | cpp | common_sampler_clone(common_sampler*):
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %r14
movl $0x1b8, %edi # imm = 0x1B8
callq 0x1b8c0
movq %rax, %rbx
movq %rax, %rdi
movq %r14, %rsi
callq 0x55552
movq 0x138(%r14), %rdi
callq 0x1b620
movq %rax, 0x138(%rbx)
movq 0x140(%r14), %rdi
callq 0x1b620
movq %rax, 0x140(%rbx)
movups 0x148(%r14), %xmm0
movups 0x158(%r14), %xmm1
movups %xmm0, 0x148(%rbx)
movups %xmm1, 0x158(%rbx)
movl $0x168, %esi # imm = 0x168
leaq (%rbx,%rsi), %r15
addq %r14, %rsi
movq %r15, %rdi
callq 0x23a70
movl $0x180, %esi # imm = 0x180
movq %rbx, %rdi
addq %rsi, %rdi
addq %r14, %rsi
callq 0xd0914
movups 0x198(%r14), %xmm0
movups 0x1a8(%r14), %xmm1
movups %xmm1, 0x1a8(%rbx)
movups %xmm0, 0x198(%rbx)
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
movq (%r15), %rdi
testq %rdi, %rdi
je 0xcf7be
movq 0x178(%rbx), %rsi
subq %rdi, %rsi
callq 0x1b8e0
jmp 0xcf7be
movq %rax, %r14
jmp 0xcf7c6
movq %rax, %r14
movq %rbx, %rdi
callq 0x2301e
movl $0x1b8, %esi # imm = 0x1B8
movq %rbx, %rdi
callq 0x1b8e0
movq %r14, %rdi
callq 0x1bf90
| _Z20common_sampler_cloneP14common_sampler:
push r15
push r14
push rbx
mov r14, rdi
mov edi, 1B8h; unsigned __int64
call __Znwm; operator new(ulong)
mov rbx, rax
mov rdi, rax; this
mov rsi, r14; common_params_sampling *
call _ZN22common_params_samplingC2ERKS_; common_params_sampling::common_params_sampling(common_params_sampling const&)
mov rdi, [r14+138h]
call _llama_sampler_clone
mov [rbx+138h], rax
mov rdi, [r14+140h]
call _llama_sampler_clone
mov [rbx+140h], rax
movups xmm0, xmmword ptr [r14+148h]
movups xmm1, xmmword ptr [r14+158h]
movups xmmword ptr [rbx+148h], xmm0
movups xmmword ptr [rbx+158h], xmm1
mov esi, 168h
lea r15, [rbx+rsi]
add rsi, r14
mov rdi, r15
call _ZNSt6vectorIiSaIiEEC2ERKS1_; std::vector<int>::vector(std::vector<int> const&)
mov esi, 180h
mov rdi, rbx
add rdi, rsi
add rsi, r14
call _ZNSt6vectorI16llama_token_dataSaIS0_EEC2ERKS2_; std::vector<llama_token_data>::vector(std::vector<llama_token_data> const&)
movups xmm0, xmmword ptr [r14+198h]
movups xmm1, xmmword ptr [r14+1A8h]
movups xmmword ptr [rbx+1A8h], xmm1
movups xmmword ptr [rbx+198h], xmm0
mov rax, rbx
pop rbx
pop r14
pop r15
retn
mov r14, rax
mov rdi, [r15]; void *
test rdi, rdi
jz short loc_CF7BE
mov rsi, [rbx+178h]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_CF7BE
mov r14, rax
jmp short loc_CF7C6
mov r14, rax
loc_CF7BE:
mov rdi, rbx; this
call _ZN22common_params_samplingD2Ev; common_params_sampling::~common_params_sampling()
loc_CF7C6:
mov esi, 1B8h; unsigned __int64
mov rdi, rbx; void *
call __ZdlPvm; operator delete(void *,ulong)
mov rdi, r14
call __Unwind_Resume
| long long common_sampler_clone(common_params_sampling *a1)
{
long long v1; // rbx
__int128 v2; // xmm1
__int128 v3; // xmm0
v1 = operator new(0x1B8uLL);
common_params_sampling::common_params_sampling((common_params_sampling *)v1, a1);
*(_QWORD *)(v1 + 312) = llama_sampler_clone(*((_QWORD *)a1 + 39));
*(_QWORD *)(v1 + 320) = llama_sampler_clone(*((_QWORD *)a1 + 40));
v2 = *(_OWORD *)((char *)a1 + 344);
*(_OWORD *)(v1 + 328) = *(_OWORD *)((char *)a1 + 328);
*(_OWORD *)(v1 + 344) = v2;
std::vector<int>::vector(v1 + 360, (long long *)a1 + 45);
std::vector<llama_token_data>::vector(v1 + 384, (char *)a1 + 384);
v3 = *(_OWORD *)((char *)a1 + 408);
*(_OWORD *)(v1 + 424) = *(_OWORD *)((char *)a1 + 424);
*(_OWORD *)(v1 + 408) = v3;
return v1;
}
| common_sampler_clone:
PUSH R15
PUSH R14
PUSH RBX
MOV R14,RDI
MOV EDI,0x1b8
CALL 0x0011b8c0
MOV RBX,RAX
LAB_001cf6fd:
MOV RDI,RAX
MOV RSI,R14
CALL 0x00155552
MOV RDI,qword ptr [R14 + 0x138]
LAB_001cf70f:
CALL 0x0011b620
MOV qword ptr [RBX + 0x138],RAX
MOV RDI,qword ptr [R14 + 0x140]
CALL 0x0011b620
MOV qword ptr [RBX + 0x140],RAX
MOVUPS XMM0,xmmword ptr [R14 + 0x148]
MOVUPS XMM1,xmmword ptr [R14 + 0x158]
MOVUPS xmmword ptr [RBX + 0x148],XMM0
MOVUPS xmmword ptr [RBX + 0x158],XMM1
MOV ESI,0x168
LEA R15,[RBX + RSI*0x1]
ADD RSI,R14
MOV RDI,R15
CALL 0x00123a70
MOV ESI,0x180
MOV RDI,RBX
ADD RDI,RSI
ADD RSI,R14
LAB_001cf76e:
CALL 0x001d0914
LAB_001cf773:
MOVUPS XMM0,xmmword ptr [R14 + 0x198]
MOVUPS XMM1,xmmword ptr [R14 + 0x1a8]
MOVUPS xmmword ptr [RBX + 0x1a8],XMM1
MOVUPS xmmword ptr [RBX + 0x198],XMM0
MOV RAX,RBX
POP RBX
POP R14
POP R15
RET
|
/* common_sampler_clone(common_sampler*) */
common_params_sampling * common_sampler_clone(common_sampler *param_1)
{
int8 uVar1;
int8 uVar2;
common_params_sampling *this;
int8 uVar3;
this = (common_params_sampling *)operator_new(0x1b8);
/* try { // try from 001cf6fd to 001cf707 has its CatchHandler @ 001cf7b6 */
common_params_sampling::common_params_sampling(this,(common_params_sampling *)param_1);
/* try { // try from 001cf70f to 001cf75f has its CatchHandler @ 001cf7bb */
uVar3 = llama_sampler_clone(*(int8 *)(param_1 + 0x138));
*(int8 *)(this + 0x138) = uVar3;
uVar3 = llama_sampler_clone(*(int8 *)(param_1 + 0x140));
*(int8 *)(this + 0x140) = uVar3;
uVar3 = *(int8 *)(param_1 + 0x150);
uVar1 = *(int8 *)(param_1 + 0x158);
uVar2 = *(int8 *)(param_1 + 0x160);
*(int8 *)(this + 0x148) = *(int8 *)(param_1 + 0x148);
*(int8 *)(this + 0x150) = uVar3;
*(int8 *)(this + 0x158) = uVar1;
*(int8 *)(this + 0x160) = uVar2;
std::vector<int,std::allocator<int>>::vector
((vector<int,std::allocator<int>> *)(this + 0x168),(vector *)(param_1 + 0x168));
/* try { // try from 001cf76e to 001cf772 has its CatchHandler @ 001cf79a */
std::vector<llama_token_data,std::allocator<llama_token_data>>::vector
((vector<llama_token_data,std::allocator<llama_token_data>> *)(this + 0x180),
(vector *)(param_1 + 0x180));
uVar3 = *(int8 *)(param_1 + 0x198);
uVar1 = *(int8 *)(param_1 + 0x1a0);
uVar2 = *(int8 *)(param_1 + 0x1b0);
*(int8 *)(this + 0x1a8) = *(int8 *)(param_1 + 0x1a8);
*(int8 *)(this + 0x1b0) = uVar2;
*(int8 *)(this + 0x198) = uVar3;
*(int8 *)(this + 0x1a0) = uVar1;
return this;
}
| |
38,017 | common_sampler_clone(common_sampler*) | monkey531[P]llama/common/sampling.cpp | struct common_sampler * common_sampler_clone(common_sampler * gsmpl) {
return new common_sampler {
/* .params = */ gsmpl->params,
/* .grmr = */ llama_sampler_clone(gsmpl->grmr),
/* .chain = */ llama_sampler_clone(gsmpl->chain),
/* .prev = */ gsmpl->prev,
/* .cur = */ gsmpl->cur,
/* .cur_p = */ gsmpl->cur_p,
};
} | O2 | cpp | common_sampler_clone(common_sampler*):
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movl $0x1b8, %edi # imm = 0x1B8
callq 0x238e0
movq %rax, %rbx
movq %rax, %rdi
movq %r14, %rsi
callq 0x3a23a
movq 0x138(%r14), %rdi
callq 0x23650
movq %rax, 0x138(%rbx)
movq 0x140(%r14), %rdi
callq 0x23650
movq %rax, 0x140(%rbx)
movl $0x148, %esi # imm = 0x148
leaq (%rbx,%rsi), %rdi
addq %r14, %rsi
callq 0x99308
movl $0x180, %esi # imm = 0x180
leaq (%rbx,%rsi), %rdi
addq %r14, %rsi
callq 0x99324
movups 0x198(%r14), %xmm0
movups 0x1a8(%r14), %xmm1
movups %xmm1, 0x1a8(%rbx)
movups %xmm0, 0x198(%rbx)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
movq %rax, %r14
movq %rbx, %rdi
addq $0x168, %rdi # imm = 0x168
callq 0x2858a
jmp 0x98582
movq %rax, %r14
jmp 0x9858a
movq %rax, %r14
movq %rbx, %rdi
callq 0x27d5c
movl $0x1b8, %esi # imm = 0x1B8
movq %rbx, %rdi
callq 0x23900
movq %r14, %rdi
callq 0x23f90
| _Z20common_sampler_cloneP14common_sampler:
push r14
push rbx
push rax
mov r14, rdi
mov edi, 1B8h; unsigned __int64
call __Znwm; operator new(ulong)
mov rbx, rax
mov rdi, rax; this
mov rsi, r14; common_params_sampling *
call _ZN22common_params_samplingC2ERKS_; common_params_sampling::common_params_sampling(common_params_sampling const&)
mov rdi, [r14+138h]
call _llama_sampler_clone
mov [rbx+138h], rax
mov rdi, [r14+140h]
call _llama_sampler_clone
mov [rbx+140h], rax
mov esi, 148h
lea rdi, [rbx+rsi]
add rsi, r14
call _ZN11ring_bufferIiEC2ERKS0_; ring_buffer<int>::ring_buffer(ring_buffer<int> const&)
mov esi, 180h
lea rdi, [rbx+rsi]
add rsi, r14
call _ZNSt6vectorI16llama_token_dataSaIS0_EEC2ERKS2_; std::vector<llama_token_data>::vector(std::vector<llama_token_data> const&)
movups xmm0, xmmword ptr [r14+198h]
movups xmm1, xmmword ptr [r14+1A8h]
movups xmmword ptr [rbx+1A8h], xmm1
movups xmmword ptr [rbx+198h], xmm0
mov rax, rbx
add rsp, 8
pop rbx
pop r14
retn
mov r14, rax
mov rdi, rbx
add rdi, 168h
call _ZNSt12_Vector_baseIiSaIiEED2Ev; std::_Vector_base<int>::~_Vector_base()
jmp short loc_98582
mov r14, rax
jmp short loc_9858A
mov r14, rax
loc_98582:
mov rdi, rbx; this
call _ZN22common_params_samplingD2Ev; common_params_sampling::~common_params_sampling()
loc_9858A:
mov esi, 1B8h; unsigned __int64
mov rdi, rbx; void *
call __ZdlPvm; operator delete(void *,ulong)
mov rdi, r14
call __Unwind_Resume
| long long common_sampler_clone(common_sampler *a1)
{
long long v1; // rbx
__int128 v2; // xmm0
v1 = operator new(0x1B8uLL);
common_params_sampling::common_params_sampling((common_params_sampling *)v1, a1);
*(_QWORD *)(v1 + 312) = llama_sampler_clone(*((_QWORD *)a1 + 39));
*(_QWORD *)(v1 + 320) = llama_sampler_clone(*((_QWORD *)a1 + 40));
ring_buffer<int>::ring_buffer(v1 + 328, (char *)a1 + 328);
std::vector<llama_token_data>::vector(v1 + 384, (char *)a1 + 384);
v2 = *(_OWORD *)((char *)a1 + 408);
*(_OWORD *)(v1 + 424) = *(_OWORD *)((char *)a1 + 424);
*(_OWORD *)(v1 + 408) = v2;
return v1;
}
| common_sampler_clone:
PUSH R14
PUSH RBX
PUSH RAX
MOV R14,RDI
MOV EDI,0x1b8
CALL 0x001238e0
MOV RBX,RAX
LAB_001984ea:
MOV RDI,RAX
MOV RSI,R14
CALL 0x0013a23a
MOV RDI,qword ptr [R14 + 0x138]
LAB_001984fc:
CALL 0x00123650
MOV qword ptr [RBX + 0x138],RAX
MOV RDI,qword ptr [R14 + 0x140]
CALL 0x00123650
MOV qword ptr [RBX + 0x140],RAX
MOV ESI,0x148
LEA RDI,[RBX + RSI*0x1]
ADD RSI,R14
CALL 0x00199308
MOV ESI,0x180
LEA RDI,[RBX + RSI*0x1]
ADD RSI,R14
LAB_00198538:
CALL 0x00199324
LAB_0019853d:
MOVUPS XMM0,xmmword ptr [R14 + 0x198]
MOVUPS XMM1,xmmword ptr [R14 + 0x1a8]
MOVUPS xmmword ptr [RBX + 0x1a8],XMM1
MOVUPS xmmword ptr [RBX + 0x198],XMM0
MOV RAX,RBX
ADD RSP,0x8
POP RBX
POP R14
RET
|
/* common_sampler_clone(common_sampler*) */
common_params_sampling * common_sampler_clone(common_sampler *param_1)
{
int8 uVar1;
int8 uVar2;
common_params_sampling *this;
int8 uVar3;
this = (common_params_sampling *)operator_new(0x1b8);
/* try { // try from 001984ea to 001984f4 has its CatchHandler @ 0019857a */
common_params_sampling::common_params_sampling(this,(common_params_sampling *)param_1);
/* try { // try from 001984fc to 0019852b has its CatchHandler @ 0019857f */
uVar3 = llama_sampler_clone(*(int8 *)(param_1 + 0x138));
*(int8 *)(this + 0x138) = uVar3;
uVar3 = llama_sampler_clone(*(int8 *)(param_1 + 0x140));
*(int8 *)(this + 0x140) = uVar3;
ring_buffer<int>::ring_buffer((ring_buffer<int> *)(this + 0x148),(ring_buffer *)(param_1 + 0x148))
;
/* try { // try from 00198538 to 0019853c has its CatchHandler @ 00198566 */
std::vector<llama_token_data,std::allocator<llama_token_data>>::vector
((vector<llama_token_data,std::allocator<llama_token_data>> *)(this + 0x180),
(vector *)(param_1 + 0x180));
uVar3 = *(int8 *)(param_1 + 0x198);
uVar1 = *(int8 *)(param_1 + 0x1a0);
uVar2 = *(int8 *)(param_1 + 0x1b0);
*(int8 *)(this + 0x1a8) = *(int8 *)(param_1 + 0x1a8);
*(int8 *)(this + 0x1b0) = uVar2;
*(int8 *)(this + 0x198) = uVar3;
*(int8 *)(this + 0x1a0) = uVar1;
return this;
}
| |
38,018 | psi_rwlock_rdlock | eloqsql/mysys/my_thr_init.c | ATTRIBUTE_COLD
int psi_rwlock_rdlock(mysql_rwlock_t *that, const char *file, uint line)
{
PSI_rwlock_locker_state state;
PSI_rwlock_locker *locker= PSI_RWLOCK_CALL(start_rwlock_rdwait)
(&state, that->m_psi, PSI_RWLOCK_READLOCK, file, line);
int result= rw_rdlock(&that->m_rwlock);
if (locker)
PSI_RWLOCK_CALL(end_rwlock_rdwait)(locker, result);
return result;
} | O0 | c | psi_rwlock_rdlock:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
leaq 0x1a84ee(%rip), %rax # 0x1e1bb8
movq (%rax), %rax
movq 0x1a0(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x90(%rcx), %rsi
movq -0x10(%rbp), %rcx
movl -0x14(%rbp), %r8d
leaq -0x48(%rbp), %rdi
xorl %edx, %edx
callq *%rax
movq %rax, -0x50(%rbp)
movq -0x8(%rbp), %rdi
callq 0x39ef0
movl %eax, -0x54(%rbp)
cmpq $0x0, -0x50(%rbp)
je 0x39720
leaq 0x1a84ab(%rip), %rax # 0x1e1bb8
movq (%rax), %rax
movq 0x1a8(%rax), %rax
movq -0x50(%rbp), %rdi
movl -0x54(%rbp), %esi
callq *%rax
movl -0x54(%rbp), %eax
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)
| psi_rwlock_rdlock:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+1A0h]
mov rcx, [rbp+var_8]
mov rsi, [rcx+90h]
mov rcx, [rbp+var_10]
mov r8d, [rbp+var_14]
lea rdi, [rbp+var_48]
xor edx, edx
call rax
mov [rbp+var_50], rax
mov rdi, [rbp+var_8]
call my_rw_rdlock
mov [rbp+var_54], eax
cmp [rbp+var_50], 0
jz short loc_39720
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+1A8h]
mov rdi, [rbp+var_50]
mov esi, [rbp+var_54]
call rax
loc_39720:
mov eax, [rbp+var_54]
add rsp, 60h
pop rbp
retn
| long long psi_rwlock_rdlock(long long a1, long long a2, unsigned int a3)
{
unsigned int v4; // [rsp+Ch] [rbp-54h]
long long v5; // [rsp+10h] [rbp-50h]
_BYTE v6[52]; // [rsp+18h] [rbp-48h] BYREF
unsigned int v7; // [rsp+4Ch] [rbp-14h]
long long v8; // [rsp+50h] [rbp-10h]
long long v9; // [rsp+58h] [rbp-8h]
v9 = a1;
v8 = a2;
v7 = a3;
v5 = (*((long long ( **)(_BYTE *, _QWORD, _QWORD, long long, _QWORD))PSI_server + 52))(
v6,
*(_QWORD *)(a1 + 144),
0LL,
a2,
a3);
v4 = my_rw_rdlock(v9);
if ( v5 )
(*((void ( **)(long long, _QWORD))PSI_server + 53))(v5, v4);
return v4;
}
| psi_rwlock_rdlock:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x14],EDX
LEA RAX,[0x2e1bb8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x1a0]
MOV RCX,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RCX + 0x90]
MOV RCX,qword ptr [RBP + -0x10]
MOV R8D,dword ptr [RBP + -0x14]
LEA RDI,[RBP + -0x48]
XOR EDX,EDX
CALL RAX
MOV qword ptr [RBP + -0x50],RAX
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x00139ef0
MOV dword ptr [RBP + -0x54],EAX
CMP qword ptr [RBP + -0x50],0x0
JZ 0x00139720
LEA RAX,[0x2e1bb8]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x1a8]
MOV RDI,qword ptr [RBP + -0x50]
MOV ESI,dword ptr [RBP + -0x54]
CALL RAX
LAB_00139720:
MOV EAX,dword ptr [RBP + -0x54]
ADD RSP,0x60
POP RBP
RET
|
int4 psi_rwlock_rdlock(long param_1,int8 param_2,int4 param_3)
{
int4 uVar1;
long lVar2;
int1 local_50 [52];
int4 local_1c;
int8 local_18;
long local_10;
local_1c = param_3;
local_18 = param_2;
local_10 = param_1;
lVar2 = (**(code **)(PSI_server + 0x1a0))
(local_50,*(int8 *)(param_1 + 0x90),0,param_2,param_3);
uVar1 = my_rw_rdlock(local_10);
if (lVar2 != 0) {
(**(code **)(PSI_server + 0x1a8))(lVar2,uVar1);
}
return uVar1;
}
| |
38,019 | psi_rwlock_rdlock | eloqsql/mysys/my_thr_init.c | ATTRIBUTE_COLD
int psi_rwlock_rdlock(mysql_rwlock_t *that, const char *file, uint line)
{
PSI_rwlock_locker_state state;
PSI_rwlock_locker *locker= PSI_RWLOCK_CALL(start_rwlock_rdwait)
(&state, that->m_psi, PSI_RWLOCK_READLOCK, file, line);
int result= rw_rdlock(&that->m_rwlock);
if (locker)
PSI_RWLOCK_CALL(end_rwlock_rdwait)(locker, result);
return result;
} | O3 | c | psi_rwlock_rdlock:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x38, %rsp
movl %edx, %r8d
movq %rsi, %rcx
movq %rdi, %r14
leaq 0x2d5de5(%rip), %r15 # 0x2fab88
movq (%r15), %rax
movq 0x90(%rdi), %rsi
leaq -0x48(%rbp), %rdi
xorl %edx, %edx
callq *0x1a0(%rax)
movq %rax, %rbx
movq %r14, %rdi
callq 0x31f58
movl %eax, %r14d
testq %rbx, %rbx
je 0x24ddb
movq (%r15), %rax
movq %rbx, %rdi
movl %r14d, %esi
callq *0x1a8(%rax)
movl %r14d, %eax
addq $0x38, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
| psi_rwlock_rdlock:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
sub rsp, 38h
mov r8d, edx
mov rcx, rsi
mov r14, rdi
lea r15, PSI_server
mov rax, [r15]
mov rsi, [rdi+90h]
lea rdi, [rbp+var_48]
xor edx, edx
call qword ptr [rax+1A0h]
mov rbx, rax
mov rdi, r14
call my_rw_rdlock
mov r14d, eax
test rbx, rbx
jz short loc_24DDB
mov rax, [r15]
mov rdi, rbx
mov esi, r14d
call qword ptr [rax+1A8h]
loc_24DDB:
mov eax, r14d
add rsp, 38h
pop rbx
pop r14
pop r15
pop rbp
retn
| long long psi_rwlock_rdlock(long long a1, long long a2, unsigned int a3)
{
long long v3; // rbx
unsigned int v4; // r14d
_BYTE v6[72]; // [rsp+8h] [rbp-48h] BYREF
v3 = (*((long long ( **)(_BYTE *, _QWORD, _QWORD, long long, _QWORD))PSI_server + 52))(
v6,
*(_QWORD *)(a1 + 144),
0LL,
a2,
a3);
v4 = my_rw_rdlock(a1);
if ( v3 )
(*((void ( **)(long long, _QWORD))PSI_server + 53))(v3, v4);
return v4;
}
| psi_rwlock_rdlock:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x38
MOV R8D,EDX
MOV RCX,RSI
MOV R14,RDI
LEA R15,[0x3fab88]
MOV RAX,qword ptr [R15]
MOV RSI,qword ptr [RDI + 0x90]
LEA RDI,[RBP + -0x48]
XOR EDX,EDX
CALL qword ptr [RAX + 0x1a0]
MOV RBX,RAX
MOV RDI,R14
CALL 0x00131f58
MOV R14D,EAX
TEST RBX,RBX
JZ 0x00124ddb
MOV RAX,qword ptr [R15]
MOV RDI,RBX
MOV ESI,R14D
CALL qword ptr [RAX + 0x1a8]
LAB_00124ddb:
MOV EAX,R14D
ADD RSP,0x38
POP RBX
POP R14
POP R15
POP RBP
RET
|
int4 psi_rwlock_rdlock(long param_1,int8 param_2,int4 param_3)
{
int4 uVar1;
long lVar2;
int1 local_50 [48];
lVar2 = (**(code **)(PSI_server + 0x1a0))
(local_50,*(int8 *)(param_1 + 0x90),0,param_2,param_3);
uVar1 = my_rw_rdlock(param_1);
if (lVar2 != 0) {
(**(code **)(PSI_server + 0x1a8))(lVar2,uVar1);
}
return uVar1;
}
| |
38,020 | js_generator_function_call | bluesky950520[P]quickjs/quickjs.c | static JSValue js_generator_function_call(JSContext *ctx, JSValue func_obj,
JSValue this_obj,
int argc, JSValue *argv,
int flags)
{
JSValue obj, func_ret;
JSGeneratorData *s;
s = js_mallocz(ctx, sizeof(*s));
if (!s)
return JS_EXCEPTION;
s->state = JS_GENERATOR_STATE_SUSPENDED_START;
if (async_func_init(ctx, &s->func_state, func_obj, this_obj, argc, argv)) {
s->state = JS_GENERATOR_STATE_COMPLETED;
goto fail;
}
/* execute the function up to 'OP_initial_yield' */
func_ret = async_func_resume(ctx, &s->func_state);
if (JS_IsException(func_ret))
goto fail;
JS_FreeValue(ctx, func_ret);
obj = js_create_from_ctor(ctx, func_obj, JS_CLASS_GENERATOR);
if (JS_IsException(obj))
goto fail;
JS_SetOpaqueInternal(obj, s);
return obj;
fail:
free_generator_stack_rt(ctx->rt, s);
js_free(ctx, s);
return JS_EXCEPTION;
} | O0 | c | js_generator_function_call:
subq $0x98, %rsp
movl 0xa8(%rsp), %eax
movq 0xa0(%rsp), %rax
movq %rsi, 0x78(%rsp)
movq %rdx, 0x80(%rsp)
movq %rcx, 0x68(%rsp)
movq %r8, 0x70(%rsp)
movq %rdi, 0x60(%rsp)
movl %r9d, 0x5c(%rsp)
movq 0x60(%rsp), %rdi
movl $0x70, %esi
callq 0x21d30
movq %rax, 0x30(%rsp)
cmpq $0x0, 0x30(%rsp)
jne 0x231cf
movl $0x0, 0x88(%rsp)
movq $0x6, 0x90(%rsp)
jmp 0x23346
movq 0x30(%rsp), %rax
movl $0x0, (%rax)
movq 0x60(%rsp), %rdi
movq 0x30(%rsp), %rsi
addq $0x8, %rsi
movl 0x5c(%rsp), %r10d
movq 0xa0(%rsp), %rax
movq 0x78(%rsp), %rdx
movq 0x80(%rsp), %rcx
movq 0x68(%rsp), %r8
movq 0x70(%rsp), %r9
movl %r10d, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x71fb0
cmpl $0x0, %eax
je 0x2322f
movq 0x30(%rsp), %rax
movl $0x4, (%rax)
jmp 0x2330d
movq 0x60(%rsp), %rdi
movq 0x30(%rsp), %rsi
addq $0x8, %rsi
callq 0x72320
movq %rax, 0x20(%rsp)
movq %rdx, 0x28(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0x28(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x38(%rsp), %rdi
movq 0x40(%rsp), %rsi
callq 0x23cc0
cmpl $0x0, %eax
je 0x23279
jmp 0x2330d
movq 0x60(%rsp), %rdi
movq 0x38(%rsp), %rsi
movq 0x40(%rsp), %rdx
callq 0x23c90
movq 0x60(%rsp), %rdi
movq 0x78(%rsp), %rsi
movq 0x80(%rsp), %rdx
movl $0x2f, %ecx
callq 0x54e00
movq %rax, 0x10(%rsp)
movq %rdx, 0x18(%rsp)
movq 0x10(%rsp), %rax
movq %rax, 0x48(%rsp)
movq 0x18(%rsp), %rax
movq %rax, 0x50(%rsp)
movq 0x48(%rsp), %rdi
movq 0x50(%rsp), %rsi
callq 0x23cc0
cmpl $0x0, %eax
je 0x232dd
jmp 0x2330d
movq 0x30(%rsp), %rdx
movq 0x48(%rsp), %rdi
movq 0x50(%rsp), %rsi
callq 0x2a9a0
movq 0x48(%rsp), %rax
movq %rax, 0x88(%rsp)
movq 0x50(%rsp), %rax
movq %rax, 0x90(%rsp)
jmp 0x23346
movq 0x60(%rsp), %rax
movq 0x18(%rax), %rdi
movq 0x30(%rsp), %rsi
callq 0x5c1d0
movq 0x60(%rsp), %rdi
movq 0x30(%rsp), %rsi
callq 0x21db0
movl $0x0, 0x88(%rsp)
movq $0x6, 0x90(%rsp)
movq 0x88(%rsp), %rax
movq 0x90(%rsp), %rdx
addq $0x98, %rsp
retq
nop
| js_generator_function_call:
sub rsp, 98h
mov eax, [rsp+98h+arg_8]
mov rax, [rsp+98h+arg_0]
mov [rsp+98h+var_20], rsi
mov [rsp+98h+var_18], rdx
mov [rsp+98h+var_30], rcx
mov [rsp+98h+var_28], r8
mov [rsp+98h+var_38], rdi
mov [rsp+98h+var_3C], r9d
mov rdi, [rsp+98h+var_38]
mov esi, 70h ; 'p'
call js_mallocz
mov [rsp+98h+var_68], rax
cmp [rsp+98h+var_68], 0
jnz short loc_231CF
mov dword ptr [rsp+98h+var_10], 0
mov [rsp+98h+var_8], 6
jmp loc_23346
loc_231CF:
mov rax, [rsp+98h+var_68]
mov dword ptr [rax], 0
mov rdi, [rsp+98h+var_38]
mov rsi, [rsp+98h+var_68]
add rsi, 8
mov r10d, [rsp+98h+var_3C]
mov rax, [rsp+98h+arg_0]
mov rdx, [rsp+98h+var_20]
mov rcx, [rsp+98h+var_18]
mov r8, [rsp+98h+var_30]
mov r9, [rsp+98h+var_28]
mov [rsp+98h+var_98], r10d
mov [rsp+98h+var_90], rax
call async_func_init
cmp eax, 0
jz short loc_2322F
mov rax, [rsp+98h+var_68]
mov dword ptr [rax], 4
jmp loc_2330D
loc_2322F:
mov rdi, [rsp+98h+var_38]
mov rsi, [rsp+98h+var_68]
add rsi, 8
call async_func_resume
mov [rsp+98h+var_78], rax
mov [rsp+98h+var_70], rdx
mov rax, [rsp+98h+var_78]
mov [rsp+98h+var_60], rax
mov rax, [rsp+98h+var_70]
mov [rsp+98h+var_58], rax
mov rdi, [rsp+98h+var_60]
mov rsi, [rsp+98h+var_58]
call JS_IsException_1
cmp eax, 0
jz short loc_23279
jmp loc_2330D
loc_23279:
mov rdi, [rsp+98h+var_38]
mov rsi, [rsp+98h+var_60]
mov rdx, [rsp+98h+var_58]
call JS_FreeValue
mov rdi, [rsp+98h+var_38]
mov rsi, [rsp+98h+var_20]
mov rdx, [rsp+98h+var_18]
mov ecx, 2Fh ; '/'
call js_create_from_ctor
mov [rsp+98h+var_88], rax
mov [rsp+98h+var_80], rdx
mov rax, [rsp+98h+var_88]
mov [rsp+98h+var_50], rax
mov rax, [rsp+98h+var_80]
mov [rsp+98h+var_48], rax
mov rdi, [rsp+98h+var_50]
mov rsi, [rsp+98h+var_48]
call JS_IsException_1
cmp eax, 0
jz short loc_232DD
jmp short loc_2330D
loc_232DD:
mov rdx, [rsp+98h+var_68]
mov rdi, [rsp+98h+var_50]
mov rsi, [rsp+98h+var_48]
call JS_SetOpaqueInternal
mov rax, [rsp+98h+var_50]
mov [rsp+98h+var_10], rax
mov rax, [rsp+98h+var_48]
mov [rsp+98h+var_8], rax
jmp short loc_23346
loc_2330D:
mov rax, [rsp+98h+var_38]
mov rdi, [rax+18h]
mov rsi, [rsp+98h+var_68]
call free_generator_stack_rt
mov rdi, [rsp+98h+var_38]
mov rsi, [rsp+98h+var_68]
call js_free
mov dword ptr [rsp+98h+var_10], 0
mov [rsp+98h+var_8], 6
loc_23346:
mov rax, [rsp+98h+var_10]
mov rdx, [rsp+98h+var_8]
add rsp, 98h
retn
| long long js_generator_function_call(long long a1, long long a2, long long a3, int a4, int a5, int a6, long long a7)
{
long long v7; // rdx
long long v8; // rdx
long long v10; // [rsp+10h] [rbp-88h]
long long v11; // [rsp+20h] [rbp-78h]
_DWORD *v12; // [rsp+30h] [rbp-68h]
long long v13; // [rsp+40h] [rbp-58h]
long long v14; // [rsp+50h] [rbp-48h]
long long v19; // [rsp+88h] [rbp-10h]
v12 = (_DWORD *)js_mallocz(a1, 0x70uLL);
if ( v12 )
{
*v12 = 0;
if ( (unsigned int)async_func_init(a1, (int)v12 + 8, a2, a3, a4, a5, a6, a7) )
{
*v12 = 4;
}
else
{
v11 = async_func_resume(a1, v12 + 2);
v13 = v7;
if ( !(unsigned int)JS_IsException_1(v11, v7) )
{
JS_FreeValue(a1, v11, v13);
v10 = js_create_from_ctor(a1, a2, a3, 47LL);
v14 = v8;
if ( !(unsigned int)JS_IsException_1(v10, v8) )
{
JS_SetOpaqueInternal(v10, v14, v12);
return v10;
}
}
}
free_generator_stack_rt(*(_QWORD *)(a1 + 24), v12);
js_free(a1, (long long)v12);
LODWORD(v19) = 0;
return v19;
}
LODWORD(v19) = 0;
return v19;
}
| js_generator_function_call:
SUB RSP,0x98
MOV EAX,dword ptr [RSP + 0xa8]
MOV RAX,qword ptr [RSP + 0xa0]
MOV qword ptr [RSP + 0x78],RSI
MOV qword ptr [RSP + 0x80],RDX
MOV qword ptr [RSP + 0x68],RCX
MOV qword ptr [RSP + 0x70],R8
MOV qword ptr [RSP + 0x60],RDI
MOV dword ptr [RSP + 0x5c],R9D
MOV RDI,qword ptr [RSP + 0x60]
MOV ESI,0x70
CALL 0x00121d30
MOV qword ptr [RSP + 0x30],RAX
CMP qword ptr [RSP + 0x30],0x0
JNZ 0x001231cf
MOV dword ptr [RSP + 0x88],0x0
MOV qword ptr [RSP + 0x90],0x6
JMP 0x00123346
LAB_001231cf:
MOV RAX,qword ptr [RSP + 0x30]
MOV dword ptr [RAX],0x0
MOV RDI,qword ptr [RSP + 0x60]
MOV RSI,qword ptr [RSP + 0x30]
ADD RSI,0x8
MOV R10D,dword ptr [RSP + 0x5c]
MOV RAX,qword ptr [RSP + 0xa0]
MOV RDX,qword ptr [RSP + 0x78]
MOV RCX,qword ptr [RSP + 0x80]
MOV R8,qword ptr [RSP + 0x68]
MOV R9,qword ptr [RSP + 0x70]
MOV dword ptr [RSP],R10D
MOV qword ptr [RSP + 0x8],RAX
CALL 0x00171fb0
CMP EAX,0x0
JZ 0x0012322f
MOV RAX,qword ptr [RSP + 0x30]
MOV dword ptr [RAX],0x4
JMP 0x0012330d
LAB_0012322f:
MOV RDI,qword ptr [RSP + 0x60]
MOV RSI,qword ptr [RSP + 0x30]
ADD RSI,0x8
CALL 0x00172320
MOV qword ptr [RSP + 0x20],RAX
MOV qword ptr [RSP + 0x28],RDX
MOV RAX,qword ptr [RSP + 0x20]
MOV qword ptr [RSP + 0x38],RAX
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x40],RAX
MOV RDI,qword ptr [RSP + 0x38]
MOV RSI,qword ptr [RSP + 0x40]
CALL 0x00123cc0
CMP EAX,0x0
JZ 0x00123279
JMP 0x0012330d
LAB_00123279:
MOV RDI,qword ptr [RSP + 0x60]
MOV RSI,qword ptr [RSP + 0x38]
MOV RDX,qword ptr [RSP + 0x40]
CALL 0x00123c90
MOV RDI,qword ptr [RSP + 0x60]
MOV RSI,qword ptr [RSP + 0x78]
MOV RDX,qword ptr [RSP + 0x80]
MOV ECX,0x2f
CALL 0x00154e00
MOV qword ptr [RSP + 0x10],RAX
MOV qword ptr [RSP + 0x18],RDX
MOV RAX,qword ptr [RSP + 0x10]
MOV qword ptr [RSP + 0x48],RAX
MOV RAX,qword ptr [RSP + 0x18]
MOV qword ptr [RSP + 0x50],RAX
MOV RDI,qword ptr [RSP + 0x48]
MOV RSI,qword ptr [RSP + 0x50]
CALL 0x00123cc0
CMP EAX,0x0
JZ 0x001232dd
JMP 0x0012330d
LAB_001232dd:
MOV RDX,qword ptr [RSP + 0x30]
MOV RDI,qword ptr [RSP + 0x48]
MOV RSI,qword ptr [RSP + 0x50]
CALL 0x0012a9a0
MOV RAX,qword ptr [RSP + 0x48]
MOV qword ptr [RSP + 0x88],RAX
MOV RAX,qword ptr [RSP + 0x50]
MOV qword ptr [RSP + 0x90],RAX
JMP 0x00123346
LAB_0012330d:
MOV RAX,qword ptr [RSP + 0x60]
MOV RDI,qword ptr [RAX + 0x18]
MOV RSI,qword ptr [RSP + 0x30]
CALL 0x0015c1d0
MOV RDI,qword ptr [RSP + 0x60]
MOV RSI,qword ptr [RSP + 0x30]
CALL 0x00121db0
MOV dword ptr [RSP + 0x88],0x0
MOV qword ptr [RSP + 0x90],0x6
LAB_00123346:
MOV RAX,qword ptr [RSP + 0x88]
MOV RDX,qword ptr [RSP + 0x90]
ADD RSP,0x98
RET
|
int1 [16]
js_generator_function_call
(long param_1,int8 param_2,int8 param_3,int8 param_4,int8 param_5,
int4 param_6,int8 param_7)
{
int iVar1;
int4 *puVar2;
int1 auVar3 [16];
int4 local_10;
int4 uStack_c;
int8 local_8;
puVar2 = (int4 *)js_mallocz(param_1,0x70);
if (puVar2 == (int4 *)0x0) {
local_10 = 0;
local_8 = 6;
}
else {
*puVar2 = 0;
iVar1 = async_func_init(param_1,puVar2 + 2,param_2,param_3,param_4,param_5,param_6,param_7);
if (iVar1 == 0) {
auVar3 = async_func_resume(param_1,puVar2 + 2);
iVar1 = JS_IsException(auVar3._0_8_,auVar3._8_8_);
if (iVar1 == 0) {
JS_FreeValue(param_1,auVar3._0_8_,auVar3._8_8_);
auVar3 = js_create_from_ctor(param_1,param_2,param_3,0x2f);
local_8 = auVar3._8_8_;
iVar1 = JS_IsException(auVar3._0_8_,local_8);
if (iVar1 == 0) {
JS_SetOpaqueInternal(auVar3._0_8_,local_8,puVar2);
local_10 = auVar3._0_4_;
uStack_c = auVar3._4_4_;
goto LAB_00123346;
}
}
}
else {
*puVar2 = 4;
}
free_generator_stack_rt(*(int8 *)(param_1 + 0x18),puVar2);
js_free(param_1,puVar2);
local_10 = 0;
local_8 = 6;
}
LAB_00123346:
auVar3._4_4_ = uStack_c;
auVar3._0_4_ = local_10;
auVar3._8_8_ = local_8;
return auVar3;
}
| |
38,021 | cs_enter | eloqsql/strings/ctype.c | static int cs_enter(MY_XML_PARSER *st,const char *attr, size_t len)
{
struct my_cs_file_info *i= (struct my_cs_file_info *)st->user_data;
const struct my_cs_file_section_st *s= cs_file_sec(attr,len);
int state= s ? s->state : 0;
switch (state) {
case 0:
i->loader->reporter(WARNING_LEVEL, "Unknown LDML tag: '%.*s'", len, attr);
break;
case _CS_CHARSET:
my_charset_file_reset_charset(i);
break;
case _CS_COLLATION:
my_charset_file_reset_collation(i);
break;
case _CS_RESET:
return tailoring_append(st, " &", 0, NULL);
default:
break;
}
return MY_XML_OK;
} | O0 | c | cs_enter:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq 0x140(%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq 0x6c5f0
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x30(%rbp)
je 0x6ab86
movq -0x30(%rbp), %rax
movl (%rax), %eax
movl %eax, -0x38(%rbp)
jmp 0x6ab8d
xorl %eax, %eax
movl %eax, -0x38(%rbp)
jmp 0x6ab8d
movl -0x38(%rbp), %eax
movl %eax, -0x34(%rbp)
movl -0x34(%rbp), %eax
movl %eax, -0x3c(%rbp)
testl %eax, %eax
je 0x6abbf
jmp 0x6ab9f
movl -0x3c(%rbp), %eax
subl $0x8, %eax
je 0x6abec
jmp 0x6aba9
movl -0x3c(%rbp), %eax
subl $0x9, %eax
je 0x6abf7
jmp 0x6abb3
movl -0x3c(%rbp), %eax
subl $0x12d, %eax # imm = 0x12D
je 0x6ac02
jmp 0x6ac1e
movq -0x28(%rbp), %rax
movq 0x7a8(%rax), %rax
movq 0xa0(%rax), %r8
movq -0x20(%rbp), %rdx
movq -0x18(%rbp), %rcx
movl $0x1, %edi
leaq 0x1018f(%rip), %rsi # 0x7ad74
movb $0x0, %al
callq *%r8
jmp 0x6ac20
movq -0x28(%rbp), %rdi
callq 0x6c590
jmp 0x6ac20
movq -0x28(%rbp), %rdi
callq 0x6c5c0
jmp 0x6ac20
movq -0x10(%rbp), %rdi
leaq 0x10180(%rip), %rsi # 0x7ad8d
xorl %eax, %eax
movl %eax, %ecx
movq %rcx, %rdx
callq 0x6c680
movl %eax, -0x4(%rbp)
jmp 0x6ac27
jmp 0x6ac20
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
| cs_enter:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov rax, [rbp+var_10]
mov rax, [rax+140h]
mov [rbp+var_28], rax
mov rdi, [rbp+var_18]
mov rsi, [rbp+var_20]
call cs_file_sec
mov [rbp+var_30], rax
cmp [rbp+var_30], 0
jz short loc_6AB86
mov rax, [rbp+var_30]
mov eax, [rax]
mov [rbp+var_38], eax
jmp short loc_6AB8D
loc_6AB86:
xor eax, eax
mov [rbp+var_38], eax
jmp short $+2
loc_6AB8D:
mov eax, [rbp+var_38]
mov [rbp+var_34], eax
mov eax, [rbp+var_34]
mov [rbp+var_3C], eax
test eax, eax
jz short loc_6ABBF
jmp short $+2
loc_6AB9F:
mov eax, [rbp+var_3C]
sub eax, 8
jz short loc_6ABEC
jmp short $+2
loc_6ABA9:
mov eax, [rbp+var_3C]
sub eax, 9
jz short loc_6ABF7
jmp short $+2
loc_6ABB3:
mov eax, [rbp+var_3C]
sub eax, 12Dh
jz short loc_6AC02
jmp short loc_6AC1E
loc_6ABBF:
mov rax, [rbp+var_28]
mov rax, [rax+7A8h]
mov r8, [rax+0A0h]
mov rdx, [rbp+var_20]
mov rcx, [rbp+var_18]
mov edi, 1
lea rsi, aUnknownLdmlTag; "Unknown LDML tag: '%.*s'"
mov al, 0
call r8
jmp short loc_6AC20
loc_6ABEC:
mov rdi, [rbp+var_28]
call my_charset_file_reset_charset
jmp short loc_6AC20
loc_6ABF7:
mov rdi, [rbp+var_28]
call my_charset_file_reset_collation
jmp short loc_6AC20
loc_6AC02:
mov rdi, [rbp+var_10]
lea rsi, asc_7AD8D; " &"
xor eax, eax
mov ecx, eax
mov rdx, rcx
call tailoring_append
mov [rbp+var_4], eax
jmp short loc_6AC27
loc_6AC1E:
jmp short $+2
loc_6AC20:
mov [rbp+var_4], 0
loc_6AC27:
mov eax, [rbp+var_4]
add rsp, 40h
pop rbp
retn
| long long cs_enter(long long a1, const char *a2, long long a3)
{
int v4; // [rsp+8h] [rbp-38h]
int *v5; // [rsp+10h] [rbp-30h]
long long v6; // [rsp+18h] [rbp-28h]
int v7; // [rsp+20h] [rbp-20h]
v7 = a3;
v6 = *(_QWORD *)(a1 + 320);
v5 = (int *)cs_file_sec(a2, a3);
if ( v5 )
v4 = *v5;
else
v4 = 0;
switch ( v4 )
{
case 0:
(*(void (**)(long long, const char *, ...))(*(_QWORD *)(v6 + 1960) + 160LL))(
1LL,
"Unknown LDML tag: '%.*s'",
v7,
a2);
return 0;
case 8:
my_charset_file_reset_charset(v6);
return 0;
case 9:
my_charset_file_reset_collation(v6);
return 0;
}
if ( v4 != 301 )
return 0;
return (unsigned int)tailoring_append(a1, " &", 0LL);
}
| cs_enter:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x140]
MOV qword ptr [RBP + -0x28],RAX
MOV RDI,qword ptr [RBP + -0x18]
MOV RSI,qword ptr [RBP + -0x20]
CALL 0x0016c5f0
MOV qword ptr [RBP + -0x30],RAX
CMP qword ptr [RBP + -0x30],0x0
JZ 0x0016ab86
MOV RAX,qword ptr [RBP + -0x30]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x38],EAX
JMP 0x0016ab8d
LAB_0016ab86:
XOR EAX,EAX
MOV dword ptr [RBP + -0x38],EAX
JMP 0x0016ab8d
LAB_0016ab8d:
MOV EAX,dword ptr [RBP + -0x38]
MOV dword ptr [RBP + -0x34],EAX
MOV EAX,dword ptr [RBP + -0x34]
MOV dword ptr [RBP + -0x3c],EAX
TEST EAX,EAX
JZ 0x0016abbf
JMP 0x0016ab9f
LAB_0016ab9f:
MOV EAX,dword ptr [RBP + -0x3c]
SUB EAX,0x8
JZ 0x0016abec
JMP 0x0016aba9
LAB_0016aba9:
MOV EAX,dword ptr [RBP + -0x3c]
SUB EAX,0x9
JZ 0x0016abf7
JMP 0x0016abb3
LAB_0016abb3:
MOV EAX,dword ptr [RBP + -0x3c]
SUB EAX,0x12d
JZ 0x0016ac02
JMP 0x0016ac1e
LAB_0016abbf:
MOV RAX,qword ptr [RBP + -0x28]
MOV RAX,qword ptr [RAX + 0x7a8]
MOV R8,qword ptr [RAX + 0xa0]
MOV RDX,qword ptr [RBP + -0x20]
MOV RCX,qword ptr [RBP + -0x18]
MOV EDI,0x1
LEA RSI,[0x17ad74]
MOV AL,0x0
CALL R8
JMP 0x0016ac20
LAB_0016abec:
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x0016c590
JMP 0x0016ac20
LAB_0016abf7:
MOV RDI,qword ptr [RBP + -0x28]
CALL 0x0016c5c0
JMP 0x0016ac20
LAB_0016ac02:
MOV RDI,qword ptr [RBP + -0x10]
LEA RSI,[0x17ad8d]
XOR EAX,EAX
MOV ECX,EAX
MOV RDX,RCX
CALL 0x0016c680
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0016ac27
LAB_0016ac1e:
JMP 0x0016ac20
LAB_0016ac20:
MOV dword ptr [RBP + -0x4],0x0
LAB_0016ac27:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x40
POP RBP
RET
|
int4 cs_enter(long param_1,int8 param_2,int8 param_3)
{
long lVar1;
int4 uVar2;
int *piVar3;
int local_40;
lVar1 = *(long *)(param_1 + 0x140);
piVar3 = (int *)cs_file_sec(param_2,param_3);
if (piVar3 == (int *)0x0) {
local_40 = 0;
}
else {
local_40 = *piVar3;
}
if (local_40 == 0) {
(**(code **)(*(long *)(lVar1 + 0x7a8) + 0xa0))(1,"Unknown LDML tag: \'%.*s\'",param_3,param_2);
}
else if (local_40 == 8) {
my_charset_file_reset_charset(lVar1);
}
else if (local_40 == 9) {
my_charset_file_reset_collation(lVar1);
}
else if (local_40 == 0x12d) {
uVar2 = tailoring_append(param_1,&DAT_0017ad8d,0);
return uVar2;
}
return 0;
}
| |
38,022 | cs_enter | eloqsql/strings/ctype.c | static int cs_enter(MY_XML_PARSER *st,const char *attr, size_t len)
{
struct my_cs_file_info *i= (struct my_cs_file_info *)st->user_data;
const struct my_cs_file_section_st *s= cs_file_sec(attr,len);
int state= s ? s->state : 0;
switch (state) {
case 0:
i->loader->reporter(WARNING_LEVEL, "Unknown LDML tag: '%.*s'", len, attr);
break;
case _CS_CHARSET:
my_charset_file_reset_charset(i);
break;
case _CS_COLLATION:
my_charset_file_reset_collation(i);
break;
case _CS_RESET:
return tailoring_append(st, " &", 0, NULL);
default:
break;
}
return MY_XML_OK;
} | O3 | c | cs_enter:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r15
movq %rsi, %r14
movq 0x140(%rdi), %rbx
leaq 0x29a6c5(%rip), %r13 # 0x2ed5a0
leaq 0x8606(%rip), %r12 # 0x5b4e8
movq %r14, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq 0x24120
testl %eax, %eax
jne 0x52efb
cmpb $0x0, (%r12,%r15)
je 0x52f3b
movq 0x18(%r13), %r12
addq $0x10, %r13
testq %r12, %r12
jne 0x52ee2
movq 0x7a8(%rbx), %r8
leaq 0xae40(%rip), %rsi # 0x5dd56
movl $0x1, %edi
movq %r15, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq *0xa0(%r8)
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl (%r13), %eax
cmpl $0x8, %eax
jg 0x52f65
testl %eax, %eax
je 0x52f08
cmpl $0x8, %eax
jne 0x52f2a
addq $0x6e0, %rbx # imm = 0x6E0
movl $0xc8, %edx
movq %rbx, %rdi
xorl %esi, %esi
callq 0x24160
jmp 0x52f2a
cmpl $0x9, %eax
je 0x52f92
cmpl $0x12d, %eax # imm = 0x12D
jne 0x52f2a
leaq 0xadf7(%rip), %rsi # 0x5dd6f
movq %rbx, %rdi
xorl %edx, %edx
xorl %ecx, %ecx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x54134
movq $0x0, 0x690(%rbx)
movb $0x0, 0x6a0(%rbx)
jmp 0x52f2a
| cs_enter:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r15, rdx
mov r14, rsi
mov rbx, [rdi+140h]
lea r13, sec
lea r12, aIndexXml+6; "xml"
loc_52EE2:
mov rdi, r14
mov rsi, r12
mov rdx, r15
call _strncmp
test eax, eax
jnz short loc_52EFB
cmp byte ptr [r12+r15], 0
jz short loc_52F3B
loc_52EFB:
mov r12, [r13+18h]
add r13, 10h
test r12, r12
jnz short loc_52EE2
loc_52F08:
mov r8, [rbx+7A8h]
lea rsi, aUnknownLdmlTag; "Unknown LDML tag: '%.*s'"
mov edi, 1
mov rdx, r15
mov rcx, r14
xor eax, eax
call qword ptr [r8+0A0h]
loc_52F2A:
xor eax, eax
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_52F3B:
mov eax, [r13+0]
cmp eax, 8
jg short loc_52F65
test eax, eax
jz short loc_52F08
cmp eax, 8
jnz short loc_52F2A
add rbx, 6E0h
mov edx, 0C8h
mov rdi, rbx
xor esi, esi
call _memset
jmp short loc_52F2A
loc_52F65:
cmp eax, 9
jz short loc_52F92
cmp eax, 12Dh
jnz short loc_52F2A
lea rsi, asc_5DD6F; " &"
mov rdi, rbx
xor edx, edx
xor ecx, ecx
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
jmp tailoring_append
loc_52F92:
mov qword ptr [rbx+690h], 0
mov byte ptr [rbx+6A0h], 0
jmp short loc_52F2A
| long long cs_enter(long long a1, const char *a2, long long a3)
{
long long v4; // rbx
char *v5; // r13
char *v6; // r12
int v8; // eax
v4 = *(_QWORD *)(a1 + 320);
v5 = (char *)&sec;
v6 = "xml";
while ( (unsigned int)strncmp(a2, v6, a3) || v6[a3] )
{
v6 = (char *)*((_QWORD *)v5 + 3);
v5 += 16;
if ( !v6 )
goto LABEL_5;
}
v8 = *(_DWORD *)v5;
if ( *(int *)v5 <= 8 )
{
if ( v8 )
{
if ( v8 == 8 )
memset(v4 + 1760, 0LL, 200LL);
}
else
{
LABEL_5:
(*(void (**)(long long, const char *, ...))(*(_QWORD *)(v4 + 1960) + 160LL))(
1LL,
"Unknown LDML tag: '%.*s'",
a3,
a2);
}
return 0LL;
}
if ( v8 == 9 )
{
*(_QWORD *)(v4 + 1680) = 0LL;
*(_BYTE *)(v4 + 1696) = 0;
return 0LL;
}
if ( v8 != 301 )
return 0LL;
return tailoring_append(v4, " &", 0LL, 0LL);
}
| cs_enter:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R15,RDX
MOV R14,RSI
MOV RBX,qword ptr [RDI + 0x140]
LEA R13,[0x3ed5a0]
LEA R12,[0x15b4e8]
LAB_00152ee2:
MOV RDI,R14
MOV RSI,R12
MOV RDX,R15
CALL 0x00124120
TEST EAX,EAX
JNZ 0x00152efb
CMP byte ptr [R12 + R15*0x1],0x0
JZ 0x00152f3b
LAB_00152efb:
MOV R12,qword ptr [R13 + 0x18]
ADD R13,0x10
TEST R12,R12
JNZ 0x00152ee2
LAB_00152f08:
MOV R8,qword ptr [RBX + 0x7a8]
LEA RSI,[0x15dd56]
MOV EDI,0x1
MOV RDX,R15
MOV RCX,R14
XOR EAX,EAX
CALL qword ptr [R8 + 0xa0]
LAB_00152f2a:
XOR EAX,EAX
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_00152f3b:
MOV EAX,dword ptr [R13]
CMP EAX,0x8
JG 0x00152f65
TEST EAX,EAX
JZ 0x00152f08
CMP EAX,0x8
JNZ 0x00152f2a
ADD RBX,0x6e0
MOV EDX,0xc8
MOV RDI,RBX
XOR ESI,ESI
CALL 0x00124160
JMP 0x00152f2a
LAB_00152f65:
CMP EAX,0x9
JZ 0x00152f92
CMP EAX,0x12d
JNZ 0x00152f2a
LEA RSI,[0x15dd6f]
MOV RDI,RBX
XOR EDX,EDX
XOR ECX,ECX
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
JMP 0x00154134
LAB_00152f92:
MOV qword ptr [RBX + 0x690],0x0
MOV byte ptr [RBX + 0x6a0],0x0
JMP 0x00152f2a
|
int8 cs_enter(long param_1,char *param_2,size_t param_3)
{
long lVar1;
int iVar2;
int8 uVar3;
char *__s2;
int *piVar4;
lVar1 = *(long *)(param_1 + 0x140);
piVar4 = &sec;
__s2 = "xml";
while ((iVar2 = strncmp(param_2,__s2,param_3), iVar2 != 0 || (__s2[param_3] != '\0'))) {
__s2 = *(char **)(piVar4 + 6);
piVar4 = piVar4 + 4;
if (__s2 == (char *)0x0) {
LAB_00152f08:
(**(code **)(*(long *)(lVar1 + 0x7a8) + 0xa0))(1,"Unknown LDML tag: \'%.*s\'",param_3,param_2)
;
return 0;
}
}
iVar2 = *piVar4;
if (8 < iVar2) {
if (iVar2 == 9) {
*(int8 *)(lVar1 + 0x690) = 0;
*(int1 *)(lVar1 + 0x6a0) = 0;
return 0;
}
if (iVar2 != 0x12d) {
return 0;
}
uVar3 = tailoring_append(lVar1,&DAT_0015dd6f,0,0);
return uVar3;
}
if (iVar2 != 0) {
if (iVar2 != 8) {
return 0;
}
memset((void *)(lVar1 + 0x6e0),0,200);
return 0;
}
goto LAB_00152f08;
}
| |
38,023 | ma_write_init_block_record | eloqsql/storage/maria/ma_blockrec.c | MARIA_RECORD_POS _ma_write_init_block_record(MARIA_HA *info,
const uchar *record)
{
DBUG_ENTER("_ma_write_init_block_record");
calc_record_size(info, record, &info->cur_row);
if (allocate_and_write_block_record(info, record,
&info->cur_row, LSN_ERROR))
DBUG_RETURN(HA_OFFSET_ERROR);
DBUG_RETURN(info->cur_row.lastpos);
} | O0 | c | ma_write_init_block_record:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x10(%rbp), %rdx
addq $0x80, %rdx
callq 0x52fd0
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x10(%rbp), %rdx
addq $0x80, %rdx
movl $0x1, %ecx
callq 0x535f0
cmpb $0x0, %al
je 0x52fb5
jmp 0x52fab
movq $-0x1, -0x8(%rbp)
jmp 0x52fc6
jmp 0x52fb7
movq -0x10(%rbp), %rax
movq 0x98(%rax), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
| _ma_write_init_block_record:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
mov rdx, [rbp+var_10]
add rdx, 80h
call calc_record_size
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
mov rdx, [rbp+var_10]
add rdx, 80h
mov ecx, 1
call allocate_and_write_block_record
cmp al, 0
jz short loc_52FB5
jmp short $+2
loc_52FAB:
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp short loc_52FC6
loc_52FB5:
jmp short $+2
loc_52FB7:
mov rax, [rbp+var_10]
mov rax, [rax+98h]
mov [rbp+var_8], rax
loc_52FC6:
mov rax, [rbp+var_8]
add rsp, 20h
pop rbp
retn
| long long ma_write_init_block_record(long long a1, long long a2)
{
calc_record_size(a1, a2, a1 + 128);
if ( (unsigned __int8)allocate_and_write_block_record(a1, a2, a1 + 128, 1LL) )
return -1LL;
else
return *(_QWORD *)(a1 + 152);
}
| _ma_write_init_block_record:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x10]
ADD RDX,0x80
CALL 0x00152fd0
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x10]
ADD RDX,0x80
MOV ECX,0x1
CALL 0x001535f0
CMP AL,0x0
JZ 0x00152fb5
JMP 0x00152fab
LAB_00152fab:
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x00152fc6
LAB_00152fb5:
JMP 0x00152fb7
LAB_00152fb7:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x98]
MOV qword ptr [RBP + -0x8],RAX
LAB_00152fc6:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x20
POP RBP
RET
|
int8 _ma_write_init_block_record(long param_1,int8 param_2)
{
char cVar1;
int8 local_10;
calc_record_size(param_1,param_2,param_1 + 0x80);
cVar1 = allocate_and_write_block_record(param_1,param_2,param_1 + 0x80,1);
if (cVar1 == '\0') {
local_10 = *(int8 *)(param_1 + 0x98);
}
else {
local_10 = 0xffffffffffffffff;
}
return local_10;
}
| |
38,024 | ma_change_bitmap_page | eloqsql/storage/maria/ma_bitmap.c | static my_bool _ma_change_bitmap_page(MARIA_HA *info,
MARIA_FILE_BITMAP *bitmap,
pgcache_page_no_t page)
{
DBUG_ENTER("_ma_change_bitmap_page");
_ma_check_bitmap(bitmap);
/*
We have to mark the file changed here, as otherwise the following
read/write to pagecache may force a page out from this file, which would
cause _ma_mark_file_changed() to be called with bitmaplock hold!
*/
_ma_bitmap_mark_file_changed(info->s, 1);
if (bitmap->changed)
{
if (write_changed_bitmap(info->s, bitmap))
DBUG_RETURN(1);
bitmap->changed= 0;
}
DBUG_RETURN(_ma_read_bitmap_page(info, bitmap, page));
} | O0 | c | ma_change_bitmap_page:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
jmp 0x48336
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movl $0x1, %esi
callq 0x46e50
movq -0x18(%rbp), %rax
cmpb $0x0, 0x20(%rax)
je 0x48375
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movq -0x18(%rbp), %rsi
callq 0x46f20
cmpb $0x0, %al
je 0x4836d
jmp 0x48367
movb $0x1, -0x1(%rbp)
jmp 0x4838b
movq -0x18(%rbp), %rax
movb $0x0, 0x20(%rax)
jmp 0x48377
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
callq 0x4a940
movb %al, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| _ma_change_bitmap_page:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
jmp short $+2
loc_48336:
mov rax, [rbp+var_10]
mov rdi, [rax]
mov esi, 1
call _ma_bitmap_mark_file_changed
mov rax, [rbp+var_18]
cmp byte ptr [rax+20h], 0
jz short loc_48375
mov rax, [rbp+var_10]
mov rdi, [rax]
mov rsi, [rbp+var_18]
call write_changed_bitmap
cmp al, 0
jz short loc_4836D
jmp short $+2
loc_48367:
mov [rbp+var_1], 1
jmp short loc_4838B
loc_4836D:
mov rax, [rbp+var_18]
mov byte ptr [rax+20h], 0
loc_48375:
jmp short $+2
loc_48377:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
mov rdx, [rbp+var_20]
call _ma_read_bitmap_page
mov [rbp+var_1], al
loc_4838B:
mov al, [rbp+var_1]
add rsp, 20h
pop rbp
retn
| char ma_change_bitmap_page(long long *a1, long long a2, long long a3)
{
ma_bitmap_mark_file_changed(*a1, 1);
if ( !*(_BYTE *)(a2 + 32) )
return ma_read_bitmap_page(a1, a2, a3);
if ( !write_changed_bitmap(*a1, a2) )
{
*(_BYTE *)(a2 + 32) = 0;
return ma_read_bitmap_page(a1, a2, a3);
}
return 1;
}
| _ma_change_bitmap_page:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
JMP 0x00148336
LAB_00148336:
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX]
MOV ESI,0x1
CALL 0x00146e50
MOV RAX,qword ptr [RBP + -0x18]
CMP byte ptr [RAX + 0x20],0x0
JZ 0x00148375
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x00146f20
CMP AL,0x0
JZ 0x0014836d
JMP 0x00148367
LAB_00148367:
MOV byte ptr [RBP + -0x1],0x1
JMP 0x0014838b
LAB_0014836d:
MOV RAX,qword ptr [RBP + -0x18]
MOV byte ptr [RAX + 0x20],0x0
LAB_00148375:
JMP 0x00148377
LAB_00148377:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x20]
CALL 0x0014a940
MOV byte ptr [RBP + -0x1],AL
LAB_0014838b:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x20
POP RBP
RET
|
int1 _ma_change_bitmap_page(int8 *param_1,long param_2,int8 param_3)
{
char cVar1;
int1 uVar2;
_ma_bitmap_mark_file_changed(*param_1,1);
if (*(char *)(param_2 + 0x20) != '\0') {
cVar1 = write_changed_bitmap(*param_1,param_2);
if (cVar1 != '\0') {
return 1;
}
*(int1 *)(param_2 + 0x20) = 0;
}
uVar2 = _ma_read_bitmap_page(param_1,param_2,param_3);
return uVar2;
}
| |
38,025 | GoodASM::loadFragment(QString, QByteArray, QString) | goodasm/goodasm.cpp | void GoodASM::loadFragment(QString label, QByteArray bytes, QString comment){
char buf[GAMAXLEN];
uint64_t base=0; //Offset into the buffer that we are adding.
uint32_t len; //Length of the working instruction.
while(base<bytes.length()){
//Load bytes, or zeroes.
for(int i=0; i<lang->maxbytes; i++)
buf[i]=(i+base<bytes.length()?bytes.at(i+base):0);
GAInstruction ins=lang->decode(workingadr, buf, len);
ins.comment=comment;
if(label.length()>0){
ins.label=label;
label="";
}
if(base+len>bytes.length()){
GAInstruction data=GAInstruction(this, buf[0]);
data.comment=comment+" (data)";
if(label.length()>0){
data.label=label;
label="";
}
base+=1;
append(data);
}else{
base+=len;
append(ins);
}
}
} | O3 | cpp | GoodASM::loadFragment(QString, QByteArray, QString):
pushq %rbp
movq %rsp, %rbp
subq $0x450, %rsp # imm = 0x450
movq %rsi, -0x3f8(%rbp)
movq %rdx, -0x3f0(%rbp)
movq %rcx, -0x3e8(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x3e0(%rbp)
movq $0x0, -0x48(%rbp)
movq -0x3f0(%rbp), %rdi
movq -0x48(%rbp), %rax
movq %rax, -0x400(%rbp)
callq 0xf5b0
movq %rax, %rcx
movq -0x400(%rbp), %rax
cmpq %rcx, %rax
jae 0x166fe
movl $0x0, -0x50(%rbp)
movq -0x3e0(%rbp), %rcx
movl -0x50(%rbp), %eax
movq 0x38(%rcx), %rcx
movzbl 0x43(%rcx), %ecx
cmpl %ecx, %eax
jge 0x1645b
movq -0x3f0(%rbp), %rdi
movslq -0x50(%rbp), %rax
addq -0x48(%rbp), %rax
movq %rax, -0x408(%rbp)
callq 0xf5b0
movq %rax, %rcx
movq -0x408(%rbp), %rax
cmpq %rcx, %rax
jae 0x16433
movq -0x3f0(%rbp), %rdi
movslq -0x50(%rbp), %rsi
addq -0x48(%rbp), %rsi
callq 0x18650
movsbl %al, %eax
movl %eax, -0x40c(%rbp)
jmp 0x1643d
xorl %eax, %eax
movl %eax, -0x40c(%rbp)
jmp 0x1643d
movl -0x40c(%rbp), %eax
movb %al, %cl
movslq -0x50(%rbp), %rax
movb %cl, -0x40(%rbp,%rax)
movl -0x50(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x50(%rbp)
jmp 0x163d4
movq -0x3e0(%rbp), %rax
movq 0x38(%rax), %rsi
movq 0x138(%rax), %rdx
leaq -0x128(%rbp), %rdi
leaq -0x40(%rbp), %rcx
leaq -0x4c(%rbp), %r8
callq 0x3d8b0
movq -0x3e8(%rbp), %rsi
leaq -0xa8(%rbp), %rdi
callq 0x77e0
movq -0x3f8(%rbp), %rdi
callq 0xf8b0
movq %rax, -0x418(%rbp)
jmp 0x164a9
movq -0x418(%rbp), %rax
cmpq $0x0, %rax
jle 0x164f7
movq -0x3f8(%rbp), %rsi
leaq -0x118(%rbp), %rdi
callq 0x77e0
movq -0x3f8(%rbp), %rdi
leaq 0x103bf1(%rip), %rsi # 0x11a0c8
callq 0xe890
jmp 0x164de
jmp 0x164f7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x130(%rbp)
movl %eax, -0x134(%rbp)
jmp 0x166f0
movq -0x3f0(%rbp), %rdi
movq -0x48(%rbp), %rax
movl -0x4c(%rbp), %ecx
addq %rcx, %rax
movq %rax, -0x428(%rbp)
callq 0xf5b0
movq %rax, -0x420(%rbp)
jmp 0x1651d
movq -0x428(%rbp), %rax
movq -0x420(%rbp), %rcx
cmpq %rcx, %rax
jbe 0x16672
movq -0x3e0(%rbp), %rsi
movzbl -0x40(%rbp), %edx
leaq -0x210(%rbp), %rdi
callq 0x106f40
jmp 0x1654d
movq -0x3e8(%rbp), %rsi
leaq 0xfa466(%rip), %rdx # 0x1109c1
leaq -0x228(%rbp), %rdi
callq 0x178b0
jmp 0x16569
leaq -0x190(%rbp), %rdi
leaq -0x228(%rbp), %rsi
movq %rsi, -0x438(%rbp)
callq 0x77e0
movq -0x438(%rbp), %rdi
callq 0xe770
movq -0x3f8(%rbp), %rdi
callq 0xf8b0
movq %rax, -0x430(%rbp)
jmp 0x165a4
movq -0x430(%rbp), %rax
cmpq $0x0, %rax
jle 0x165ef
movq -0x3f8(%rbp), %rsi
leaq -0x200(%rbp), %rdi
callq 0x77e0
movq -0x3f8(%rbp), %rdi
leaq 0x103af6(%rip), %rsi # 0x11a0c8
callq 0xe890
jmp 0x165d9
jmp 0x165ef
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x130(%rbp)
movl %eax, -0x134(%rbp)
jmp 0x16664
movq -0x48(%rbp), %rax
incq %rax
movq %rax, -0x48(%rbp)
leaq -0x300(%rbp), %rdi
movq %rdi, -0x440(%rbp)
leaq -0x210(%rbp), %rsi
callq 0x18340
movq -0x3e0(%rbp), %rdi
movq -0x440(%rbp), %rsi
callq 0x162a0
jmp 0x16629
leaq -0x300(%rbp), %rdi
callq 0x17830
leaq -0x210(%rbp), %rdi
callq 0x17830
jmp 0x166df
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x130(%rbp)
movl %eax, -0x134(%rbp)
leaq -0x300(%rbp), %rdi
callq 0x17830
leaq -0x210(%rbp), %rdi
callq 0x17830
jmp 0x166f0
movl -0x4c(%rbp), %eax
movl %eax, %ecx
movq -0x48(%rbp), %rax
addq %rcx, %rax
movq %rax, -0x48(%rbp)
leaq -0x3d8(%rbp), %rdi
movq %rdi, -0x448(%rbp)
leaq -0x128(%rbp), %rsi
callq 0x18340
movq -0x3e0(%rbp), %rdi
movq -0x448(%rbp), %rsi
callq 0x162a0
jmp 0x166b1
leaq -0x3d8(%rbp), %rdi
callq 0x17830
jmp 0x166df
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x130(%rbp)
movl %eax, -0x134(%rbp)
leaq -0x3d8(%rbp), %rdi
callq 0x17830
jmp 0x166f0
leaq -0x128(%rbp), %rdi
callq 0x17830
jmp 0x163a3
leaq -0x128(%rbp), %rdi
callq 0x17830
jmp 0x16707
addq $0x450, %rsp # imm = 0x450
popq %rbp
retq
movq -0x130(%rbp), %rdi
callq 0x7210
nopw %cs:(%rax,%rax)
| _ZN7GoodASM12loadFragmentE7QString10QByteArrayS0_:
push rbp
mov rbp, rsp
sub rsp, 450h
mov [rbp+var_3F8], rsi
mov [rbp+var_3F0], rdx
mov [rbp+var_3E8], rcx
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_3E0], rax
mov [rbp+var_48], 0
loc_163A3:
mov rdi, [rbp+var_3F0]; this
mov rax, [rbp+var_48]
mov [rbp+var_400], rax
call _ZNK10QByteArray6lengthEv; QByteArray::length(void)
mov rcx, rax
mov rax, [rbp+var_400]
cmp rax, rcx
jnb loc_166FE
mov [rbp+var_50], 0
loc_163D4:
mov rcx, [rbp+var_3E0]
mov eax, [rbp+var_50]
mov rcx, [rcx+38h]
movzx ecx, byte ptr [rcx+43h]
cmp eax, ecx
jge short loc_1645B
mov rdi, [rbp+var_3F0]; this
movsxd rax, [rbp+var_50]
add rax, [rbp+var_48]
mov [rbp+var_408], rax
call _ZNK10QByteArray6lengthEv; QByteArray::length(void)
mov rcx, rax
mov rax, [rbp+var_408]
cmp rax, rcx
jnb short loc_16433
mov rdi, [rbp+var_3F0]; this
movsxd rsi, [rbp+var_50]
add rsi, [rbp+var_48]; __int64
call _ZNK10QByteArray2atEx; QByteArray::at(long long)
movsx eax, al
mov [rbp+var_40C], eax
jmp short loc_1643D
loc_16433:
xor eax, eax
mov [rbp+var_40C], eax
jmp short $+2
loc_1643D:
mov eax, [rbp+var_40C]
mov cl, al
movsxd rax, [rbp+var_50]
mov byte ptr [rbp+rax+var_40], cl
mov eax, [rbp+var_50]
add eax, 1
mov [rbp+var_50], eax
jmp loc_163D4
loc_1645B:
mov rax, [rbp+var_3E0]
mov rsi, [rax+38h]; unsigned __int64
mov rdx, [rax+138h]; char *
lea rdi, [rbp+var_128]; this
lea rcx, [rbp+var_40]; unsigned int *
lea r8, [rbp+var_4C]
call _ZN10GALanguage6decodeEmPcRj; GALanguage::decode(ulong,char *,uint &)
mov rsi, [rbp+var_3E8]
lea rdi, [rbp+var_A8]
call __ZN7QStringaSERKS_; QString::operator=(QString const&)
mov rdi, [rbp+var_3F8]; this
call _ZNK7QString6lengthEv; QString::length(void)
mov [rbp+var_418], rax
jmp short $+2
loc_164A9:
mov rax, [rbp+var_418]
cmp rax, 0
jle short loc_164F7
mov rsi, [rbp+var_3F8]
lea rdi, [rbp+var_118]
call __ZN7QStringaSERKS_; QString::operator=(QString const&)
mov rdi, [rbp+var_3F8]
lea rsi, byte_11A0C8
call _ZN7QStringaSEPKc; QString::operator=(char const*)
jmp short $+2
loc_164DE:
jmp short loc_164F7
mov rcx, rax
mov eax, edx
mov [rbp+var_130], rcx
mov [rbp+var_134], eax
jmp loc_166F0
loc_164F7:
mov rdi, [rbp+var_3F0]; this
mov rax, [rbp+var_48]
mov ecx, [rbp+var_4C]
add rax, rcx
mov [rbp+var_428], rax
call _ZNK10QByteArray6lengthEv; QByteArray::length(void)
mov [rbp+var_420], rax
jmp short $+2
loc_1651D:
mov rax, [rbp+var_428]
mov rcx, [rbp+var_420]
cmp rax, rcx
jbe loc_16672
mov rsi, [rbp+var_3E0]; GoodASM *
movzx edx, byte ptr [rbp+var_40]; unsigned __int8
lea rdi, [rbp+var_210]; this
call _ZN13GAInstructionC2EP7GoodASMh; GAInstruction::GAInstruction(GoodASM *,uchar)
jmp short $+2
loc_1654D:
mov rsi, [rbp+var_3E8]
lea rdx, aData; " (data)"
lea rdi, [rbp+var_228]
call _ZplRK7QStringPKc; operator+(QString const&,char const*)
jmp short $+2
loc_16569:
lea rdi, [rbp+var_190]
lea rsi, [rbp+var_228]
mov [rbp+var_438], rsi
call __ZN7QStringaSERKS_; QString::operator=(QString const&)
mov rdi, [rbp+var_438]; this
call _ZN7QStringD2Ev; QString::~QString()
mov rdi, [rbp+var_3F8]; this
call _ZNK7QString6lengthEv; QString::length(void)
mov [rbp+var_430], rax
jmp short $+2
loc_165A4:
mov rax, [rbp+var_430]
cmp rax, 0
jle short loc_165EF
mov rsi, [rbp+var_3F8]
lea rdi, [rbp+var_200]
call __ZN7QStringaSERKS_; QString::operator=(QString const&)
mov rdi, [rbp+var_3F8]
lea rsi, byte_11A0C8
call _ZN7QStringaSEPKc; QString::operator=(char const*)
jmp short $+2
loc_165D9:
jmp short loc_165EF
mov rcx, rax
mov eax, edx
mov [rbp+var_130], rcx
mov [rbp+var_134], eax
jmp short loc_16664
loc_165EF:
mov rax, [rbp+var_48]
inc rax
mov [rbp+var_48], rax
lea rdi, [rbp+var_300]; this
mov [rbp+var_440], rdi
lea rsi, [rbp+var_210]; GAInstruction *
call _ZN13GAInstructionC2ERKS_; GAInstruction::GAInstruction(GAInstruction const&)
mov rdi, [rbp+var_3E0]
mov rsi, [rbp+var_440]
call _ZN7GoodASM6appendE13GAInstruction; GoodASM::append(GAInstruction)
jmp short $+2
loc_16629:
lea rdi, [rbp+var_300]; this
call _ZN13GAInstructionD2Ev; GAInstruction::~GAInstruction()
lea rdi, [rbp+var_210]; this
call _ZN13GAInstructionD2Ev; GAInstruction::~GAInstruction()
jmp loc_166DF
mov rcx, rax
mov eax, edx
mov [rbp+var_130], rcx
mov [rbp+var_134], eax
lea rdi, [rbp+var_300]; this
call _ZN13GAInstructionD2Ev; GAInstruction::~GAInstruction()
loc_16664:
lea rdi, [rbp+var_210]; this
call _ZN13GAInstructionD2Ev; GAInstruction::~GAInstruction()
jmp short loc_166F0
loc_16672:
mov eax, [rbp+var_4C]
mov ecx, eax
mov rax, [rbp+var_48]
add rax, rcx
mov [rbp+var_48], rax
lea rdi, [rbp+var_3D8]; this
mov [rbp+var_448], rdi
lea rsi, [rbp+var_128]; GAInstruction *
call _ZN13GAInstructionC2ERKS_; GAInstruction::GAInstruction(GAInstruction const&)
mov rdi, [rbp+var_3E0]
mov rsi, [rbp+var_448]
call _ZN7GoodASM6appendE13GAInstruction; GoodASM::append(GAInstruction)
jmp short $+2
loc_166B1:
lea rdi, [rbp+var_3D8]; this
call _ZN13GAInstructionD2Ev; GAInstruction::~GAInstruction()
jmp short loc_166DF
mov rcx, rax
mov eax, edx
mov [rbp+var_130], rcx
mov [rbp+var_134], eax
lea rdi, [rbp+var_3D8]; this
call _ZN13GAInstructionD2Ev; GAInstruction::~GAInstruction()
jmp short loc_166F0
loc_166DF:
lea rdi, [rbp+var_128]; this
call _ZN13GAInstructionD2Ev; GAInstruction::~GAInstruction()
jmp loc_163A3
loc_166F0:
lea rdi, [rbp+var_128]; this
call _ZN13GAInstructionD2Ev; GAInstruction::~GAInstruction()
jmp short loc_16707
loc_166FE:
add rsp, 450h
pop rbp
retn
loc_16707:
mov rdi, [rbp+var_130]
call __Unwind_Resume
| unsigned long long GoodASM::loadFragment(long long a1, QString *a2, QByteArray *a3, long long a4)
{
unsigned long long v4; // rcx
unsigned long long result; // rax
unsigned long long v6; // [rsp+28h] [rbp-428h]
char v7; // [rsp+44h] [rbp-40Ch]
unsigned long long v8; // [rsp+48h] [rbp-408h]
unsigned long long v9; // [rsp+50h] [rbp-400h]
unsigned int v12[54]; // [rsp+78h] [rbp-3D8h] BYREF
unsigned int v13[54]; // [rsp+150h] [rbp-300h] BYREF
_BYTE v14[24]; // [rsp+228h] [rbp-228h] BYREF
_BYTE v15[16]; // [rsp+240h] [rbp-210h] BYREF
char v16[112]; // [rsp+250h] [rbp-200h] BYREF
char v17[92]; // [rsp+2C0h] [rbp-190h] BYREF
_BYTE v18[16]; // [rsp+328h] [rbp-128h] BYREF
char v19[112]; // [rsp+338h] [rbp-118h] BYREF
char v20[88]; // [rsp+3A8h] [rbp-A8h] BYREF
int i; // [rsp+400h] [rbp-50h]
unsigned int v22; // [rsp+404h] [rbp-4Ch]
unsigned long long v23; // [rsp+408h] [rbp-48h]
unsigned int v24[8]; // [rsp+410h] [rbp-40h] BYREF
long long v25; // [rsp+430h] [rbp-20h]
QByteArray *v26; // [rsp+438h] [rbp-18h]
QString *v27; // [rsp+440h] [rbp-10h]
long long v28; // [rsp+448h] [rbp-8h]
v28 = a1;
v27 = a2;
v26 = a3;
v25 = a4;
v23 = 0LL;
while ( 1 )
{
v9 = v23;
v4 = QByteArray::length(a3);
result = v9;
if ( v9 >= v4 )
break;
for ( i = 0; i < *(unsigned __int8 *)(*(_QWORD *)(a1 + 56) + 67LL); ++i )
{
v8 = v23 + i;
if ( v8 >= QByteArray::length(a3) )
v7 = 0;
else
v7 = QByteArray::at(a3, v23 + i);
*((_BYTE *)v24 + i) = v7;
}
GALanguage::decode((GALanguage *)v18, *(_QWORD *)(a1 + 56), *(char **)(a1 + 312), v24);
QString::operator=(v20, a4);
if ( QString::length(a2) > 0 )
{
QString::operator=(v19, a2);
QString::operator=((long long)a2, (long long)&byte_11A0C8);
}
v6 = v22 + v23;
if ( v6 <= QByteArray::length(a3) )
{
v23 += v22;
GAInstruction::GAInstruction((GAInstruction *)v12, (const GAInstruction *)v18);
GoodASM::append(a1, v12);
GAInstruction::~GAInstruction((GAInstruction *)v12);
}
else
{
GAInstruction::GAInstruction((GAInstruction *)v15, (GoodASM *)a1, v24[0]);
operator+(v14, a4, " (data)");
QString::operator=(v17, v14);
QString::~QString((QString *)v14);
if ( QString::length(a2) > 0 )
{
QString::operator=(v16, a2);
QString::operator=((long long)a2, (long long)&byte_11A0C8);
}
++v23;
GAInstruction::GAInstruction((GAInstruction *)v13, (const GAInstruction *)v15);
GoodASM::append(a1, v13);
GAInstruction::~GAInstruction((GAInstruction *)v13);
GAInstruction::~GAInstruction((GAInstruction *)v15);
}
GAInstruction::~GAInstruction((GAInstruction *)v18);
}
return result;
}
| loadFragment:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x450
MOV qword ptr [RBP + -0x3f8],RSI
MOV qword ptr [RBP + -0x3f0],RDX
MOV qword ptr [RBP + -0x3e8],RCX
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x3e0],RAX
MOV qword ptr [RBP + -0x48],0x0
LAB_001163a3:
MOV RDI,qword ptr [RBP + -0x3f0]
MOV RAX,qword ptr [RBP + -0x48]
MOV qword ptr [RBP + -0x400],RAX
CALL 0x0010f5b0
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x400]
CMP RAX,RCX
JNC 0x001166fe
MOV dword ptr [RBP + -0x50],0x0
LAB_001163d4:
MOV RCX,qword ptr [RBP + -0x3e0]
MOV EAX,dword ptr [RBP + -0x50]
MOV RCX,qword ptr [RCX + 0x38]
MOVZX ECX,byte ptr [RCX + 0x43]
CMP EAX,ECX
JGE 0x0011645b
MOV RDI,qword ptr [RBP + -0x3f0]
MOVSXD RAX,dword ptr [RBP + -0x50]
ADD RAX,qword ptr [RBP + -0x48]
MOV qword ptr [RBP + -0x408],RAX
CALL 0x0010f5b0
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x408]
CMP RAX,RCX
JNC 0x00116433
MOV RDI,qword ptr [RBP + -0x3f0]
MOVSXD RSI,dword ptr [RBP + -0x50]
ADD RSI,qword ptr [RBP + -0x48]
CALL 0x00118650
MOVSX EAX,AL
MOV dword ptr [RBP + -0x40c],EAX
JMP 0x0011643d
LAB_00116433:
XOR EAX,EAX
MOV dword ptr [RBP + -0x40c],EAX
JMP 0x0011643d
LAB_0011643d:
MOV EAX,dword ptr [RBP + -0x40c]
MOV CL,AL
MOVSXD RAX,dword ptr [RBP + -0x50]
MOV byte ptr [RBP + RAX*0x1 + -0x40],CL
MOV EAX,dword ptr [RBP + -0x50]
ADD EAX,0x1
MOV dword ptr [RBP + -0x50],EAX
JMP 0x001163d4
LAB_0011645b:
MOV RAX,qword ptr [RBP + -0x3e0]
MOV RSI,qword ptr [RAX + 0x38]
MOV RDX,qword ptr [RAX + 0x138]
LEA RDI,[RBP + -0x128]
LEA RCX,[RBP + -0x40]
LEA R8,[RBP + -0x4c]
CALL 0x0013d8b0
MOV RSI,qword ptr [RBP + -0x3e8]
LEA RDI,[RBP + -0xa8]
CALL 0x001077e0
MOV RDI,qword ptr [RBP + -0x3f8]
LAB_0011649b:
CALL 0x0010f8b0
MOV qword ptr [RBP + -0x418],RAX
JMP 0x001164a9
LAB_001164a9:
MOV RAX,qword ptr [RBP + -0x418]
CMP RAX,0x0
JLE 0x001164f7
MOV RSI,qword ptr [RBP + -0x3f8]
LEA RDI,[RBP + -0x118]
CALL 0x001077e0
MOV RDI,qword ptr [RBP + -0x3f8]
LEA RSI,[0x21a0c8]
CALL 0x0010e890
JMP 0x001164de
LAB_001164de:
JMP 0x001164f7
LAB_001164f7:
MOV RDI,qword ptr [RBP + -0x3f0]
MOV RAX,qword ptr [RBP + -0x48]
MOV ECX,dword ptr [RBP + -0x4c]
ADD RAX,RCX
MOV qword ptr [RBP + -0x428],RAX
CALL 0x0010f5b0
MOV qword ptr [RBP + -0x420],RAX
JMP 0x0011651d
LAB_0011651d:
MOV RAX,qword ptr [RBP + -0x428]
MOV RCX,qword ptr [RBP + -0x420]
CMP RAX,RCX
JBE 0x00116672
MOV RSI,qword ptr [RBP + -0x3e0]
MOVZX EDX,byte ptr [RBP + -0x40]
LEA RDI,[RBP + -0x210]
CALL 0x00206f40
JMP 0x0011654d
LAB_0011654d:
MOV RSI,qword ptr [RBP + -0x3e8]
LEA RDX,[0x2109c1]
LEA RDI,[RBP + -0x228]
CALL 0x001178b0
JMP 0x00116569
LAB_00116569:
LEA RDI,[RBP + -0x190]
LEA RSI,[RBP + -0x228]
MOV qword ptr [RBP + -0x438],RSI
CALL 0x001077e0
MOV RDI,qword ptr [RBP + -0x438]
CALL 0x0010e770
MOV RDI,qword ptr [RBP + -0x3f8]
CALL 0x0010f8b0
MOV qword ptr [RBP + -0x430],RAX
JMP 0x001165a4
LAB_001165a4:
MOV RAX,qword ptr [RBP + -0x430]
CMP RAX,0x0
JLE 0x001165ef
MOV RSI,qword ptr [RBP + -0x3f8]
LEA RDI,[RBP + -0x200]
CALL 0x001077e0
MOV RDI,qword ptr [RBP + -0x3f8]
LEA RSI,[0x21a0c8]
CALL 0x0010e890
JMP 0x001165d9
LAB_001165d9:
JMP 0x001165ef
LAB_001165ef:
MOV RAX,qword ptr [RBP + -0x48]
INC RAX
MOV qword ptr [RBP + -0x48],RAX
LEA RDI,[RBP + -0x300]
MOV qword ptr [RBP + -0x440],RDI
LEA RSI,[RBP + -0x210]
CALL 0x00118340
MOV RDI,qword ptr [RBP + -0x3e0]
MOV RSI,qword ptr [RBP + -0x440]
LAB_00116622:
CALL 0x001162a0
JMP 0x00116629
LAB_00116629:
LEA RDI,[RBP + -0x300]
CALL 0x00117830
LEA RDI,[RBP + -0x210]
CALL 0x00117830
JMP 0x001166df
LAB_00116672:
MOV EAX,dword ptr [RBP + -0x4c]
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x48]
ADD RAX,RCX
MOV qword ptr [RBP + -0x48],RAX
LEA RDI,[RBP + -0x3d8]
MOV qword ptr [RBP + -0x448],RDI
LEA RSI,[RBP + -0x128]
CALL 0x00118340
MOV RDI,qword ptr [RBP + -0x3e0]
MOV RSI,qword ptr [RBP + -0x448]
LAB_001166aa:
CALL 0x001162a0
LAB_001166af:
JMP 0x001166b1
LAB_001166b1:
LEA RDI,[RBP + -0x3d8]
CALL 0x00117830
JMP 0x001166df
LAB_001166df:
LEA RDI,[RBP + -0x128]
CALL 0x00117830
JMP 0x001163a3
LAB_001166fe:
ADD RSP,0x450
POP RBP
RET
|
/* GoodASM::loadFragment(QString, QByteArray, QString) */
void __thiscall
GoodASM::loadFragment(GoodASM *this,QString *param_2,QByteArray *param_3,QString *param_4)
{
uchar uVar1;
ulong uVar2;
ulong uVar3;
long lVar4;
GAInstruction local_3e0 [216];
GAInstruction local_308 [216];
QString local_230 [24];
GAInstruction local_218 [16];
QString local_208 [112];
QString local_198 [104];
GAInstruction local_130 [16];
QString local_120 [112];
QString local_b0 [88];
int local_58;
uint local_54;
ulong local_50;
uchar local_48 [32];
QString *local_28;
QByteArray *local_20;
QString *local_18;
GoodASM *local_10;
local_50 = 0;
local_28 = param_4;
local_20 = param_3;
local_18 = param_2;
local_10 = this;
while( true ) {
uVar3 = local_50;
uVar2 = QByteArray::length(param_3);
if (uVar2 <= uVar3) break;
for (local_58 = 0; local_58 < (int)(uint)*(byte *)(*(long *)(this + 0x38) + 0x43);
local_58 = local_58 + 1) {
uVar3 = (long)local_58 + local_50;
uVar2 = QByteArray::length(param_3);
if (uVar3 < uVar2) {
uVar1 = QByteArray::at(param_3,(long)local_58 + local_50);
}
else {
uVar1 = '\0';
}
local_48[local_58] = uVar1;
}
GALanguage::decode((ulong)local_130,*(char **)(this + 0x38),*(uint **)(this + 0x138));
QString::operator=(local_b0,param_4);
/* try { // try from 0011649b to 0011654a has its CatchHandler @ 001164e0 */
lVar4 = QString::length(param_2);
if (0 < lVar4) {
QString::operator=(local_120,param_2);
QString::operator=(param_2,"");
}
uVar3 = local_50 + local_54;
uVar2 = QByteArray::length(param_3);
if (uVar2 < uVar3) {
GAInstruction::GAInstruction(local_218,this,local_48[0]);
/* try { // try from 0011654d to 001165d6 has its CatchHandler @ 001165db */
operator+(local_230,(char *)param_4);
QString::operator=(local_198,local_230);
QString::~QString(local_230);
lVar4 = QString::length(param_2);
if (0 < lVar4) {
QString::operator=(local_208,param_2);
QString::operator=(param_2,"");
}
local_50 = local_50 + 1;
GAInstruction::GAInstruction(local_308,local_218);
/* try { // try from 00116622 to 00116626 has its CatchHandler @ 00116646 */
append(this,local_308);
GAInstruction::~GAInstruction(local_308);
GAInstruction::~GAInstruction(local_218);
}
else {
local_50 = local_50 + local_54;
GAInstruction::GAInstruction(local_3e0,local_130);
/* try { // try from 001166aa to 001166ae has its CatchHandler @ 001166bf */
append(this,local_3e0);
GAInstruction::~GAInstruction(local_3e0);
}
GAInstruction::~GAInstruction(local_130);
}
return;
}
| |
38,026 | Prepared_statement::setup_set_params() | eloqsql/sql/sql_prepare.cc | void Prepared_statement::setup_set_params()
{
/*
Note: BUG#25843 applies here too (query cache lookup uses thd->db, not
db from "prepare" time).
*/
if (query_cache_maybe_disabled(thd)) // we won't expand the query
lex->safe_to_cache_query= FALSE; // so don't cache it at Execution
/*
Decide if we have to expand the query (because we must write it to logs or
because we want to look it up in the query cache) or not.
*/
bool replace_params_with_values= false;
// binlog
replace_params_with_values|= mysql_bin_log.is_open() && is_update_query(lex->sql_command);
// general or slow log
replace_params_with_values|= opt_log || thd->variables.sql_log_slow;
// query cache
replace_params_with_values|= query_cache_is_cacheable_query(lex);
// but never for compound statements
replace_params_with_values&= lex->sql_command != SQLCOM_COMPOUND;
if (replace_params_with_values)
{
set_params_from_actual_params= insert_params_from_actual_params_with_log;
#ifndef EMBEDDED_LIBRARY
set_params= insert_params_with_log;
set_bulk_params= insert_bulk_params; // RBR is on for bulk operation
#else
//TODO: add bulk support for bulk parameters
set_params_data= emb_insert_params_with_log;
#endif
}
else
{
set_params_from_actual_params= insert_params_from_actual_params;
#ifndef EMBEDDED_LIBRARY
set_params= insert_params;
set_bulk_params= insert_bulk_params;
#else
//TODO: add bulk support for bulk parameters
set_params_data= emb_insert_params;
#endif
}
} | O3 | cpp | Prepared_statement::setup_set_params():
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0xc0(%rdi), %rax
cmpq $0x0, 0xad0(%rax)
je 0x772101
leaq 0xde6415(%rip), %rax # 0x1558510
cmpq $0x0, (%rax)
jne 0x77210f
movq 0x58(%rbx), %rax
andl $0xfffff7ff, 0x17c6(%rax) # imm = 0xFFFFF7FF
leaq 0xe14b82(%rip), %rax # 0x1586c98
movl 0x444(%rax), %ecx
xorl %eax, %eax
cmpl $0x1, %ecx
je 0x772132
movq 0x58(%rbx), %rax
movl 0x8(%rax), %edi
callq 0x75940f
movzbl %al, %eax
leaq 0xde2dd7(%rip), %rdx # 0x1554f10
movl $0x1, %ecx
cmpb $0x0, (%rdx)
jne 0x772156
movq 0xc0(%rbx), %rdx
xorl %ecx, %ecx
cmpb $0x0, 0xb25(%rdx)
setne %cl
movq 0x58(%rbx), %rdi
movl 0x8(%rdi), %edx
xorl %esi, %esi
testl %edx, %edx
jne 0x77216f
movl 0x17c6(%rdi), %esi
shrl $0xb, %esi
andl $0x1, %esi
orl %eax, %ecx
orl %esi, %ecx
cmpl $0x8e, %edx
sete %al
testl %ecx, %ecx
sete %cl
orb %al, %cl
leaq 0x42f(%rip), %rax # 0x7725b9
leaq 0x39(%rip), %rcx # 0x7721ca
cmovneq %rax, %rcx
leaq 0x4ae(%rip), %rax # 0x77264a
leaq 0x10b(%rip), %rdx # 0x7722ae
cmovneq %rax, %rdx
movq %rcx, 0x368(%rbx)
movq %rdx, 0x358(%rbx)
leaq 0x2d3(%rip), %rax # 0x77248f
movq %rax, 0x360(%rbx)
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
| _ZN18Prepared_statement16setup_set_paramsEv:
push rbp
mov rbp, rsp
push rbx
push rax
mov rbx, rdi
mov rax, [rdi+0C0h]
cmp qword ptr [rax+0AD0h], 0
jz short loc_772101
lea rax, query_cache
cmp qword ptr [rax], 0
jnz short loc_77210F
loc_772101:
mov rax, [rbx+58h]
and dword ptr [rax+17C6h], 0FFFFF7FFh
loc_77210F:
lea rax, mysql_bin_log
mov ecx, [rax+444h]
xor eax, eax
cmp ecx, 1
jz short loc_772132
mov rax, [rbx+58h]
mov edi, [rax+8]
call _Z15is_update_query16enum_sql_command; is_update_query(enum_sql_command)
movzx eax, al
loc_772132:
lea rdx, opt_log
mov ecx, 1
cmp byte ptr [rdx], 0
jnz short loc_772156
mov rdx, [rbx+0C0h]
xor ecx, ecx
cmp byte ptr [rdx+0B25h], 0
setnz cl
loc_772156:
mov rdi, [rbx+58h]
mov edx, [rdi+8]
xor esi, esi
test edx, edx
jnz short loc_77216F
mov esi, [rdi+17C6h]
shr esi, 0Bh
and esi, 1
loc_77216F:
or ecx, eax
or ecx, esi
cmp edx, 8Eh
setz al
test ecx, ecx
setz cl
or cl, al
lea rax, _ZL32insert_params_from_actual_paramsP18Prepared_statementR4ListI4ItemEP6String; insert_params_from_actual_params(Prepared_statement *,List<Item> &,String *)
lea rcx, _ZL41insert_params_from_actual_params_with_logP18Prepared_statementR4ListI4ItemEP6String; insert_params_from_actual_params_with_log(Prepared_statement *,List<Item> &,String *)
cmovnz rcx, rax
lea rax, _ZL13insert_paramsP18Prepared_statementPhS1_S1_P6String; insert_params(Prepared_statement *,uchar *,uchar *,uchar *,String *)
lea rdx, _ZL22insert_params_with_logP18Prepared_statementPhS1_S1_P6String; insert_params_with_log(Prepared_statement *,uchar *,uchar *,uchar *,String *)
cmovnz rdx, rax
mov [rbx+368h], rcx
mov [rbx+358h], rdx
lea rax, _ZL18insert_bulk_paramsP18Prepared_statementPPhS1_b; insert_bulk_params(Prepared_statement *,uchar **,uchar *,bool)
mov [rbx+360h], rax
add rsp, 8
pop rbx
pop rbp
retn
| long long ( * Prepared_statement::setup_set_params(
Prepared_statement *this))(Prepared_statement *, unsigned __int8 **, unsigned __int8 *, bool)
{
int updated; // eax
BOOL v3; // ecx
long long v4; // rdi
int v5; // edx
int v6; // esi
bool v7; // zf
long long ( *v8)(); // rcx
long long ( *v9)(Prepared_statement *, unsigned __int8 *, unsigned __int8 *, unsigned __int8 *, String *); // rdx
long long ( *result)(Prepared_statement *, unsigned __int8 **, unsigned __int8 *, bool); // rax
if ( !*(_QWORD *)(*((_QWORD *)this + 24) + 2768LL) || !query_cache )
*(_DWORD *)(*((_QWORD *)this + 11) + 6086LL) &= ~0x800u;
updated = 0;
if ( *((_DWORD *)&mysql_bin_log + 273) != 1 )
updated = (unsigned __int8)is_update_query(*(_DWORD *)(*((_QWORD *)this + 11) + 8LL));
v3 = 1;
if ( !opt_log )
v3 = *(_BYTE *)(*((_QWORD *)this + 24) + 2853LL) != 0;
v4 = *((_QWORD *)this + 11);
v5 = *(_DWORD *)(v4 + 8);
v6 = 0;
if ( !v5 )
v6 = (*(_DWORD *)(v4 + 6086) >> 11) & 1;
v7 = v5 != 142 && (v6 | updated | v3) != 0;
v8 = insert_params_from_actual_params_with_log;
if ( !v7 )
v8 = insert_params_from_actual_params;
v9 = insert_params_with_log;
if ( !v7 )
v9 = insert_params;
*((_QWORD *)this + 109) = v8;
*((_QWORD *)this + 107) = v9;
result = insert_bulk_params;
*((_QWORD *)this + 108) = insert_bulk_params;
return result;
}
| row_merge_buf_add:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RDI
MOV R14,qword ptr [RDI]
TEST R14,R14
JZ 0x0077214c
MOV R15D,ESI
MOV RAX,qword ptr [RDX + 0x10]
MOV R12,qword ptr [RAX + 0x48]
LEA R13D,[R15 + 0x7]
AND R13D,0xfffffff8
LEA RCX,[R12 + R13*0x1]
CMP qword ptr [RAX + 0x30],RCX
JNC 0x00772125
MOV RDI,RDX
MOV RSI,R15
CALL 0x00c6d654
MOV R12,qword ptr [RAX + 0x48]
ADD R13,R12
MOV RCX,R13
LAB_00772125:
ADD R12,RAX
MOV qword ptr [RAX + 0x48],RCX
MOV RDI,R12
MOV RSI,R14
MOV RDX,R15
CALL 0x0071b1b0
LAB_0077213a:
MOV qword ptr [RBX],R12
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0077214c:
XOR R12D,R12D
JMP 0x0077213a
|
/* row_merge_buf_add(row_merge_buf_t*, dict_index_t*, dict_table_t const*, dict_table_t const*,
fts_psort_t*, dtuple_t*, row_ext_t const*, unsigned long*, mem_block_info_t*, dberr_t*,
mem_block_info_t**, TABLE*, trx_t*, std::map<unsigned int, dict_col_t*, std::less<unsigned int>,
std::allocator<std::pair<unsigned int const, dict_col_t*> > > const*) [clone .cold.5] */
void row_merge_buf_add(row_merge_buf_t *param_1,dict_index_t *param_2,dict_table_t *param_3,
dict_table_t *param_4,fts_psort_t *param_5,dtuple_t *param_6,
row_ext_t *param_7,ulong *param_8,mem_block_info_t *param_9,dberr_t *param_10,
mem_block_info_t **param_11,TABLE *param_12,trx_t *param_13,map *param_14)
{
void *__src;
long lVar1;
void *__dest;
ulong uVar3;
ulong uVar4;
long lVar2;
__src = *(void **)param_1;
if (__src == (void *)0x0) {
__dest = (void *)0x0;
}
else {
lVar1 = *(long *)(param_3 + 0x10);
lVar2 = *(long *)(lVar1 + 0x48);
uVar3 = (ulong)((int)param_2 + 7U & 0xfffffff8);
uVar4 = lVar2 + uVar3;
if (*(ulong *)(lVar1 + 0x30) < uVar4) {
lVar1 = mem_heap_add_block((mem_block_info_t *)param_3,(ulong)param_2 & 0xffffffff);
lVar2 = *(long *)(lVar1 + 0x48);
uVar4 = uVar3 + lVar2;
}
__dest = (void *)(lVar2 + lVar1);
*(ulong *)(lVar1 + 0x48) = uVar4;
memcpy(__dest,__src,(ulong)param_2 & 0xffffffff);
}
*(void **)param_1 = __dest;
return;
}
| |
38,027 | my_init_mysys_psi_keys | eloqsql/mysys/my_init.c | void my_init_mysys_psi_keys()
{
const char* category= "mysys";
int count;
count= sizeof(all_mysys_mutexes)/sizeof(all_mysys_mutexes[0]);
mysql_mutex_register(category, all_mysys_mutexes, count);
count= sizeof(all_mysys_conds)/sizeof(all_mysys_conds[0]);
mysql_cond_register(category, all_mysys_conds, count);
count= sizeof(all_mysys_rwlocks)/sizeof(all_mysys_rwlocks[0]);
mysql_rwlock_register(category, all_mysys_rwlocks, count);
count= sizeof(all_mysys_threads)/sizeof(all_mysys_threads[0]);
mysql_thread_register(category, all_mysys_threads, count);
count= sizeof(all_mysys_files)/sizeof(all_mysys_files[0]);
mysql_file_register(category, all_mysys_files, count);
count= array_elements(all_mysys_stages);
mysql_stage_register(category, all_mysys_stages, count);
} | O3 | c | my_init_mysys_psi_keys:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x2e692f(%rip), %r14 # 0x386010
movq (%r14), %rax
leaq 0x3ce5b(%rip), %rbx # 0xdc546
leaq 0x2e610e(%rip), %rsi # 0x385800
movq %rbx, %rdi
movl $0x13, %edx
callq *(%rax)
movq (%r14), %rax
leaq 0x2e62ca(%rip), %rsi # 0x3859d0
movq %rbx, %rdi
movl $0x7, %edx
callq *0x10(%rax)
movq (%r14), %rax
leaq 0x2e6365(%rip), %rsi # 0x385a80
movq %rbx, %rdi
movl $0x1, %edx
callq *0x8(%rax)
movq (%r14), %rax
leaq 0x2e6370(%rip), %rsi # 0x385aa0
movq %rbx, %rdi
movl $0x1, %edx
callq *0x18(%rax)
movq (%r14), %rax
leaq 0x2e637b(%rip), %rsi # 0x385ac0
movq %rbx, %rdi
movl $0x2, %edx
callq *0x20(%rax)
movq (%r14), %rax
movq 0x28(%rax), %rax
leaq 0x2e6092(%rip), %rsi # 0x3857f0
movq %rbx, %rdi
movl $0x1, %edx
popq %rbx
popq %r14
popq %rbp
jmpq *%rax
| my_init_mysys_psi_keys:
push rbp
mov rbp, rsp
push r14
push rbx
lea r14, PSI_server
mov rax, [r14]
lea rbx, aMysys; "mysys"
lea rsi, all_mysys_mutexes
mov rdi, rbx
mov edx, 13h
call qword ptr [rax]
mov rax, [r14]
lea rsi, all_mysys_conds
mov rdi, rbx
mov edx, 7
call qword ptr [rax+10h]
mov rax, [r14]
lea rsi, all_mysys_rwlocks
mov rdi, rbx
mov edx, 1
call qword ptr [rax+8]
mov rax, [r14]
lea rsi, all_mysys_threads
mov rdi, rbx
mov edx, 1
call qword ptr [rax+18h]
mov rax, [r14]
lea rsi, all_mysys_files
mov rdi, rbx
mov edx, 2
call qword ptr [rax+20h]
mov rax, [r14]
mov rax, [rax+28h]
lea rsi, all_mysys_stages
mov rdi, rbx
mov edx, 1
pop rbx
pop r14
pop rbp
jmp rax
| long long my_init_mysys_psi_keys()
{
((void ( *)(const char *, _UNKNOWN **, long long))*PSI_server)("mysys", &all_mysys_mutexes, 19LL);
((void ( *)(const char *, _UNKNOWN **, long long))PSI_server[2])("mysys", &all_mysys_conds, 7LL);
((void ( *)(const char *, _UNKNOWN **, long long))PSI_server[1])("mysys", &all_mysys_rwlocks, 1LL);
((void ( *)(const char *, _UNKNOWN **, long long))PSI_server[3])("mysys", &all_mysys_threads, 1LL);
((void ( *)(const char *, _UNKNOWN **, long long))PSI_server[4])("mysys", &all_mysys_files, 2LL);
return ((long long ( *)(const char *, _UNKNOWN **, long long))PSI_server[5])("mysys", &all_mysys_stages, 1LL);
}
| my_init_mysys_psi_keys:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
LEA R14,[0x486010]
MOV RAX,qword ptr [R14]
LEA RBX,[0x1dc546]
LEA RSI,[0x485800]
MOV RDI,RBX
MOV EDX,0x13
CALL qword ptr [RAX]
MOV RAX,qword ptr [R14]
LEA RSI,[0x4859d0]
MOV RDI,RBX
MOV EDX,0x7
CALL qword ptr [RAX + 0x10]
MOV RAX,qword ptr [R14]
LEA RSI,[0x485a80]
MOV RDI,RBX
MOV EDX,0x1
CALL qword ptr [RAX + 0x8]
MOV RAX,qword ptr [R14]
LEA RSI,[0x485aa0]
MOV RDI,RBX
MOV EDX,0x1
CALL qword ptr [RAX + 0x18]
MOV RAX,qword ptr [R14]
LEA RSI,[0x485ac0]
MOV RDI,RBX
MOV EDX,0x2
CALL qword ptr [RAX + 0x20]
MOV RAX,qword ptr [R14]
MOV RAX,qword ptr [RAX + 0x28]
LEA RSI,[0x4857f0]
MOV RDI,RBX
MOV EDX,0x1
POP RBX
POP R14
POP RBP
JMP RAX
|
void my_init_mysys_psi_keys(void)
{
(**(code **)PSI_server)("mysys",all_mysys_mutexes,0x13);
(**(code **)(PSI_server + 0x10))("mysys",all_mysys_conds,7);
(**(code **)(PSI_server + 8))("mysys",all_mysys_rwlocks,1);
(**(code **)(PSI_server + 0x18))("mysys",all_mysys_threads,1);
(**(code **)(PSI_server + 0x20))("mysys",all_mysys_files,2);
/* WARNING: Could not recover jumptable at 0x0019f76a. Too many branches */
/* WARNING: Treating indirect jump as call */
(**(code **)(PSI_server + 0x28))("mysys",&all_mysys_stages,1);
return;
}
| |
38,028 | json_parse_error | bluesky950520[P]quickjs/quickjs.c | static int json_parse_error(JSParseState *s, const uint8_t *curp, const char *msg)
{
const uint8_t *p, *line_start;
int position = curp - s->buf_start;
int line = 1;
for (line_start = p = s->buf_start; p < curp; p++) {
/* column count does not account for TABs nor wide characters */
if (*p == '\r' || *p == '\n') {
p += 1 + (p[0] == '\r' && p[1] == '\n');
line++;
line_start = p;
}
}
return js_parse_error(s, "%s in JSON at position %d (line %d column %d)",
msg, position, line, (int)(p - line_start) + 1);
} | O0 | c | json_parse_error:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
movq %rdx, 0x20(%rsp)
movq 0x28(%rsp), %rax
movq 0x30(%rsp), %rcx
movq 0x68(%rcx), %rcx
subq %rcx, %rax
movl %eax, 0xc(%rsp)
movl $0x1, 0x8(%rsp)
movq 0x30(%rsp), %rax
movq 0x68(%rax), %rax
movq %rax, 0x18(%rsp)
movq %rax, 0x10(%rsp)
movq 0x18(%rsp), %rax
cmpq 0x28(%rsp), %rax
jae 0x86ac9
movq 0x18(%rsp), %rax
movzbl (%rax), %eax
cmpl $0xd, %eax
je 0x86a5d
movq 0x18(%rsp), %rax
movzbl (%rax), %eax
cmpl $0xa, %eax
jne 0x86ab4
movq 0x18(%rsp), %rax
movzbl (%rax), %ecx
xorl %eax, %eax
cmpl $0xd, %ecx
movb %al, 0x7(%rsp)
jne 0x86a83
movq 0x18(%rsp), %rax
movzbl 0x1(%rax), %eax
cmpl $0xa, %eax
sete %al
movb %al, 0x7(%rsp)
movb 0x7(%rsp), %al
andb $0x1, %al
movzbl %al, %ecx
addl $0x1, %ecx
movq 0x18(%rsp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, 0x18(%rsp)
movl 0x8(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x8(%rsp)
movq 0x18(%rsp), %rax
movq %rax, 0x10(%rsp)
jmp 0x86ab6
movq 0x18(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x18(%rsp)
jmp 0x86a33
movq 0x30(%rsp), %rdi
movq 0x20(%rsp), %rdx
movl 0xc(%rsp), %ecx
movl 0x8(%rsp), %r8d
movq 0x18(%rsp), %rax
movq 0x10(%rsp), %rsi
subq %rsi, %rax
movl %eax, %r9d
addl $0x1, %r9d
leaq 0x882cf(%rip), %rsi # 0x10edc6
movb $0x0, %al
callq 0x48690
addq $0x38, %rsp
retq
nopw %cs:(%rax,%rax)
| json_parse_error:
sub rsp, 38h
mov [rsp+38h+var_8], rdi
mov [rsp+38h+var_10], rsi
mov [rsp+38h+var_18], rdx
mov rax, [rsp+38h+var_10]
mov rcx, [rsp+38h+var_8]
mov rcx, [rcx+68h]
sub rax, rcx
mov [rsp+38h+var_2C], eax
mov [rsp+38h+var_30], 1
mov rax, [rsp+38h+var_8]
mov rax, [rax+68h]
mov [rsp+38h+var_20], rax
mov [rsp+38h+var_28], rax
loc_86A33:
mov rax, [rsp+38h+var_20]
cmp rax, [rsp+38h+var_10]
jnb loc_86AC9
mov rax, [rsp+38h+var_20]
movzx eax, byte ptr [rax]
cmp eax, 0Dh
jz short loc_86A5D
mov rax, [rsp+38h+var_20]
movzx eax, byte ptr [rax]
cmp eax, 0Ah
jnz short loc_86AB4
loc_86A5D:
mov rax, [rsp+38h+var_20]
movzx ecx, byte ptr [rax]
xor eax, eax
cmp ecx, 0Dh
mov [rsp+38h+var_31], al
jnz short loc_86A83
mov rax, [rsp+38h+var_20]
movzx eax, byte ptr [rax+1]
cmp eax, 0Ah
setz al
mov [rsp+38h+var_31], al
loc_86A83:
mov al, [rsp+38h+var_31]
and al, 1
movzx ecx, al
add ecx, 1
mov rax, [rsp+38h+var_20]
movsxd rcx, ecx
add rax, rcx
mov [rsp+38h+var_20], rax
mov eax, [rsp+38h+var_30]
add eax, 1
mov [rsp+38h+var_30], eax
mov rax, [rsp+38h+var_20]
mov [rsp+38h+var_28], rax
loc_86AB4:
jmp short $+2
loc_86AB6:
mov rax, [rsp+38h+var_20]
add rax, 1
mov [rsp+38h+var_20], rax
jmp loc_86A33
loc_86AC9:
mov rdi, [rsp+38h+var_8]
mov rdx, [rsp+38h+var_18]
mov ecx, [rsp+38h+var_2C]
mov r8d, [rsp+38h+var_30]
mov rax, [rsp+38h+var_20]
mov rsi, [rsp+38h+var_28]
sub rax, rsi
mov r9d, eax
add r9d, 1
lea rsi, aSInJsonAtPosit; "%s in JSON at position %d (line %d colu"...
mov al, 0
call js_parse_error
add rsp, 38h
retn
| long long json_parse_error(
_QWORD *a1,
unsigned long long a2,
long long a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11)
{
char v12; // [rsp+0h] [rbp-38h]
bool v13; // [rsp+7h] [rbp-31h]
unsigned int v14; // [rsp+8h] [rbp-30h]
int v15; // [rsp+10h] [rbp-28h]
_BYTE *v16; // [rsp+18h] [rbp-20h]
v14 = 1;
v16 = (_BYTE *)a1[13];
v15 = (int)v16;
while ( (unsigned long long)v16 < a2 )
{
if ( *v16 == 13 || *v16 == 10 )
{
v13 = 0;
if ( *v16 == 13 )
v13 = v16[1] == 10;
v16 += v13 + 1;
++v14;
v15 = (int)v16;
}
++v16;
}
return js_parse_error(
a1,
(long long)"%s in JSON at position %d (line %d column %d)",
a3,
(unsigned int)a2 - (unsigned int)a1[13],
v14,
(unsigned int)((_DWORD)v16 - v15 + 1),
a4,
a5,
a6,
a7,
a8,
a9,
a10,
a11,
v12);
}
| json_parse_error:
SUB RSP,0x38
MOV qword ptr [RSP + 0x30],RDI
MOV qword ptr [RSP + 0x28],RSI
MOV qword ptr [RSP + 0x20],RDX
MOV RAX,qword ptr [RSP + 0x28]
MOV RCX,qword ptr [RSP + 0x30]
MOV RCX,qword ptr [RCX + 0x68]
SUB RAX,RCX
MOV dword ptr [RSP + 0xc],EAX
MOV dword ptr [RSP + 0x8],0x1
MOV RAX,qword ptr [RSP + 0x30]
MOV RAX,qword ptr [RAX + 0x68]
MOV qword ptr [RSP + 0x18],RAX
MOV qword ptr [RSP + 0x10],RAX
LAB_00186a33:
MOV RAX,qword ptr [RSP + 0x18]
CMP RAX,qword ptr [RSP + 0x28]
JNC 0x00186ac9
MOV RAX,qword ptr [RSP + 0x18]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0xd
JZ 0x00186a5d
MOV RAX,qword ptr [RSP + 0x18]
MOVZX EAX,byte ptr [RAX]
CMP EAX,0xa
JNZ 0x00186ab4
LAB_00186a5d:
MOV RAX,qword ptr [RSP + 0x18]
MOVZX ECX,byte ptr [RAX]
XOR EAX,EAX
CMP ECX,0xd
MOV byte ptr [RSP + 0x7],AL
JNZ 0x00186a83
MOV RAX,qword ptr [RSP + 0x18]
MOVZX EAX,byte ptr [RAX + 0x1]
CMP EAX,0xa
SETZ AL
MOV byte ptr [RSP + 0x7],AL
LAB_00186a83:
MOV AL,byte ptr [RSP + 0x7]
AND AL,0x1
MOVZX ECX,AL
ADD ECX,0x1
MOV RAX,qword ptr [RSP + 0x18]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RSP + 0x18],RAX
MOV EAX,dword ptr [RSP + 0x8]
ADD EAX,0x1
MOV dword ptr [RSP + 0x8],EAX
MOV RAX,qword ptr [RSP + 0x18]
MOV qword ptr [RSP + 0x10],RAX
LAB_00186ab4:
JMP 0x00186ab6
LAB_00186ab6:
MOV RAX,qword ptr [RSP + 0x18]
ADD RAX,0x1
MOV qword ptr [RSP + 0x18],RAX
JMP 0x00186a33
LAB_00186ac9:
MOV RDI,qword ptr [RSP + 0x30]
MOV RDX,qword ptr [RSP + 0x20]
MOV ECX,dword ptr [RSP + 0xc]
MOV R8D,dword ptr [RSP + 0x8]
MOV RAX,qword ptr [RSP + 0x18]
MOV RSI,qword ptr [RSP + 0x10]
SUB RAX,RSI
MOV R9D,EAX
ADD R9D,0x1
LEA RSI,[0x20edc6]
MOV AL,0x0
CALL 0x00148690
ADD RSP,0x38
RET
|
void json_parse_error(long param_1,char *param_2,int8 param_3)
{
bool local_31;
int local_30;
char *local_28;
char *local_20;
local_30 = 1;
local_28 = *(char **)(param_1 + 0x68);
for (local_20 = local_28; local_20 < param_2; local_20 = local_20 + 1) {
if ((*local_20 == '\r') || (*local_20 == '\n')) {
local_31 = false;
if (*local_20 == '\r') {
local_31 = local_20[1] == '\n';
}
local_28 = local_20 + (int)(local_31 + 1);
local_30 = local_30 + 1;
local_20 = local_28;
}
}
js_parse_error(param_1,"%s in JSON at position %d (line %d column %d)",param_3,
(int)param_2 - (int)*(int8 *)(param_1 + 0x68),local_30,
((int)local_20 - (int)local_28) + 1);
return;
}
| |
38,029 | json_parse_error | bluesky950520[P]quickjs/quickjs.c | static int json_parse_error(JSParseState *s, const uint8_t *curp, const char *msg)
{
const uint8_t *p, *line_start;
int position = curp - s->buf_start;
int line = 1;
for (line_start = p = s->buf_start; p < curp; p++) {
/* column count does not account for TABs nor wide characters */
if (*p == '\r' || *p == '\n') {
p += 1 + (p[0] == '\r' && p[1] == '\n');
line++;
line_start = p;
}
}
return js_parse_error(s, "%s in JSON at position %d (line %d column %d)",
msg, position, line, (int)(p - line_start) + 1);
} | O1 | c | json_parse_error:
movq %rsi, %rcx
movq 0x68(%rdi), %rax
movl $0x1, %r8d
movq %rax, %rsi
movq %rax, %r9
cmpq %rcx, %rax
jae 0x4cdb1
movq %rax, %r9
movq %rax, %rsi
movzbl (%r9), %r10d
cmpl $0xa, %r10d
je 0x4cd9b
cmpl $0xd, %r10d
jne 0x4cda9
xorl %esi, %esi
cmpb $0xa, 0x1(%r9)
sete %sil
incq %rsi
jmp 0x4cda0
movl $0x1, %esi
addq %rsi, %r9
incl %r8d
movq %r9, %rsi
incq %r9
cmpq %rcx, %r9
jb 0x4cd7b
subl %eax, %ecx
subl %esi, %r9d
incl %r9d
leaq 0x52fa2(%rip), %rsi # 0x9fd62
xorl %eax, %eax
jmp 0x2fce9
| json_parse_error:
mov rcx, rsi
mov rax, [rdi+68h]
mov r8d, 1
mov rsi, rax
mov r9, rax
cmp rax, rcx
jnb short loc_4CDB1
mov r9, rax
mov rsi, rax
loc_4CD7B:
movzx r10d, byte ptr [r9]
cmp r10d, 0Ah
jz short loc_4CD9B
cmp r10d, 0Dh
jnz short loc_4CDA9
xor esi, esi
cmp byte ptr [r9+1], 0Ah
setz sil
inc rsi
jmp short loc_4CDA0
loc_4CD9B:
mov esi, 1
loc_4CDA0:
add r9, rsi
inc r8d
mov rsi, r9
loc_4CDA9:
inc r9
cmp r9, rcx
jb short loc_4CD7B
loc_4CDB1:
sub ecx, eax
sub r9d, esi
inc r9d
lea rsi, aSInJsonAtPosit; "%s in JSON at position %d (line %d colu"...
xor eax, eax
jmp js_parse_error
| long long json_parse_error(
long long *a1,
unsigned long long a2,
long long a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
long long a12,
long long a13,
long long a14,
char a15)
{
unsigned long long v16; // rax
long long v17; // r8
int v18; // esi
unsigned __int8 *v19; // r9
int v20; // r10d
long long v21; // rsi
v16 = a1[13];
v17 = 1LL;
v18 = v16;
LODWORD(v19) = v16;
if ( v16 < a2 )
{
v19 = (unsigned __int8 *)a1[13];
v18 = (int)v19;
while ( 1 )
{
v20 = *v19;
if ( v20 == 10 )
break;
if ( v20 == 13 )
{
v21 = (v19[1] == 10) + 1LL;
LABEL_7:
v19 += v21;
v17 = (unsigned int)(v17 + 1);
v18 = (int)v19;
}
if ( (unsigned long long)++v19 >= a2 )
return js_parse_error(
a1,
(long long)"%s in JSON at position %d (line %d column %d)",
a3,
(unsigned int)(a2 - v16),
v17,
(unsigned int)((_DWORD)v19 - v18 + 1),
a4,
a5,
a6,
a7,
a8,
a9,
a10,
a11,
a15);
}
v21 = 1LL;
goto LABEL_7;
}
return js_parse_error(
a1,
(long long)"%s in JSON at position %d (line %d column %d)",
a3,
(unsigned int)(a2 - v16),
v17,
(unsigned int)((_DWORD)v19 - v18 + 1),
a4,
a5,
a6,
a7,
a8,
a9,
a10,
a11,
a15);
}
| |||
38,030 | json_parse_error | bluesky950520[P]quickjs/quickjs.c | static int json_parse_error(JSParseState *s, const uint8_t *curp, const char *msg)
{
const uint8_t *p, *line_start;
int position = curp - s->buf_start;
int line = 1;
for (line_start = p = s->buf_start; p < curp; p++) {
/* column count does not account for TABs nor wide characters */
if (*p == '\r' || *p == '\n') {
p += 1 + (p[0] == '\r' && p[1] == '\n');
line++;
line_start = p;
}
}
return js_parse_error(s, "%s in JSON at position %d (line %d column %d)",
msg, position, line, (int)(p - line_start) + 1);
} | O2 | c | json_parse_error:
pushq %rbx
movq %rsi, %rcx
movq 0x68(%rdi), %rax
movl $0x1, %r8d
movabsq $0x1, %rsi
movq %rax, %r10
movq %rax, %r9
cmpq %rcx, %r9
jae 0x41ecd
movzbl (%r9), %ebx
movq %rsi, %r11
cmpl $0xa, %ebx
je 0x41ebf
cmpl $0xd, %ebx
jne 0x41ec8
xorl %r11d, %r11d
cmpb $0xa, 0x1(%r9)
sete %r11b
incq %r11
addq %r11, %r9
incl %r8d
movq %r9, %r10
incq %r9
jmp 0x41e9a
subl %eax, %ecx
subl %r10d, %r9d
incl %r9d
leaq 0x44dd6(%rip), %rsi # 0x86cb2
xorl %eax, %eax
popq %rbx
jmp 0x28457
| json_parse_error:
push rbx
mov rcx, rsi
mov rax, [rdi+68h]
mov r8d, 1
mov rsi, 1
mov r10, rax
mov r9, rax
loc_41E9A:
cmp r9, rcx
jnb short loc_41ECD
movzx ebx, byte ptr [r9]
mov r11, rsi
cmp ebx, 0Ah
jz short loc_41EBF
cmp ebx, 0Dh
jnz short loc_41EC8
xor r11d, r11d
cmp byte ptr [r9+1], 0Ah
setz r11b
inc r11
loc_41EBF:
add r9, r11
inc r8d
mov r10, r9
loc_41EC8:
inc r9
jmp short loc_41E9A
loc_41ECD:
sub ecx, eax
sub r9d, r10d
inc r9d
lea rsi, aSInJsonAtPosit; "%s in JSON at position %d (line %d colu"...
xor eax, eax
pop rbx
jmp js_parse_error
| long long json_parse_error(
long long *a1,
unsigned long long a2,
long long a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
long long a12,
long long a13,
long long a14,
char a15)
{
unsigned __int8 *v15; // rax
long long v16; // r8
int v17; // r10d
unsigned __int8 *i; // r9
int v19; // ebx
long long v20; // r11
v15 = (unsigned __int8 *)a1[13];
v16 = 1LL;
v17 = (int)v15;
for ( i = v15; (unsigned long long)i < a2; ++i )
{
v19 = *i;
v20 = 1LL;
if ( v19 != 10 )
{
if ( v19 != 13 )
continue;
v20 = (i[1] == 10) + 1LL;
}
i += v20;
v16 = (unsigned int)(v16 + 1);
v17 = (int)i;
}
return js_parse_error(
a1,
(long long)"%s in JSON at position %d (line %d column %d)",
a3,
(unsigned int)(a2 - (_DWORD)v15),
v16,
(unsigned int)((_DWORD)i - v17 + 1),
a4,
a5,
a6,
a7,
a8,
a9,
a10,
a11,
a15);
}
| json_parse_error:
PUSH RBX
MOV RCX,RSI
MOV RAX,qword ptr [RDI + 0x68]
MOV R8D,0x1
MOV RSI,0x1
MOV R10,RAX
MOV R9,RAX
LAB_00141e9a:
CMP R9,RCX
JNC 0x00141ecd
MOVZX EBX,byte ptr [R9]
MOV R11,RSI
CMP EBX,0xa
JZ 0x00141ebf
CMP EBX,0xd
JNZ 0x00141ec8
XOR R11D,R11D
CMP byte ptr [R9 + 0x1],0xa
SETZ R11B
INC R11
LAB_00141ebf:
ADD R9,R11
INC R8D
MOV R10,R9
LAB_00141ec8:
INC R9
JMP 0x00141e9a
LAB_00141ecd:
SUB ECX,EAX
SUB R9D,R10D
INC R9D
LEA RSI,[0x186cb2]
XOR EAX,EAX
POP RBX
JMP 0x00128457
|
void json_parse_error(long param_1,char *param_2,int8 param_3)
{
char *pcVar1;
int iVar2;
char *pcVar3;
char *pcVar4;
long lVar5;
pcVar1 = *(char **)(param_1 + 0x68);
iVar2 = 1;
pcVar3 = pcVar1;
pcVar4 = pcVar1;
do {
if (param_2 <= pcVar3) {
js_parse_error(param_1,"%s in JSON at position %d (line %d column %d)",param_3,
(int)param_2 - (int)pcVar1,iVar2,((int)pcVar3 - (int)pcVar4) + 1);
return;
}
lVar5 = 1;
if (*pcVar3 == '\n') {
LAB_00141ebf:
pcVar3 = pcVar3 + lVar5;
iVar2 = iVar2 + 1;
pcVar4 = pcVar3;
}
else if (*pcVar3 == '\r') {
lVar5 = (ulong)(pcVar3[1] == '\n') + 1;
goto LAB_00141ebf;
}
pcVar3 = pcVar3 + 1;
} while( true );
}
| |
38,031 | json_parse_error | bluesky950520[P]quickjs/quickjs.c | static int json_parse_error(JSParseState *s, const uint8_t *curp, const char *msg)
{
const uint8_t *p, *line_start;
int position = curp - s->buf_start;
int line = 1;
for (line_start = p = s->buf_start; p < curp; p++) {
/* column count does not account for TABs nor wide characters */
if (*p == '\r' || *p == '\n') {
p += 1 + (p[0] == '\r' && p[1] == '\n');
line++;
line_start = p;
}
}
return js_parse_error(s, "%s in JSON at position %d (line %d column %d)",
msg, position, line, (int)(p - line_start) + 1);
} | O3 | c | json_parse_error:
movq %rsi, %rcx
movq 0x68(%rdi), %rax
movl $0x1, %r8d
movq %rax, %rsi
movq %rax, %r9
cmpq %rcx, %rax
jae 0x4ec01
movq %rax, %r9
movq %rax, %rsi
movzbl (%r9), %r10d
cmpl $0xa, %r10d
je 0x4ebeb
cmpl $0xd, %r10d
jne 0x4ebf9
xorl %esi, %esi
cmpb $0xa, 0x1(%r9)
sete %sil
incq %rsi
jmp 0x4ebf0
movl $0x1, %esi
addq %rsi, %r9
incl %r8d
movq %r9, %rsi
incq %r9
cmpq %rcx, %r9
jb 0x4ebcb
subl %eax, %ecx
subl %esi, %r9d
incl %r9d
leaq 0x54112(%rip), %rsi # 0xa2d22
xorl %eax, %eax
jmp 0x30b0d
| json_parse_error:
mov rcx, rsi
mov rax, [rdi+68h]
mov r8d, 1
mov rsi, rax
mov r9, rax
cmp rax, rcx
jnb short loc_4EC01
mov r9, rax
mov rsi, rax
loc_4EBCB:
movzx r10d, byte ptr [r9]
cmp r10d, 0Ah
jz short loc_4EBEB
cmp r10d, 0Dh
jnz short loc_4EBF9
xor esi, esi
cmp byte ptr [r9+1], 0Ah
setz sil
inc rsi
jmp short loc_4EBF0
loc_4EBEB:
mov esi, 1
loc_4EBF0:
add r9, rsi
inc r8d
mov rsi, r9
loc_4EBF9:
inc r9
cmp r9, rcx
jb short loc_4EBCB
loc_4EC01:
sub ecx, eax
sub r9d, esi
inc r9d
lea rsi, aSInJsonAtPosit; "%s in JSON at position %d (line %d colu"...
xor eax, eax
jmp js_parse_error
| long long json_parse_error(
long long *a1,
unsigned long long a2,
long long a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
long long a12,
long long a13,
long long a14,
char a15)
{
unsigned long long v16; // rax
long long v17; // r8
int v18; // esi
unsigned __int8 *v19; // r9
int v20; // r10d
long long v21; // rsi
v16 = a1[13];
v17 = 1LL;
v18 = v16;
LODWORD(v19) = v16;
if ( v16 < a2 )
{
v19 = (unsigned __int8 *)a1[13];
v18 = (int)v19;
while ( 1 )
{
v20 = *v19;
if ( v20 == 10 )
break;
if ( v20 == 13 )
{
v21 = (v19[1] == 10) + 1LL;
LABEL_7:
v19 += v21;
v17 = (unsigned int)(v17 + 1);
v18 = (int)v19;
}
if ( (unsigned long long)++v19 >= a2 )
return js_parse_error(
a1,
(long long)"%s in JSON at position %d (line %d column %d)",
a3,
(unsigned int)(a2 - v16),
v17,
(unsigned int)((_DWORD)v19 - v18 + 1),
a4,
a5,
a6,
a7,
a8,
a9,
a10,
a11,
a15);
}
v21 = 1LL;
goto LABEL_7;
}
return js_parse_error(
a1,
(long long)"%s in JSON at position %d (line %d column %d)",
a3,
(unsigned int)(a2 - v16),
v17,
(unsigned int)((_DWORD)v19 - v18 + 1),
a4,
a5,
a6,
a7,
a8,
a9,
a10,
a11,
a15);
}
| json_parse_error:
MOV RCX,RSI
MOV RAX,qword ptr [RDI + 0x68]
MOV R8D,0x1
MOV RSI,RAX
MOV R9,RAX
CMP RAX,RCX
JNC 0x0014ec01
MOV R9,RAX
MOV RSI,RAX
LAB_0014ebcb:
MOVZX R10D,byte ptr [R9]
CMP R10D,0xa
JZ 0x0014ebeb
CMP R10D,0xd
JNZ 0x0014ebf9
XOR ESI,ESI
CMP byte ptr [R9 + 0x1],0xa
SETZ SIL
INC RSI
JMP 0x0014ebf0
LAB_0014ebeb:
MOV ESI,0x1
LAB_0014ebf0:
ADD R9,RSI
INC R8D
MOV RSI,R9
LAB_0014ebf9:
INC R9
CMP R9,RCX
JC 0x0014ebcb
LAB_0014ec01:
SUB ECX,EAX
SUB R9D,ESI
INC R9D
LEA RSI,[0x1a2d22]
XOR EAX,EAX
JMP 0x00130b0d
|
void json_parse_error(long param_1,char *param_2,int8 param_3)
{
char *pcVar1;
long lVar2;
int iVar3;
char *pcVar4;
char *pcVar5;
pcVar1 = *(char **)(param_1 + 0x68);
iVar3 = 1;
pcVar5 = pcVar1;
pcVar4 = pcVar1;
do {
if (param_2 <= pcVar5) {
js_parse_error(param_1,"%s in JSON at position %d (line %d column %d)",param_3,
(int)param_2 - (int)pcVar1,iVar3,((int)pcVar5 - (int)pcVar4) + 1);
return;
}
if (*pcVar5 == '\n') {
lVar2 = 1;
LAB_0014ebf0:
pcVar4 = pcVar5 + lVar2;
iVar3 = iVar3 + 1;
pcVar5 = pcVar4;
}
else if (*pcVar5 == '\r') {
lVar2 = (ulong)(pcVar5[1] == '\n') + 1;
goto LAB_0014ebf0;
}
pcVar5 = pcVar5 + 1;
} while( true );
}
| |
38,032 | js__pstrcpy | bluesky950520[P]quickjs/cutils.c | void js__pstrcpy(char *buf, int buf_size, const char *str)
{
int c;
char *q = buf;
if (buf_size <= 0)
return;
for(;;) {
c = *str++;
if (c == 0 || q >= buf + buf_size - 1)
break;
*q++ = c;
}
*q = '\0';
} | O2 | c | js__pstrcpy:
testl %esi, %esi
jle 0x196b4
movl %esi, %eax
addq %rdi, %rax
decq %rax
movb (%rdx), %cl
testb %cl, %cl
je 0x196b1
cmpq %rax, %rdi
jae 0x196b1
incq %rdx
movb %cl, (%rdi)
incq %rdi
jmp 0x1969c
movb $0x0, (%rdi)
retq
| js__pstrcpy:
test esi, esi
jle short locret_196B4
mov eax, esi
add rax, rdi
dec rax
loc_1969C:
mov cl, [rdx]
test cl, cl
jz short loc_196B1
cmp rdi, rax
jnb short loc_196B1
inc rdx
mov [rdi], cl
inc rdi
jmp short loc_1969C
loc_196B1:
mov byte ptr [rdi], 0
locret_196B4:
retn
| void js__pstrcpy(_BYTE *a1, int a2, char *a3)
{
unsigned long long v3; // rax
char v4; // cl
if ( a2 > 0 )
{
v3 = (unsigned long long)&a1[a2 - 1];
while ( 1 )
{
v4 = *a3;
if ( !*a3 || (unsigned long long)a1 >= v3 )
break;
++a3;
*a1++ = v4;
}
*a1 = 0;
}
}
| js__pstrcpy:
TEST ESI,ESI
JLE 0x001196b4
MOV EAX,ESI
ADD RAX,RDI
DEC RAX
LAB_0011969c:
MOV CL,byte ptr [RDX]
TEST CL,CL
JZ 0x001196b1
CMP RDI,RAX
JNC 0x001196b1
INC RDX
MOV byte ptr [RDI],CL
INC RDI
JMP 0x0011969c
LAB_001196b1:
MOV byte ptr [RDI],0x0
LAB_001196b4:
RET
|
void js__pstrcpy(char *param_1,uint param_2,char *param_3)
{
char cVar1;
char *pcVar2;
if (0 < (int)param_2) {
pcVar2 = param_1 + ((ulong)param_2 - 1);
for (; (cVar1 = *param_3, cVar1 != '\0' && (param_1 < pcVar2)); param_1 = param_1 + 1) {
param_3 = param_3 + 1;
*param_1 = cVar1;
}
*param_1 = '\0';
}
return;
}
| |
38,033 | js__pstrcpy | bluesky950520[P]quickjs/cutils.c | void js__pstrcpy(char *buf, int buf_size, const char *str)
{
int c;
char *q = buf;
if (buf_size <= 0)
return;
for(;;) {
c = *str++;
if (c == 0 || q >= buf + buf_size - 1)
break;
*q++ = c;
}
*q = '\0';
} | O3 | c | js__pstrcpy:
testl %esi, %esi
jle 0x1fba5
movl %esi, %eax
addq %rdi, %rax
decq %rax
movb (%rdx), %cl
testb %cl, %cl
setne %sil
cmpq %rdi, %rax
seta %r8b
andb %sil, %r8b
cmpb $0x1, %r8b
jne 0x1fba2
incq %rdx
movb %cl, (%rdi)
incq %rdi
movb (%rdx), %cl
testb %cl, %cl
je 0x1fba2
incq %rdx
cmpq %rax, %rdi
jb 0x1fb8f
movb $0x0, (%rdi)
retq
| js__pstrcpy:
test esi, esi
jle short locret_1FBA5
mov eax, esi
add rax, rdi
dec rax
mov cl, [rdx]
test cl, cl
setnz sil
cmp rax, rdi
setnbe r8b
and r8b, sil
cmp r8b, 1
jnz short loc_1FBA2
inc rdx
loc_1FB8F:
mov [rdi], cl
inc rdi
mov cl, [rdx]
test cl, cl
jz short loc_1FBA2
inc rdx
cmp rdi, rax
jb short loc_1FB8F
loc_1FBA2:
mov byte ptr [rdi], 0
locret_1FBA5:
retn
| void js__pstrcpy(_BYTE *a1, int a2, char *a3)
{
unsigned long long v3; // rax
char v4; // cl
char *v5; // rdx
if ( a2 > 0 )
{
v3 = (unsigned long long)&a1[a2 - 1];
v4 = *a3;
if ( *a3 != 0 && v3 > (unsigned long long)a1 )
{
v5 = a3 + 1;
do
{
*a1++ = v4;
v4 = *v5;
if ( !*v5 )
break;
++v5;
}
while ( (unsigned long long)a1 < v3 );
}
*a1 = 0;
}
}
| js__pstrcpy:
TEST ESI,ESI
JLE 0x0011fba5
MOV EAX,ESI
ADD RAX,RDI
DEC RAX
MOV CL,byte ptr [RDX]
TEST CL,CL
SETNZ SIL
CMP RAX,RDI
SETA R8B
AND R8B,SIL
CMP R8B,0x1
JNZ 0x0011fba2
INC RDX
LAB_0011fb8f:
MOV byte ptr [RDI],CL
INC RDI
MOV CL,byte ptr [RDX]
TEST CL,CL
JZ 0x0011fba2
INC RDX
CMP RDI,RAX
JC 0x0011fb8f
LAB_0011fba2:
MOV byte ptr [RDI],0x0
LAB_0011fba5:
RET
|
void js__pstrcpy(char *param_1,uint param_2,char *param_3)
{
char *pcVar1;
char cVar2;
if (0 < (int)param_2) {
pcVar1 = param_1 + ((ulong)param_2 - 1);
cVar2 = *param_3;
if (param_1 < pcVar1 && cVar2 != '\0') {
param_3 = param_3 + 1;
do {
*param_1 = cVar2;
param_1 = param_1 + 1;
cVar2 = *param_3;
if (cVar2 == '\0') break;
param_3 = param_3 + 1;
} while (param_1 < pcVar1);
}
*param_1 = '\0';
}
return;
}
| |
38,034 | stbi__parse_zlib_header | dmazzella[P]pylunasvg/lunasvg/plutovg/source/plutovg-stb-image.h | static int stbi__parse_zlib_header(stbi__zbuf *a)
{
int cmf = stbi__zget8(a);
int cm = cmf & 15;
/* int cinfo = cmf >> 4; */
int flg = stbi__zget8(a);
if (stbi__zeof(a)) return stbi__err("bad zlib header","Corrupt PNG"); // zlib spec
if ((cmf*256+flg) % 31 != 0) return stbi__err("bad zlib header","Corrupt PNG"); // zlib spec
if (flg & 32) return stbi__err("no preset dict","Corrupt PNG"); // preset dictionary not allowed in png
if (cm != 8) return stbi__err("bad compression","Corrupt PNG"); // DEFLATE required for png
// window = 1 << (8 + cinfo)... but who cares, we fully buffer output
return 1;
} | O0 | c | stbi__parse_zlib_header:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
callq 0x1cc00
movzbl %al, %eax
movl %eax, -0x14(%rbp)
movl -0x14(%rbp), %eax
andl $0xf, %eax
movl %eax, -0x18(%rbp)
movq -0x10(%rbp), %rdi
callq 0x1cc00
movzbl %al, %eax
movl %eax, -0x1c(%rbp)
movq -0x10(%rbp), %rdi
callq 0x1cc50
cmpl $0x0, %eax
je 0x1c032
leaq 0x21db3(%rip), %rdi # 0x3dddb
callq 0x15290
movl %eax, -0x4(%rbp)
jmp 0x1c093
movl -0x14(%rbp), %eax
shll $0x8, %eax
addl -0x1c(%rbp), %eax
movl $0x1f, %ecx
cltd
idivl %ecx
cmpl $0x0, %edx
je 0x1c059
leaq 0x21d8c(%rip), %rdi # 0x3dddb
callq 0x15290
movl %eax, -0x4(%rbp)
jmp 0x1c093
movl -0x1c(%rbp), %eax
andl $0x20, %eax
cmpl $0x0, %eax
je 0x1c075
leaq 0x21d80(%rip), %rdi # 0x3ddeb
callq 0x15290
movl %eax, -0x4(%rbp)
jmp 0x1c093
cmpl $0x8, -0x18(%rbp)
je 0x1c08c
leaq 0x21d78(%rip), %rdi # 0x3ddfa
callq 0x15290
movl %eax, -0x4(%rbp)
jmp 0x1c093
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
| stbi__parse_zlib_header:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_10], rdi
mov rdi, [rbp+var_10]
call stbi__zget8
movzx eax, al
mov [rbp+var_14], eax
mov eax, [rbp+var_14]
and eax, 0Fh
mov [rbp+var_18], eax
mov rdi, [rbp+var_10]
call stbi__zget8
movzx eax, al
mov [rbp+var_1C], eax
mov rdi, [rbp+var_10]
call stbi__zeof
cmp eax, 0
jz short loc_1C032
lea rdi, aBadZlibHeader; "bad zlib header"
call stbi__err
mov [rbp+var_4], eax
jmp short loc_1C093
loc_1C032:
mov eax, [rbp+var_14]
shl eax, 8
add eax, [rbp+var_1C]
mov ecx, 1Fh
cdq
idiv ecx
cmp edx, 0
jz short loc_1C059
lea rdi, aBadZlibHeader; "bad zlib header"
call stbi__err
mov [rbp+var_4], eax
jmp short loc_1C093
loc_1C059:
mov eax, [rbp+var_1C]
and eax, 20h
cmp eax, 0
jz short loc_1C075
lea rdi, aNoPresetDict; "no preset dict"
call stbi__err
mov [rbp+var_4], eax
jmp short loc_1C093
loc_1C075:
cmp [rbp+var_18], 8
jz short loc_1C08C
lea rdi, aBadCompression; "bad compression"
call stbi__err
mov [rbp+var_4], eax
jmp short loc_1C093
loc_1C08C:
mov [rbp+var_4], 1
loc_1C093:
mov eax, [rbp+var_4]
add rsp, 20h
pop rbp
retn
| long long stbi__parse_zlib_header(long long a1)
{
unsigned __int8 v1; // al
int v3; // [rsp+4h] [rbp-1Ch]
int v4; // [rsp+8h] [rbp-18h]
int v5; // [rsp+Ch] [rbp-14h]
v1 = stbi__zget8(a1);
v5 = v1;
v4 = v1 & 0xF;
v3 = (unsigned __int8)stbi__zget8(a1);
if ( (unsigned int)stbi__zeof(a1) || (v3 + (v5 << 8)) % 31 )
{
return (unsigned int)stbi__err((long long)"bad zlib header");
}
else if ( (v3 & 0x20) != 0 )
{
return (unsigned int)stbi__err((long long)"no preset dict");
}
else if ( v4 == 8 )
{
return 1;
}
else
{
return (unsigned int)stbi__err((long long)"bad compression");
}
}
| stbi__parse_zlib_header:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x10],RDI
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0011cc00
MOVZX EAX,AL
MOV dword ptr [RBP + -0x14],EAX
MOV EAX,dword ptr [RBP + -0x14]
AND EAX,0xf
MOV dword ptr [RBP + -0x18],EAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0011cc00
MOVZX EAX,AL
MOV dword ptr [RBP + -0x1c],EAX
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0011cc50
CMP EAX,0x0
JZ 0x0011c032
LEA RDI,[0x13dddb]
CALL 0x00115290
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0011c093
LAB_0011c032:
MOV EAX,dword ptr [RBP + -0x14]
SHL EAX,0x8
ADD EAX,dword ptr [RBP + -0x1c]
MOV ECX,0x1f
CDQ
IDIV ECX
CMP EDX,0x0
JZ 0x0011c059
LEA RDI,[0x13dddb]
CALL 0x00115290
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0011c093
LAB_0011c059:
MOV EAX,dword ptr [RBP + -0x1c]
AND EAX,0x20
CMP EAX,0x0
JZ 0x0011c075
LEA RDI,[0x13ddeb]
CALL 0x00115290
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0011c093
LAB_0011c075:
CMP dword ptr [RBP + -0x18],0x8
JZ 0x0011c08c
LEA RDI,[0x13ddfa]
CALL 0x00115290
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0011c093
LAB_0011c08c:
MOV dword ptr [RBP + -0x4],0x1
LAB_0011c093:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x20
POP RBP
RET
|
int4 stbi__parse_zlib_header(int8 param_1)
{
byte bVar1;
byte bVar2;
int iVar3;
int4 local_c;
bVar1 = stbi__zget8(param_1);
bVar2 = stbi__zget8(param_1);
iVar3 = stbi__zeof(param_1);
if (iVar3 == 0) {
if (((uint)bVar1 * 0x100 + (uint)bVar2) % 0x1f == 0) {
if ((bVar2 & 0x20) == 0) {
if ((bVar1 & 0xf) == 8) {
local_c = 1;
}
else {
local_c = stbi__err("bad compression");
}
}
else {
local_c = stbi__err("no preset dict");
}
}
else {
local_c = stbi__err("bad zlib header");
}
}
else {
local_c = stbi__err("bad zlib header");
}
return local_c;
}
| |
38,035 | mysql_query_start_internal | eloqsql/libmariadb/libmariadb/mariadb_async.c | static void
mysql_query_start_internal(void *d)
{
MK_ASYNC_INTERNAL_BODY(
mysql_query,
(parms->mysql, parms->q),
parms->mysql,
int,
r_int)
} | O0 | c | mysql_query_start_internal:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x480(%rax), %rax
movq 0x28(%rax), %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rsi
callq 0x38a70
movl %eax, -0x14(%rbp)
movl -0x14(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, 0x8(%rax)
movq -0x20(%rbp), %rax
movl $0x0, (%rax)
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| mysql_query_start_internal:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
mov [rbp+var_10], rax
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+480h]
mov rax, [rax+28h]
mov [rbp+var_20], rax
mov rax, [rbp+var_10]
mov rdi, [rax]
mov rax, [rbp+var_10]
mov rsi, [rax+8]
call mysql_query
mov [rbp+var_14], eax
mov ecx, [rbp+var_14]
mov rax, [rbp+var_20]
mov [rax+8], ecx
mov rax, [rbp+var_20]
mov dword ptr [rax], 0
add rsp, 20h
pop rbp
retn
| _DWORD * mysql_query_start_internal(long long a1)
{
_DWORD *result; // rax
_DWORD *v2; // [rsp+0h] [rbp-20h]
v2 = *(_DWORD **)(*(_QWORD *)(*(_QWORD *)a1 + 1152LL) + 40LL);
v2[2] = mysql_query(*(_QWORD *)a1, *(const char **)(a1 + 8));
result = v2;
*v2 = 0;
return result;
}
| mysql_query_start_internal:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x480]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RAX + 0x8]
CALL 0x00138a70
MOV dword ptr [RBP + -0x14],EAX
MOV ECX,dword ptr [RBP + -0x14]
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX + 0x8],ECX
MOV RAX,qword ptr [RBP + -0x20]
MOV dword ptr [RAX],0x0
ADD RSP,0x20
POP RBP
RET
|
void mysql_query_start_internal(long *param_1)
{
int4 *puVar1;
int4 uVar2;
puVar1 = *(int4 **)(*(long *)(*param_1 + 0x480) + 0x28);
uVar2 = mysql_query(*param_1,param_1[1]);
puVar1[2] = uVar2;
*puVar1 = 0;
return;
}
| |
38,036 | common_sampler_type_to_chr(common_sampler_type) | monkey531[P]llama/common/sampling.cpp | char common_sampler_type_to_chr(enum common_sampler_type cnstr) {
switch (cnstr) {
case COMMON_SAMPLER_TYPE_DRY: return 'd';
case COMMON_SAMPLER_TYPE_TOP_K: return 'k';
case COMMON_SAMPLER_TYPE_TYPICAL_P: return 'y';
case COMMON_SAMPLER_TYPE_TOP_P: return 'p';
case COMMON_SAMPLER_TYPE_MIN_P: return 'm';
case COMMON_SAMPLER_TYPE_TEMPERATURE: return 't';
case COMMON_SAMPLER_TYPE_XTC: return 'x';
case COMMON_SAMPLER_TYPE_INFILL: return 'i';
case COMMON_SAMPLER_TYPE_PENALTIES: return 'e';
default : return '?';
}
} | O2 | cpp | common_sampler_type_to_chr(common_sampler_type):
decl %edi
movb $0x3f, %al
cmpl $0x9, %edi
ja 0x99eb3
movl %edi, %eax
leaq 0x20834(%rip), %rcx # 0xba6e4
movb (%rax,%rcx), %al
retq
| _Z26common_sampler_type_to_chr19common_sampler_type:
dec edi
mov al, 3Fh ; '?'
cmp edi, 9
ja short locret_99EB3
mov eax, edi
lea rcx, aDkpmYtxie; "dkpm?ytxie"
mov al, [rax+rcx]
locret_99EB3:
retn
| char common_sampler_type_to_chr(int a1)
{
unsigned int v1; // edi
char result; // al
v1 = a1 - 1;
result = 63;
if ( v1 <= 9 )
return aDkpmYtxie[v1];
return result;
}
| common_sampler_type_to_chr:
DEC EDI
MOV AL,0x3f
CMP EDI,0x9
JA 0x00199eb3
MOV EAX,EDI
LEA RCX,[0x1ba6e4]
MOV AL,byte ptr [RAX + RCX*0x1]
LAB_00199eb3:
RET
|
/* common_sampler_type_to_chr(common_sampler_type) */
char common_sampler_type_to_chr(int param_1)
{
char cVar1;
cVar1 = '?';
if (param_1 - 1U < 10) {
cVar1 = "dkpm?ytxie"[param_1 - 1U];
}
return cVar1;
}
| |
38,037 | test_bug14210 | eloqsql/libmariadb/unittest/libmariadb/cursor.c | static int test_bug14210(MYSQL *mysql)
{
MYSQL_STMT *stmt;
int rc, i;
const char *stmt_text;
ulong type;
rc= mysql_query(mysql, "drop table if exists t1");
check_mysql_rc(rc, mysql);
/*
To trigger the problem the table must be InnoDB, although the problem
itself is not InnoDB related. In case the table is MyISAM this test
is harmless.
*/
rc= mysql_query(mysql, "create table t1 (a varchar(255)) engine=InnoDB");
check_mysql_rc(rc, mysql);
rc= mysql_query(mysql, "insert into t1 (a) values (repeat('a', 256))");
check_mysql_rc(rc, mysql);
rc= mysql_query(mysql, "set @@session.max_heap_table_size=16384");
/* Create a big enough table (more than max_heap_table_size) */
for (i= 0; i < 8; i++)
{
rc= mysql_query(mysql, "insert into t1 (a) select a from t1");
check_mysql_rc(rc, mysql);
}
/* create statement */
stmt= mysql_stmt_init(mysql);
type= (ulong) CURSOR_TYPE_READ_ONLY;
mysql_stmt_attr_set(stmt, STMT_ATTR_CURSOR_TYPE, (const void*) &type);
stmt_text= "select a from t1";
rc= mysql_stmt_prepare(stmt, SL(stmt_text));
check_stmt_rc(rc, stmt);
rc= mysql_stmt_execute(stmt);
while ((rc= mysql_stmt_fetch(stmt)) == 0);
FAIL_UNLESS(rc == MYSQL_NO_DATA, "rc != MYSQL_NO_DATA");
rc= mysql_stmt_close(stmt);
rc= mysql_query(mysql, "drop table t1");
check_mysql_rc(rc, mysql);
rc= mysql_query(mysql, "set @@session.max_heap_table_size=default");
check_mysql_rc(rc, mysql);
return OK;
} | O3 | c | test_bug14210:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
leaq 0x217b7(%rip), %rsi # 0x39c56
callq 0x1f651
testl %eax, %eax
je 0x184df
movl %eax, %r14d
movq %rbx, %rdi
callq 0x216ca
movq %rax, %r15
movq %rbx, %rdi
callq 0x216b5
leaq 0x20d18(%rip), %rdi # 0x391dd
leaq 0x21158(%rip), %r8 # 0x39624
movl %r14d, %esi
movq %r15, %rdx
movl %eax, %ecx
movl $0x53e, %r9d # imm = 0x53E
jmp 0x18639
leaq 0x23043(%rip), %rsi # 0x3b529
movq %rbx, %rdi
callq 0x1f651
testl %eax, %eax
je 0x18529
movl %eax, %r14d
movq %rbx, %rdi
callq 0x216ca
movq %rax, %r15
movq %rbx, %rdi
callq 0x216b5
leaq 0x20cce(%rip), %rdi # 0x391dd
leaq 0x2110e(%rip), %r8 # 0x39624
movl %r14d, %esi
movq %r15, %rdx
movl %eax, %ecx
movl $0x545, %r9d # imm = 0x545
jmp 0x18639
leaq 0x23028(%rip), %rsi # 0x3b558
movq %rbx, %rdi
callq 0x1f651
testl %eax, %eax
je 0x18573
movl %eax, %r14d
movq %rbx, %rdi
callq 0x216ca
movq %rax, %r15
movq %rbx, %rdi
callq 0x216b5
leaq 0x20c84(%rip), %rdi # 0x391dd
leaq 0x210c4(%rip), %r8 # 0x39624
movl %r14d, %esi
movq %r15, %rdx
movl %eax, %ecx
movl $0x547, %r9d # imm = 0x547
jmp 0x18639
leaq 0x2300b(%rip), %rsi # 0x3b585
movq %rbx, %rdi
callq 0x1f651
movl $0x8, %r12d
leaq 0x2301e(%rip), %r15 # 0x3b5ad
movq %rbx, %rdi
movq %r15, %rsi
callq 0x1f651
testl %eax, %eax
jne 0x18607
decl %r12d
jne 0x1858f
movq %rbx, %rdi
callq 0x25d10
movq %rax, %r15
leaq -0x28(%rbp), %rdx
movq $0x1, (%rdx)
movl $0x1, %r14d
movq %rax, %rdi
movl $0x1, %esi
callq 0x24cd2
leaq 0x22fed(%rip), %rsi # 0x3b5c0
movl $0x10, %edx
movq %r15, %rdi
callq 0x260d4
testl %eax, %eax
je 0x18656
movq %r15, %rdi
callq 0x257b0
leaq 0x20aa5(%rip), %rdi # 0x39098
leaq 0x2102a(%rip), %rdx # 0x39624
movq %rax, %rsi
movl $0x558, %ecx # imm = 0x558
jmp 0x186d8
movl %eax, %r14d
movq %rbx, %rdi
callq 0x216ca
movq %rax, %r15
movq %rbx, %rdi
callq 0x216b5
leaq 0x20bb9(%rip), %rdi # 0x391dd
leaq 0x20ff9(%rip), %r8 # 0x39624
movl %r14d, %esi
movq %r15, %rdx
movl %eax, %ecx
movl $0x54e, %r9d # imm = 0x54E
xorl %eax, %eax
callq 0x19f47
movl $0x1, %r14d
movl %r14d, %eax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %r15, %rdi
callq 0x26ca5
movq %r15, %rdi
callq 0x257cb
testl %eax, %eax
je 0x1865e
cmpl $0x64, %eax
jne 0x186be
movq %r15, %rdi
callq 0x25721
leaq 0x216c0(%rip), %rsi # 0x39d3e
movq %rbx, %rdi
callq 0x1f651
testl %eax, %eax
je 0x186e4
movl %eax, %r15d
movq %rbx, %rdi
callq 0x216ca
movq %rax, %r12
movq %rbx, %rdi
callq 0x216b5
leaq 0x20b36(%rip), %rdi # 0x391dd
leaq 0x20f76(%rip), %r8 # 0x39624
movl %r15d, %esi
movq %r12, %rdx
movl %eax, %ecx
movl $0x560, %r9d # imm = 0x560
jmp 0x18729
leaq 0x209d3(%rip), %rdi # 0x39098
leaq 0x2165e(%rip), %rsi # 0x39d2a
leaq 0x20f51(%rip), %rdx # 0x39624
movl $0x55b, %ecx # imm = 0x55B
xorl %eax, %eax
callq 0x19f47
jmp 0x18646
leaq 0x22ee6(%rip), %rsi # 0x3b5d1
movq %rbx, %rdi
callq 0x1f651
testl %eax, %eax
je 0x18735
movl %eax, %r15d
movq %rbx, %rdi
callq 0x216ca
movq %rax, %r12
movq %rbx, %rdi
callq 0x216b5
leaq 0x20ac9(%rip), %rdi # 0x391dd
leaq 0x20f09(%rip), %r8 # 0x39624
movl %r15d, %esi
movq %r12, %rdx
movl %eax, %ecx
movl $0x562, %r9d # imm = 0x562
xorl %eax, %eax
callq 0x19f47
jmp 0x18646
xorl %r14d, %r14d
jmp 0x18646
| test_bug14210:
push rbp
mov rbp, rsp
push r15
push r14
push r12
push rbx
sub rsp, 10h
mov rbx, rdi
lea rsi, aDropTableIfExi; "drop table if exists t1"
call mysql_query
test eax, eax
jz short loc_184DF
mov r14d, eax
mov rdi, rbx
call mysql_error
mov r15, rax
mov rdi, rbx
call mysql_errno
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, r14d
mov rdx, r15
mov ecx, eax
mov r9d, 53Eh
jmp loc_18639
loc_184DF:
lea rsi, aCreateTableT1A_1; "create table t1 (a varchar(255)) engine"...
mov rdi, rbx
call mysql_query
test eax, eax
jz short loc_18529
mov r14d, eax
mov rdi, rbx
call mysql_error
mov r15, rax
mov rdi, rbx
call mysql_errno
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, r14d
mov rdx, r15
mov ecx, eax
mov r9d, 545h
jmp loc_18639
loc_18529:
lea rsi, aInsertIntoT1AV_0; "insert into t1 (a) values (repeat('a', "...
mov rdi, rbx
call mysql_query
test eax, eax
jz short loc_18573
mov r14d, eax
mov rdi, rbx
call mysql_error
mov r15, rax
mov rdi, rbx
call mysql_errno
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, r14d
mov rdx, r15
mov ecx, eax
mov r9d, 547h
jmp loc_18639
loc_18573:
lea rsi, aSetSessionMaxH; "set @@session.max_heap_table_size=16384"
mov rdi, rbx
call mysql_query
mov r12d, 8
lea r15, aInsertIntoT1AS; "insert into t1 (a) select a from t1"
loc_1858F:
mov rdi, rbx
mov rsi, r15
call mysql_query
test eax, eax
jnz short loc_18607
dec r12d
jnz short loc_1858F
mov rdi, rbx
call mysql_stmt_init
mov r15, rax
lea rdx, [rbp+var_28]
mov qword ptr [rdx], 1
mov r14d, 1
mov rdi, rax
mov esi, 1
call mysql_stmt_attr_set
lea rsi, aInsertIntoT1AS+13h; "select a from t1"
mov edx, 10h
mov rdi, r15
call mysql_stmt_prepare
test eax, eax
jz short loc_18656
mov rdi, r15
call mysql_stmt_error
lea rdi, aErrorSSD; "Error: %s (%s: %d)"
lea rdx, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov rsi, rax
mov ecx, 558h
jmp loc_186D8
loc_18607:
mov r14d, eax
mov rdi, rbx
call mysql_error
mov r15, rax
mov rdi, rbx
call mysql_errno
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, r14d
mov rdx, r15
mov ecx, eax
mov r9d, 54Eh
loc_18639:
xor eax, eax
call diag
mov r14d, 1
loc_18646:
mov eax, r14d
add rsp, 10h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_18656:
mov rdi, r15
call mysql_stmt_execute
loc_1865E:
mov rdi, r15
call mysql_stmt_fetch
test eax, eax
jz short loc_1865E
cmp eax, 64h ; 'd'
jnz short loc_186BE
mov rdi, r15
call mysql_stmt_close
lea rsi, aDropTableT1; "drop table t1"
mov rdi, rbx
call mysql_query
test eax, eax
jz short loc_186E4
mov r15d, eax
mov rdi, rbx
call mysql_error
mov r12, rax
mov rdi, rbx
call mysql_errno
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, r15d
mov rdx, r12
mov ecx, eax
mov r9d, 560h
jmp short loc_18729
loc_186BE:
lea rdi, aErrorSSD; "Error: %s (%s: %d)"
lea rsi, aRcMysqlNoData; "rc != MYSQL_NO_DATA"
lea rdx, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov ecx, 55Bh
loc_186D8:
xor eax, eax
call diag
jmp loc_18646
loc_186E4:
lea rsi, aSetSessionMaxH_0; "set @@session.max_heap_table_size=defau"...
mov rdi, rbx
call mysql_query
test eax, eax
jz short loc_18735
mov r15d, eax
mov rdi, rbx
call mysql_error
mov r12, rax
mov rdi, rbx
call mysql_errno
lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d"
lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov esi, r15d
mov rdx, r12
mov ecx, eax
mov r9d, 562h
loc_18729:
xor eax, eax
call diag
jmp loc_18646
loc_18735:
xor r14d, r14d
jmp loc_18646
| long long test_bug14210(long long a1)
{
int v1; // eax
int v2; // r14d
int v3; // r15d
int v4; // eax
int v5; // esi
int v6; // edx
int v7; // ecx
int v8; // r9d
int v9; // eax
int v10; // r14d
int v11; // r15d
int v12; // eax
int v13; // eax
int v14; // r14d
int v15; // r15d
int v16; // eax
int v17; // r12d
int v18; // eax
long long v19; // r15
unsigned int v20; // r14d
int v21; // eax
const char *v22; // r8
int v23; // r9d
const char *v24; // rdi
const char *v25; // rdx
const char *v26; // rsi
int v27; // ecx
int v28; // r14d
int v29; // r15d
int v30; // eax
int v32; // eax
int v33; // eax
int v34; // r15d
int v35; // r12d
int v36; // eax
int v37; // eax
int v38; // r15d
int v39; // r12d
int v40; // eax
long long v41[5]; // [rsp+8h] [rbp-28h] BYREF
v1 = mysql_query(a1, "drop table if exists t1");
if ( v1 )
{
v2 = v1;
v3 = mysql_error(a1);
v4 = mysql_errno(a1);
v5 = v2;
v6 = v3;
v7 = v4;
v8 = 1342;
LABEL_13:
diag(
(unsigned int)"Error (%d): %s (%d) in %s line %d",
v5,
v6,
v7,
(unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/cursor.c",
v8);
return 1;
}
v9 = mysql_query(a1, "create table t1 (a varchar(255)) engine=InnoDB");
if ( v9 )
{
v10 = v9;
v11 = mysql_error(a1);
v12 = mysql_errno(a1);
v5 = v10;
v6 = v11;
v7 = v12;
v8 = 1349;
goto LABEL_13;
}
v13 = mysql_query(a1, "insert into t1 (a) values (repeat('a', 256))");
if ( v13 )
{
v14 = v13;
v15 = mysql_error(a1);
v16 = mysql_errno(a1);
v5 = v14;
v6 = v15;
v7 = v16;
v8 = 1351;
goto LABEL_13;
}
mysql_query(a1, "set @@session.max_heap_table_size=16384");
v17 = 8;
do
{
v18 = mysql_query(a1, "insert into t1 (a) select a from t1");
if ( v18 )
{
v28 = v18;
v29 = mysql_error(a1);
v30 = mysql_errno(a1);
v5 = v28;
v6 = v29;
v7 = v30;
v8 = 1358;
goto LABEL_13;
}
--v17;
}
while ( v17 );
v19 = mysql_stmt_init(a1);
v41[0] = 1LL;
v20 = 1;
mysql_stmt_attr_set(v19, 1LL, v41);
if ( (unsigned int)mysql_stmt_prepare(v19, "select a from t1", 16LL) )
{
v21 = mysql_stmt_error(v19);
v24 = "Error: %s (%s: %d)";
v25 = "/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/cursor.c";
LODWORD(v26) = v21;
v27 = 1368;
}
else
{
mysql_stmt_execute(v19);
do
v32 = mysql_stmt_fetch(v19);
while ( !v32 );
if ( v32 == 100 )
{
mysql_stmt_close(v19);
v33 = mysql_query(a1, "drop table t1");
if ( v33 )
{
v34 = v33;
v35 = mysql_error(a1);
v36 = mysql_errno(a1);
v24 = "Error (%d): %s (%d) in %s line %d";
v22 = "/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/cursor.c";
LODWORD(v26) = v34;
LODWORD(v25) = v35;
v27 = v36;
v23 = 1376;
}
else
{
v37 = mysql_query(a1, "set @@session.max_heap_table_size=default");
if ( !v37 )
return 0;
v38 = v37;
v39 = mysql_error(a1);
v40 = mysql_errno(a1);
v24 = "Error (%d): %s (%d) in %s line %d";
v22 = "/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/cursor.c";
LODWORD(v26) = v38;
LODWORD(v25) = v39;
v27 = v40;
v23 = 1378;
}
}
else
{
v24 = "Error: %s (%s: %d)";
v26 = "rc != MYSQL_NO_DATA";
v25 = "/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/cursor.c";
v27 = 1371;
}
}
diag((_DWORD)v24, (_DWORD)v26, (_DWORD)v25, v27, (_DWORD)v22, v23);
return v20;
}
| test_bug14210:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x10
MOV RBX,RDI
LEA RSI,[0x139c56]
CALL 0x0011f651
TEST EAX,EAX
JZ 0x001184df
MOV R14D,EAX
MOV RDI,RBX
CALL 0x001216ca
MOV R15,RAX
MOV RDI,RBX
CALL 0x001216b5
LEA RDI,[0x1391dd]
LEA R8,[0x139624]
MOV ESI,R14D
MOV RDX,R15
MOV ECX,EAX
MOV R9D,0x53e
JMP 0x00118639
LAB_001184df:
LEA RSI,[0x13b529]
MOV RDI,RBX
CALL 0x0011f651
TEST EAX,EAX
JZ 0x00118529
MOV R14D,EAX
MOV RDI,RBX
CALL 0x001216ca
MOV R15,RAX
MOV RDI,RBX
CALL 0x001216b5
LEA RDI,[0x1391dd]
LEA R8,[0x139624]
MOV ESI,R14D
MOV RDX,R15
MOV ECX,EAX
MOV R9D,0x545
JMP 0x00118639
LAB_00118529:
LEA RSI,[0x13b558]
MOV RDI,RBX
CALL 0x0011f651
TEST EAX,EAX
JZ 0x00118573
MOV R14D,EAX
MOV RDI,RBX
CALL 0x001216ca
MOV R15,RAX
MOV RDI,RBX
CALL 0x001216b5
LEA RDI,[0x1391dd]
LEA R8,[0x139624]
MOV ESI,R14D
MOV RDX,R15
MOV ECX,EAX
MOV R9D,0x547
JMP 0x00118639
LAB_00118573:
LEA RSI,[0x13b585]
MOV RDI,RBX
CALL 0x0011f651
MOV R12D,0x8
LEA R15,[0x13b5ad]
LAB_0011858f:
MOV RDI,RBX
MOV RSI,R15
CALL 0x0011f651
TEST EAX,EAX
JNZ 0x00118607
DEC R12D
JNZ 0x0011858f
MOV RDI,RBX
CALL 0x00125d10
MOV R15,RAX
LEA RDX,[RBP + -0x28]
MOV qword ptr [RDX],0x1
MOV R14D,0x1
MOV RDI,RAX
MOV ESI,0x1
CALL 0x00124cd2
LEA RSI,[0x13b5c0]
MOV EDX,0x10
MOV RDI,R15
CALL 0x001260d4
TEST EAX,EAX
JZ 0x00118656
MOV RDI,R15
CALL 0x001257b0
LEA RDI,[0x139098]
LEA RDX,[0x139624]
MOV RSI,RAX
MOV ECX,0x558
JMP 0x001186d8
LAB_00118607:
MOV R14D,EAX
MOV RDI,RBX
CALL 0x001216ca
MOV R15,RAX
MOV RDI,RBX
CALL 0x001216b5
LEA RDI,[0x1391dd]
LEA R8,[0x139624]
MOV ESI,R14D
MOV RDX,R15
MOV ECX,EAX
MOV R9D,0x54e
LAB_00118639:
XOR EAX,EAX
CALL 0x00119f47
MOV R14D,0x1
LAB_00118646:
MOV EAX,R14D
ADD RSP,0x10
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_00118656:
MOV RDI,R15
CALL 0x00126ca5
LAB_0011865e:
MOV RDI,R15
CALL 0x001257cb
TEST EAX,EAX
JZ 0x0011865e
CMP EAX,0x64
JNZ 0x001186be
MOV RDI,R15
CALL 0x00125721
LEA RSI,[0x139d3e]
MOV RDI,RBX
CALL 0x0011f651
TEST EAX,EAX
JZ 0x001186e4
MOV R15D,EAX
MOV RDI,RBX
CALL 0x001216ca
MOV R12,RAX
MOV RDI,RBX
CALL 0x001216b5
LEA RDI,[0x1391dd]
LEA R8,[0x139624]
MOV ESI,R15D
MOV RDX,R12
MOV ECX,EAX
MOV R9D,0x560
JMP 0x00118729
LAB_001186be:
LEA RDI,[0x139098]
LEA RSI,[0x139d2a]
LEA RDX,[0x139624]
MOV ECX,0x55b
LAB_001186d8:
XOR EAX,EAX
CALL 0x00119f47
JMP 0x00118646
LAB_001186e4:
LEA RSI,[0x13b5d1]
MOV RDI,RBX
CALL 0x0011f651
TEST EAX,EAX
JZ 0x00118735
MOV R15D,EAX
MOV RDI,RBX
CALL 0x001216ca
MOV R12,RAX
MOV RDI,RBX
CALL 0x001216b5
LEA RDI,[0x1391dd]
LEA R8,[0x139624]
MOV ESI,R15D
MOV RDX,R12
MOV ECX,EAX
MOV R9D,0x562
LAB_00118729:
XOR EAX,EAX
CALL 0x00119f47
JMP 0x00118646
LAB_00118735:
XOR R14D,R14D
JMP 0x00118646
|
int8 test_bug14210(int8 param_1)
{
int iVar1;
int4 uVar2;
int8 uVar3;
char *pcVar4;
int8 uVar5;
int iVar6;
iVar1 = mysql_query(param_1,"drop table if exists t1");
if (iVar1 == 0) {
iVar1 = mysql_query(param_1,"create table t1 (a varchar(255)) engine=InnoDB");
if (iVar1 == 0) {
iVar1 = mysql_query(param_1,"insert into t1 (a) values (repeat(\'a\', 256))");
if (iVar1 == 0) {
mysql_query(param_1,"set @@session.max_heap_table_size=16384");
iVar6 = 8;
while (iVar1 = mysql_query(param_1,"insert into t1 (a) select a from t1"), iVar1 == 0) {
iVar6 = iVar6 + -1;
if (iVar6 == 0) {
uVar3 = mysql_stmt_init(param_1);
mysql_stmt_attr_set(uVar3,1);
iVar1 = mysql_stmt_prepare(uVar3,"select a from t1",0x10);
if (iVar1 == 0) {
mysql_stmt_execute(uVar3);
do {
iVar1 = mysql_stmt_fetch(uVar3);
} while (iVar1 == 0);
if (iVar1 == 100) {
mysql_stmt_close(uVar3);
iVar1 = mysql_query(param_1,"drop table t1");
if (iVar1 == 0) {
iVar1 = mysql_query(param_1,"set @@session.max_heap_table_size=default");
if (iVar1 == 0) {
return 0;
}
uVar3 = mysql_error(param_1);
uVar2 = mysql_errno(param_1);
uVar5 = 0x562;
}
else {
uVar3 = mysql_error(param_1);
uVar2 = mysql_errno(param_1);
uVar5 = 0x560;
}
diag("Error (%d): %s (%d) in %s line %d",iVar1,uVar3,uVar2,
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/cursor.c"
,uVar5);
return 1;
}
pcVar4 = "rc != MYSQL_NO_DATA";
uVar3 = 0x55b;
}
else {
pcVar4 = (char *)mysql_stmt_error(uVar3);
uVar3 = 0x558;
}
diag("Error: %s (%s: %d)",pcVar4,
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/cursor.c",
uVar3);
return 1;
}
}
uVar3 = mysql_error(param_1);
uVar2 = mysql_errno(param_1);
uVar5 = 0x54e;
}
else {
uVar3 = mysql_error(param_1);
uVar2 = mysql_errno(param_1);
uVar5 = 0x547;
}
}
else {
uVar3 = mysql_error(param_1);
uVar2 = mysql_errno(param_1);
uVar5 = 0x545;
}
}
else {
uVar3 = mysql_error(param_1);
uVar2 = mysql_errno(param_1);
uVar5 = 0x53e;
}
diag("Error (%d): %s (%d) in %s line %d",iVar1,uVar3,uVar2,
"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/cursor.c",uVar5);
return 1;
}
| |
38,038 | mysql_fetch_row | eloqsql/libmariadb/libmariadb/mariadb_lib.c | MYSQL_ROW STDCALL
mysql_fetch_row(MYSQL_RES *res)
{
if (!res)
return 0;
if (res->handle)
{
if (res->handle->status != MYSQL_STATUS_USE_RESULT &&
res->handle->status != MYSQL_STATUS_GET_RESULT)
return 0;
}
if (!res->data)
{ /* Unbufferred fetch */
if (!res->eof && res->handle)
{
if (!(res->handle->methods->db_read_one_row(res->handle,res->field_count,res->row, res->lengths)))
{
res->row_count++;
return(res->current_row=res->row);
}
res->eof=1;
res->handle->status=MYSQL_STATUS_READY;
/* Don't clear handle in mysql_free_results */
res->handle=0;
}
return((MYSQL_ROW) NULL);
}
{
MYSQL_ROW tmp;
if (!res->data_cursor)
{
return(res->current_row=(MYSQL_ROW) NULL);
}
tmp = res->data_cursor->data;
res->data_cursor = res->data_cursor->next;
return(res->current_row=tmp);
}
} | O0 | c | mysql_fetch_row:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0x1fda0
movq $0x0, -0x8(%rbp)
jmp 0x1fef2
movq -0x10(%rbp), %rax
cmpq $0x0, 0x78(%rax)
je 0x1fddc
movq -0x10(%rbp), %rax
movq 0x78(%rax), %rax
cmpl $0x2, 0x488(%rax)
je 0x1fdda
movq -0x10(%rbp), %rax
movq 0x78(%rax), %rax
cmpl $0x1, 0x488(%rax)
je 0x1fdda
movq $0x0, -0x8(%rbp)
jmp 0x1fef2
jmp 0x1fddc
movq -0x10(%rbp), %rax
cmpq $0x0, 0x18(%rax)
jne 0x1fe9e
movq -0x10(%rbp), %rax
cmpb $0x0, 0x80(%rax)
jne 0x1fe94
movq -0x10(%rbp), %rax
cmpq $0x0, 0x78(%rax)
je 0x1fe94
movq -0x10(%rbp), %rax
movq 0x78(%rax), %rax
movq 0x4d0(%rax), %rax
movq 0x30(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x78(%rcx), %rdi
movq -0x10(%rbp), %rcx
movl 0x8(%rcx), %esi
movq -0x10(%rbp), %rcx
movq 0x60(%rcx), %rdx
movq -0x10(%rbp), %rcx
movq 0x70(%rcx), %rcx
callq *%rax
cmpl $0x0, %eax
jne 0x1fe6b
movq -0x10(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
movq 0x60(%rax), %rax
movq -0x10(%rbp), %rcx
movq %rax, 0x68(%rcx)
movq %rax, -0x8(%rbp)
jmp 0x1fef2
movq -0x10(%rbp), %rax
movb $0x1, 0x80(%rax)
movq -0x10(%rbp), %rax
movq 0x78(%rax), %rax
movl $0x0, 0x488(%rax)
movq -0x10(%rbp), %rax
movq $0x0, 0x78(%rax)
movq $0x0, -0x8(%rbp)
jmp 0x1fef2
movq -0x10(%rbp), %rax
cmpq $0x0, 0x20(%rax)
jne 0x1febf
movq -0x10(%rbp), %rax
movq $0x0, 0x68(%rax)
movq $0x0, -0x8(%rbp)
jmp 0x1fef2
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq 0x8(%rax), %rax
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq (%rax), %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x20(%rax)
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rcx
movq %rax, 0x68(%rcx)
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopl (%rax)
| mysql_fetch_row:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_10], rdi
cmp [rbp+var_10], 0
jnz short loc_1FDA0
mov [rbp+var_8], 0
jmp loc_1FEF2
loc_1FDA0:
mov rax, [rbp+var_10]
cmp qword ptr [rax+78h], 0
jz short loc_1FDDC
mov rax, [rbp+var_10]
mov rax, [rax+78h]
cmp dword ptr [rax+488h], 2
jz short loc_1FDDA
mov rax, [rbp+var_10]
mov rax, [rax+78h]
cmp dword ptr [rax+488h], 1
jz short loc_1FDDA
mov [rbp+var_8], 0
jmp loc_1FEF2
loc_1FDDA:
jmp short $+2
loc_1FDDC:
mov rax, [rbp+var_10]
cmp qword ptr [rax+18h], 0
jnz loc_1FE9E
mov rax, [rbp+var_10]
cmp byte ptr [rax+80h], 0
jnz loc_1FE94
mov rax, [rbp+var_10]
cmp qword ptr [rax+78h], 0
jz loc_1FE94
mov rax, [rbp+var_10]
mov rax, [rax+78h]
mov rax, [rax+4D0h]
mov rax, [rax+30h]
mov rcx, [rbp+var_10]
mov rdi, [rcx+78h]
mov rcx, [rbp+var_10]
mov esi, [rcx+8]
mov rcx, [rbp+var_10]
mov rdx, [rcx+60h]
mov rcx, [rbp+var_10]
mov rcx, [rcx+70h]
call rax
cmp eax, 0
jnz short loc_1FE6B
mov rax, [rbp+var_10]
mov rcx, [rax]
add rcx, 1
mov [rax], rcx
mov rax, [rbp+var_10]
mov rax, [rax+60h]
mov rcx, [rbp+var_10]
mov [rcx+68h], rax
mov [rbp+var_8], rax
jmp loc_1FEF2
loc_1FE6B:
mov rax, [rbp+var_10]
mov byte ptr [rax+80h], 1
mov rax, [rbp+var_10]
mov rax, [rax+78h]
mov dword ptr [rax+488h], 0
mov rax, [rbp+var_10]
mov qword ptr [rax+78h], 0
loc_1FE94:
mov [rbp+var_8], 0
jmp short loc_1FEF2
loc_1FE9E:
mov rax, [rbp+var_10]
cmp qword ptr [rax+20h], 0
jnz short loc_1FEBF
mov rax, [rbp+var_10]
mov qword ptr [rax+68h], 0
mov [rbp+var_8], 0
jmp short loc_1FEF2
loc_1FEBF:
mov rax, [rbp+var_10]
mov rax, [rax+20h]
mov rax, [rax+8]
mov [rbp+var_18], rax
mov rax, [rbp+var_10]
mov rax, [rax+20h]
mov rcx, [rax]
mov rax, [rbp+var_10]
mov [rax+20h], rcx
mov rax, [rbp+var_18]
mov rcx, [rbp+var_10]
mov [rcx+68h], rax
mov [rbp+var_8], rax
loc_1FEF2:
mov rax, [rbp+var_8]
add rsp, 20h
pop rbp
retn
| long long mysql_fetch_row(long long a1)
{
long long v1; // rax
long long v3; // [rsp+8h] [rbp-18h]
if ( !a1 )
return 0LL;
if ( *(_QWORD *)(a1 + 120)
&& *(_DWORD *)(*(_QWORD *)(a1 + 120) + 1160LL) != 2
&& *(_DWORD *)(*(_QWORD *)(a1 + 120) + 1160LL) != 1 )
{
return 0LL;
}
if ( !*(_QWORD *)(a1 + 24) )
{
if ( !*(_BYTE *)(a1 + 128) && *(_QWORD *)(a1 + 120) )
{
if ( !(*(unsigned int ( **)(_QWORD, _QWORD, _QWORD, _QWORD))(*(_QWORD *)(*(_QWORD *)(a1 + 120) + 1232LL)
+ 48LL))(
*(_QWORD *)(a1 + 120),
*(unsigned int *)(a1 + 8),
*(_QWORD *)(a1 + 96),
*(_QWORD *)(a1 + 112)) )
{
++*(_QWORD *)a1;
v1 = *(_QWORD *)(a1 + 96);
*(_QWORD *)(a1 + 104) = v1;
return v1;
}
*(_BYTE *)(a1 + 128) = 1;
*(_DWORD *)(*(_QWORD *)(a1 + 120) + 1160LL) = 0;
*(_QWORD *)(a1 + 120) = 0LL;
}
return 0LL;
}
if ( *(_QWORD *)(a1 + 32) )
{
v3 = *(_QWORD *)(*(_QWORD *)(a1 + 32) + 8LL);
*(_QWORD *)(a1 + 32) = **(_QWORD **)(a1 + 32);
*(_QWORD *)(a1 + 104) = v3;
return v3;
}
else
{
*(_QWORD *)(a1 + 104) = 0LL;
return 0LL;
}
}
| mysql_fetch_row:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x10],RDI
CMP qword ptr [RBP + -0x10],0x0
JNZ 0x0011fda0
MOV qword ptr [RBP + -0x8],0x0
JMP 0x0011fef2
LAB_0011fda0:
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x78],0x0
JZ 0x0011fddc
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x78]
CMP dword ptr [RAX + 0x488],0x2
JZ 0x0011fdda
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x78]
CMP dword ptr [RAX + 0x488],0x1
JZ 0x0011fdda
MOV qword ptr [RBP + -0x8],0x0
JMP 0x0011fef2
LAB_0011fdda:
JMP 0x0011fddc
LAB_0011fddc:
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x18],0x0
JNZ 0x0011fe9e
MOV RAX,qword ptr [RBP + -0x10]
CMP byte ptr [RAX + 0x80],0x0
JNZ 0x0011fe94
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x78],0x0
JZ 0x0011fe94
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x78]
MOV RAX,qword ptr [RAX + 0x4d0]
MOV RAX,qword ptr [RAX + 0x30]
MOV RCX,qword ptr [RBP + -0x10]
MOV RDI,qword ptr [RCX + 0x78]
MOV RCX,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RCX + 0x8]
MOV RCX,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RCX + 0x60]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x70]
CALL RAX
CMP EAX,0x0
JNZ 0x0011fe6b
MOV RAX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RAX]
ADD RCX,0x1
MOV qword ptr [RAX],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x60]
MOV RCX,qword ptr [RBP + -0x10]
MOV qword ptr [RCX + 0x68],RAX
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0011fef2
LAB_0011fe6b:
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x80],0x1
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x78]
MOV dword ptr [RAX + 0x488],0x0
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x78],0x0
LAB_0011fe94:
MOV qword ptr [RBP + -0x8],0x0
JMP 0x0011fef2
LAB_0011fe9e:
MOV RAX,qword ptr [RBP + -0x10]
CMP qword ptr [RAX + 0x20],0x0
JNZ 0x0011febf
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x68],0x0
MOV qword ptr [RBP + -0x8],0x0
JMP 0x0011fef2
LAB_0011febf:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x20]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x20]
MOV RCX,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x20],RCX
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x10]
MOV qword ptr [RCX + 0x68],RAX
MOV qword ptr [RBP + -0x8],RAX
LAB_0011fef2:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x20
POP RBP
RET
|
long mysql_fetch_row(long *param_1)
{
int iVar1;
long local_10;
if (param_1 == (long *)0x0) {
local_10 = 0;
}
else if (((param_1[0xf] == 0) || (*(int *)(param_1[0xf] + 0x488) == 2)) ||
(*(int *)(param_1[0xf] + 0x488) == 1)) {
if (param_1[3] == 0) {
if (((char)param_1[0x10] == '\0') && (param_1[0xf] != 0)) {
iVar1 = (**(code **)(*(long *)(param_1[0xf] + 0x4d0) + 0x30))
(param_1[0xf],(int)param_1[1],param_1[0xc],param_1[0xe]);
if (iVar1 == 0) {
*param_1 = *param_1 + 1;
param_1[0xd] = param_1[0xc];
return param_1[0xc];
}
*(int1 *)(param_1 + 0x10) = 1;
*(int4 *)(param_1[0xf] + 0x488) = 0;
param_1[0xf] = 0;
}
local_10 = 0;
}
else if (param_1[4] == 0) {
param_1[0xd] = 0;
local_10 = 0;
}
else {
local_10 = *(long *)(param_1[4] + 8);
param_1[4] = *(long *)param_1[4];
param_1[0xd] = local_10;
}
}
else {
local_10 = 0;
}
return local_10;
}
| |
38,039 | stbi__zhuffman_decode | dmazzella[P]pylunasvg/lunasvg/plutovg/source/plutovg-stb-image.h | stbi_inline static int stbi__zhuffman_decode(stbi__zbuf *a, stbi__zhuffman *z)
{
int b,s;
if (a->num_bits < 16) {
if (stbi__zeof(a)) {
if (!a->hit_zeof_once) {
// This is the first time we hit eof, insert 16 extra padding btis
// to allow us to keep going; if we actually consume any of them
// though, that is invalid data. This is caught later.
a->hit_zeof_once = 1;
a->num_bits += 16; // add 16 implicit zero bits
} else {
// We already inserted our extra 16 padding bits and are again
// out, this stream is actually prematurely terminated.
return -1;
}
} else {
stbi__fill_bits(a);
}
}
b = z->fast[a->code_buffer & STBI__ZFAST_MASK];
if (b) {
s = b >> 9;
a->code_buffer >>= s;
a->num_bits -= s;
return b & 511;
}
return stbi__zhuffman_decode_slowpath(a, z);
} | O0 | c | stbi__zhuffman_decode:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
cmpl $0x10, 0x10(%rax)
jge 0x1cf62
movq -0x10(%rbp), %rdi
callq 0x1cc50
cmpl $0x0, %eax
je 0x1cf57
movq -0x10(%rbp), %rax
cmpl $0x0, 0x14(%rax)
jne 0x1cf4c
movq -0x10(%rbp), %rax
movl $0x1, 0x14(%rax)
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
addl $0x10, %ecx
movl %ecx, 0x10(%rax)
jmp 0x1cf55
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x1cfc8
jmp 0x1cf60
movq -0x10(%rbp), %rdi
callq 0x1cc80
jmp 0x1cf62
movq -0x18(%rbp), %rax
movq -0x10(%rbp), %rcx
movl 0x18(%rcx), %ecx
andl $0x1ff, %ecx # imm = 0x1FF
movl %ecx, %ecx
movzwl (%rax,%rcx,2), %eax
movl %eax, -0x1c(%rbp)
cmpl $0x0, -0x1c(%rbp)
je 0x1cfb8
movl -0x1c(%rbp), %eax
sarl $0x9, %eax
movl %eax, -0x20(%rbp)
movl -0x20(%rbp), %ecx
movq -0x10(%rbp), %rax
movl 0x18(%rax), %edx
shrl %cl, %edx
movl %edx, %ecx
movl %ecx, 0x18(%rax)
movl -0x20(%rbp), %edx
movq -0x10(%rbp), %rax
movl 0x10(%rax), %ecx
subl %edx, %ecx
movl %ecx, 0x10(%rax)
movl -0x1c(%rbp), %eax
andl $0x1ff, %eax # imm = 0x1FF
movl %eax, -0x4(%rbp)
jmp 0x1cfc8
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0x1cfe0
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| stbi__zhuffman_decode:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov rax, [rbp+var_10]
cmp dword ptr [rax+10h], 10h
jge short loc_1CF62
mov rdi, [rbp+var_10]
call stbi__zeof
cmp eax, 0
jz short loc_1CF57
mov rax, [rbp+var_10]
cmp dword ptr [rax+14h], 0
jnz short loc_1CF4C
mov rax, [rbp+var_10]
mov dword ptr [rax+14h], 1
mov rax, [rbp+var_10]
mov ecx, [rax+10h]
add ecx, 10h
mov [rax+10h], ecx
jmp short loc_1CF55
loc_1CF4C:
mov [rbp+var_4], 0FFFFFFFFh
jmp short loc_1CFC8
loc_1CF55:
jmp short loc_1CF60
loc_1CF57:
mov rdi, [rbp+var_10]
call stbi__fill_bits
loc_1CF60:
jmp short $+2
loc_1CF62:
mov rax, [rbp+var_18]
mov rcx, [rbp+var_10]
mov ecx, [rcx+18h]
and ecx, 1FFh
mov ecx, ecx
movzx eax, word ptr [rax+rcx*2]
mov [rbp+var_1C], eax
cmp [rbp+var_1C], 0
jz short loc_1CFB8
mov eax, [rbp+var_1C]
sar eax, 9
mov [rbp+var_20], eax
mov ecx, [rbp+var_20]
mov rax, [rbp+var_10]
mov edx, [rax+18h]
shr edx, cl
mov ecx, edx
mov [rax+18h], ecx
mov edx, [rbp+var_20]
mov rax, [rbp+var_10]
mov ecx, [rax+10h]
sub ecx, edx
mov [rax+10h], ecx
mov eax, [rbp+var_1C]
and eax, 1FFh
mov [rbp+var_4], eax
jmp short loc_1CFC8
loc_1CFB8:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
call stbi__zhuffman_decode_slowpath
mov [rbp+var_4], eax
loc_1CFC8:
mov eax, [rbp+var_4]
add rsp, 20h
pop rbp
retn
| long long stbi__zhuffman_decode(long long a1, long long a2)
{
long long v2; // rcx
int v4; // [rsp+4h] [rbp-1Ch]
if ( *(int *)(a1 + 16) < 16 )
{
if ( stbi__zeof((_QWORD *)a1) )
{
if ( *(_DWORD *)(a1 + 20) )
return (unsigned int)-1;
*(_DWORD *)(a1 + 20) = 1;
*(_DWORD *)(a1 + 16) += 16;
}
else
{
stbi__fill_bits(a1);
}
}
v2 = *(_DWORD *)(a1 + 24) & 0x1FF;
v4 = *(unsigned __int16 *)(a2 + 2 * v2);
if ( *(_WORD *)(a2 + 2 * v2) )
{
*(_DWORD *)(a1 + 24) >>= v4 >> 9;
*(_DWORD *)(a1 + 16) -= v4 >> 9;
return v4 & 0x1FF;
}
else
{
return (unsigned int)stbi__zhuffman_decode_slowpath(a1, a2);
}
}
| stbi__zhuffman_decode:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x10],0x10
JGE 0x0011cf62
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0011cc50
CMP EAX,0x0
JZ 0x0011cf57
MOV RAX,qword ptr [RBP + -0x10]
CMP dword ptr [RAX + 0x14],0x0
JNZ 0x0011cf4c
MOV RAX,qword ptr [RBP + -0x10]
MOV dword ptr [RAX + 0x14],0x1
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x10]
ADD ECX,0x10
MOV dword ptr [RAX + 0x10],ECX
JMP 0x0011cf55
LAB_0011cf4c:
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x0011cfc8
LAB_0011cf55:
JMP 0x0011cf60
LAB_0011cf57:
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0011cc80
LAB_0011cf60:
JMP 0x0011cf62
LAB_0011cf62:
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RCX + 0x18]
AND ECX,0x1ff
MOV ECX,ECX
MOVZX EAX,word ptr [RAX + RCX*0x2]
MOV dword ptr [RBP + -0x1c],EAX
CMP dword ptr [RBP + -0x1c],0x0
JZ 0x0011cfb8
MOV EAX,dword ptr [RBP + -0x1c]
SAR EAX,0x9
MOV dword ptr [RBP + -0x20],EAX
MOV ECX,dword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x10]
MOV EDX,dword ptr [RAX + 0x18]
SHR EDX,CL
MOV ECX,EDX
MOV dword ptr [RAX + 0x18],ECX
MOV EDX,dword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x10]
MOV ECX,dword ptr [RAX + 0x10]
SUB ECX,EDX
MOV dword ptr [RAX + 0x10],ECX
MOV EAX,dword ptr [RBP + -0x1c]
AND EAX,0x1ff
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0011cfc8
LAB_0011cfb8:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x0011cfe0
MOV dword ptr [RBP + -0x4],EAX
LAB_0011cfc8:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x20
POP RBP
RET
|
uint stbi__zhuffman_decode(long param_1,long param_2)
{
int iVar1;
uint local_c;
if (*(int *)(param_1 + 0x10) < 0x10) {
iVar1 = stbi__zeof(param_1);
if (iVar1 == 0) {
stbi__fill_bits(param_1);
}
else {
if (*(int *)(param_1 + 0x14) != 0) {
return 0xffffffff;
}
*(int4 *)(param_1 + 0x14) = 1;
*(int *)(param_1 + 0x10) = *(int *)(param_1 + 0x10) + 0x10;
}
}
local_c = (uint)*(ushort *)(param_2 + (ulong)(*(uint *)(param_1 + 0x18) & 0x1ff) * 2);
if (local_c == 0) {
local_c = stbi__zhuffman_decode_slowpath(param_1,param_2);
}
else {
*(uint *)(param_1 + 0x18) = *(uint *)(param_1 + 0x18) >> ((byte)((int)local_c >> 9) & 0x1f);
*(int *)(param_1 + 0x10) = *(int *)(param_1 + 0x10) - ((int)local_c >> 9);
local_c = local_c & 0x1ff;
}
return local_c;
}
| |
38,040 | ch2x | eloqsql/strings/ctype-uca.c | static int ch2x(int ch)
{
if (ch >= '0' && ch <= '9')
return ch - '0';
if (ch >= 'a' && ch <= 'f')
return 10 + ch - 'a';
if (ch >= 'A' && ch <= 'F')
return 10 + ch - 'A';
return -1;
} | O0 | c | ch2x:
pushq %rbp
movq %rsp, %rbp
movl %edi, -0x8(%rbp)
cmpl $0x30, -0x8(%rbp)
jl 0x4f1fe
cmpl $0x39, -0x8(%rbp)
jg 0x4f1fe
movl -0x8(%rbp), %eax
subl $0x30, %eax
movl %eax, -0x4(%rbp)
jmp 0x4f239
cmpl $0x61, -0x8(%rbp)
jl 0x4f218
cmpl $0x66, -0x8(%rbp)
jg 0x4f218
movl -0x8(%rbp), %eax
addl $0xa, %eax
subl $0x61, %eax
movl %eax, -0x4(%rbp)
jmp 0x4f239
cmpl $0x41, -0x8(%rbp)
jl 0x4f232
cmpl $0x46, -0x8(%rbp)
jg 0x4f232
movl -0x8(%rbp), %eax
addl $0xa, %eax
subl $0x41, %eax
movl %eax, -0x4(%rbp)
jmp 0x4f239
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
movl -0x4(%rbp), %eax
popq %rbp
retq
nop
| ch2x:
push rbp
mov rbp, rsp
mov [rbp+var_8], edi
cmp [rbp+var_8], 30h ; '0'
jl short loc_4F1FE
cmp [rbp+var_8], 39h ; '9'
jg short loc_4F1FE
mov eax, [rbp+var_8]
sub eax, 30h ; '0'
mov [rbp+var_4], eax
jmp short loc_4F239
loc_4F1FE:
cmp [rbp+var_8], 61h ; 'a'
jl short loc_4F218
cmp [rbp+var_8], 66h ; 'f'
jg short loc_4F218
mov eax, [rbp+var_8]
add eax, 0Ah
sub eax, 61h ; 'a'
mov [rbp+var_4], eax
jmp short loc_4F239
loc_4F218:
cmp [rbp+var_8], 41h ; 'A'
jl short loc_4F232
cmp [rbp+var_8], 46h ; 'F'
jg short loc_4F232
mov eax, [rbp+var_8]
add eax, 0Ah
sub eax, 41h ; 'A'
mov [rbp+var_4], eax
jmp short loc_4F239
loc_4F232:
mov [rbp+var_4], 0FFFFFFFFh
loc_4F239:
mov eax, [rbp+var_4]
pop rbp
retn
| long long ch2x(int a1)
{
if ( a1 < 48 || a1 > 57 )
{
if ( a1 < 97 || a1 > 102 )
{
if ( a1 < 65 || a1 > 70 )
return (unsigned int)-1;
else
return (unsigned int)(a1 - 55);
}
else
{
return (unsigned int)(a1 - 87);
}
}
else
{
return (unsigned int)(a1 - 48);
}
}
| ch2x:
PUSH RBP
MOV RBP,RSP
MOV dword ptr [RBP + -0x8],EDI
CMP dword ptr [RBP + -0x8],0x30
JL 0x0014f1fe
CMP dword ptr [RBP + -0x8],0x39
JG 0x0014f1fe
MOV EAX,dword ptr [RBP + -0x8]
SUB EAX,0x30
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014f239
LAB_0014f1fe:
CMP dword ptr [RBP + -0x8],0x61
JL 0x0014f218
CMP dword ptr [RBP + -0x8],0x66
JG 0x0014f218
MOV EAX,dword ptr [RBP + -0x8]
ADD EAX,0xa
SUB EAX,0x61
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014f239
LAB_0014f218:
CMP dword ptr [RBP + -0x8],0x41
JL 0x0014f232
CMP dword ptr [RBP + -0x8],0x46
JG 0x0014f232
MOV EAX,dword ptr [RBP + -0x8]
ADD EAX,0xa
SUB EAX,0x41
MOV dword ptr [RBP + -0x4],EAX
JMP 0x0014f239
LAB_0014f232:
MOV dword ptr [RBP + -0x4],0xffffffff
LAB_0014f239:
MOV EAX,dword ptr [RBP + -0x4]
POP RBP
RET
|
int ch2x(int param_1)
{
int4 local_c;
if ((param_1 < 0x30) || (0x39 < param_1)) {
if ((param_1 < 0x61) || (0x66 < param_1)) {
if ((param_1 < 0x41) || (0x46 < param_1)) {
local_c = -1;
}
else {
local_c = param_1 + -0x37;
}
}
else {
local_c = param_1 + -0x57;
}
}
else {
local_c = param_1 + -0x30;
}
return local_c;
}
| |
38,041 | my_uni_utf16 | eloqsql/strings/ctype-ucs2.c | int
my_uni_utf16(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t wc, uchar *s, uchar *e)
{
if (wc <= 0xFFFF)
{
if (s + 2 > e)
return MY_CS_TOOSMALL2;
if (MY_UTF16_SURROGATE(wc))
return MY_CS_ILUNI;
*s++= (uchar) (wc >> 8);
*s= (uchar) (wc & 0xFF);
return 2;
}
if (wc <= 0x10FFFF)
{
if (s + 4 > e)
return MY_CS_TOOSMALL4;
*s++= (uchar) ((wc-= 0x10000) >> 18) | 0xD8;
*s++= (uchar) (wc >> 10) & 0xFF;
*s++= (uchar) ((wc >> 8) & 3) | 0xDC;
*s= (uchar) wc & 0xFF;
return 4;
}
return MY_CS_ILUNI;
} | O0 | c | my_uni_utf16:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
cmpq $0xffff, -0x18(%rbp) # imm = 0xFFFF
ja 0x67cdf
movq -0x20(%rbp), %rax
addq $0x2, %rax
cmpq -0x28(%rbp), %rax
jbe 0x67c88
movl $0xffffff9a, -0x4(%rbp) # imm = 0xFFFFFF9A
jmp 0x67da2
movq -0x18(%rbp), %rax
andq $0xf800, %rax # imm = 0xF800
cmpq $0xd800, %rax # imm = 0xD800
jne 0x67ca6
movl $0x0, -0x4(%rbp)
jmp 0x67da2
movq -0x18(%rbp), %rax
shrq $0x8, %rax
movb %al, %cl
movq -0x20(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x20(%rbp)
movb %cl, (%rax)
movq -0x18(%rbp), %rax
andq $0xff, %rax
movb %al, %cl
movq -0x20(%rbp), %rax
movb %cl, (%rax)
movl $0x2, -0x4(%rbp)
jmp 0x67da2
cmpq $0x10ffff, -0x18(%rbp) # imm = 0x10FFFF
ja 0x67d9b
movq -0x20(%rbp), %rax
addq $0x4, %rax
cmpq -0x28(%rbp), %rax
jbe 0x67d07
movl $0xffffff98, -0x4(%rbp) # imm = 0xFFFFFF98
jmp 0x67da2
movq -0x18(%rbp), %rax
subq $0x10000, %rax # imm = 0x10000
movq %rax, -0x18(%rbp)
shrq $0x12, %rax
movzbl %al, %eax
orl $0xd8, %eax
movb %al, %cl
movq -0x20(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x20(%rbp)
movb %cl, (%rax)
movq -0x18(%rbp), %rax
shrq $0xa, %rax
movzbl %al, %eax
andl $0xff, %eax
movb %al, %cl
movq -0x20(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x20(%rbp)
movb %cl, (%rax)
movq -0x18(%rbp), %rax
shrq $0x8, %rax
andq $0x3, %rax
movzbl %al, %eax
orl $0xdc, %eax
movb %al, %cl
movq -0x20(%rbp), %rax
movq %rax, %rdx
addq $0x1, %rdx
movq %rdx, -0x20(%rbp)
movb %cl, (%rax)
movq -0x18(%rbp), %rax
movzbl %al, %eax
andl $0xff, %eax
movb %al, %cl
movq -0x20(%rbp), %rax
movb %cl, (%rax)
movl $0x4, -0x4(%rbp)
jmp 0x67da2
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nopw (%rax,%rax)
| my_uni_utf16:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
cmp [rbp+var_18], 0FFFFh
ja short loc_67CDF
mov rax, [rbp+var_20]
add rax, 2
cmp rax, [rbp+var_28]
jbe short loc_67C88
mov [rbp+var_4], 0FFFFFF9Ah
jmp loc_67DA2
loc_67C88:
mov rax, [rbp+var_18]
and rax, 0F800h
cmp rax, 0D800h
jnz short loc_67CA6
mov [rbp+var_4], 0
jmp loc_67DA2
loc_67CA6:
mov rax, [rbp+var_18]
shr rax, 8
mov cl, al
mov rax, [rbp+var_20]
mov rdx, rax
add rdx, 1
mov [rbp+var_20], rdx
mov [rax], cl
mov rax, [rbp+var_18]
and rax, 0FFh
mov cl, al
mov rax, [rbp+var_20]
mov [rax], cl
mov [rbp+var_4], 2
jmp loc_67DA2
loc_67CDF:
cmp [rbp+var_18], offset unk_10FFFF
ja loc_67D9B
mov rax, [rbp+var_20]
add rax, 4
cmp rax, [rbp+var_28]
jbe short loc_67D07
mov [rbp+var_4], 0FFFFFF98h
jmp loc_67DA2
loc_67D07:
mov rax, [rbp+var_18]
sub rax, 10000h
mov [rbp+var_18], rax
shr rax, 12h
movzx eax, al
or eax, 0D8h
mov cl, al
mov rax, [rbp+var_20]
mov rdx, rax
add rdx, 1
mov [rbp+var_20], rdx
mov [rax], cl
mov rax, [rbp+var_18]
shr rax, 0Ah
movzx eax, al
and eax, 0FFh
mov cl, al
mov rax, [rbp+var_20]
mov rdx, rax
add rdx, 1
mov [rbp+var_20], rdx
mov [rax], cl
mov rax, [rbp+var_18]
shr rax, 8
and rax, 3
movzx eax, al
or eax, 0DCh
mov cl, al
mov rax, [rbp+var_20]
mov rdx, rax
add rdx, 1
mov [rbp+var_20], rdx
mov [rax], cl
mov rax, [rbp+var_18]
movzx eax, al
and eax, 0FFh
mov cl, al
mov rax, [rbp+var_20]
mov [rax], cl
mov [rbp+var_4], 4
jmp short loc_67DA2
loc_67D9B:
mov [rbp+var_4], 0
loc_67DA2:
mov eax, [rbp+var_4]
pop rbp
retn
| long long my_uni_utf16(long long a1, unsigned long long a2, _BYTE *a3, unsigned long long a4)
{
if ( a2 > 0xFFFF )
{
if ( a2 > (unsigned long long)&unk_10FFFF )
{
return 0;
}
else if ( (unsigned long long)(a3 + 4) <= a4 )
{
*a3 = ((a2 - 0x10000) >> 18) | 0xD8;
a3[1] = (a2 - 0x10000) >> 10;
a3[2] = BYTE1(a2) & 3 | 0xDC;
a3[3] = a2;
return 4;
}
else
{
return (unsigned int)-104;
}
}
else if ( (unsigned long long)(a3 + 2) <= a4 )
{
if ( (a2 & 0xF800) == 0xD800 )
{
return 0;
}
else
{
*a3 = BYTE1(a2);
a3[1] = a2;
return 2;
}
}
else
{
return (unsigned int)-102;
}
}
| my_uni_utf16:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
CMP qword ptr [RBP + -0x18],0xffff
JA 0x00167cdf
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x2
CMP RAX,qword ptr [RBP + -0x28]
JBE 0x00167c88
MOV dword ptr [RBP + -0x4],0xffffff9a
JMP 0x00167da2
LAB_00167c88:
MOV RAX,qword ptr [RBP + -0x18]
AND RAX,0xf800
CMP RAX,0xd800
JNZ 0x00167ca6
MOV dword ptr [RBP + -0x4],0x0
JMP 0x00167da2
LAB_00167ca6:
MOV RAX,qword ptr [RBP + -0x18]
SHR RAX,0x8
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV RDX,RAX
ADD RDX,0x1
MOV qword ptr [RBP + -0x20],RDX
MOV byte ptr [RAX],CL
MOV RAX,qword ptr [RBP + -0x18]
AND RAX,0xff
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV byte ptr [RAX],CL
MOV dword ptr [RBP + -0x4],0x2
JMP 0x00167da2
LAB_00167cdf:
CMP qword ptr [RBP + -0x18],0x10ffff
JA 0x00167d9b
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x4
CMP RAX,qword ptr [RBP + -0x28]
JBE 0x00167d07
MOV dword ptr [RBP + -0x4],0xffffff98
JMP 0x00167da2
LAB_00167d07:
MOV RAX,qword ptr [RBP + -0x18]
SUB RAX,0x10000
MOV qword ptr [RBP + -0x18],RAX
SHR RAX,0x12
MOVZX EAX,AL
OR EAX,0xd8
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV RDX,RAX
ADD RDX,0x1
MOV qword ptr [RBP + -0x20],RDX
MOV byte ptr [RAX],CL
MOV RAX,qword ptr [RBP + -0x18]
SHR RAX,0xa
MOVZX EAX,AL
AND EAX,0xff
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV RDX,RAX
ADD RDX,0x1
MOV qword ptr [RBP + -0x20],RDX
MOV byte ptr [RAX],CL
MOV RAX,qword ptr [RBP + -0x18]
SHR RAX,0x8
AND RAX,0x3
MOVZX EAX,AL
OR EAX,0xdc
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV RDX,RAX
ADD RDX,0x1
MOV qword ptr [RBP + -0x20],RDX
MOV byte ptr [RAX],CL
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,AL
AND EAX,0xff
MOV CL,AL
MOV RAX,qword ptr [RBP + -0x20]
MOV byte ptr [RAX],CL
MOV dword ptr [RBP + -0x4],0x4
JMP 0x00167da2
LAB_00167d9b:
MOV dword ptr [RBP + -0x4],0x0
LAB_00167da2:
MOV EAX,dword ptr [RBP + -0x4]
POP RBP
RET
|
int4 my_uni_utf16(int8 param_1,ulong param_2,byte *param_3,byte *param_4)
{
int4 local_c;
if (param_2 < 0x10000) {
if (param_4 < param_3 + 2) {
local_c = 0xffffff9a;
}
else if ((param_2 & 0xf800) == 0xd800) {
local_c = 0;
}
else {
*param_3 = (byte)(param_2 >> 8);
param_3[1] = (byte)param_2;
local_c = 2;
}
}
else if (param_2 < 0x110000) {
if (param_4 < param_3 + 4) {
local_c = 0xffffff98;
}
else {
param_2 = param_2 - 0x10000;
*param_3 = (byte)(param_2 >> 0x12) | 0xd8;
param_3[1] = (byte)(param_2 >> 10);
param_3[2] = (byte)(param_2 >> 8) & 3 | 0xdc;
param_3[3] = (byte)param_2;
local_c = 4;
}
}
else {
local_c = 0;
}
return local_c;
}
| |
38,042 | ma_apply_undo_row_insert | eloqsql/storage/maria/ma_blockrec.c | my_bool _ma_apply_undo_row_insert(MARIA_HA *info, LSN undo_lsn,
const uchar *header)
{
pgcache_page_no_t page;
uint rownr;
uchar *buff;
my_bool res;
MARIA_PINNED_PAGE page_link;
MARIA_SHARE *share= info->s;
ha_checksum checksum;
LSN lsn;
DBUG_ENTER("_ma_apply_undo_row_insert");
page= page_korr(header);
header+= PAGE_STORE_SIZE;
rownr= dirpos_korr(header);
header+= DIRPOS_STORE_SIZE;
DBUG_PRINT("enter", ("rowid: %lu page: %lu rownr: %u",
(ulong) ma_recordpos(page, rownr),
(ulong) page, rownr));
buff= pagecache_read(share->pagecache,
&info->dfile, page, 0,
0, share->page_type,
PAGECACHE_LOCK_WRITE,
&page_link.link);
page_link.unlock= PAGECACHE_LOCK_WRITE_UNLOCK;
page_link.changed= buff != 0;
push_dynamic(&info->pinned_pages, (void*) &page_link);
if (!buff)
goto err;
if (read_row_extent_info(info, buff, rownr))
goto err;
_ma_bitmap_flushable(info, 1);
if (delete_head_or_tail(info, page, rownr, 1, 1) ||
delete_tails(info, info->cur_row.tail_positions))
goto err;
if (info->cur_row.extents_count && free_full_pages(info, &info->cur_row))
goto err;
checksum= 0;
if (share->calc_checksum)
checksum= (ha_checksum) 0 - ha_checksum_korr(header);
info->last_auto_increment= ~ (ulonglong) 0;
if (_ma_write_clr(info, undo_lsn, LOGREC_UNDO_ROW_INSERT,
share->calc_checksum != 0, checksum, &lsn, (void*) 0))
goto err;
res= 0;
end:
/* The following is true only if _ma_bitmap_flushable() was called earlier */
if (info->non_flushable_state)
_ma_bitmap_flushable(info, -1);
_ma_unpin_all_pages_and_finalize_row(info, lsn);
DBUG_RETURN(res);
err:
DBUG_ASSERT(!maria_assert_if_crashed_table);
res= 1;
_ma_mark_file_crashed(share);
/*
Don't write a new LSN on the used pages. Not important as the file is
marked as crashed and need to be repaired before it can be used.
*/
lsn= LSN_IMPOSSIBLE;
goto end;
} | O0 | c | ma_apply_undo_row_insert:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x58(%rbp)
movq -0x18(%rbp), %rdi
callq 0x56790
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rax
addq $0x5, %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rax
movzbl (%rax), %eax
movl %eax, -0x24(%rbp)
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0x57f63
movq -0x58(%rbp), %rax
movq 0x600(%rax), %rdi
movq -0x8(%rbp), %rsi
addq $0x470, %rsi # imm = 0x470
movq -0x20(%rbp), %rdx
movq -0x58(%rbp), %rax
movl 0x7d4(%rax), %r9d
leaq -0x50(%rbp), %rax
xorl %ecx, %ecx
xorl %r8d, %r8d
movl $0x4, (%rsp)
movq %rax, 0x8(%rsp)
callq 0x96df0
movq %rax, -0x30(%rbp)
movl $0x6, -0x48(%rbp)
cmpq $0x0, -0x30(%rbp)
setne %al
andb $0x1, %al
movzbl %al, %eax
movb %al, -0x40(%rbp)
movq -0x8(%rbp), %rdi
addq $0x2e8, %rdi # imm = 0x2E8
leaq -0x50(%rbp), %rsi
callq 0xdd8b0
cmpq $0x0, -0x30(%rbp)
jne 0x57fdd
jmp 0x5811c
movq -0x8(%rbp), %rdi
movq -0x30(%rbp), %rsi
movl -0x24(%rbp), %edx
callq 0x58140
cmpb $0x0, %al
je 0x57ff6
jmp 0x5811c
movq -0x8(%rbp), %rdi
movl $0x1, %esi
callq 0x60200
movq -0x8(%rbp), %rdi
movq -0x20(%rbp), %rsi
movl -0x24(%rbp), %edx
movl $0x1, %r8d
movl %r8d, %ecx
callq 0x52230
movsbl %al, %eax
cmpl $0x0, %eax
jne 0x58041
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rax
movq 0xa8(%rax), %rsi
callq 0x53230
movsbl %al, %eax
cmpl $0x0, %eax
je 0x58046
jmp 0x5811c
movq -0x8(%rbp), %rax
cmpl $0x0, 0x12c(%rax)
je 0x58074
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rsi
addq $0x80, %rsi
callq 0x532c0
movsbl %al, %eax
cmpl $0x0, %eax
je 0x58074
jmp 0x5811c
movl $0x0, -0x5c(%rbp)
movq -0x58(%rbp), %rax
cmpq $0x0, 0x6a8(%rax)
je 0x58094
movq -0x18(%rbp), %rcx
xorl %eax, %eax
subl (%rcx), %eax
movl %eax, -0x5c(%rbp)
movq -0x8(%rbp), %rax
movq $-0x1, 0x3e8(%rax)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
movq -0x58(%rbp), %rax
cmpq $0x0, 0x6a8(%rax)
setne %al
andb $0x1, %al
movzbl %al, %eax
movl -0x5c(%rbp), %r8d
movl $0x12, %edx
leaq -0x68(%rbp), %r9
xorl %ecx, %ecx
movsbl %al, %ecx
movq $0x0, (%rsp)
callq 0x3f280
cmpb $0x0, %al
je 0x580e4
jmp 0x5811c
movb $0x0, -0x31(%rbp)
movq -0x8(%rbp), %rax
cmpl $0x0, 0x644(%rax)
je 0x58103
movq -0x8(%rbp), %rdi
movl $0xffffffff, %esi # imm = 0xFFFFFFFF
callq 0x60200
movq -0x8(%rbp), %rdi
movq -0x68(%rbp), %rsi
callq 0x52840
movb -0x31(%rbp), %al
addq $0x80, %rsp
popq %rbp
retq
jmp 0x5811e
jmp 0x58120
movb $0x1, -0x31(%rbp)
movq -0x58(%rbp), %rdi
callq 0x44570
movq $0x0, -0x68(%rbp)
jmp 0x580e8
nopw (%rax,%rax)
| _ma_apply_undo_row_insert:
push rbp
mov rbp, rsp
sub rsp, 80h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov rax, [rbp+var_8]
mov rax, [rax]
mov [rbp+var_58], rax
mov rdi, [rbp+var_18]
call uint5korr_0
mov [rbp+var_20], rax
mov rax, [rbp+var_18]
add rax, 5
mov [rbp+var_18], rax
mov rax, [rbp+var_18]
movzx eax, byte ptr [rax]
mov [rbp+var_24], eax
mov rax, [rbp+var_18]
add rax, 1
mov [rbp+var_18], rax
jmp short $+2
loc_57F63:
mov rax, [rbp+var_58]
mov rdi, [rax+600h]
mov rsi, [rbp+var_8]
add rsi, 470h
mov rdx, [rbp+var_20]
mov rax, [rbp+var_58]
mov r9d, [rax+7D4h]
lea rax, [rbp+var_50]
xor ecx, ecx
xor r8d, r8d
mov dword ptr [rsp+80h+var_80], 4
mov [rsp+80h+var_78], rax
call pagecache_read
mov [rbp+var_30], rax
mov [rbp+var_48], 6
cmp [rbp+var_30], 0
setnz al
and al, 1
movzx eax, al
mov [rbp+var_40], al
mov rdi, [rbp+var_8]
add rdi, 2E8h
lea rsi, [rbp+var_50]
call insert_dynamic
cmp [rbp+var_30], 0
jnz short loc_57FDD
jmp loc_5811C
loc_57FDD:
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_30]
mov edx, [rbp+var_24]
call read_row_extent_info
cmp al, 0
jz short loc_57FF6
jmp loc_5811C
loc_57FF6:
mov rdi, [rbp+var_8]
mov esi, 1
call _ma_bitmap_flushable
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_20]
mov edx, [rbp+var_24]
mov r8d, 1
mov ecx, r8d
call delete_head_or_tail
movsx eax, al
cmp eax, 0
jnz short loc_58041
mov rdi, [rbp+var_8]
mov rax, [rbp+var_8]
mov rsi, [rax+0A8h]
call delete_tails
movsx eax, al
cmp eax, 0
jz short loc_58046
loc_58041:
jmp loc_5811C
loc_58046:
mov rax, [rbp+var_8]
cmp dword ptr [rax+12Ch], 0
jz short loc_58074
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_8]
add rsi, 80h
call free_full_pages
movsx eax, al
cmp eax, 0
jz short loc_58074
jmp loc_5811C
loc_58074:
mov [rbp+var_5C], 0
mov rax, [rbp+var_58]
cmp qword ptr [rax+6A8h], 0
jz short loc_58094
mov rcx, [rbp+var_18]
xor eax, eax
sub eax, [rcx]
mov [rbp+var_5C], eax
loc_58094:
mov rax, [rbp+var_8]
mov qword ptr [rax+3E8h], 0FFFFFFFFFFFFFFFFh
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_10]
mov rax, [rbp+var_58]
cmp qword ptr [rax+6A8h], 0
setnz al
and al, 1
movzx eax, al
mov r8d, [rbp+var_5C]
mov edx, 12h
lea r9, [rbp+var_68]
xor ecx, ecx
movsx ecx, al
mov [rsp+80h+var_80], 0
call _ma_write_clr
cmp al, 0
jz short loc_580E4
jmp short loc_5811C
loc_580E4:
mov [rbp+var_31], 0
loc_580E8:
mov rax, [rbp+var_8]
cmp dword ptr [rax+644h], 0
jz short loc_58103
mov rdi, [rbp+var_8]
mov esi, 0FFFFFFFFh
call _ma_bitmap_flushable
loc_58103:
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_68]
call _ma_unpin_all_pages_and_finalize_row_0
mov al, [rbp+var_31]
add rsp, 80h
pop rbp
retn
loc_5811C:
jmp short $+2
loc_5811E:
jmp short $+2
loc_58120:
mov [rbp+var_31], 1
mov rdi, [rbp+var_58]
call _ma_mark_file_crashed
mov [rbp+var_68], 0
jmp short loc_580E8
| char ma_apply_undo_row_insert(_QWORD *a1, long long a2, unsigned int *a3)
{
long long v4; // [rsp+18h] [rbp-68h] BYREF
int v5; // [rsp+24h] [rbp-5Ch]
long long v6; // [rsp+28h] [rbp-58h]
_BYTE v7[8]; // [rsp+30h] [rbp-50h] BYREF
int v8; // [rsp+38h] [rbp-48h]
bool v9; // [rsp+40h] [rbp-40h]
char v10; // [rsp+4Fh] [rbp-31h]
long long v11; // [rsp+50h] [rbp-30h]
unsigned int v12; // [rsp+5Ch] [rbp-24h]
unsigned long long v13; // [rsp+60h] [rbp-20h]
unsigned int *v14; // [rsp+68h] [rbp-18h]
long long v15; // [rsp+70h] [rbp-10h]
_QWORD *v16; // [rsp+78h] [rbp-8h]
v16 = a1;
v15 = a2;
v14 = a3;
v6 = *a1;
v13 = uint5korr_0(a3);
v14 = (unsigned int *)((char *)v14 + 5);
v12 = *(unsigned __int8 *)v14;
v14 = (unsigned int *)((char *)v14 + 1);
v11 = pagecache_read(*(_QWORD *)(v6 + 1536), (int)a1 + 1136, v13, 0, 0, *(_DWORD *)(v6 + 2004), 4, (long long)v7);
v8 = 6;
v9 = v11 != 0;
insert_dynamic(v16 + 93, v7);
if ( !v11 )
goto LABEL_15;
if ( (unsigned __int8)read_row_extent_info(v16, v11, v12) )
goto LABEL_15;
ma_bitmap_flushable(v16, 1LL);
if ( delete_head_or_tail(v16, v13, v12, 1, 1)
|| delete_tails(v16, (unsigned long long *)v16[21])
|| *((_DWORD *)v16 + 75) && free_full_pages((long long)v16, (long long)(v16 + 16)) )
{
goto LABEL_15;
}
v5 = 0;
if ( *(_QWORD *)(v6 + 1704) )
v5 = -*v14;
v16[125] = -1LL;
if ( ma_write_clr(v16, v15, 18, *(_QWORD *)(v6 + 1704) != 0LL, v5, (long long)&v4, 0LL) )
{
LABEL_15:
v10 = 1;
ma_mark_file_crashed(v6);
v4 = 0LL;
}
else
{
v10 = 0;
}
if ( *((_DWORD *)v16 + 401) )
ma_bitmap_flushable(v16, 0xFFFFFFFFLL);
ma_unpin_all_pages_and_finalize_row_0((long long)v16, v4);
return v10;
}
| _ma_apply_undo_row_insert:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x80
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x58],RAX
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x00156790
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x5
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX]
MOV dword ptr [RBP + -0x24],EAX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x1
MOV qword ptr [RBP + -0x18],RAX
JMP 0x00157f63
LAB_00157f63:
MOV RAX,qword ptr [RBP + -0x58]
MOV RDI,qword ptr [RAX + 0x600]
MOV RSI,qword ptr [RBP + -0x8]
ADD RSI,0x470
MOV RDX,qword ptr [RBP + -0x20]
MOV RAX,qword ptr [RBP + -0x58]
MOV R9D,dword ptr [RAX + 0x7d4]
LEA RAX,[RBP + -0x50]
XOR ECX,ECX
XOR R8D,R8D
MOV dword ptr [RSP],0x4
MOV qword ptr [RSP + 0x8],RAX
CALL 0x00196df0
MOV qword ptr [RBP + -0x30],RAX
MOV dword ptr [RBP + -0x48],0x6
CMP qword ptr [RBP + -0x30],0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
MOV byte ptr [RBP + -0x40],AL
MOV RDI,qword ptr [RBP + -0x8]
ADD RDI,0x2e8
LEA RSI,[RBP + -0x50]
CALL 0x001dd8b0
CMP qword ptr [RBP + -0x30],0x0
JNZ 0x00157fdd
JMP 0x0015811c
LAB_00157fdd:
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x30]
MOV EDX,dword ptr [RBP + -0x24]
CALL 0x00158140
CMP AL,0x0
JZ 0x00157ff6
JMP 0x0015811c
LAB_00157ff6:
MOV RDI,qword ptr [RBP + -0x8]
MOV ESI,0x1
CALL 0x00160200
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x20]
MOV EDX,dword ptr [RBP + -0x24]
MOV R8D,0x1
MOV ECX,R8D
CALL 0x00152230
MOVSX EAX,AL
CMP EAX,0x0
JNZ 0x00158041
MOV RDI,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RAX + 0xa8]
CALL 0x00153230
MOVSX EAX,AL
CMP EAX,0x0
JZ 0x00158046
LAB_00158041:
JMP 0x0015811c
LAB_00158046:
MOV RAX,qword ptr [RBP + -0x8]
CMP dword ptr [RAX + 0x12c],0x0
JZ 0x00158074
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x8]
ADD RSI,0x80
CALL 0x001532c0
MOVSX EAX,AL
CMP EAX,0x0
JZ 0x00158074
JMP 0x0015811c
LAB_00158074:
MOV dword ptr [RBP + -0x5c],0x0
MOV RAX,qword ptr [RBP + -0x58]
CMP qword ptr [RAX + 0x6a8],0x0
JZ 0x00158094
MOV RCX,qword ptr [RBP + -0x18]
XOR EAX,EAX
SUB EAX,dword ptr [RCX]
MOV dword ptr [RBP + -0x5c],EAX
LAB_00158094:
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x3e8],-0x1
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x58]
CMP qword ptr [RAX + 0x6a8],0x0
SETNZ AL
AND AL,0x1
MOVZX EAX,AL
MOV R8D,dword ptr [RBP + -0x5c]
MOV EDX,0x12
LEA R9,[RBP + -0x68]
XOR ECX,ECX
MOVSX ECX,AL
MOV qword ptr [RSP],0x0
CALL 0x0013f280
CMP AL,0x0
JZ 0x001580e4
JMP 0x0015811c
LAB_001580e4:
MOV byte ptr [RBP + -0x31],0x0
LAB_001580e8:
MOV RAX,qword ptr [RBP + -0x8]
CMP dword ptr [RAX + 0x644],0x0
JZ 0x00158103
MOV RDI,qword ptr [RBP + -0x8]
MOV ESI,0xffffffff
CALL 0x00160200
LAB_00158103:
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x68]
CALL 0x00152840
MOV AL,byte ptr [RBP + -0x31]
ADD RSP,0x80
POP RBP
RET
LAB_0015811c:
JMP 0x0015811e
LAB_0015811e:
JMP 0x00158120
LAB_00158120:
MOV byte ptr [RBP + -0x31],0x1
MOV RDI,qword ptr [RBP + -0x58]
CALL 0x00144570
MOV qword ptr [RBP + -0x68],0x0
JMP 0x001580e8
|
int1 _ma_apply_undo_row_insert(long *param_1,int8 param_2,long param_3)
{
char cVar1;
int8 in_stack_ffffffffffffff78;
int4 uVar2;
int8 local_70;
int local_64;
long local_60;
int1 local_58 [8];
int4 local_50;
int1 local_48;
int1 local_39;
long local_38;
uint local_2c;
int8 local_28;
int *local_20;
int8 local_18;
long *local_10;
uVar2 = (int4)((ulong)in_stack_ffffffffffffff78 >> 0x20);
local_60 = *param_1;
local_20 = (int *)param_3;
local_18 = param_2;
local_10 = param_1;
local_28 = uint5korr(param_3);
local_2c = (uint)*(byte *)((long)local_20 + 5);
local_20 = (int *)((long)local_20 + 6);
local_38 = pagecache_read(*(int8 *)(local_60 + 0x600),local_10 + 0x8e,local_28,0,0,
*(int4 *)(local_60 + 0x7d4),CONCAT44(uVar2,4),local_58);
local_50 = 6;
local_48 = local_38 != 0;
insert_dynamic(local_10 + 0x5d,local_58);
if ((local_38 != 0) && (cVar1 = read_row_extent_info(local_10,local_38,local_2c), cVar1 == '\0'))
{
_ma_bitmap_flushable(local_10,1);
cVar1 = delete_head_or_tail(local_10,local_28,local_2c,1);
if (((cVar1 == '\0') && (cVar1 = delete_tails(local_10,local_10[0x15]), cVar1 == '\0')) &&
((*(int *)((long)local_10 + 300) == 0 ||
(cVar1 = free_full_pages(local_10,local_10 + 0x10), cVar1 == '\0')))) {
local_64 = 0;
if (*(long *)(local_60 + 0x6a8) != 0) {
local_64 = -*local_20;
}
local_10[0x7d] = -1;
cVar1 = _ma_write_clr(local_10,local_18,0x12,*(long *)(local_60 + 0x6a8) != 0,local_64,
&local_70,0);
if (cVar1 == '\0') {
local_39 = 0;
goto LAB_001580e8;
}
}
}
local_39 = 1;
_ma_mark_file_crashed(local_60);
local_70 = 0;
LAB_001580e8:
if (*(int *)((long)local_10 + 0x644) != 0) {
_ma_bitmap_flushable(local_10,0xffffffff);
}
_ma_unpin_all_pages_and_finalize_row(local_10,local_70);
return local_39;
}
| |
38,043 | my_thread_destory_thr_mutex | eloqsql/mysys/my_thr_init.c | static void my_thread_destory_thr_mutex(struct st_my_thread_var *var)
{
mysql_mutex_destroy(&var->mutex);
mysql_cond_destroy(&var->suspend);
} | O3 | c | my_thread_destory_thr_mutex:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
leaq 0x40(%rdi), %r14
movq 0x80(%rdi), %rdi
testq %rdi, %rdi
je 0x6c4bf
leaq 0x2e1c6a(%rip), %rax # 0x34e118
movq (%rax), %rax
callq *0x48(%rax)
movq $0x0, 0x80(%rbx)
movq %r14, %rdi
callq 0x370e0
movq 0x38(%rbx), %rdi
testq %rdi, %rdi
jne 0x6c4e0
addq $0x8, %rbx
movq %rbx, %rdi
popq %rbx
popq %r14
popq %rbp
jmp 0x372c0
leaq 0x2e1c31(%rip), %rax # 0x34e118
movq (%rax), %rax
callq *0x68(%rax)
movq $0x0, 0x38(%rbx)
jmp 0x6c4d0
| my_thread_destory_thr_mutex:
push rbp
mov rbp, rsp
push r14
push rbx
mov rbx, rdi
lea r14, [rdi+40h]
mov rdi, [rdi+80h]
test rdi, rdi
jz short loc_6C4BF
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+48h]
mov qword ptr [rbx+80h], 0
loc_6C4BF:
mov rdi, r14
call _pthread_mutex_destroy
mov rdi, [rbx+38h]
test rdi, rdi
jnz short loc_6C4E0
loc_6C4D0:
add rbx, 8
mov rdi, rbx
pop rbx
pop r14
pop rbp
jmp _pthread_cond_destroy
loc_6C4E0:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+68h]
mov qword ptr [rbx+38h], 0
jmp short loc_6C4D0
| long long my_thread_destory_thr_mutex(long long a1)
{
if ( *(_QWORD *)(a1 + 128) )
{
(*((void (**)(void))PSI_server + 9))();
*(_QWORD *)(a1 + 128) = 0LL;
}
pthread_mutex_destroy(a1 + 64);
if ( *(_QWORD *)(a1 + 56) )
{
(*((void (**)(void))PSI_server + 13))();
*(_QWORD *)(a1 + 56) = 0LL;
}
return pthread_cond_destroy(a1 + 8);
}
| my_thread_destory_thr_mutex:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
MOV RBX,RDI
LEA R14,[RDI + 0x40]
MOV RDI,qword ptr [RDI + 0x80]
TEST RDI,RDI
JZ 0x0016c4bf
LEA RAX,[0x44e118]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x48]
MOV qword ptr [RBX + 0x80],0x0
LAB_0016c4bf:
MOV RDI,R14
CALL 0x001370e0
MOV RDI,qword ptr [RBX + 0x38]
TEST RDI,RDI
JNZ 0x0016c4e0
LAB_0016c4d0:
ADD RBX,0x8
MOV RDI,RBX
POP RBX
POP R14
POP RBP
JMP 0x001372c0
LAB_0016c4e0:
LEA RAX,[0x44e118]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x68]
MOV qword ptr [RBX + 0x38],0x0
JMP 0x0016c4d0
|
void my_thread_destory_thr_mutex(long param_1)
{
if (*(long *)(param_1 + 0x80) != 0) {
(**(code **)(PSI_server + 0x48))();
*(int8 *)(param_1 + 0x80) = 0;
}
pthread_mutex_destroy((pthread_mutex_t *)(param_1 + 0x40));
if (*(long *)(param_1 + 0x38) != 0) {
(**(code **)(PSI_server + 0x68))();
*(int8 *)(param_1 + 0x38) = 0;
}
pthread_cond_destroy((pthread_cond_t *)(param_1 + 8));
return;
}
| |
38,044 | updateCursorImage | untodesu[P]riteg/build_O3/_deps/glfw-src/src/x11_window.c | static void updateCursorImage(_GLFWwindow* window)
{
if (window->cursorMode == GLFW_CURSOR_NORMAL)
{
if (window->cursor)
{
XDefineCursor(_glfw.x11.display, window->x11.handle,
window->cursor->x11.handle);
}
else
XUndefineCursor(_glfw.x11.display, window->x11.handle);
}
else
{
XDefineCursor(_glfw.x11.display, window->x11.handle,
_glfw.x11.hiddenCursorHandle);
}
} | O3 | c | updateCursorImage:
cmpl $0x34001, 0x74(%rdi) # imm = 0x34001
jne 0x2534a
movq 0x48(%rdi), %rcx
leaq 0x8330d(%rip), %rax # 0xa8638
movq 0x1fec0(%rax), %rax
movq 0x348(%rdi), %rsi
testq %rcx, %rcx
je 0x2536b
movq 0x8(%rcx), %rdx
movq %rax, %rdi
jmp 0xcec0
leaq 0x832e7(%rip), %rax # 0xa8638
movq 0x348(%rdi), %rsi
movq 0x1fec0(%rax), %rdi
movq 0x1fee8(%rax), %rdx
jmp 0xcec0
movq %rax, %rdi
jmp 0xc2b0
| updateCursorImage:
cmp dword ptr [rdi+74h], 34001h
jnz short loc_2534A
mov rcx, [rdi+48h]
lea rax, _glfw
mov rax, [rax+1FEC0h]
mov rsi, [rdi+348h]
test rcx, rcx
jz short loc_2536B
mov rdx, [rcx+8]
mov rdi, rax
jmp _XDefineCursor
loc_2534A:
lea rax, _glfw
mov rsi, [rdi+348h]
mov rdi, [rax+1FEC0h]
mov rdx, [rax+1FEE8h]
jmp _XDefineCursor
loc_2536B:
mov rdi, rax
jmp _XUndefineCursor
| long long updateCursorImage(long long a1)
{
long long v1; // rcx
long long v2; // rsi
if ( *(_DWORD *)(a1 + 116) != 212993 )
return XDefineCursor(*(_QWORD *)&glfw[32688], *(_QWORD *)(a1 + 840), *(_QWORD *)&glfw[32698]);
v1 = *(_QWORD *)(a1 + 72);
v2 = *(_QWORD *)(a1 + 840);
if ( v1 )
return XDefineCursor(*(_QWORD *)&glfw[32688], v2, *(_QWORD *)(v1 + 8));
else
return XUndefineCursor(*(_QWORD *)&glfw[32688], v2);
}
| updateCursorImage:
CMP dword ptr [RDI + 0x74],0x34001
JNZ 0x0012534a
MOV RCX,qword ptr [RDI + 0x48]
LEA RAX,[0x1a8638]
MOV RAX,qword ptr [RAX + 0x1fec0]
MOV RSI,qword ptr [RDI + 0x348]
TEST RCX,RCX
JZ 0x0012536b
MOV RDX,qword ptr [RCX + 0x8]
MOV RDI,RAX
JMP 0x0010cec0
LAB_0012534a:
LEA RAX,[0x1a8638]
MOV RSI,qword ptr [RDI + 0x348]
MOV RDI,qword ptr [RAX + 0x1fec0]
MOV RDX,qword ptr [RAX + 0x1fee8]
JMP 0x0010cec0
LAB_0012536b:
MOV RDI,RAX
JMP 0x0010c2b0
|
void updateCursorImage(long param_1)
{
if (*(int *)(param_1 + 0x74) != 0x34001) {
XDefineCursor(DAT_001c84f8,*(int8 *)(param_1 + 0x348),DAT_001c8520);
return;
}
if (*(long *)(param_1 + 0x48) != 0) {
XDefineCursor(DAT_001c84f8,*(int8 *)(param_1 + 0x348),
*(int8 *)(*(long *)(param_1 + 0x48) + 8));
return;
}
XUndefineCursor(DAT_001c84f8,*(int8 *)(param_1 + 0x348));
return;
}
| |
38,045 | js_compile_regexp | bluesky950520[P]quickjs/quickjs.c | static JSValue js_compile_regexp(JSContext *ctx, JSValue pattern,
JSValue flags)
{
const char *str;
int re_flags, mask;
uint8_t *re_bytecode_buf;
size_t i, len;
int re_bytecode_len;
JSValue ret;
char error_msg[64];
re_flags = 0;
if (!JS_IsUndefined(flags)) {
str = JS_ToCStringLen(ctx, &len, flags);
if (!str)
return JS_EXCEPTION;
/* XXX: re_flags = LRE_FLAG_OCTAL unless strict mode? */
for (i = 0; i < len; i++) {
switch(str[i]) {
case 'd':
mask = LRE_FLAG_INDICES;
break;
case 'g':
mask = LRE_FLAG_GLOBAL;
break;
case 'i':
mask = LRE_FLAG_IGNORECASE;
break;
case 'm':
mask = LRE_FLAG_MULTILINE;
break;
case 's':
mask = LRE_FLAG_DOTALL;
break;
case 'u':
mask = LRE_FLAG_UNICODE;
break;
case 'v':
mask = LRE_FLAG_UNICODE_SETS;
break;
case 'y':
mask = LRE_FLAG_STICKY;
break;
default:
goto bad_flags;
}
if ((re_flags & mask) != 0) {
bad_flags:
JS_FreeCString(ctx, str);
return JS_ThrowSyntaxError(ctx, "invalid regular expression flags");
}
re_flags |= mask;
}
JS_FreeCString(ctx, str);
}
if (re_flags & LRE_FLAG_UNICODE)
if (re_flags & LRE_FLAG_UNICODE_SETS)
return JS_ThrowSyntaxError(ctx, "invalid regular expression flags");
str = JS_ToCStringLen2(ctx, &len, pattern, !(re_flags & LRE_FLAG_UNICODE));
if (!str)
return JS_EXCEPTION;
re_bytecode_buf = lre_compile(&re_bytecode_len, error_msg,
sizeof(error_msg), str, len, re_flags, ctx);
JS_FreeCString(ctx, str);
if (!re_bytecode_buf) {
JS_ThrowSyntaxError(ctx, "%s", error_msg);
return JS_EXCEPTION;
}
ret = js_new_string8_len(ctx, (char *)re_bytecode_buf, re_bytecode_len);
js_free(ctx, re_bytecode_buf);
return ret;
} | O1 | c | js_compile_regexp:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %rdx, %r12
movq %rsi, %r13
movq %rdi, %rbx
xorl %r15d, %r15d
cmpl $0x3, %r8d
jne 0x3299c
movl %r15d, %eax
notl %eax
testl $0x110, %eax # imm = 0x110
jne 0x32a9a
leaq 0x6ba28(%rip), %rsi # 0x9e3ac
xorl %r15d, %r15d
movq %rbx, %rdi
xorl %eax, %eax
callq 0x218bd
movl $0x6, %r14d
jmp 0x32bc9
leaq 0x10(%rsp), %rsi
xorl %r15d, %r15d
movq %rbx, %rdi
movq %rcx, %rdx
movq %r8, %rcx
xorl %r8d, %r8d
callq 0x1ffe3
movl $0x6, %r14d
testq %rax, %rax
je 0x32bc9
movq 0x10(%rsp), %rcx
testq %rcx, %rcx
je 0x32a6c
xorl %r15d, %r15d
leaq 0x687f4(%rip), %rdx # 0x9b1d0
leaq 0x687c5(%rip), %rsi # 0x9b1a8
xorl %edi, %edi
movzbl (%rax,%rdi), %r8d
leal -0x64(%r8), %r9d
cmpl $0x9, %r9d
jbe 0x32a14
addl $-0x73, %r8d
cmpl $0x6, %r8d
ja 0x32b75
movslq (%rdx,%r8,4), %r8
addq %rdx, %r8
jmpq *%r8
movl $0x8, %r8d
jmp 0x32a54
movslq (%rsi,%r9,4), %r8
addq %rsi, %r8
jmpq *%r8
movl $0x40, %r8d
jmp 0x32a54
movl $0x2, %r8d
jmp 0x32a54
movl $0x1, %r8d
jmp 0x32a54
movl $0x4, %r8d
jmp 0x32a54
movl $0x100, %r8d # imm = 0x100
jmp 0x32a54
movl $0x10, %r8d
jmp 0x32a54
movl $0x20, %r8d
testl %r15d, %r8d
jne 0x32b75
orl %r8d, %r15d
incq %rdi
cmpq %rdi, %rcx
jne 0x329e5
movq 0x18(%rbx), %rdi
movl -0x18(%rax), %ecx
leal -0x1(%rcx), %edx
movl %edx, -0x18(%rax)
cmpl $0x1, %ecx
jg 0x3296d
addq $-0x18, %rax
movq %rax, %rsi
movq $-0x7, %rdx
callq 0x20652
jmp 0x3296d
xorl %r8d, %r8d
testb $0x10, %r15b
sete %r8b
leaq 0x10(%rsp), %rsi
movq %rbx, %rdi
movq %r13, %rdx
movq %r12, %rcx
callq 0x1ffe3
movl $0x6, %r14d
testq %rax, %rax
je 0x32b70
movq %rax, %r12
movq 0x10(%rsp), %r8
movq %rbx, (%rsp)
leaq 0x1c(%rsp), %rdi
leaq 0x20(%rsp), %rsi
movl $0x40, %edx
movq %rax, %rcx
movl %r15d, %r9d
callq 0x93bed
movq %rax, %r15
movq 0x18(%rbx), %rdi
movl -0x18(%r12), %eax
leal -0x1(%rax), %ecx
movl %ecx, -0x18(%r12)
cmpl $0x1, %eax
jg 0x32b19
addq $-0x18, %r12
movq %r12, %rsi
movq $-0x7, %rdx
callq 0x20652
testq %r15, %r15
je 0x32bb0
movl 0x1c(%rsp), %edx
movq %rbx, %rdi
movq %r15, %rsi
callq 0x1f5c9
movq %rax, %r12
movq %rdx, %r14
movq 0x18(%rbx), %rbx
decq 0x28(%rbx)
movq %r15, %rdi
callq *0x20(%rbx)
movq 0x30(%rbx), %rcx
movq 0x40(%rbx), %rdi
subq %rax, %rcx
addq $-0x8, %rcx
movq %rcx, 0x30(%rbx)
movq %r15, %rsi
callq *0x10(%rbx)
movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000
andq %r12, %rax
movl %r12d, %r15d
jmp 0x32bcb
xorl %r15d, %r15d
jmp 0x32bc9
movq 0x18(%rbx), %rdi
movl -0x18(%rax), %ecx
leal -0x1(%rcx), %edx
movl %edx, -0x18(%rax)
cmpl $0x1, %ecx
jg 0x32b9a
addq $-0x18, %rax
movq %rax, %rsi
movq $-0x7, %rdx
callq 0x20652
leaq 0x6b80b(%rip), %rsi # 0x9e3ac
xorl %r15d, %r15d
movq %rbx, %rdi
xorl %eax, %eax
callq 0x218bd
jmp 0x32bc9
leaq 0x6d40f(%rip), %rsi # 0x9ffc6
xorl %r15d, %r15d
leaq 0x20(%rsp), %rdx
movq %rbx, %rdi
xorl %eax, %eax
callq 0x218bd
xorl %eax, %eax
orq %rax, %r15
movq %r15, %rax
movq %r14, %rdx
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
| js_compile_regexp:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 60h
mov r12, rdx
mov r13, rsi
mov rbx, rdi
xor r15d, r15d
cmp r8d, 3
jnz short loc_3299C
loc_3296D:
mov eax, r15d
not eax
test eax, 110h
jnz loc_32A9A
lea rsi, aInvalidRegular; "invalid regular expression flags"
xor r15d, r15d
mov rdi, rbx
xor eax, eax
call JS_ThrowSyntaxError
mov r14d, 6
jmp loc_32BC9
loc_3299C:
lea rsi, [rsp+88h+var_78]
xor r15d, r15d
mov rdi, rbx
mov rdx, rcx
mov rcx, r8
xor r8d, r8d
call JS_ToCStringLen2
mov r14d, 6
test rax, rax
jz loc_32BC9
mov rcx, [rsp+88h+var_78]
test rcx, rcx
jz loc_32A6C
xor r15d, r15d
lea rdx, jpt_32A09
lea rsi, jpt_32A1B
xor edi, edi
loc_329E5:
movzx r8d, byte ptr [rax+rdi]
lea r9d, [r8-64h]; switch 10 cases
cmp r9d, 9
jbe short loc_32A14
def_32A1B:
add r8d, 0FFFFFF8Dh; jumptable 0000000000032A1B default case
cmp r8d, 6
ja def_32A09; jumptable 0000000000032A09 default case, cases 116,119,120
movsxd r8, ds:(jpt_32A09 - 9B1D0h)[rdx+r8*4]
add r8, rdx
jmp r8; switch jump
loc_32A0C:
mov r8d, 8; jumptable 0000000000032A09 case 115
jmp short loc_32A54
loc_32A14:
movsxd r8, ds:(jpt_32A1B - 9B1A8h)[rsi+r9*4]
add r8, rsi
jmp r8; switch jump
loc_32A1E:
mov r8d, 40h ; '@'; jumptable 0000000000032A1B case 100
jmp short loc_32A54
loc_32A26:
mov r8d, 2; jumptable 0000000000032A1B case 105
jmp short loc_32A54
loc_32A2E:
mov r8d, 1; jumptable 0000000000032A1B case 103
jmp short loc_32A54
loc_32A36:
mov r8d, 4; jumptable 0000000000032A1B case 109
jmp short loc_32A54
loc_32A3E:
mov r8d, 100h; jumptable 0000000000032A09 case 118
jmp short loc_32A54
loc_32A46:
mov r8d, 10h; jumptable 0000000000032A09 case 117
jmp short loc_32A54
loc_32A4E:
mov r8d, 20h ; ' '; jumptable 0000000000032A09 case 121
loc_32A54:
test r8d, r15d
jnz def_32A09; jumptable 0000000000032A09 default case, cases 116,119,120
or r15d, r8d
inc rdi
cmp rcx, rdi
jnz loc_329E5
loc_32A6C:
mov rdi, [rbx+18h]
mov ecx, [rax-18h]
lea edx, [rcx-1]
mov [rax-18h], edx
cmp ecx, 1
jg loc_3296D
add rax, 0FFFFFFFFFFFFFFE8h
mov rsi, rax
mov rdx, 0FFFFFFFFFFFFFFF9h
call js_free_value_rt
jmp loc_3296D
loc_32A9A:
xor r8d, r8d
test r15b, 10h
setz r8b
lea rsi, [rsp+88h+var_78]
mov rdi, rbx
mov rdx, r13
mov rcx, r12
call JS_ToCStringLen2
mov r14d, 6
test rax, rax
jz loc_32B70
mov r12, rax
mov r8, [rsp+88h+var_78]
mov [rsp+88h+var_88], rbx
lea rdi, [rsp+88h+var_6C]
lea rsi, [rsp+88h+var_68]
mov edx, 40h ; '@'
mov rcx, rax
mov r9d, r15d
call lre_compile
mov r15, rax
mov rdi, [rbx+18h]
mov eax, [r12-18h]
lea ecx, [rax-1]
mov [r12-18h], ecx
cmp eax, 1
jg short loc_32B19
add r12, 0FFFFFFFFFFFFFFE8h
mov rsi, r12
mov rdx, 0FFFFFFFFFFFFFFF9h
call js_free_value_rt
loc_32B19:
test r15, r15
jz loc_32BB0
mov edx, [rsp+88h+var_6C]
mov rdi, rbx
mov rsi, r15
call js_new_string8_len
mov r12, rax
mov r14, rdx
mov rbx, [rbx+18h]
dec qword ptr [rbx+28h]
mov rdi, r15
call qword ptr [rbx+20h]
mov rcx, [rbx+30h]
mov rdi, [rbx+40h]
sub rcx, rax
add rcx, 0FFFFFFFFFFFFFFF8h
mov [rbx+30h], rcx
mov rsi, r15
call qword ptr [rbx+10h]
mov rax, 0FFFFFFFF00000000h
and rax, r12
mov r15d, r12d
jmp short loc_32BCB
loc_32B70:
xor r15d, r15d
jmp short loc_32BC9
def_32A09:
mov rdi, [rbx+18h]; jumptable 0000000000032A09 default case, cases 116,119,120
mov ecx, [rax-18h]
lea edx, [rcx-1]
mov [rax-18h], edx
cmp ecx, 1
jg short loc_32B9A
add rax, 0FFFFFFFFFFFFFFE8h
mov rsi, rax
mov rdx, 0FFFFFFFFFFFFFFF9h
call js_free_value_rt
loc_32B9A:
lea rsi, aInvalidRegular; "invalid regular expression flags"
xor r15d, r15d
mov rdi, rbx
xor eax, eax
call JS_ThrowSyntaxError
jmp short loc_32BC9
loc_32BB0:
lea rsi, aUnsupportedKey+15h; "%s"
xor r15d, r15d
lea rdx, [rsp+88h+var_68]
mov rdi, rbx
xor eax, eax
call JS_ThrowSyntaxError
loc_32BC9:
xor eax, eax
loc_32BCB:
or r15, rax
mov rax, r15
mov rdx, r14
add rsp, 60h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
| unsigned long long js_compile_regexp(
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)
{
long long v14; // r12
long long v16; // r15
long long v17; // rax
long long v18; // rdi
long long v19; // rdi
long long v20; // rax
long long v21; // r12
long long v22; // r8
long long v23; // r9
long long v24; // r15
__m128 v25; // xmm4
__m128 v26; // xmm5
long long v27; // rdi
int v28; // eax
long long v29; // rcx
long long v30; // r12
long long v31; // rbx
long long v32; // rax
long long v33; // rdi
unsigned long long v34; // rax
long long v35; // rdi
char v37; // [rsp+0h] [rbp-88h]
char v38; // [rsp+0h] [rbp-88h]
long long v39; // [rsp+10h] [rbp-78h] BYREF
unsigned int v40; // [rsp+1Ch] [rbp-6Ch] BYREF
_BYTE v41[104]; // [rsp+20h] [rbp-68h] BYREF
v14 = a3;
LODWORD(v16) = 0;
if ( (_DWORD)a5 != 3 )
{
v16 = 0LL;
v17 = JS_ToCStringLen2(a1, &v39, a4, a5, 0);
if ( !v17 )
goto LABEL_32;
if ( v39 )
{
LODWORD(v16) = 0;
v18 = 0LL;
while ( 1 )
{
a5 = *(unsigned __int8 *)(v17 + v18);
a6 = (unsigned int)(a5 - 100);
switch ( *(_BYTE *)(v17 + v18) )
{
case 'd':
a5 = 64LL;
goto LABEL_18;
case 'e':
case 'f':
case 'h':
case 'j':
case 'k':
case 'l':
goto LABEL_28;
case 'g':
a5 = 1LL;
goto LABEL_18;
case 'i':
a5 = 2LL;
goto LABEL_18;
case 'm':
a5 = 4LL;
LABEL_18:
if ( ((unsigned int)v16 & (unsigned int)a5) != 0 )
{
LABEL_28:
v35 = *(_QWORD *)(a1 + 24);
a4 = *(unsigned int *)(v17 - 24);
a3 = (unsigned int)(a4 - 1);
*(_DWORD *)(v17 - 24) = a3;
if ( (int)a4 <= 1 )
js_free_value_rt(v35, (_QWORD *)(v17 - 24), -7LL, a4, a5, a6);
LABEL_3:
v16 = 0LL;
JS_ThrowSyntaxError(
a1,
(long long)"invalid regular expression flags",
a3,
a4,
a5,
a6,
a7,
a8,
a9,
a10,
a11,
a12,
a13,
a14,
v37);
LABEL_32:
v34 = 0LL;
return v34 | v16;
}
LODWORD(v16) = a5 | v16;
if ( v39 == ++v18 )
goto LABEL_20;
break;
default:
a5 = (unsigned int)(a5 - 115);
switch ( (int)a5 )
{
case 0:
a5 = 8LL;
goto LABEL_18;
case 2:
a5 = 16LL;
goto LABEL_18;
case 3:
a5 = 256LL;
goto LABEL_18;
case 6:
a5 = 32LL;
goto LABEL_18;
default:
goto LABEL_28;
}
}
}
}
LABEL_20:
v19 = *(_QWORD *)(a1 + 24);
a4 = *(unsigned int *)(v17 - 24);
a3 = (unsigned int)(a4 - 1);
*(_DWORD *)(v17 - 24) = a3;
if ( (int)a4 <= 1 )
js_free_value_rt(v19, (_QWORD *)(v17 - 24), -7LL, a4, a5, a6);
}
if ( (~(_WORD)v16 & 0x110) == 0 )
goto LABEL_3;
v20 = JS_ToCStringLen2(a1, &v39, a2, v14, (v16 & 0x10) == 0);
if ( !v20 )
{
v16 = 0LL;
goto LABEL_32;
}
v21 = v20;
v24 = lre_compile((unsigned int)&v40, (unsigned int)v41, 64, v20, v39, v16, a1);
v27 = *(_QWORD *)(a1 + 24);
v28 = *(_DWORD *)(v21 - 24);
v29 = (unsigned int)(v28 - 1);
*(_DWORD *)(v21 - 24) = v29;
if ( v28 <= 1 )
js_free_value_rt(v27, (_QWORD *)(v21 - 24), -7LL, v29, v22, v23);
if ( !v24 )
{
v16 = 0LL;
JS_ThrowSyntaxError(a1, (long long)"%s", (long long)v41, v29, v22, v23, a7, a8, a9, a10, v25, v26, a13, a14, v38);
goto LABEL_32;
}
v30 = js_new_string8_len(a1, v24, v40);
v31 = *(_QWORD *)(a1 + 24);
--*(_QWORD *)(v31 + 40);
v32 = (*(long long ( **)(long long))(v31 + 32))(v24);
v33 = *(_QWORD *)(v31 + 64);
*(_QWORD *)(v31 + 48) = *(_QWORD *)(v31 + 48) - v32 - 8;
(*(void ( **)(long long, long long))(v31 + 16))(v33, v24);
v34 = v30 & 0xFFFFFFFF00000000LL;
v16 = (unsigned int)v30;
return v34 | v16;
}
| js_compile_regexp:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x60
MOV R12,RDX
MOV R13,RSI
MOV RBX,RDI
XOR R15D,R15D
CMP R8D,0x3
JNZ 0x0013299c
LAB_0013296d:
MOV EAX,R15D
NOT EAX
TEST EAX,0x110
JNZ 0x00132a9a
LEA RSI,[0x19e3ac]
XOR R15D,R15D
MOV RDI,RBX
XOR EAX,EAX
CALL 0x001218bd
MOV R14D,0x6
JMP 0x00132bc9
LAB_0013299c:
LEA RSI,[RSP + 0x10]
XOR R15D,R15D
MOV RDI,RBX
MOV RDX,RCX
MOV RCX,R8
XOR R8D,R8D
CALL 0x0011ffe3
MOV R14D,0x6
TEST RAX,RAX
JZ 0x00132bc9
MOV RCX,qword ptr [RSP + 0x10]
TEST RCX,RCX
JZ 0x00132a6c
XOR R15D,R15D
LEA RDX,[0x19b1d0]
LEA RSI,[0x19b1a8]
XOR EDI,EDI
LAB_001329e5:
MOVZX R8D,byte ptr [RAX + RDI*0x1]
LEA R9D,[R8 + -0x64]
CMP R9D,0x9
JBE 0x00132a14
default:
ADD R8D,-0x73
CMP R8D,0x6
JA 0x00132b75
MOVSXD R8,dword ptr [RDX + R8*0x4]
ADD R8,RDX
switchD:
JMP R8
caseD_73:
MOV R8D,0x8
JMP 0x00132a54
LAB_00132a14:
MOVSXD R8,dword ptr [RSI + R9*0x4]
ADD R8,RSI
switchD:
JMP R8
caseD_64:
MOV R8D,0x40
JMP 0x00132a54
caseD_69:
MOV R8D,0x2
JMP 0x00132a54
caseD_67:
MOV R8D,0x1
JMP 0x00132a54
caseD_6d:
MOV R8D,0x4
JMP 0x00132a54
caseD_76:
MOV R8D,0x100
JMP 0x00132a54
caseD_75:
MOV R8D,0x10
JMP 0x00132a54
caseD_79:
MOV R8D,0x20
LAB_00132a54:
TEST R8D,R15D
JNZ 0x00132b75
OR R15D,R8D
INC RDI
CMP RCX,RDI
JNZ 0x001329e5
LAB_00132a6c:
MOV RDI,qword ptr [RBX + 0x18]
MOV ECX,dword ptr [RAX + -0x18]
LEA EDX,[RCX + -0x1]
MOV dword ptr [RAX + -0x18],EDX
CMP ECX,0x1
JG 0x0013296d
ADD RAX,-0x18
MOV RSI,RAX
MOV RDX,-0x7
CALL 0x00120652
JMP 0x0013296d
LAB_00132a9a:
XOR R8D,R8D
TEST R15B,0x10
SETZ R8B
LEA RSI,[RSP + 0x10]
MOV RDI,RBX
MOV RDX,R13
MOV RCX,R12
CALL 0x0011ffe3
MOV R14D,0x6
TEST RAX,RAX
JZ 0x00132b70
MOV R12,RAX
MOV R8,qword ptr [RSP + 0x10]
MOV qword ptr [RSP],RBX
LEA RDI,[RSP + 0x1c]
LEA RSI,[RSP + 0x20]
MOV EDX,0x40
MOV RCX,RAX
MOV R9D,R15D
CALL 0x00193bed
MOV R15,RAX
MOV RDI,qword ptr [RBX + 0x18]
MOV EAX,dword ptr [R12 + -0x18]
LEA ECX,[RAX + -0x1]
MOV dword ptr [R12 + -0x18],ECX
CMP EAX,0x1
JG 0x00132b19
ADD R12,-0x18
MOV RSI,R12
MOV RDX,-0x7
CALL 0x00120652
LAB_00132b19:
TEST R15,R15
JZ 0x00132bb0
MOV EDX,dword ptr [RSP + 0x1c]
MOV RDI,RBX
MOV RSI,R15
CALL 0x0011f5c9
MOV R12,RAX
MOV R14,RDX
MOV RBX,qword ptr [RBX + 0x18]
DEC qword ptr [RBX + 0x28]
MOV RDI,R15
CALL qword ptr [RBX + 0x20]
MOV RCX,qword ptr [RBX + 0x30]
MOV RDI,qword ptr [RBX + 0x40]
SUB RCX,RAX
ADD RCX,-0x8
MOV qword ptr [RBX + 0x30],RCX
MOV RSI,R15
CALL qword ptr [RBX + 0x10]
MOV RAX,-0x100000000
AND RAX,R12
MOV R15D,R12D
JMP 0x00132bcb
LAB_00132b70:
XOR R15D,R15D
JMP 0x00132bc9
caseD_74:
MOV RDI,qword ptr [RBX + 0x18]
MOV ECX,dword ptr [RAX + -0x18]
LEA EDX,[RCX + -0x1]
MOV dword ptr [RAX + -0x18],EDX
CMP ECX,0x1
JG 0x00132b9a
ADD RAX,-0x18
MOV RSI,RAX
MOV RDX,-0x7
CALL 0x00120652
LAB_00132b9a:
LEA RSI,[0x19e3ac]
XOR R15D,R15D
MOV RDI,RBX
XOR EAX,EAX
CALL 0x001218bd
JMP 0x00132bc9
LAB_00132bb0:
LEA RSI,[0x19ffc6]
XOR R15D,R15D
LEA RDX,[RSP + 0x20]
MOV RDI,RBX
XOR EAX,EAX
CALL 0x001218bd
LAB_00132bc9:
XOR EAX,EAX
LAB_00132bcb:
OR R15,RAX
MOV RAX,R15
MOV RDX,R14
ADD RSP,0x60
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
int1 [16]
js_compile_regexp(long param_1,int8 param_2,int8 param_3,int8 param_4,
int8 param_5)
{
int iVar1;
long lVar2;
long lVar3;
long lVar4;
ulong uVar5;
uint uVar6;
int8 uVar7;
uint uVar8;
ulong uVar9;
int1 auVar10 [16];
long local_78;
int4 local_6c;
int1 local_68 [64];
uVar8 = 0;
if ((int)param_5 == 3) {
LAB_0013296d:
if ((~uVar8 & 0x110) == 0) {
JS_ThrowSyntaxError(param_1,"invalid regular expression flags");
}
else {
lVar2 = JS_ToCStringLen2(param_1,&local_78,param_2,param_3,(uVar8 & 0x10) == 0);
if (lVar2 != 0) {
lVar3 = lre_compile(&local_6c,local_68,0x40,lVar2,local_78,uVar8,param_1);
uVar7 = *(int8 *)(param_1 + 0x18);
iVar1 = *(int *)(lVar2 + -0x18);
*(int *)(lVar2 + -0x18) = iVar1 + -1;
if (iVar1 < 2) {
js_free_value_rt(uVar7,lVar2 + -0x18,0xfffffffffffffff9);
}
if (lVar3 != 0) {
auVar10 = js_new_string8_len(param_1,lVar3,local_6c);
uVar7 = auVar10._8_8_;
lVar2 = *(long *)(param_1 + 0x18);
*(long *)(lVar2 + 0x28) = *(long *)(lVar2 + 0x28) + -1;
lVar4 = (**(code **)(lVar2 + 0x20))(lVar3);
*(long *)(lVar2 + 0x30) = (*(long *)(lVar2 + 0x30) - lVar4) + -8;
(**(code **)(lVar2 + 0x10))(*(int8 *)(lVar2 + 0x40),lVar3);
uVar5 = auVar10._0_8_ & 0xffffffff00000000;
uVar9 = auVar10._0_8_ & 0xffffffff;
goto LAB_00132bcb;
}
JS_ThrowSyntaxError(param_1,"%s",local_68);
}
}
}
else {
uVar8 = 0;
lVar2 = JS_ToCStringLen2(param_1,&local_78,param_4,param_5,0);
if (lVar2 != 0) {
if (local_78 != 0) {
uVar8 = 0;
lVar3 = 0;
do {
switch(*(int1 *)(lVar2 + lVar3)) {
case 100:
uVar6 = 0x40;
break;
case 0x65:
case 0x66:
case 0x68:
case 0x6a:
case 0x6b:
case 0x6c:
goto switchD_00132a09_caseD_74;
case 0x67:
uVar6 = 1;
break;
case 0x69:
uVar6 = 2;
break;
case 0x6d:
uVar6 = 4;
break;
default:
switch(*(int1 *)(lVar2 + lVar3)) {
case 0x73:
uVar6 = 8;
break;
default:
goto switchD_00132a09_caseD_74;
case 0x75:
uVar6 = 0x10;
break;
case 0x76:
uVar6 = 0x100;
break;
case 0x79:
uVar6 = 0x20;
}
}
if ((uVar6 & uVar8) != 0) {
switchD_00132a09_caseD_74:
uVar7 = *(int8 *)(param_1 + 0x18);
iVar1 = *(int *)(lVar2 + -0x18);
*(int *)(lVar2 + -0x18) = iVar1 + -1;
if (iVar1 < 2) {
js_free_value_rt(uVar7,lVar2 + -0x18,0xfffffffffffffff9);
}
JS_ThrowSyntaxError(param_1,"invalid regular expression flags");
goto LAB_00132bc9;
}
uVar8 = uVar8 | uVar6;
lVar3 = lVar3 + 1;
} while (local_78 != lVar3);
}
uVar7 = *(int8 *)(param_1 + 0x18);
iVar1 = *(int *)(lVar2 + -0x18);
*(int *)(lVar2 + -0x18) = iVar1 + -1;
if (iVar1 < 2) {
js_free_value_rt(uVar7,lVar2 + -0x18,0xfffffffffffffff9);
}
goto LAB_0013296d;
}
}
LAB_00132bc9:
uVar9 = 0;
uVar7 = 6;
uVar5 = 0;
LAB_00132bcb:
auVar10._8_8_ = uVar7;
auVar10._0_8_ = uVar9 | uVar5;
return auVar10;
}
| |
38,046 | js_compile_regexp | bluesky950520[P]quickjs/quickjs.c | static JSValue js_compile_regexp(JSContext *ctx, JSValue pattern,
JSValue flags)
{
const char *str;
int re_flags, mask;
uint8_t *re_bytecode_buf;
size_t i, len;
int re_bytecode_len;
JSValue ret;
char error_msg[64];
re_flags = 0;
if (!JS_IsUndefined(flags)) {
str = JS_ToCStringLen(ctx, &len, flags);
if (!str)
return JS_EXCEPTION;
/* XXX: re_flags = LRE_FLAG_OCTAL unless strict mode? */
for (i = 0; i < len; i++) {
switch(str[i]) {
case 'd':
mask = LRE_FLAG_INDICES;
break;
case 'g':
mask = LRE_FLAG_GLOBAL;
break;
case 'i':
mask = LRE_FLAG_IGNORECASE;
break;
case 'm':
mask = LRE_FLAG_MULTILINE;
break;
case 's':
mask = LRE_FLAG_DOTALL;
break;
case 'u':
mask = LRE_FLAG_UNICODE;
break;
case 'v':
mask = LRE_FLAG_UNICODE_SETS;
break;
case 'y':
mask = LRE_FLAG_STICKY;
break;
default:
goto bad_flags;
}
if ((re_flags & mask) != 0) {
bad_flags:
JS_FreeCString(ctx, str);
return JS_ThrowSyntaxError(ctx, "invalid regular expression flags");
}
re_flags |= mask;
}
JS_FreeCString(ctx, str);
}
if (re_flags & LRE_FLAG_UNICODE)
if (re_flags & LRE_FLAG_UNICODE_SETS)
return JS_ThrowSyntaxError(ctx, "invalid regular expression flags");
str = JS_ToCStringLen2(ctx, &len, pattern, !(re_flags & LRE_FLAG_UNICODE));
if (!str)
return JS_EXCEPTION;
re_bytecode_buf = lre_compile(&re_bytecode_len, error_msg,
sizeof(error_msg), str, len, re_flags, ctx);
JS_FreeCString(ctx, str);
if (!re_bytecode_buf) {
JS_ThrowSyntaxError(ctx, "%s", error_msg);
return JS_EXCEPTION;
}
ret = js_new_string8_len(ctx, (char *)re_bytecode_buf, re_bytecode_len);
js_free(ctx, re_bytecode_buf);
return ret;
} | O3 | c | js_compile_regexp:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x60, %rsp
movq %r8, %rax
movq %rdx, %r12
movq %rsi, %r13
movq %rdi, %r14
xorl %r8d, %r8d
movl $0x0, %r15d
cmpl $0x3, %eax
jne 0x33875
shrl $0x4, %r8d
xorl $0x1, %r8d
leaq 0x10(%rsp), %rsi
movq %r14, %rdi
movq %r13, %rdx
movq %r12, %rcx
callq 0x20717
movl $0x6, %ebx
testq %rax, %rax
je 0x33979
movq %rax, %r12
movq 0x10(%rsp), %r8
movq %r14, (%rsp)
leaq 0x1c(%rsp), %rdi
leaq 0x20(%rsp), %rsi
movl $0x40, %edx
movq %rax, %rcx
movl %r15d, %r9d
callq 0x966c6
movq %rax, %r15
movq 0x18(%r14), %rdi
movl -0x18(%r12), %eax
leal -0x1(%rax), %ecx
movl %ecx, -0x18(%r12)
cmpl $0x1, %eax
jg 0x33819
addq $-0x18, %r12
movq %r12, %rsi
movq $-0x7, %rdx
callq 0x20d90
testq %r15, %r15
je 0x3397e
movl 0x1c(%rsp), %edx
movq %r14, %rdi
movq %r15, %rsi
callq 0x1fcd9
movq %rax, %r12
movq %rdx, %rbx
movq 0x18(%r14), %r14
decq 0x28(%r14)
movq %r15, %rdi
callq *0x20(%r14)
movq 0x30(%r14), %rcx
movq 0x40(%r14), %rdi
subq %rax, %rcx
addq $-0x8, %rcx
movq %rcx, 0x30(%r14)
movq %r15, %rsi
callq *0x10(%r14)
movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000
andq %r12, %rax
movl %r12d, %r15d
jmp 0x339d4
leaq 0x10(%rsp), %rsi
xorl %r15d, %r15d
movq %r14, %rdi
movq %rcx, %rdx
movq %rax, %rcx
xorl %r8d, %r8d
callq 0x20717
movl $0x6, %ebx
testq %rax, %rax
je 0x339d2
movq 0x10(%rsp), %rcx
testq %rcx, %rcx
je 0x3393c
xorl %r15d, %r15d
leaq 0x6a8ec(%rip), %rdx # 0x9e1a0
leaq 0x6a8bd(%rip), %rsi # 0x9e178
xorl %edi, %edi
movzbl (%rax,%rdi), %r8d
leal -0x64(%r8), %r9d
cmpl $0x9, %r9d
jbe 0x338ec
addl $-0x73, %r8d
cmpl $0x6, %r8d
ja 0x33999
movslq (%rdx,%r8,4), %r8
addq %rdx, %r8
jmpq *%r8
movl $0x8, %r8d
jmp 0x3392c
movslq (%rsi,%r9,4), %r8
addq %rsi, %r8
jmpq *%r8
movl $0x40, %r8d
jmp 0x3392c
movl $0x2, %r8d
jmp 0x3392c
movl $0x1, %r8d
jmp 0x3392c
movl $0x4, %r8d
jmp 0x3392c
movl $0x100, %r8d # imm = 0x100
jmp 0x3392c
movl $0x10, %r8d
jmp 0x3392c
movl $0x20, %r8d
testl %r15d, %r8d
jne 0x33999
orl %r8d, %r15d
incq %rdi
cmpq %rdi, %rcx
jne 0x338bd
movq 0x18(%r14), %rdi
movl -0x18(%rax), %ecx
leal -0x1(%rcx), %edx
movl %edx, -0x18(%rax)
cmpl $0x1, %ecx
jg 0x33961
addq $-0x18, %rax
movq %rax, %rsi
movq $-0x7, %rdx
callq 0x20d90
movl %r15d, %eax
notl %eax
testl $0x110, %eax # imm = 0x110
je 0x339be
movl %r15d, %r8d
andl $0x10, %r8d
jmp 0x3379e
xorl %r15d, %r15d
jmp 0x339d2
leaq 0x6f5fb(%rip), %rsi # 0xa2f80
xorl %r15d, %r15d
leaq 0x20(%rsp), %rdx
movq %r14, %rdi
xorl %eax, %eax
callq 0x220b9
jmp 0x339d2
movq 0x18(%r14), %rdi
movl -0x18(%rax), %ecx
leal -0x1(%rcx), %edx
movl %edx, -0x18(%rax)
cmpl $0x1, %ecx
jg 0x339be
addq $-0x18, %rax
movq %rax, %rsi
movq $-0x7, %rdx
callq 0x20d90
leaq 0x6d9b7(%rip), %rsi # 0xa137c
xorl %r15d, %r15d
movq %r14, %rdi
xorl %eax, %eax
callq 0x220b9
xorl %eax, %eax
orq %rax, %r15
movq %r15, %rax
movq %rbx, %rdx
addq $0x60, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
| js_compile_regexp:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 60h
mov rax, r8
mov r12, rdx
mov r13, rsi
mov r14, rdi
xor r8d, r8d
mov r15d, 0
cmp eax, 3
jnz loc_33875
loc_3379E:
shr r8d, 4
xor r8d, 1
lea rsi, [rsp+88h+var_78]
mov rdi, r14
mov rdx, r13
mov rcx, r12
call JS_ToCStringLen2
mov ebx, 6
test rax, rax
jz loc_33979
mov r12, rax
mov r8, [rsp+88h+var_78]
mov [rsp+88h+var_88], r14
lea rdi, [rsp+88h+var_6C]
lea rsi, [rsp+88h+var_68]
mov edx, 40h ; '@'
mov rcx, rax
mov r9d, r15d
call lre_compile
mov r15, rax
mov rdi, [r14+18h]
mov eax, [r12-18h]
lea ecx, [rax-1]
mov [r12-18h], ecx
cmp eax, 1
jg short loc_33819
add r12, 0FFFFFFFFFFFFFFE8h
mov rsi, r12
mov rdx, 0FFFFFFFFFFFFFFF9h
call js_free_value_rt
loc_33819:
test r15, r15
jz loc_3397E
mov edx, [rsp+88h+var_6C]
mov rdi, r14
mov rsi, r15
call js_new_string8_len
mov r12, rax
mov rbx, rdx
mov r14, [r14+18h]
dec qword ptr [r14+28h]
mov rdi, r15
call qword ptr [r14+20h]
mov rcx, [r14+30h]
mov rdi, [r14+40h]
sub rcx, rax
add rcx, 0FFFFFFFFFFFFFFF8h
mov [r14+30h], rcx
mov rsi, r15
call qword ptr [r14+10h]
mov rax, 0FFFFFFFF00000000h
and rax, r12
mov r15d, r12d
jmp loc_339D4
loc_33875:
lea rsi, [rsp+88h+var_78]
xor r15d, r15d
mov rdi, r14
mov rdx, rcx
mov rcx, rax
xor r8d, r8d
call JS_ToCStringLen2
mov ebx, 6
test rax, rax
jz loc_339D2
mov rcx, [rsp+88h+var_78]
test rcx, rcx
jz loc_3393C
xor r15d, r15d
lea rdx, jpt_338E1
lea rsi, jpt_338F3
xor edi, edi
loc_338BD:
movzx r8d, byte ptr [rax+rdi]
lea r9d, [r8-64h]; switch 10 cases
cmp r9d, 9
jbe short loc_338EC
def_338F3:
add r8d, 0FFFFFF8Dh; jumptable 00000000000338F3 default case
cmp r8d, 6
ja def_338E1; jumptable 00000000000338E1 default case, cases 116,119,120
movsxd r8, ds:(jpt_338E1 - 9E1A0h)[rdx+r8*4]
add r8, rdx
jmp r8; switch jump
loc_338E4:
mov r8d, 8; jumptable 00000000000338E1 case 115
jmp short loc_3392C
loc_338EC:
movsxd r8, ds:(jpt_338F3 - 9E178h)[rsi+r9*4]
add r8, rsi
jmp r8; switch jump
loc_338F6:
mov r8d, 40h ; '@'; jumptable 00000000000338F3 case 100
jmp short loc_3392C
loc_338FE:
mov r8d, 2; jumptable 00000000000338F3 case 105
jmp short loc_3392C
loc_33906:
mov r8d, 1; jumptable 00000000000338F3 case 103
jmp short loc_3392C
loc_3390E:
mov r8d, 4; jumptable 00000000000338F3 case 109
jmp short loc_3392C
loc_33916:
mov r8d, 100h; jumptable 00000000000338E1 case 118
jmp short loc_3392C
loc_3391E:
mov r8d, 10h; jumptable 00000000000338E1 case 117
jmp short loc_3392C
loc_33926:
mov r8d, 20h ; ' '; jumptable 00000000000338E1 case 121
loc_3392C:
test r8d, r15d
jnz short def_338E1; jumptable 00000000000338E1 default case, cases 116,119,120
or r15d, r8d
inc rdi
cmp rcx, rdi
jnz short loc_338BD
loc_3393C:
mov rdi, [r14+18h]
mov ecx, [rax-18h]
lea edx, [rcx-1]
mov [rax-18h], edx
cmp ecx, 1
jg short loc_33961
add rax, 0FFFFFFFFFFFFFFE8h
mov rsi, rax
mov rdx, 0FFFFFFFFFFFFFFF9h
call js_free_value_rt
loc_33961:
mov eax, r15d
not eax
test eax, 110h
jz short loc_339BE
mov r8d, r15d
and r8d, 10h
jmp loc_3379E
loc_33979:
xor r15d, r15d
jmp short loc_339D2
loc_3397E:
lea rsi, aUnsupportedKey+15h; "%s"
xor r15d, r15d
lea rdx, [rsp+88h+var_68]
mov rdi, r14
xor eax, eax
call JS_ThrowSyntaxError
jmp short loc_339D2
def_338E1:
mov rdi, [r14+18h]; jumptable 00000000000338E1 default case, cases 116,119,120
mov ecx, [rax-18h]
lea edx, [rcx-1]
mov [rax-18h], edx
cmp ecx, 1
jg short loc_339BE
add rax, 0FFFFFFFFFFFFFFE8h
mov rsi, rax
mov rdx, 0FFFFFFFFFFFFFFF9h
call js_free_value_rt
loc_339BE:
lea rsi, aInvalidRegular; "invalid regular expression flags"
xor r15d, r15d
mov rdi, r14
xor eax, eax
call JS_ThrowSyntaxError
loc_339D2:
xor eax, eax
loc_339D4:
or r15, rax
mov rax, r15
mov rdx, rbx
add rsp, 60h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
| unsigned long long js_compile_regexp(
long long a1,
_DWORD *a2,
long long a3,
_DWORD *a4,
long long a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
double a10,
double a11,
__m128 a12,
__m128 a13)
{
unsigned int v16; // r8d
long long v17; // r15
int *v18; // rax
int *v19; // r12
long long v20; // r8
long long v21; // r9
long long v22; // r15
__m128 v23; // xmm4
__m128 v24; // xmm5
long long v25; // rdi
int v26; // eax
long long v27; // rcx
long long v28; // r12
long long v29; // r14
long long v30; // rax
long long v31; // rdi
unsigned long long v32; // rax
int *v33; // rax
long long v34; // r8
long long v35; // r9
__m128 v36; // xmm4
__m128 v37; // xmm5
long long v38; // rdi
long long v39; // rdi
long long v40; // rcx
long long v41; // rdx
long long v42; // rdi
char v44; // [rsp+0h] [rbp-88h]
char v45; // [rsp+0h] [rbp-88h]
long long v46; // [rsp+10h] [rbp-78h] BYREF
int v47; // [rsp+1Ch] [rbp-6Ch] BYREF
_BYTE v48[104]; // [rsp+20h] [rbp-68h] BYREF
v16 = 0;
LODWORD(v17) = 0;
if ( (_DWORD)a5 != 3 )
{
v17 = 0LL;
v33 = JS_ToCStringLen2(a1, &v46, a4, a5, 0);
if ( !v33 )
goto LABEL_32;
if ( v46 )
{
LODWORD(v17) = 0;
v38 = 0LL;
while ( 1 )
{
v34 = *((unsigned __int8 *)v33 + v38);
v35 = (unsigned int)(v34 - 100);
switch ( *((_BYTE *)v33 + v38) )
{
case 'd':
v34 = 64LL;
goto LABEL_21;
case 'e':
case 'f':
case 'h':
case 'j':
case 'k':
case 'l':
goto LABEL_29;
case 'g':
v34 = 1LL;
goto LABEL_21;
case 'i':
v34 = 2LL;
goto LABEL_21;
case 'm':
v34 = 4LL;
LABEL_21:
if ( ((unsigned int)v17 & (unsigned int)v34) != 0 )
{
LABEL_29:
v42 = *(_QWORD *)(a1 + 24);
v40 = (unsigned int)*(v33 - 6);
v41 = (unsigned int)(v40 - 1);
*(v33 - 6) = v41;
if ( (int)v40 <= 1 )
js_free_value_rt(v42, (_QWORD *)v33 - 3, -7LL, v40, v34, v35);
LABEL_31:
v17 = 0LL;
JS_ThrowSyntaxError(
a1,
(long long)"invalid regular expression flags",
v41,
v40,
v34,
v35,
a6,
a7,
a8,
a9,
v36,
v37,
a12,
a13,
v44);
LABEL_32:
v32 = 0LL;
return v32 | v17;
}
LODWORD(v17) = v34 | v17;
if ( v46 == ++v38 )
goto LABEL_23;
break;
default:
v34 = (unsigned int)(v34 - 115);
switch ( (int)v34 )
{
case 0:
v34 = 8LL;
goto LABEL_21;
case 2:
v34 = 16LL;
goto LABEL_21;
case 3:
v34 = 256LL;
goto LABEL_21;
case 6:
v34 = 32LL;
goto LABEL_21;
default:
goto LABEL_29;
}
}
}
}
LABEL_23:
v39 = *(_QWORD *)(a1 + 24);
v40 = (unsigned int)*(v33 - 6);
v41 = (unsigned int)(v40 - 1);
*(v33 - 6) = v41;
if ( (int)v40 <= 1 )
js_free_value_rt(v39, (_QWORD *)v33 - 3, -7LL, v40, v34, v35);
if ( (~(_WORD)v17 & 0x110) == 0 )
goto LABEL_31;
v16 = v17 & 0x10;
}
v18 = JS_ToCStringLen2(a1, &v46, a2, a3, (v16 >> 4) ^ 1);
if ( !v18 )
{
v17 = 0LL;
goto LABEL_32;
}
v19 = v18;
v22 = lre_compile((unsigned int)&v47, (unsigned int)v48, 64, (_DWORD)v18, v46, v17, a1);
v25 = *(_QWORD *)(a1 + 24);
v26 = *(v19 - 6);
v27 = (unsigned int)(v26 - 1);
*(v19 - 6) = v27;
if ( v26 <= 1 )
js_free_value_rt(v25, (_QWORD *)v19 - 3, -7LL, v27, v20, v21);
if ( !v22 )
{
v17 = 0LL;
JS_ThrowSyntaxError(a1, (long long)"%s", (long long)v48, v27, v20, v21, a6, a7, a8, a9, v23, v24, a12, a13, v45);
goto LABEL_32;
}
v28 = js_new_string8_len(a1, v22, v47);
v29 = *(_QWORD *)(a1 + 24);
--*(_QWORD *)(v29 + 40);
v30 = (*(long long ( **)(long long))(v29 + 32))(v22);
v31 = *(_QWORD *)(v29 + 64);
*(_QWORD *)(v29 + 48) = *(_QWORD *)(v29 + 48) - v30 - 8;
(*(void ( **)(long long, long long))(v29 + 16))(v31, v22);
v32 = v28 & 0xFFFFFFFF00000000LL;
v17 = (unsigned int)v28;
return v32 | v17;
}
| js_compile_regexp:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x60
MOV RAX,R8
MOV R12,RDX
MOV R13,RSI
MOV R14,RDI
XOR R8D,R8D
MOV R15D,0x0
CMP EAX,0x3
JNZ 0x00133875
LAB_0013379e:
SHR R8D,0x4
XOR R8D,0x1
LEA RSI,[RSP + 0x10]
MOV RDI,R14
MOV RDX,R13
MOV RCX,R12
CALL 0x00120717
MOV EBX,0x6
TEST RAX,RAX
JZ 0x00133979
MOV R12,RAX
MOV R8,qword ptr [RSP + 0x10]
MOV qword ptr [RSP],R14
LEA RDI,[RSP + 0x1c]
LEA RSI,[RSP + 0x20]
MOV EDX,0x40
MOV RCX,RAX
MOV R9D,R15D
CALL 0x001966c6
MOV R15,RAX
MOV RDI,qword ptr [R14 + 0x18]
MOV EAX,dword ptr [R12 + -0x18]
LEA ECX,[RAX + -0x1]
MOV dword ptr [R12 + -0x18],ECX
CMP EAX,0x1
JG 0x00133819
ADD R12,-0x18
MOV RSI,R12
MOV RDX,-0x7
CALL 0x00120d90
LAB_00133819:
TEST R15,R15
JZ 0x0013397e
MOV EDX,dword ptr [RSP + 0x1c]
MOV RDI,R14
MOV RSI,R15
CALL 0x0011fcd9
MOV R12,RAX
MOV RBX,RDX
MOV R14,qword ptr [R14 + 0x18]
DEC qword ptr [R14 + 0x28]
MOV RDI,R15
CALL qword ptr [R14 + 0x20]
MOV RCX,qword ptr [R14 + 0x30]
MOV RDI,qword ptr [R14 + 0x40]
SUB RCX,RAX
ADD RCX,-0x8
MOV qword ptr [R14 + 0x30],RCX
MOV RSI,R15
CALL qword ptr [R14 + 0x10]
MOV RAX,-0x100000000
AND RAX,R12
MOV R15D,R12D
JMP 0x001339d4
LAB_00133875:
LEA RSI,[RSP + 0x10]
XOR R15D,R15D
MOV RDI,R14
MOV RDX,RCX
MOV RCX,RAX
XOR R8D,R8D
CALL 0x00120717
MOV EBX,0x6
TEST RAX,RAX
JZ 0x001339d2
MOV RCX,qword ptr [RSP + 0x10]
TEST RCX,RCX
JZ 0x0013393c
XOR R15D,R15D
LEA RDX,[0x19e1a0]
LEA RSI,[0x19e178]
XOR EDI,EDI
LAB_001338bd:
MOVZX R8D,byte ptr [RAX + RDI*0x1]
LEA R9D,[R8 + -0x64]
CMP R9D,0x9
JBE 0x001338ec
default:
ADD R8D,-0x73
CMP R8D,0x6
JA 0x00133999
MOVSXD R8,dword ptr [RDX + R8*0x4]
ADD R8,RDX
switchD:
JMP R8
caseD_73:
MOV R8D,0x8
JMP 0x0013392c
LAB_001338ec:
MOVSXD R8,dword ptr [RSI + R9*0x4]
ADD R8,RSI
switchD:
JMP R8
caseD_64:
MOV R8D,0x40
JMP 0x0013392c
caseD_69:
MOV R8D,0x2
JMP 0x0013392c
caseD_67:
MOV R8D,0x1
JMP 0x0013392c
caseD_6d:
MOV R8D,0x4
JMP 0x0013392c
caseD_76:
MOV R8D,0x100
JMP 0x0013392c
caseD_75:
MOV R8D,0x10
JMP 0x0013392c
caseD_79:
MOV R8D,0x20
LAB_0013392c:
TEST R8D,R15D
JNZ 0x00133999
OR R15D,R8D
INC RDI
CMP RCX,RDI
JNZ 0x001338bd
LAB_0013393c:
MOV RDI,qword ptr [R14 + 0x18]
MOV ECX,dword ptr [RAX + -0x18]
LEA EDX,[RCX + -0x1]
MOV dword ptr [RAX + -0x18],EDX
CMP ECX,0x1
JG 0x00133961
ADD RAX,-0x18
MOV RSI,RAX
MOV RDX,-0x7
CALL 0x00120d90
LAB_00133961:
MOV EAX,R15D
NOT EAX
TEST EAX,0x110
JZ 0x001339be
MOV R8D,R15D
AND R8D,0x10
JMP 0x0013379e
LAB_00133979:
XOR R15D,R15D
JMP 0x001339d2
LAB_0013397e:
LEA RSI,[0x1a2f80]
XOR R15D,R15D
LEA RDX,[RSP + 0x20]
MOV RDI,R14
XOR EAX,EAX
CALL 0x001220b9
JMP 0x001339d2
caseD_74:
MOV RDI,qword ptr [R14 + 0x18]
MOV ECX,dword ptr [RAX + -0x18]
LEA EDX,[RCX + -0x1]
MOV dword ptr [RAX + -0x18],EDX
CMP ECX,0x1
JG 0x001339be
ADD RAX,-0x18
MOV RSI,RAX
MOV RDX,-0x7
CALL 0x00120d90
LAB_001339be:
LEA RSI,[0x1a137c]
XOR R15D,R15D
MOV RDI,R14
XOR EAX,EAX
CALL 0x001220b9
LAB_001339d2:
XOR EAX,EAX
LAB_001339d4:
OR R15,RAX
MOV RAX,R15
MOV RDX,RBX
ADD RSP,0x60
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
int1 [16]
js_compile_regexp(long param_1,int8 param_2,int8 param_3,int8 param_4,
int8 param_5)
{
int iVar1;
long lVar2;
long lVar3;
long lVar4;
ulong uVar5;
int8 uVar6;
uint uVar7;
uint uVar8;
ulong uVar9;
int1 auVar10 [16];
long local_78;
int4 local_6c;
int1 local_68 [64];
uVar7 = 0;
uVar8 = 0;
if ((int)param_5 == 3) {
LAB_0013379e:
lVar2 = JS_ToCStringLen2(param_1,&local_78,param_2,param_3,uVar7 >> 4 ^ 1);
if (lVar2 != 0) {
lVar3 = lre_compile(&local_6c,local_68,0x40,lVar2,local_78,uVar8,param_1);
uVar6 = *(int8 *)(param_1 + 0x18);
iVar1 = *(int *)(lVar2 + -0x18);
*(int *)(lVar2 + -0x18) = iVar1 + -1;
if (iVar1 < 2) {
js_free_value_rt(uVar6,lVar2 + -0x18,0xfffffffffffffff9);
}
if (lVar3 != 0) {
auVar10 = js_new_string8_len(param_1,lVar3,local_6c);
uVar6 = auVar10._8_8_;
lVar2 = *(long *)(param_1 + 0x18);
*(long *)(lVar2 + 0x28) = *(long *)(lVar2 + 0x28) + -1;
lVar4 = (**(code **)(lVar2 + 0x20))(lVar3);
*(long *)(lVar2 + 0x30) = (*(long *)(lVar2 + 0x30) - lVar4) + -8;
(**(code **)(lVar2 + 0x10))(*(int8 *)(lVar2 + 0x40),lVar3);
uVar5 = auVar10._0_8_ & 0xffffffff00000000;
uVar9 = auVar10._0_8_ & 0xffffffff;
goto LAB_001339d4;
}
JS_ThrowSyntaxError(param_1,"%s",local_68);
}
}
else {
uVar8 = 0;
lVar2 = JS_ToCStringLen2(param_1,&local_78,param_4,param_5,0);
if (lVar2 != 0) {
if (local_78 != 0) {
uVar8 = 0;
lVar3 = 0;
do {
switch(*(int1 *)(lVar2 + lVar3)) {
case 100:
uVar7 = 0x40;
break;
case 0x65:
case 0x66:
case 0x68:
case 0x6a:
case 0x6b:
case 0x6c:
goto switchD_001338e1_caseD_74;
case 0x67:
uVar7 = 1;
break;
case 0x69:
uVar7 = 2;
break;
case 0x6d:
uVar7 = 4;
break;
default:
switch(*(int1 *)(lVar2 + lVar3)) {
case 0x73:
uVar7 = 8;
break;
default:
goto switchD_001338e1_caseD_74;
case 0x75:
uVar7 = 0x10;
break;
case 0x76:
uVar7 = 0x100;
break;
case 0x79:
uVar7 = 0x20;
}
}
if ((uVar7 & uVar8) != 0) {
switchD_001338e1_caseD_74:
uVar6 = *(int8 *)(param_1 + 0x18);
iVar1 = *(int *)(lVar2 + -0x18);
*(int *)(lVar2 + -0x18) = iVar1 + -1;
if (iVar1 < 2) {
js_free_value_rt(uVar6,lVar2 + -0x18,0xfffffffffffffff9);
}
goto LAB_001339be;
}
uVar8 = uVar8 | uVar7;
lVar3 = lVar3 + 1;
} while (local_78 != lVar3);
}
uVar6 = *(int8 *)(param_1 + 0x18);
iVar1 = *(int *)(lVar2 + -0x18);
*(int *)(lVar2 + -0x18) = iVar1 + -1;
if (iVar1 < 2) {
js_free_value_rt(uVar6,lVar2 + -0x18,0xfffffffffffffff9);
}
if ((~uVar8 & 0x110) != 0) {
uVar7 = uVar8 & 0x10;
goto LAB_0013379e;
}
LAB_001339be:
JS_ThrowSyntaxError(param_1,"invalid regular expression flags");
}
}
uVar9 = 0;
uVar6 = 6;
uVar5 = 0;
LAB_001339d4:
auVar10._8_8_ = uVar6;
auVar10._0_8_ = uVar9 | uVar5;
return auVar10;
}
| |
38,047 | get_charset_by_csname | eloqsql/mysys/charset.c | CHARSET_INFO *
get_charset_by_csname(const char *cs_name, uint cs_flags, myf flags)
{
MY_CHARSET_LOADER loader;
my_charset_loader_init_mysys(&loader);
return my_charset_get_by_name(&loader, cs_name, cs_flags, flags);
} | O3 | c | get_charset_by_csname:
pushq %rbp
movq %rsp, %rbp
subq $0xc0, %rsp
movq %rdx, %rcx
movl %esi, %edx
movq %rdi, %rsi
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
leaq -0xb8(%rbp), %rdi
movb $0x0, (%rdi)
leaq -0x1249(%rip), %rax # 0x91b4a
movq %rax, 0x80(%rdi)
leaq -0x1248(%rip), %rax # 0x91b59
movq %rax, 0x88(%rdi)
leaq -0x123b(%rip), %rax # 0x91b74
movq %rax, 0x90(%rdi)
leaq 0xcded(%rip), %rax # 0x9fbaa
movq %rax, 0x98(%rdi)
leaq 0x2f2925(%rip), %rax # 0x3856f0
movq (%rax), %rax
movq %rax, 0xa0(%rdi)
leaq -0x124a(%rip), %rax # 0x91b92
movq %rax, 0xa8(%rdi)
callq 0x92c8c
movq %fs:0x28, %rcx
cmpq -0x8(%rbp), %rcx
jne 0x92e00
addq $0xc0, %rsp
popq %rbp
retq
callq 0x29270
| get_charset_by_csname:
push rbp
mov rbp, rsp
sub rsp, 0C0h
mov rcx, rdx
mov edx, esi
mov rsi, rdi
mov rax, fs:28h
mov [rbp+var_8], rax
lea rdi, [rbp+var_B8]
mov byte ptr [rdi], 0
lea rax, my_once_alloc_c
mov [rdi+80h], rax
lea rax, my_malloc_c
mov [rdi+88h], rax
lea rax, my_realloc_c
mov [rdi+90h], rax
lea rax, my_free
mov [rdi+98h], rax
lea rax, my_charset_error_reporter
mov rax, [rax]
mov [rdi+0A0h], rax
lea rax, add_collation
mov [rdi+0A8h], rax
call my_charset_get_by_name
mov rcx, fs:28h
cmp rcx, [rbp+var_8]
jnz short loc_92E00
add rsp, 0C0h
pop rbp
retn
loc_92E00:
call ___stack_chk_fail
| long long get_charset_by_csname(long long a1, unsigned int a2, long long a3)
{
_BYTE v4[128]; // [rsp+8h] [rbp-B8h] BYREF
long long ( *v5)(long long); // [rsp+88h] [rbp-38h]
long long ( *v6)(long long); // [rsp+90h] [rbp-30h]
long long ( *v7)(long long, long long, long long, long long, long long, long long); // [rsp+98h] [rbp-28h]
long long ( *v8)(_QWORD); // [rsp+A0h] [rbp-20h]
long long ( *v9)(); // [rsp+A8h] [rbp-18h]
long long ( *v10)(unsigned int *); // [rsp+B0h] [rbp-10h]
unsigned long long v11; // [rsp+B8h] [rbp-8h]
v11 = __readfsqword(0x28u);
v4[0] = 0;
v5 = my_once_alloc_c;
v6 = my_malloc_c;
v7 = my_realloc_c;
v8 = my_free;
v9 = my_charset_error_reporter;
v10 = add_collation;
return my_charset_get_by_name((long long)v4, a1, a2, a3);
}
| get_charset_by_csname:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xc0
MOV RCX,RDX
MOV EDX,ESI
MOV RSI,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
LEA RDI,[RBP + -0xb8]
MOV byte ptr [RDI],0x0
LEA RAX,[0x191b4a]
MOV qword ptr [RDI + 0x80],RAX
LEA RAX,[0x191b59]
MOV qword ptr [RDI + 0x88],RAX
LEA RAX,[0x191b74]
MOV qword ptr [RDI + 0x90],RAX
LEA RAX,[0x19fbaa]
MOV qword ptr [RDI + 0x98],RAX
LEA RAX,[0x4856f0]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RDI + 0xa0],RAX
LEA RAX,[0x191b92]
MOV qword ptr [RDI + 0xa8],RAX
CALL 0x00192c8c
MOV RCX,qword ptr FS:[0x28]
CMP RCX,qword ptr [RBP + -0x8]
JNZ 0x00192e00
ADD RSP,0xc0
POP RBP
RET
LAB_00192e00:
CALL 0x00129270
|
void get_charset_by_csname(int8 param_1,int4 param_2,int8 param_3)
{
long in_FS_OFFSET;
int1 local_c0 [128];
code *local_40;
code *local_38;
code *local_30;
code *local_28;
int *local_20;
code *local_18;
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
local_c0[0] = 0;
local_40 = my_once_alloc_c;
local_38 = my_malloc_c;
local_30 = my_realloc_c;
local_28 = my_free;
local_20 = my_charset_error_reporter;
local_18 = add_collation;
my_charset_get_by_name(local_c0,param_1,param_2,param_3);
if (*(long *)(in_FS_OFFSET + 0x28) == local_10) {
return;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
| |
38,048 | nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const>>::key() const | monkey531[P]llama/common/./json.hpp | const string_type& key() const
{
JSON_ASSERT(anchor.m_object != nullptr);
switch (anchor.m_object->type())
{
// use integer array index as key
case value_t::array:
{
if (array_index != array_index_last)
{
int_to_string( array_index_str, array_index );
array_index_last = array_index;
}
return array_index_str;
}
// use key from the object
case value_t::object:
return anchor.key();
// use an empty key for all primitive types
case value_t::null:
case value_t::string:
case value_t::boolean:
case value_t::number_integer:
case value_t::number_unsigned:
case value_t::number_float:
case value_t::binary:
case value_t::discarded:
default:
return empty_str;
}
} | O1 | cpp | nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const>>::key() const:
pushq %rbx
movq (%rdi), %rax
testq %rax, %rax
je 0x70b70
movq %rdi, %rbx
movzbl (%rax), %eax
cmpl $0x1, %eax
je 0x70b5e
cmpl $0x2, %eax
jne 0x70b67
movq 0x20(%rbx), %rsi
cmpq 0x28(%rbx), %rsi
je 0x70b58
leaq 0x30(%rbx), %rdi
callq 0x7389f
movq 0x20(%rbx), %rax
movq %rax, 0x28(%rbx)
addq $0x30, %rbx
jmp 0x70b6b
movq %rbx, %rdi
popq %rbx
jmp 0x4f6f6
addq $0x50, %rbx
movq %rbx, %rax
popq %rbx
retq
leaq 0x5038c(%rip), %rdi # 0xc0f03
leaq 0x4a2b0(%rip), %rsi # 0xbae2e
leaq 0x507e8(%rip), %rcx # 0xc136d
movl $0x1491, %edx # imm = 0x1491
callq 0x18470
nop
| _ZNK8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEE3keyEv:
push rbx
mov rax, [rdi]
test rax, rax
jz short loc_70B70
mov rbx, rdi
movzx eax, byte ptr [rax]
cmp eax, 1
jz short loc_70B5E
cmp eax, 2
jnz short loc_70B67
mov rsi, [rbx+20h]
cmp rsi, [rbx+28h]
jz short loc_70B58
lea rdi, [rbx+30h]
call _ZN8nlohmann16json_abi_v3_11_36detail13int_to_stringINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEvRT_m; nlohmann::json_abi_v3_11_3::detail::int_to_string<std::string>(std::string &,ulong)
mov rax, [rbx+20h]
mov [rbx+28h], rax
loc_70B58:
add rbx, 30h ; '0'
jmp short loc_70B6B
loc_70B5E:
mov rdi, rbx
pop rbx
jmp _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE3keyEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::key(void)
loc_70B67:
add rbx, 50h ; 'P'
loc_70B6B:
mov rax, rbx
pop rbx
retn
loc_70B70:
lea rdi, aAnchorMObjectN; "anchor.m_object != nullptr"
lea rsi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aConstStringTyp; "const string_type &nlohmann::detail::it"...
mov edx, 1491h
call ___assert_fail
| long long nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>>::key(
unsigned __int8 **a1)
{
int v1; // eax
if ( !*a1 )
__assert_fail(
"anchor.m_object != nullptr",
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",
5265LL,
"const string_type &nlohmann::detail::iteration_proxy_value<nlohmann::detail::iter_impl<const nlohmann::basic_json<"
"nlohmann::ordered_map>>>::key() const [IteratorType = nlohmann::detail::iter_impl<const nlohmann::basic_json<nlohm"
"ann::ordered_map>>]");
v1 = **a1;
if ( v1 == 1 )
return nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::key(a1);
if ( v1 != 2 )
return (long long)(a1 + 10);
if ( a1[4] != a1[5] )
{
nlohmann::json_abi_v3_11_3::detail::int_to_string<std::string>(a1 + 6);
a1[5] = a1[4];
}
return (long long)(a1 + 6);
}
| key:
PUSH RBX
MOV RAX,qword ptr [RDI]
TEST RAX,RAX
JZ 0x00170b70
MOV RBX,RDI
MOVZX EAX,byte ptr [RAX]
CMP EAX,0x1
JZ 0x00170b5e
CMP EAX,0x2
JNZ 0x00170b67
MOV RSI,qword ptr [RBX + 0x20]
CMP RSI,qword ptr [RBX + 0x28]
JZ 0x00170b58
LEA RDI,[RBX + 0x30]
CALL 0x0017389f
MOV RAX,qword ptr [RBX + 0x20]
MOV qword ptr [RBX + 0x28],RAX
LAB_00170b58:
ADD RBX,0x30
JMP 0x00170b6b
LAB_00170b5e:
MOV RDI,RBX
POP RBX
JMP 0x0014f6f6
LAB_00170b67:
ADD RBX,0x50
LAB_00170b6b:
MOV RAX,RBX
POP RBX
RET
LAB_00170b70:
LEA RDI,[0x1c0f03]
LEA RSI,[0x1bae2e]
LEA RCX,[0x1c136d]
MOV EDX,0x1491
CALL 0x00118470
|
/* nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> const> >::key() const */
iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>>
* __thiscall
nlohmann::json_abi_v3_11_3::detail::
iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>>
::key(iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>>
*this)
{
char cVar1;
iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>>
*piVar2;
if (*(char **)this == (char *)0x0) {
/* WARNING: Subroutine does not return */
__assert_fail("anchor.m_object != nullptr",
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",
0x1491,
"const string_type &nlohmann::detail::iteration_proxy_value<nlohmann::detail::iter_impl<const nlohmann::basic_json<nlohmann::ordered_map>>>::key() const [IteratorType = nlohmann::detail::iter_impl<const nlohmann::basic_json<nlohmann::ordered_map>>]"
);
}
cVar1 = **(char **)this;
if (cVar1 != '\x01') {
if (cVar1 == '\x02') {
if (*(ulong *)(this + 0x20) != *(ulong *)(this + 0x28)) {
int_to_string<std::__cxx11::string>((string *)(this + 0x30),*(ulong *)(this + 0x20));
*(int8 *)(this + 0x28) = *(int8 *)(this + 0x20);
}
piVar2 = this + 0x30;
}
else {
piVar2 = this + 0x50;
}
return piVar2;
}
piVar2 = (iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>>
*)iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
::key((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const>
*)this);
return piVar2;
}
| |
38,049 | nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const>>::key() const | monkey531[P]llama/common/./json.hpp | const string_type& key() const
{
JSON_ASSERT(anchor.m_object != nullptr);
switch (anchor.m_object->type())
{
// use integer array index as key
case value_t::array:
{
if (array_index != array_index_last)
{
int_to_string( array_index_str, array_index );
array_index_last = array_index;
}
return array_index_str;
}
// use key from the object
case value_t::object:
return anchor.key();
// use an empty key for all primitive types
case value_t::null:
case value_t::string:
case value_t::boolean:
case value_t::number_integer:
case value_t::number_unsigned:
case value_t::number_float:
case value_t::binary:
case value_t::discarded:
default:
return empty_str;
}
} | O3 | cpp | nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const>>::key() const:
pushq %rbx
movq (%rdi), %rax
testq %rax, %rax
je 0x71acc
movq %rdi, %rbx
movzbl (%rax), %eax
cmpl $0x1, %eax
je 0x71aba
cmpl $0x2, %eax
jne 0x71ac3
movq 0x20(%rbx), %rsi
cmpq 0x28(%rbx), %rsi
je 0x71ab4
leaq 0x30(%rbx), %rdi
callq 0x71b7f
movq 0x20(%rbx), %rax
movq %rax, 0x28(%rbx)
addq $0x30, %rbx
jmp 0x71ac7
movq %rbx, %rdi
popq %rbx
jmp 0x71c40
addq $0x50, %rbx
movq %rbx, %rax
popq %rbx
retq
leaq 0x4b2a8(%rip), %rdi # 0xbcd7b
leaq 0x451cc(%rip), %rsi # 0xb6ca6
leaq 0x4b2b5(%rip), %rcx # 0xbcd96
movl $0x1491, %edx # imm = 0x1491
callq 0x18470
nop
| _ZNK8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEE3keyEv:
push rbx
mov rax, [rdi]
test rax, rax
jz short loc_71ACC
mov rbx, rdi
movzx eax, byte ptr [rax]
cmp eax, 1
jz short loc_71ABA
cmp eax, 2
jnz short loc_71AC3
mov rsi, [rbx+20h]
cmp rsi, [rbx+28h]
jz short loc_71AB4
lea rdi, [rbx+30h]
call _ZN8nlohmann16json_abi_v3_11_36detail13int_to_stringINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEEvRT_m; nlohmann::json_abi_v3_11_3::detail::int_to_string<std::string>(std::string &,ulong)
mov rax, [rbx+20h]
mov [rbx+28h], rax
loc_71AB4:
add rbx, 30h ; '0'
jmp short loc_71AC7
loc_71ABA:
mov rdi, rbx
pop rbx
jmp _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE3keyEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::key(void)
loc_71AC3:
add rbx, 50h ; 'P'
loc_71AC7:
mov rax, rbx
pop rbx
retn
loc_71ACC:
lea rdi, aAnchorMObjectN; "anchor.m_object != nullptr"
lea rsi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rcx, aConstStringTyp_0; "const string_type &nlohmann::detail::it"...
mov edx, 1491h
call ___assert_fail
| long long nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>>::key(
unsigned __int8 **a1)
{
int v1; // eax
if ( !*a1 )
__assert_fail(
"anchor.m_object != nullptr",
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",
5265LL,
"const string_type &nlohmann::detail::iteration_proxy_value<nlohmann::detail::iter_impl<nlohmann::basic_json<nlohma"
"nn::ordered_map>>>::key() const [IteratorType = nlohmann::detail::iter_impl<nlohmann::basic_json<nlohmann::ordered_map>>]");
v1 = **a1;
if ( v1 == 1 )
return nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::key(a1);
if ( v1 != 2 )
return (long long)(a1 + 10);
if ( a1[4] != a1[5] )
{
nlohmann::json_abi_v3_11_3::detail::int_to_string<std::string>(a1 + 6);
a1[5] = a1[4];
}
return (long long)(a1 + 6);
}
| key:
PUSH RBX
MOV RAX,qword ptr [RDI]
TEST RAX,RAX
JZ 0x00171acc
MOV RBX,RDI
MOVZX EAX,byte ptr [RAX]
CMP EAX,0x1
JZ 0x00171aba
CMP EAX,0x2
JNZ 0x00171ac3
MOV RSI,qword ptr [RBX + 0x20]
CMP RSI,qword ptr [RBX + 0x28]
JZ 0x00171ab4
LEA RDI,[RBX + 0x30]
CALL 0x00171b7f
MOV RAX,qword ptr [RBX + 0x20]
MOV qword ptr [RBX + 0x28],RAX
LAB_00171ab4:
ADD RBX,0x30
JMP 0x00171ac7
LAB_00171aba:
MOV RDI,RBX
POP RBX
JMP 0x00171c40
LAB_00171ac3:
ADD RBX,0x50
LAB_00171ac7:
MOV RAX,RBX
POP RBX
RET
LAB_00171acc:
LEA RDI,[0x1bcd7b]
LEA RSI,[0x1b6ca6]
LEA RCX,[0x1bcd96]
MOV EDX,0x1491
CALL 0x00118470
|
/* nlohmann::json_abi_v3_11_3::detail::iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void> > >::key() const */
iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>
* __thiscall
nlohmann::json_abi_v3_11_3::detail::
iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>
::key(iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>
*this)
{
char cVar1;
iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>
*piVar2;
if (*(char **)this == (char *)0x0) {
/* WARNING: Subroutine does not return */
__assert_fail("anchor.m_object != nullptr",
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",
0x1491,
"const string_type &nlohmann::detail::iteration_proxy_value<nlohmann::detail::iter_impl<nlohmann::basic_json<nlohmann::ordered_map>>>::key() const [IteratorType = nlohmann::detail::iter_impl<nlohmann::basic_json<nlohmann::ordered_map>>]"
);
}
cVar1 = **(char **)this;
if (cVar1 != '\x01') {
if (cVar1 == '\x02') {
if (*(ulong *)(this + 0x20) != *(ulong *)(this + 0x28)) {
int_to_string<std::__cxx11::string>((string *)(this + 0x30),*(ulong *)(this + 0x20));
*(int8 *)(this + 0x28) = *(int8 *)(this + 0x20);
}
piVar2 = this + 0x30;
}
else {
piVar2 = this + 0x50;
}
return piVar2;
}
piVar2 = (iteration_proxy_value<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>
*)iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::key((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*)this);
return piVar2;
}
| |
38,050 | my_init_mysys_psi_keys | eloqsql/mysys/my_init.c | void my_init_mysys_psi_keys()
{
const char* category= "mysys";
int count;
count= sizeof(all_mysys_mutexes)/sizeof(all_mysys_mutexes[0]);
mysql_mutex_register(category, all_mysys_mutexes, count);
count= sizeof(all_mysys_conds)/sizeof(all_mysys_conds[0]);
mysql_cond_register(category, all_mysys_conds, count);
count= sizeof(all_mysys_rwlocks)/sizeof(all_mysys_rwlocks[0]);
mysql_rwlock_register(category, all_mysys_rwlocks, count);
count= sizeof(all_mysys_threads)/sizeof(all_mysys_threads[0]);
mysql_thread_register(category, all_mysys_threads, count);
count= sizeof(all_mysys_files)/sizeof(all_mysys_files[0]);
mysql_file_register(category, all_mysys_files, count);
count= array_elements(all_mysys_stages);
mysql_stage_register(category, all_mysys_stages, count);
} | O3 | c | my_init_mysys_psi_keys:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
leaq 0x2e9f27(%rip), %r14 # 0x393a58
movq (%r14), %rax
leaq 0x3f0ef(%rip), %rbx # 0xe8c2a
leaq 0x2e96be(%rip), %rsi # 0x393200
movq %rbx, %rdi
movl $0x13, %edx
callq *(%rax)
movq (%r14), %rax
leaq 0x2e987a(%rip), %rsi # 0x3933d0
movq %rbx, %rdi
movl $0x7, %edx
callq *0x10(%rax)
movq (%r14), %rax
leaq 0x2e9915(%rip), %rsi # 0x393480
movq %rbx, %rdi
movl $0x1, %edx
callq *0x8(%rax)
movq (%r14), %rax
leaq 0x2e9920(%rip), %rsi # 0x3934a0
movq %rbx, %rdi
movl $0x1, %edx
callq *0x18(%rax)
movq (%r14), %rax
leaq 0x2e992b(%rip), %rsi # 0x3934c0
movq %rbx, %rdi
movl $0x2, %edx
callq *0x20(%rax)
movq (%r14), %rax
movq 0x28(%rax), %rax
leaq 0x2e9642(%rip), %rsi # 0x3931f0
movq %rbx, %rdi
movl $0x1, %edx
popq %rbx
popq %r14
popq %rbp
jmpq *%rax
| my_init_mysys_psi_keys:
push rbp
mov rbp, rsp
push r14
push rbx
lea r14, PSI_server
mov rax, [r14]
lea rbx, aMysys; "mysys"
lea rsi, all_mysys_mutexes
mov rdi, rbx
mov edx, 13h
call qword ptr [rax]
mov rax, [r14]
lea rsi, all_mysys_conds
mov rdi, rbx
mov edx, 7
call qword ptr [rax+10h]
mov rax, [r14]
lea rsi, all_mysys_rwlocks
mov rdi, rbx
mov edx, 1
call qword ptr [rax+8]
mov rax, [r14]
lea rsi, all_mysys_threads
mov rdi, rbx
mov edx, 1
call qword ptr [rax+18h]
mov rax, [r14]
lea rsi, all_mysys_files
mov rdi, rbx
mov edx, 2
call qword ptr [rax+20h]
mov rax, [r14]
mov rax, [rax+28h]
lea rsi, all_mysys_stages
mov rdi, rbx
mov edx, 1
pop rbx
pop r14
pop rbp
jmp rax
| long long my_init_mysys_psi_keys()
{
((void ( *)(const char *, _UNKNOWN **, long long))*PSI_server)("mysys", &all_mysys_mutexes, 19LL);
((void ( *)(const char *, _UNKNOWN **, long long))PSI_server[2])("mysys", &all_mysys_conds, 7LL);
((void ( *)(const char *, _UNKNOWN **, long long))PSI_server[1])("mysys", &all_mysys_rwlocks, 1LL);
((void ( *)(const char *, _UNKNOWN **, long long))PSI_server[3])("mysys", &all_mysys_threads, 1LL);
((void ( *)(const char *, _UNKNOWN **, long long))PSI_server[4])("mysys", &all_mysys_files, 2LL);
return ((long long ( *)(const char *, _UNKNOWN **, long long))PSI_server[5])("mysys", &all_mysys_stages, 1LL);
}
| my_init_mysys_psi_keys:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
LEA R14,[0x493a58]
MOV RAX,qword ptr [R14]
LEA RBX,[0x1e8c2a]
LEA RSI,[0x493200]
MOV RDI,RBX
MOV EDX,0x13
CALL qword ptr [RAX]
MOV RAX,qword ptr [R14]
LEA RSI,[0x4933d0]
MOV RDI,RBX
MOV EDX,0x7
CALL qword ptr [RAX + 0x10]
MOV RAX,qword ptr [R14]
LEA RSI,[0x493480]
MOV RDI,RBX
MOV EDX,0x1
CALL qword ptr [RAX + 0x8]
MOV RAX,qword ptr [R14]
LEA RSI,[0x4934a0]
MOV RDI,RBX
MOV EDX,0x1
CALL qword ptr [RAX + 0x18]
MOV RAX,qword ptr [R14]
LEA RSI,[0x4934c0]
MOV RDI,RBX
MOV EDX,0x2
CALL qword ptr [RAX + 0x20]
MOV RAX,qword ptr [R14]
MOV RAX,qword ptr [RAX + 0x28]
LEA RSI,[0x4931f0]
MOV RDI,RBX
MOV EDX,0x1
POP RBX
POP R14
POP RBP
JMP RAX
|
void my_init_mysys_psi_keys(void)
{
(**(code **)PSI_server)("mysys",all_mysys_mutexes,0x13);
(**(code **)(PSI_server + 0x10))("mysys",all_mysys_conds,7);
(**(code **)(PSI_server + 8))("mysys",all_mysys_rwlocks,1);
(**(code **)(PSI_server + 0x18))("mysys",all_mysys_threads,1);
(**(code **)(PSI_server + 0x20))("mysys",all_mysys_files,2);
/* WARNING: Could not recover jumptable at 0x001a9bba. Too many branches */
/* WARNING: Treating indirect jump as call */
(**(code **)(PSI_server + 0x28))("mysys",&all_mysys_stages,1);
return;
}
| |
38,051 | dequeue | xtate/src/util-data/lfqueue.c | static void *_dequeue(lfqueue_t *lfqueue) {
lfqueue_cas_node_t *head, *next;
void *val;
for (;;) {
head = lfqueue->head;
if (__LFQ_BOOL_COMPARE_AND_SWAP(&lfqueue->head, head, head)) {
next = head->next;
if (__LFQ_BOOL_COMPARE_AND_SWAP(&lfqueue->tail, head, head)) {
if (next == NULL) {
val = NULL;
goto _done;
}
} else {
if (next) {
val = next->value;
if (__LFQ_BOOL_COMPARE_AND_SWAP(&lfqueue->head, head,
next)) {
break;
}
} else {
val = NULL;
goto _done;
}
}
}
}
__lfq_recycle_free(lfqueue, head);
_done:
// __asm volatile("" ::: "memory");
__LFQ_SYNC_MEMORY();
__lfq_check_free(lfqueue);
return val;
} | O3 | c | dequeue:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movq (%rbx), %r14
movq %r14, %rax
lock
cmpxchgq %r14, (%rbx)
jne 0x50c18
movq 0x8(%r14), %rcx
movq %r14, %rax
lock
cmpxchgq %r14, 0x8(%rbx)
jne 0x50c3b
testq %rcx, %rcx
jne 0x50c18
jmp 0x50c7c
testq %rcx, %rcx
je 0x50c7c
movq (%rcx), %r15
movq %r14, %rax
lock
cmpxchgq %rcx, (%rbx)
jne 0x50c18
movq 0x18(%rbx), %r12
xorl %eax, %eax
lock
cmpxchgq %r14, 0x10(%r12)
jne 0x50c4d
movq %rsp, %r13
movq %r13, %rdi
xorl %esi, %esi
callq 0x15530
movq (%r13), %rax
movq %rax, 0x18(%r14)
movq %r12, %rax
lock
cmpxchgq %r14, 0x18(%rbx)
jmp 0x50c7f
xorl %r15d, %r15d
mfence
movq %rbx, %rdi
callq 0x50d54
movq %r15, %rax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
| _dequeue:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 10h
mov rbx, rdi
loc_50C18:
mov r14, [rbx]
mov rax, r14
lock cmpxchg [rbx], r14
jnz short loc_50C18
mov rcx, [r14+8]
mov rax, r14
lock cmpxchg [rbx+8], r14
jnz short loc_50C3B
test rcx, rcx
jnz short loc_50C18
jmp short loc_50C7C
loc_50C3B:
test rcx, rcx
jz short loc_50C7C
mov r15, [rcx]
mov rax, r14
lock cmpxchg [rbx], rcx
jnz short loc_50C18
loc_50C4D:
mov r12, [rbx+18h]
xor eax, eax
lock cmpxchg [r12+10h], r14
jnz short loc_50C4D
mov r13, rsp
mov rdi, r13
xor esi, esi
call _gettimeofday
mov rax, [r13+0]
mov [r14+18h], rax
mov rax, r12
lock cmpxchg [rbx+18h], r14
jmp short loc_50C7F
loc_50C7C:
xor r15d, r15d
loc_50C7F:
mfence
mov rdi, rbx
call __lfq_check_free
mov rax, r15
add rsp, 10h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
| long long dequeue(volatile signed long long *a1)
{
signed long long v1; // r14
long long *v2; // rcx
long long v3; // r15
signed long long v4; // r12
long long v6; // [rsp+0h] [rbp-38h] BYREF
do
{
while ( 1 )
{
do
v1 = *a1;
while ( v1 != _InterlockedCompareExchange64(a1, v1, v1) );
v2 = *(long long **)(v1 + 8);
if ( v1 != _InterlockedCompareExchange64(a1 + 1, v1, v1) )
break;
if ( !v2 )
goto LABEL_9;
}
if ( !v2 )
{
LABEL_9:
v3 = 0LL;
goto LABEL_10;
}
v3 = *v2;
}
while ( v1 != _InterlockedCompareExchange64(a1, (signed long long)v2, v1) );
do
v4 = *((_QWORD *)a1 + 3);
while ( _InterlockedCompareExchange64((volatile signed long long *)(v4 + 16), v1, 0LL) );
gettimeofday(&v6, 0LL);
*(_QWORD *)(v1 + 24) = v6;
_InterlockedCompareExchange64(a1 + 3, v1, v4);
LABEL_10:
_mm_mfence();
_lfq_check_free(a1);
return v3;
}
| _dequeue:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x10
MOV RBX,RDI
LAB_00150c18:
MOV R14,qword ptr [RBX]
MOV RAX,R14
CMPXCHG.LOCK qword ptr [RBX],R14
JNZ 0x00150c18
MOV RCX,qword ptr [R14 + 0x8]
MOV RAX,R14
CMPXCHG.LOCK qword ptr [RBX + 0x8],R14
JNZ 0x00150c3b
TEST RCX,RCX
JNZ 0x00150c18
JMP 0x00150c7c
LAB_00150c3b:
TEST RCX,RCX
JZ 0x00150c7c
MOV R15,qword ptr [RCX]
MOV RAX,R14
CMPXCHG.LOCK qword ptr [RBX],RCX
JNZ 0x00150c18
LAB_00150c4d:
MOV R12,qword ptr [RBX + 0x18]
XOR EAX,EAX
CMPXCHG.LOCK qword ptr [R12 + 0x10],R14
JNZ 0x00150c4d
MOV R13,RSP
MOV RDI,R13
XOR ESI,ESI
CALL 0x00115530
MOV RAX,qword ptr [R13]
MOV qword ptr [R14 + 0x18],RAX
MOV RAX,R12
CMPXCHG.LOCK qword ptr [RBX + 0x18],R14
JMP 0x00150c7f
LAB_00150c7c:
XOR R15D,R15D
LAB_00150c7f:
MFENCE
MOV RDI,RBX
CALL 0x00150d54
MOV RAX,R15
ADD RSP,0x10
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
int8 _dequeue(long *param_1)
{
long *plVar1;
long lVar2;
long lVar3;
int8 *puVar4;
int8 uVar5;
bool bVar6;
timeval local_38;
do {
while( true ) {
do {
lVar3 = *param_1;
LOCK();
lVar2 = *param_1;
if (lVar3 == lVar2) {
*param_1 = lVar3;
}
UNLOCK();
} while (lVar3 != lVar2);
puVar4 = *(int8 **)(lVar3 + 8);
LOCK();
bVar6 = lVar3 == param_1[1];
if (bVar6) {
param_1[1] = lVar3;
}
UNLOCK();
if (!bVar6) break;
if (puVar4 == (int8 *)0x0) {
LAB_00150c7c:
uVar5 = 0;
goto code_r0x00150c82;
}
}
if (puVar4 == (int8 *)0x0) goto LAB_00150c7c;
uVar5 = *puVar4;
LOCK();
lVar2 = *param_1;
if (lVar3 == lVar2) {
*param_1 = (long)puVar4;
}
UNLOCK();
} while (lVar3 != lVar2);
do {
lVar2 = param_1[3];
plVar1 = (long *)(lVar2 + 0x10);
LOCK();
bVar6 = *plVar1 == 0;
if (bVar6) {
*plVar1 = lVar3;
}
UNLOCK();
} while (!bVar6);
gettimeofday(&local_38,(__timezone_ptr_t)0x0);
*(__time_t *)(lVar3 + 0x18) = local_38.tv_sec;
LOCK();
if (lVar2 == param_1[3]) {
param_1[3] = lVar3;
}
UNLOCK();
code_r0x00150c82:
__lfq_check_free(param_1);
return uVar5;
}
| |
38,052 | nlohmann::json_abi_v3_11_3::detail::dtoa_impl::format_buffer(char*, int, int, int, int) | monkey531[P]llama/common/./json.hpp | inline char* format_buffer(char* buf, int len, int decimal_exponent,
int min_exp, int max_exp)
{
JSON_ASSERT(min_exp < 0);
JSON_ASSERT(max_exp > 0);
const int k = len;
const int n = len + decimal_exponent;
// v = buf * 10^(n-k)
// k is the length of the buffer (number of decimal digits)
// n is the position of the decimal point relative to the start of the buffer.
if (k <= n && n <= max_exp)
{
// digits[000]
// len <= max_exp + 2
std::memset(buf + k, '0', static_cast<size_t>(n) - static_cast<size_t>(k));
// Make it look like a floating-point number (#362, #378)
buf[n + 0] = '.';
buf[n + 1] = '0';
return buf + (static_cast<size_t>(n) + 2);
}
if (0 < n && n <= max_exp)
{
// dig.its
// len <= max_digits10 + 1
JSON_ASSERT(k > n);
std::memmove(buf + (static_cast<size_t>(n) + 1), buf + n, static_cast<size_t>(k) - static_cast<size_t>(n));
buf[n] = '.';
return buf + (static_cast<size_t>(k) + 1U);
}
if (min_exp < n && n <= 0)
{
// 0.[000]digits
// len <= 2 + (-min_exp - 1) + max_digits10
std::memmove(buf + (2 + static_cast<size_t>(-n)), buf, static_cast<size_t>(k));
buf[0] = '0';
buf[1] = '.';
std::memset(buf + 2, '0', static_cast<size_t>(-n));
return buf + (2U + static_cast<size_t>(-n) + static_cast<size_t>(k));
}
if (k == 1)
{
// dE+123
// len <= 1 + 5
buf += 1;
}
else
{
// d.igitsE+123
// len <= max_digits10 + 1 + 5
std::memmove(buf + 2, buf + 1, static_cast<size_t>(k) - 1);
buf[1] = '.';
buf += 1 + static_cast<size_t>(k);
}
*buf++ = 'e';
return append_exponent(buf, n - 1);
} | O1 | cpp | nlohmann::json_abi_v3_11_3::detail::dtoa_impl::format_buffer(char*, int, int, int, int):
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
testl %ecx, %ecx
jns 0x7640c
testl %r8d, %r8d
jle 0x76428
movq %rdi, %rbx
leal (%rdx,%rsi), %r14d
testl %edx, %edx
sets %al
cmpl %r8d, %r14d
setg %dil
orb %al, %dil
je 0x762c6
cmpl %r8d, %r14d
setg %al
testl %r14d, %r14d
setle %dil
orb %al, %dil
je 0x762f4
cmpl %ecx, %r14d
setle %al
testl %r14d, %r14d
setg %cl
orb %al, %cl
jne 0x7632e
negl %r14d
leaq (%rbx,%r14), %r15
addq $0x2, %r15
movslq %esi, %r12
movq %r15, %rdi
movq %rbx, %rsi
movq %r12, %rdx
callq 0x201b0
movw $0x2e30, (%rbx) # imm = 0x2E30
addq $0x2, %rbx
movq %rbx, %rdi
movl $0x30, %esi
movq %r14, %rdx
callq 0x1f610
addq %r12, %r15
jmp 0x763fd
movslq %esi, %rax
leaq (%rbx,%rax), %rdi
movslq %r14d, %r14
movq %r14, %rdx
subq %rax, %rdx
movl $0x30, %esi
callq 0x1f610
leaq (%rbx,%r14), %r15
addq $0x2, %r15
movw $0x302e, -0x2(%r15) # imm = 0x302E
jmp 0x763fd
testl %edx, %edx
jns 0x76449
movl %r14d, %ecx
leaq (%rbx,%rcx), %rax
leaq (%rbx,%rcx), %r14
incq %r14
movl %esi, %r15d
movq %r15, %rdx
subq %rcx, %rdx
movq %r14, %rdi
movq %rax, %rsi
callq 0x201b0
movb $0x2e, -0x1(%r14)
addq %rbx, %r15
incq %r15
jmp 0x763fd
cmpl $0x1, %esi
je 0x76351
leaq 0x2(%rbx), %rdi
leaq 0x1(%rbx), %rax
movslq %esi, %r15
leaq -0x1(%r15), %rdx
movq %rax, %rsi
callq 0x201b0
movb $0x2e, 0x1(%rbx)
addq %r15, %rbx
movb $0x65, 0x1(%rbx)
cmpl $0xfffffc19, %r14d # imm = 0xFFFFFC19
jle 0x76465
cmpl $0x3e9, %r14d # imm = 0x3E9
jge 0x76481
leal -0x1(%r14), %ecx
testl %r14d, %r14d
setle %dl
addb %dl, %dl
addb $0x2b, %dl
movl %ecx, %eax
negl %eax
cmovsl %ecx, %eax
movb %dl, 0x2(%rbx)
cmpl $0x9, %eax
ja 0x76393
movb $0x30, 0x3(%rbx)
jmp 0x763b6
movl %eax, %ecx
cmpl $0x63, %eax
ja 0x763c1
movl $0xcccccccd, %edx # imm = 0xCCCCCCCD
imulq %rcx, %rdx
shrq $0x23, %rdx
movl %edx, %ecx
orb $0x30, %cl
movb %cl, 0x3(%rbx)
addl %edx, %edx
leal (%rdx,%rdx,4), %ecx
subl %ecx, %eax
orb $0x30, %al
movb %al, 0x4(%rbx)
addq $0x5, %rbx
jmp 0x763fa
imulq $0x51eb851f, %rcx, %rcx # imm = 0x51EB851F
shrq $0x25, %rcx
leal 0x30(%rcx), %edx
movb %dl, 0x3(%rbx)
imull $0x64, %ecx, %ecx
subl %ecx, %eax
imulq $0x1999999a, %rax, %rcx # imm = 0x1999999A
shrq $0x20, %rcx
movl %ecx, %edx
orb $0x30, %dl
movb %dl, 0x4(%rbx)
addl %ecx, %ecx
leal (%rcx,%rcx,4), %ecx
subl %ecx, %eax
orb $0x30, %al
movb %al, 0x5(%rbx)
addq $0x6, %rbx
movq %rbx, %r15
movq %r15, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
leaq 0xd597b(%rip), %rdi # 0x14bd8e
leaq 0xd59c0(%rip), %rdx # 0x14bdda
leaq 0xd7936(%rip), %rcx # 0x14dd57
movl $0x45e3, %esi # imm = 0x45E3
jmp 0x76442
leaq 0xd595f(%rip), %rdi # 0x14bd8e
leaq 0xd59a4(%rip), %rdx # 0x14bdda
leaq 0xd7926(%rip), %rcx # 0x14dd63
movl $0x45e4, %esi # imm = 0x45E4
xorl %eax, %eax
callq 0x20250
leaq 0xd593e(%rip), %rdi # 0x14bd8e
leaq 0xd5983(%rip), %rdx # 0x14bdda
leaq 0xd7911(%rip), %rcx # 0x14dd6f
movl $0x45fe, %esi # imm = 0x45FE
jmp 0x76442
leaq 0xd5922(%rip), %rdi # 0x14bd8e
leaq 0xd5967(%rip), %rdx # 0x14bdda
leaq 0xd78fb(%rip), %rcx # 0x14dd75
movl $0x45ae, %esi # imm = 0x45AE
jmp 0x76442
leaq 0xd5906(%rip), %rdi # 0x14bd8e
leaq 0xd594b(%rip), %rdx # 0x14bdda
leaq 0xd78e9(%rip), %rcx # 0x14dd7f
movl $0x45af, %esi # imm = 0x45AF
jmp 0x76442
| _ZN8nlohmann16json_abi_v3_11_36detail9dtoa_impl13format_bufferEPciiii:
push r15
push r14
push r12
push rbx
push rax
test ecx, ecx
jns loc_7640C
test r8d, r8d
jle loc_76428
mov rbx, rdi
lea r14d, [rdx+rsi]
test edx, edx
sets al
cmp r14d, r8d
setnle dil
or dil, al
jz short loc_762C6
cmp r14d, r8d
setnle al
test r14d, r14d
setle dil
or dil, al
jz short loc_762F4
cmp r14d, ecx
setle al
test r14d, r14d
setnle cl
or cl, al
jnz loc_7632E
neg r14d
lea r15, [rbx+r14]
add r15, 2
movsxd r12, esi
mov rdi, r15
mov rsi, rbx
mov rdx, r12
call _memmove
mov word ptr [rbx], 2E30h
add rbx, 2
mov rdi, rbx
mov esi, 30h ; '0'
mov rdx, r14
call _memset
add r15, r12
jmp loc_763FD
loc_762C6:
movsxd rax, esi
lea rdi, [rbx+rax]
movsxd r14, r14d
mov rdx, r14
sub rdx, rax
mov esi, 30h ; '0'
call _memset
lea r15, [rbx+r14]
add r15, 2
mov word ptr [r15-2], 302Eh
jmp loc_763FD
loc_762F4:
test edx, edx
jns loc_76449
mov ecx, r14d
lea rax, [rbx+rcx]
lea r14, [rbx+rcx]
inc r14
mov r15d, esi
mov rdx, r15
sub rdx, rcx
mov rdi, r14
mov rsi, rax
call _memmove
mov byte ptr [r14-1], 2Eh ; '.'
add r15, rbx
inc r15
jmp loc_763FD
loc_7632E:
cmp esi, 1
jz short loc_76351
lea rdi, [rbx+2]
lea rax, [rbx+1]
movsxd r15, esi
lea rdx, [r15-1]
mov rsi, rax
call _memmove
mov byte ptr [rbx+1], 2Eh ; '.'
add rbx, r15
loc_76351:
mov byte ptr [rbx+1], 65h ; 'e'
cmp r14d, 0FFFFFC19h
jle loc_76465
cmp r14d, 3E9h
jge loc_76481
lea ecx, [r14-1]
test r14d, r14d
setle dl
add dl, dl
add dl, 2Bh ; '+'
mov eax, ecx
neg eax
cmovs eax, ecx
mov [rbx+2], dl
cmp eax, 9
ja short loc_76393
mov byte ptr [rbx+3], 30h ; '0'
jmp short loc_763B6
loc_76393:
mov ecx, eax
cmp eax, 63h ; 'c'
ja short loc_763C1
mov edx, 0CCCCCCCDh
imul rdx, rcx
shr rdx, 23h
mov ecx, edx
or cl, 30h
mov [rbx+3], cl
add edx, edx
lea ecx, [rdx+rdx*4]
sub eax, ecx
loc_763B6:
or al, 30h
mov [rbx+4], al
add rbx, 5
jmp short loc_763FA
loc_763C1:
imul rcx, 51EB851Fh
shr rcx, 25h
lea edx, [rcx+30h]
mov [rbx+3], dl
imul ecx, 64h ; 'd'
sub eax, ecx
imul rcx, rax, 1999999Ah
shr rcx, 20h
mov edx, ecx
or dl, 30h
mov [rbx+4], dl
add ecx, ecx
lea ecx, [rcx+rcx*4]
sub eax, ecx
or al, 30h
mov [rbx+5], al
add rbx, 6
loc_763FA:
mov r15, rbx
loc_763FD:
mov rax, r15
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
loc_7640C:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMinExp0; "min_exp < 0"
mov esi, 45E3h
jmp short loc_76442
loc_76428:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aMaxExp0; "max_exp > 0"
mov esi, 45E4h
loc_76442:
xor eax, eax
call _ggml_abort
loc_76449:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aKN; "k > n"
mov esi, 45FEh
jmp short loc_76442
loc_76465:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aE1000; "e > -1000"
mov esi, 45AEh
jmp short loc_76442
loc_76481:
lea rdi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aE1000_0; "e < 1000"
mov esi, 45AFh
jmp short loc_76442
| char * nlohmann::json_abi_v3_11_3::detail::dtoa_impl::format_buffer(
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *this,
char *a2,
int a3,
int a4,
int a5)
{
nlohmann::json_abi_v3_11_3::detail::dtoa_impl *v5; // rbx
int v6; // r14d
long long v7; // r14
char *v8; // r15
long long v9; // rcx
char *v10; // r14
unsigned int v11; // eax
long long v13; // rax
if ( a4 >= 0 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",
17891LL,
"GGML_ASSERT(%s) failed",
"min_exp < 0");
goto LABEL_26;
}
if ( a5 <= 0 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",
17892LL,
"GGML_ASSERT(%s) failed",
"max_exp > 0");
goto LABEL_26;
}
v5 = this;
v6 = a3 + (_DWORD)a2;
if ( a3 >= 0 && a3 + (int)a2 <= a5 )
{
memset((char *)this + (int)a2, 48LL, v6 - (long long)(int)a2);
v8 = (char *)this + v6 + 2;
*(_WORD *)((char *)this + v6) = 12334;
return v8;
}
if ( v6 <= a5 && v6 > 0 )
{
if ( a3 < 0 )
{
v9 = (unsigned int)v6;
v10 = (char *)this + (unsigned int)v6 + 1;
memmove(v10, (char *)this + v9, (unsigned int)a2 - v9);
*(v10 - 1) = 46;
return (char *)this + (unsigned int)a2 + 1;
}
goto LABEL_26;
}
if ( v6 <= a4 || v6 > 0 )
{
if ( (_DWORD)a2 != 1 )
{
memmove((char *)this + 2, (char *)this + 1, (int)a2 - 1LL);
*((_BYTE *)this + 1) = 46;
v5 = (nlohmann::json_abi_v3_11_3::detail::dtoa_impl *)((char *)this + (int)a2);
}
*((_BYTE *)v5 + 1) = 101;
if ( v6 <= -999 )
{
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",
17838LL,
"GGML_ASSERT(%s) failed",
"e > -1000");
}
else
{
if ( v6 < 1001 )
{
v11 = 1 - v6;
if ( 1 - v6 < 0 )
v11 = v6 - 1;
*((_BYTE *)v5 + 2) = 2 * (v6 <= 0) + 43;
if ( v11 > 9 )
{
if ( v11 > 0x63 )
{
*((_BYTE *)v5 + 3) = v11 / 0x64 + 48;
v13 = v11 % 0x64;
*((_BYTE *)v5 + 4) = ((unsigned long long)(429496730 * v13) >> 32) | 0x30;
*((_BYTE *)v5 + 5) = (v13 - 10 * ((unsigned long long)(429496730 * v13) >> 32)) | 0x30;
return (char *)v5 + 6;
}
*((_BYTE *)v5 + 3) = (v11 / 0xA) | 0x30;
v11 %= 0xAu;
}
else
{
*((_BYTE *)v5 + 3) = 48;
}
*((_BYTE *)v5 + 4) = v11 | 0x30;
return (char *)v5 + 5;
}
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",
17839LL,
"GGML_ASSERT(%s) failed",
"e < 1000");
}
while ( 1 )
LABEL_26:
ggml_abort(
"/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",
17918LL,
"GGML_ASSERT(%s) failed",
"k > n");
}
v7 = (unsigned int)-v6;
memmove((char *)this + v7 + 2, this, (int)a2);
*(_WORD *)this = 11824;
memset((char *)this + 2, 48LL, v7);
return (char *)this + v7 + (int)a2 + 2;
}
| format_buffer:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
TEST ECX,ECX
JNS 0x0017640c
TEST R8D,R8D
JLE 0x00176428
MOV RBX,RDI
LEA R14D,[RDX + RSI*0x1]
TEST EDX,EDX
SETS AL
CMP R14D,R8D
SETG DIL
OR DIL,AL
JZ 0x001762c6
CMP R14D,R8D
SETG AL
TEST R14D,R14D
SETLE DIL
OR DIL,AL
JZ 0x001762f4
CMP R14D,ECX
SETLE AL
TEST R14D,R14D
SETG CL
OR CL,AL
JNZ 0x0017632e
NEG R14D
LEA R15,[RBX + R14*0x1]
ADD R15,0x2
MOVSXD R12,ESI
MOV RDI,R15
MOV RSI,RBX
MOV RDX,R12
CALL 0x001201b0
MOV word ptr [RBX],0x2e30
ADD RBX,0x2
MOV RDI,RBX
MOV ESI,0x30
MOV RDX,R14
CALL 0x0011f610
ADD R15,R12
JMP 0x001763fd
LAB_001762c6:
MOVSXD RAX,ESI
LEA RDI,[RBX + RAX*0x1]
MOVSXD R14,R14D
MOV RDX,R14
SUB RDX,RAX
MOV ESI,0x30
CALL 0x0011f610
LEA R15,[RBX + R14*0x1]
ADD R15,0x2
MOV word ptr [R15 + -0x2],0x302e
JMP 0x001763fd
LAB_001762f4:
TEST EDX,EDX
JNS 0x00176449
MOV ECX,R14D
LEA RAX,[RBX + RCX*0x1]
LEA R14,[RBX + RCX*0x1]
INC R14
MOV R15D,ESI
MOV RDX,R15
SUB RDX,RCX
MOV RDI,R14
MOV RSI,RAX
CALL 0x001201b0
MOV byte ptr [R14 + -0x1],0x2e
ADD R15,RBX
INC R15
JMP 0x001763fd
LAB_0017632e:
CMP ESI,0x1
JZ 0x00176351
LEA RDI,[RBX + 0x2]
LEA RAX,[RBX + 0x1]
MOVSXD R15,ESI
LEA RDX,[R15 + -0x1]
MOV RSI,RAX
CALL 0x001201b0
MOV byte ptr [RBX + 0x1],0x2e
ADD RBX,R15
LAB_00176351:
MOV byte ptr [RBX + 0x1],0x65
CMP R14D,0xfffffc19
JLE 0x00176465
CMP R14D,0x3e9
JGE 0x00176481
LEA ECX,[R14 + -0x1]
TEST R14D,R14D
SETLE DL
ADD DL,DL
ADD DL,0x2b
MOV EAX,ECX
NEG EAX
CMOVS EAX,ECX
MOV byte ptr [RBX + 0x2],DL
CMP EAX,0x9
JA 0x00176393
MOV byte ptr [RBX + 0x3],0x30
JMP 0x001763b6
LAB_00176393:
MOV ECX,EAX
CMP EAX,0x63
JA 0x001763c1
MOV EDX,0xcccccccd
IMUL RDX,RCX
SHR RDX,0x23
MOV ECX,EDX
OR CL,0x30
MOV byte ptr [RBX + 0x3],CL
ADD EDX,EDX
LEA ECX,[RDX + RDX*0x4]
SUB EAX,ECX
LAB_001763b6:
OR AL,0x30
MOV byte ptr [RBX + 0x4],AL
ADD RBX,0x5
JMP 0x001763fa
LAB_001763c1:
IMUL RCX,RCX,0x51eb851f
SHR RCX,0x25
LEA EDX,[RCX + 0x30]
MOV byte ptr [RBX + 0x3],DL
IMUL ECX,ECX,0x64
SUB EAX,ECX
IMUL RCX,RAX,0x1999999a
SHR RCX,0x20
MOV EDX,ECX
OR DL,0x30
MOV byte ptr [RBX + 0x4],DL
ADD ECX,ECX
LEA ECX,[RCX + RCX*0x4]
SUB EAX,ECX
OR AL,0x30
MOV byte ptr [RBX + 0x5],AL
ADD RBX,0x6
LAB_001763fa:
MOV R15,RBX
LAB_001763fd:
MOV RAX,R15
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
LAB_0017640c:
LEA RDI,[0x24bd8e]
LEA RDX,[0x24bdda]
LEA RCX,[0x24dd57]
MOV ESI,0x45e3
JMP 0x00176442
LAB_00176428:
LEA RDI,[0x24bd8e]
LEA RDX,[0x24bdda]
LEA RCX,[0x24dd63]
MOV ESI,0x45e4
LAB_00176442:
XOR EAX,EAX
CALL 0x00120250
LAB_00176449:
LEA RDI,[0x24bd8e]
LEA RDX,[0x24bdda]
LEA RCX,[0x24dd6f]
MOV ESI,0x45fe
JMP 0x00176442
LAB_00176465:
LEA RDI,[0x24bd8e]
LEA RDX,[0x24bdda]
LEA RCX,[0x24dd75]
MOV ESI,0x45ae
JMP 0x00176442
LAB_00176481:
LEA RDI,[0x24bd8e]
LEA RDX,[0x24bdda]
LEA RCX,[0x24dd7f]
MOV ESI,0x45af
JMP 0x00176442
|
/* nlohmann::json_abi_v3_11_3::detail::dtoa_impl::format_buffer(char*, int, int, int, int) */
char * nlohmann::json_abi_v3_11_3::detail::dtoa_impl::format_buffer
(char *param_1,int param_2,int param_3,int param_4,int param_5)
{
uint uVar1;
uint uVar2;
ulong uVar3;
char *pcVar4;
byte bVar5;
int8 uVar6;
uint uVar7;
if (param_4 < 0) {
if (param_5 < 1) {
pcVar4 = "max_exp > 0";
uVar6 = 0x45e4;
}
else {
uVar7 = param_3 + param_2;
if ((int)uVar7 <= param_5 && -1 < param_3) {
memset(param_1 + param_2,0x30,(long)(int)uVar7 - (long)param_2);
pcVar4 = param_1 + (int)uVar7;
pcVar4[0] = '.';
pcVar4[1] = '0';
return pcVar4 + 2;
}
if ((int)uVar7 < 1 || param_5 < (int)uVar7) {
if ((int)uVar7 < 1 && param_4 < (int)uVar7) {
memmove(param_1 + (ulong)-uVar7 + 2,param_1,(long)param_2);
param_1[0] = '0';
param_1[1] = '.';
memset(param_1 + 2,0x30,(ulong)-uVar7);
return param_1 + (ulong)-uVar7 + 2 + param_2;
}
if (param_2 != 1) {
memmove(param_1 + 2,param_1 + 1,(long)param_2 - 1);
param_1[1] = '.';
param_1 = param_1 + param_2;
}
param_1[1] = 'e';
if ((int)uVar7 < -0x3e6) {
pcVar4 = "e > -1000";
uVar6 = 0x45ae;
}
else {
if ((int)uVar7 < 0x3e9) {
uVar1 = uVar7 - 1;
uVar2 = -uVar1;
if (0 < (int)uVar1) {
uVar2 = uVar1;
}
param_1[2] = ((int)uVar7 < 1) * '\x02' + '+';
if (uVar2 < 10) {
param_1[3] = '0';
}
else {
if (99 < uVar2) {
param_1[3] = (char)(uVar2 / 100) + '0';
bVar5 = (byte)((ulong)(uVar2 % 100) * 0x1999999a >> 0x20);
param_1[4] = bVar5 | 0x30;
param_1[5] = (char)(uVar2 % 100) + bVar5 * -10 | 0x30;
return param_1 + 6;
}
param_1[3] = (byte)((ulong)uVar2 / 10) | 0x30;
uVar2 = uVar2 + (uVar2 / 10 + uVar2 / 10) * -5;
}
param_1[4] = (byte)uVar2 | 0x30;
return param_1 + 5;
}
pcVar4 = "e < 1000";
uVar6 = 0x45af;
}
}
else {
if (param_3 < 0) {
uVar3 = (ulong)uVar7;
memmove(param_1 + uVar3 + 1,param_1 + uVar3,(uint)param_2 - uVar3);
param_1[uVar3] = '.';
return param_1 + (ulong)(uint)param_2 + 1;
}
pcVar4 = "k > n";
uVar6 = 0x45fe;
}
}
}
else {
pcVar4 = "min_exp < 0";
uVar6 = 0x45e3;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/./json.hpp",uVar6,
"GGML_ASSERT(%s) failed",pcVar4);
}
| |
38,053 | maria_rtree_get_next | eloqsql/storage/maria/ma_rt_index.c | int maria_rtree_get_next(MARIA_HA *info, uint keynr, uint key_length)
{
my_off_t root;
MARIA_KEYDEF *keyinfo= info->s->keyinfo + keynr;
uchar *keyread_buff= info->keyread_buff;
if (!info->keyread_buff_used)
{
uint key_data_length= keyinfo->keylength - info->s->base.rec_reflength;
/* rt_PAGE_NEXT_KEY(*info->last_rtree_keypos) */
uchar *key= keyread_buff + *info->last_rtree_keypos + keyinfo->keylength;
/* rt_PAGE_NEXT_KEY(key) */
uchar *after_key= key + keyinfo->keylength;
MARIA_KEY tmp_key;
tmp_key.keyinfo= keyinfo;
tmp_key.data= key;
tmp_key.data_length= key_data_length;
tmp_key.ref_length= info->s->base.rec_reflength;
tmp_key.flag= 0;
info->cur_row.lastpos= _ma_row_pos_from_key(&tmp_key);
_ma_copy_key(&info->last_key, &tmp_key);
*info->last_rtree_keypos= (uint) (key - keyread_buff);
if (after_key >= info->int_maxpos)
{
info->keyread_buff_used= 1;
}
return 0;
}
else
{
if ((root= info->s->state.key_root[keynr]) == HA_OFFSET_ERROR)
{
my_errno= HA_ERR_END_OF_FILE;
return -1;
}
return maria_rtree_get_req(info, &keyinfo[keynr], key_length, root, 0);
}
} | O0 | c | maria_rtree_get_next:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x570(%rax), %rax
movl -0x14(%rbp), %ecx
imulq $0x118, %rcx, %rcx # imm = 0x118
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rax
movq 0x380(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x10(%rbp), %rax
cmpb $0x0, 0x685(%rax)
jne 0x7c8e5
movq -0x28(%rbp), %rax
movzwl 0xaa(%rax), %eax
movq -0x10(%rbp), %rcx
movq (%rcx), %rcx
subl 0x3e0(%rcx), %eax
movl %eax, -0x34(%rbp)
movq -0x30(%rbp), %rax
movq -0x10(%rbp), %rcx
movq 0x638(%rcx), %rcx
movl (%rcx), %ecx
addq %rcx, %rax
movq -0x28(%rbp), %rcx
movzwl 0xaa(%rcx), %ecx
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq -0x28(%rbp), %rcx
movzwl 0xaa(%rcx), %ecx
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x48(%rbp)
movq -0x28(%rbp), %rax
movq %rax, -0x60(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x68(%rbp)
movl -0x34(%rbp), %eax
movl %eax, -0x58(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movl 0x3e0(%rax), %eax
movl %eax, -0x54(%rbp)
movl $0x0, -0x50(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x97330
movq %rax, %rcx
movq -0x10(%rbp), %rax
movq %rcx, 0x98(%rax)
movq -0x10(%rbp), %rdi
addq $0x200, %rdi # imm = 0x200
leaq -0x68(%rbp), %rsi
callq 0x49450
movq -0x40(%rbp), %rax
movq -0x30(%rbp), %rcx
subq %rcx, %rax
movl %eax, %ecx
movq -0x10(%rbp), %rax
movq 0x638(%rax), %rax
movl %ecx, (%rax)
movq -0x48(%rbp), %rax
movq -0x10(%rbp), %rcx
cmpq 0x3b8(%rcx), %rax
jb 0x7c8dc
movq -0x10(%rbp), %rax
movb $0x1, 0x685(%rax)
movl $0x0, -0x4(%rbp)
jmp 0x7c93f
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x118(%rax), %rax
movl -0x14(%rbp), %ecx
movq (%rax,%rcx,8), %rax
movq %rax, -0x20(%rbp)
cmpq $-0x1, %rax
jne 0x7c918
callq 0xf7a70
movl $0x89, (%rax)
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x7c93f
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rsi
movl -0x14(%rbp), %eax
imulq $0x118, %rax, %rax # imm = 0x118
addq %rax, %rsi
movl -0x18(%rbp), %edx
movq -0x20(%rbp), %rcx
xorl %r8d, %r8d
callq 0x7c270
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x70, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| maria_rtree_get_next:
push rbp
mov rbp, rsp
sub rsp, 70h
mov [rbp+var_10], rdi
mov [rbp+var_14], esi
mov [rbp+var_18], edx
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+570h]
mov ecx, [rbp+var_14]
imul rcx, 118h
add rax, rcx
mov [rbp+var_28], rax
mov rax, [rbp+var_10]
mov rax, [rax+380h]
mov [rbp+var_30], rax
mov rax, [rbp+var_10]
cmp byte ptr [rax+685h], 0
jnz loc_7C8E5
mov rax, [rbp+var_28]
movzx eax, word ptr [rax+0AAh]
mov rcx, [rbp+var_10]
mov rcx, [rcx]
sub eax, [rcx+3E0h]
mov [rbp+var_34], eax
mov rax, [rbp+var_30]
mov rcx, [rbp+var_10]
mov rcx, [rcx+638h]
mov ecx, [rcx]
add rax, rcx
mov rcx, [rbp+var_28]
movzx ecx, word ptr [rcx+0AAh]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_40], rax
mov rax, [rbp+var_40]
mov rcx, [rbp+var_28]
movzx ecx, word ptr [rcx+0AAh]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_48], rax
mov rax, [rbp+var_28]
mov [rbp+var_60], rax
mov rax, [rbp+var_40]
mov [rbp+var_68], rax
mov eax, [rbp+var_34]
mov [rbp+var_58], eax
mov rax, [rbp+var_10]
mov rax, [rax]
mov eax, [rax+3E0h]
mov [rbp+var_54], eax
mov [rbp+var_50], 0
lea rdi, [rbp+var_68]
call _ma_row_pos_from_key
mov rcx, rax
mov rax, [rbp+var_10]
mov [rax+98h], rcx
mov rdi, [rbp+var_10]
add rdi, 200h
lea rsi, [rbp+var_68]
call _ma_copy_key
mov rax, [rbp+var_40]
mov rcx, [rbp+var_30]
sub rax, rcx
mov ecx, eax
mov rax, [rbp+var_10]
mov rax, [rax+638h]
mov [rax], ecx
mov rax, [rbp+var_48]
mov rcx, [rbp+var_10]
cmp rax, [rcx+3B8h]
jb short loc_7C8DC
mov rax, [rbp+var_10]
mov byte ptr [rax+685h], 1
loc_7C8DC:
mov [rbp+var_4], 0
jmp short loc_7C93F
loc_7C8E5:
mov rax, [rbp+var_10]
mov rax, [rax]
mov rax, [rax+118h]
mov ecx, [rbp+var_14]
mov rax, [rax+rcx*8]
mov [rbp+var_20], rax
cmp rax, 0FFFFFFFFFFFFFFFFh
jnz short loc_7C918
call _my_thread_var
mov dword ptr [rax], 89h
mov [rbp+var_4], 0FFFFFFFFh
jmp short loc_7C93F
loc_7C918:
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_28]
mov eax, [rbp+var_14]
imul rax, 118h
add rsi, rax
mov edx, [rbp+var_18]
mov rcx, [rbp+var_20]
xor r8d, r8d
call maria_rtree_get_req
mov [rbp+var_4], eax
loc_7C93F:
mov eax, [rbp+var_4]
add rsp, 70h
pop rbp
retn
| long long maria_rtree_get_next(long long a1, const char *a2, unsigned int a3)
{
long long v3; // rax
_QWORD v5[2]; // [rsp+8h] [rbp-68h] BYREF
int v6; // [rsp+18h] [rbp-58h]
int v7; // [rsp+1Ch] [rbp-54h]
int v8; // [rsp+20h] [rbp-50h]
unsigned long long v9; // [rsp+28h] [rbp-48h]
long long v10; // [rsp+30h] [rbp-40h]
int v11; // [rsp+3Ch] [rbp-34h]
long long v12; // [rsp+40h] [rbp-30h]
long long v13; // [rsp+48h] [rbp-28h]
long long v14; // [rsp+50h] [rbp-20h]
unsigned int v15; // [rsp+58h] [rbp-18h]
unsigned int v16; // [rsp+5Ch] [rbp-14h]
long long *v17; // [rsp+60h] [rbp-10h]
v17 = (long long *)a1;
v16 = (unsigned int)a2;
v15 = a3;
v13 = 280LL * (unsigned int)a2 + *(_QWORD *)(*(_QWORD *)a1 + 1392LL);
v12 = *(_QWORD *)(a1 + 896);
if ( *(_BYTE *)(a1 + 1669) )
{
v14 = *(_QWORD *)(*(_QWORD *)(*v17 + 280) + 8LL * v16);
if ( v14 == -1 )
{
*(_DWORD *)my_thread_var(a1, a2) = 137;
return (unsigned int)-1;
}
else
{
return (unsigned int)maria_rtree_get_req(v17, 280LL * v16 + v13, v15, v14, 0);
}
}
else
{
v11 = *(unsigned __int16 *)(v13 + 170) - *(_DWORD *)(*v17 + 992);
v10 = *(unsigned __int16 *)(v13 + 170) + *(unsigned int *)v17[199] + v12;
v9 = *(unsigned __int16 *)(v13 + 170) + v10;
v5[1] = v13;
v5[0] = v10;
v6 = v11;
v7 = *(_DWORD *)(*v17 + 992);
v8 = 0;
v3 = ma_row_pos_from_key(v5);
v17[19] = v3;
ma_copy_key((long long)(v17 + 64), (long long)v5);
*(_DWORD *)v17[199] = v10 - v12;
if ( v9 >= v17[119] )
*((_BYTE *)v17 + 1669) = 1;
return 0;
}
}
| maria_rtree_get_next:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x70
MOV qword ptr [RBP + -0x10],RDI
MOV dword ptr [RBP + -0x14],ESI
MOV dword ptr [RBP + -0x18],EDX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x570]
MOV ECX,dword ptr [RBP + -0x14]
IMUL RCX,RCX,0x118
ADD RAX,RCX
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x380]
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x10]
CMP byte ptr [RAX + 0x685],0x0
JNZ 0x0017c8e5
MOV RAX,qword ptr [RBP + -0x28]
MOVZX EAX,word ptr [RAX + 0xaa]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX]
SUB EAX,dword ptr [RCX + 0x3e0]
MOV dword ptr [RBP + -0x34],EAX
MOV RAX,qword ptr [RBP + -0x30]
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x638]
MOV ECX,dword ptr [RCX]
ADD RAX,RCX
MOV RCX,qword ptr [RBP + -0x28]
MOVZX ECX,word ptr [RCX + 0xaa]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x40],RAX
MOV RAX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RBP + -0x28]
MOVZX ECX,word ptr [RCX + 0xaa]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x48],RAX
MOV RAX,qword ptr [RBP + -0x28]
MOV qword ptr [RBP + -0x60],RAX
MOV RAX,qword ptr [RBP + -0x40]
MOV qword ptr [RBP + -0x68],RAX
MOV EAX,dword ptr [RBP + -0x34]
MOV dword ptr [RBP + -0x58],EAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV EAX,dword ptr [RAX + 0x3e0]
MOV dword ptr [RBP + -0x54],EAX
MOV dword ptr [RBP + -0x50],0x0
LEA RDI,[RBP + -0x68]
CALL 0x00197330
MOV RCX,RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RAX + 0x98],RCX
MOV RDI,qword ptr [RBP + -0x10]
ADD RDI,0x200
LEA RSI,[RBP + -0x68]
CALL 0x00149450
MOV RAX,qword ptr [RBP + -0x40]
MOV RCX,qword ptr [RBP + -0x30]
SUB RAX,RCX
MOV ECX,EAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x638]
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBP + -0x10]
CMP RAX,qword ptr [RCX + 0x3b8]
JC 0x0017c8dc
MOV RAX,qword ptr [RBP + -0x10]
MOV byte ptr [RAX + 0x685],0x1
LAB_0017c8dc:
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0017c93f
LAB_0017c8e5:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x118]
MOV ECX,dword ptr [RBP + -0x14]
MOV RAX,qword ptr [RAX + RCX*0x8]
MOV qword ptr [RBP + -0x20],RAX
CMP RAX,-0x1
JNZ 0x0017c918
CALL 0x001f7a70
MOV dword ptr [RAX],0x89
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x0017c93f
LAB_0017c918:
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x28]
MOV EAX,dword ptr [RBP + -0x14]
IMUL RAX,RAX,0x118
ADD RSI,RAX
MOV EDX,dword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x20]
XOR R8D,R8D
CALL 0x0017c270
MOV dword ptr [RBP + -0x4],EAX
LAB_0017c93f:
MOV EAX,dword ptr [RBP + -0x4]
ADD RSP,0x70
POP RBP
RET
|
int4 maria_rtree_get_next(long *param_1,uint param_2,int4 param_3)
{
long lVar1;
int4 *puVar2;
long local_70;
long local_68;
int local_60;
int4 local_5c;
int4 local_58;
ulong local_50;
long local_48;
int local_3c;
long local_38;
long local_30;
long local_28;
int4 local_20;
uint local_1c;
long *local_18;
int4 local_c;
local_68 = *(long *)(*param_1 + 0x570) + (ulong)param_2 * 0x118;
local_38 = param_1[0x70];
local_30 = local_68;
local_20 = param_3;
local_1c = param_2;
local_18 = param_1;
if (*(char *)((long)param_1 + 0x685) == '\0') {
local_60 = (uint)*(ushort *)(local_68 + 0xaa) - *(int *)(*param_1 + 0x3e0);
local_70 = local_38 + (ulong)*(uint *)param_1[199] +
(long)(int)(uint)*(ushort *)(local_68 + 0xaa);
local_50 = local_70 + (int)(uint)*(ushort *)(local_68 + 0xaa);
local_5c = *(int4 *)(*param_1 + 0x3e0);
local_58 = 0;
local_48 = local_70;
local_3c = local_60;
lVar1 = _ma_row_pos_from_key(&local_70);
local_18[0x13] = lVar1;
_ma_copy_key(local_18 + 0x40,&local_70);
*(int *)local_18[199] = (int)local_48 - (int)local_38;
if ((ulong)local_18[0x77] <= local_50) {
*(int1 *)((long)local_18 + 0x685) = 1;
}
local_c = 0;
}
else {
local_28 = *(long *)(*(long *)(*param_1 + 0x118) + (ulong)param_2 * 8);
if (local_28 == -1) {
puVar2 = (int4 *)_my_thread_var();
*puVar2 = 0x89;
local_c = 0xffffffff;
}
else {
local_c = maria_rtree_get_req(param_1,local_68 + (ulong)param_2 * 0x118,param_3,local_28,0);
}
}
return local_c;
}
| |
38,054 | mysql_session_track_get_first | eloqsql/libmariadb/libmariadb/mariadb_lib.c | int STDCALL mysql_session_track_get_first(MYSQL *mysql, enum enum_session_state_type type,
const char **data, size_t *length)
{
mysql->extension->session_state[type].current= mysql->extension->session_state[type].list;
return mysql_session_track_get_next(mysql, type, data, length);
} | O3 | c | mysql_session_track_get_first:
pushq %rbp
movq %rsp, %rbp
movq 0x4f0(%rdi), %r8
movl %esi, %eax
shlq $0x4, %rax
movq 0x8(%r8,%rax), %rsi
movq %rsi, 0x10(%r8,%rax)
movq 0x4f0(%rdi), %rdi
movq 0x10(%rdi,%rax), %rsi
testq %rsi, %rsi
je 0x78a1a
addq %rdi, %rax
addq $0x10, %rax
movq 0x8(%rsi), %rdi
movq 0x10(%rsi), %rsi
movq %rdi, (%rax)
movq (%rsi), %rdi
movq %rdi, (%rdx)
xorl %eax, %eax
testq %rdi, %rdi
je 0x78a21
movq 0x8(%rsi), %rdx
jmp 0x78a23
movl $0x1, %eax
jmp 0x78a26
xorl %edx, %edx
movq %rdx, (%rcx)
popq %rbp
retq
| mysql_session_track_get_first:
push rbp
mov rbp, rsp
mov r8, [rdi+4F0h]
mov eax, esi
shl rax, 4
mov rsi, [r8+rax+8]
mov [r8+rax+10h], rsi
mov rdi, [rdi+4F0h]
mov rsi, [rdi+rax+10h]
test rsi, rsi
jz short loc_78A1A
add rax, rdi
add rax, 10h
mov rdi, [rsi+8]
mov rsi, [rsi+10h]
mov [rax], rdi
mov rdi, [rsi]
mov [rdx], rdi
xor eax, eax
test rdi, rdi
jz short loc_78A21
mov rdx, [rsi+8]
jmp short loc_78A23
loc_78A1A:
mov eax, 1
jmp short loc_78A26
loc_78A21:
xor edx, edx
loc_78A23:
mov [rcx], rdx
loc_78A26:
pop rbp
retn
| long long mysql_session_track_get_first(long long a1, unsigned int a2, long long *a3, _QWORD *a4)
{
long long v4; // rax
long long v5; // rdi
long long v6; // rsi
_QWORD *v7; // rax
long long v8; // rdi
long long *v9; // rsi
long long v10; // rdi
long long result; // rax
long long v12; // rdx
v4 = 16LL * a2;
*(_QWORD *)(*(_QWORD *)(a1 + 1264) + v4 + 16) = *(_QWORD *)(*(_QWORD *)(a1 + 1264) + v4 + 8);
v5 = *(_QWORD *)(a1 + 1264);
v6 = *(_QWORD *)(v5 + v4 + 16);
if ( !v6 )
return 1LL;
v7 = (_QWORD *)(v5 + v4 + 16);
v8 = *(_QWORD *)(v6 + 8);
v9 = *(long long **)(v6 + 16);
*v7 = v8;
v10 = *v9;
*a3 = *v9;
result = 0LL;
if ( v10 )
v12 = v9[1];
else
v12 = 0LL;
*a4 = v12;
return result;
}
| mysql_session_track_get_first:
PUSH RBP
MOV RBP,RSP
MOV R8,qword ptr [RDI + 0x4f0]
MOV EAX,ESI
SHL RAX,0x4
MOV RSI,qword ptr [R8 + RAX*0x1 + 0x8]
MOV qword ptr [R8 + RAX*0x1 + 0x10],RSI
MOV RDI,qword ptr [RDI + 0x4f0]
MOV RSI,qword ptr [RDI + RAX*0x1 + 0x10]
TEST RSI,RSI
JZ 0x00178a1a
ADD RAX,RDI
ADD RAX,0x10
MOV RDI,qword ptr [RSI + 0x8]
MOV RSI,qword ptr [RSI + 0x10]
MOV qword ptr [RAX],RDI
MOV RDI,qword ptr [RSI]
MOV qword ptr [RDX],RDI
XOR EAX,EAX
TEST RDI,RDI
JZ 0x00178a21
MOV RDX,qword ptr [RSI + 0x8]
JMP 0x00178a23
LAB_00178a1a:
MOV EAX,0x1
JMP 0x00178a26
LAB_00178a21:
XOR EDX,EDX
LAB_00178a23:
MOV qword ptr [RCX],RDX
LAB_00178a26:
POP RBP
RET
|
int8 mysql_session_track_get_first(long param_1,ulong param_2,long *param_3,long *param_4)
{
long *plVar1;
long lVar2;
int8 uVar3;
long lVar4;
lVar2 = (param_2 & 0xffffffff) * 0x10;
*(int8 *)(*(long *)(param_1 + 0x4f0) + 0x10 + lVar2) =
*(int8 *)(*(long *)(param_1 + 0x4f0) + 8 + lVar2);
lVar4 = *(long *)(*(long *)(param_1 + 0x4f0) + 0x10 + lVar2);
if (lVar4 == 0) {
uVar3 = 1;
}
else {
plVar1 = *(long **)(lVar4 + 0x10);
*(int8 *)(lVar2 + *(long *)(param_1 + 0x4f0) + 0x10) = *(int8 *)(lVar4 + 8);
lVar4 = *plVar1;
*param_3 = lVar4;
uVar3 = 0;
if (lVar4 == 0) {
lVar4 = 0;
}
else {
lVar4 = plVar1[1];
}
*param_4 = lVar4;
}
return uVar3;
}
| |
38,055 | exchange_int64s | bluesky950520[P]quickjs/cutils.c | static void exchange_int64s(void *a, void *b, size_t size) {
uint64_t *ap = (uint64_t *)a;
uint64_t *bp = (uint64_t *)b;
for (size /= sizeof(uint64_t); size-- != 0;) {
uint64_t t = *ap;
*ap++ = *bp;
*bp++ = t;
}
} | O0 | c | exchange_int64s:
movq %rdi, -0x8(%rsp)
movq %rsi, -0x10(%rsp)
movq %rdx, -0x18(%rsp)
movq -0x8(%rsp), %rax
movq %rax, -0x20(%rsp)
movq -0x10(%rsp), %rax
movq %rax, -0x28(%rsp)
movq -0x18(%rsp), %rax
shrq $0x3, %rax
movq %rax, -0x18(%rsp)
movq -0x18(%rsp), %rax
movq %rax, %rcx
addq $-0x1, %rcx
movq %rcx, -0x18(%rsp)
cmpq $0x0, %rax
je 0x2008c
movq -0x20(%rsp), %rax
movq (%rax), %rax
movq %rax, -0x30(%rsp)
movq -0x28(%rsp), %rax
movq (%rax), %rcx
movq -0x20(%rsp), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, -0x20(%rsp)
movq %rcx, (%rax)
movq -0x30(%rsp), %rcx
movq -0x28(%rsp), %rax
movq %rax, %rdx
addq $0x8, %rdx
movq %rdx, -0x28(%rsp)
movq %rcx, (%rax)
jmp 0x20031
retq
nopl (%rax)
| exchange_int64s:
mov [rsp+var_8], rdi
mov [rsp+var_10], rsi
mov [rsp+var_18], rdx
mov rax, [rsp+var_8]
mov [rsp+var_20], rax
mov rax, [rsp+var_10]
mov [rsp+var_28], rax
mov rax, [rsp+var_18]
shr rax, 3
mov [rsp+var_18], rax
loc_20031:
mov rax, [rsp+var_18]
mov rcx, rax
add rcx, 0FFFFFFFFFFFFFFFFh
mov [rsp+var_18], rcx
cmp rax, 0
jz short locret_2008C
mov rax, [rsp+var_20]
mov rax, [rax]
mov [rsp+var_30], rax
mov rax, [rsp+var_28]
mov rcx, [rax]
mov rax, [rsp+var_20]
mov rdx, rax
add rdx, 8
mov [rsp+var_20], rdx
mov [rax], rcx
mov rcx, [rsp+var_30]
mov rax, [rsp+var_28]
mov rdx, rax
add rdx, 8
mov [rsp+var_28], rdx
mov [rax], rcx
jmp short loc_20031
locret_2008C:
retn
| long long exchange_int64s(long long *a1, long long *a2, unsigned long long a3)
{
long long result; // rax
long long *v4; // rax
long long *v5; // rax
long long v6; // [rsp+0h] [rbp-30h]
unsigned long long v9; // [rsp+18h] [rbp-18h]
v9 = a3 >> 3;
while ( 1 )
{
result = v9--;
if ( !result )
break;
v6 = *a1;
v4 = a1++;
*v4 = *a2;
v5 = a2++;
*v5 = v6;
}
return result;
}
| exchange_int64s:
MOV qword ptr [RSP + -0x8],RDI
MOV qword ptr [RSP + -0x10],RSI
MOV qword ptr [RSP + -0x18],RDX
MOV RAX,qword ptr [RSP + -0x8]
MOV qword ptr [RSP + -0x20],RAX
MOV RAX,qword ptr [RSP + -0x10]
MOV qword ptr [RSP + -0x28],RAX
MOV RAX,qword ptr [RSP + -0x18]
SHR RAX,0x3
MOV qword ptr [RSP + -0x18],RAX
LAB_00120031:
MOV RAX,qword ptr [RSP + -0x18]
MOV RCX,RAX
ADD RCX,-0x1
MOV qword ptr [RSP + -0x18],RCX
CMP RAX,0x0
JZ 0x0012008c
MOV RAX,qword ptr [RSP + -0x20]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP + -0x30],RAX
MOV RAX,qword ptr [RSP + -0x28]
MOV RCX,qword ptr [RAX]
MOV RAX,qword ptr [RSP + -0x20]
MOV RDX,RAX
ADD RDX,0x8
MOV qword ptr [RSP + -0x20],RDX
MOV qword ptr [RAX],RCX
MOV RCX,qword ptr [RSP + -0x30]
MOV RAX,qword ptr [RSP + -0x28]
MOV RDX,RAX
ADD RDX,0x8
MOV qword ptr [RSP + -0x28],RDX
MOV qword ptr [RAX],RCX
JMP 0x00120031
LAB_0012008c:
RET
|
void exchange_int64s(int8 *param_1,int8 *param_2,ulong param_3)
{
int8 uVar1;
int8 *local_28;
int8 *local_20;
ulong local_18;
local_28 = param_2;
local_20 = param_1;
local_18 = param_3 >> 3;
while (local_18 != 0) {
uVar1 = *local_20;
*local_20 = *local_28;
*local_28 = uVar1;
local_28 = local_28 + 1;
local_20 = local_20 + 1;
local_18 = local_18 - 1;
}
return;
}
| |
38,056 | exchange_int64s | bluesky950520[P]quickjs/cutils.c | static void exchange_int64s(void *a, void *b, size_t size) {
uint64_t *ap = (uint64_t *)a;
uint64_t *bp = (uint64_t *)b;
for (size /= sizeof(uint64_t); size-- != 0;) {
uint64_t t = *ap;
*ap++ = *bp;
*bp++ = t;
}
} | O1 | c | exchange_int64s:
cmpq $0x8, %rdx
jb 0x1bcf6
shrq $0x3, %rdx
xorl %eax, %eax
movq (%rdi,%rax,8), %rcx
movq (%rsi,%rax,8), %r8
movq %r8, (%rdi,%rax,8)
movq %rcx, (%rsi,%rax,8)
incq %rax
cmpq %rax, %rdx
jne 0x1bcde
retq
| exchange_int64s:
cmp rdx, 8
jb short locret_1BCF6
shr rdx, 3
xor eax, eax
loc_1BCDE:
mov rcx, [rdi+rax*8]
mov r8, [rsi+rax*8]
mov [rdi+rax*8], r8
mov [rsi+rax*8], rcx
inc rax
cmp rdx, rax
jnz short loc_1BCDE
locret_1BCF6:
retn
| void exchange_int64s(long long a1, long long a2, unsigned long long a3)
{
unsigned long long v3; // rdx
long long v4; // rax
long long v5; // rcx
if ( a3 >= 8 )
{
v3 = a3 >> 3;
v4 = 0LL;
do
{
v5 = *(_QWORD *)(a1 + 8 * v4);
*(_QWORD *)(a1 + 8 * v4) = *(_QWORD *)(a2 + 8 * v4);
*(_QWORD *)(a2 + 8 * v4++) = v5;
}
while ( v3 != v4 );
}
}
| exchange_int64s:
CMP RDX,0x8
JC 0x0011bcf6
SHR RDX,0x3
XOR EAX,EAX
LAB_0011bcde:
MOV RCX,qword ptr [RDI + RAX*0x8]
MOV R8,qword ptr [RSI + RAX*0x8]
MOV qword ptr [RDI + RAX*0x8],R8
MOV qword ptr [RSI + RAX*0x8],RCX
INC RAX
CMP RDX,RAX
JNZ 0x0011bcde
LAB_0011bcf6:
RET
|
void exchange_int64s(long param_1,long param_2,ulong param_3)
{
int8 uVar1;
ulong uVar2;
if (7 < param_3) {
uVar2 = 0;
do {
uVar1 = *(int8 *)(param_1 + uVar2 * 8);
*(int8 *)(param_1 + uVar2 * 8) = *(int8 *)(param_2 + uVar2 * 8);
*(int8 *)(param_2 + uVar2 * 8) = uVar1;
uVar2 = uVar2 + 1;
} while (param_3 >> 3 != uVar2);
}
return;
}
| |
38,057 | exchange_int64s | bluesky950520[P]quickjs/cutils.c | static void exchange_int64s(void *a, void *b, size_t size) {
uint64_t *ap = (uint64_t *)a;
uint64_t *bp = (uint64_t *)b;
for (size /= sizeof(uint64_t); size-- != 0;) {
uint64_t t = *ap;
*ap++ = *bp;
*bp++ = t;
}
} | O3 | c | exchange_int64s:
cmpq $0x8, %rdx
jb 0x1c5cc
shrq $0x3, %rdx
xorl %eax, %eax
movq (%rdi,%rax,8), %rcx
movq (%rsi,%rax,8), %r8
movq %r8, (%rdi,%rax,8)
movq %rcx, (%rsi,%rax,8)
incq %rax
cmpq %rax, %rdx
jne 0x1c5b4
retq
| exchange_int64s:
cmp rdx, 8
jb short locret_1C5CC
shr rdx, 3
xor eax, eax
loc_1C5B4:
mov rcx, [rdi+rax*8]
mov r8, [rsi+rax*8]
mov [rdi+rax*8], r8
mov [rsi+rax*8], rcx
inc rax
cmp rdx, rax
jnz short loc_1C5B4
locret_1C5CC:
retn
| void exchange_int64s(long long a1, long long a2, unsigned long long a3)
{
unsigned long long v3; // rdx
long long v4; // rax
long long v5; // rcx
if ( a3 >= 8 )
{
v3 = a3 >> 3;
v4 = 0LL;
do
{
v5 = *(_QWORD *)(a1 + 8 * v4);
*(_QWORD *)(a1 + 8 * v4) = *(_QWORD *)(a2 + 8 * v4);
*(_QWORD *)(a2 + 8 * v4++) = v5;
}
while ( v3 != v4 );
}
}
| exchange_int64s:
CMP RDX,0x8
JC 0x0011c5cc
SHR RDX,0x3
XOR EAX,EAX
LAB_0011c5b4:
MOV RCX,qword ptr [RDI + RAX*0x8]
MOV R8,qword ptr [RSI + RAX*0x8]
MOV qword ptr [RDI + RAX*0x8],R8
MOV qword ptr [RSI + RAX*0x8],RCX
INC RAX
CMP RDX,RAX
JNZ 0x0011c5b4
LAB_0011c5cc:
RET
|
void exchange_int64s(long param_1,long param_2,ulong param_3)
{
int8 uVar1;
ulong uVar2;
if (7 < param_3) {
uVar2 = 0;
do {
uVar1 = *(int8 *)(param_1 + uVar2 * 8);
*(int8 *)(param_1 + uVar2 * 8) = *(int8 *)(param_2 + uVar2 * 8);
*(int8 *)(param_2 + uVar2 * 8) = uVar1;
uVar2 = uVar2 + 1;
} while (param_3 >> 3 != uVar2);
}
return;
}
| |
38,058 | lshift | eloqsql/libmariadb/libmariadb/ma_dtoa.c | static Bigint *lshift(Bigint *b, int k, Stack_alloc *alloc)
{
int i, k1, n, n1;
Bigint *b1;
ULong *x, *x1, *xe, z;
n= k >> 5;
k1= b->k;
n1= n + b->wds + 1;
for (i= b->maxwds; n1 > i; i<<= 1)
k1++;
b1= Balloc(k1, alloc);
x1= b1->p.x;
for (i= 0; i < n; i++)
*x1++= 0;
x= b->p.x;
xe= x + b->wds;
if (k&= 0x1f)
{
k1= 32 - k;
z= 0;
do
{
*x1++= *x << k | z;
z= *x++ >> k1;
}
while (x < xe);
if ((*x1= z))
++n1;
}
else
do
*x1++= *x++;
while (x < xe);
b1->wds= n1 - 1;
Bfree(b, alloc);
return b1;
} | O0 | c | lshift:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movl -0xc(%rbp), %eax
sarl $0x5, %eax
movl %eax, -0x24(%rbp)
movq -0x8(%rbp), %rax
movl 0x8(%rax), %eax
movl %eax, -0x20(%rbp)
movl -0x24(%rbp), %eax
movq -0x8(%rbp), %rcx
addl 0x14(%rcx), %eax
addl $0x1, %eax
movl %eax, -0x28(%rbp)
movq -0x8(%rbp), %rax
movl 0xc(%rax), %eax
movl %eax, -0x1c(%rbp)
movl -0x28(%rbp), %eax
cmpl -0x1c(%rbp), %eax
jle 0xbd27b
movl -0x20(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x20(%rbp)
movl -0x1c(%rbp), %eax
shll %eax
movl %eax, -0x1c(%rbp)
jmp 0xbd260
movl -0x20(%rbp), %edi
movq -0x18(%rbp), %rsi
callq 0xbd5d0
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x40(%rbp)
movl $0x0, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
cmpl -0x24(%rbp), %eax
jge 0xbd2c5
movq -0x40(%rbp), %rax
movq %rax, %rcx
addq $0x4, %rcx
movq %rcx, -0x40(%rbp)
movl $0x0, (%rax)
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0xbd29d
movq -0x8(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x38(%rbp)
movq -0x38(%rbp), %rax
movq -0x8(%rbp), %rcx
movslq 0x14(%rcx), %rcx
shlq $0x2, %rcx
addq %rcx, %rax
movq %rax, -0x48(%rbp)
movl -0xc(%rbp), %eax
andl $0x1f, %eax
movl %eax, -0xc(%rbp)
cmpl $0x0, %eax
je 0xbd364
movl $0x20, %eax
subl -0xc(%rbp), %eax
movl %eax, -0x20(%rbp)
movl $0x0, -0x4c(%rbp)
movq -0x38(%rbp), %rax
movl (%rax), %eax
movl -0xc(%rbp), %ecx
shll %cl, %eax
movl %eax, %ecx
orl -0x4c(%rbp), %ecx
movq -0x40(%rbp), %rax
movq %rax, %rdx
addq $0x4, %rdx
movq %rdx, -0x40(%rbp)
movl %ecx, (%rax)
movq -0x38(%rbp), %rax
movq %rax, %rcx
addq $0x4, %rcx
movq %rcx, -0x38(%rbp)
movl (%rax), %eax
movl -0x20(%rbp), %ecx
shrl %cl, %eax
movl %eax, -0x4c(%rbp)
movq -0x38(%rbp), %rax
cmpq -0x48(%rbp), %rax
jb 0xbd307
movl -0x4c(%rbp), %eax
movq -0x40(%rbp), %rcx
movl %eax, (%rcx)
cmpl $0x0, %eax
je 0xbd362
movl -0x28(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x28(%rbp)
jmp 0xbd394
jmp 0xbd366
movq -0x38(%rbp), %rax
movq %rax, %rcx
addq $0x4, %rcx
movq %rcx, -0x38(%rbp)
movl (%rax), %ecx
movq -0x40(%rbp), %rax
movq %rax, %rdx
addq $0x4, %rdx
movq %rdx, -0x40(%rbp)
movl %ecx, (%rax)
movq -0x38(%rbp), %rax
cmpq -0x48(%rbp), %rax
jb 0xbd366
jmp 0xbd394
movl -0x28(%rbp), %ecx
subl $0x1, %ecx
movq -0x30(%rbp), %rax
movl %ecx, 0x14(%rax)
movq -0x8(%rbp), %rdi
movq -0x18(%rbp), %rsi
callq 0xbd0d0
movq -0x30(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax,%rax)
| lshift:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov [rbp+var_18], rdx
mov eax, [rbp+var_C]
sar eax, 5
mov [rbp+var_24], eax
mov rax, [rbp+var_8]
mov eax, [rax+8]
mov [rbp+var_20], eax
mov eax, [rbp+var_24]
mov rcx, [rbp+var_8]
add eax, [rcx+14h]
add eax, 1
mov [rbp+var_28], eax
mov rax, [rbp+var_8]
mov eax, [rax+0Ch]
mov [rbp+var_1C], eax
loc_BD260:
mov eax, [rbp+var_28]
cmp eax, [rbp+var_1C]
jle short loc_BD27B
mov eax, [rbp+var_20]
add eax, 1
mov [rbp+var_20], eax
mov eax, [rbp+var_1C]
shl eax, 1
mov [rbp+var_1C], eax
jmp short loc_BD260
loc_BD27B:
mov edi, [rbp+var_20]
mov rsi, [rbp+var_18]
call Balloc
mov [rbp+var_30], rax
mov rax, [rbp+var_30]
mov rax, [rax]
mov [rbp+var_40], rax
mov [rbp+var_1C], 0
loc_BD29D:
mov eax, [rbp+var_1C]
cmp eax, [rbp+var_24]
jge short loc_BD2C5
mov rax, [rbp+var_40]
mov rcx, rax
add rcx, 4
mov [rbp+var_40], rcx
mov dword ptr [rax], 0
mov eax, [rbp+var_1C]
add eax, 1
mov [rbp+var_1C], eax
jmp short loc_BD29D
loc_BD2C5:
mov rax, [rbp+var_8]
mov rax, [rax]
mov [rbp+var_38], rax
mov rax, [rbp+var_38]
mov rcx, [rbp+var_8]
movsxd rcx, dword ptr [rcx+14h]
shl rcx, 2
add rax, rcx
mov [rbp+var_48], rax
mov eax, [rbp+var_C]
and eax, 1Fh
mov [rbp+var_C], eax
cmp eax, 0
jz short loc_BD364
mov eax, 20h ; ' '
sub eax, [rbp+var_C]
mov [rbp+var_20], eax
mov [rbp+var_4C], 0
loc_BD307:
mov rax, [rbp+var_38]
mov eax, [rax]
mov ecx, [rbp+var_C]
shl eax, cl
mov ecx, eax
or ecx, [rbp+var_4C]
mov rax, [rbp+var_40]
mov rdx, rax
add rdx, 4
mov [rbp+var_40], rdx
mov [rax], ecx
mov rax, [rbp+var_38]
mov rcx, rax
add rcx, 4
mov [rbp+var_38], rcx
mov eax, [rax]
mov ecx, [rbp+var_20]
shr eax, cl
mov [rbp+var_4C], eax
mov rax, [rbp+var_38]
cmp rax, [rbp+var_48]
jb short loc_BD307
mov eax, [rbp+var_4C]
mov rcx, [rbp+var_40]
mov [rcx], eax
cmp eax, 0
jz short loc_BD362
mov eax, [rbp+var_28]
add eax, 1
mov [rbp+var_28], eax
loc_BD362:
jmp short loc_BD394
loc_BD364:
jmp short $+2
loc_BD366:
mov rax, [rbp+var_38]
mov rcx, rax
add rcx, 4
mov [rbp+var_38], rcx
mov ecx, [rax]
mov rax, [rbp+var_40]
mov rdx, rax
add rdx, 4
mov [rbp+var_40], rdx
mov [rax], ecx
mov rax, [rbp+var_38]
cmp rax, [rbp+var_48]
jb short loc_BD366
jmp short $+2
loc_BD394:
mov ecx, [rbp+var_28]
sub ecx, 1
mov rax, [rbp+var_30]
mov [rax+14h], ecx
mov rdi, [rbp+var_8]
mov rsi, [rbp+var_18]
call Bfree
mov rax, [rbp+var_30]
add rsp, 50h
pop rbp
retn
| long long lshift(unsigned long long a1, int a2, unsigned long long *a3)
{
int *v3; // rax
int *v4; // rax
int *v5; // rax
int *v6; // rax
int v7; // ecx
int *v8; // rax
int v10; // [rsp+4h] [rbp-4Ch]
unsigned long long v11; // [rsp+8h] [rbp-48h]
int *v12; // [rsp+10h] [rbp-40h]
int *v13; // [rsp+18h] [rbp-38h]
long long v14; // [rsp+20h] [rbp-30h]
int v15; // [rsp+28h] [rbp-28h]
unsigned int v16; // [rsp+30h] [rbp-20h]
int i; // [rsp+34h] [rbp-1Ch]
int j; // [rsp+34h] [rbp-1Ch]
char v20; // [rsp+44h] [rbp-Ch]
v16 = *(_DWORD *)(a1 + 8);
v15 = *(_DWORD *)(a1 + 20) + (a2 >> 5) + 1;
for ( i = *(_DWORD *)(a1 + 12); v15 > i; i *= 2 )
++v16;
v14 = Balloc(v16, a3);
v12 = *(int **)v14;
for ( j = 0; j < a2 >> 5; ++j )
{
v3 = v12++;
*v3 = 0;
}
v13 = *(int **)a1;
v11 = 4LL * *(int *)(a1 + 20) + *(_QWORD *)a1;
v20 = a2 & 0x1F;
if ( (a2 & 0x1F) != 0 )
{
v10 = 0;
do
{
v4 = v12++;
*v4 = v10 | (*v13 << v20);
v5 = v13++;
v10 = (unsigned int)*v5 >> (32 - v20);
}
while ( (unsigned long long)v13 < v11 );
*v12 = v10;
if ( v10 )
++v15;
}
else
{
do
{
v6 = v13++;
v7 = *v6;
v8 = v12++;
*v8 = v7;
}
while ( (unsigned long long)v13 < v11 );
}
*(_DWORD *)(v14 + 20) = v15 - 1;
Bfree(a1, a3);
return v14;
}
| lshift:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],ESI
MOV qword ptr [RBP + -0x18],RDX
MOV EAX,dword ptr [RBP + -0xc]
SAR EAX,0x5
MOV dword ptr [RBP + -0x24],EAX
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0x8]
MOV dword ptr [RBP + -0x20],EAX
MOV EAX,dword ptr [RBP + -0x24]
MOV RCX,qword ptr [RBP + -0x8]
ADD EAX,dword ptr [RCX + 0x14]
ADD EAX,0x1
MOV dword ptr [RBP + -0x28],EAX
MOV RAX,qword ptr [RBP + -0x8]
MOV EAX,dword ptr [RAX + 0xc]
MOV dword ptr [RBP + -0x1c],EAX
LAB_001bd260:
MOV EAX,dword ptr [RBP + -0x28]
CMP EAX,dword ptr [RBP + -0x1c]
JLE 0x001bd27b
MOV EAX,dword ptr [RBP + -0x20]
ADD EAX,0x1
MOV dword ptr [RBP + -0x20],EAX
MOV EAX,dword ptr [RBP + -0x1c]
SHL EAX,0x1
MOV dword ptr [RBP + -0x1c],EAX
JMP 0x001bd260
LAB_001bd27b:
MOV EDI,dword ptr [RBP + -0x20]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x001bd5d0
MOV qword ptr [RBP + -0x30],RAX
MOV RAX,qword ptr [RBP + -0x30]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x40],RAX
MOV dword ptr [RBP + -0x1c],0x0
LAB_001bd29d:
MOV EAX,dword ptr [RBP + -0x1c]
CMP EAX,dword ptr [RBP + -0x24]
JGE 0x001bd2c5
MOV RAX,qword ptr [RBP + -0x40]
MOV RCX,RAX
ADD RCX,0x4
MOV qword ptr [RBP + -0x40],RCX
MOV dword ptr [RAX],0x0
MOV EAX,dword ptr [RBP + -0x1c]
ADD EAX,0x1
MOV dword ptr [RBP + -0x1c],EAX
JMP 0x001bd29d
LAB_001bd2c5:
MOV RAX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV RCX,qword ptr [RBP + -0x8]
MOVSXD RCX,dword ptr [RCX + 0x14]
SHL RCX,0x2
ADD RAX,RCX
MOV qword ptr [RBP + -0x48],RAX
MOV EAX,dword ptr [RBP + -0xc]
AND EAX,0x1f
MOV dword ptr [RBP + -0xc],EAX
CMP EAX,0x0
JZ 0x001bd364
MOV EAX,0x20
SUB EAX,dword ptr [RBP + -0xc]
MOV dword ptr [RBP + -0x20],EAX
MOV dword ptr [RBP + -0x4c],0x0
LAB_001bd307:
MOV RAX,qword ptr [RBP + -0x38]
MOV EAX,dword ptr [RAX]
MOV ECX,dword ptr [RBP + -0xc]
SHL EAX,CL
MOV ECX,EAX
OR ECX,dword ptr [RBP + -0x4c]
MOV RAX,qword ptr [RBP + -0x40]
MOV RDX,RAX
ADD RDX,0x4
MOV qword ptr [RBP + -0x40],RDX
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RBP + -0x38]
MOV RCX,RAX
ADD RCX,0x4
MOV qword ptr [RBP + -0x38],RCX
MOV EAX,dword ptr [RAX]
MOV ECX,dword ptr [RBP + -0x20]
SHR EAX,CL
MOV dword ptr [RBP + -0x4c],EAX
MOV RAX,qword ptr [RBP + -0x38]
CMP RAX,qword ptr [RBP + -0x48]
JC 0x001bd307
MOV EAX,dword ptr [RBP + -0x4c]
MOV RCX,qword ptr [RBP + -0x40]
MOV dword ptr [RCX],EAX
CMP EAX,0x0
JZ 0x001bd362
MOV EAX,dword ptr [RBP + -0x28]
ADD EAX,0x1
MOV dword ptr [RBP + -0x28],EAX
LAB_001bd362:
JMP 0x001bd394
LAB_001bd364:
JMP 0x001bd366
LAB_001bd366:
MOV RAX,qword ptr [RBP + -0x38]
MOV RCX,RAX
ADD RCX,0x4
MOV qword ptr [RBP + -0x38],RCX
MOV ECX,dword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x40]
MOV RDX,RAX
ADD RDX,0x4
MOV qword ptr [RBP + -0x40],RDX
MOV dword ptr [RAX],ECX
MOV RAX,qword ptr [RBP + -0x38]
CMP RAX,qword ptr [RBP + -0x48]
JC 0x001bd366
JMP 0x001bd394
LAB_001bd394:
MOV ECX,dword ptr [RBP + -0x28]
SUB ECX,0x1
MOV RAX,qword ptr [RBP + -0x30]
MOV dword ptr [RAX + 0x14],ECX
MOV RDI,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RBP + -0x18]
CALL 0x001bd0d0
MOV RAX,qword ptr [RBP + -0x30]
ADD RSP,0x50
POP RBP
RET
|
int8 * lshift(int8 *param_1,uint param_2,int8 param_3)
{
sbyte sVar1;
int iVar2;
int8 *puVar3;
uint *puVar4;
uint *puVar5;
uint *puVar6;
uint local_54;
uint *local_48;
uint *local_40;
int local_30;
int local_28;
int local_24;
local_28 = *(int *)(param_1 + 1);
iVar2 = ((int)param_2 >> 5) + *(int *)((long)param_1 + 0x14);
local_30 = iVar2 + 1;
for (local_24 = *(int *)((long)param_1 + 0xc); local_24 < local_30; local_24 = local_24 << 1) {
local_28 = local_28 + 1;
}
puVar3 = (int8 *)Balloc(local_28,param_3);
local_48 = (uint *)*puVar3;
for (local_24 = 0; local_24 < (int)param_2 >> 5; local_24 = local_24 + 1) {
*local_48 = 0;
local_48 = local_48 + 1;
}
local_40 = (uint *)*param_1;
puVar4 = local_40 + *(int *)((long)param_1 + 0x14);
if ((param_2 & 0x1f) == 0) {
do {
puVar5 = local_40 + 1;
*local_48 = *local_40;
local_48 = local_48 + 1;
local_40 = puVar5;
} while (puVar5 < puVar4);
}
else {
sVar1 = (sbyte)(param_2 & 0x1f);
local_54 = 0;
do {
puVar6 = local_48 + 1;
*local_48 = *local_40 << sVar1 | local_54;
puVar5 = local_40 + 1;
local_54 = *local_40 >> (0x20U - sVar1 & 0x1f);
local_48 = puVar6;
local_40 = puVar5;
} while (puVar5 < puVar4);
*puVar6 = local_54;
if (local_54 != 0) {
local_30 = iVar2 + 2;
}
}
*(int *)((long)puVar3 + 0x14) = local_30 + -1;
Bfree(param_1,param_3);
return puVar3;
}
| |
38,059 | common_arg::common_arg(std::initializer_list<char const*> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, void (*)(common_params&)) | monkey531[P]llama/common/arg.h | common_arg(
const std::initializer_list<const char *> & args,
const std::string & help,
void (*handler)(common_params & params)
) : args(args), help(help), handler_void(handler) {} | O1 | c | common_arg::common_arg(std::initializer_list<char const*> const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, void (*)(common_params&)):
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r13
movq %rdi, %rbx
leaq 0xc(%rsp), %rsi
movl $0x0, (%rsi)
leaq 0xb(%rsp), %rcx
leaq 0xa(%rsp), %r8
movl $0x1, %edx
callq 0x8865a
leaq 0x38(%rbx), %rax
xorps %xmm0, %xmm0
movups %xmm0, 0x40(%rbx)
movups %xmm0, 0x50(%rbx)
movups %xmm0, 0x30(%rbx)
movq %rax, 0x48(%rbx)
movq %rax, 0x50(%rbx)
movq $0x0, 0x58(%rbx)
leaq 0x60(%rbx), %r12
movq (%r13), %rsi
movq 0x8(%r13), %rdx
leaq 0x9(%rsp), %rcx
movq %r12, %rdi
callq 0x886dc
leaq 0x90(%rbx), %rdi
leaq 0xa0(%rbx), %rax
xorps %xmm0, %xmm0
movups %xmm0, 0x78(%rbx)
movq $0x0, 0x88(%rbx)
movq %rax, 0x90(%rbx)
movq (%r15), %rsi
movq 0x8(%r15), %rdx
addq %rsi, %rdx
callq 0x2665e
movb $0x0, 0xb0(%rbx)
movq %r14, 0xb8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0xc0(%rbx)
movq $0x0, 0xd0(%rbx)
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
movq %rax, %r14
movq (%r12), %rdi
testq %rdi, %rdi
je 0x85342
movq 0x70(%rbx), %rsi
subq %rdi, %rsi
callq 0x1dc40
jmp 0x85342
movq %rax, %r14
leaq 0x30(%rbx), %rdi
callq 0x88722
movq %rbx, %rdi
callq 0x88722
movq %r14, %rdi
callq 0x1e650
nop
| _ZN10common_argC2ERKSt16initializer_listIPKcERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPFvR13common_paramsE:
push r15
push r14
push r13
push r12
push rbx
sub rsp, 10h
mov r14, rcx
mov r15, rdx
mov r13, rsi
mov rbx, rdi
lea rsi, [rsp+38h+var_2C]
mov dword ptr [rsi], 0
lea rcx, [rsp+38h+var_2D]
lea r8, [rsp+38h+var_2E]
mov edx, 1
call _ZNSt3setI13llama_exampleSt4lessIS0_ESaIS0_EEC2ESt16initializer_listIS0_ERKS2_RKS3_; std::set<llama_example>::set(std::initializer_list<llama_example>,std::less<llama_example> const&,std::allocator<llama_example> const&)
lea rax, [rbx+38h]
xorps xmm0, xmm0
movups xmmword ptr [rbx+40h], xmm0
movups xmmword ptr [rbx+50h], xmm0
movups xmmword ptr [rbx+30h], xmm0
mov [rbx+48h], rax
mov [rbx+50h], rax
mov qword ptr [rbx+58h], 0
lea r12, [rbx+60h]
mov rsi, [r13+0]
mov rdx, [r13+8]
lea rcx, [rsp+38h+var_2F]
mov rdi, r12
call _ZNSt6vectorIPKcSaIS1_EEC2ESt16initializer_listIS1_ERKS2_; std::vector<char const*>::vector(std::initializer_list<char const*>,std::allocator<char const*> const&)
lea rdi, [rbx+90h]
lea rax, [rbx+0A0h]
xorps xmm0, xmm0
movups xmmword ptr [rbx+78h], xmm0
mov qword ptr [rbx+88h], 0
mov [rbx+90h], rax
mov rsi, [r15]
mov rdx, [r15+8]
add rdx, rsi
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag)
mov byte ptr [rbx+0B0h], 0
mov [rbx+0B8h], r14
xorps xmm0, xmm0
movups xmmword ptr [rbx+0C0h], xmm0
mov qword ptr [rbx+0D0h], 0
add rsp, 10h
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
mov r14, rax
mov rdi, [r12]; void *
test rdi, rdi
jz short loc_85342
mov rsi, [rbx+70h]
sub rsi, rdi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_85342
mov r14, rax
loc_85342:
lea rdi, [rbx+30h]
call _ZNSt8_Rb_treeI13llama_exampleS0_St9_IdentityIS0_ESt4lessIS0_ESaIS0_EED2Ev; std::_Rb_tree<llama_example,llama_example,std::_Identity<llama_example>,std::less<llama_example>,std::allocator<llama_example>>::~_Rb_tree()
mov rdi, rbx
call _ZNSt8_Rb_treeI13llama_exampleS0_St9_IdentityIS0_ESt4lessIS0_ESaIS0_EED2Ev; std::_Rb_tree<llama_example,llama_example,std::_Identity<llama_example>,std::less<llama_example>,std::allocator<llama_example>>::~_Rb_tree()
mov rdi, r14
call __Unwind_Resume
| long long common_arg::common_arg(long long a1, _QWORD *a2, long long a3, long long a4)
{
long long result; // rax
char v7; // [rsp+9h] [rbp-2Fh] BYREF
char v8; // [rsp+Ah] [rbp-2Eh] BYREF
char v9; // [rsp+Bh] [rbp-2Dh] BYREF
_DWORD v10[11]; // [rsp+Ch] [rbp-2Ch] BYREF
v10[0] = 0;
std::set<llama_example>::set(a1, v10, 1LL, &v9, &v8);
*(_OWORD *)(a1 + 64) = 0LL;
*(_OWORD *)(a1 + 80) = 0LL;
*(_OWORD *)(a1 + 48) = 0LL;
*(_QWORD *)(a1 + 72) = a1 + 56;
*(_QWORD *)(a1 + 80) = a1 + 56;
*(_QWORD *)(a1 + 88) = 0LL;
std::vector<char const*>::vector(a1 + 96, *a2, a2[1], &v7);
*(_OWORD *)(a1 + 120) = 0LL;
*(_QWORD *)(a1 + 136) = 0LL;
*(_QWORD *)(a1 + 144) = a1 + 160;
result = std::string::_M_construct<char *>((_QWORD *)(a1 + 144), *(_BYTE **)a3, *(_QWORD *)a3 + *(_QWORD *)(a3 + 8));
*(_BYTE *)(a1 + 176) = 0;
*(_QWORD *)(a1 + 184) = a4;
*(_OWORD *)(a1 + 192) = 0LL;
*(_QWORD *)(a1 + 208) = 0LL;
return result;
}
| common_arg:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x10
MOV R14,RCX
MOV R15,RDX
MOV R13,RSI
MOV RBX,RDI
LEA RSI,[RSP + 0xc]
MOV dword ptr [RSI],0x0
LEA RCX,[RSP + 0xb]
LEA R8,[RSP + 0xa]
MOV EDX,0x1
CALL 0x0018865a
LEA RAX,[RBX + 0x38]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x40],XMM0
MOVUPS xmmword ptr [RBX + 0x50],XMM0
MOVUPS xmmword ptr [RBX + 0x30],XMM0
MOV qword ptr [RBX + 0x48],RAX
MOV qword ptr [RBX + 0x50],RAX
MOV qword ptr [RBX + 0x58],0x0
LEA R12,[RBX + 0x60]
MOV RSI,qword ptr [R13]
MOV RDX,qword ptr [R13 + 0x8]
LAB_001852b1:
LEA RCX,[RSP + 0x9]
MOV RDI,R12
CALL 0x001886dc
LEA RDI,[RBX + 0x90]
LEA RAX,[RBX + 0xa0]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0x78],XMM0
MOV qword ptr [RBX + 0x88],0x0
MOV qword ptr [RBX + 0x90],RAX
MOV RSI,qword ptr [R15]
MOV RDX,qword ptr [R15 + 0x8]
ADD RDX,RSI
LAB_001852ef:
CALL 0x0012665e
LAB_001852f4:
MOV byte ptr [RBX + 0xb0],0x0
MOV qword ptr [RBX + 0xb8],R14
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RBX + 0xc0],XMM0
MOV qword ptr [RBX + 0xd0],0x0
ADD RSP,0x10
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
/* common_arg::common_arg(std::initializer_list<char const*> const&, std::__cxx11::string const&,
void (*)(common_params&)) */
void __thiscall
common_arg::common_arg
(common_arg *this,initializer_list *param_1,string *param_2,
_func_void_common_params_ptr *param_3)
{
int1 local_2f;
int1 local_2e;
int1 local_2d;
int4 local_2c;
local_2c = 0;
std::set<llama_example,std::less<llama_example>,std::allocator<llama_example>>::set
(this,&local_2c,1,&local_2d,&local_2e);
*(int8 *)(this + 0x40) = 0;
*(int8 *)(this + 0x48) = 0;
*(int8 *)(this + 0x50) = 0;
*(int8 *)(this + 0x58) = 0;
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(common_arg **)(this + 0x48) = this + 0x38;
*(common_arg **)(this + 0x50) = this + 0x38;
*(int8 *)(this + 0x58) = 0;
/* try { // try from 001852b1 to 001852bd has its CatchHandler @ 0018533f */
std::vector<char_const*,std::allocator<char_const*>>::vector
((vector<char_const*,std::allocator<char_const*>> *)(this + 0x60),*(int8 *)param_1
,*(int8 *)(param_1 + 8),&local_2f);
*(int8 *)(this + 0x78) = 0;
*(int8 *)(this + 0x80) = 0;
*(int8 *)(this + 0x88) = 0;
*(common_arg **)(this + 0x90) = this + 0xa0;
/* try { // try from 001852ef to 001852f3 has its CatchHandler @ 00185325 */
std::__cxx11::string::_M_construct<char*>
(this + 0x90,*(long *)param_2,*(long *)(param_2 + 8) + *(long *)param_2);
this[0xb0] = (common_arg)0x0;
*(_func_void_common_params_ptr **)(this + 0xb8) = param_3;
*(int8 *)(this + 0xc0) = 0;
*(int8 *)(this + 200) = 0;
*(int8 *)(this + 0xd0) = 0;
return;
}
| |
38,060 | std::pair<__gnu_cxx::__normal_iterator<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>*, std::vector<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>, 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>>>>, bool> 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>>>::emplace<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, 0>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, minja::Value&&) | monkey531[P]llama/common/json.hpp | std::pair<iterator, bool> emplace(KeyType && key, T && t)
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
return {it, false};
}
}
Container::emplace_back(std::forward<KeyType>(key), std::forward<T>(t));
return {std::prev(this->end()), true};
} | O0 | cpp | std::pair<__gnu_cxx::__normal_iterator<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>*, std::vector<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>, 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>>>>, bool> 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>>>::emplace<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, 0>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, minja::Value&&):
subq $0x68, %rsp
movq %rdi, 0x50(%rsp)
movq %rsi, 0x48(%rsp)
movq %rdx, 0x40(%rsp)
movq 0x50(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x116e20
movq %rax, 0x38(%rsp)
movq 0x8(%rsp), %rdi
callq 0x116e90
movq %rax, 0x30(%rsp)
leaq 0x38(%rsp), %rdi
leaq 0x30(%rsp), %rsi
callq 0x116e50
testb $0x1, %al
jne 0x1236bb
jmp 0x123712
movq 0x8(%rsp), %rax
addq $0x18, %rax
movq %rax, (%rsp)
leaq 0x38(%rsp), %rdi
callq 0x116ec0
movq (%rsp), %rdi
movq %rax, %rsi
movq 0x48(%rsp), %rdx
callq 0x123770
testb $0x1, %al
jne 0x1236e9
jmp 0x123704
movb $0x0, 0x2f(%rsp)
leaq 0x58(%rsp), %rdi
leaq 0x38(%rsp), %rsi
leaq 0x2f(%rsp), %rdx
callq 0x1237d0
jmp 0x123762
jmp 0x123706
leaq 0x38(%rsp), %rdi
callq 0x117210
jmp 0x123697
movq 0x8(%rsp), %rdi
movq 0x48(%rsp), %rsi
movq 0x40(%rsp), %rdx
callq 0x123800
movq 0x8(%rsp), %rdi
callq 0x116e90
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rdi
movl $0x1, %esi
callq 0x123890
movq %rax, 0x20(%rsp)
movb $0x1, 0x17(%rsp)
leaq 0x58(%rsp), %rdi
leaq 0x20(%rsp), %rsi
leaq 0x17(%rsp), %rdx
callq 0x1238d0
movq 0x58(%rsp), %rax
movb 0x60(%rsp), %dl
addq $0x68, %rsp
retq
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE7emplaceIRKS9_TnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvESD_T_EE5valueEiE4typeELi0EEESI_IN9__gnu_cxx17__normal_iteratorIPSK_S3_ISK_SL_EEEbEOST_OSF_:
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 _ZNSt6vectorISt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES_IhSaIhEEvEEN5minja5ValueEESaISI_EE5beginEv; 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>>::begin(void)
mov [rsp+68h+var_30], rax
loc_123697:
mov rdi, [rsp+68h+var_60]
call _ZNSt6vectorISt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES_IhSaIhEEvEEN5minja5ValueEESaISI_EE3endEv; 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>>::end(void)
mov [rsp+68h+var_38], rax
lea rdi, [rsp+68h+var_30]
lea rsi, [rsp+68h+var_38]
call _ZN9__gnu_cxxneIPSt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEN5minja5ValueEES6_ISK_SaISK_EEEEbRKNS_17__normal_iteratorIT_T0_EEST_; __gnu_cxx::operator!=<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> *,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>>>(__gnu_cxx::__normal_iterator<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> *,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>>> const&,__gnu_cxx::__normal_iterator<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> *,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>>> const&)
test al, 1
jnz short loc_1236BB
jmp short loc_123712
loc_1236BB:
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_iteratorIPSt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEN5minja5ValueEES6_ISK_SaISK_EEEptEv; __gnu_cxx::__normal_iterator<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> *,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>>>::operator->(void)
mov rdi, [rsp+68h+var_68]
mov rsi, rax
mov rdx, [rsp+68h+var_20]
call _ZNKSt8equal_toIvEclIRKN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEERKSC_EEDTeqclsr3stdE7forwardIT_Efp_Eclsr3stdE7forwardIT0_Efp0_EEOSL_OSM_
test al, 1
jnz short loc_1236E9
jmp short loc_123704
loc_1236E9:
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_IKN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEN5minja5ValueEES6_ISK_SaISK_EEEEbEC2IRSO_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIST_SU_EEEbE4typeELb1EEEOST_OSU_
jmp short loc_123762
loc_123704:
jmp short $+2
loc_123706:
lea rdi, [rsp+68h+var_30]
call _ZN9__gnu_cxx17__normal_iteratorIPSt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEN5minja5ValueEES6_ISK_SaISK_EEEppEv; __gnu_cxx::__normal_iterator<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> *,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>>>::operator++(void)
jmp short loc_123697
loc_123712:
mov rdi, [rsp+68h+var_60]
mov rsi, [rsp+68h+var_20]
mov rdx, [rsp+68h+var_28]
call _ZNSt6vectorISt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES_IhSaIhEEvEEN5minja5ValueEESaISI_EE12emplace_backIJRKSA_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<std::string const&,minja::Value>(std::string const&,minja::Value &&)
mov rdi, [rsp+68h+var_60]
call _ZNSt6vectorISt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES_IhSaIhEEvEEN5minja5ValueEESaISI_EE3endEv; 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>>::end(void)
mov [rsp+68h+var_50], rax
mov rdi, [rsp+68h+var_50]
mov esi, 1
call _ZSt4prevIN9__gnu_cxx17__normal_iteratorIPSt4pairIKN8nlohmann16json_abi_v3_11_310basic_jsonINS4_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS4_14adl_serializerES7_IhSaIhEEvEEN5minja5ValueEES7_ISL_SaISL_EEEEET_SQ_NSt15iterator_traitsISQ_E15difference_typeE; std::prev<__gnu_cxx::__normal_iterator<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> *,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>>>>(__gnu_cxx::__normal_iterator<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> *,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>>>,std::iterator_traits<__gnu_cxx::__normal_iterator<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> *,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>>>>::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_IKN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEN5minja5ValueEES6_ISK_SaISK_EEEEbEC2ISO_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISS_ST_EEEbE4typeELb1EEEOSS_OST_
loc_123762:
mov rax, [rsp+68h+var_10]
mov dl, [rsp+68h+var_8]
add rsp, 68h
retn
| long long ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE7emplaceIRKS9_TnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvESD_T_EE5valueEiE4typeELi0EEESI_IN9__gnu_cxx17__normal_iteratorIPSK_S3_ISK_SL_EEEbEOST_OSF_(
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<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>>::begin(a1);
;
__gnu_cxx::__normal_iterator<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> *,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>>>::operator++(&i) )
{
v9 = 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>>::end(a1);
if ( !__gnu_cxx::operator!=<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> *,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>>>(
(long long)&i,
(long long)&v9) )
break;
v3 = __gnu_cxx::__normal_iterator<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> *,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>>>::operator->((long long)&i);
if ( (std::equal_to<void>::operator()<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const&,std::string const&>(
a1 + 24,
v3,
v12) & 1) != 0 )
{
v8 = 0;
ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEN5minja5ValueEES6_ISK_SaISK_EEEEbEC2IRSO_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairIST_SU_EEEbE4typeELb1EEEOST_OSU_(
&v14,
&i,
&v8);
return v14;
}
}
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<std::string const&,minja::Value>(
a1,
v12,
v11);
v6 = 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>>::end(a1);
v7 = std::prev<__gnu_cxx::__normal_iterator<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> *,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>>>>(
v6,
1LL);
v5 = 1;
ZNSt4pairIN9__gnu_cxx17__normal_iteratorIPS_IKN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEEN5minja5ValueEES6_ISK_SaISK_EEEEbEC2ISO_bTnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISS_ST_EEEbE4typeELb1EEEOSS_OST_(
&v14,
&v7,
&v5);
return v14;
}
| |||
38,061 | std::pair<__gnu_cxx::__normal_iterator<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>*, std::vector<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>, 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>>>>, bool> 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>>>::emplace<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, 0>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, minja::Value&&) | monkey531[P]llama/common/json.hpp | std::pair<iterator, bool> emplace(KeyType && key, T && t)
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
return {it, false};
}
}
Container::emplace_back(std::forward<KeyType>(key), std::forward<T>(t));
return {std::prev(this->end()), true};
} | O2 | cpp | std::pair<__gnu_cxx::__normal_iterator<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>*, std::vector<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>, 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>>>>, bool> 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>>>::emplace<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, 0>(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, minja::Value&&):
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %r14
movq (%rdi), %rbx
leaq 0x18(%rdi), %r13
cmpq 0x8(%r14), %rbx
je 0x68c8f
movq %r13, %rdi
movq %rbx, %rsi
movq %r12, %rdx
callq 0x68cb8
testb %al, %al
jne 0x68ca9
addq $0x60, %rbx
jmp 0x68c71
movq %r14, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq 0x68cf2
movq 0x8(%r14), %rbx
addq $-0x60, %rbx
movb $0x1, %dl
jmp 0x68cab
xorl %edx, %edx
movq %rbx, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE7emplaceIRKS9_TnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvESD_T_EE5valueEiE4typeELi0EEESI_IN9__gnu_cxx17__normal_iteratorIPSK_S3_ISK_SL_EEEbEOST_OSF_:
push r15
push r14
push r13
push r12
push rbx
mov r15, rdx
mov r12, rsi
mov r14, rdi
mov rbx, [rdi]
lea r13, [rdi+18h]
loc_68C71:
cmp rbx, [r14+8]
jz short loc_68C8F
mov rdi, r13
mov rsi, rbx
mov rdx, r12
call _ZNKSt8equal_toIvEclIRKN8nlohmann16json_abi_v3_11_310basic_jsonINS3_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS3_14adl_serializerES6_IhSaIhEEvEERKSC_EEDTeqclsr3stdE7forwardIT_Efp_Eclsr3stdE7forwardIT0_Efp0_EEOSL_OSM_
test al, al
jnz short loc_68CA9
add rbx, 60h ; '`'
jmp short loc_68C71
loc_68C8F:
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_backIJRKSA_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<std::string const&,minja::Value>(std::string const&,minja::Value &&)
mov rbx, [r14+8]
add rbx, 0FFFFFFFFFFFFFFA0h
mov dl, 1
jmp short loc_68CAB
loc_68CA9:
xor edx, edx
loc_68CAB:
mov rax, rbx
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
| long long ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE7emplaceIRKS9_TnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvESD_T_EE5valueEiE4typeELi0EEESI_IN9__gnu_cxx17__normal_iteratorIPSK_S3_ISK_SL_EEEbEOST_OSF_(
long long *a1,
long long a2,
long long a3)
{
long long i; // rbx
for ( i = *a1; i != a1[1]; i += 96LL )
{
if ( (unsigned __int8)std::equal_to<void>::operator()<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const&,std::string const&>(
a1 + 3,
i,
a2) )
return i;
}
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<std::string const&,minja::Value>(
a1,
a2,
a3);
return a1[1] - 96;
}
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE7emplaceIRKS9_TnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvESD_T_EE5valueEiE4typeELi0EEESI_IN9__gnu_cxx17__normal_iteratorIPSK_S3_ISK_SL_EEEbEOST_OSF_:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV R15,RDX
MOV R12,RSI
MOV R14,RDI
MOV RBX,qword ptr [RDI]
LEA R13,[RDI + 0x18]
LAB_00168c71:
CMP RBX,qword ptr [R14 + 0x8]
JZ 0x00168c8f
MOV RDI,R13
MOV RSI,RBX
MOV RDX,R12
CALL 0x00168cb8
TEST AL,AL
JNZ 0x00168ca9
ADD RBX,0x60
JMP 0x00168c71
LAB_00168c8f:
MOV RDI,R14
MOV RSI,R12
MOV RDX,R15
CALL 0x00168cf2
MOV RBX,qword ptr [R14 + 0x8]
ADD RBX,-0x60
MOV DL,0x1
JMP 0x00168cab
LAB_00168ca9:
XOR EDX,EDX
LAB_00168cab:
MOV RAX,RBX
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
int1 [16]
_ZN8nlohmann16json_abi_v3_11_311ordered_mapINS0_10basic_jsonIS1_St6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEEN5minja5ValueESt4lessISD_ESaISt4pairIKSD_SF_EEE7emplaceIRKS9_TnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvESD_T_EE5valueEiE4typeELi0EEESI_IN9__gnu_cxx17__normal_iteratorIPSK_S3_ISK_SL_EEEbEOST_OSF_
(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>>>
*param_1,string *param_2,Value *param_3)
{
char cVar1;
int8 extraout_RDX;
int8 uVar2;
basic_json *pbVar3;
int1 auVar4 [16];
pbVar3 = *(basic_json **)param_1;
do {
if (pbVar3 == *(basic_json **)(param_1 + 8)) {
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<std::__cxx11::string_const&,minja::Value>(param_1,param_2,param_3);
pbVar3 = (basic_json *)(*(long *)(param_1 + 8) + -0x60);
uVar2 = CONCAT71((int7)((ulong)extraout_RDX >> 8),1);
LAB_00168cab:
auVar4._8_8_ = uVar2;
auVar4._0_8_ = pbVar3;
return auVar4;
}
cVar1 = std::equal_to<void>::operator()((equal_to<void> *)(param_1 + 0x18),pbVar3,param_2);
if (cVar1 != '\0') {
uVar2 = 0;
goto LAB_00168cab;
}
pbVar3 = pbVar3 + 0x60;
} while( true );
}
| |
38,062 | ma_ft_segiterator_dummy_init | eloqsql/storage/maria/ma_ft_update.c | void _ma_ft_segiterator_dummy_init(const uchar *record, uint len,
FT_SEG_ITERATOR *ftsi)
{
DBUG_ENTER("_ma_ft_segiterator_dummy_init");
ftsi->num=1;
ftsi->seg=0;
ftsi->pos=record;
ftsi->len=len;
DBUG_VOID_RETURN;
} | O0 | c | ma_ft_segiterator_dummy_init:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x18(%rbp), %rax
movl $0x1, (%rax)
movq -0x18(%rbp), %rax
movq $0x0, 0x8(%rax)
movq -0x8(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x18(%rax)
movl -0xc(%rbp), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x4(%rax)
jmp 0x8c52d
popq %rbp
retq
nop
| _ma_ft_segiterator_dummy_init:
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov [rbp+var_C], esi
mov [rbp+var_18], rdx
mov rax, [rbp+var_18]
mov dword ptr [rax], 1
mov rax, [rbp+var_18]
mov qword ptr [rax+8], 0
mov rcx, [rbp+var_8]
mov rax, [rbp+var_18]
mov [rax+18h], rcx
mov ecx, [rbp+var_C]
mov rax, [rbp+var_18]
mov [rax+4], ecx
jmp short $+2
loc_8C52D:
pop rbp
retn
| long long ma_ft_segiterator_dummy_init(long long a1, int a2, long long a3)
{
long long result; // rax
*(_DWORD *)a3 = 1;
*(_QWORD *)(a3 + 8) = 0LL;
*(_QWORD *)(a3 + 24) = a1;
result = a3;
*(_DWORD *)(a3 + 4) = a2;
return result;
}
| _ma_ft_segiterator_dummy_init:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV dword ptr [RBP + -0xc],ESI
MOV qword ptr [RBP + -0x18],RDX
MOV RAX,qword ptr [RBP + -0x18]
MOV dword ptr [RAX],0x1
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX + 0x8],0x0
MOV RCX,qword ptr [RBP + -0x8]
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RAX + 0x18],RCX
MOV ECX,dword ptr [RBP + -0xc]
MOV RAX,qword ptr [RBP + -0x18]
MOV dword ptr [RAX + 0x4],ECX
JMP 0x0018c52d
LAB_0018c52d:
POP RBP
RET
|
void _ma_ft_segiterator_dummy_init(int8 param_1,int4 param_2,int4 *param_3)
{
*param_3 = 1;
*(int8 *)(param_3 + 2) = 0;
*(int8 *)(param_3 + 6) = param_1;
param_3[1] = param_2;
return;
}
| |
38,063 | ma_rec_pos | eloqsql/storage/maria/ma_search.c | MARIA_RECORD_POS _ma_rec_pos(MARIA_SHARE *share, uchar *ptr)
{
my_off_t pos;
switch (share->rec_reflength) {
#if SIZEOF_OFF_T > 4
case 8:
pos= (my_off_t) mi_uint8korr(ptr);
if (pos == HA_OFFSET_ERROR)
return HA_OFFSET_ERROR; /* end of list */
break;
case 7:
pos= (my_off_t) mi_uint7korr(ptr);
if (pos == (((my_off_t) 1) << 56) -1)
return HA_OFFSET_ERROR; /* end of list */
break;
case 6:
pos= (my_off_t) mi_uint6korr(ptr);
if (pos == (((my_off_t) 1) << 48) -1)
return HA_OFFSET_ERROR; /* end of list */
break;
case 5:
pos= (my_off_t) mi_uint5korr(ptr);
if (pos == (((my_off_t) 1) << 40) -1)
return HA_OFFSET_ERROR; /* end of list */
break;
#else
case 8:
case 7:
case 6:
case 5:
ptr+= (share->rec_reflength-4);
/* fall through */
#endif
case 4:
pos= (my_off_t) mi_uint4korr(ptr);
if (pos == (my_off_t) (uint32) ~0L)
return HA_OFFSET_ERROR;
break;
case 3:
pos= (my_off_t) mi_uint3korr(ptr);
if (pos == (my_off_t) (1 << 24) -1)
return HA_OFFSET_ERROR;
break;
case 2:
pos= (my_off_t) mi_uint2korr(ptr);
if (pos == (my_off_t) (1 << 16) -1)
return HA_OFFSET_ERROR;
break;
default: abort(); /* Impossible */
}
return (*share->keypos_to_recpos)(share, pos);
} | O0 | c | ma_rec_pos:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movl 0x740(%rax), %eax
addl $-0x2, %eax
movl %eax, %ecx
movq %rcx, -0x28(%rbp)
subl $0x6, %eax
ja 0x97764
movq -0x28(%rbp), %rax
leaq 0xc328d(%rip), %rcx # 0x15a814
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq -0x18(%rbp), %rax
movzbl 0x7(%rax), %eax
movq -0x18(%rbp), %rcx
movzbl 0x6(%rcx), %ecx
shll $0x8, %ecx
orl %ecx, %eax
movq -0x18(%rbp), %rcx
movzbl 0x5(%rcx), %ecx
shll $0x10, %ecx
orl %ecx, %eax
movq -0x18(%rbp), %rcx
movzbl 0x4(%rcx), %ecx
shll $0x18, %ecx
orl %ecx, %eax
movl %eax, %eax
movq -0x18(%rbp), %rcx
movzbl 0x3(%rcx), %ecx
movq -0x18(%rbp), %rdx
movzbl 0x2(%rdx), %edx
shll $0x8, %edx
orl %edx, %ecx
movq -0x18(%rbp), %rdx
movzbl 0x1(%rdx), %edx
shll $0x10, %edx
orl %edx, %ecx
movq -0x18(%rbp), %rdx
movzbl (%rdx), %edx
shll $0x18, %edx
orl %edx, %ecx
movl %ecx, %ecx
shlq $0x20, %rcx
orq %rcx, %rax
movq %rax, -0x20(%rbp)
cmpq $-0x1, -0x20(%rbp)
jne 0x97610
movq $-0x1, -0x8(%rbp)
jmp 0x97782
jmp 0x97769
movq -0x18(%rbp), %rdi
callq 0x96fb0
movq %rax, -0x20(%rbp)
movabsq $0xffffffffffffff, %rax # imm = 0xFFFFFFFFFFFFFF
cmpq %rax, -0x20(%rbp)
jne 0x9763f
movq $-0x1, -0x8(%rbp)
jmp 0x97782
jmp 0x97769
movq -0x18(%rbp), %rdi
callq 0x97010
movq %rax, -0x20(%rbp)
movabsq $0xffffffffffff, %rax # imm = 0xFFFFFFFFFFFF
cmpq %rax, -0x20(%rbp)
jne 0x9766e
movq $-0x1, -0x8(%rbp)
jmp 0x97782
jmp 0x97769
movq -0x18(%rbp), %rdi
callq 0x97060
movq %rax, -0x20(%rbp)
movabsq $0xffffffffff, %rax # imm = 0xFFFFFFFFFF
cmpq %rax, -0x20(%rbp)
jne 0x9769d
movq $-0x1, -0x8(%rbp)
jmp 0x97782
jmp 0x97769
movq -0x18(%rbp), %rax
movzbl 0x3(%rax), %eax
movq -0x18(%rbp), %rcx
movzbl 0x2(%rcx), %ecx
shll $0x8, %ecx
orl %ecx, %eax
movq -0x18(%rbp), %rcx
movzbl 0x1(%rcx), %ecx
shll $0x10, %ecx
orl %ecx, %eax
movq -0x18(%rbp), %rcx
movzbl (%rcx), %ecx
shll $0x18, %ecx
orl %ecx, %eax
movl %eax, %eax
movq %rax, -0x20(%rbp)
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
cmpq %rax, -0x20(%rbp)
jne 0x976ee
movq $-0x1, -0x8(%rbp)
jmp 0x97782
jmp 0x97769
movq -0x18(%rbp), %rax
movzbl 0x2(%rax), %eax
movq -0x18(%rbp), %rcx
movzbl 0x1(%rcx), %ecx
shll $0x8, %ecx
orl %ecx, %eax
movq -0x18(%rbp), %rcx
movzbl (%rcx), %ecx
shll $0x10, %ecx
orl %ecx, %eax
movl %eax, %eax
movq %rax, -0x20(%rbp)
cmpq $0xffffff, -0x20(%rbp) # imm = 0xFFFFFF
jne 0x9772b
movq $-0x1, -0x8(%rbp)
jmp 0x97782
jmp 0x97769
movq -0x18(%rbp), %rax
movzbl 0x1(%rax), %eax
movzwl %ax, %eax
movq -0x18(%rbp), %rcx
movzbl (%rcx), %ecx
movzwl %cx, %ecx
shll $0x8, %ecx
orl %ecx, %eax
movzwl %ax, %eax
movq %rax, -0x20(%rbp)
cmpq $0xffff, -0x20(%rbp) # imm = 0xFFFF
jne 0x97762
movq $-0x1, -0x8(%rbp)
jmp 0x97782
jmp 0x97769
callq 0x2a5c0
movq -0x10(%rbp), %rax
movq 0x6c8(%rax), %rax
movq -0x10(%rbp), %rdi
movq -0x20(%rbp), %rsi
callq *%rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)
| _ma_rec_pos:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov rax, [rbp+var_10]
mov eax, [rax+740h]
add eax, 0FFFFFFFEh; switch 7 cases
mov ecx, eax
mov [rbp+var_28], rcx
sub eax, 6
ja def_9758E; jumptable 000000000009758E default case
mov rax, [rbp+var_28]
lea rcx, jpt_9758E
movsxd rax, ds:(jpt_9758E - 15A814h)[rcx+rax*4]
add rax, rcx
jmp rax; switch jump
loc_97590:
mov rax, [rbp+var_18]; jumptable 000000000009758E case 8
movzx eax, byte ptr [rax+7]
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+6]
shl ecx, 8
or eax, ecx
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+5]
shl ecx, 10h
or eax, ecx
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+4]
shl ecx, 18h
or eax, ecx
mov eax, eax
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+3]
mov rdx, [rbp+var_18]
movzx edx, byte ptr [rdx+2]
shl edx, 8
or ecx, edx
mov rdx, [rbp+var_18]
movzx edx, byte ptr [rdx+1]
shl edx, 10h
or ecx, edx
mov rdx, [rbp+var_18]
movzx edx, byte ptr [rdx]
shl edx, 18h
or ecx, edx
mov ecx, ecx
shl rcx, 20h
or rax, rcx
mov [rbp+var_20], rax
cmp [rbp+var_20], 0FFFFFFFFFFFFFFFFh
jnz short loc_97610
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp loc_97782
loc_97610:
jmp loc_97769
loc_97615:
mov rdi, [rbp+var_18]; jumptable 000000000009758E case 7
call mi_uint7korr
mov [rbp+var_20], rax
mov rax, 0FFFFFFFFFFFFFFh
cmp [rbp+var_20], rax
jnz short loc_9763F
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp loc_97782
loc_9763F:
jmp loc_97769
loc_97644:
mov rdi, [rbp+var_18]; jumptable 000000000009758E case 6
call mi_uint6korr
mov [rbp+var_20], rax
mov rax, 0FFFFFFFFFFFFh
cmp [rbp+var_20], rax
jnz short loc_9766E
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp loc_97782
loc_9766E:
jmp loc_97769
loc_97673:
mov rdi, [rbp+var_18]; jumptable 000000000009758E case 5
call mi_uint5korr
mov [rbp+var_20], rax
mov rax, 0FFFFFFFFFFh
cmp [rbp+var_20], rax
jnz short loc_9769D
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp loc_97782
loc_9769D:
jmp loc_97769
loc_976A2:
mov rax, [rbp+var_18]; jumptable 000000000009758E case 4
movzx eax, byte ptr [rax+3]
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+2]
shl ecx, 8
or eax, ecx
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+1]
shl ecx, 10h
or eax, ecx
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx]
shl ecx, 18h
or eax, ecx
mov eax, eax
mov [rbp+var_20], rax
mov eax, 0FFFFFFFFh
cmp [rbp+var_20], rax
jnz short loc_976EE
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp loc_97782
loc_976EE:
jmp short loc_97769
loc_976F0:
mov rax, [rbp+var_18]; jumptable 000000000009758E case 3
movzx eax, byte ptr [rax+2]
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx+1]
shl ecx, 8
or eax, ecx
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx]
shl ecx, 10h
or eax, ecx
mov eax, eax
mov [rbp+var_20], rax
cmp [rbp+var_20], 0FFFFFFh
jnz short loc_9772B
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp short loc_97782
loc_9772B:
jmp short loc_97769
loc_9772D:
mov rax, [rbp+var_18]; jumptable 000000000009758E case 2
movzx eax, byte ptr [rax+1]
movzx eax, ax
mov rcx, [rbp+var_18]
movzx ecx, byte ptr [rcx]
movzx ecx, cx
shl ecx, 8
or eax, ecx
movzx eax, ax
mov [rbp+var_20], rax
cmp [rbp+var_20], 0FFFFh
jnz short loc_97762
mov [rbp+var_8], 0FFFFFFFFFFFFFFFFh
jmp short loc_97782
loc_97762:
jmp short loc_97769
def_9758E:
call _abort; jumptable 000000000009758E default case
loc_97769:
mov rax, [rbp+var_10]
mov rax, [rax+6C8h]
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_20]
call rax
mov [rbp+var_8], rax
loc_97782:
mov rax, [rbp+var_8]
add rsp, 30h
pop rbp
retn
| long long ma_rec_pos(long long a1, unsigned int *a2, long long a3)
{
unsigned long long v4; // [rsp+10h] [rbp-20h]
long long v5; // [rsp+28h] [rbp-8h]
switch ( *(_DWORD *)(a1 + 1856) )
{
case 2:
v4 = _byteswap_ushort(*(_WORD *)a2);
if ( v4 != 0xFFFF )
goto LABEL_24;
v5 = -1LL;
break;
case 3:
v4 = (*(unsigned __int8 *)a2 << 16) | (*((unsigned __int8 *)a2 + 1) << 8) | (unsigned int)*((unsigned __int8 *)a2
+ 2);
if ( v4 != 0xFFFFFF )
goto LABEL_24;
v5 = -1LL;
break;
case 4:
v4 = _byteswap_ulong(*a2);
if ( v4 != 0xFFFFFFFF )
goto LABEL_24;
v5 = -1LL;
break;
case 5:
v4 = mi_uint5korr(a2);
if ( v4 != 0xFFFFFFFFFFLL )
goto LABEL_24;
v5 = -1LL;
break;
case 6:
v4 = mi_uint6korr(a2);
if ( v4 != 0xFFFFFFFFFFFFLL )
goto LABEL_24;
v5 = -1LL;
break;
case 7:
v4 = mi_uint7korr(a2);
if ( v4 != 0xFFFFFFFFFFFFFFLL )
goto LABEL_24;
v5 = -1LL;
break;
case 8:
v4 = ((unsigned long long)_byteswap_ulong(*a2) << 32) | _byteswap_ulong(a2[1]);
if ( v4 == -1LL )
v5 = -1LL;
else
LABEL_24:
v5 = (*(long long ( **)(long long, unsigned long long))(a1 + 1736))(a1, v4);
break;
default:
abort(a1, a2, a3);
}
return v5;
}
| _ma_rec_pos:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX + 0x740]
ADD EAX,-0x2
MOV ECX,EAX
MOV qword ptr [RBP + -0x28],RCX
SUB EAX,0x6
JA 0x00197764
MOV RAX,qword ptr [RBP + -0x28]
LEA RCX,[0x25a814]
MOVSXD RAX,dword ptr [RCX + RAX*0x4]
ADD RAX,RCX
switchD:
JMP RAX
caseD_8:
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX + 0x7]
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x6]
SHL ECX,0x8
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x5]
SHL ECX,0x10
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x4]
SHL ECX,0x18
OR EAX,ECX
MOV EAX,EAX
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x3]
MOV RDX,qword ptr [RBP + -0x18]
MOVZX EDX,byte ptr [RDX + 0x2]
SHL EDX,0x8
OR ECX,EDX
MOV RDX,qword ptr [RBP + -0x18]
MOVZX EDX,byte ptr [RDX + 0x1]
SHL EDX,0x10
OR ECX,EDX
MOV RDX,qword ptr [RBP + -0x18]
MOVZX EDX,byte ptr [RDX]
SHL EDX,0x18
OR ECX,EDX
MOV ECX,ECX
SHL RCX,0x20
OR RAX,RCX
MOV qword ptr [RBP + -0x20],RAX
CMP qword ptr [RBP + -0x20],-0x1
JNZ 0x00197610
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x00197782
LAB_00197610:
JMP 0x00197769
caseD_7:
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x00196fb0
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,0xffffffffffffff
CMP qword ptr [RBP + -0x20],RAX
JNZ 0x0019763f
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x00197782
LAB_0019763f:
JMP 0x00197769
caseD_6:
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x00197010
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,0xffffffffffff
CMP qword ptr [RBP + -0x20],RAX
JNZ 0x0019766e
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x00197782
LAB_0019766e:
JMP 0x00197769
caseD_5:
MOV RDI,qword ptr [RBP + -0x18]
CALL 0x00197060
MOV qword ptr [RBP + -0x20],RAX
MOV RAX,0xffffffffff
CMP qword ptr [RBP + -0x20],RAX
JNZ 0x0019769d
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x00197782
LAB_0019769d:
JMP 0x00197769
caseD_4:
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX + 0x3]
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x2]
SHL ECX,0x8
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x1]
SHL ECX,0x10
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX]
SHL ECX,0x18
OR EAX,ECX
MOV EAX,EAX
MOV qword ptr [RBP + -0x20],RAX
MOV EAX,0xffffffff
CMP qword ptr [RBP + -0x20],RAX
JNZ 0x001976ee
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x00197782
LAB_001976ee:
JMP 0x00197769
caseD_3:
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX + 0x2]
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX + 0x1]
SHL ECX,0x8
OR EAX,ECX
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX]
SHL ECX,0x10
OR EAX,ECX
MOV EAX,EAX
MOV qword ptr [RBP + -0x20],RAX
CMP qword ptr [RBP + -0x20],0xffffff
JNZ 0x0019772b
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x00197782
LAB_0019772b:
JMP 0x00197769
caseD_2:
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,byte ptr [RAX + 0x1]
MOVZX EAX,AX
MOV RCX,qword ptr [RBP + -0x18]
MOVZX ECX,byte ptr [RCX]
MOVZX ECX,CX
SHL ECX,0x8
OR EAX,ECX
MOVZX EAX,AX
MOV qword ptr [RBP + -0x20],RAX
CMP qword ptr [RBP + -0x20],0xffff
JNZ 0x00197762
MOV qword ptr [RBP + -0x8],-0x1
JMP 0x00197782
LAB_00197762:
JMP 0x00197769
default:
CALL 0x0012a5c0
LAB_00197769:
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x6c8]
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x20]
CALL RAX
MOV qword ptr [RBP + -0x8],RAX
LAB_00197782:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x30
POP RBP
RET
|
int8 _ma_rec_pos(long param_1,int1 *param_2)
{
int8 uVar1;
ulong local_28;
switch(*(int4 *)(param_1 + 0x740)) {
case 2:
local_28 = (ulong)CONCAT11(*param_2,param_2[1]);
if (local_28 == 0xffff) {
return 0xffffffffffffffff;
}
break;
case 3:
local_28 = (ulong)CONCAT12(*param_2,CONCAT11(param_2[1],param_2[2]));
if (local_28 == 0xffffff) {
return 0xffffffffffffffff;
}
break;
case 4:
local_28 = (ulong)CONCAT13(*param_2,CONCAT12(param_2[1],CONCAT11(param_2[2],param_2[3])));
if (local_28 == 0xffffffff) {
return 0xffffffffffffffff;
}
break;
case 5:
local_28 = mi_uint5korr(param_2);
if (local_28 == 0xffffffffff) {
return 0xffffffffffffffff;
}
break;
case 6:
local_28 = mi_uint6korr(param_2);
if (local_28 == 0xffffffffffff) {
return 0xffffffffffffffff;
}
break;
case 7:
local_28 = mi_uint7korr(param_2);
if (local_28 == 0xffffffffffffff) {
return 0xffffffffffffffff;
}
break;
case 8:
local_28 = CONCAT44(CONCAT13(*param_2,CONCAT12(param_2[1],CONCAT11(param_2[2],param_2[3]))),
CONCAT13(param_2[4],CONCAT12(param_2[5],CONCAT11(param_2[6],param_2[7]))));
if (local_28 == 0xffffffffffffffff) {
return 0xffffffffffffffff;
}
break;
default:
/* WARNING: Subroutine does not return */
abort();
}
uVar1 = (**(code **)(param_1 + 0x6c8))(param_1,local_28);
return uVar1;
}
| |
38,064 | fmt::v11::format_facet<std::locale>::do_put(fmt::v11::basic_appender<char>, fmt::v11::loc_value, fmt::v11::format_specs const&) const | zkingston[P]unknot/build_O0/_deps/fmt-src/include/fmt/format-inl.h | FMT_API FMT_FUNC auto format_facet<std::locale>::do_put(
appender out, loc_value val, const format_specs& specs) const -> bool {
return val.visit(
detail::loc_writer<>{out, specs, separator_, grouping_, decimal_point_});
} | O0 | c | fmt::v11::format_facet<std::locale>::do_put(fmt::v11::basic_appender<char>, fmt::v11::loc_value, fmt::v11::format_specs const&) const:
subq $0xc8, %rsp
leaq 0xd0(%rsp), %rax
movq %rax, 0x10(%rsp)
movq %rsi, 0xc0(%rsp)
movq %rdi, 0xb8(%rsp)
movq %rdx, 0xb0(%rsp)
movq 0xb8(%rsp), %rsi
movq %rsi, 0x20(%rsp)
movq 0xc0(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0xb0(%rsp), %rax
movq %rax, 0x48(%rsp)
leaq 0x50(%rsp), %rdi
movq %rdi, 0x18(%rsp)
addq $0x10, %rsi
callq 0x12510
movq 0x20(%rsp), %rsi
leaq 0x70(%rsp), %rdi
movq %rdi, 0x28(%rsp)
addq $0x30, %rsi
callq 0x12510
jmp 0xa55f0
movq 0x20(%rsp), %rsi
leaq 0x90(%rsp), %rdi
addq $0x50, %rsi
callq 0x12510
jmp 0xa5608
movq 0x10(%rsp), %rdi
leaq 0x40(%rsp), %rsi
callq 0xa7070
movb %al, 0xf(%rsp)
jmp 0xa561d
leaq 0x40(%rsp), %rdi
callq 0xa7470
movb 0xf(%rsp), %al
andb $0x1, %al
addq $0xc8, %rsp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x38(%rsp)
movl %eax, 0x34(%rsp)
jmp 0xa565d
movq 0x28(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x38(%rsp)
movl %eax, 0x34(%rsp)
callq 0x13768
movq 0x18(%rsp), %rdi
callq 0x13768
jmp 0xa5681
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x38(%rsp)
movl %eax, 0x34(%rsp)
leaq 0x40(%rsp), %rdi
callq 0xa7470
movq 0x38(%rsp), %rdi
callq 0x13540
nopl (%rax,%rax)
| _ZNK3fmt3v1112format_facetISt6localeE6do_putENS0_14basic_appenderIcEENS0_9loc_valueERKNS0_12format_specsE:
sub rsp, 0C8h
lea rax, [rsp+0C8h+arg_0]
mov [rsp+0C8h+var_B8], rax
mov [rsp+0C8h+var_8], rsi
mov [rsp+0C8h+var_10], rdi
mov [rsp+0C8h+var_18], rdx
mov rsi, [rsp+0C8h+var_10]
mov [rsp+0C8h+var_A8], rsi
mov rax, [rsp+0C8h+var_8]
mov [rsp+0C8h+var_88], rax
mov rax, [rsp+0C8h+var_18]
mov [rsp+0C8h+var_80], rax
lea rdi, [rsp+0C8h+var_78]
mov [rsp+0C8h+var_B0], rdi
add rsi, 10h
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1ERKS4_; std::string::basic_string(std::string const&)
mov rsi, [rsp+0C8h+var_A8]
lea rdi, [rsp+0C8h+var_58]
mov [rsp+0C8h+var_A0], rdi
add rsi, 30h ; '0'
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1ERKS4_; std::string::basic_string(std::string const&)
jmp short $+2
loc_A55F0:
mov rsi, [rsp+0C8h+var_A8]
lea rdi, [rsp+0C8h+var_38]
add rsi, 50h ; 'P'
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1ERKS4_; std::string::basic_string(std::string const&)
jmp short $+2
loc_A5608:
mov rdi, [rsp+0C8h+var_B8]
lea rsi, [rsp+0C8h+var_88]
call _ZN3fmt3v119loc_value5visitINS0_6detail10loc_writerIcEEEEDTclfp_Li0EEEOT_; fmt::v11::loc_value::visit<fmt::v11::detail::loc_writer<char>>(fmt::v11::detail::loc_writer<char> &&)
mov [rsp+0C8h+var_B9], al
jmp short $+2
loc_A561D:
lea rdi, [rsp+0C8h+var_88]
call _ZN3fmt3v116detail10loc_writerIcED2Ev; fmt::v11::detail::loc_writer<char>::~loc_writer()
mov al, [rsp+0C8h+var_B9]
and al, 1
add rsp, 0C8h
retn
mov rcx, rax
mov eax, edx
mov [rsp+arg_30], rcx
mov [rsp+arg_2C], eax
jmp short loc_A565D
mov rdi, [rsp+arg_20]; void *
mov rcx, rax
mov eax, edx
mov [rsp+arg_30], rcx
mov [rsp+arg_2C], eax
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
loc_A565D:
mov rdi, [rsp+arg_10]; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string()
jmp short loc_A5681
mov rcx, rax
mov eax, edx
mov [rsp+arg_30], rcx
mov [rsp+arg_2C], eax
lea rdi, [rsp+arg_38]
call _ZN3fmt3v116detail10loc_writerIcED2Ev; fmt::v11::detail::loc_writer<char>::~loc_writer()
loc_A5681:
mov rdi, [rsp+arg_30]
call __Unwind_Resume
| char fmt::v11::format_facet<std::locale>::do_put(
long long a1,
long long a2,
long long a3,
int a4,
int a5,
int a6,
char a7)
{
char v8; // [rsp+Fh] [rbp-B9h]
_QWORD v9[2]; // [rsp+40h] [rbp-88h] BYREF
_BYTE v10[32]; // [rsp+50h] [rbp-78h] BYREF
_BYTE v11[32]; // [rsp+70h] [rbp-58h] BYREF
_BYTE v12[32]; // [rsp+90h] [rbp-38h] BYREF
long long v13; // [rsp+B0h] [rbp-18h]
long long v14; // [rsp+B8h] [rbp-10h]
long long v15; // [rsp+C0h] [rbp-8h]
v15 = a2;
v14 = a1;
v13 = a3;
v9[0] = a2;
v9[1] = a3;
std::string::basic_string(v10, a1 + 16);
std::string::basic_string(v11, a1 + 48);
std::string::basic_string(v12, a1 + 80);
v8 = fmt::v11::loc_value::visit<fmt::v11::detail::loc_writer<char>>(&a7, v9);
fmt::v11::detail::loc_writer<char>::~loc_writer(v9);
return v8 & 1;
}
| do_put:
SUB RSP,0xc8
LEA RAX,[RSP + 0xd0]
MOV qword ptr [RSP + 0x10],RAX
MOV qword ptr [RSP + 0xc0],RSI
MOV qword ptr [RSP + 0xb8],RDI
MOV qword ptr [RSP + 0xb0],RDX
MOV RSI,qword ptr [RSP + 0xb8]
MOV qword ptr [RSP + 0x20],RSI
MOV RAX,qword ptr [RSP + 0xc0]
MOV qword ptr [RSP + 0x40],RAX
MOV RAX,qword ptr [RSP + 0xb0]
MOV qword ptr [RSP + 0x48],RAX
LEA RDI,[RSP + 0x50]
MOV qword ptr [RSP + 0x18],RDI
ADD RSI,0x10
CALL 0x00112510
MOV RSI,qword ptr [RSP + 0x20]
LEA RDI,[RSP + 0x70]
MOV qword ptr [RSP + 0x28],RDI
ADD RSI,0x30
LAB_001a55e9:
CALL 0x00112510
JMP 0x001a55f0
LAB_001a55f0:
MOV RSI,qword ptr [RSP + 0x20]
LEA RDI,[RSP + 0x90]
ADD RSI,0x50
LAB_001a5601:
CALL 0x00112510
JMP 0x001a5608
LAB_001a5608:
MOV RDI,qword ptr [RSP + 0x10]
LEA RSI,[RSP + 0x40]
CALL 0x001a7070
LAB_001a5617:
MOV byte ptr [RSP + 0xf],AL
JMP 0x001a561d
LAB_001a561d:
LEA RDI,[RSP + 0x40]
CALL 0x001a7470
MOV AL,byte ptr [RSP + 0xf]
AND AL,0x1
ADD RSP,0xc8
RET
|
/* fmt::v11::format_facet<std::locale>::do_put(fmt::v11::basic_appender<char>, fmt::v11::loc_value,
fmt::v11::format_specs const&) const */
ulong fmt::v11::format_facet<std::locale>::do_put
(long param_1,int8 param_2,int8 param_3)
{
int1 uVar1;
int8 uVar2;
int8 local_88;
int8 local_80;
string local_78 [32];
string local_58 [32];
string local_38 [32];
int8 local_18;
long local_10;
int8 local_8;
local_88 = param_2;
local_80 = param_3;
local_18 = param_3;
local_10 = param_1;
local_8 = param_2;
std::__cxx11::string::string(local_78,(string *)(param_1 + 0x10));
/* try { // try from 001a55e9 to 001a55ed has its CatchHandler @ 001a5635 */
std::__cxx11::string::string(local_58,(string *)(param_1 + 0x30));
/* try { // try from 001a5601 to 001a5605 has its CatchHandler @ 001a5645 */
std::__cxx11::string::string(local_38,(string *)(param_1 + 0x50));
/* try { // try from 001a5608 to 001a5616 has its CatchHandler @ 001a5669 */
uVar1 = loc_value::visit<fmt::v11::detail::loc_writer<char>>
((loc_value *)&stack0x00000008,(loc_writer *)&local_88);
uVar2 = detail::loc_writer<char>::~loc_writer((loc_writer<char> *)&local_88);
return CONCAT71((int7)((ulong)uVar2 >> 8),uVar1) & 0xffffffffffffff01;
}
| |
38,065 | ggml_backend_cpu_buffer_type_alloc_buffer(ggml_backend_buffer_type*, unsigned long) | Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-backend.cpp | static ggml_backend_buffer_t ggml_backend_cpu_buffer_type_alloc_buffer(ggml_backend_buffer_type_t buft, size_t size) {
void * data = ggml_aligned_malloc(size);
if (data == NULL) {
GGML_LOG_ERROR("%s: failed to allocate buffer of size %zu\n", __func__, size);
return NULL;
}
return ggml_backend_buffer_init(buft, ggml_backend_cpu_buffer_i, data, size);
} | O2 | cpp | ggml_backend_cpu_buffer_type_alloc_buffer(ggml_backend_buffer_type*, unsigned long):
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r15
movq %rsi, %rdi
callq 0x1dc40
testq %rax, %rax
je 0x2e847
movq %rax, %r12
pushq $0x68
popq %rdi
callq 0x1e7e0
movq %rax, %r14
leaq 0x44444(%rip), %rsi # 0x72c70
pushq $0x9
popq %rcx
movq %rax, %rdi
rep movsq (%rsi), %es:(%rdi)
movq %r15, 0x48(%rax)
movq %r12, 0x50(%rax)
movq %rbx, 0x58(%rax)
andl $0x0, 0x60(%rax)
jmp 0x2e865
leaq 0x23bc7(%rip), %rsi # 0x52415
leaq 0x23beb(%rip), %rdx # 0x52440
xorl %r14d, %r14d
pushq $0x4
popq %rdi
movq %rbx, %rcx
xorl %eax, %eax
callq 0x1db70
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
| _ZL41ggml_backend_cpu_buffer_type_alloc_bufferP24ggml_backend_buffer_typem:
push r15
push r14
push r12
push rbx
push rax
mov rbx, rsi
mov r15, rdi
mov rdi, rsi
call _ggml_aligned_malloc
test rax, rax
jz short loc_2E847
mov r12, rax
push 68h ; 'h'
pop rdi; unsigned __int64
call __Znwm; operator new(ulong)
mov r14, rax
lea rsi, _ZL25ggml_backend_cpu_buffer_i; ggml_backend_cpu_buffer_i
push 9
pop rcx
mov rdi, rax
rep movsq
mov [rax+48h], r15
mov [rax+50h], r12
mov [rax+58h], rbx
and dword ptr [rax+60h], 0
jmp short loc_2E865
loc_2E847:
lea rsi, aSFailedToAlloc_5; "%s: failed to allocate buffer of size %"...
lea rdx, aGgmlBackendCpu_1; "ggml_backend_cpu_buffer_type_alloc_buff"...
xor r14d, r14d
push 4
pop rdi
mov rcx, rbx
xor eax, eax
call _ggml_log_internal
loc_2E865:
mov rax, r14
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
| long long ggml_backend_cpu_buffer_type_alloc_buffer(
long long a1,
unsigned 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)
{
long long v14; // rax
long long v15; // r8
long long v16; // r9
__m128 v17; // xmm4
__m128 v18; // xmm5
long long v19; // r12
long long v20; // r14
v14 = ggml_aligned_malloc(a2, a7, a8, a9, a10, a11, a12, a13, a14, a2, a3, a4, a5, a6);
if ( v14 )
{
v19 = v14;
v20 = operator new(0x68uLL);
qmemcpy((void *)v20, ggml_backend_cpu_buffer_i, 0x48uLL);
*(_QWORD *)(v20 + 72) = a1;
*(_QWORD *)(v20 + 80) = v19;
*(_QWORD *)(v20 + 88) = a2;
*(_DWORD *)(v20 + 96) = 0;
}
else
{
v20 = 0LL;
ggml_log_internal(
a7,
a8,
a9,
a10,
v17,
v18,
a13,
a14,
4LL,
(long long)"%s: failed to allocate buffer of size %zu\n",
(long long)"ggml_backend_cpu_buffer_type_alloc_buffer",
a2,
v15,
v16);
}
return v20;
}
| ggml_backend_cpu_buffer_type_alloc_buffer:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RSI
MOV R15,RDI
MOV RDI,RSI
CALL 0x0011dc40
TEST RAX,RAX
JZ 0x0012e847
MOV R12,RAX
PUSH 0x68
POP RDI
CALL 0x0011e7e0
MOV R14,RAX
LEA RSI,[0x172c70]
PUSH 0x9
POP RCX
MOV RDI,RAX
MOVSQ.REP RDI,RSI
MOV qword ptr [RAX + 0x48],R15
MOV qword ptr [RAX + 0x50],R12
MOV qword ptr [RAX + 0x58],RBX
AND dword ptr [RAX + 0x60],0x0
JMP 0x0012e865
LAB_0012e847:
LEA RSI,[0x152415]
LEA RDX,[0x152440]
XOR R14D,R14D
PUSH 0x4
POP RDI
MOV RCX,RBX
XOR EAX,EAX
CALL 0x0011db70
LAB_0012e865:
MOV RAX,R14
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
|
/* ggml_backend_cpu_buffer_type_alloc_buffer(ggml_backend_buffer_type*, unsigned long) */
int8 *
ggml_backend_cpu_buffer_type_alloc_buffer(ggml_backend_buffer_type *param_1,ulong param_2)
{
long lVar1;
int8 *puVar2;
long lVar3;
int **ppuVar4;
int8 *puVar5;
byte bVar6;
bVar6 = 0;
lVar1 = ggml_aligned_malloc(param_2);
if (lVar1 == 0) {
puVar2 = (int8 *)0x0;
ggml_log_internal(4,"%s: failed to allocate buffer of size %zu\n",
"ggml_backend_cpu_buffer_type_alloc_buffer",param_2);
}
else {
puVar2 = (int8 *)operator_new(0x68);
ppuVar4 = &ggml_backend_cpu_buffer_i;
puVar5 = puVar2;
for (lVar3 = 9; lVar3 != 0; lVar3 = lVar3 + -1) {
*puVar5 = *ppuVar4;
ppuVar4 = ppuVar4 + (ulong)bVar6 * -2 + 1;
puVar5 = puVar5 + (ulong)bVar6 * -2 + 1;
}
puVar2[9] = param_1;
puVar2[10] = lVar1;
puVar2[0xb] = param_2;
*(int4 *)(puVar2 + 0xc) = 0;
}
return puVar2;
}
| |
38,066 | ggml_backend_cpu_buffer_type_alloc_buffer(ggml_backend_buffer_type*, unsigned long) | Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-backend.cpp | static ggml_backend_buffer_t ggml_backend_cpu_buffer_type_alloc_buffer(ggml_backend_buffer_type_t buft, size_t size) {
void * data = ggml_aligned_malloc(size);
if (data == NULL) {
GGML_LOG_ERROR("%s: failed to allocate buffer of size %zu\n", __func__, size);
return NULL;
}
return ggml_backend_buffer_init(buft, ggml_backend_cpu_buffer_i, data, size);
} | O3 | cpp | ggml_backend_cpu_buffer_type_alloc_buffer(ggml_backend_buffer_type*, unsigned long):
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r15
movq %rsi, %rdi
callq 0x16880
testq %rax, %rax
je 0x291cc
movq %rax, %r12
movl $0x68, %edi
callq 0x17080
movq %rax, %r14
leaq 0x44ac4(%rip), %rsi # 0x6dc70
movl $0x9, %ecx
movq %rax, %rdi
rep movsq (%rsi), %es:(%rdi)
movq %r15, 0x48(%rax)
movq %r12, 0x50(%rax)
movq %rbx, 0x58(%rax)
movl $0x0, 0x60(%rax)
jmp 0x291ec
leaq 0x272d2(%rip), %rsi # 0x504a5
leaq 0x272f6(%rip), %rdx # 0x504d0
xorl %r14d, %r14d
movl $0x4, %edi
movq %rbx, %rcx
xorl %eax, %eax
callq 0x16810
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
| _ZL41ggml_backend_cpu_buffer_type_alloc_bufferP24ggml_backend_buffer_typem:
push r15
push r14
push r12
push rbx
push rax
mov rbx, rsi
mov r15, rdi
mov rdi, rsi
call _ggml_aligned_malloc
test rax, rax
jz short loc_291CC
mov r12, rax
mov edi, 68h ; 'h'; unsigned __int64
call __Znwm; operator new(ulong)
mov r14, rax
lea rsi, _ZL25ggml_backend_cpu_buffer_i; ggml_backend_cpu_buffer_i
mov ecx, 9
mov rdi, rax
rep movsq
mov [rax+48h], r15
mov [rax+50h], r12
mov [rax+58h], rbx
mov dword ptr [rax+60h], 0
jmp short loc_291EC
loc_291CC:
lea rsi, aSFailedToAlloc_5; "%s: failed to allocate buffer of size %"...
lea rdx, aGgmlBackendCpu_1; "ggml_backend_cpu_buffer_type_alloc_buff"...
xor r14d, r14d
mov edi, 4
mov rcx, rbx
xor eax, eax
call _ggml_log_internal
loc_291EC:
mov rax, r14
add rsp, 8
pop rbx
pop r12
pop r14
pop r15
retn
| long long ggml_backend_cpu_buffer_type_alloc_buffer(
long long a1,
unsigned 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)
{
long long v14; // rax
long long v15; // r8
long long v16; // r9
__m128 v17; // xmm4
__m128 v18; // xmm5
long long v19; // r12
long long v20; // r14
v14 = ggml_aligned_malloc(a2, a7, a8, a9, a10, a11, a12, a13, a14, a2, a3, a4, a5, a6);
if ( v14 )
{
v19 = v14;
v20 = operator new(0x68uLL);
qmemcpy((void *)v20, ggml_backend_cpu_buffer_i, 0x48uLL);
*(_QWORD *)(v20 + 72) = a1;
*(_QWORD *)(v20 + 80) = v19;
*(_QWORD *)(v20 + 88) = a2;
*(_DWORD *)(v20 + 96) = 0;
}
else
{
v20 = 0LL;
ggml_log_internal(
4u,
(long long)"%s: failed to allocate buffer of size %zu\n",
(long long)"ggml_backend_cpu_buffer_type_alloc_buffer",
a2,
v15,
v16,
a7,
a8,
a9,
a10,
v17,
v18,
a13,
a14);
}
return v20;
}
| ggml_backend_cpu_buffer_type_alloc_buffer:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
PUSH RAX
MOV RBX,RSI
MOV R15,RDI
MOV RDI,RSI
CALL 0x00116880
TEST RAX,RAX
JZ 0x001291cc
MOV R12,RAX
MOV EDI,0x68
CALL 0x00117080
MOV R14,RAX
LEA RSI,[0x16dc70]
MOV ECX,0x9
MOV RDI,RAX
MOVSQ.REP RDI,RSI
MOV qword ptr [RAX + 0x48],R15
MOV qword ptr [RAX + 0x50],R12
MOV qword ptr [RAX + 0x58],RBX
MOV dword ptr [RAX + 0x60],0x0
JMP 0x001291ec
LAB_001291cc:
LEA RSI,[0x1504a5]
LEA RDX,[0x1504d0]
XOR R14D,R14D
MOV EDI,0x4
MOV RCX,RBX
XOR EAX,EAX
CALL 0x00116810
LAB_001291ec:
MOV RAX,R14
ADD RSP,0x8
POP RBX
POP R12
POP R14
POP R15
RET
|
/* ggml_backend_cpu_buffer_type_alloc_buffer(ggml_backend_buffer_type*, unsigned long) */
int8 *
ggml_backend_cpu_buffer_type_alloc_buffer(ggml_backend_buffer_type *param_1,ulong param_2)
{
long lVar1;
int8 *puVar2;
long lVar3;
int **ppuVar4;
int8 *puVar5;
byte bVar6;
bVar6 = 0;
lVar1 = ggml_aligned_malloc(param_2);
if (lVar1 == 0) {
puVar2 = (int8 *)0x0;
ggml_log_internal(4,"%s: failed to allocate buffer of size %zu\n",
"ggml_backend_cpu_buffer_type_alloc_buffer",param_2);
}
else {
puVar2 = (int8 *)operator_new(0x68);
ppuVar4 = &ggml_backend_cpu_buffer_i;
puVar5 = puVar2;
for (lVar3 = 9; lVar3 != 0; lVar3 = lVar3 + -1) {
*puVar5 = *ppuVar4;
ppuVar4 = ppuVar4 + (ulong)bVar6 * -2 + 1;
puVar5 = puVar5 + (ulong)bVar6 * -2 + 1;
}
puVar2[9] = param_1;
puVar2[10] = lVar1;
puVar2[0xb] = param_2;
*(int4 *)(puVar2 + 0xc) = 0;
}
return puVar2;
}
| |
38,067 | testing::internal::PrettyUnitTestResultPrinter::OnTestIterationStart(testing::UnitTest const&, int) | seiftnesse[P]memoryallocator/build_O1/_deps/googletest-src/googletest/src/gtest.cc | void PrettyUnitTestResultPrinter::OnTestIterationStart(
const UnitTest& unit_test, int iteration) {
if (GTEST_FLAG_GET(repeat) != 1)
printf("\nRepeating all tests (iteration %d) . . .\n\n", iteration + 1);
std::string f = GTEST_FLAG_GET(filter);
const char* const filter = f.c_str();
// Prints the filter if it's not *. This reminds the user that some
// tests may be skipped.
if (!String::CStringEquals(filter, kUniversalFilter)) {
ColoredPrintf(GTestColor::kYellow, "Note: %s filter = %s\n", GTEST_NAME_,
filter);
}
if (internal::ShouldShard(kTestTotalShards, kTestShardIndex, false)) {
const int32_t shard_index = Int32FromEnvOrDie(kTestShardIndex, -1);
ColoredPrintf(GTestColor::kYellow, "Note: This is test shard %d of %s.\n",
static_cast<int>(shard_index) + 1,
internal::posix::GetEnv(kTestTotalShards));
}
if (GTEST_FLAG_GET(shuffle)) {
ColoredPrintf(GTestColor::kYellow,
"Note: Randomizing tests' orders with a seed of %d .\n",
unit_test.random_seed());
}
ColoredPrintf(GTestColor::kGreen, "[==========] ");
printf("Running %s from %s.\n",
FormatTestCount(unit_test.test_to_run_count()).c_str(),
FormatTestSuiteCount(unit_test.test_suite_to_run_count()).c_str());
fflush(stdout);
} | O1 | cpp | testing::internal::PrettyUnitTestResultPrinter::OnTestIterationStart(testing::UnitTest const&, int):
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x68, %rsp
movq %rsi, %rbx
cmpl $0x1, 0x4137d3a(%rip) # 0x415dea8
je 0x26182
incl %edx
leaq 0x1d319(%rip), %rdi # 0x43492
movl %edx, %esi
xorl %eax, %eax
callq 0x9080
leaq 0x38(%rsp), %r15
movq %r15, -0x10(%r15)
movq 0x4137cc6(%rip), %rsi # 0x415de58
movq 0x4137cc7(%rip), %rdx # 0x415de60
addq %rsi, %rdx
leaq 0x28(%rsp), %r14
movq %r14, %rdi
callq 0xf66a
movq (%r14), %r14
testq %r14, %r14
je 0x261c4
leaq 0x1af08(%rip), %rsi # 0x410c0
movq %r14, %rdi
callq 0x97b0
testl %eax, %eax
je 0x261e1
leaq 0x1d2f3(%rip), %rsi # 0x434be
leaq 0x1d302(%rip), %rdx # 0x434d4
movl $0x3, %edi
movq %r14, %rcx
xorl %eax, %eax
callq 0x26396
leaq 0x1aee8(%rip), %rdi # 0x410d0
leaq 0x1af01(%rip), %rsi # 0x410f0
xorl %edx, %edx
callq 0x264fa
testb %al, %al
je 0x26233
leaq 0x1aeef(%rip), %rdi # 0x410f0
movl $0xffffffff, %esi # imm = 0xFFFFFFFF
callq 0x2698d
movl %eax, %ebp
incl %ebp
leaq 0x1aeba(%rip), %rdi # 0x410d0
callq 0x9660
leaq 0x1d2be(%rip), %rsi # 0x434e0
movl $0x3, %edi
movl %ebp, %edx
movq %rax, %rcx
xorl %eax, %eax
callq 0x26396
cmpb $0x1, 0x4137c74(%rip) # 0x415deae
jne 0x26259
movq 0x40(%rbx), %rax
movl 0x21c(%rax), %edx
leaq 0x1d2b7(%rip), %rsi # 0x43504
movl $0x3, %edi
xorl %eax, %eax
callq 0x26396
leaq 0x1d2d9(%rip), %rsi # 0x43539
movl $0x2, %edi
xorl %eax, %eax
callq 0x26396
movq 0x40(%rbx), %rdi
callq 0x20b46
leaq 0x1c279(%rip), %rdx # 0x424f5
leaq 0x1c685(%rip), %rcx # 0x42908
leaq 0x8(%rsp), %rdi
movl %eax, %esi
callq 0x26bc4
movq 0x40(%rbx), %rcx
movq 0xb8(%rcx), %rax
movq 0xc0(%rcx), %rcx
xorl %esi, %esi
cmpq %rcx, %rax
je 0x262b7
movq (%rax), %rdx
movzbl 0x70(%rdx), %edx
addl %edx, %esi
addq $0x8, %rax
jmp 0x262a3
movq 0x8(%rsp), %rbx
leaq 0x1e272(%rip), %rdx # 0x44535
leaq 0x1e276(%rip), %rcx # 0x44540
leaq 0x48(%rsp), %rdi
callq 0x26bc4
leaq 0x58(%rsp), %r14
movq -0x10(%r14), %rdx
leaq 0x1d263(%rip), %rdi # 0x43547
movq %rbx, %rsi
xorl %eax, %eax
callq 0x9080
movq -0x10(%r14), %rdi
cmpq %r14, %rdi
je 0x26304
movq 0x58(%rsp), %rsi
incq %rsi
callq 0x94c0
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x2631f
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x94c0
movq 0x33c5a(%rip), %rax # 0x59f80
movq (%rax), %rdi
callq 0x95f0
movq 0x28(%rsp), %rdi
cmpq %r15, %rdi
je 0x26345
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x94c0
addq $0x68, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
leaq 0x18(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x26377
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x94c0
jmp 0x26377
jmp 0x26374
jmp 0x26374
movq %rax, %rbx
movq 0x28(%rsp), %rdi
cmpq %r15, %rdi
je 0x2638e
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x94c0
movq %rbx, %rdi
callq 0x99a0
| _ZN7testing8internal27PrettyUnitTestResultPrinter20OnTestIterationStartERKNS_8UnitTestEi:
push rbp
push r15
push r14
push rbx
sub rsp, 68h
mov rbx, rsi
cmp cs:_ZN7testing18FLAGS_gtest_repeatE, 1; testing::FLAGS_gtest_repeat
jz short loc_26182
inc edx
lea rdi, aRepeatingAllTe; "\nRepeating all tests (iteration %d) . "...
mov esi, edx
xor eax, eax
call _printf
loc_26182:
lea r15, [rsp+88h+var_50]
mov [r15-10h], r15
mov rsi, cs:_ZN7testing18FLAGS_gtest_filterB5cxx11E; testing::FLAGS_gtest_filter
mov rdx, cs:qword_415DE60
add rdx, rsi
lea r14, [rsp+88h+var_60]
mov rdi, r14
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag)
mov r14, [r14]
test r14, r14
jz short loc_261C4
lea rsi, _ZN7testingL16kUniversalFilterE; "*"
mov rdi, r14
call _strcmp
test eax, eax
jz short loc_261E1
loc_261C4:
lea rsi, aNoteSFilterS; "Note: %s filter = %s\n"
lea rdx, aGoogleTest; "Google Test"
mov edi, 3
mov rcx, r14
xor eax, eax
call _ZN7testing8internalL13ColoredPrintfENS0_12_GLOBAL__N_110GTestColorEPKcz; testing::internal::ColoredPrintf(testing::internal::`anonymous namespace'::GTestColor,char const*,...)
loc_261E1:
lea rdi, _ZN7testingL16kTestTotalShardsE; "GTEST_TOTAL_SHARDS"
lea rsi, _ZN7testingL15kTestShardIndexE; "GTEST_SHARD_INDEX"
xor edx, edx; char *
call _ZN7testing8internal11ShouldShardEPKcS2_b; testing::internal::ShouldShard(char const*,char const*,bool)
test al, al
jz short loc_26233
lea rdi, _ZN7testingL15kTestShardIndexE; "GTEST_SHARD_INDEX"
mov esi, 0FFFFFFFFh; char *
call _ZN7testing8internal17Int32FromEnvOrDieEPKci; testing::internal::Int32FromEnvOrDie(char const*,int)
mov ebp, eax
inc ebp
lea rdi, _ZN7testingL16kTestTotalShardsE; "GTEST_TOTAL_SHARDS"
call _getenv
lea rsi, aNoteThisIsTest; "Note: This is test shard %d of %s.\n"
mov edi, 3
mov edx, ebp
mov rcx, rax
xor eax, eax
call _ZN7testing8internalL13ColoredPrintfENS0_12_GLOBAL__N_110GTestColorEPKcz; testing::internal::ColoredPrintf(testing::internal::`anonymous namespace'::GTestColor,char const*,...)
loc_26233:
cmp cs:_ZN7testing19FLAGS_gtest_shuffleE, 1; testing::FLAGS_gtest_shuffle
jnz short loc_26259
mov rax, [rbx+40h]
mov edx, [rax+21Ch]
lea rsi, aNoteRandomizin; "Note: Randomizing tests' orders with a "...
mov edi, 3
xor eax, eax
call _ZN7testing8internalL13ColoredPrintfENS0_12_GLOBAL__N_110GTestColorEPKcz; testing::internal::ColoredPrintf(testing::internal::`anonymous namespace'::GTestColor,char const*,...)
loc_26259:
lea rsi, asc_43539; "[==========] "
mov edi, 2
xor eax, eax
call _ZN7testing8internalL13ColoredPrintfENS0_12_GLOBAL__N_110GTestColorEPKcz; testing::internal::ColoredPrintf(testing::internal::`anonymous namespace'::GTestColor,char const*,...)
mov rdi, [rbx+40h]; this
call _ZNK7testing8internal12UnitTestImpl17test_to_run_countEv; testing::internal::UnitTestImpl::test_to_run_count(void)
lea rdx, aDeathtestPasse+36h; int
lea rcx, aAlsoRunDisable+12h; int
lea rdi, [rsp+88h+var_80]; int
mov esi, eax; int
call _ZN7testingL19FormatCountableNounB5cxx11EiPKcS1_; testing::FormatCountableNoun(int,char const*,char const*)
mov rcx, [rbx+40h]
mov rax, [rcx+0B8h]
mov rcx, [rcx+0C0h]
xor esi, esi; int
loc_262A3:
cmp rax, rcx
jz short loc_262B7
mov rdx, [rax]
movzx edx, byte ptr [rdx+70h]
add esi, edx
add rax, 8
jmp short loc_262A3
loc_262B7:
mov rbx, qword ptr [rsp+88h+var_80]
lea rdx, aTestSuite; "test suite"
lea rcx, aTestSuites; "test suites"
lea rdi, [rsp+88h+var_40]; int
call _ZN7testingL19FormatCountableNounB5cxx11EiPKcS1_; testing::FormatCountableNoun(int,char const*,char const*)
lea r14, [rsp+88h+var_30]
mov rdx, [r14-10h]
lea rdi, aRunningSFromS; "Running %s from %s.\n"
mov rsi, rbx
xor eax, eax
call _printf
mov rdi, [r14-10h]; void *
cmp rdi, r14
jz short loc_26304
mov rsi, [rsp+88h+var_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_26304:
lea rax, [rsp+88h+var_70]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_2631F
mov rsi, [rsp+88h+var_70]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_2631F:
mov rax, cs:stdout_ptr
mov rdi, [rax]
call _fflush
mov rdi, [rsp+88h+var_60]; void *
cmp rdi, r15
jz short loc_26345
mov rsi, [rsp+88h+var_50]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_26345:
add rsp, 68h
pop rbx
pop r14
pop r15
pop rbp
retn
mov rbx, rax
lea rax, [rsp+arg_10]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_26377
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_26377
jmp short loc_26374
jmp short $+2
loc_26374:
mov rbx, rax
loc_26377:
mov rdi, [rsp+arg_20]; void *
cmp rdi, r15
jz short loc_2638E
mov rsi, [rsp+arg_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_2638E:
mov rdi, rbx
call __Unwind_Resume
| void testing::internal::PrettyUnitTestResultPrinter::OnTestIterationStart(
testing::internal::PrettyUnitTestResultPrinter *this,
const testing::UnitTest *a2,
int a3)
{
int v3; // r8d
int v4; // r9d
int v5; // r14d
bool v6; // cl
int v7; // edx
int v8; // ecx
int v9; // r8d
int v10; // r9d
int v11; // ebp
int v12; // eax
int v13; // r8d
int v14; // r9d
int v15; // eax
int v16; // r8d
int v17; // r9d
int v18; // r8d
int v19; // r9d
long long v20; // rcx
long long v21; // rax
long long v22; // rcx
int v23; // esi
const char *v24; // rbx
void *v25; // [rsp+0h] [rbp-88h]
void *v26; // [rsp+0h] [rbp-88h]
int v27[2]; // [rsp+8h] [rbp-80h] BYREF
long long v28; // [rsp+10h] [rbp-78h]
long long v29; // [rsp+18h] [rbp-70h] BYREF
int v30; // [rsp+20h] [rbp-68h]
void *v31; // [rsp+28h] [rbp-60h] BYREF
long long v32; // [rsp+30h] [rbp-58h]
_QWORD v33[2]; // [rsp+38h] [rbp-50h] BYREF
char *v34; // [rsp+48h] [rbp-40h] BYREF
long long v35; // [rsp+58h] [rbp-30h] BYREF
if ( testing::FLAGS_gtest_repeat != 1 )
printf("\nRepeating all tests (iteration %d) . . .\n\n", a3 + 1);
v31 = v33;
std::string::_M_construct<char *>(
&v31,
*(_BYTE **)&testing::FLAGS_gtest_filter[abi:cxx11],
*(_QWORD *)&testing::FLAGS_gtest_filter[abi:cxx11] + qword_415DE60);
v5 = (int)v31;
if ( !v31 || (unsigned int)strcmp(v31, "*") )
testing::internal::ColoredPrintf(3, (unsigned int)"Note: %s filter = %s\n", (unsigned int)"Google Test", v5, v3, v4);
if ( (unsigned __int8)testing::internal::ShouldShard(
(testing::internal *)"GTEST_TOTAL_SHARDS",
"GTEST_SHARD_INDEX",
0LL,
v6) )
{
v11 = testing::internal::Int32FromEnvOrDie((testing::internal *)"GTEST_SHARD_INDEX", (const char *)0xFFFFFFFFLL, v7)
+ 1;
v12 = getenv("GTEST_TOTAL_SHARDS");
testing::internal::ColoredPrintf(3, (unsigned int)"Note: This is test shard %d of %s.\n", v11, v12, v13, v14);
}
if ( testing::FLAGS_gtest_shuffle == 1 )
testing::internal::ColoredPrintf(
3,
(unsigned int)"Note: Randomizing tests' orders with a seed of %d .\n",
*(_DWORD *)(*((_QWORD *)a2 + 8) + 540LL),
v8,
v9,
v10);
testing::internal::ColoredPrintf(2, (unsigned int)"[==========] ", v7, v8, v9, v10);
v15 = testing::internal::UnitTestImpl::test_to_run_count(*((testing::internal::UnitTestImpl **)a2 + 8));
testing::FormatCountableNoun[abi:cxx11](
(int)v27,
v15,
(int)"test",
(int)"tests",
v16,
v17,
v25,
v27[0],
v28,
v29,
v30,
(int)v31,
v32);
v20 = *((_QWORD *)a2 + 8);
v21 = *(_QWORD *)(v20 + 184);
v22 = *(_QWORD *)(v20 + 192);
v23 = 0;
while ( v21 != v22 )
{
v23 += *(unsigned __int8 *)(*(_QWORD *)v21 + 112LL);
v21 += 8LL;
}
v24 = *(const char **)v27;
testing::FormatCountableNoun[abi:cxx11](
(int)&v34,
v23,
(int)"test suite",
(int)"test suites",
v18,
v19,
v26,
v27[0],
v28,
v29,
v30,
(int)v31,
v32);
printf("Running %s from %s.\n", v24, v34);
if ( v34 != (char *)&v35 )
operator delete(v34, v35 + 1);
if ( *(long long **)v27 != &v29 )
operator delete(*(void **)v27, v29 + 1);
fflush(stdout);
if ( v31 != v33 )
operator delete(v31, v33[0] + 1LL);
}
| OnTestIterationStart:
PUSH RBP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x68
MOV RBX,RSI
CMP dword ptr [0x0425dea8],0x1
JZ 0x00126182
INC EDX
LEA RDI,[0x143492]
MOV ESI,EDX
XOR EAX,EAX
CALL 0x00109080
LAB_00126182:
LEA R15,[RSP + 0x38]
MOV qword ptr [R15 + -0x10],R15
MOV RSI,qword ptr [0x0425de58]
MOV RDX,qword ptr [0x0425de60]
ADD RDX,RSI
LEA R14,[RSP + 0x28]
MOV RDI,R14
CALL 0x0010f66a
MOV R14,qword ptr [R14]
TEST R14,R14
JZ 0x001261c4
LEA RSI,[0x1410c0]
MOV RDI,R14
CALL 0x001097b0
TEST EAX,EAX
JZ 0x001261e1
LAB_001261c4:
LEA RSI,[0x1434be]
LEA RDX,[0x1434d4]
MOV EDI,0x3
MOV RCX,R14
XOR EAX,EAX
CALL 0x00126396
LAB_001261e1:
LEA RDI,[0x1410d0]
LEA RSI,[0x1410f0]
XOR EDX,EDX
CALL 0x001264fa
TEST AL,AL
JZ 0x00126233
LAB_001261fa:
LEA RDI,[0x1410f0]
MOV ESI,0xffffffff
CALL 0x0012698d
MOV EBP,EAX
INC EBP
LEA RDI,[0x1410d0]
CALL 0x00109660
LEA RSI,[0x1434e0]
MOV EDI,0x3
MOV EDX,EBP
MOV RCX,RAX
XOR EAX,EAX
CALL 0x00126396
LAB_00126233:
CMP byte ptr [0x0425deae],0x1
JNZ 0x00126259
MOV RAX,qword ptr [RBX + 0x40]
MOV EDX,dword ptr [RAX + 0x21c]
LAB_00126246:
LEA RSI,[0x143504]
MOV EDI,0x3
XOR EAX,EAX
CALL 0x00126396
LAB_00126259:
LEA RSI,[0x143539]
MOV EDI,0x2
XOR EAX,EAX
CALL 0x00126396
MOV RDI,qword ptr [RBX + 0x40]
CALL 0x00120b46
LAB_00126275:
LEA RDX,[0x1424f5]
LEA RCX,[0x142908]
LEA RDI,[RSP + 0x8]
MOV ESI,EAX
CALL 0x00126bc4
MOV RCX,qword ptr [RBX + 0x40]
MOV RAX,qword ptr [RCX + 0xb8]
MOV RCX,qword ptr [RCX + 0xc0]
XOR ESI,ESI
LAB_001262a3:
CMP RAX,RCX
JZ 0x001262b7
MOV RDX,qword ptr [RAX]
MOVZX EDX,byte ptr [RDX + 0x70]
ADD ESI,EDX
ADD RAX,0x8
JMP 0x001262a3
LAB_001262b7:
MOV RBX,qword ptr [RSP + 0x8]
LAB_001262bc:
LEA RDX,[0x144535]
LEA RCX,[0x144540]
LEA RDI,[RSP + 0x48]
CALL 0x00126bc4
LAB_001262d4:
LEA R14,[RSP + 0x58]
MOV RDX,qword ptr [R14 + -0x10]
LEA RDI,[0x143547]
MOV RSI,RBX
XOR EAX,EAX
CALL 0x00109080
MOV RDI,qword ptr [R14 + -0x10]
CMP RDI,R14
JZ 0x00126304
MOV RSI,qword ptr [RSP + 0x58]
INC RSI
CALL 0x001094c0
LAB_00126304:
LEA RAX,[RSP + 0x18]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x0012631f
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001094c0
LAB_0012631f:
MOV RAX,qword ptr [0x00159f80]
MOV RDI,qword ptr [RAX]
CALL 0x001095f0
MOV RDI,qword ptr [RSP + 0x28]
CMP RDI,R15
JZ 0x00126345
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x001094c0
LAB_00126345:
ADD RSP,0x68
POP RBX
POP R14
POP R15
POP RBP
RET
|
/* testing::internal::PrettyUnitTestResultPrinter::OnTestIterationStart(testing::UnitTest const&,
int) */
void __thiscall
testing::internal::PrettyUnitTestResultPrinter::OnTestIterationStart
(PrettyUnitTestResultPrinter *this,UnitTest *param_1,int param_2)
{
long *plVar1;
char cVar2;
int iVar3;
uint uVar4;
char *pcVar5;
long *plVar6;
long *local_80 [2];
long local_70 [2];
long *local_60 [2];
long local_50 [2];
long *local_40 [2];
long local_30 [2];
if (FLAGS_gtest_repeat != 1) {
printf("\nRepeating all tests (iteration %d) . . .\n\n",(ulong)(param_2 + 1));
}
local_60[0] = local_50;
std::__cxx11::string::_M_construct<char*>
(local_60,FLAGS_gtest_filter_abi_cxx11_,DAT_0425de60 + FLAGS_gtest_filter_abi_cxx11_);
plVar6 = local_60[0];
if (local_60[0] != (long *)0x0) {
iVar3 = strcmp((char *)local_60[0],"*");
if (iVar3 == 0) goto LAB_001261e1;
}
/* try { // try from 001261c4 to 001261f5 has its CatchHandler @ 00126374 */
ColoredPrintf(3,"Note: %s filter = %s\n","Google Test",plVar6);
LAB_001261e1:
cVar2 = ShouldShard("GTEST_TOTAL_SHARDS","GTEST_SHARD_INDEX",false);
if (cVar2 != '\0') {
/* try { // try from 001261fa to 00126232 has its CatchHandler @ 00126372 */
iVar3 = Int32FromEnvOrDie("GTEST_SHARD_INDEX",-1);
pcVar5 = getenv("GTEST_TOTAL_SHARDS");
ColoredPrintf(3,"Note: This is test shard %d of %s.\n",iVar3 + 1,pcVar5);
}
if (FLAGS_gtest_shuffle == '\x01') {
/* try { // try from 00126246 to 0012626b has its CatchHandler @ 00126374 */
ColoredPrintf(3,"Note: Randomizing tests\' orders with a seed of %d .\n",
*(int4 *)(*(long *)(param_1 + 0x40) + 0x21c));
}
ColoredPrintf(2,"[==========] ");
uVar4 = UnitTestImpl::test_to_run_count(*(UnitTestImpl **)(param_1 + 0x40));
/* try { // try from 00126275 to 0012628e has its CatchHandler @ 00126370 */
FormatCountableNoun_abi_cxx11_((int)local_80,(char *)(ulong)uVar4,"test");
plVar1 = local_80[0];
pcVar5 = (char *)0x0;
for (plVar6 = *(long **)(*(long *)(param_1 + 0x40) + 0xb8);
plVar6 != *(long **)(*(long *)(param_1 + 0x40) + 0xc0); plVar6 = plVar6 + 1) {
pcVar5 = (char *)(ulong)((int)pcVar5 + (uint)*(byte *)(*plVar6 + 0x70));
}
/* try { // try from 001262bc to 001262d3 has its CatchHandler @ 00126350 */
FormatCountableNoun_abi_cxx11_((int)local_40,pcVar5,"test suite");
printf("Running %s from %s.\n",plVar1,local_40[0]);
if (local_40[0] != local_30) {
operator_delete(local_40[0],local_30[0] + 1);
}
if (local_80[0] != local_70) {
operator_delete(local_80[0],local_70[0] + 1);
}
fflush(*(FILE **)PTR_stdout_00159f80);
if (local_60[0] != local_50) {
operator_delete(local_60[0],local_50[0] + 1);
}
return;
}
| |
38,068 | google::protobuf::DescriptorBuilder::BuildFile(google::protobuf::FileDescriptorProto const&) | aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc | const FileDescriptor* DescriptorBuilder::BuildFile(
const FileDescriptorProto& proto) {
filename_ = proto.name();
// Check if the file already exists and is identical to the one being built.
// Note: This only works if the input is canonical -- that is, it
// fully-qualifies all type names, has no UninterpretedOptions, etc.
// This is fine, because this idempotency "feature" really only exists to
// accommodate one hack in the proto1->proto2 migration layer.
const FileDescriptor* existing_file = tables_->FindFile(filename_);
if (existing_file != nullptr) {
// File already in pool. Compare the existing one to the input.
if (ExistingFileMatchesProto(existing_file, proto)) {
// They're identical. Return the existing descriptor.
return existing_file;
}
// Not a match. The error will be detected and handled later.
}
// Check to see if this file is already on the pending files list.
// TODO(kenton): Allow recursive imports? It may not work with some
// (most?) programming languages. E.g., in C++, a forward declaration
// of a type is not sufficient to allow it to be used even in a
// generated header file due to inlining. This could perhaps be
// worked around using tricks involving inserting #include statements
// mid-file, but that's pretty ugly, and I'm pretty sure there are
// some languages out there that do not allow recursive dependencies
// at all.
for (size_t i = 0; i < tables_->pending_files_.size(); i++) {
if (tables_->pending_files_[i] == proto.name()) {
AddRecursiveImportError(proto, i);
return nullptr;
}
}
static const int kMaximumPackageLength = 511;
if (proto.package().size() > kMaximumPackageLength) {
AddError(proto.package(), proto, DescriptorPool::ErrorCollector::NAME,
"Package name is too long");
return nullptr;
}
// If we have a fallback_database_, and we aren't doing lazy import building,
// attempt to load all dependencies now, before checkpointing tables_. This
// avoids confusion with recursive checkpoints.
if (!pool_->lazily_build_dependencies_) {
if (pool_->fallback_database_ != nullptr) {
tables_->pending_files_.push_back(proto.name());
for (int i = 0; i < proto.dependency_size(); i++) {
if (tables_->FindFile(proto.dependency(i)) == nullptr &&
(pool_->underlay_ == nullptr ||
pool_->underlay_->FindFileByName(proto.dependency(i)) ==
nullptr)) {
// We don't care what this returns since we'll find out below anyway.
pool_->TryFindFileInFallbackDatabase(proto.dependency(i));
}
}
tables_->pending_files_.pop_back();
}
}
// Checkpoint the tables so that we can roll back if something goes wrong.
tables_->AddCheckpoint();
internal::FlatAllocator alloc;
PlanAllocationSize(proto, alloc);
alloc.FinalizePlanning(tables_);
FileDescriptor* result = BuildFileImpl(proto, alloc);
file_tables_->FinalizeTables();
if (result) {
tables_->ClearLastCheckpoint();
result->finished_building_ = true;
alloc.ExpectConsumed();
} else {
tables_->RollbackToLastCheckpoint();
}
return result;
} | O0 | cpp | google::protobuf::DescriptorBuilder::BuildFile(google::protobuf::FileDescriptorProto const&):
subq $0x188, %rsp # imm = 0x188
movq %rdi, 0x178(%rsp)
movq %rsi, 0x170(%rsp)
movq 0x178(%rsp), %rax
movq %rax, 0x40(%rsp)
movq 0x170(%rsp), %rdi
callq 0x759a0
movq 0x40(%rsp), %rdi
movq %rax, %rsi
addq $0x38, %rdi
callq 0x15990
movq 0x40(%rsp), %rsi
movq 0x8(%rsi), %rax
movq %rax, 0x48(%rsp)
addq $0x38, %rsi
leaq 0x158(%rsp), %rdi
callq 0x30550
movq 0x48(%rsp), %rdi
movq 0x158(%rsp), %rsi
movq 0x160(%rsp), %rdx
callq 0x744b0
movq %rax, 0x168(%rsp)
cmpq $0x0, 0x168(%rsp)
je 0x41eb0
movq 0x168(%rsp), %rdi
movq 0x170(%rsp), %rsi
callq 0x47a60
testb $0x1, %al
jne 0x41e99
jmp 0x41eae
movq 0x168(%rsp), %rax
movq %rax, 0x180(%rsp)
jmp 0x42222
jmp 0x41eb0
movq $0x0, 0x150(%rsp)
movq 0x40(%rsp), %rax
movq 0x150(%rsp), %rcx
movq %rcx, 0x38(%rsp)
movq 0x8(%rax), %rdi
callq 0x1e260
movq %rax, %rcx
movq 0x38(%rsp), %rax
cmpq %rcx, %rax
jae 0x41f6b
movq 0x40(%rsp), %rax
movq 0x8(%rax), %rdi
movq 0x150(%rsp), %rsi
callq 0x77c00
movq %rax, 0x30(%rsp)
movq 0x170(%rsp), %rdi
callq 0x759a0
movq 0x30(%rsp), %rdi
movq %rax, %rsi
callq 0x17780
testb $0x1, %al
jne 0x41f23
jmp 0x41f50
movq 0x40(%rsp), %rdi
movq 0x170(%rsp), %rsi
movq 0x150(%rsp), %rax
movl %eax, %edx
callq 0x47580
movq $0x0, 0x180(%rsp)
jmp 0x42222
jmp 0x41f52
movq 0x150(%rsp), %rax
addq $0x1, %rax
movq %rax, 0x150(%rsp)
jmp 0x41ebc
movq 0x170(%rsp), %rdi
callq 0x77c40
movq %rax, %rdi
callq 0x147d0
cmpq $0x1ff, %rax # imm = 0x1FF
jbe 0x41fc4
movq 0x170(%rsp), %rdi
callq 0x77c40
movq 0x40(%rsp), %rdi
movq %rax, %rsi
movq 0x170(%rsp), %rdx
xorl %ecx, %ecx
leaq 0x1abf78(%rip), %r8 # 0x1edf26
callq 0x42950
movq $0x0, 0x180(%rsp)
jmp 0x42222
movq 0x40(%rsp), %rax
movq (%rax), %rax
testb $0x1, 0x29(%rax)
jne 0x42172
movq 0x40(%rsp), %rax
movq (%rax), %rax
cmpq $0x0, 0x8(%rax)
je 0x42170
movq 0x40(%rsp), %rax
movq 0x8(%rax), %rax
movq %rax, 0x28(%rsp)
movq 0x170(%rsp), %rdi
callq 0x759a0
movq 0x28(%rsp), %rdi
movq %rax, %rsi
callq 0x77c50
movl $0x0, 0x14c(%rsp)
movl 0x14c(%rsp), %eax
movl %eax, 0x24(%rsp)
movq 0x170(%rsp), %rdi
callq 0x77cc0
movl %eax, %ecx
movl 0x24(%rsp), %eax
cmpl %ecx, %eax
jge 0x42162
movq 0x40(%rsp), %rax
movq 0x8(%rax), %rax
movq %rax, 0x18(%rsp)
movq 0x170(%rsp), %rdi
movl 0x14c(%rsp), %esi
callq 0x77c20
movq %rax, %rsi
leaq 0x138(%rsp), %rdi
callq 0x30550
movq 0x18(%rsp), %rdi
movq 0x138(%rsp), %rsi
movq 0x140(%rsp), %rdx
callq 0x744b0
movq %rax, %rcx
xorl %eax, %eax
cmpq $0x0, %rcx
movb %al, 0x23(%rsp)
jne 0x420f7
movq 0x40(%rsp), %rax
movq (%rax), %rcx
movb $0x1, %al
cmpq $0x0, 0x18(%rcx)
movb %al, 0x17(%rsp)
je 0x420ef
movq 0x40(%rsp), %rax
movq (%rax), %rax
movq 0x18(%rax), %rax
movq %rax, 0x8(%rsp)
movq 0x170(%rsp), %rdi
movl 0x14c(%rsp), %esi
callq 0x77c20
movq 0x8(%rsp), %rdi
movq %rax, %rsi
callq 0x34c90
cmpq $0x0, %rax
sete %al
movb %al, 0x17(%rsp)
movb 0x17(%rsp), %al
movb %al, 0x23(%rsp)
movb 0x23(%rsp), %al
testb $0x1, %al
jne 0x42101
jmp 0x4214a
movq 0x40(%rsp), %rax
movq (%rax), %rax
movq %rax, (%rsp)
movq 0x170(%rsp), %rdi
movl 0x14c(%rsp), %esi
callq 0x77c20
movq %rax, %rsi
leaq 0x128(%rsp), %rdi
callq 0x30550
movq (%rsp), %rdi
movq 0x128(%rsp), %rsi
movq 0x130(%rsp), %rdx
callq 0x34ef0
jmp 0x4214c
movl 0x14c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x14c(%rsp)
jmp 0x4201c
movq 0x40(%rsp), %rax
movq 0x8(%rax), %rdi
callq 0x77cd0
jmp 0x42172
movq 0x40(%rsp), %rax
movq 0x8(%rax), %rdi
callq 0x32a50
leaq 0x58(%rsp), %rdi
callq 0x774b0
movq 0x170(%rsp), %rdi
leaq 0x58(%rsp), %rsi
callq 0x47c50
movq 0x40(%rsp), %rsi
addq $0x8, %rsi
leaq 0x58(%rsp), %rdi
callq 0x47d90
movq 0x40(%rsp), %rdi
movq 0x170(%rsp), %rsi
leaq 0x58(%rsp), %rdx
callq 0x47f60
movq %rax, %rcx
movq 0x40(%rsp), %rax
movq %rcx, 0x50(%rsp)
movq 0x60(%rax), %rdi
callq 0x33f90
cmpq $0x0, 0x50(%rsp)
je 0x42207
movq 0x40(%rsp), %rax
movq 0x8(%rax), %rdi
callq 0x32a90
movq 0x50(%rsp), %rax
movb $0x1, 0x2(%rax)
leaq 0x58(%rsp), %rdi
callq 0x49ce0
jmp 0x42215
movq 0x40(%rsp), %rax
movq 0x8(%rax), %rdi
callq 0x32bc0
movq 0x50(%rsp), %rax
movq %rax, 0x180(%rsp)
movq 0x180(%rsp), %rax
addq $0x188, %rsp # imm = 0x188
retq
nopw %cs:(%rax,%rax)
| _ZN6google8protobuf17DescriptorBuilder9BuildFileERKNS0_19FileDescriptorProtoE:
sub rsp, 188h
mov [rsp+188h+var_10], rdi
mov [rsp+188h+var_18], rsi
mov rax, [rsp+188h+var_10]
mov [rsp+188h+var_148], rax
mov rdi, [rsp+188h+var_18]
call _ZNK6google8protobuf19FileDescriptorProto4nameB5cxx11Ev; google::protobuf::FileDescriptorProto::name(void)
mov rdi, [rsp+188h+var_148]
mov rsi, rax
add rdi, 38h ; '8'
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSERKS4_; std::string::operator=(std::string const&)
mov rsi, [rsp+188h+var_148]
mov rax, [rsi+8]
mov [rsp+188h+var_140], rax
add rsi, 38h ; '8'
lea rdi, [rsp+188h+var_30]
call _ZN6google8protobuf20stringpiece_internal11StringPieceC2ISaIcEEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcET_EE; google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(std::string const&)
mov rdi, [rsp+188h+var_140]
mov rsi, [rsp+188h+var_30]
mov rdx, [rsp+188h+var_28]
call _ZNK6google8protobuf14DescriptorPool6Tables8FindFileENS0_20stringpiece_internal11StringPieceE; google::protobuf::DescriptorPool::Tables::FindFile(google::protobuf::stringpiece_internal::StringPiece)
mov [rsp+188h+var_20], rax
cmp [rsp+188h+var_20], 0
jz short loc_41EB0
mov rdi, [rsp+188h+var_20]; this
mov rsi, [rsp+188h+var_18]; google::protobuf::FileDescriptor *
call _ZN6google8protobufL24ExistingFileMatchesProtoEPKNS0_14FileDescriptorERKNS0_19FileDescriptorProtoE; google::protobuf::ExistingFileMatchesProto(google::protobuf::FileDescriptor const*,google::protobuf::FileDescriptorProto const&)
test al, 1
jnz short loc_41E99
jmp short loc_41EAE
loc_41E99:
mov rax, [rsp+188h+var_20]
mov [rsp+188h+var_8], rax
jmp loc_42222
loc_41EAE:
jmp short $+2
loc_41EB0:
mov qword ptr [rsp+188h+var_38], 0
loc_41EBC:
mov rax, [rsp+188h+var_148]
mov rcx, qword ptr [rsp+188h+var_38]
mov [rsp+188h+var_150], rcx
mov rdi, [rax+8]
call _ZNKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE4sizeEv; std::vector<std::string>::size(void)
mov rcx, rax
mov rax, [rsp+188h+var_150]
cmp rax, rcx
jnb loc_41F6B
mov rax, [rsp+188h+var_148]
mov rdi, [rax+8]
mov rsi, qword ptr [rsp+188h+var_38]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EEixEm; std::vector<std::string>::operator[](ulong)
mov [rsp+188h+var_158], rax
mov rdi, [rsp+188h+var_18]
call _ZNK6google8protobuf19FileDescriptorProto4nameB5cxx11Ev; google::protobuf::FileDescriptorProto::name(void)
mov rdi, [rsp+188h+var_158]
mov rsi, rax
call _ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_
test al, 1
jnz short loc_41F23
jmp short loc_41F50
loc_41F23:
mov rdi, [rsp+188h+var_148]; this
mov rsi, [rsp+188h+var_18]; google::protobuf::FileDescriptorProto *
mov rax, qword ptr [rsp+188h+var_38]
mov edx, eax; int
call _ZN6google8protobuf17DescriptorBuilder23AddRecursiveImportErrorERKNS0_19FileDescriptorProtoEi; google::protobuf::DescriptorBuilder::AddRecursiveImportError(google::protobuf::FileDescriptorProto const&,int)
mov [rsp+188h+var_8], 0
jmp loc_42222
loc_41F50:
jmp short $+2
loc_41F52:
mov rax, qword ptr [rsp+188h+var_38]
add rax, 1
mov qword ptr [rsp+188h+var_38], rax
jmp loc_41EBC
loc_41F6B:
mov rdi, [rsp+188h+var_18]
call _ZNK6google8protobuf19FileDescriptorProto7packageB5cxx11Ev; google::protobuf::FileDescriptorProto::package(void)
mov rdi, rax
call _ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4sizeEv; std::string::size(void)
cmp rax, 1FFh
jbe short loc_41FC4
mov rdi, [rsp+188h+var_18]
call _ZNK6google8protobuf19FileDescriptorProto7packageB5cxx11Ev; google::protobuf::FileDescriptorProto::package(void)
mov rdi, [rsp+188h+var_148]
mov rsi, rax
mov rdx, [rsp+188h+var_18]
xor ecx, ecx
lea r8, aPackageNameIsT; "Package name is too long"
call _ZN6google8protobuf17DescriptorBuilder8AddErrorERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKNS0_7MessageENS0_14DescriptorPool14ErrorCollector13ErrorLocationEPKc; google::protobuf::DescriptorBuilder::AddError(std::string const&,google::protobuf::Message const&,google::protobuf::DescriptorPool::ErrorCollector::ErrorLocation,char const*)
mov [rsp+188h+var_8], 0
jmp loc_42222
loc_41FC4:
mov rax, [rsp+188h+var_148]
mov rax, [rax]
test byte ptr [rax+29h], 1
jnz loc_42172
mov rax, [rsp+188h+var_148]
mov rax, [rax]
cmp qword ptr [rax+8], 0
jz loc_42170
mov rax, [rsp+188h+var_148]
mov rax, [rax+8]
mov [rsp+188h+var_160], rax
mov rdi, [rsp+188h+var_18]
call _ZNK6google8protobuf19FileDescriptorProto4nameB5cxx11Ev; google::protobuf::FileDescriptorProto::name(void)
mov rdi, [rsp+188h+var_160]
mov rsi, rax
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE9push_backERKS5_; std::vector<std::string>::push_back(std::string const&)
mov [rsp+188h+var_3C], 0
loc_4201C:
mov eax, [rsp+188h+var_3C]
mov [rsp+188h+var_164], eax
mov rdi, [rsp+188h+var_18]; this
call _ZNK6google8protobuf19FileDescriptorProto15dependency_sizeEv; google::protobuf::FileDescriptorProto::dependency_size(void)
mov ecx, eax
mov eax, [rsp+188h+var_164]
cmp eax, ecx
jge loc_42162
mov rax, [rsp+188h+var_148]
mov rax, [rax+8]
mov [rsp+188h+var_170], rax
mov rdi, [rsp+188h+var_18]
mov esi, [rsp+188h+var_3C]
call _ZNK6google8protobuf19FileDescriptorProto10dependencyB5cxx11Ei; google::protobuf::FileDescriptorProto::dependency(int)
mov rsi, rax
lea rdi, [rsp+188h+var_50]
call _ZN6google8protobuf20stringpiece_internal11StringPieceC2ISaIcEEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcET_EE; google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(std::string const&)
mov rdi, [rsp+188h+var_170]
mov rsi, [rsp+188h+var_50]
mov rdx, [rsp+188h+var_48]
call _ZNK6google8protobuf14DescriptorPool6Tables8FindFileENS0_20stringpiece_internal11StringPieceE; google::protobuf::DescriptorPool::Tables::FindFile(google::protobuf::stringpiece_internal::StringPiece)
mov rcx, rax
xor eax, eax
cmp rcx, 0
mov [rsp+188h+var_165], al
jnz short loc_420F7
mov rax, [rsp+188h+var_148]
mov rcx, [rax]
mov al, 1
cmp qword ptr [rcx+18h], 0
mov [rsp+188h+var_171], al
jz short loc_420EF
mov rax, [rsp+188h+var_148]
mov rax, [rax]
mov rax, [rax+18h]
mov [rsp+188h+var_180], rax
mov rdi, [rsp+188h+var_18]
mov esi, [rsp+188h+var_3C]
call _ZNK6google8protobuf19FileDescriptorProto10dependencyB5cxx11Ei; google::protobuf::FileDescriptorProto::dependency(int)
mov rdi, [rsp+188h+var_180]
mov rsi, rax
call _ZNK6google8protobuf14DescriptorPool14FindFileByNameERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; google::protobuf::DescriptorPool::FindFileByName(std::string const&)
cmp rax, 0
setz al
mov [rsp+188h+var_171], al
loc_420EF:
mov al, [rsp+188h+var_171]
mov [rsp+188h+var_165], al
loc_420F7:
mov al, [rsp+188h+var_165]
test al, 1
jnz short loc_42101
jmp short loc_4214A
loc_42101:
mov rax, [rsp+188h+var_148]
mov rax, [rax]
mov [rsp+188h+var_188], rax
mov rdi, [rsp+188h+var_18]
mov esi, [rsp+188h+var_3C]
call _ZNK6google8protobuf19FileDescriptorProto10dependencyB5cxx11Ei; google::protobuf::FileDescriptorProto::dependency(int)
mov rsi, rax
lea rdi, [rsp+188h+var_60]
call _ZN6google8protobuf20stringpiece_internal11StringPieceC2ISaIcEEERKNSt7__cxx1112basic_stringIcSt11char_traitsIcET_EE; google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(std::string const&)
mov rdi, [rsp+188h+var_188]
mov rsi, [rsp+188h+var_60]
mov rdx, [rsp+188h+var_58]
call _ZNK6google8protobuf14DescriptorPool29TryFindFileInFallbackDatabaseENS0_20stringpiece_internal11StringPieceE; google::protobuf::DescriptorPool::TryFindFileInFallbackDatabase(google::protobuf::stringpiece_internal::StringPiece)
loc_4214A:
jmp short $+2
loc_4214C:
mov eax, [rsp+188h+var_3C]
add eax, 1
mov [rsp+188h+var_3C], eax
jmp loc_4201C
loc_42162:
mov rax, [rsp+188h+var_148]
mov rdi, [rax+8]
call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE8pop_backEv; std::vector<std::string>::pop_back(void)
loc_42170:
jmp short $+2
loc_42172:
mov rax, [rsp+188h+var_148]
mov rdi, [rax+8]; this
call _ZN6google8protobuf14DescriptorPool6Tables13AddCheckpointEv; google::protobuf::DescriptorPool::Tables::AddCheckpoint(void)
lea rdi, [rsp+188h+var_130]; this
call _ZN6google8protobuf8internal13FlatAllocatorC2Ev; google::protobuf::internal::FlatAllocator::FlatAllocator(void)
mov rdi, [rsp+188h+var_18]; this
lea rsi, [rsp+188h+var_130]; google::protobuf::FileDescriptorProto *
call _ZN6google8protobufL18PlanAllocationSizeERKNS0_19FileDescriptorProtoERNS0_8internal13FlatAllocatorE; google::protobuf::PlanAllocationSize(google::protobuf::FileDescriptorProto const&,google::protobuf::internal::FlatAllocator &)
mov rsi, [rsp+188h+var_148]
add rsi, 8
lea rdi, [rsp+188h+var_130]
call _ZN6google8protobuf12_GLOBAL__N_117FlatAllocatorImplIJcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_14SourceCodeInfoENS0_20FileDescriptorTablesENS0_14MessageOptionsENS0_12FieldOptionsENS0_11EnumOptionsENS0_16EnumValueOptionsENS0_21ExtensionRangeOptionsENS0_12OneofOptionsENS0_14ServiceOptionsENS0_13MethodOptionsENS0_11FileOptionsEEE16FinalizePlanningIPNS0_14DescriptorPool6TablesEEEvRT_; google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::FinalizePlanning<google::protobuf::DescriptorPool::Tables *>(google::protobuf::DescriptorPool::Tables * &)
mov rdi, [rsp+188h+var_148]; this
mov rsi, [rsp+188h+var_18]; google::protobuf::FileDescriptorProto *
lea rdx, [rsp+188h+var_130]; google::protobuf::internal::FlatAllocator *
call _ZN6google8protobuf17DescriptorBuilder13BuildFileImplERKNS0_19FileDescriptorProtoERNS0_8internal13FlatAllocatorE; google::protobuf::DescriptorBuilder::BuildFileImpl(google::protobuf::FileDescriptorProto const&,google::protobuf::internal::FlatAllocator &)
mov rcx, rax
mov rax, [rsp+188h+var_148]
mov [rsp+188h+var_138], rcx
mov rdi, [rax+60h]; this
call _ZN6google8protobuf20FileDescriptorTables14FinalizeTablesEv; google::protobuf::FileDescriptorTables::FinalizeTables(void)
cmp [rsp+188h+var_138], 0
jz short loc_42207
mov rax, [rsp+188h+var_148]
mov rdi, [rax+8]; this
call _ZN6google8protobuf14DescriptorPool6Tables19ClearLastCheckpointEv; google::protobuf::DescriptorPool::Tables::ClearLastCheckpoint(void)
mov rax, [rsp+188h+var_138]
mov byte ptr [rax+2], 1
lea rdi, [rsp+188h+var_130]
call _ZNK6google8protobuf12_GLOBAL__N_117FlatAllocatorImplIJcNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_14SourceCodeInfoENS0_20FileDescriptorTablesENS0_14MessageOptionsENS0_12FieldOptionsENS0_11EnumOptionsENS0_16EnumValueOptionsENS0_21ExtensionRangeOptionsENS0_12OneofOptionsENS0_14ServiceOptionsENS0_13MethodOptionsENS0_11FileOptionsEEE14ExpectConsumedEv; google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::ExpectConsumed(void)
jmp short loc_42215
loc_42207:
mov rax, [rsp+188h+var_148]
mov rdi, [rax+8]; this
call _ZN6google8protobuf14DescriptorPool6Tables24RollbackToLastCheckpointEv; google::protobuf::DescriptorPool::Tables::RollbackToLastCheckpoint(void)
loc_42215:
mov rax, [rsp+188h+var_138]
mov [rsp+188h+var_8], rax
loc_42222:
mov rax, [rsp+188h+var_8]
add rsp, 188h
retn
| google::protobuf * google::protobuf::DescriptorBuilder::BuildFile(
google::protobuf::DescriptorPool::Tables **this,
const google::protobuf::FileDescriptorProto *a2)
{
long long v2; // rax
const google::protobuf::FileDescriptorProto *v3; // rdx
long long v4; // rax
long long v5; // rax
int v6; // eax
int v7; // r9d
long long v8; // rax
long long v9; // rax
long long v10; // rax
long long v11; // rax
google::protobuf::internal::FlatAllocator *v12; // rdx
int v13; // edx
int v14; // ecx
int v15; // r8d
int v16; // r9d
google::protobuf::DescriptorPool *v18; // [rsp+0h] [rbp-188h]
long long v19; // [rsp+8h] [rbp-180h]
bool v20; // [rsp+17h] [rbp-171h]
google::protobuf::DescriptorPool::Tables *v21; // [rsp+18h] [rbp-170h]
bool v22; // [rsp+23h] [rbp-165h]
int v23; // [rsp+24h] [rbp-164h]
google::protobuf::DescriptorPool::Tables *v24; // [rsp+28h] [rbp-160h]
long long v25; // [rsp+30h] [rbp-158h]
google::protobuf::DescriptorPool::Tables *v26; // [rsp+48h] [rbp-140h]
long long v27; // [rsp+50h] [rbp-138h]
_BYTE v28[208]; // [rsp+58h] [rbp-130h] BYREF
long long v29[2]; // [rsp+128h] [rbp-60h] BYREF
long long v30[2]; // [rsp+138h] [rbp-50h] BYREF
unsigned int i; // [rsp+14Ch] [rbp-3Ch]
int v32[2]; // [rsp+150h] [rbp-38h]
long long v33[2]; // [rsp+158h] [rbp-30h] BYREF
google::protobuf *File; // [rsp+168h] [rbp-20h]
google::protobuf::FileDescriptorProto *v35; // [rsp+170h] [rbp-18h]
google::protobuf::DescriptorBuilder *v36; // [rsp+178h] [rbp-10h]
v36 = (google::protobuf::DescriptorBuilder *)this;
v35 = a2;
v2 = google::protobuf::FileDescriptorProto::name[abi:cxx11](a2);
std::string::operator=((long long)(this + 7), v2);
v26 = this[1];
google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(v33, (long long)(this + 7));
File = (google::protobuf *)google::protobuf::DescriptorPool::Tables::FindFile(v26, v33[0], v33[1]);
if ( File && (google::protobuf::ExistingFileMatchesProto(File, v35, v3) & 1) != 0 )
return File;
for ( *(_QWORD *)v32 = 0LL; *(_QWORD *)v32 < (unsigned long long)std::vector<std::string>::size(this[1]); ++*(_QWORD *)v32 )
{
v25 = std::vector<std::string>::operator[](this[1], *(_QWORD *)v32);
v4 = google::protobuf::FileDescriptorProto::name[abi:cxx11](v35);
if ( (std::operator==<char>(v25, v4) & 1) != 0 )
{
google::protobuf::DescriptorBuilder::AddRecursiveImportError(
(google::protobuf::DescriptorBuilder *)this,
v35,
v32[0]);
return 0LL;
}
}
v5 = google::protobuf::FileDescriptorProto::package[abi:cxx11](v35);
if ( (unsigned long long)std::string::size(v5) <= 0x1FF )
{
if ( (*((_BYTE *)*this + 41) & 1) == 0 && *((_QWORD *)*this + 1) )
{
v24 = this[1];
v8 = google::protobuf::FileDescriptorProto::name[abi:cxx11](v35);
std::vector<std::string>::push_back(v24, v8);
for ( i = 0; ; ++i )
{
v23 = i;
if ( v23 >= (int)google::protobuf::FileDescriptorProto::dependency_size(v35) )
break;
v21 = this[1];
v9 = google::protobuf::FileDescriptorProto::dependency[abi:cxx11](v35, i);
google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(v30, v9);
v22 = 0;
if ( !google::protobuf::DescriptorPool::Tables::FindFile(v21, v30[0], v30[1]) )
{
v20 = 1;
if ( *((_QWORD *)*this + 3) )
{
v19 = *((_QWORD *)*this + 3);
v10 = google::protobuf::FileDescriptorProto::dependency[abi:cxx11](v35, i);
v20 = google::protobuf::DescriptorPool::FindFileByName(v19, v10) == 0;
}
v22 = v20;
}
if ( v22 )
{
v18 = *this;
v11 = google::protobuf::FileDescriptorProto::dependency[abi:cxx11](v35, i);
google::protobuf::stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>(v29, v11);
google::protobuf::DescriptorPool::TryFindFileInFallbackDatabase(v18, v29[0], v29[1]);
}
}
std::vector<std::string>::pop_back(this[1]);
}
google::protobuf::DescriptorPool::Tables::AddCheckpoint(this[1]);
google::protobuf::internal::FlatAllocator::FlatAllocator((google::protobuf::internal::FlatAllocator *)v28);
google::protobuf::PlanAllocationSize(v35, (const google::protobuf::FileDescriptorProto *)v28, v12);
google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::FinalizePlanning<google::protobuf::DescriptorPool::Tables *>(
(unsigned int)v28,
(_DWORD)this + 8,
v13,
v14,
v15,
v16,
(_DWORD)v18,
v19);
v27 = google::protobuf::DescriptorBuilder::BuildFileImpl(
(google::protobuf::DescriptorBuilder *)this,
v35,
(google::protobuf::internal::FlatAllocator *)v28);
google::protobuf::FileDescriptorTables::FinalizeTables(this[12]);
if ( v27 )
{
google::protobuf::DescriptorPool::Tables::ClearLastCheckpoint(this[1]);
*(_BYTE *)(v27 + 2) = 1;
google::protobuf::`anonymous namespace'::FlatAllocatorImpl<char,std::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>::ExpectConsumed(v28);
}
else
{
google::protobuf::DescriptorPool::Tables::RollbackToLastCheckpoint(this[1]);
}
return (google::protobuf *)v27;
}
else
{
v6 = google::protobuf::FileDescriptorProto::package[abi:cxx11](v35);
google::protobuf::DescriptorBuilder::AddError(
(_DWORD)this,
v6,
(_DWORD)v35,
0,
(unsigned int)"Package name is too long",
v7);
return 0LL;
}
}
| BuildFile:
SUB RSP,0x188
MOV qword ptr [RSP + 0x178],RDI
MOV qword ptr [RSP + 0x170],RSI
MOV RAX,qword ptr [RSP + 0x178]
MOV qword ptr [RSP + 0x40],RAX
MOV RDI,qword ptr [RSP + 0x170]
CALL 0x001759a0
MOV RDI,qword ptr [RSP + 0x40]
MOV RSI,RAX
ADD RDI,0x38
CALL 0x00115990
MOV RSI,qword ptr [RSP + 0x40]
MOV RAX,qword ptr [RSI + 0x8]
MOV qword ptr [RSP + 0x48],RAX
ADD RSI,0x38
LEA RDI,[RSP + 0x158]
CALL 0x00130550
MOV RDI,qword ptr [RSP + 0x48]
MOV RSI,qword ptr [RSP + 0x158]
MOV RDX,qword ptr [RSP + 0x160]
CALL 0x001744b0
MOV qword ptr [RSP + 0x168],RAX
CMP qword ptr [RSP + 0x168],0x0
JZ 0x00141eb0
MOV RDI,qword ptr [RSP + 0x168]
MOV RSI,qword ptr [RSP + 0x170]
CALL 0x00147a60
TEST AL,0x1
JNZ 0x00141e99
JMP 0x00141eae
LAB_00141e99:
MOV RAX,qword ptr [RSP + 0x168]
MOV qword ptr [RSP + 0x180],RAX
JMP 0x00142222
LAB_00141eae:
JMP 0x00141eb0
LAB_00141eb0:
MOV qword ptr [RSP + 0x150],0x0
LAB_00141ebc:
MOV RAX,qword ptr [RSP + 0x40]
MOV RCX,qword ptr [RSP + 0x150]
MOV qword ptr [RSP + 0x38],RCX
MOV RDI,qword ptr [RAX + 0x8]
CALL 0x0011e260
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x38]
CMP RAX,RCX
JNC 0x00141f6b
MOV RAX,qword ptr [RSP + 0x40]
MOV RDI,qword ptr [RAX + 0x8]
MOV RSI,qword ptr [RSP + 0x150]
CALL 0x00177c00
MOV qword ptr [RSP + 0x30],RAX
MOV RDI,qword ptr [RSP + 0x170]
CALL 0x001759a0
MOV RDI,qword ptr [RSP + 0x30]
MOV RSI,RAX
CALL 0x00117780
TEST AL,0x1
JNZ 0x00141f23
JMP 0x00141f50
LAB_00141f23:
MOV RDI,qword ptr [RSP + 0x40]
MOV RSI,qword ptr [RSP + 0x170]
MOV RAX,qword ptr [RSP + 0x150]
MOV EDX,EAX
CALL 0x00147580
MOV qword ptr [RSP + 0x180],0x0
JMP 0x00142222
LAB_00141f50:
JMP 0x00141f52
LAB_00141f52:
MOV RAX,qword ptr [RSP + 0x150]
ADD RAX,0x1
MOV qword ptr [RSP + 0x150],RAX
JMP 0x00141ebc
LAB_00141f6b:
MOV RDI,qword ptr [RSP + 0x170]
CALL 0x00177c40
MOV RDI,RAX
CALL 0x001147d0
CMP RAX,0x1ff
JBE 0x00141fc4
MOV RDI,qword ptr [RSP + 0x170]
CALL 0x00177c40
MOV RDI,qword ptr [RSP + 0x40]
MOV RSI,RAX
MOV RDX,qword ptr [RSP + 0x170]
XOR ECX,ECX
LEA R8,[0x2edf26]
CALL 0x00142950
MOV qword ptr [RSP + 0x180],0x0
JMP 0x00142222
LAB_00141fc4:
MOV RAX,qword ptr [RSP + 0x40]
MOV RAX,qword ptr [RAX]
TEST byte ptr [RAX + 0x29],0x1
JNZ 0x00142172
MOV RAX,qword ptr [RSP + 0x40]
MOV RAX,qword ptr [RAX]
CMP qword ptr [RAX + 0x8],0x0
JZ 0x00142170
MOV RAX,qword ptr [RSP + 0x40]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x28],RAX
MOV RDI,qword ptr [RSP + 0x170]
CALL 0x001759a0
MOV RDI,qword ptr [RSP + 0x28]
MOV RSI,RAX
CALL 0x00177c50
MOV dword ptr [RSP + 0x14c],0x0
LAB_0014201c:
MOV EAX,dword ptr [RSP + 0x14c]
MOV dword ptr [RSP + 0x24],EAX
MOV RDI,qword ptr [RSP + 0x170]
CALL 0x00177cc0
MOV ECX,EAX
MOV EAX,dword ptr [RSP + 0x24]
CMP EAX,ECX
JGE 0x00142162
MOV RAX,qword ptr [RSP + 0x40]
MOV RAX,qword ptr [RAX + 0x8]
MOV qword ptr [RSP + 0x18],RAX
MOV RDI,qword ptr [RSP + 0x170]
MOV ESI,dword ptr [RSP + 0x14c]
CALL 0x00177c20
MOV RSI,RAX
LEA RDI,[RSP + 0x138]
CALL 0x00130550
MOV RDI,qword ptr [RSP + 0x18]
MOV RSI,qword ptr [RSP + 0x138]
MOV RDX,qword ptr [RSP + 0x140]
CALL 0x001744b0
MOV RCX,RAX
XOR EAX,EAX
CMP RCX,0x0
MOV byte ptr [RSP + 0x23],AL
JNZ 0x001420f7
MOV RAX,qword ptr [RSP + 0x40]
MOV RCX,qword ptr [RAX]
MOV AL,0x1
CMP qword ptr [RCX + 0x18],0x0
MOV byte ptr [RSP + 0x17],AL
JZ 0x001420ef
MOV RAX,qword ptr [RSP + 0x40]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x18]
MOV qword ptr [RSP + 0x8],RAX
MOV RDI,qword ptr [RSP + 0x170]
MOV ESI,dword ptr [RSP + 0x14c]
CALL 0x00177c20
MOV RDI,qword ptr [RSP + 0x8]
MOV RSI,RAX
CALL 0x00134c90
CMP RAX,0x0
SETZ AL
MOV byte ptr [RSP + 0x17],AL
LAB_001420ef:
MOV AL,byte ptr [RSP + 0x17]
MOV byte ptr [RSP + 0x23],AL
LAB_001420f7:
MOV AL,byte ptr [RSP + 0x23]
TEST AL,0x1
JNZ 0x00142101
JMP 0x0014214a
LAB_00142101:
MOV RAX,qword ptr [RSP + 0x40]
MOV RAX,qword ptr [RAX]
MOV qword ptr [RSP],RAX
MOV RDI,qword ptr [RSP + 0x170]
MOV ESI,dword ptr [RSP + 0x14c]
CALL 0x00177c20
MOV RSI,RAX
LEA RDI,[RSP + 0x128]
CALL 0x00130550
MOV RDI,qword ptr [RSP]
MOV RSI,qword ptr [RSP + 0x128]
MOV RDX,qword ptr [RSP + 0x130]
CALL 0x00134ef0
LAB_0014214a:
JMP 0x0014214c
LAB_0014214c:
MOV EAX,dword ptr [RSP + 0x14c]
ADD EAX,0x1
MOV dword ptr [RSP + 0x14c],EAX
JMP 0x0014201c
LAB_00142162:
MOV RAX,qword ptr [RSP + 0x40]
MOV RDI,qword ptr [RAX + 0x8]
CALL 0x00177cd0
LAB_00142170:
JMP 0x00142172
LAB_00142172:
MOV RAX,qword ptr [RSP + 0x40]
MOV RDI,qword ptr [RAX + 0x8]
CALL 0x00132a50
LEA RDI,[RSP + 0x58]
CALL 0x001774b0
MOV RDI,qword ptr [RSP + 0x170]
LEA RSI,[RSP + 0x58]
CALL 0x00147c50
MOV RSI,qword ptr [RSP + 0x40]
ADD RSI,0x8
LEA RDI,[RSP + 0x58]
CALL 0x00147d90
MOV RDI,qword ptr [RSP + 0x40]
MOV RSI,qword ptr [RSP + 0x170]
LEA RDX,[RSP + 0x58]
CALL 0x00147f60
MOV RCX,RAX
MOV RAX,qword ptr [RSP + 0x40]
MOV qword ptr [RSP + 0x50],RCX
MOV RDI,qword ptr [RAX + 0x60]
CALL 0x00133f90
CMP qword ptr [RSP + 0x50],0x0
JZ 0x00142207
MOV RAX,qword ptr [RSP + 0x40]
MOV RDI,qword ptr [RAX + 0x8]
CALL 0x00132a90
MOV RAX,qword ptr [RSP + 0x50]
MOV byte ptr [RAX + 0x2],0x1
LEA RDI,[RSP + 0x58]
CALL 0x00149ce0
JMP 0x00142215
LAB_00142207:
MOV RAX,qword ptr [RSP + 0x40]
MOV RDI,qword ptr [RAX + 0x8]
CALL 0x00132bc0
LAB_00142215:
MOV RAX,qword ptr [RSP + 0x50]
MOV qword ptr [RSP + 0x180],RAX
LAB_00142222:
MOV RAX,qword ptr [RSP + 0x180]
ADD RSP,0x188
RET
|
/* google::protobuf::DescriptorBuilder::BuildFile(google::protobuf::FileDescriptorProto const&) */
FileDescriptor * __thiscall
google::protobuf::DescriptorBuilder::BuildFile(DescriptorBuilder *this,FileDescriptorProto *param_1)
{
vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *this_00;
DescriptorPool *this_01;
int iVar1;
int iVar2;
string *psVar3;
ulong uVar4;
ulong uVar5;
string *psVar6;
int8 uVar7;
long lVar8;
FileDescriptor *pFVar9;
bool bVar10;
FlatAllocator local_130 [208];
int8 local_60;
int8 local_58;
int8 local_50;
int8 local_48;
int local_3c;
ulong local_38;
int8 local_30;
int8 local_28;
FileDescriptor *local_20;
FileDescriptorProto *local_18;
DescriptorBuilder *local_10;
FileDescriptor *local_8;
local_18 = param_1;
local_10 = this;
psVar3 = (string *)FileDescriptorProto::name_abi_cxx11_(param_1);
std::__cxx11::string::operator=((string *)(this + 0x38),psVar3);
uVar7 = *(int8 *)(this + 8);
stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>
((StringPiece *)&local_30,(string *)(this + 0x38));
local_20 = (FileDescriptor *)DescriptorPool::Tables::FindFile(uVar7,local_30,local_28);
if ((local_20 == (FileDescriptor *)0x0) ||
(uVar4 = ExistingFileMatchesProto(local_20,local_18), (uVar4 & 1) == 0)) {
for (local_38 = 0; uVar4 = local_38,
uVar5 = std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::size
(*(vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> **)
(this + 8)), uVar4 < uVar5; local_38 = local_38 + 1) {
psVar3 = (string *)
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::operator[]
(*(vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> **)
(this + 8),local_38);
psVar6 = (string *)FileDescriptorProto::name_abi_cxx11_(local_18);
uVar4 = std::operator==(psVar3,psVar6);
if ((uVar4 & 1) != 0) {
AddRecursiveImportError(this,local_18,(int)local_38);
return (FileDescriptor *)0x0;
}
}
psVar3 = (string *)FileDescriptorProto::package_abi_cxx11_(local_18);
uVar4 = std::__cxx11::string::size(psVar3);
if (uVar4 < 0x200) {
if (((*(byte *)(*(long *)this + 0x29) & 1) == 0) && (*(long *)(*(long *)this + 8) != 0)) {
this_00 = *(vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> **)(this + 8);
psVar3 = (string *)FileDescriptorProto::name_abi_cxx11_(local_18);
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::push_back
(this_00,psVar3);
for (local_3c = 0; iVar1 = local_3c, iVar2 = FileDescriptorProto::dependency_size(local_18),
iVar1 < iVar2; local_3c = local_3c + 1) {
uVar7 = *(int8 *)(this + 8);
psVar3 = (string *)FileDescriptorProto::dependency_abi_cxx11_(local_18,local_3c);
stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>
((StringPiece *)&local_50,psVar3);
lVar8 = DescriptorPool::Tables::FindFile(uVar7,local_50,local_48);
bVar10 = false;
if ((lVar8 == 0) && (bVar10 = true, *(long *)(*(long *)this + 0x18) != 0)) {
this_01 = *(DescriptorPool **)(*(long *)this + 0x18);
psVar3 = (string *)FileDescriptorProto::dependency_abi_cxx11_(local_18,local_3c);
lVar8 = DescriptorPool::FindFileByName(this_01,psVar3);
bVar10 = lVar8 == 0;
}
if (bVar10) {
uVar7 = *(int8 *)this;
psVar3 = (string *)FileDescriptorProto::dependency_abi_cxx11_(local_18,local_3c);
stringpiece_internal::StringPiece::StringPiece<std::allocator<char>>
((StringPiece *)&local_60,psVar3);
DescriptorPool::TryFindFileInFallbackDatabase(uVar7,local_60,local_58);
}
}
std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::pop_back
(*(vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> **)(this + 8)
);
}
DescriptorPool::Tables::AddCheckpoint(*(Tables **)(this + 8));
internal::FlatAllocator::FlatAllocator(local_130);
PlanAllocationSize(local_18,local_130);
(anonymous_namespace)::
FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>
::FinalizePlanning<google::protobuf::DescriptorPool::Tables*>
((FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>
*)local_130,(Tables **)(this + 8));
pFVar9 = (FileDescriptor *)BuildFileImpl(this,local_18,local_130);
FileDescriptorTables::FinalizeTables();
local_8 = pFVar9;
if (pFVar9 == (FileDescriptor *)0x0) {
DescriptorPool::Tables::RollbackToLastCheckpoint(*(Tables **)(this + 8));
}
else {
DescriptorPool::Tables::ClearLastCheckpoint(*(Tables **)(this + 8));
pFVar9[2] = (FileDescriptor)0x1;
(anonymous_namespace)::
FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>
::ExpectConsumed((FlatAllocatorImpl<char,std::__cxx11::string,google::protobuf::SourceCodeInfo,google::protobuf::FileDescriptorTables,google::protobuf::MessageOptions,google::protobuf::FieldOptions,google::protobuf::EnumOptions,google::protobuf::EnumValueOptions,google::protobuf::ExtensionRangeOptions,google::protobuf::OneofOptions,google::protobuf::ServiceOptions,google::protobuf::MethodOptions,google::protobuf::FileOptions>
*)local_130);
}
}
else {
uVar7 = FileDescriptorProto::package_abi_cxx11_(local_18);
AddError(this,uVar7,local_18,0,"Package name is too long");
local_8 = (FileDescriptor *)0x0;
}
}
else {
local_8 = local_20;
}
return local_8;
}
| |
38,069 | testing::internal::StreamingListener::OnTestStart(testing::TestInfo const&) | giladroyz[P]FindPeaks/build_O3/_deps/googletest-src/googletest/src/gtest-internal-inl.h | void OnTestStart(const TestInfo& test_info) override {
SendLn(std::string("event=TestStart&name=") + test_info.name());
} | O3 | c | testing::internal::StreamingListener::OnTestStart(testing::TestInfo const&):
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x48, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x38(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0xc973(%rip), %rsi # 0x44513
leaq 0xc981(%rip), %rdx # 0x44528
leaq 0x28(%rsp), %r15
movq %r15, %rdi
callq 0x3911e
movq 0x20(%r14), %rsi
movq %r15, %rdi
callq 0x8a50
leaq 0x18(%rsp), %r14
movq %r14, -0x10(%r14)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x37be7
movq %rdx, 0x8(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x18(%rsp)
jmp 0x37bee
movups (%rcx), %xmm0
movups %xmm0, (%r14)
movq 0x8(%rax), %rdx
leaq 0x8(%rsp), %rsi
movq %rdx, 0x8(%rsi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq 0x8(%rbx), %rdi
callq 0x3903c
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0x37c2a
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x84e0
movq 0x28(%rsp), %rdi
cmpq %r12, %rdi
je 0x37c41
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x84e0
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r14, %rdi
je 0x37c6c
movq 0x18(%rsp), %rsi
incq %rsi
callq 0x84e0
jmp 0x37c6c
movq %rax, %rbx
movq 0x28(%rsp), %rdi
cmpq %r12, %rdi
je 0x37c83
movq 0x38(%rsp), %rsi
incq %rsi
callq 0x84e0
movq %rbx, %rdi
callq 0x8990
nop
| _ZN7testing8internal17StreamingListener11OnTestStartERKNS_8TestInfoE:
push r15
push r14
push r12
push rbx
sub rsp, 48h
mov r14, rsi
mov rbx, rdi
lea r12, [rsp+68h+var_30]
mov [r12-10h], r12
lea rsi, aEventTeststart; "event=TestStart&name="
lea rdx, aEventTeststart+15h; ""
lea r15, [rsp+68h+var_40]
mov rdi, r15
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
mov rsi, [r14+20h]
mov rdi, r15
call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*)
lea r14, [rsp+68h+var_50]
mov [r14-10h], r14
mov rdx, [rax]
mov rcx, rax
add rcx, 10h
cmp rdx, rcx
jz short loc_37BE7
mov [rsp+68h+var_60], rdx
mov rdx, [rcx]
mov [rsp+68h+var_50], rdx
jmp short loc_37BEE
loc_37BE7:
movups xmm0, xmmword ptr [rcx]
movups xmmword ptr [r14], xmm0
loc_37BEE:
mov rdx, [rax+8]
lea rsi, [rsp+68h+var_60]
mov [rsi+8], rdx
mov [rax], rcx
mov qword ptr [rax+8], 0
mov byte ptr [rax+10h], 0
mov rdi, [rbx+8]
call _ZN7testing8internal17StreamingListener20AbstractSocketWriter6SendLnERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; testing::internal::StreamingListener::AbstractSocketWriter::SendLn(std::string const&)
mov rdi, [rsp+68h+var_60]; void *
cmp rdi, r14
jz short loc_37C2A
mov rsi, [rsp+68h+var_50]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_37C2A:
mov rdi, [rsp+68h+var_40]; void *
cmp rdi, r12
jz short loc_37C41
mov rsi, [rsp+68h+var_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_37C41:
add rsp, 48h
pop rbx
pop r12
pop r14
pop r15
retn
mov rbx, rax
mov rdi, [rsp+arg_0]; void *
cmp rdi, r14
jz short loc_37C6C
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_37C6C
mov rbx, rax
loc_37C6C:
mov rdi, [rsp+arg_20]; void *
cmp rdi, r12
jz short loc_37C83
mov rsi, [rsp+arg_30]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_37C83:
mov rdi, rbx
call __Unwind_Resume
| void testing::internal::StreamingListener::OnTestStart(
testing::internal::StreamingListener *this,
const char **a2)
{
long long v2; // rax
int v3; // r8d
int v4; // r9d
__int128 *v5; // rcx
int v6; // edx
void *v7; // [rsp+8h] [rbp-60h] BYREF
long long v8; // [rsp+10h] [rbp-58h]
__int128 v9; // [rsp+18h] [rbp-50h] BYREF
void *v10[2]; // [rsp+28h] [rbp-40h] BYREF
_QWORD v11[6]; // [rsp+38h] [rbp-30h] BYREF
v10[0] = v11;
std::string::_M_construct<char const*>(v10, "event=TestStart&name=", "");
v2 = std::string::append(v10, a2[4]);
v7 = &v9;
v5 = (__int128 *)(v2 + 16);
if ( *(_QWORD *)v2 == v2 + 16 )
{
v9 = *v5;
}
else
{
v7 = *(void **)v2;
*(_QWORD *)&v9 = *(_QWORD *)v5;
}
v8 = *(_QWORD *)(v2 + 8);
v6 = v8;
*(_QWORD *)v2 = v5;
*(_QWORD *)(v2 + 8) = 0LL;
*(_BYTE *)(v2 + 16) = 0;
testing::internal::StreamingListener::AbstractSocketWriter::SendLn(
*((_QWORD *)this + 1),
(unsigned int)&v7,
v6,
(_DWORD)v5,
v3,
v4);
if ( v7 != &v9 )
operator delete(v7, v9 + 1);
if ( v10[0] != v11 )
operator delete(v10[0], v11[0] + 1LL);
}
| OnTestStart:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x48
MOV R14,RSI
MOV RBX,RDI
LEA R12,[RSP + 0x38]
MOV qword ptr [R12 + -0x10],R12
LEA RSI,[0x144513]
LEA RDX,[0x144528]
LEA R15,[RSP + 0x28]
MOV RDI,R15
CALL 0x0013911e
MOV RSI,qword ptr [R14 + 0x20]
LAB_00137bb8:
MOV RDI,R15
CALL 0x00108a50
LEA R14,[RSP + 0x18]
MOV qword ptr [R14 + -0x10],R14
MOV RDX,qword ptr [RAX]
MOV RCX,RAX
ADD RCX,0x10
CMP RDX,RCX
JZ 0x00137be7
MOV qword ptr [RSP + 0x8],RDX
MOV RDX,qword ptr [RCX]
MOV qword ptr [RSP + 0x18],RDX
JMP 0x00137bee
LAB_00137be7:
MOVUPS XMM0,xmmword ptr [RCX]
MOVUPS xmmword ptr [R14],XMM0
LAB_00137bee:
MOV RDX,qword ptr [RAX + 0x8]
LEA RSI,[RSP + 0x8]
MOV qword ptr [RSI + 0x8],RDX
MOV qword ptr [RAX],RCX
MOV qword ptr [RAX + 0x8],0x0
MOV byte ptr [RAX + 0x10],0x0
MOV RDI,qword ptr [RBX + 0x8]
LAB_00137c0e:
CALL 0x0013903c
LAB_00137c13:
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,R14
JZ 0x00137c2a
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x001084e0
LAB_00137c2a:
MOV RDI,qword ptr [RSP + 0x28]
CMP RDI,R12
JZ 0x00137c41
MOV RSI,qword ptr [RSP + 0x38]
INC RSI
CALL 0x001084e0
LAB_00137c41:
ADD RSP,0x48
POP RBX
POP R12
POP R14
POP R15
RET
|
/* testing::internal::StreamingListener::OnTestStart(testing::TestInfo const&) */
void testing::internal::StreamingListener::OnTestStart(TestInfo *param_1)
{
long *plVar1;
long *plVar2;
long *local_60;
long local_58;
long local_50;
long lStack_48;
long *local_40 [2];
long local_30 [2];
local_40[0] = local_30;
std::__cxx11::string::_M_construct<char_const*>(local_40,"event=TestStart&name=","");
/* try { // try from 00137bb8 to 00137bbf has its CatchHandler @ 00137c69 */
plVar1 = (long *)std::__cxx11::string::append((char *)local_40);
plVar2 = plVar1 + 2;
if ((long *)*plVar1 == plVar2) {
local_50 = *plVar2;
lStack_48 = plVar1[3];
local_60 = &local_50;
}
else {
local_50 = *plVar2;
local_60 = (long *)*plVar1;
}
local_58 = plVar1[1];
*plVar1 = (long)plVar2;
plVar1[1] = 0;
*(int1 *)(plVar1 + 2) = 0;
/* try { // try from 00137c0e to 00137c12 has its CatchHandler @ 00137c4d */
AbstractSocketWriter::SendLn(*(AbstractSocketWriter **)(param_1 + 8),(string *)&local_60);
if (local_60 != &local_50) {
operator_delete(local_60,local_50 + 1);
}
if (local_40[0] != local_30) {
operator_delete(local_40[0],local_30[0] + 1);
}
return;
}
| |
38,070 | ftxui::HorizontalContainer::EventHandler(ftxui::Event) | Andrewchistyakov[P]flashcards_lyc/build_O2/_deps/ftxui-src/src/ftxui/component/container.cpp | bool EventHandler(Event event) override {
const int old_selected = *selector_;
if (event == Event::ArrowLeft || event == Event::Character('h')) {
MoveSelector(-1);
}
if (event == Event::ArrowRight || event == Event::Character('l')) {
MoveSelector(+1);
}
if (event == Event::Tab) {
MoveSelectorWrap(+1);
}
if (event == Event::TabReverse) {
MoveSelectorWrap(-1);
}
*selector_ = std::max(0, std::min(int(children_.size()) - 1, *selector_));
return old_selected != *selector_;
} | O2 | cpp | ftxui::HorizontalContainer::EventHandler(ftxui::Event):
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rsi, %r14
movq %rdi, %rbx
movq 0x30(%rdi), %rax
movl (%rax), %r12d
addq $0x20, %r14
leaq 0x2fa32(%rip), %rsi # 0x52ad8
addq $0x20, %rsi
movq %r14, %rdi
callq 0x13f98
testb %al, %al
jne 0x230e0
movq %rsp, %rdi
pushq $0x68
popq %rsi
callq 0x23b7a
leaq 0x20(%rsp), %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x13f98
movl %eax, %ebp
movq %r15, %rdi
callq 0xc8c8
testb %bpl, %bpl
je 0x230eb
pushq $-0x1
popq %rsi
movq %rbx, %rdi
callq 0x22c80
leaq 0x2fa26(%rip), %rsi # 0x52b18
addq $0x20, %rsi
movq %r14, %rdi
callq 0x13f98
testb %al, %al
jne 0x2312c
movq %rsp, %rdi
pushq $0x6c
popq %rsi
callq 0x23b7a
leaq 0x20(%rsp), %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x13f98
movl %eax, %ebp
movq %r15, %rdi
callq 0xc8c8
testb %bpl, %bpl
je 0x23137
pushq $0x1
popq %rsi
movq %rbx, %rdi
callq 0x22c80
leaq 0x2fc9a(%rip), %rsi # 0x52dd8
addq $0x20, %rsi
movq %r14, %rdi
callq 0x13f98
testb %al, %al
je 0x23159
pushq $0x1
popq %rsi
movq %rbx, %rdi
callq 0x22cca
leaq 0x2fcb8(%rip), %rsi # 0x52e18
addq $0x20, %rsi
movq %r14, %rdi
callq 0x13f98
testb %al, %al
je 0x2317b
pushq $-0x1
popq %rsi
movq %rbx, %rdi
callq 0x22cca
movq 0x10(%rbx), %rax
movq 0x30(%rbx), %rcx
subq 0x8(%rbx), %rax
shrq $0x4, %rax
decl %eax
movl (%rcx), %edx
cmpl %eax, %edx
cmovll %edx, %eax
xorl %edx, %edx
testl %eax, %eax
cmovgl %eax, %edx
movl %edx, (%rcx)
cmpl %edx, %r12d
setne %al
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
| _ZN5ftxui19HorizontalContainer12EventHandlerENS_5EventE:
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 40h
mov r14, rsi
mov rbx, rdi
mov rax, [rdi+30h]
mov r12d, [rax]
add r14, 20h ; ' '
lea rsi, _ZN5ftxui5Event9ArrowLeftE; ftxui::Event::ArrowLeft
add rsi, 20h ; ' '
mov rdi, r14
call _ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_
test al, al
jnz short loc_230E0
mov rdi, rsp; this
push 68h ; 'h'
pop rsi; char
call _ZN5ftxui5Event9CharacterEc; ftxui::Event::Character(char)
lea r15, [rsp+68h+var_48]
mov rdi, r14
mov rsi, r15
call _ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_
mov ebp, eax
mov rdi, r15; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
test bpl, bpl
jz short loc_230EB
loc_230E0:
push 0FFFFFFFFFFFFFFFFh
pop rsi; int
mov rdi, rbx; this
call _ZN5ftxui13ContainerBase12MoveSelectorEi; ftxui::ContainerBase::MoveSelector(int)
loc_230EB:
lea rsi, _ZN5ftxui5Event10ArrowRightE; ftxui::Event::ArrowRight
add rsi, 20h ; ' '
mov rdi, r14
call _ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_
test al, al
jnz short loc_2312C
mov rdi, rsp; this
push 6Ch ; 'l'
pop rsi; char
call _ZN5ftxui5Event9CharacterEc; ftxui::Event::Character(char)
lea r15, [rsp+68h+var_48]
mov rdi, r14
mov rsi, r15
call _ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_
mov ebp, eax
mov rdi, r15; void *
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string()
test bpl, bpl
jz short loc_23137
loc_2312C:
push 1
pop rsi; int
mov rdi, rbx; this
call _ZN5ftxui13ContainerBase12MoveSelectorEi; ftxui::ContainerBase::MoveSelector(int)
loc_23137:
lea rsi, _ZN5ftxui5Event3TabE; ftxui::Event::Tab
add rsi, 20h ; ' '
mov rdi, r14
call _ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_
test al, al
jz short loc_23159
push 1
pop rsi; int
mov rdi, rbx; this
call _ZN5ftxui13ContainerBase16MoveSelectorWrapEi; ftxui::ContainerBase::MoveSelectorWrap(int)
loc_23159:
lea rsi, _ZN5ftxui5Event10TabReverseE; ftxui::Event::TabReverse
add rsi, 20h ; ' '
mov rdi, r14
call _ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_
test al, al
jz short loc_2317B
push 0FFFFFFFFFFFFFFFFh
pop rsi; int
mov rdi, rbx; this
call _ZN5ftxui13ContainerBase16MoveSelectorWrapEi; ftxui::ContainerBase::MoveSelectorWrap(int)
loc_2317B:
mov rax, [rbx+10h]
mov rcx, [rbx+30h]
sub rax, [rbx+8]
shr rax, 4
dec eax
mov edx, [rcx]
cmp edx, eax
cmovl eax, edx
xor edx, edx
test eax, eax
cmovg edx, eax
mov [rcx], edx
cmp r12d, edx
setnz al
add rsp, 40h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
| bool ftxui::HorizontalContainer::EventHandler(long long a1, long long a2)
{
int v2; // r12d
_QWORD *v3; // r14
bool v4; // bp
bool v5; // bp
int *v6; // rcx
int v7; // eax
int v8; // edx
_BYTE v10[32]; // [rsp+0h] [rbp-68h] BYREF
_QWORD v11[9]; // [rsp+20h] [rbp-48h] BYREF
v2 = **(_DWORD **)(a1 + 48);
v3 = (_QWORD *)(a2 + 32);
if ( std::operator==<char>((_QWORD *)(a2 + 32), &ftxui::Event::ArrowLeft[4])
|| (ftxui::Event::Character((ftxui::Event *)v10, 104),
v4 = std::operator==<char>(v3, v11),
std::string::~string(v11),
v4) )
{
ftxui::ContainerBase::MoveSelector((ftxui::ContainerBase *)a1, -1);
}
if ( std::operator==<char>(v3, &ftxui::Event::ArrowRight[4])
|| (ftxui::Event::Character((ftxui::Event *)v10, 108),
v5 = std::operator==<char>(v3, v11),
std::string::~string(v11),
v5) )
{
ftxui::ContainerBase::MoveSelector((ftxui::ContainerBase *)a1, 1);
}
if ( std::operator==<char>(v3, &ftxui::Event::Tab[4]) )
ftxui::ContainerBase::MoveSelectorWrap((ftxui::ContainerBase *)a1, 1);
if ( std::operator==<char>(v3, &ftxui::Event::TabReverse[4]) )
ftxui::ContainerBase::MoveSelectorWrap((ftxui::ContainerBase *)a1, -1);
v6 = *(int **)(a1 + 48);
v7 = ((*(_QWORD *)(a1 + 16) - *(_QWORD *)(a1 + 8)) >> 4) - 1;
if ( *v6 < v7 )
v7 = *v6;
v8 = 0;
if ( v7 > 0 )
v8 = v7;
*v6 = v8;
return v2 != v8;
}
| EventHandler:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x40
MOV R14,RSI
MOV RBX,RDI
MOV RAX,qword ptr [RDI + 0x30]
MOV R12D,dword ptr [RAX]
ADD R14,0x20
LEA RSI,[0x152ad8]
ADD RSI,0x20
MOV RDI,R14
CALL 0x00113f98
TEST AL,AL
JNZ 0x001230e0
MOV RDI,RSP
PUSH 0x68
POP RSI
CALL 0x00123b7a
LEA R15,[RSP + 0x20]
MOV RDI,R14
MOV RSI,R15
CALL 0x00113f98
MOV EBP,EAX
MOV RDI,R15
CALL 0x0010c8c8
TEST BPL,BPL
JZ 0x001230eb
LAB_001230e0:
PUSH -0x1
POP RSI
MOV RDI,RBX
CALL 0x00122c80
LAB_001230eb:
LEA RSI,[0x152b18]
ADD RSI,0x20
MOV RDI,R14
CALL 0x00113f98
TEST AL,AL
JNZ 0x0012312c
MOV RDI,RSP
PUSH 0x6c
POP RSI
CALL 0x00123b7a
LEA R15,[RSP + 0x20]
MOV RDI,R14
MOV RSI,R15
CALL 0x00113f98
MOV EBP,EAX
MOV RDI,R15
CALL 0x0010c8c8
TEST BPL,BPL
JZ 0x00123137
LAB_0012312c:
PUSH 0x1
POP RSI
MOV RDI,RBX
CALL 0x00122c80
LAB_00123137:
LEA RSI,[0x152dd8]
ADD RSI,0x20
MOV RDI,R14
CALL 0x00113f98
TEST AL,AL
JZ 0x00123159
PUSH 0x1
POP RSI
MOV RDI,RBX
CALL 0x00122cca
LAB_00123159:
LEA RSI,[0x152e18]
ADD RSI,0x20
MOV RDI,R14
CALL 0x00113f98
TEST AL,AL
JZ 0x0012317b
PUSH -0x1
POP RSI
MOV RDI,RBX
CALL 0x00122cca
LAB_0012317b:
MOV RAX,qword ptr [RBX + 0x10]
MOV RCX,qword ptr [RBX + 0x30]
SUB RAX,qword ptr [RBX + 0x8]
SHR RAX,0x4
DEC EAX
MOV EDX,dword ptr [RCX]
CMP EDX,EAX
CMOVL EAX,EDX
XOR EDX,EDX
TEST EAX,EAX
CMOVG EDX,EAX
MOV dword ptr [RCX],EDX
CMP R12D,EDX
SETNZ AL
ADD RSP,0x40
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
/* ftxui::HorizontalContainer::EventHandler(ftxui::Event) */
int4 __thiscall
ftxui::HorizontalContainer::EventHandler(HorizontalContainer *this,long param_2)
{
int iVar1;
char cVar2;
int iVar3;
int iVar4;
string *psVar5;
Event aEStack_68 [32];
string local_48 [32];
iVar1 = **(int **)(this + 0x30);
psVar5 = (string *)(param_2 + 0x20);
cVar2 = std::operator==(psVar5,(string *)(Event::ArrowLeft + 0x20));
if (cVar2 == '\0') {
Event::Character(aEStack_68,'h');
cVar2 = std::operator==(psVar5,local_48);
std::__cxx11::string::~string(local_48);
if (cVar2 != '\0') goto LAB_001230e0;
}
else {
LAB_001230e0:
ftxui::ContainerBase::MoveSelector((ContainerBase *)this,-1);
}
cVar2 = std::operator==(psVar5,(string *)(Event::ArrowRight + 0x20));
if (cVar2 == '\0') {
Event::Character(aEStack_68,'l');
cVar2 = std::operator==(psVar5,local_48);
std::__cxx11::string::~string(local_48);
if (cVar2 == '\0') goto LAB_00123137;
}
ftxui::ContainerBase::MoveSelector((ContainerBase *)this,1);
LAB_00123137:
cVar2 = std::operator==(psVar5,(string *)(Event::Tab + 0x20));
if (cVar2 != '\0') {
ftxui::ContainerBase::MoveSelectorWrap((ContainerBase *)this,1);
}
cVar2 = std::operator==(psVar5,(string *)(Event::TabReverse + 0x20));
if (cVar2 != '\0') {
ftxui::ContainerBase::MoveSelectorWrap((ContainerBase *)this,-1);
}
iVar3 = (int)((ulong)(*(long *)(this + 0x10) - *(long *)(this + 8)) >> 4) + -1;
iVar4 = **(int **)(this + 0x30);
if (iVar4 < iVar3) {
iVar3 = iVar4;
}
iVar4 = 0;
if (0 < iVar3) {
iVar4 = iVar3;
}
**(int **)(this + 0x30) = iVar4;
return CONCAT31((int3)((uint)iVar3 >> 8),iVar1 != iVar4);
}
| |
38,071 | nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::json_sax_dom_callback_parser(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&, 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) | llama.cpp/common/json.hpp | json_sax_dom_callback_parser(BasicJsonType& r,
const parser_callback_t cb,
const bool allow_exceptions_ = true)
: root(r), callback(cb), allow_exceptions(allow_exceptions_)
{
keep_stack.push_back(true);
} | O3 | cpp | nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::json_sax_dom_callback_parser(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>&, 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):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, %ebp
movq %rdi, %rbx
movq %rsi, (%rdi)
leaq 0x20(%rdi), %r14
leaq 0x80(%rdi), %r12
xorps %xmm0, %xmm0
movups %xmm0, 0x8(%rdi)
movups %xmm0, 0x18(%rdi)
movups %xmm0, 0x28(%rdi)
movups %xmm0, 0x38(%rdi)
movups %xmm0, 0x48(%rdi)
movups %xmm0, 0x58(%rdi)
movups %xmm0, 0x68(%rdi)
movb $0x0, 0x78(%rdi)
movq %r12, %rdi
movq %rdx, %rsi
callq 0x923fe
movb %bpl, 0xa0(%rbx)
leaq 0xa8(%rbx), %r13
movb $0x9, 0xa8(%rbx)
movq $0x0, 0xb0(%rbx)
movq %r13, %rdi
movl $0x1, %esi
callq 0x92a5c
movq %r14, %rdi
movl $0x1, %esi
callq 0x84f3e
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r15
movq %r13, %rdi
xorl %esi, %esi
callq 0x92a5c
movq %r13, %rdi
callq 0x97176
movq 0x90(%rbx), %rax
testq %rax, %rax
je 0x939e6
movq %r12, %rdi
movq %r12, %rsi
movl $0x3, %edx
callq *%rax
jmp 0x939e6
jmp 0x93a0d
movq %rax, %r15
leaq 0x48(%rbx), %rdi
callq 0x85146
movq %r14, %rdi
callq 0x85146
leaq 0x8(%rbx), %rdi
movq %rbx, %rsi
callq 0x22dc9
movq %r15, %rdi
callq 0x21b70
jmp 0x93a0d
movq %rax, %rdi
callq 0x33a55
nop
| _ZN8nlohmann16json_abi_v3_11_36detail28json_sax_dom_callback_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEC2ERSF_St8functionIFbiNS1_13parse_event_tESH_EEb:
push rbp
push r15
push r14
push r13
push r12
push rbx
push rax
mov ebp, ecx
mov rbx, rdi
mov [rdi], rsi
lea r14, [rdi+20h]
lea r12, [rdi+80h]
xorps xmm0, xmm0
movups xmmword ptr [rdi+8], xmm0
movups xmmword ptr [rdi+18h], xmm0
movups xmmword ptr [rdi+28h], xmm0
movups xmmword ptr [rdi+38h], xmm0
movups xmmword ptr [rdi+48h], xmm0
movups xmmword ptr [rdi+58h], xmm0
movups xmmword ptr [rdi+68h], xmm0
mov byte ptr [rdi+78h], 0
mov rdi, r12
mov rsi, rdx
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&)
mov [rbx+0A0h], bpl
lea r13, [rbx+0A8h]
mov byte ptr [rbx+0A8h], 9
mov qword ptr [rbx+0B0h], 0
mov rdi, r13
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, r14
mov esi, 1
call _ZNSt6vectorIbSaIbEE9push_backEb; std::vector<bool>::push_back(bool)
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
mov r15, rax
mov rdi, r13
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, r13
call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data()
mov rax, [rbx+90h]
test rax, rax
jz short loc_939E6
mov rdi, r12
mov rsi, r12
mov edx, 3
call rax
jmp short loc_939E6
jmp short loc_93A0D
mov r15, rax
loc_939E6:
lea rdi, [rbx+48h]
call _ZNSt13_Bvector_baseISaIbEE13_M_deallocateEv; std::_Bvector_base<std::allocator<bool>>::_M_deallocate(void)
mov rdi, r14
call _ZNSt13_Bvector_baseISaIbEE13_M_deallocateEv; std::_Bvector_base<std::allocator<bool>>::_M_deallocate(void)
lea rdi, [rbx+8]
mov rsi, rbx
call _ZN8nlohmann16json_abi_v3_11_36detail28json_sax_dom_callback_parserINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEC2ERSF_St8functionIFbiNS1_13parse_event_tESH_EEb_cold_1; nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::json_sax_dom_callback_parser(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&,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) [clone]
mov rdi, r15
call __Unwind_Resume
jmp short $+2
loc_93A0D:
mov rdi, rax
call __clang_call_terminate
| long long nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::json_sax_dom_callback_parser(
long long a1,
long long a2,
long long a3,
char a4)
{
*(_QWORD *)a1 = a2;
*(_OWORD *)(a1 + 8) = 0LL;
*(_OWORD *)(a1 + 24) = 0LL;
*(_OWORD *)(a1 + 40) = 0LL;
*(_OWORD *)(a1 + 56) = 0LL;
*(_OWORD *)(a1 + 72) = 0LL;
*(_OWORD *)(a1 + 88) = 0LL;
*(_OWORD *)(a1 + 104) = 0LL;
*(_BYTE *)(a1 + 120) = 0;
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(
(_OWORD *)(a1 + 128),
a3);
*(_BYTE *)(a1 + 160) = a4;
*(_BYTE *)(a1 + 168) = 9;
*(_QWORD *)(a1 + 176) = 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 + 168));
return std::vector<bool>::push_back(a1 + 32, 1u);
}
| json_sax_dom_callback_parser:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV EBP,ECX
MOV RBX,RDI
MOV qword ptr [RDI],RSI
LEA R14,[RDI + 0x20]
LEA R12,[RDI + 0x80]
XORPS XMM0,XMM0
MOVUPS xmmword ptr [RDI + 0x8],XMM0
MOVUPS xmmword ptr [RDI + 0x18],XMM0
MOVUPS xmmword ptr [RDI + 0x28],XMM0
MOVUPS xmmword ptr [RDI + 0x38],XMM0
MOVUPS xmmword ptr [RDI + 0x48],XMM0
MOVUPS xmmword ptr [RDI + 0x58],XMM0
MOVUPS xmmword ptr [RDI + 0x68],XMM0
MOV byte ptr [RDI + 0x78],0x0
LAB_0019395d:
MOV RDI,R12
MOV RSI,RDX
CALL 0x001923fe
MOV byte ptr [RBX + 0xa0],BPL
LEA R13,[RBX + 0xa8]
MOV byte ptr [RBX + 0xa8],0x9
MOV qword ptr [RBX + 0xb0],0x0
MOV RDI,R13
MOV ESI,0x1
CALL 0x00192a5c
LAB_00193995:
MOV RDI,R14
MOV ESI,0x1
CALL 0x00184f3e
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* nlohmann::json_abi_v3_11_3::detail::json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>
>::json_sax_dom_callback_parser(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,
std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator,
nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned
char> >, void>&, 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) */
void __thiscall
nlohmann::json_abi_v3_11_3::detail::
json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::json_sax_dom_callback_parser
(json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
*this,int8 param_1,function *param_3,
json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
param_4)
{
*(int8 *)this = param_1;
*(int8 *)(this + 8) = 0;
*(int8 *)(this + 0x10) = 0;
*(int8 *)(this + 0x18) = 0;
*(int8 *)(this + 0x20) = 0;
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x40) = 0;
*(int8 *)(this + 0x48) = 0;
*(int8 *)(this + 0x50) = 0;
*(int8 *)(this + 0x58) = 0;
*(int8 *)(this + 0x60) = 0;
*(int8 *)(this + 0x68) = 0;
*(int8 *)(this + 0x70) = 0;
this[0x78] = (json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
)0x0;
/* try { // try from 0019395d to 00193967 has its CatchHandler @ 001939e3 */
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((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>&)>
*)(this + 0x80),param_3);
this[0xa0] = param_4;
this[0xa8] = (json_sax_dom_callback_parser<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
)0x9;
*(int8 *)(this + 0xb0) = 0;
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant((bool)((char)this + -0x58));
/* try { // try from 00193995 to 001939a1 has its CatchHandler @ 001939b1 */
std::vector<bool,std::allocator<bool>>::push_back
((vector<bool,std::allocator<bool>> *)(this + 0x20),true);
return;
}
| |
38,072 | write_hook_for_undo | eloqsql/storage/maria/ma_blockrec.c | my_bool write_hook_for_undo(enum translog_record_type type
__attribute__ ((unused)),
TRN *trn, MARIA_HA *tbl_info
__attribute__ ((unused)),
LSN *lsn, void *hook_arg
__attribute__ ((unused)))
{
DBUG_ASSERT(trn->trid != 0);
trn->undo_lsn= *lsn;
if (unlikely(LSN_WITH_FLAGS_TO_LSN(trn->first_undo_lsn) == 0))
trn->first_undo_lsn=
trn->undo_lsn | LSN_WITH_FLAGS_TO_FLAGS(trn->first_undo_lsn);
return 0;
/*
when we implement purging, we will specialize this hook: UNDO_PURGE
records will additionally set trn->undo_purge_lsn
*/
} | O3 | c | write_hook_for_undo:
pushq %rbp
movq %rsp, %rbp
movq (%rcx), %rax
movq %rax, 0x98(%rsi)
movq 0xa0(%rsi), %rcx
movq %rcx, %rdx
shlq $0x8, %rdx
je 0x4e1ba
xorl %eax, %eax
popq %rbp
retq
orq %rax, %rcx
movq %rcx, 0xa0(%rsi)
jmp 0x4e1b6
| write_hook_for_undo:
push rbp
mov rbp, rsp
mov rax, [rcx]
mov [rsi+98h], rax
mov rcx, [rsi+0A0h]
mov rdx, rcx
shl rdx, 8
jz short loc_4E1BA
loc_4E1B6:
xor eax, eax
pop rbp
retn
loc_4E1BA:
or rcx, rax
mov [rsi+0A0h], rcx
jmp short loc_4E1B6
| long long write_hook_for_undo(long long a1, long long a2, long long a3, long long *a4)
{
long long v4; // rax
v4 = *a4;
*(_QWORD *)(a2 + 152) = *a4;
if ( !(*(_QWORD *)(a2 + 160) << 8) )
*(_QWORD *)(a2 + 160) |= v4;
return 0LL;
}
| write_hook_for_undo:
PUSH RBP
MOV RBP,RSP
MOV RAX,qword ptr [RCX]
MOV qword ptr [RSI + 0x98],RAX
MOV RCX,qword ptr [RSI + 0xa0]
MOV RDX,RCX
SHL RDX,0x8
JZ 0x0014e1ba
LAB_0014e1b6:
XOR EAX,EAX
POP RBP
RET
LAB_0014e1ba:
OR RCX,RAX
MOV qword ptr [RSI + 0xa0],RCX
JMP 0x0014e1b6
|
int8 write_hook_for_undo(int8 param_1,long param_2,int8 param_3,ulong *param_4)
{
ulong uVar1;
uVar1 = *param_4;
*(ulong *)(param_2 + 0x98) = uVar1;
if ((*(ulong *)(param_2 + 0xa0) & 0xffffffffffffff) == 0) {
*(ulong *)(param_2 + 0xa0) = *(ulong *)(param_2 + 0xa0) | uVar1;
}
return 0;
}
| |
38,073 | JS_ToIntegerFree | bluesky950520[P]quickjs/quickjs.c | static __maybe_unused JSValue JS_ToIntegerFree(JSContext *ctx, JSValue val)
{
uint32_t tag;
JSValue ret;
redo:
tag = JS_VALUE_GET_NORM_TAG(val);
switch(tag) {
case JS_TAG_INT:
case JS_TAG_BOOL:
case JS_TAG_NULL:
case JS_TAG_UNDEFINED:
ret = js_int32(JS_VALUE_GET_INT(val));
break;
case JS_TAG_FLOAT64:
{
double d = JS_VALUE_GET_FLOAT64(val);
if (isnan(d)) {
ret = js_int32(0);
} else {
/* convert -0 to +0 */
d = trunc(d) + 0.0;
ret = js_number(d);
}
}
break;
default:
val = JS_ToNumberFree(ctx, val);
if (JS_IsException(val))
return val;
goto redo;
}
return ret;
} | O2 | c | JS_ToIntegerFree:
pushq %rbx
movq %rsi, %rax
movq %rdi, %rbx
cmpl $0x4, %edx
jb 0x60e3f
cmpl $0x7, %edx
je 0x60e45
movq %rbx, %rdi
movq %rax, %rsi
callq 0x2e216
cmpl $0x6, %edx
jne 0x60e23
jmp 0x60e43
movl %eax, %eax
xorl %edx, %edx
popq %rbx
retq
movq %rax, %xmm0
ucomisd %xmm0, %xmm0
jp 0x60e64
callq 0xe150
xorpd %xmm1, %xmm1
addsd %xmm1, %xmm0
callq 0x16f9e
jmp 0x60e43
xorl %eax, %eax
jmp 0x60e41
| JS_ToIntegerFree:
push rbx
mov rax, rsi
mov rbx, rdi
loc_60E23:
cmp edx, 4
jb short loc_60E3F
cmp edx, 7
jz short loc_60E45
mov rdi, rbx
mov rsi, rax
call JS_ToNumberFree
cmp edx, 6
jnz short loc_60E23
jmp short loc_60E43
loc_60E3F:
mov eax, eax
loc_60E41:
xor edx, edx
loc_60E43:
pop rbx
retn
loc_60E45:
movq xmm0, rax
ucomisd xmm0, xmm0
jp short loc_60E64
call _trunc
xorpd xmm1, xmm1
addsd xmm0, xmm1
call js_number
jmp short loc_60E43
loc_60E64:
xor eax, eax
jmp short loc_60E41
| long long JS_ToIntegerFree(long long a1, long long a2, long long a3)
{
long long result; // rax
double v4; // xmm0_8
result = a2;
while ( 1 )
{
if ( (unsigned int)a3 < 4 )
return (unsigned int)result;
if ( (_DWORD)a3 == 7 )
break;
result = JS_ToNumberFree(a1, result, a3);
if ( (_DWORD)a3 == 6 )
return result;
}
v4 = trunc(*(double *)&result);
return js_number(v4 + 0.0);
}
| JS_ToIntegerFree:
PUSH RBX
MOV RAX,RSI
MOV RBX,RDI
LAB_00160e23:
CMP EDX,0x4
JC 0x00160e3f
CMP EDX,0x7
JZ 0x00160e45
MOV RDI,RBX
MOV RSI,RAX
CALL 0x0012e216
CMP EDX,0x6
JNZ 0x00160e23
JMP 0x00160e43
LAB_00160e3f:
MOV EAX,EAX
LAB_00160e41:
XOR EDX,EDX
LAB_00160e43:
POP RBX
RET
LAB_00160e45:
MOVQ XMM0,RAX
UCOMISD XMM0,XMM0
JP 0x00160e64
CALL 0x0010e150
XORPD XMM1,XMM1
ADDSD XMM0,XMM1
CALL 0x00116f9e
JMP 0x00160e43
LAB_00160e64:
XOR EAX,EAX
JMP 0x00160e41
|
ulong JS_ToIntegerFree(int8 param_1,int8 param_2,int8 param_3)
{
ulong uVar1;
double dVar2;
int1 auVar3 [16];
auVar3._8_8_ = param_3;
auVar3._0_8_ = param_2;
while( true ) {
dVar2 = auVar3._0_8_;
if (auVar3._8_4_ < 4) {
return (ulong)dVar2 & 0xffffffff;
}
if (auVar3._8_4_ == 7) break;
auVar3 = JS_ToNumberFree(param_1,dVar2);
if (auVar3._8_4_ == 6) {
return auVar3._0_8_;
}
}
if (!NAN(dVar2)) {
dVar2 = trunc(dVar2);
uVar1 = js_number(dVar2 + 0.0);
return uVar1;
}
return 0;
}
| |
38,074 | my_charpos_utf16 | eloqsql/strings/ctype-ucs2.c | static size_t
my_charpos_utf16(CHARSET_INFO *cs,
const char *b, const char *e, size_t pos)
{
const char *b0= b;
uint charlen;
for ( ; pos; b+= charlen, pos--)
{
if (!(charlen= my_ismbchar(cs, b, e)))
return (e + 2 - b0); /* Error, return pos outside the string */
}
return (size_t) (pos ? (e + 2 - b0) : (b - b0));
} | O0 | c | my_charpos_utf16:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x30(%rbp)
cmpq $0x0, -0x28(%rbp)
je 0x8fbc5
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rsi
movq -0x20(%rbp), %rdx
callq 0x93260
movl %eax, -0x34(%rbp)
cmpl $0x0, %eax
jne 0x8fba5
movq -0x20(%rbp), %rax
addq $0x2, %rax
movq -0x30(%rbp), %rcx
subq %rcx, %rax
movq %rax, -0x8(%rbp)
jmp 0x8fbf8
jmp 0x8fba7
movl -0x34(%rbp), %ecx
movq -0x18(%rbp), %rax
movl %ecx, %ecx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
movq -0x28(%rbp), %rax
addq $-0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x8fb70
cmpq $0x0, -0x28(%rbp)
je 0x8fbe1
movq -0x20(%rbp), %rax
addq $0x2, %rax
movq -0x30(%rbp), %rcx
subq %rcx, %rax
movq %rax, -0x40(%rbp)
jmp 0x8fbf0
movq -0x18(%rbp), %rax
movq -0x30(%rbp), %rcx
subq %rcx, %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| my_charpos_utf16:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov rax, [rbp+var_18]
mov [rbp+var_30], rax
loc_8FB70:
cmp [rbp+var_28], 0
jz short loc_8FBC5
mov rdi, [rbp+var_10]
mov rsi, [rbp+var_18]
mov rdx, [rbp+var_20]
call my_ismbchar_1
mov [rbp+var_34], eax
cmp eax, 0
jnz short loc_8FBA5
mov rax, [rbp+var_20]
add rax, 2
mov rcx, [rbp+var_30]
sub rax, rcx
mov [rbp+var_8], rax
jmp short loc_8FBF8
loc_8FBA5:
jmp short $+2
loc_8FBA7:
mov ecx, [rbp+var_34]
mov rax, [rbp+var_18]
mov ecx, ecx
add rax, rcx
mov [rbp+var_18], rax
mov rax, [rbp+var_28]
add rax, 0FFFFFFFFFFFFFFFFh
mov [rbp+var_28], rax
jmp short loc_8FB70
loc_8FBC5:
cmp [rbp+var_28], 0
jz short loc_8FBE1
mov rax, [rbp+var_20]
add rax, 2
mov rcx, [rbp+var_30]
sub rax, rcx
mov [rbp+var_40], rax
jmp short loc_8FBF0
loc_8FBE1:
mov rax, [rbp+var_18]
mov rcx, [rbp+var_30]
sub rax, rcx
mov [rbp+var_40], rax
loc_8FBF0:
mov rax, [rbp+var_40]
mov [rbp+var_8], rax
loc_8FBF8:
mov rax, [rbp+var_8]
add rsp, 40h
pop rbp
retn
| long long my_charpos_utf16(long long a1, long long a2, long long a3, long long a4)
{
unsigned int v5; // [rsp+Ch] [rbp-34h]
long long v8; // [rsp+28h] [rbp-18h]
v8 = a2;
while ( a4 )
{
v5 = my_ismbchar_1(a1, v8, a3);
if ( !v5 )
return a3 + 2 - a2;
v8 += v5;
--a4;
}
return v8 - a2;
}
| my_charpos_utf16:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x18]
MOV qword ptr [RBP + -0x30],RAX
LAB_0018fb70:
CMP qword ptr [RBP + -0x28],0x0
JZ 0x0018fbc5
MOV RDI,qword ptr [RBP + -0x10]
MOV RSI,qword ptr [RBP + -0x18]
MOV RDX,qword ptr [RBP + -0x20]
CALL 0x00193260
MOV dword ptr [RBP + -0x34],EAX
CMP EAX,0x0
JNZ 0x0018fba5
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x2
MOV RCX,qword ptr [RBP + -0x30]
SUB RAX,RCX
MOV qword ptr [RBP + -0x8],RAX
JMP 0x0018fbf8
LAB_0018fba5:
JMP 0x0018fba7
LAB_0018fba7:
MOV ECX,dword ptr [RBP + -0x34]
MOV RAX,qword ptr [RBP + -0x18]
MOV ECX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RBP + -0x28]
ADD RAX,-0x1
MOV qword ptr [RBP + -0x28],RAX
JMP 0x0018fb70
LAB_0018fbc5:
CMP qword ptr [RBP + -0x28],0x0
JZ 0x0018fbe1
MOV RAX,qword ptr [RBP + -0x20]
ADD RAX,0x2
MOV RCX,qword ptr [RBP + -0x30]
SUB RAX,RCX
MOV qword ptr [RBP + -0x40],RAX
JMP 0x0018fbf0
LAB_0018fbe1:
MOV RAX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x30]
SUB RAX,RCX
MOV qword ptr [RBP + -0x40],RAX
LAB_0018fbf0:
MOV RAX,qword ptr [RBP + -0x40]
MOV qword ptr [RBP + -0x8],RAX
LAB_0018fbf8:
MOV RAX,qword ptr [RBP + -0x8]
ADD RSP,0x40
POP RBP
RET
|
/* WARNING: Removing unreachable block (ram,0x0018fbcc) */
long my_charpos_utf16(int8 param_1,long param_2,long param_3,long param_4)
{
uint uVar1;
long local_30;
long local_20;
local_30 = param_4;
local_20 = param_2;
while( true ) {
if (local_30 == 0) {
return local_20 - param_2;
}
uVar1 = my_ismbchar(param_1,local_20,param_3);
if (uVar1 == 0) break;
local_20 = local_20 + (ulong)uVar1;
local_30 = local_30 + -1;
}
return (param_3 + 2) - param_2;
}
| |
38,075 | unsigned long 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>>>>::erase<char const (&) [5], 0>(char const (&) [5]) | monkey531[P]llama/common/json.hpp | size_type erase(KeyType && key) // NOLINT(cppcoreguidelines-missing-std-forward)
{
for (auto it = this->begin(); it != this->end(); ++it)
{
if (m_compare(it->first, key))
{
// Since we cannot move const Keys, re-construct them in place
for (auto next = it; ++next != this->end(); ++it)
{
it->~value_type(); // Destroy but keep allocation
new (&*it) value_type{std::move(*next)};
}
Container::pop_back();
return 1;
}
}
return 0;
} | O2 | cpp | unsigned long 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>>>>::erase<char const (&) [5], 0>(char const (&) [5]):
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movq %rsi, %r15
movq %rdi, %r14
movq (%rdi), %rbx
movq 0x8(%r14), %r13
cmpq %r13, %rbx
je 0x7f51f
movq %rbx, %rdi
movq %r15, %rsi
callq 0x275fc
testb %al, %al
jne 0x7f4f2
addq $0x30, %rbx
jmp 0x7f4d4
movq %rbx, %r15
leaq 0x30(%r15), %r12
cmpq 0x8(%r14), %r12
je 0x7f517
movq %r15, %rdi
callq 0x42f88
movq %r15, %rdi
movq %r12, %rsi
callq 0x43bec
movq %r12, %r15
jmp 0x7f4f5
movq %r14, %rdi
callq 0x7f1a8
xorl %eax, %eax
cmpq %r13, %rbx
setne %al
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
nop
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE5eraseIRA5_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEmOSS_:
push r15
push r14
push r13
push r12
push rbx
mov r15, rsi
mov r14, rdi
mov rbx, [rdi]
loc_7F4D4:
mov r13, [r14+8]
cmp rbx, r13
jz short loc_7F51F
mov rdi, rbx
mov rsi, r15
call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_; std::operator==<char>(std::string const&,char const*)
test al, al
jnz short loc_7F4F2
add rbx, 30h ; '0'
jmp short loc_7F4D4
loc_7F4F2:
mov r15, rbx
loc_7F4F5:
lea r12, [r15+30h]
cmp r12, [r14+8]
jz short loc_7F517
mov rdi, r15; void *
call _ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEED2Ev; std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::~pair()
mov rdi, r15
mov rsi, r12
call _ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEEC2EOSG_; std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::pair(std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>&&)
mov r15, r12
jmp short loc_7F4F5
loc_7F517:
mov rdi, r14
call _ZNSt6vectorISt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS9_11ordered_mapES_S6_blmdSaNS9_14adl_serializerES_IhSaIhEEvEEESaISG_EE8pop_backEv; 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>>>::pop_back(void)
loc_7F51F:
xor eax, eax
cmp rbx, r13
setnz al
pop rbx
pop r12
pop r13
pop r14
pop r15
retn
| _BOOL8 ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE5eraseIRA5_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEmOSS_(
long long *a1)
{
long long i; // rbx
long long v2; // r13
char *j; // r15
for ( i = *a1; ; i += 48LL )
{
v2 = a1[1];
if ( i == v2 )
break;
if ( std::operator==<char>(i) )
{
for ( j = (char *)i; j + 48 != (char *)a1[1]; j += 48 )
{
std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::~pair(j);
std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::pair(
(long long)j,
(long long)(j + 48));
}
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>>>::pop_back((long long)a1);
return i != v2;
}
}
return i != v2;
}
| _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE5eraseIRA5_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEmOSS_:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
MOV R15,RSI
MOV R14,RDI
MOV RBX,qword ptr [RDI]
LAB_0017f4d4:
MOV R13,qword ptr [R14 + 0x8]
CMP RBX,R13
JZ 0x0017f51f
MOV RDI,RBX
MOV RSI,R15
CALL 0x001275fc
TEST AL,AL
JNZ 0x0017f4f2
ADD RBX,0x30
JMP 0x0017f4d4
LAB_0017f4f2:
MOV R15,RBX
LAB_0017f4f5:
LEA R12,[R15 + 0x30]
CMP R12,qword ptr [R14 + 0x8]
JZ 0x0017f517
MOV RDI,R15
CALL 0x00142f88
MOV RDI,R15
MOV RSI,R12
CALL 0x00143bec
MOV R15,R12
JMP 0x0017f4f5
LAB_0017f517:
MOV RDI,R14
CALL 0x0017f1a8
LAB_0017f51f:
XOR EAX,EAX
CMP RBX,R13
SETNZ AL
POP RBX
POP R12
POP R13
POP R14
POP R15
RET
|
bool _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE5eraseIRA5_KcTnNSt9enable_ifIXsr6detail21is_usable_as_key_typeISt8equal_toIvES7_T_EE5valueEiE4typeELi0EEEmOSS_
(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>>>>
*param_1,char *param_2)
{
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>>
*ppVar1;
string *psVar2;
bool bVar3;
string *psVar4;
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;
for (psVar4 = *(string **)param_1; psVar2 = *(string **)(param_1 + 8), psVar4 != psVar2;
psVar4 = psVar4 + 0x30) {
bVar3 = std::operator==(psVar4,param_2);
this = (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>>
*)psVar4;
if (bVar3) goto LAB_0017f4f5;
}
LAB_0017f51f:
return psVar4 != psVar2;
LAB_0017f4f5:
while (ppVar1 = this + 0x30,
ppVar1 != *(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>>
**)(param_1 + 8)) {
std::
pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::~pair(this);
std::
pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>
::pair(this,ppVar1);
this = ppVar1;
}
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>>>>
::pop_back(param_1);
goto LAB_0017f51f;
}
| |
38,076 | my_wc_mb_utf8mb4_no_range | eloqsql/strings/ctype-utf8.c | static int
my_wc_mb_utf8mb4_no_range(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t wc, uchar *r)
{
int count;
if (wc < 0x80)
count= 1;
else if (wc < 0x800)
count= 2;
else if (wc < 0x10000)
count= 3;
else if (wc < 0x200000)
count= 4;
else
return MY_CS_ILUNI;
switch (count)
{
case 4: r[3]= (uchar) (0x80 | (wc & 0x3f)); wc= wc >> 6; wc |= 0x10000;
/* fall through */
case 3: r[2]= (uchar) (0x80 | (wc & 0x3f)); wc= wc >> 6; wc |= 0x800;
/* fall through */
case 2: r[1]= (uchar) (0x80 | (wc & 0x3f)); wc= wc >> 6; wc |= 0xc0;
/* fall through */
case 1: r[0]= (uchar) wc;
}
return count;
} | O3 | c | my_wc_mb_utf8mb4_no_range:
pushq %rbp
movq %rsp, %rbp
movl $0x1, %eax
cmpq $0x80, %rdi
jb 0x53199
movl $0x2, %eax
cmpq $0x800, %rdi # imm = 0x800
jb 0x53183
movl $0x3, %eax
cmpq $0x10000, %rdi # imm = 0x10000
jb 0x5316d
xorl %eax, %eax
cmpq $0x1fffff, %rdi # imm = 0x1FFFFF
ja 0x5319c
movl %edi, %eax
andb $0x3f, %al
orb $-0x80, %al
movb %al, 0x3(%rsi)
shrq $0x6, %rdi
orq $0x10000, %rdi # imm = 0x10000
movl $0x4, %eax
movl %edi, %ecx
andb $0x3f, %cl
orb $-0x80, %cl
movb %cl, 0x2(%rsi)
shrq $0x6, %rdi
orq $0x800, %rdi # imm = 0x800
movl %edi, %ecx
andb $0x3f, %cl
orb $-0x80, %cl
movb %cl, 0x1(%rsi)
shrq $0x6, %rdi
orq $0xc0, %rdi
movb %dil, (%rsi)
popq %rbp
retq
| my_wc_mb_utf8mb4_no_range:
push rbp
mov rbp, rsp
mov eax, 1
cmp rdi, 80h
jb short loc_53199
mov eax, 2
cmp rdi, 800h
jb short loc_53183
mov eax, 3
cmp rdi, offset stru_10000
jb short loc_5316D
xor eax, eax
cmp rdi, offset unk_1FFFFF
ja short loc_5319C
mov eax, edi
and al, 3Fh
or al, 80h
mov [rsi+3], al
shr rdi, 6
or rdi, 10000h
mov eax, 4
loc_5316D:
mov ecx, edi
and cl, 3Fh
or cl, 80h
mov [rsi+2], cl
shr rdi, 6
or rdi, 800h
loc_53183:
mov ecx, edi
and cl, 3Fh
or cl, 80h
mov [rsi+1], cl
shr rdi, 6
or rdi, 0C0h
loc_53199:
mov [rsi], dil
loc_5319C:
pop rbp
retn
| long long my_wc_mb_utf8mb4_no_range(unsigned long long a1, _BYTE *a2)
{
long long result; // rax
result = 1LL;
if ( a1 >= 0x80 )
{
result = 2LL;
if ( a1 >= 0x800 )
{
result = 3LL;
if ( a1 >= (unsigned long long)&stru_10000 )
{
result = 0LL;
if ( a1 > (unsigned long long)&unk_1FFFFF )
return result;
a2[3] = a1 & 0x3F | 0x80;
a1 = (a1 >> 6) | 0x10000;
result = 4LL;
}
a2[2] = a1 & 0x3F | 0x80;
a1 = (a1 >> 6) | 0x800;
}
a2[1] = a1 & 0x3F | 0x80;
a1 = (a1 >> 6) | 0xC0;
}
*a2 = a1;
return result;
}
| my_wc_mb_utf8mb4_no_range:
PUSH RBP
MOV RBP,RSP
MOV EAX,0x1
CMP RDI,0x80
JC 0x00153199
MOV EAX,0x2
CMP RDI,0x800
JC 0x00153183
MOV EAX,0x3
CMP RDI,0x10000
JC 0x0015316d
XOR EAX,EAX
CMP RDI,0x1fffff
JA 0x0015319c
MOV EAX,EDI
AND AL,0x3f
OR AL,0x80
MOV byte ptr [RSI + 0x3],AL
SHR RDI,0x6
OR RDI,0x10000
MOV EAX,0x4
LAB_0015316d:
MOV ECX,EDI
AND CL,0x3f
OR CL,0x80
MOV byte ptr [RSI + 0x2],CL
SHR RDI,0x6
OR RDI,0x800
LAB_00153183:
MOV ECX,EDI
AND CL,0x3f
OR CL,0x80
MOV byte ptr [RSI + 0x1],CL
SHR RDI,0x6
OR RDI,0xc0
LAB_00153199:
MOV byte ptr [RSI],DIL
LAB_0015319c:
POP RBP
RET
|
int8 my_wc_mb_utf8mb4_no_range(ulong param_1,int1 *param_2)
{
int8 uVar1;
uVar1 = 1;
if (0x7f < param_1) {
uVar1 = 2;
if (0x7ff < param_1) {
uVar1 = 3;
if (0xffff < param_1) {
if (0x1fffff < param_1) {
return 0;
}
param_2[3] = (byte)param_1 & 0x3f | 0x80;
param_1 = param_1 >> 6 | 0x10000;
uVar1 = 4;
}
param_2[2] = (byte)param_1 & 0x3f | 0x80;
param_1 = param_1 >> 6 | 0x800;
}
param_2[1] = (byte)param_1 & 0x3f | 0x80;
param_1 = param_1 >> 6 | 0xc0;
}
*param_2 = (char)param_1;
return uVar1;
}
| |
38,077 | mcp::tool_builder::with_number_param(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&, bool) | hkr04[P]cpp-mcp/src/mcp_tool.cpp | tool_builder& tool_builder::with_number_param(const std::string& name,
const std::string& description,
bool required) {
return add_param(name, description, "number", required);
} | O3 | cpp | mcp::tool_builder::with_number_param(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&, bool):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movl %ecx, %ebp
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
leaq 0x18(%rsp), %r13
movq %r13, -0x10(%r13)
leaq 0x19d7(%rip), %rsi # 0x56332
leaq 0x19d6(%rip), %rdx # 0x56338
leaq 0x8(%rsp), %r12
movq %r12, %rdi
callq 0xf902
movq %rbx, %rdi
movq %r15, %rsi
movq %r14, %rdx
movq %r12, %rcx
movl %ebp, %r8d
callq 0x54590
movq 0x8(%rsp), %rdi
cmpq %r13, %rdi
je 0x5499a
movq 0x18(%rsp), %rsi
incq %rsi
callq 0xa630
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq 0x8(%rsp), %rdi
cmpq %r13, %rdi
je 0x549c6
movq 0x18(%rsp), %rsi
incq %rsi
callq 0xa630
movq %rbx, %rdi
callq 0xaa50
| _ZN3mcp12tool_builder17with_number_paramERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES8_b:
push rbp; int
push r15; int
push r14; int
push r13; char
push r12; int
push rbx; __int64
sub rsp, 28h
mov ebp, ecx
mov r14, rdx
mov r15, rsi
mov rbx, rdi
lea r13, [rsp+58h+var_40]
mov [r13-10h], r13
lea rsi, aNumber; "number"
lea rdx, aNumber+6; ""
lea r12, [rsp+58h+var_50]
mov rdi, r12
call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag)
mov rdi, rbx; int
mov rsi, r15; int
mov rdx, r14; int
mov rcx, r12; int
mov r8d, ebp; int
call _ZN3mcp12tool_builder9add_paramERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES8_S8_b; mcp::tool_builder::add_param(std::string const&,std::string const&,std::string const&,bool)
mov rdi, [rsp+58h+var_50]; void *
cmp rdi, r13
jz short loc_5499A
mov rsi, [rsp+58h+var_40]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_5499A:
mov rax, rbx
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 *
cmp rdi, r13
jz short loc_549C6
mov rsi, [rsp+arg_10]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_549C6:
mov rdi, rbx
call __Unwind_Resume
| long long mcp::tool_builder::with_number_param(long long a1, long long a2, long long a3, char a4)
{
void *v7[2]; // [rsp+8h] [rbp-50h] BYREF
_QWORD v8[8]; // [rsp+18h] [rbp-40h] BYREF
v7[0] = v8;
std::string::_M_construct<char const*>((long long)v7, "number", (long long)"");
mcp::tool_builder::add_param(a1, a2, a3, (long long)v7, a4);
if ( v7[0] != v8 )
operator delete(v7[0], v8[0] + 1LL);
return a1;
}
| with_number_param:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x28
MOV EBP,ECX
MOV R14,RDX
MOV R15,RSI
MOV RBX,RDI
LEA R13,[RSP + 0x18]
MOV qword ptr [R13 + -0x10],R13
LEA RSI,[0x156332]
LEA RDX,[0x156338]
LEA R12,[RSP + 0x8]
MOV RDI,R12
CALL 0x0010f902
LAB_0015496f:
MOV RDI,RBX
MOV RSI,R15
MOV RDX,R14
MOV RCX,R12
MOV R8D,EBP
CALL 0x00154590
LAB_00154983:
MOV RDI,qword ptr [RSP + 0x8]
CMP RDI,R13
JZ 0x0015499a
MOV RSI,qword ptr [RSP + 0x18]
INC RSI
CALL 0x0010a630
LAB_0015499a:
MOV RAX,RBX
ADD RSP,0x28
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
/* mcp::tool_builder::with_number_param(std::__cxx11::string const&, std::__cxx11::string const&,
bool) */
tool_builder * __thiscall
mcp::tool_builder::with_number_param
(tool_builder *this,string *param_1,string *param_2,bool param_3)
{
long *local_50 [2];
long local_40 [2];
local_50[0] = local_40;
std::__cxx11::string::_M_construct<char_const*>((string *)local_50,"number","");
/* try { // try from 0015496f to 00154982 has its CatchHandler @ 001549ac */
add_param(this,param_1,param_2,(string *)local_50,param_3);
if (local_50[0] != local_40) {
operator_delete(local_50[0],local_40[0] + 1);
}
return this;
}
| |
38,078 | google::protobuf::compiler::java::RepeatedImmutablePrimitiveFieldLiteGenerator::GenerateFieldInfo(google::protobuf::io::Printer*, std::vector<unsigned short, std::allocator<unsigned short>>*) const | aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/compiler/java/primitive_field_lite.cc | void RepeatedImmutablePrimitiveFieldLiteGenerator::GenerateFieldInfo(
io::Printer* printer, std::vector<uint16_t>* output) const {
WriteIntToUtf16CharSequence(descriptor_->number(), output);
WriteIntToUtf16CharSequence(GetExperimentalJavaFieldType(descriptor_),
output);
printer->Print(variables_, "\"$name$_\",\n");
} | O3 | cpp | google::protobuf::compiler::java::RepeatedImmutablePrimitiveFieldLiteGenerator::GenerateFieldInfo(google::protobuf::io::Printer*, std::vector<unsigned short, std::allocator<unsigned short>>*) const:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movq 0x8(%rdi), %rax
movl 0x4(%rax), %edi
movq %rdx, %rsi
callq 0x45d05
movq 0x8(%r15), %rdi
callq 0x45ef8
movl %eax, %edi
movq %rbx, %rsi
callq 0x45d05
addq $0x10, %r15
leaq 0xf7bff(%rip), %rdx # 0x1ddb30
movq %r14, %rdi
movq %r15, %rsi
popq %rbx
popq %r14
popq %r15
jmp 0x16cd32
nop
| _ZNK6google8protobuf8compiler4java44RepeatedImmutablePrimitiveFieldLiteGenerator17GenerateFieldInfoEPNS0_2io7PrinterEPSt6vectorItSaItEE:
push r15
push r14
push rbx
mov rbx, rdx
mov r14, rsi
mov r15, rdi
mov rax, [rdi+8]
mov edi, [rax+4]
mov rsi, rdx; google::protobuf::FieldDescriptor *
call _ZN6google8protobuf8compiler4java30WriteUInt32ToUtf16CharSequenceEjPSt6vectorItSaItEE; google::protobuf::compiler::java::WriteUInt32ToUtf16CharSequence(uint,std::vector<ushort> *)
mov rdi, [r15+8]; this
call _ZN6google8protobuf8compiler4java28GetExperimentalJavaFieldTypeEPKNS0_15FieldDescriptorE; google::protobuf::compiler::java::GetExperimentalJavaFieldType(google::protobuf::FieldDescriptor const*)
mov edi, eax
mov rsi, rbx
call _ZN6google8protobuf8compiler4java30WriteUInt32ToUtf16CharSequenceEjPSt6vectorItSaItEE; google::protobuf::compiler::java::WriteUInt32ToUtf16CharSequence(uint,std::vector<ushort> *)
add r15, 10h
lea rdx, aName_0; "\"$name$_\",\n"
mov rdi, r14; this
mov rsi, r15
pop rbx
pop r14
pop r15
jmp _ZN6google8protobuf2io7Printer5PrintERKSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_St4lessIS9_ESaISt4pairIKS9_S9_EEEPKc; google::protobuf::io::Printer::Print(std::map<std::string,std::string> const&,char const*)
| long long google::protobuf::compiler::java::RepeatedImmutablePrimitiveFieldLiteGenerator::GenerateFieldInfo(
long long a1,
google::protobuf::io::Printer *a2,
const google::protobuf::FieldDescriptor *a3,
long long a4,
long long a5,
long long a6,
void *a7,
int a8,
char a9,
int a10,
int a11,
int a12,
int a13,
int a14,
int a15,
void *a16,
int a17,
char a18)
{
unsigned int ExperimentalJavaFieldType; // eax
google::protobuf::compiler::java::WriteUInt32ToUtf16CharSequence(*(_DWORD *)(*(_QWORD *)(a1 + 8) + 4LL), (long long)a3);
ExperimentalJavaFieldType = google::protobuf::compiler::java::GetExperimentalJavaFieldType(
*(google::protobuf::compiler::java **)(a1 + 8),
a3);
google::protobuf::compiler::java::WriteUInt32ToUtf16CharSequence(ExperimentalJavaFieldType, (long long)a3);
return google::protobuf::io::Printer::Print(a2, a7, a8, a9, a10, a11, a12, a13, a14, a15, a16, a17, a18);
}
| GenerateFieldInfo:
PUSH R15
PUSH R14
PUSH RBX
MOV RBX,RDX
MOV R14,RSI
MOV R15,RDI
MOV RAX,qword ptr [RDI + 0x8]
MOV EDI,dword ptr [RAX + 0x4]
MOV RSI,RDX
CALL 0x00145d05
MOV RDI,qword ptr [R15 + 0x8]
CALL 0x00145ef8
MOV EDI,EAX
MOV RSI,RBX
CALL 0x00145d05
ADD R15,0x10
LEA RDX,[0x2ddb30]
MOV RDI,R14
MOV RSI,R15
POP RBX
POP R14
POP R15
JMP 0x0026cd32
|
/* google::protobuf::compiler::java::RepeatedImmutablePrimitiveFieldLiteGenerator::GenerateFieldInfo(google::protobuf::io::Printer*,
std::vector<unsigned short, std::allocator<unsigned short> >*) const */
void __thiscall
google::protobuf::compiler::java::RepeatedImmutablePrimitiveFieldLiteGenerator::GenerateFieldInfo
(RepeatedImmutablePrimitiveFieldLiteGenerator *this,Printer *param_1,vector *param_2)
{
uint uVar1;
WriteUInt32ToUtf16CharSequence(*(uint *)(*(long *)(this + 8) + 4),param_2);
uVar1 = GetExperimentalJavaFieldType(*(FieldDescriptor **)(this + 8));
WriteUInt32ToUtf16CharSequence(uVar1,param_2);
io::Printer::Print(param_1,(map *)(this + 0x10),"\"$name$_\",\n");
return;
}
| |
38,079 | mbedtls_platform_entropy_poll | msxemulator/build_O3/_deps/pico_sdk-src/lib/mbedtls/library/entropy_poll.c | int mbedtls_platform_entropy_poll(void *data,
unsigned char *output, size_t len, size_t *olen)
{
FILE *file;
size_t read_len;
int ret = MBEDTLS_ERR_ERROR_CORRUPTION_DETECTED;
((void) data);
#if defined(HAVE_GETRANDOM)
ret = getrandom_wrapper(output, len, 0);
if (ret >= 0) {
*olen = ret;
return 0;
} else if (errno != ENOSYS) {
return MBEDTLS_ERR_ENTROPY_SOURCE_FAILED;
}
/* Fall through if the system call isn't known. */
#else
((void) ret);
#endif /* HAVE_GETRANDOM */
#if defined(HAVE_SYSCTL_ARND)
((void) file);
((void) read_len);
if (sysctl_arnd_wrapper(output, len) == -1) {
return MBEDTLS_ERR_ENTROPY_SOURCE_FAILED;
}
*olen = len;
return 0;
#else
*olen = 0;
file = fopen("/dev/urandom", "rb");
if (file == NULL) {
return MBEDTLS_ERR_ENTROPY_SOURCE_FAILED;
}
read_len = fread(output, 1, len, file);
if (read_len != len) {
fclose(file);
return MBEDTLS_ERR_ENTROPY_SOURCE_FAILED;
}
fclose(file);
*olen = len;
return 0;
#endif /* HAVE_SYSCTL_ARND */
} | O3 | c | mbedtls_platform_entropy_poll:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rcx, %rbx
movq %rdx, %r14
movq %rsi, %r15
movl $0x13e, %edi # imm = 0x13E
xorl %ecx, %ecx
xorl %eax, %eax
callq 0xf090
testl %eax, %eax
js 0x8969e
andl $0x7fffffff, %eax # imm = 0x7FFFFFFF
movq %rax, %r14
movq %r14, (%rbx)
xorl %ebp, %ebp
jmp 0x896f2
callq 0xf060
movl $0xffffffc4, %ebp # imm = 0xFFFFFFC4
cmpl $0x26, (%rax)
jne 0x896f2
movq $0x0, (%rbx)
leaq 0x23b6e(%rip), %rdi # 0xad229
leaq 0x22b61(%rip), %rsi # 0xac223
callq 0xf540
testq %rax, %rax
je 0x896f2
movq %rax, %r12
movl $0x1, %esi
movq %r15, %rdi
movq %r14, %rdx
movq %rax, %rcx
callq 0xf690
movq %rax, %r15
movq %r12, %rdi
callq 0xf450
cmpq %r14, %r15
je 0x89697
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
| mbedtls_platform_entropy_poll:
push rbp
push r15
push r14
push r12
push rbx
mov rbx, rcx
mov r14, rdx
mov r15, rsi
mov edi, 13Eh
xor ecx, ecx
xor eax, eax
call _syscall
test eax, eax
js short loc_8969E
and eax, 7FFFFFFFh
mov r14, rax
loc_89697:
mov [rbx], r14
xor ebp, ebp
jmp short loc_896F2
loc_8969E:
call ___errno_location
mov ebp, 0FFFFFFC4h
cmp dword ptr [rax], 26h ; '&'
jnz short loc_896F2
mov qword ptr [rbx], 0
lea rdi, aDevUrandom; "/dev/urandom"
lea rsi, unk_AC223
call _fopen
test rax, rax
jz short loc_896F2
mov r12, rax
mov esi, 1
mov rdi, r15
mov rdx, r14
mov rcx, rax
call _fread
mov r15, rax
mov rdi, r12
call _fclose
cmp r15, r14
jz short loc_89697
loc_896F2:
mov eax, ebp
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
| long long mbedtls_platform_entropy_poll(long long a1, long long a2, long long a3, _QWORD *a4)
{
long long v5; // r14
int v6; // eax
unsigned int v7; // ebp
long long v8; // rax
long long v9; // r12
long long v10; // r15
v5 = a3;
v6 = syscall(318LL, a2, a3, 0LL);
if ( v6 >= 0 )
{
v5 = v6 & 0x7FFFFFFF;
LABEL_3:
*a4 = v5;
return 0;
}
v7 = -60;
if ( *(_DWORD *)__errno_location() == 38 )
{
*a4 = 0LL;
v8 = fopen("/dev/urandom", &unk_AC223);
if ( v8 )
{
v9 = v8;
v10 = fread(a2, 1LL, v5, v8);
fclose(v9);
if ( v10 == v5 )
goto LABEL_3;
}
}
return v7;
}
| mbedtls_platform_entropy_poll:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
MOV RBX,RCX
MOV R14,RDX
MOV R15,RSI
MOV EDI,0x13e
XOR ECX,ECX
XOR EAX,EAX
CALL 0x0010f090
TEST EAX,EAX
JS 0x0018969e
AND EAX,0x7fffffff
MOV R14,RAX
LAB_00189697:
MOV qword ptr [RBX],R14
XOR EBP,EBP
JMP 0x001896f2
LAB_0018969e:
CALL 0x0010f060
MOV EBP,0xffffffc4
CMP dword ptr [RAX],0x26
JNZ 0x001896f2
MOV qword ptr [RBX],0x0
LEA RDI,[0x1ad229]
LEA RSI,[0x1ac223]
CALL 0x0010f540
TEST RAX,RAX
JZ 0x001896f2
MOV R12,RAX
MOV ESI,0x1
MOV RDI,R15
MOV RDX,R14
MOV RCX,RAX
CALL 0x0010f690
MOV R15,RAX
MOV RDI,R12
CALL 0x0010f450
CMP R15,R14
JZ 0x00189697
LAB_001896f2:
MOV EAX,EBP
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
|
int8
mbedtls_platform_entropy_poll(int8 param_1,void *param_2,ulong param_3,ulong *param_4)
{
long lVar1;
int *piVar2;
FILE *__stream;
size_t sVar3;
lVar1 = syscall(0x13e,param_2,param_3,0);
if ((int)(uint)lVar1 < 0) {
piVar2 = __errno_location();
if (*piVar2 != 0x26) {
return 0xffffffc4;
}
*param_4 = 0;
__stream = fopen("/dev/urandom","rb");
if (__stream == (FILE *)0x0) {
return 0xffffffc4;
}
sVar3 = fread(param_2,1,param_3,__stream);
fclose(__stream);
if (sVar3 != param_3) {
return 0xffffffc4;
}
}
else {
param_3 = (ulong)((uint)lVar1 & 0x7fffffff);
}
*param_4 = param_3;
return 0;
}
| |
38,080 | minja::Value::dump_string(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, std::__cxx11::basic_ostringstream<char, std::char_traits<char>, std::allocator<char>>&, char) | monkey531[P]llama/common/minja.hpp | static void dump_string(const json & primitive, std::ostringstream & out, char string_quote = '\'') {
if (!primitive.is_string()) throw std::runtime_error("Value is not a string: " + primitive.dump());
auto s = primitive.dump();
if (string_quote == '"' || s.find('\'') != std::string::npos) {
out << s;
return;
}
// Reuse json dump, just changing string quotes
out << string_quote;
for (size_t i = 1, n = s.size() - 1; i < n; ++i) {
if (s[i] == '\\' && s[i + 1] == '"') {
out << '"';
i++;
} else if (s[i] == string_quote) {
out << '\\' << string_quote;
} else {
out << s[i];
}
}
out << string_quote;
} | O1 | cpp | minja::Value::dump_string(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, std::__cxx11::basic_ostringstream<char, std::char_traits<char>, std::allocator<char>>&, char):
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rdi, %r14
cmpb $0x3, (%rdi)
jne 0x88d49
movl %edx, %ebp
movq %rsi, %rbx
movq %rsp, %rdi
movq %r14, %rsi
movl $0xffffffff, %edx # imm = 0xFFFFFFFF
movl $0x20, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x8137a
cmpb $0x22, %bpl
je 0x88c49
movq %rsp, %rdi
movl $0x27, %esi
xorl %edx, %edx
callq 0x1bb30
cmpq $-0x1, %rax
je 0x88c82
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x1ba00
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x88c75
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1b8e0
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x20(%rsp), %rsi
movb %bpl, (%rsi)
movl $0x1, %edx
movq %rbx, %rdi
callq 0x1ba00
movq 0x8(%rsp), %r15
decq %r15
cmpq $0x2, %r15
jb 0x88d2f
movl $0x1, %r12d
leaq 0x20(%rsp), %r14
movq (%rsp), %rcx
movb (%rcx,%r12), %al
cmpb $0x5c, %al
jne 0x88ce2
cmpb $0x22, 0x1(%rcx,%r12)
jne 0x88ce2
movb $0x22, 0x20(%rsp)
movl $0x1, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1ba00
incq %r12
jmp 0x88d27
cmpb %bpl, %al
jne 0x88d13
movb $0x5c, 0x20(%rsp)
movl $0x1, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1ba00
movb %bpl, 0x20(%rsp)
movl $0x1, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x1ba00
jmp 0x88d27
movb %al, 0x20(%rsp)
movl $0x1, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1ba00
incq %r12
cmpq %r15, %r12
jb 0x88cb4
leaq 0x20(%rsp), %rsi
movb %bpl, (%rsi)
movl $0x1, %edx
movq %rbx, %rdi
callq 0x1ba00
jmp 0x88c5a
movl $0x10, %edi
callq 0x1b430
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
movq %r14, %rsi
movl $0xffffffff, %edx # imm = 0xFFFFFFFF
movl $0x20, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x8137a
leaq 0x69dfd(%rip), %rsi # 0xf2b77
movq %rsp, %rdi
leaq 0x20(%rsp), %rdx
callq 0x7a07b
movb $0x1, %bpl
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x1be30
xorl %ebp, %ebp
movq 0xa6252(%rip), %rsi # 0x12eff0
movq 0xa61bb(%rip), %rdx # 0x12ef60
movq %rbx, %rdi
callq 0x1bf20
movq %rax, %r14
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x88dd3
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1b8e0
jmp 0x88dd3
movq %rax, %r14
movb $0x1, %bpl
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x88df6
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1b8e0
jmp 0x88df6
movq %rax, %r14
movb $0x1, %bpl
testb %bpl, %bpl
je 0x88e25
movq %rbx, %rdi
callq 0x1b670
jmp 0x88e25
jmp 0x88e07
movq %rax, %r14
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x88e25
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1b8e0
movq %r14, %rdi
callq 0x1bfb0
nop
| _ZN5minja5Value11dump_stringERKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES5_IhSaIhEEvEERNS6_19basic_ostringstreamIcS9_SA_EEc:
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 40h
mov r14, rdi
cmp byte ptr [rdi], 3
jnz loc_88D49
mov ebp, edx
mov rbx, rsi
mov rdi, rsp
mov rsi, r14
mov edx, 0FFFFFFFFh
mov ecx, 20h ; ' '
xor r8d, r8d
xor r9d, r9d
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dumpEicbNS0_6detail15error_handler_tE; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::dump(int,char,bool,nlohmann::json_abi_v3_11_3::detail::error_handler_t)
cmp bpl, 22h ; '"'
jz short loc_88C49
mov rdi, rsp
mov esi, 27h ; '''
xor edx, edx
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEcm; std::string::find(char,ulong)
cmp rax, 0FFFFFFFFFFFFFFFFh
jz short loc_88C82
loc_88C49:
mov rsi, [rsp+68h+var_68]
mov rdx, [rsp+68h+var_60]
mov rdi, rbx
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
loc_88C5A:
lea rax, [rsp+68h+var_58]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_88C75
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_88C75:
add rsp, 40h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_88C82:
lea rsi, [rsp+68h+var_48]
mov [rsi], bpl
mov edx, 1
mov rdi, rbx
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov r15, [rsp+68h+var_60]
dec r15
cmp r15, 2
jb loc_88D2F
mov r12d, 1
lea r14, [rsp+68h+var_48]
loc_88CB4:
mov rcx, [rsp+68h+var_68]
mov al, [rcx+r12]
cmp al, 5Ch ; '\'
jnz short loc_88CE2
cmp byte ptr [rcx+r12+1], 22h ; '"'
jnz short loc_88CE2
mov [rsp+68h+var_48], 22h ; '"'
mov edx, 1
mov rdi, rbx
mov rsi, r14
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
inc r12
jmp short loc_88D27
loc_88CE2:
cmp al, bpl
jnz short loc_88D13
mov [rsp+68h+var_48], 5Ch ; '\'
mov edx, 1
mov rdi, rbx
mov rsi, 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 [rsp+68h+var_48], bpl
mov edx, 1
mov rdi, rax
mov rsi, r14
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
jmp short loc_88D27
loc_88D13:
mov [rsp+68h+var_48], al
mov edx, 1
mov rdi, rbx
mov rsi, r14
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
loc_88D27:
inc r12
cmp r12, r15
jb short loc_88CB4
loc_88D2F:
lea rsi, [rsp+68h+var_48]
mov [rsi], bpl
mov edx, 1
mov rdi, rbx
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
jmp loc_88C5A
loc_88D49:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea rdi, [rsp+68h+var_48]
mov rsi, r14
mov edx, 0FFFFFFFFh
mov ecx, 20h ; ' '
xor r8d, r8d
xor r9d, r9d
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dumpEicbNS0_6detail15error_handler_tE; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::dump(int,char,bool,nlohmann::json_abi_v3_11_3::detail::error_handler_t)
lea rsi, aValueIsNotAStr; "Value is not a string: "
mov rdi, rsp
lea rdx, [rsp+68h+var_48]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&)
mov bpl, 1
mov rsi, rsp
mov rdi, rbx
call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
xor ebp, ebp
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rax, [rsp+68h+var_58]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_88DD3
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_88DD3
mov r14, rax
mov bpl, 1
loc_88DD3:
lea rax, [rsp+68h+var_38]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_88DF6
mov rsi, [rsp+68h+var_38]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_88DF6
mov r14, rax
mov bpl, 1
loc_88DF6:
test bpl, bpl
jz short loc_88E25
mov rdi, rbx; void *
call ___cxa_free_exception
jmp short loc_88E25
jmp short $+2
loc_88E07:
mov r14, rax
lea rax, [rsp+68h+var_58]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_88E25
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_88E25:
mov rdi, r14
call __Unwind_Resume
| void minja::Value::dump_string(_BYTE *a1, long long a2, char a3)
{
unsigned long long v4; // r15
unsigned long long v5; // r12
char v6; // al
long long v7; // rax
void *exception; // rbx
long long *v9; // [rsp+0h] [rbp-68h] BYREF
long long v10; // [rsp+8h] [rbp-60h]
long long v11; // [rsp+10h] [rbp-58h] BYREF
_BYTE v12[16]; // [rsp+20h] [rbp-48h] BYREF
if ( *a1 != 3 )
{
exception = __cxa_allocate_exception(0x10uLL);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::dump(
(long long)v12,
(long long)a1,
-1,
32,
0,
0);
std::operator+<char>((long long)&v9, (long long)"Value is not a string: ", (long long)v12);
std::runtime_error::runtime_error(exception, &v9);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::dump(
(long long)&v9,
(long long)a1,
-1,
32,
0,
0);
if ( a3 != 34 && std::string::find(&v9, 39LL, 0LL) == -1 )
{
v12[0] = a3;
std::__ostream_insert<char,std::char_traits<char>>(a2, v12, 1LL);
v4 = v10 - 1;
if ( (unsigned long long)(v10 - 1) >= 2 )
{
v5 = 1LL;
do
{
v6 = *((_BYTE *)v9 + v5);
if ( v6 == 92 && *((_BYTE *)v9 + v5 + 1) == 34 )
{
v12[0] = 34;
std::__ostream_insert<char,std::char_traits<char>>(a2, v12, 1LL);
++v5;
}
else if ( v6 == a3 )
{
v12[0] = 92;
v7 = std::__ostream_insert<char,std::char_traits<char>>(a2, v12, 1LL);
v12[0] = a3;
std::__ostream_insert<char,std::char_traits<char>>(v7, v12, 1LL);
}
else
{
v12[0] = *((_BYTE *)v9 + v5);
std::__ostream_insert<char,std::char_traits<char>>(a2, v12, 1LL);
}
++v5;
}
while ( v5 < v4 );
}
v12[0] = a3;
std::__ostream_insert<char,std::char_traits<char>>(a2, v12, 1LL);
}
else
{
std::__ostream_insert<char,std::char_traits<char>>(a2, v9, v10);
}
if ( v9 != &v11 )
operator delete(v9, v11 + 1);
}
| dump_string:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x40
MOV R14,RDI
CMP byte ptr [RDI],0x3
JNZ 0x00188d49
MOV EBP,EDX
MOV RBX,RSI
MOV RDI,RSP
MOV RSI,R14
MOV EDX,0xffffffff
MOV ECX,0x20
XOR R8D,R8D
XOR R9D,R9D
CALL 0x0018137a
CMP BPL,0x22
JZ 0x00188c49
MOV RDI,RSP
MOV ESI,0x27
XOR EDX,EDX
CALL 0x0011bb30
CMP RAX,-0x1
JZ 0x00188c82
LAB_00188c49:
MOV RSI,qword ptr [RSP]
MOV RDX,qword ptr [RSP + 0x8]
LAB_00188c52:
MOV RDI,RBX
CALL 0x0011ba00
LAB_00188c5a:
LEA RAX,[RSP + 0x10]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x00188c75
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x0011b8e0
LAB_00188c75:
ADD RSP,0x40
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_00188c82:
LEA RSI,[RSP + 0x20]
MOV byte ptr [RSI],BPL
MOV EDX,0x1
MOV RDI,RBX
CALL 0x0011ba00
MOV R15,qword ptr [RSP + 0x8]
DEC R15
CMP R15,0x2
JC 0x00188d2f
MOV R12D,0x1
LEA R14,[RSP + 0x20]
LAB_00188cb4:
MOV RCX,qword ptr [RSP]
MOV AL,byte ptr [RCX + R12*0x1]
CMP AL,0x5c
JNZ 0x00188ce2
CMP byte ptr [RCX + R12*0x1 + 0x1],0x22
JNZ 0x00188ce2
MOV byte ptr [RSP + 0x20],0x22
LAB_00188ccd:
MOV EDX,0x1
MOV RDI,RBX
MOV RSI,R14
CALL 0x0011ba00
INC R12
JMP 0x00188d27
LAB_00188ce2:
CMP AL,BPL
JNZ 0x00188d13
MOV byte ptr [RSP + 0x20],0x5c
MOV EDX,0x1
MOV RDI,RBX
MOV RSI,R14
CALL 0x0011ba00
MOV byte ptr [RSP + 0x20],BPL
MOV EDX,0x1
MOV RDI,RAX
MOV RSI,R14
CALL 0x0011ba00
JMP 0x00188d27
LAB_00188d13:
MOV byte ptr [RSP + 0x20],AL
MOV EDX,0x1
MOV RDI,RBX
MOV RSI,R14
CALL 0x0011ba00
LAB_00188d27:
INC R12
CMP R12,R15
JC 0x00188cb4
LAB_00188d2f:
LEA RSI,[RSP + 0x20]
MOV byte ptr [RSI],BPL
LAB_00188d37:
MOV EDX,0x1
MOV RDI,RBX
CALL 0x0011ba00
LAB_00188d44:
JMP 0x00188c5a
LAB_00188d49:
MOV EDI,0x10
CALL 0x0011b430
MOV RBX,RAX
LAB_00188d56:
LEA RDI,[RSP + 0x20]
MOV RSI,R14
MOV EDX,0xffffffff
MOV ECX,0x20
XOR R8D,R8D
XOR R9D,R9D
CALL 0x0018137a
LAB_00188d73:
LEA RSI,[0x1f2b77]
MOV RDI,RSP
LEA RDX,[RSP + 0x20]
CALL 0x0017a07b
MOV BPL,0x1
LAB_00188d8a:
MOV RSI,RSP
MOV RDI,RBX
CALL 0x0011be30
XOR EBP,EBP
MOV RSI,qword ptr [0x0022eff0]
MOV RDX,qword ptr [0x0022ef60]
MOV RDI,RBX
CALL 0x0011bf20
|
/* minja::Value::dump_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> const&, std::__cxx11::ostringstream&, char) */
void minja::Value::dump_string(basic_json *param_1,ostringstream *param_2,char param_3)
{
long lVar1;
ostream *poVar2;
runtime_error *this;
ulong uVar3;
long *local_68;
long local_60;
long local_58 [2];
char local_48 [32];
if (*param_1 != (basic_json)0x3) {
this = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00188d56 to 00188d72 has its CatchHandler @ 00188df0 */
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::dump(local_48,param_1,0xffffffff,0x20,0,0);
/* try { // try from 00188d73 to 00188d86 has its CatchHandler @ 00188dcd */
std::operator+((char *)&local_68,(string *)"Value is not a string: ");
/* try { // try from 00188d8a to 00188dac has its CatchHandler @ 00188dad */
std::runtime_error::runtime_error(this,(string *)&local_68);
/* WARNING: Subroutine does not return */
__cxa_throw(this,PTR_typeinfo_0022eff0,PTR__runtime_error_0022ef60);
}
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::dump(&local_68,param_1,0xffffffff,0x20,0,0);
if (param_3 != '\"') {
lVar1 = std::__cxx11::string::find((char)&local_68,0x27);
if (lVar1 == -1) {
local_48[0] = param_3;
std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,local_48,1);
if (1 < local_60 - 1U) {
uVar3 = 1;
do {
local_48[0] = *(char *)((long)local_68 + uVar3);
if ((local_48[0] == '\\') && (*(char *)((long)local_68 + uVar3 + 1) == '\"')) {
local_48[0] = '\"';
/* try { // try from 00188ccd to 00188d26 has its CatchHandler @ 00188e07 */
std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,local_48,1);
uVar3 = uVar3 + 1;
}
else if (local_48[0] == param_3) {
local_48[0] = '\\';
poVar2 = std::__ostream_insert<char,std::char_traits<char>>
((ostream *)param_2,local_48,1);
local_48[0] = param_3;
std::__ostream_insert<char,std::char_traits<char>>(poVar2,local_48,1);
}
else {
std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,local_48,1);
}
uVar3 = uVar3 + 1;
} while (uVar3 < local_60 - 1U);
}
local_48[0] = param_3;
/* try { // try from 00188d37 to 00188d43 has its CatchHandler @ 00188e05 */
std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,local_48,1);
goto LAB_00188c5a;
}
}
/* try { // try from 00188c52 to 00188c96 has its CatchHandler @ 00188e05 */
std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,(char *)local_68,local_60);
LAB_00188c5a:
if (local_68 != local_58) {
operator_delete(local_68,local_58[0] + 1);
}
return;
}
| |
38,081 | minja::Value::dump_string(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, std::__cxx11::basic_ostringstream<char, std::char_traits<char>, std::allocator<char>>&, char) | monkey531[P]llama/common/minja.hpp | static void dump_string(const json & primitive, std::ostringstream & out, char string_quote = '\'') {
if (!primitive.is_string()) throw std::runtime_error("Value is not a string: " + primitive.dump());
auto s = primitive.dump();
if (string_quote == '"' || s.find('\'') != std::string::npos) {
out << s;
return;
}
// Reuse json dump, just changing string quotes
out << string_quote;
for (size_t i = 1, n = s.size() - 1; i < n; ++i) {
if (s[i] == '\\' && s[i + 1] == '"') {
out << '"';
i++;
} else if (s[i] == string_quote) {
out << '\\' << string_quote;
} else {
out << s[i];
}
}
out << string_quote;
} | O3 | cpp | minja::Value::dump_string(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, std::__cxx11::basic_ostringstream<char, std::char_traits<char>, std::allocator<char>>&, char):
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x40, %rsp
movq %rdi, %r14
cmpb $0x3, (%rdi)
jne 0x87833
movl %edx, %ebp
movq %rsi, %rbx
movq %rsp, %rdi
movq %r14, %rsi
movl $0xffffffff, %edx # imm = 0xFFFFFFFF
movl $0x20, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x80148
cmpb $0x22, %bpl
je 0x87733
movq %rsp, %rdi
movl $0x27, %esi
xorl %edx, %edx
callq 0x1ab30
cmpq $-0x1, %rax
je 0x8776c
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x1aa00
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x8775f
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1a8e0
addq $0x40, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
leaq 0x20(%rsp), %rsi
movb %bpl, (%rsi)
movl $0x1, %edx
movq %rbx, %rdi
callq 0x1aa00
movq 0x8(%rsp), %r15
decq %r15
cmpq $0x2, %r15
jb 0x87819
movl $0x1, %r12d
leaq 0x20(%rsp), %r14
movq (%rsp), %rcx
movb (%rcx,%r12), %al
cmpb $0x5c, %al
jne 0x877cc
cmpb $0x22, 0x1(%rcx,%r12)
jne 0x877cc
movb $0x22, 0x20(%rsp)
movl $0x1, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1aa00
incq %r12
jmp 0x87811
cmpb %bpl, %al
jne 0x877fd
movb $0x5c, 0x20(%rsp)
movl $0x1, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1aa00
movb %bpl, 0x20(%rsp)
movl $0x1, %edx
movq %rax, %rdi
movq %r14, %rsi
callq 0x1aa00
jmp 0x87811
movb %al, 0x20(%rsp)
movl $0x1, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1aa00
incq %r12
cmpq %r15, %r12
jb 0x8779e
leaq 0x20(%rsp), %rsi
movb %bpl, (%rsi)
movl $0x1, %edx
movq %rbx, %rdi
callq 0x1aa00
jmp 0x87744
movl $0x10, %edi
callq 0x1a430
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
movq %r14, %rsi
movl $0xffffffff, %edx # imm = 0xFFFFFFFF
movl $0x20, %ecx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x80148
leaq 0x68303(%rip), %rsi # 0xefb67
movq %rsp, %rdi
leaq 0x20(%rsp), %rdx
callq 0x794e9
movb $0x1, %bpl
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x1ae30
xorl %ebp, %ebp
movq 0xa4768(%rip), %rsi # 0x12bff0
movq 0xa46d1(%rip), %rdx # 0x12bf60
movq %rbx, %rdi
callq 0x1af20
movq %rax, %r14
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x878b5
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1a8e0
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x878d0
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1a8e0
testb %bpl, %bpl
jne 0x878fa
jmp 0x87924
movq %rax, %r14
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x878fa
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x1a8e0
jmp 0x878fa
movq %rax, %r14
movq %rbx, %rdi
callq 0x1a670
jmp 0x87924
jmp 0x87906
movq %rax, %r14
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x87924
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x1a8e0
movq %r14, %rdi
callq 0x1afb0
| _ZN5minja5Value11dump_stringERKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES5_IhSaIhEEvEERNS6_19basic_ostringstreamIcS9_SA_EEc:
push rbp
push r15
push r14
push r12
push rbx
sub rsp, 40h
mov r14, rdi
cmp byte ptr [rdi], 3
jnz loc_87833
mov ebp, edx
mov rbx, rsi
mov rdi, rsp
mov rsi, r14
mov edx, 0FFFFFFFFh
mov ecx, 20h ; ' '
xor r8d, r8d
xor r9d, r9d
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dumpEicbNS0_6detail15error_handler_tE; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::dump(int,char,bool,nlohmann::json_abi_v3_11_3::detail::error_handler_t)
cmp bpl, 22h ; '"'
jz short loc_87733
mov rdi, rsp
mov esi, 27h ; '''
xor edx, edx
call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE4findEcm; std::string::find(char,ulong)
cmp rax, 0FFFFFFFFFFFFFFFFh
jz short loc_8776C
loc_87733:
mov rsi, [rsp+68h+var_68]
mov rdx, [rsp+68h+var_60]
mov rdi, rbx
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
loc_87744:
lea rax, [rsp+68h+var_58]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_8775F
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_8775F:
add rsp, 40h
pop rbx
pop r12
pop r14
pop r15
pop rbp
retn
loc_8776C:
lea rsi, [rsp+68h+var_48]
mov [rsi], bpl
mov edx, 1
mov rdi, rbx
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
mov r15, [rsp+68h+var_60]
dec r15
cmp r15, 2
jb loc_87819
mov r12d, 1
lea r14, [rsp+68h+var_48]
loc_8779E:
mov rcx, [rsp+68h+var_68]
mov al, [rcx+r12]
cmp al, 5Ch ; '\'
jnz short loc_877CC
cmp byte ptr [rcx+r12+1], 22h ; '"'
jnz short loc_877CC
mov [rsp+68h+var_48], 22h ; '"'
mov edx, 1
mov rdi, rbx
mov rsi, r14
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
inc r12
jmp short loc_87811
loc_877CC:
cmp al, bpl
jnz short loc_877FD
mov [rsp+68h+var_48], 5Ch ; '\'
mov edx, 1
mov rdi, rbx
mov rsi, 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 [rsp+68h+var_48], bpl
mov edx, 1
mov rdi, rax
mov rsi, r14
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
jmp short loc_87811
loc_877FD:
mov [rsp+68h+var_48], al
mov edx, 1
mov rdi, rbx
mov rsi, r14
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
loc_87811:
inc r12
cmp r12, r15
jb short loc_8779E
loc_87819:
lea rsi, [rsp+68h+var_48]
mov [rsi], bpl
mov edx, 1
mov rdi, rbx
call __ZSt16__ostream_insertIcSt11char_traitsIcEERSt13basic_ostreamIT_T0_ES6_PKS3_l; std::__ostream_insert<char,std::char_traits<char>>(std::ostream &,char const*,long)
jmp loc_87744
loc_87833:
mov edi, 10h; thrown_size
call ___cxa_allocate_exception
mov rbx, rax
lea rdi, [rsp+68h+var_48]
mov rsi, r14
mov edx, 0FFFFFFFFh
mov ecx, 20h ; ' '
xor r8d, r8d
xor r9d, r9d
call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dumpEicbNS0_6detail15error_handler_tE; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::dump(int,char,bool,nlohmann::json_abi_v3_11_3::detail::error_handler_t)
lea rsi, aValueIsNotAStr; "Value is not a string: "
mov rdi, rsp
lea rdx, [rsp+68h+var_48]
call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_; std::operator+<char>(char const*,std::string&&)
mov bpl, 1
mov rsi, rsp
mov rdi, rbx
call __ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; std::runtime_error::runtime_error(std::string const&)
xor ebp, ebp
mov rsi, cs:_ZTISt13runtime_error_ptr; lptinfo
mov rdx, cs:_ZTISt19_Sp_make_shared_tag; void (*)(void *)
mov rdi, rbx; void *
call ___cxa_throw
mov r14, rax
lea rax, [rsp+68h+var_58]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_878B5
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_878B5:
lea rax, [rsp+68h+var_38]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_878D0
mov rsi, [rsp+68h+var_38]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_878D0:
test bpl, bpl
jnz short loc_878FA
jmp short loc_87924
mov r14, rax
lea rax, [rsp+68h+var_38]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_878FA
mov rsi, [rsp+68h+var_38]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
jmp short loc_878FA
mov r14, rax
loc_878FA:
mov rdi, rbx; void *
call ___cxa_free_exception
jmp short loc_87924
jmp short $+2
loc_87906:
mov r14, rax
lea rax, [rsp+68h+var_58]
mov rdi, [rax-10h]; void *
cmp rdi, rax
jz short loc_87924
mov rsi, [rsp+68h+var_58]
inc rsi; unsigned __int64
call __ZdlPvm; operator delete(void *,ulong)
loc_87924:
mov rdi, r14
call __Unwind_Resume
| void minja::Value::dump_string(_BYTE *a1, long long a2, char a3)
{
unsigned long long v4; // r15
unsigned long long v5; // r12
char v6; // al
long long v7; // rax
void *exception; // rbx
long long *v9; // [rsp+0h] [rbp-68h] BYREF
long long v10; // [rsp+8h] [rbp-60h]
long long v11; // [rsp+10h] [rbp-58h] BYREF
_BYTE v12[16]; // [rsp+20h] [rbp-48h] BYREF
if ( *a1 != 3 )
{
exception = __cxa_allocate_exception(0x10uLL);
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::dump(
(long long)v12,
(long long)a1,
-1,
32,
0,
0);
std::operator+<char>((long long)&v9, (long long)"Value is not a string: ", (long long)v12);
std::runtime_error::runtime_error(exception, &v9);
__cxa_throw(
exception,
(struct type_info *)&`typeinfo for'std::runtime_error,
(void (*)(void *))&std::runtime_error::~runtime_error);
}
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::dump(
(long long)&v9,
(long long)a1,
-1,
32,
0,
0);
if ( a3 != 34 && std::string::find(&v9, 39LL, 0LL) == -1 )
{
v12[0] = a3;
std::__ostream_insert<char,std::char_traits<char>>(a2, v12, 1LL);
v4 = v10 - 1;
if ( (unsigned long long)(v10 - 1) >= 2 )
{
v5 = 1LL;
do
{
v6 = *((_BYTE *)v9 + v5);
if ( v6 == 92 && *((_BYTE *)v9 + v5 + 1) == 34 )
{
v12[0] = 34;
std::__ostream_insert<char,std::char_traits<char>>(a2, v12, 1LL);
++v5;
}
else if ( v6 == a3 )
{
v12[0] = 92;
v7 = std::__ostream_insert<char,std::char_traits<char>>(a2, v12, 1LL);
v12[0] = a3;
std::__ostream_insert<char,std::char_traits<char>>(v7, v12, 1LL);
}
else
{
v12[0] = *((_BYTE *)v9 + v5);
std::__ostream_insert<char,std::char_traits<char>>(a2, v12, 1LL);
}
++v5;
}
while ( v5 < v4 );
}
v12[0] = a3;
std::__ostream_insert<char,std::char_traits<char>>(a2, v12, 1LL);
}
else
{
std::__ostream_insert<char,std::char_traits<char>>(a2, v9, v10);
}
if ( v9 != &v11 )
operator delete(v9, v11 + 1);
}
| dump_string:
PUSH RBP
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x40
MOV R14,RDI
CMP byte ptr [RDI],0x3
JNZ 0x00187833
MOV EBP,EDX
MOV RBX,RSI
MOV RDI,RSP
MOV RSI,R14
MOV EDX,0xffffffff
MOV ECX,0x20
XOR R8D,R8D
XOR R9D,R9D
CALL 0x00180148
CMP BPL,0x22
JZ 0x00187733
MOV RDI,RSP
MOV ESI,0x27
XOR EDX,EDX
CALL 0x0011ab30
CMP RAX,-0x1
JZ 0x0018776c
LAB_00187733:
MOV RSI,qword ptr [RSP]
MOV RDX,qword ptr [RSP + 0x8]
LAB_0018773c:
MOV RDI,RBX
CALL 0x0011aa00
LAB_00187744:
LEA RAX,[RSP + 0x10]
MOV RDI,qword ptr [RAX + -0x10]
CMP RDI,RAX
JZ 0x0018775f
MOV RSI,qword ptr [RSP + 0x10]
INC RSI
CALL 0x0011a8e0
LAB_0018775f:
ADD RSP,0x40
POP RBX
POP R12
POP R14
POP R15
POP RBP
RET
LAB_0018776c:
LEA RSI,[RSP + 0x20]
MOV byte ptr [RSI],BPL
MOV EDX,0x1
MOV RDI,RBX
CALL 0x0011aa00
MOV R15,qword ptr [RSP + 0x8]
DEC R15
CMP R15,0x2
JC 0x00187819
MOV R12D,0x1
LEA R14,[RSP + 0x20]
LAB_0018779e:
MOV RCX,qword ptr [RSP]
MOV AL,byte ptr [RCX + R12*0x1]
CMP AL,0x5c
JNZ 0x001877cc
CMP byte ptr [RCX + R12*0x1 + 0x1],0x22
JNZ 0x001877cc
MOV byte ptr [RSP + 0x20],0x22
LAB_001877b7:
MOV EDX,0x1
MOV RDI,RBX
MOV RSI,R14
CALL 0x0011aa00
INC R12
JMP 0x00187811
LAB_001877cc:
CMP AL,BPL
JNZ 0x001877fd
MOV byte ptr [RSP + 0x20],0x5c
MOV EDX,0x1
MOV RDI,RBX
MOV RSI,R14
CALL 0x0011aa00
MOV byte ptr [RSP + 0x20],BPL
MOV EDX,0x1
MOV RDI,RAX
MOV RSI,R14
CALL 0x0011aa00
JMP 0x00187811
LAB_001877fd:
MOV byte ptr [RSP + 0x20],AL
MOV EDX,0x1
MOV RDI,RBX
MOV RSI,R14
CALL 0x0011aa00
LAB_00187811:
INC R12
CMP R12,R15
JC 0x0018779e
LAB_00187819:
LEA RSI,[RSP + 0x20]
MOV byte ptr [RSI],BPL
LAB_00187821:
MOV EDX,0x1
MOV RDI,RBX
CALL 0x0011aa00
LAB_0018782e:
JMP 0x00187744
LAB_00187833:
MOV EDI,0x10
CALL 0x0011a430
MOV RBX,RAX
LAB_00187840:
LEA RDI,[RSP + 0x20]
MOV RSI,R14
MOV EDX,0xffffffff
MOV ECX,0x20
XOR R8D,R8D
XOR R9D,R9D
CALL 0x00180148
LAB_0018785d:
LEA RSI,[0x1efb67]
MOV RDI,RSP
LEA RDX,[RSP + 0x20]
CALL 0x001794e9
MOV BPL,0x1
LAB_00187874:
MOV RSI,RSP
MOV RDI,RBX
CALL 0x0011ae30
XOR EBP,EBP
MOV RSI,qword ptr [0x0022bff0]
MOV RDX,qword ptr [0x0022bf60]
MOV RDI,RBX
CALL 0x0011af20
|
/* minja::Value::dump_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> const&, std::__cxx11::ostringstream&, char) */
void minja::Value::dump_string(basic_json *param_1,ostringstream *param_2,char param_3)
{
long lVar1;
ostream *poVar2;
runtime_error *this;
ulong uVar3;
long *local_68;
long local_60;
long local_58 [2];
char local_48 [32];
if (*param_1 != (basic_json)0x3) {
this = (runtime_error *)__cxa_allocate_exception(0x10);
/* try { // try from 00187840 to 0018785c has its CatchHandler @ 001878f7 */
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::dump(local_48,param_1,0xffffffff,0x20,0,0);
/* try { // try from 0018785d to 00187870 has its CatchHandler @ 001878d7 */
std::operator+((char *)&local_68,(string *)"Value is not a string: ");
/* try { // try from 00187874 to 00187896 has its CatchHandler @ 00187897 */
std::runtime_error::runtime_error(this,(string *)&local_68);
/* WARNING: Subroutine does not return */
__cxa_throw(this,PTR_typeinfo_0022bff0,PTR__runtime_error_0022bf60);
}
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::dump(&local_68,param_1,0xffffffff,0x20,0,0);
if (param_3 != '\"') {
lVar1 = std::__cxx11::string::find((char)&local_68,0x27);
if (lVar1 == -1) {
local_48[0] = param_3;
std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,local_48,1);
if (1 < local_60 - 1U) {
uVar3 = 1;
do {
local_48[0] = *(char *)((long)local_68 + uVar3);
if ((local_48[0] == '\\') && (*(char *)((long)local_68 + uVar3 + 1) == '\"')) {
local_48[0] = '\"';
/* try { // try from 001877b7 to 00187810 has its CatchHandler @ 00187906 */
std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,local_48,1);
uVar3 = uVar3 + 1;
}
else if (local_48[0] == param_3) {
local_48[0] = '\\';
poVar2 = std::__ostream_insert<char,std::char_traits<char>>
((ostream *)param_2,local_48,1);
local_48[0] = param_3;
std::__ostream_insert<char,std::char_traits<char>>(poVar2,local_48,1);
}
else {
std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,local_48,1);
}
uVar3 = uVar3 + 1;
} while (uVar3 < local_60 - 1U);
}
local_48[0] = param_3;
/* try { // try from 00187821 to 0018782d has its CatchHandler @ 00187904 */
std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,local_48,1);
goto LAB_00187744;
}
}
/* try { // try from 0018773c to 00187780 has its CatchHandler @ 00187904 */
std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,(char *)local_68,local_60);
LAB_00187744:
if (local_68 != local_58) {
operator_delete(local_68,local_58[0] + 1);
}
return;
}
| |
38,082 | my_hash_sort_bin | eloqsql/strings/ctype-bin.c | void my_hash_sort_bin(CHARSET_INFO *cs __attribute__((unused)),
const uchar *key, size_t len,ulong *nr1, ulong *nr2)
{
const uchar *end = key + len;
ulong tmp1= *nr1;
ulong tmp2= *nr2;
for (; key < end ; key++)
{
MY_HASH_ADD(tmp1, tmp2, (uint) *key);
}
*nr1= tmp1;
*nr2= tmp2;
} | O3 | c | my_hash_sort_bin:
movq (%rcx), %rax
movq (%r8), %rdi
testq %rdx, %rdx
jle 0x67f97
pushq %rbp
movq %rsp, %rbp
addq %rsi, %rdx
movl %eax, %r9d
andl $0x3f, %r9d
addq %rdi, %r9
movzbl (%rsi), %r10d
imulq %r9, %r10
movq %rax, %r9
shlq $0x8, %r9
addq %r10, %r9
xorq %r9, %rax
addq $0x3, %rdi
incq %rsi
cmpq %rdx, %rsi
jb 0x67f6b
popq %rbp
movq %rax, (%rcx)
movq %rdi, (%r8)
retq
| my_hash_sort_bin:
mov rax, [rcx]
mov rdi, [r8]
test rdx, rdx
jle short loc_67F97
push rbp
mov rbp, rsp
add rdx, rsi
loc_67F6B:
mov r9d, eax
and r9d, 3Fh
add r9, rdi
movzx r10d, byte ptr [rsi]
imul r10, r9
mov r9, rax
shl r9, 8
add r9, r10
xor rax, r9
add rdi, 3
inc rsi
cmp rsi, rdx
jb short loc_67F6B
pop rbp
loc_67F97:
mov [rcx], rax
mov [r8], rdi
retn
| long long my_hash_sort_bin(long long a1, unsigned __int8 *a2, long long a3, long long *a4, long long *a5)
{
long long result; // rax
long long v6; // rdi
unsigned __int8 *v7; // rdx
result = *a4;
v6 = *a5;
if ( a3 > 0 )
{
v7 = &a2[a3];
do
{
result ^= (v6 + (result & 0x3F)) * *a2 + (result << 8);
v6 += 3LL;
++a2;
}
while ( a2 < v7 );
}
*a4 = result;
*a5 = v6;
return result;
}
| my_hash_sort_bin:
MOV RAX,qword ptr [RCX]
MOV RDI,qword ptr [R8]
TEST RDX,RDX
JLE 0x00167f97
PUSH RBP
MOV RBP,RSP
ADD RDX,RSI
LAB_00167f6b:
MOV R9D,EAX
AND R9D,0x3f
ADD R9,RDI
MOVZX R10D,byte ptr [RSI]
IMUL R10,R9
MOV R9,RAX
SHL R9,0x8
ADD R9,R10
XOR RAX,R9
ADD RDI,0x3
INC RSI
CMP RSI,RDX
JC 0x00167f6b
POP RBP
LAB_00167f97:
MOV qword ptr [RCX],RAX
MOV qword ptr [R8],RDI
RET
|
void my_hash_sort_bin(int8 param_1,byte *param_2,long param_3,ulong *param_4,long *param_5)
{
ulong uVar1;
byte *pbVar2;
long lVar3;
uVar1 = *param_4;
lVar3 = *param_5;
if (0 < param_3) {
pbVar2 = param_2 + param_3;
do {
uVar1 = uVar1 ^ uVar1 * 0x100 + (ulong)*param_2 * ((ulong)((uint)uVar1 & 0x3f) + lVar3);
lVar3 = lVar3 + 3;
param_2 = param_2 + 1;
} while (param_2 < pbVar2);
}
*param_4 = uVar1;
*param_5 = lVar3;
return;
}
| |
38,083 | ma_find_writepos | eloqsql/storage/maria/ma_dynrec.c | static int _ma_find_writepos(MARIA_HA *info,
ulong reclength, /* record length */
my_off_t *filepos, /* Return file pos */
ulong *length) /* length of block at filepos */
{
MARIA_BLOCK_INFO block_info;
ulong tmp;
DBUG_ENTER("_ma_find_writepos");
if (info->s->state.dellink != HA_OFFSET_ERROR &&
!info->append_insert_at_end)
{
/* Deleted blocks exists; Get last used block */
*filepos=info->s->state.dellink;
block_info.second_read=0;
info->rec_cache.seek_not_done=1;
if (!(_ma_get_block_info(info, &block_info, info->dfile.file,
info->s->state.dellink) &
BLOCK_DELETED))
{
DBUG_PRINT("error",("Delete link crashed"));
_ma_set_fatal_error_with_share(info->s, HA_ERR_WRONG_IN_RECORD);
DBUG_RETURN(-1);
}
info->s->state.dellink=block_info.next_filepos;
info->state->del--;
info->state->empty-= block_info.block_len;
*length= block_info.block_len;
}
else
{
/* No deleted blocks; Allocate a new block */
*filepos=info->state->data_file_length;
if ((tmp= reclength + 3 + MY_TEST(reclength >= (65520 - 3))) <
info->s->base.min_block_length)
tmp= info->s->base.min_block_length;
else
tmp= ((tmp+MARIA_DYN_ALIGN_SIZE-1) &
(~ (ulong) (MARIA_DYN_ALIGN_SIZE-1)));
if (info->state->data_file_length >
(info->s->base.max_data_file_length - tmp))
{
my_errno=HA_ERR_RECORD_FILE_FULL;
DBUG_RETURN(-1);
}
if (tmp > MARIA_MAX_BLOCK_LENGTH)
tmp=MARIA_MAX_BLOCK_LENGTH;
*length= tmp;
info->state->data_file_length+= tmp;
info->s->state.split++;
info->update|=HA_STATE_WRITE_AT_END;
}
DBUG_RETURN(0);
} | O3 | c | ma_find_writepos:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x60, %rsp
movq %rcx, %r14
movq %rdi, %rbx
movq %fs:0x28, %rax
movq %rax, -0x18(%rbp)
movq (%rdi), %rax
movq 0xc8(%rax), %rax
cmpq $-0x1, %rax
je 0x49f68
cmpb $0x0, 0x681(%rbx)
je 0x49fe6
movq 0x20(%rbx), %rax
movq 0x28(%rax), %rax
movq %rax, (%rdx)
cmpq $0xffed, %rsi # imm = 0xFFED
sbbq $-0x1, %rsi
leaq 0x3(%rsi), %rax
movq (%rbx), %rcx
movq 0x20(%rbx), %rdx
movq 0x3b8(%rcx), %rdi
addq $0x6, %rsi
andq $-0x4, %rsi
cmpq %rdi, %rax
cmovbq %rdi, %rsi
movq 0x368(%rcx), %rax
subq %rsi, %rax
cmpq %rax, 0x28(%rdx)
jbe 0x49fbc
callq 0xa1ac2
movl $0x87, (%rax)
jmp 0x4a027
movl $0xfffffc, %eax # imm = 0xFFFFFC
cmpq %rax, %rsi
cmovbq %rsi, %rax
movq %rax, (%r14)
movq 0x20(%rbx), %rcx
addq %rax, 0x28(%rcx)
movq (%rbx), %rax
incq 0xc0(%rax)
orb $0x1, 0x625(%rbx)
jmp 0x4a057
movq %rax, (%rdx)
leaq -0x70(%rbp), %rsi
movl $0x0, 0x50(%rsi)
movl $0x1, 0x598(%rbx)
movl 0x480(%rbx), %edx
movq (%rbx), %rax
movq 0xc8(%rax), %rcx
movq %rbx, %rdi
callq 0x48398
testb $0x4, %al
jne 0x4a02e
movq (%rbx), %rdi
movl $0x7f, %esi
callq 0x3fc8a
movl $0xffffffff, %eax # imm = 0xFFFFFFFF
jmp 0x4a059
movq -0x30(%rbp), %rax
movq (%rbx), %rcx
movq %rax, 0xc8(%rcx)
movq 0x20(%rbx), %rax
decq 0x8(%rax)
movq -0x48(%rbp), %rax
movq 0x20(%rbx), %rcx
subq %rax, 0x10(%rcx)
movq -0x48(%rbp), %rax
movq %rax, (%r14)
xorl %eax, %eax
movq %fs:0x28, %rcx
cmpq -0x18(%rbp), %rcx
jne 0x4a071
addq $0x60, %rsp
popq %rbx
popq %r14
popq %rbp
retq
callq 0x29250
nop
| _ma_find_writepos:
push rbp
mov rbp, rsp
push r14
push rbx
sub rsp, 60h
mov r14, rcx
mov rbx, rdi
mov rax, fs:28h
mov [rbp+var_18], rax
mov rax, [rdi]
mov rax, [rax+0C8h]
cmp rax, 0FFFFFFFFFFFFFFFFh
jz short loc_49F68
cmp byte ptr [rbx+681h], 0
jz short loc_49FE6
loc_49F68:
mov rax, [rbx+20h]
mov rax, [rax+28h]
mov [rdx], rax
cmp rsi, 0FFEDh
sbb rsi, 0FFFFFFFFFFFFFFFFh
lea rax, [rsi+3]
mov rcx, [rbx]
mov rdx, [rbx+20h]
mov rdi, [rcx+3B8h]
add rsi, 6
and rsi, 0FFFFFFFFFFFFFFFCh
cmp rax, rdi
cmovb rsi, rdi
mov rax, [rcx+368h]
sub rax, rsi
cmp [rdx+28h], rax
jbe short loc_49FBC
call _my_thread_var
mov dword ptr [rax], 87h
jmp short loc_4A027
loc_49FBC:
mov eax, 0FFFFFCh
cmp rsi, rax
cmovb rax, rsi
mov [r14], rax
mov rcx, [rbx+20h]
add [rcx+28h], rax
mov rax, [rbx]
inc qword ptr [rax+0C0h]
or byte ptr [rbx+625h], 1
jmp short loc_4A057
loc_49FE6:
mov [rdx], rax
lea rsi, [rbp+var_70]
mov dword ptr [rsi+50h], 0
mov dword ptr [rbx+598h], 1
mov edx, [rbx+480h]
mov rax, [rbx]
mov rcx, [rax+0C8h]
mov rdi, rbx
call _ma_get_block_info
test al, 4
jnz short loc_4A02E
mov rdi, [rbx]
mov esi, 7Fh
call _ma_set_fatal_error_with_share
loc_4A027:
mov eax, 0FFFFFFFFh
jmp short loc_4A059
loc_4A02E:
mov rax, [rbp+var_30]
mov rcx, [rbx]
mov [rcx+0C8h], rax
mov rax, [rbx+20h]
dec qword ptr [rax+8]
mov rax, [rbp+var_48]
mov rcx, [rbx+20h]
sub [rcx+10h], rax
mov rax, [rbp+var_48]
mov [r14], rax
loc_4A057:
xor eax, eax
loc_4A059:
mov rcx, fs:28h
cmp rcx, [rbp+var_18]
jnz short loc_4A071
add rsp, 60h
pop rbx
pop r14
pop rbp
retn
loc_4A071:
call ___stack_chk_fail
| long long ma_find_writepos(_QWORD *a1, unsigned long long a2, _QWORD *a3, long long *a4, long long a5, int a6)
{
long long v8; // rax
unsigned long long v9; // rsi
unsigned long long v10; // rax
long long v11; // rcx
long long v12; // rdx
unsigned long long v13; // rdi
unsigned long long v14; // rsi
long long v15; // rax
long long v16; // rdx
long long v17; // rcx
long long v18; // r8
int v19; // r9d
unsigned __int8 v21[40]; // [rsp+0h] [rbp-70h] BYREF
long long v22; // [rsp+28h] [rbp-48h]
long long v23; // [rsp+40h] [rbp-30h]
int v24; // [rsp+50h] [rbp-20h]
unsigned long long v25; // [rsp+58h] [rbp-18h]
v25 = __readfsqword(0x28u);
v8 = *(_QWORD *)(*a1 + 200LL);
if ( v8 == -1 || *((_BYTE *)a1 + 1665) )
{
*a3 = *(_QWORD *)(a1[4] + 40LL);
v9 = a2 - ((a2 < 0xFFED) - 1LL);
v10 = v9 + 3;
v11 = *a1;
v12 = a1[4];
v13 = *(_QWORD *)(*a1 + 952LL);
v14 = (v9 + 6) & 0xFFFFFFFFFFFFFFFCLL;
if ( v10 < v13 )
v14 = *(_QWORD *)(*a1 + 952LL);
if ( *(_QWORD *)(v12 + 40) > *(_QWORD *)(v11 + 872) - v14 )
{
*(_DWORD *)my_thread_var(v13) = 135;
return 0xFFFFFFFFLL;
}
v15 = 16777212LL;
if ( v14 < 0xFFFFFC )
v15 = v14;
*a4 = v15;
*(_QWORD *)(a1[4] + 40LL) += v15;
++*(_QWORD *)(*a1 + 192LL);
*((_BYTE *)a1 + 1573) |= 1u;
}
else
{
*a3 = v8;
v24 = 0;
*((_DWORD *)a1 + 358) = 1;
if ( (ma_get_block_info((long long)a1, v21, *((unsigned int *)a1 + 288), *(_QWORD *)(*a1 + 200LL), a5, a6) & 4) == 0 )
{
ma_set_fatal_error_with_share(*a1, 127, v16, v17, v18, v19);
return 0xFFFFFFFFLL;
}
*(_QWORD *)(*a1 + 200LL) = v23;
--*(_QWORD *)(a1[4] + 8LL);
*(_QWORD *)(a1[4] + 16LL) -= v22;
*a4 = v22;
}
return 0LL;
}
| _ma_find_writepos:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
SUB RSP,0x60
MOV R14,RCX
MOV RBX,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [RDI]
MOV RAX,qword ptr [RAX + 0xc8]
CMP RAX,-0x1
JZ 0x00149f68
CMP byte ptr [RBX + 0x681],0x0
JZ 0x00149fe6
LAB_00149f68:
MOV RAX,qword ptr [RBX + 0x20]
MOV RAX,qword ptr [RAX + 0x28]
MOV qword ptr [RDX],RAX
CMP RSI,0xffed
SBB RSI,-0x1
LEA RAX,[RSI + 0x3]
MOV RCX,qword ptr [RBX]
MOV RDX,qword ptr [RBX + 0x20]
MOV RDI,qword ptr [RCX + 0x3b8]
ADD RSI,0x6
AND RSI,-0x4
CMP RAX,RDI
CMOVC RSI,RDI
MOV RAX,qword ptr [RCX + 0x368]
SUB RAX,RSI
CMP qword ptr [RDX + 0x28],RAX
JBE 0x00149fbc
CALL 0x001a1ac2
MOV dword ptr [RAX],0x87
JMP 0x0014a027
LAB_00149fbc:
MOV EAX,0xfffffc
CMP RSI,RAX
CMOVC RAX,RSI
MOV qword ptr [R14],RAX
MOV RCX,qword ptr [RBX + 0x20]
ADD qword ptr [RCX + 0x28],RAX
MOV RAX,qword ptr [RBX]
INC qword ptr [RAX + 0xc0]
OR byte ptr [RBX + 0x625],0x1
JMP 0x0014a057
LAB_00149fe6:
MOV qword ptr [RDX],RAX
LEA RSI,[RBP + -0x70]
MOV dword ptr [RSI + 0x50],0x0
MOV dword ptr [RBX + 0x598],0x1
MOV EDX,dword ptr [RBX + 0x480]
MOV RAX,qword ptr [RBX]
MOV RCX,qword ptr [RAX + 0xc8]
MOV RDI,RBX
CALL 0x00148398
TEST AL,0x4
JNZ 0x0014a02e
MOV RDI,qword ptr [RBX]
MOV ESI,0x7f
CALL 0x0013fc8a
LAB_0014a027:
MOV EAX,0xffffffff
JMP 0x0014a059
LAB_0014a02e:
MOV RAX,qword ptr [RBP + -0x30]
MOV RCX,qword ptr [RBX]
MOV qword ptr [RCX + 0xc8],RAX
MOV RAX,qword ptr [RBX + 0x20]
DEC qword ptr [RAX + 0x8]
MOV RAX,qword ptr [RBP + -0x48]
MOV RCX,qword ptr [RBX + 0x20]
SUB qword ptr [RCX + 0x10],RAX
MOV RAX,qword ptr [RBP + -0x48]
MOV qword ptr [R14],RAX
LAB_0014a057:
XOR EAX,EAX
LAB_0014a059:
MOV RCX,qword ptr FS:[0x28]
CMP RCX,qword ptr [RBP + -0x18]
JNZ 0x0014a071
ADD RSP,0x60
POP RBX
POP R14
POP RBP
RET
LAB_0014a071:
CALL 0x00129250
|
int8 _ma_find_writepos(long *param_1,ulong param_2,long *param_3,ulong *param_4)
{
int4 *puVar1;
ulong uVar2;
int8 uVar3;
long lVar4;
ulong uVar5;
long in_FS_OFFSET;
int1 local_78 [40];
ulong local_50;
int8 local_38;
int4 local_28;
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
if ((*(long *)(*param_1 + 200) == -1) || (*(char *)((long)param_1 + 0x681) != '\0')) {
*param_3 = *(long *)(param_1[4] + 0x28);
lVar4 = (param_2 + 1) - (ulong)(param_2 < 0xffed);
uVar2 = *(ulong *)(*param_1 + 0x3b8);
uVar5 = lVar4 + 6U & 0xfffffffffffffffc;
if (lVar4 + 3U < uVar2) {
uVar5 = uVar2;
}
if (*(ulong *)(param_1[4] + 0x28) <= *(long *)(*param_1 + 0x368) - uVar5) {
uVar2 = 0xfffffc;
if (uVar5 < 0xfffffc) {
uVar2 = uVar5;
}
*param_4 = uVar2;
*(long *)(param_1[4] + 0x28) = *(long *)(param_1[4] + 0x28) + uVar2;
*(long *)(*param_1 + 0xc0) = *(long *)(*param_1 + 0xc0) + 1;
*(byte *)((long)param_1 + 0x625) = *(byte *)((long)param_1 + 0x625) | 1;
LAB_0014a057:
uVar3 = 0;
goto LAB_0014a059;
}
puVar1 = (int4 *)_my_thread_var();
*puVar1 = 0x87;
}
else {
*param_3 = *(long *)(*param_1 + 200);
local_28 = 0;
*(int4 *)(param_1 + 0xb3) = 1;
uVar2 = _ma_get_block_info(param_1,local_78,(int)param_1[0x90],*(int8 *)(*param_1 + 200));
if ((uVar2 & 4) != 0) {
*(int8 *)(*param_1 + 200) = local_38;
*(long *)(param_1[4] + 8) = *(long *)(param_1[4] + 8) + -1;
*(long *)(param_1[4] + 0x10) = *(long *)(param_1[4] + 0x10) - local_50;
*param_4 = local_50;
goto LAB_0014a057;
}
_ma_set_fatal_error_with_share(*param_1,0x7f);
}
uVar3 = 0xffffffff;
LAB_0014a059:
if (*(long *)(in_FS_OFFSET + 0x28) == local_20) {
return uVar3;
}
/* WARNING: Subroutine does not return */
__stack_chk_fail();
}
| |
38,084 | maria_status | eloqsql/storage/maria/ma_info.c | int maria_status(MARIA_HA *info, register MARIA_INFO *x, uint flag)
{
MY_STAT state;
MARIA_SHARE *share= info->s;
DBUG_ENTER("maria_status");
DBUG_PRINT("info", ("records: %lld", info->state->records));
x->recpos= info->cur_row.lastpos;
if (flag == HA_STATUS_POS)
DBUG_RETURN(0); /* Compatible with ISAM */
if (!(flag & HA_STATUS_NO_LOCK))
{
mysql_mutex_lock(&share->intern_lock);
_ma_readinfo(info,F_RDLCK,0);
fast_ma_writeinfo(info);
mysql_mutex_unlock(&share->intern_lock);
}
if (flag & HA_STATUS_VARIABLE)
{
/* If table is locked, give versioned number otherwise last commited */
if (info->lock_type == F_UNLCK)
x->records = share->state.state.records;
else
x->records = info->state->records;
x->deleted = share->state.state.del;
x->delete_length = share->state.state.empty;
x->data_file_length = share->state.state.data_file_length;
x->index_file_length= share->state.state.key_file_length;
x->keys = share->state.header.keys;
x->check_time = share->state.check_time;
x->mean_reclength = x->records ?
(ulong) ((x->data_file_length - x->delete_length) /x->records) :
(ulong) share->min_pack_length;
}
if (flag & HA_STATUS_ERRKEY)
{
x->errkey= info->errkey;
x->dup_key_pos= info->dup_key_pos;
}
if (flag & HA_STATUS_CONST)
{
x->reclength = share->base.reclength;
x->max_data_file_length=share->base.max_data_file_length;
x->max_index_file_length=info->s->base.max_key_file_length;
x->filenr = info->dfile.file;
x->options = share->options;
x->create_time=share->state.create_time;
x->reflength= maria_get_pointer_length(share->base.max_data_file_length,
maria_data_pointer_size);
x->record_offset= (info->s->data_file_type == STATIC_RECORD ?
share->base.pack_reclength: 0);
x->sortkey= -1; /* No clustering */
x->rec_per_key = share->state.rec_per_key_part;
x->key_map = share->state.key_map;
x->data_file_name = share->data_file_name.str;
x->index_file_name = share->index_file_name.str;
x->data_file_type = share->data_file_type;
}
if ((flag & HA_STATUS_TIME) && !my_fstat(info->dfile.file, &state, MYF(0)))
x->update_time=state.st_mtime;
else
x->update_time=0;
if (flag & HA_STATUS_AUTO)
{
x->auto_increment= share->state.auto_increment+1;
if (!x->auto_increment) /* This shouldn't happen */
x->auto_increment= ~(ulonglong) 0;
}
DBUG_RETURN(0);
} | O3 | c | maria_status:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x98, %rsp
movq (%rdi), %r13
movq 0x98(%rdi), %rax
movq %rax, 0x10(%rsi)
cmpl $0x1, %edx
je 0x3dbaa
movl %edx, %r14d
movq %rsi, %rbx
movq %rdi, %r15
testb $0x2, %r14b
jne 0x3d9f3
leaq 0x8f0(%r13), %r12
cmpq $0x0, 0x930(%r13)
jne 0x3dbbe
movq %r12, %rdi
callq 0x2b230
movq %r15, %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x44176
movq (%r15), %rax
cmpl $0x0, 0x7b8(%rax)
jne 0x3d9db
movq %r15, %rdi
xorl %esi, %esi
callq 0x4417e
movq 0x930(%r13), %rdi
testq %rdi, %rdi
jne 0x3dbd7
movq %r12, %rdi
callq 0x2b1f0
testb $0x10, %r14b
je 0x3da66
cmpl $0x2, 0x664(%r15)
jne 0x3da09
leaq 0x18(%r13), %rax
jmp 0x3da0d
movq 0x20(%r15), %rax
movq (%rax), %rcx
movq %rcx, (%rbx)
movq 0x20(%r13), %rax
movq %rax, 0x8(%rbx)
movq 0x28(%r13), %rdx
movq %rdx, 0x48(%rbx)
movq 0x40(%r13), %rax
movq %rax, 0x28(%rbx)
movq 0x38(%r13), %rsi
movq %rsi, 0x38(%rbx)
movzbl 0x12(%r13), %esi
movl %esi, 0xac(%rbx)
movq 0x160(%r13), %rsi
movq %rsi, 0x68(%rbx)
testq %rcx, %rcx
je 0x3da58
subq %rdx, %rax
xorl %edx, %edx
divq %rcx
jmp 0x3da5f
movq 0x728(%r13), %rax
movq %rax, 0x90(%rbx)
testb $0x20, %r14b
je 0x3da84
movl 0x660(%r15), %eax
movl %eax, 0xb8(%rbx)
movq 0x428(%r15), %rax
movq %rax, 0x20(%rbx)
testb $0x8, %r14b
je 0x3db5c
movq 0x398(%r13), %rax
movq %rax, 0x88(%rbx)
movq 0x368(%r13), %rax
movq %rax, 0x30(%rbx)
movq (%r15), %rax
movq 0x370(%rax), %rax
movq %rax, 0x40(%rbx)
movl 0x480(%r15), %eax
movl %eax, 0xc0(%rbx)
movl 0x720(%r13), %eax
movl %eax, 0xb0(%rbx)
movq 0x150(%r13), %rax
movq %rax, 0x60(%rbx)
movq 0x368(%r13), %rdi
leaq 0x379110(%rip), %rax # 0x3b6bf8
movl (%rax), %esi
callq 0x60853
movl %eax, 0xb4(%rbx)
movq (%r15), %rax
cmpl $0x0, 0x7d0(%rax)
je 0x3db05
xorl %eax, %eax
jmp 0x3db0c
movq 0x3a0(%r13), %rax
movq %rax, 0x78(%rbx)
movl $0xffffffff, 0xbc(%rbx) # imm = 0xFFFFFFFF
movq 0x100(%r13), %rax
movq %rax, 0x80(%rbx)
movq 0x140(%r13), %rax
movq %rax, 0x58(%rbx)
movq 0x5c0(%r13), %rax
movq %rax, 0x98(%rbx)
movq 0x5d0(%r13), %rax
movq %rax, 0xa0(%rbx)
movl 0x7d0(%r13), %eax
movl %eax, 0xa8(%rbx)
testb $0x4, %r14b
jne 0x3db67
xorl %r15d, %r15d
jmp 0x3db87
movl 0x480(%r15), %edi
xorl %r15d, %r15d
leaq -0xb8(%rbp), %rsi
xorl %edx, %edx
callq 0xc3863
testl %eax, %eax
jne 0x3db87
movq -0x60(%rbp), %r15
movq %r15, 0x70(%rbx)
testb $0x40, %r14b
je 0x3dbaa
movq 0xd8(%r13), %rax
incq %rax
movq $-0x1, %rcx
cmovneq %rax, %rcx
movq %rcx, 0x50(%rbx)
xorl %eax, %eax
addq $0x98, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0xc4694(%rip), %rsi # 0x102259
movq %r12, %rdi
movl $0x34, %edx
callq 0x324c0
jmp 0x3d9b9
leaq 0x37b02a(%rip), %rax # 0x3b8c08
movq (%rax), %rax
callq *0x160(%rax)
jmp 0x3d9eb
| maria_status:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 98h
mov r13, [rdi]
mov rax, [rdi+98h]
mov [rsi+10h], rax
cmp edx, 1
jz loc_3DBAA
mov r14d, edx
mov rbx, rsi
mov r15, rdi
test r14b, 2
jnz short loc_3D9F3
lea r12, [r13+8F0h]
cmp qword ptr [r13+930h], 0
jnz loc_3DBBE
mov rdi, r12
call _pthread_mutex_lock
loc_3D9B9:
mov rdi, r15
xor esi, esi
xor edx, edx
call _ma_readinfo
mov rax, [r15]
cmp dword ptr [rax+7B8h], 0
jnz short loc_3D9DB
mov rdi, r15
xor esi, esi
call _ma_writeinfo
loc_3D9DB:
mov rdi, [r13+930h]
test rdi, rdi
jnz loc_3DBD7
loc_3D9EB:
mov rdi, r12
call _pthread_mutex_unlock
loc_3D9F3:
test r14b, 10h
jz short loc_3DA66
cmp dword ptr [r15+664h], 2
jnz short loc_3DA09
lea rax, [r13+18h]
jmp short loc_3DA0D
loc_3DA09:
mov rax, [r15+20h]
loc_3DA0D:
mov rcx, [rax]
mov [rbx], rcx
mov rax, [r13+20h]
mov [rbx+8], rax
mov rdx, [r13+28h]
mov [rbx+48h], rdx
mov rax, [r13+40h]
mov [rbx+28h], rax
mov rsi, [r13+38h]
mov [rbx+38h], rsi
movzx esi, byte ptr [r13+12h]
mov [rbx+0ACh], esi
mov rsi, [r13+160h]
mov [rbx+68h], rsi
test rcx, rcx
jz short loc_3DA58
sub rax, rdx
xor edx, edx
div rcx
jmp short loc_3DA5F
loc_3DA58:
mov rax, [r13+728h]
loc_3DA5F:
mov [rbx+90h], rax
loc_3DA66:
test r14b, 20h
jz short loc_3DA84
mov eax, [r15+660h]
mov [rbx+0B8h], eax
mov rax, [r15+428h]
mov [rbx+20h], rax
loc_3DA84:
test r14b, 8
jz loc_3DB5C
mov rax, [r13+398h]
mov [rbx+88h], rax
mov rax, [r13+368h]
mov [rbx+30h], rax
mov rax, [r15]
mov rax, [rax+370h]
mov [rbx+40h], rax
mov eax, [r15+480h]
mov [rbx+0C0h], eax
mov eax, [r13+720h]
mov [rbx+0B0h], eax
mov rax, [r13+150h]
mov [rbx+60h], rax
mov rdi, [r13+368h]
lea rax, maria_data_pointer_size
mov esi, [rax]
call maria_get_pointer_length
mov [rbx+0B4h], eax
mov rax, [r15]
cmp dword ptr [rax+7D0h], 0
jz short loc_3DB05
xor eax, eax
jmp short loc_3DB0C
loc_3DB05:
mov rax, [r13+3A0h]
loc_3DB0C:
mov [rbx+78h], rax
mov dword ptr [rbx+0BCh], 0FFFFFFFFh
mov rax, [r13+100h]
mov [rbx+80h], rax
mov rax, [r13+140h]
mov [rbx+58h], rax
mov rax, [r13+5C0h]
mov [rbx+98h], rax
mov rax, [r13+5D0h]
mov [rbx+0A0h], rax
mov eax, [r13+7D0h]
mov [rbx+0A8h], eax
loc_3DB5C:
test r14b, 4
jnz short loc_3DB67
xor r15d, r15d
jmp short loc_3DB87
loc_3DB67:
mov edi, [r15+480h]
xor r15d, r15d
lea rsi, [rbp+var_B8]
xor edx, edx
call my_fstat
test eax, eax
jnz short loc_3DB87
mov r15, [rbp+var_60]
loc_3DB87:
mov [rbx+70h], r15
test r14b, 40h
jz short loc_3DBAA
mov rax, [r13+0D8h]
inc rax
mov rcx, 0FFFFFFFFFFFFFFFFh
cmovnz rcx, rax
mov [rbx+50h], rcx
loc_3DBAA:
xor eax, eax
add rsp, 98h
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
loc_3DBBE:
lea rsi, aWorkspaceLlm4b_33; "/workspace/llm4binary/github2025/eloqsq"...
mov rdi, r12
mov edx, 34h ; '4'
call psi_mutex_lock
jmp loc_3D9B9
loc_3DBD7:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp loc_3D9EB
| long long maria_status(_DWORD *a1, long long a2, int a3)
{
long long v3; // r13
char v4; // r14
unsigned long long *v5; // rax
unsigned long long v6; // rcx
long long v7; // rdx
long long v8; // rax
unsigned long long v9; // rax
long long v10; // rax
long long v11; // r15
long long v12; // rcx
_BYTE v14[88]; // [rsp+8h] [rbp-B8h] BYREF
long long v15; // [rsp+60h] [rbp-60h]
v3 = *(_QWORD *)a1;
*(_QWORD *)(a2 + 16) = *((_QWORD *)a1 + 19);
if ( a3 != 1 )
{
v4 = a3;
if ( (a3 & 2) == 0 )
{
if ( *(_QWORD *)(v3 + 2352) )
psi_mutex_lock(v3 + 2288, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_info.c", 0x34u);
else
pthread_mutex_lock(v3 + 2288);
ma_readinfo(a1, 0LL, 0LL);
if ( !*(_DWORD *)(*(_QWORD *)a1 + 1976LL) )
ma_writeinfo(a1, 0LL);
if ( *(_QWORD *)(v3 + 2352) )
PSI_server[44]();
pthread_mutex_unlock(v3 + 2288);
}
if ( (v4 & 0x10) != 0 )
{
if ( a1[409] == 2 )
v5 = (unsigned long long *)(v3 + 24);
else
v5 = (unsigned long long *)*((_QWORD *)a1 + 4);
v6 = *v5;
*(_QWORD *)a2 = *v5;
*(_QWORD *)(a2 + 8) = *(_QWORD *)(v3 + 32);
v7 = *(_QWORD *)(v3 + 40);
*(_QWORD *)(a2 + 72) = v7;
v8 = *(_QWORD *)(v3 + 64);
*(_QWORD *)(a2 + 40) = v8;
*(_QWORD *)(a2 + 56) = *(_QWORD *)(v3 + 56);
*(_DWORD *)(a2 + 172) = *(unsigned __int8 *)(v3 + 18);
*(_QWORD *)(a2 + 104) = *(_QWORD *)(v3 + 352);
if ( v6 )
v9 = (v8 - v7) / v6;
else
v9 = *(_QWORD *)(v3 + 1832);
*(_QWORD *)(a2 + 144) = v9;
}
if ( (v4 & 0x20) != 0 )
{
*(_DWORD *)(a2 + 184) = a1[408];
*(_QWORD *)(a2 + 32) = *((_QWORD *)a1 + 133);
}
if ( (v4 & 8) != 0 )
{
*(_QWORD *)(a2 + 136) = *(_QWORD *)(v3 + 920);
*(_QWORD *)(a2 + 48) = *(_QWORD *)(v3 + 872);
*(_QWORD *)(a2 + 64) = *(_QWORD *)(*(_QWORD *)a1 + 880LL);
*(_DWORD *)(a2 + 192) = a1[288];
*(_DWORD *)(a2 + 176) = *(_DWORD *)(v3 + 1824);
*(_QWORD *)(a2 + 96) = *(_QWORD *)(v3 + 336);
*(_DWORD *)(a2 + 180) = maria_get_pointer_length(*(_QWORD *)(v3 + 872), maria_data_pointer_size);
if ( *(_DWORD *)(*(_QWORD *)a1 + 2000LL) )
v10 = 0LL;
else
v10 = *(_QWORD *)(v3 + 928);
*(_QWORD *)(a2 + 120) = v10;
*(_DWORD *)(a2 + 188) = -1;
*(_QWORD *)(a2 + 128) = *(_QWORD *)(v3 + 256);
*(_QWORD *)(a2 + 88) = *(_QWORD *)(v3 + 320);
*(_QWORD *)(a2 + 152) = *(_QWORD *)(v3 + 1472);
*(_QWORD *)(a2 + 160) = *(_QWORD *)(v3 + 1488);
*(_DWORD *)(a2 + 168) = *(_DWORD *)(v3 + 2000);
}
if ( (v4 & 4) != 0 )
{
v11 = 0LL;
if ( !(unsigned int)my_fstat((unsigned int)a1[288], v14, 0LL) )
v11 = v15;
}
else
{
v11 = 0LL;
}
*(_QWORD *)(a2 + 112) = v11;
if ( (v4 & 0x40) != 0 )
{
v12 = -1LL;
if ( *(_QWORD *)(v3 + 216) != -1LL )
v12 = *(_QWORD *)(v3 + 216) + 1LL;
*(_QWORD *)(a2 + 80) = v12;
}
}
return 0LL;
}
| maria_status:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x98
MOV R13,qword ptr [RDI]
MOV RAX,qword ptr [RDI + 0x98]
MOV qword ptr [RSI + 0x10],RAX
CMP EDX,0x1
JZ 0x0013dbaa
MOV R14D,EDX
MOV RBX,RSI
MOV R15,RDI
TEST R14B,0x2
JNZ 0x0013d9f3
LEA R12,[R13 + 0x8f0]
CMP qword ptr [R13 + 0x930],0x0
JNZ 0x0013dbbe
MOV RDI,R12
CALL 0x0012b230
LAB_0013d9b9:
MOV RDI,R15
XOR ESI,ESI
XOR EDX,EDX
CALL 0x00144176
MOV RAX,qword ptr [R15]
CMP dword ptr [RAX + 0x7b8],0x0
JNZ 0x0013d9db
MOV RDI,R15
XOR ESI,ESI
CALL 0x0014417e
LAB_0013d9db:
MOV RDI,qword ptr [R13 + 0x930]
TEST RDI,RDI
JNZ 0x0013dbd7
LAB_0013d9eb:
MOV RDI,R12
CALL 0x0012b1f0
LAB_0013d9f3:
TEST R14B,0x10
JZ 0x0013da66
CMP dword ptr [R15 + 0x664],0x2
JNZ 0x0013da09
LEA RAX,[R13 + 0x18]
JMP 0x0013da0d
LAB_0013da09:
MOV RAX,qword ptr [R15 + 0x20]
LAB_0013da0d:
MOV RCX,qword ptr [RAX]
MOV qword ptr [RBX],RCX
MOV RAX,qword ptr [R13 + 0x20]
MOV qword ptr [RBX + 0x8],RAX
MOV RDX,qword ptr [R13 + 0x28]
MOV qword ptr [RBX + 0x48],RDX
MOV RAX,qword ptr [R13 + 0x40]
MOV qword ptr [RBX + 0x28],RAX
MOV RSI,qword ptr [R13 + 0x38]
MOV qword ptr [RBX + 0x38],RSI
MOVZX ESI,byte ptr [R13 + 0x12]
MOV dword ptr [RBX + 0xac],ESI
MOV RSI,qword ptr [R13 + 0x160]
MOV qword ptr [RBX + 0x68],RSI
TEST RCX,RCX
JZ 0x0013da58
SUB RAX,RDX
XOR EDX,EDX
DIV RCX
JMP 0x0013da5f
LAB_0013da58:
MOV RAX,qword ptr [R13 + 0x728]
LAB_0013da5f:
MOV qword ptr [RBX + 0x90],RAX
LAB_0013da66:
TEST R14B,0x20
JZ 0x0013da84
MOV EAX,dword ptr [R15 + 0x660]
MOV dword ptr [RBX + 0xb8],EAX
MOV RAX,qword ptr [R15 + 0x428]
MOV qword ptr [RBX + 0x20],RAX
LAB_0013da84:
TEST R14B,0x8
JZ 0x0013db5c
MOV RAX,qword ptr [R13 + 0x398]
MOV qword ptr [RBX + 0x88],RAX
MOV RAX,qword ptr [R13 + 0x368]
MOV qword ptr [RBX + 0x30],RAX
MOV RAX,qword ptr [R15]
MOV RAX,qword ptr [RAX + 0x370]
MOV qword ptr [RBX + 0x40],RAX
MOV EAX,dword ptr [R15 + 0x480]
MOV dword ptr [RBX + 0xc0],EAX
MOV EAX,dword ptr [R13 + 0x720]
MOV dword ptr [RBX + 0xb0],EAX
MOV RAX,qword ptr [R13 + 0x150]
MOV qword ptr [RBX + 0x60],RAX
MOV RDI,qword ptr [R13 + 0x368]
LEA RAX,[0x4b6bf8]
MOV ESI,dword ptr [RAX]
CALL 0x00160853
MOV dword ptr [RBX + 0xb4],EAX
MOV RAX,qword ptr [R15]
CMP dword ptr [RAX + 0x7d0],0x0
JZ 0x0013db05
XOR EAX,EAX
JMP 0x0013db0c
LAB_0013db05:
MOV RAX,qword ptr [R13 + 0x3a0]
LAB_0013db0c:
MOV qword ptr [RBX + 0x78],RAX
MOV dword ptr [RBX + 0xbc],0xffffffff
MOV RAX,qword ptr [R13 + 0x100]
MOV qword ptr [RBX + 0x80],RAX
MOV RAX,qword ptr [R13 + 0x140]
MOV qword ptr [RBX + 0x58],RAX
MOV RAX,qword ptr [R13 + 0x5c0]
MOV qword ptr [RBX + 0x98],RAX
MOV RAX,qword ptr [R13 + 0x5d0]
MOV qword ptr [RBX + 0xa0],RAX
MOV EAX,dword ptr [R13 + 0x7d0]
MOV dword ptr [RBX + 0xa8],EAX
LAB_0013db5c:
TEST R14B,0x4
JNZ 0x0013db67
XOR R15D,R15D
JMP 0x0013db87
LAB_0013db67:
MOV EDI,dword ptr [R15 + 0x480]
XOR R15D,R15D
LEA RSI,[RBP + -0xb8]
XOR EDX,EDX
CALL 0x001c3863
TEST EAX,EAX
JNZ 0x0013db87
MOV R15,qword ptr [RBP + -0x60]
LAB_0013db87:
MOV qword ptr [RBX + 0x70],R15
TEST R14B,0x40
JZ 0x0013dbaa
MOV RAX,qword ptr [R13 + 0xd8]
INC RAX
MOV RCX,-0x1
CMOVNZ RCX,RAX
MOV qword ptr [RBX + 0x50],RCX
LAB_0013dbaa:
XOR EAX,EAX
ADD RSP,0x98
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
LAB_0013dbbe:
LEA RSI,[0x202259]
MOV RDI,R12
MOV EDX,0x34
CALL 0x001324c0
JMP 0x0013d9b9
LAB_0013dbd7:
LEA RAX,[0x4b8c08]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x0013d9eb
|
int8 maria_status(long *param_1,ulong *param_2,uint param_3)
{
pthread_mutex_t *__mutex;
long lVar1;
int4 uVar2;
int iVar3;
ulong *puVar4;
ulong uVar5;
ulong uVar6;
ulong uVar7;
int1 local_c0 [88];
ulong local_68;
lVar1 = *param_1;
param_2[2] = param_1[0x13];
if (param_3 != 1) {
if ((param_3 & 2) == 0) {
__mutex = (pthread_mutex_t *)(lVar1 + 0x8f0);
if (*(long *)(lVar1 + 0x930) == 0) {
pthread_mutex_lock(__mutex);
}
else {
psi_mutex_lock(__mutex,"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_info.c",
0x34);
}
_ma_readinfo(param_1,0,0);
if (*(int *)(*param_1 + 0x7b8) == 0) {
_ma_writeinfo(param_1,0);
}
if (*(long *)(lVar1 + 0x930) != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock(__mutex);
}
if ((param_3 & 0x10) != 0) {
if (*(int *)((long)param_1 + 0x664) == 2) {
puVar4 = (ulong *)(lVar1 + 0x18);
}
else {
puVar4 = (ulong *)param_1[4];
}
uVar5 = *puVar4;
*param_2 = uVar5;
param_2[1] = *(ulong *)(lVar1 + 0x20);
uVar6 = *(ulong *)(lVar1 + 0x28);
param_2[9] = uVar6;
uVar7 = *(ulong *)(lVar1 + 0x40);
param_2[5] = uVar7;
param_2[7] = *(ulong *)(lVar1 + 0x38);
*(uint *)((long)param_2 + 0xac) = (uint)*(byte *)(lVar1 + 0x12);
param_2[0xd] = *(ulong *)(lVar1 + 0x160);
if (uVar5 == 0) {
uVar5 = *(ulong *)(lVar1 + 0x728);
}
else {
uVar5 = (uVar7 - uVar6) / uVar5;
}
param_2[0x12] = uVar5;
}
if ((param_3 & 0x20) != 0) {
*(int *)(param_2 + 0x17) = (int)param_1[0xcc];
param_2[4] = param_1[0x85];
}
if ((param_3 & 8) != 0) {
param_2[0x11] = *(ulong *)(lVar1 + 0x398);
param_2[6] = *(ulong *)(lVar1 + 0x368);
param_2[8] = *(ulong *)(*param_1 + 0x370);
*(int *)(param_2 + 0x18) = (int)param_1[0x90];
*(int4 *)(param_2 + 0x16) = *(int4 *)(lVar1 + 0x720);
param_2[0xc] = *(ulong *)(lVar1 + 0x150);
uVar2 = maria_get_pointer_length(*(int8 *)(lVar1 + 0x368),maria_data_pointer_size);
*(int4 *)((long)param_2 + 0xb4) = uVar2;
if (*(int *)(*param_1 + 2000) == 0) {
uVar6 = *(ulong *)(lVar1 + 0x3a0);
}
else {
uVar6 = 0;
}
param_2[0xf] = uVar6;
*(int4 *)((long)param_2 + 0xbc) = 0xffffffff;
param_2[0x10] = *(ulong *)(lVar1 + 0x100);
param_2[0xb] = *(ulong *)(lVar1 + 0x140);
param_2[0x13] = *(ulong *)(lVar1 + 0x5c0);
param_2[0x14] = *(ulong *)(lVar1 + 0x5d0);
*(int4 *)(param_2 + 0x15) = *(int4 *)(lVar1 + 2000);
}
if ((param_3 & 4) == 0) {
uVar6 = 0;
}
else {
iVar3 = my_fstat((int)param_1[0x90],local_c0,0);
uVar6 = 0;
if (iVar3 == 0) {
uVar6 = local_68;
}
}
param_2[0xe] = uVar6;
if ((param_3 & 0x40) != 0) {
uVar7 = *(long *)(lVar1 + 0xd8) + 1;
uVar6 = 0xffffffffffffffff;
if (uVar7 != 0) {
uVar6 = uVar7;
}
param_2[10] = uVar6;
}
}
return 0;
}
| |
38,085 | js_parse_expect_semi | bluesky950520[P]quickjs/quickjs.c | static int js_parse_expect_semi(JSParseState *s)
{
if (s->token.val != ';') {
/* automatic insertion of ';' */
if (s->token.val == TOK_EOF || s->token.val == '}' || s->got_lf) {
return 0;
}
return js_parse_error(s, "expecting '%c'", ';');
}
return next_token(s);
} | O0 | c | js_parse_expect_semi:
subq $0x18, %rsp
movq %rdi, 0x8(%rsp)
movq 0x8(%rsp), %rax
cmpl $0x3b, 0x20(%rax)
je 0xae59d
movq 0x8(%rsp), %rax
cmpl $-0x56, 0x20(%rax)
je 0xae575
movq 0x8(%rsp), %rax
cmpl $0x7d, 0x20(%rax)
je 0xae575
movq 0x8(%rsp), %rax
cmpl $0x0, 0x58(%rax)
je 0xae57f
movl $0x0, 0x14(%rsp)
jmp 0xae5ab
movq 0x8(%rsp), %rdi
leaq 0x61a40(%rip), %rsi # 0x10ffcb
movl $0x3b, %edx
movb $0x0, %al
callq 0x48690
movl %eax, 0x14(%rsp)
jmp 0xae5ab
movq 0x8(%rsp), %rdi
callq 0x9cfc0
movl %eax, 0x14(%rsp)
movl 0x14(%rsp), %eax
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
| js_parse_expect_semi:
sub rsp, 18h
mov [rsp+18h+var_10], rdi
mov rax, [rsp+18h+var_10]
cmp dword ptr [rax+20h], 3Bh ; ';'
jz short loc_AE59D
mov rax, [rsp+18h+var_10]
cmp dword ptr [rax+20h], 0FFFFFFAAh
jz short loc_AE575
mov rax, [rsp+18h+var_10]
cmp dword ptr [rax+20h], 7Dh ; '}'
jz short loc_AE575
mov rax, [rsp+18h+var_10]
cmp dword ptr [rax+58h], 0
jz short loc_AE57F
loc_AE575:
mov [rsp+18h+var_4], 0
jmp short loc_AE5AB
loc_AE57F:
mov rdi, [rsp+18h+var_10]
lea rsi, aExpectingC; "expecting '%c'"
mov edx, 3Bh ; ';'
mov al, 0
call js_parse_error
mov [rsp+18h+var_4], eax
jmp short loc_AE5AB
loc_AE59D:
mov rdi, [rsp+18h+var_10]
call next_token
mov [rsp+18h+var_4], eax
loc_AE5AB:
mov eax, [rsp+18h+var_4]
add rsp, 18h
retn
| long long js_parse_expect_semi(
long long a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
long long a10,
long long a11,
long long a12,
long long a13,
long long a14)
{
char v15; // [rsp+0h] [rbp-18h]
if ( *(_DWORD *)(a1 + 32) == 59 )
{
return (unsigned int)next_token(
(long long *)a1,
a2,
a3,
a4,
a5,
*(double *)a6.m128_u64,
*(double *)a7.m128_u64,
a8,
a9);
}
else if ( *(_DWORD *)(a1 + 32) == -86 || *(_DWORD *)(a1 + 32) == 125 || *(_DWORD *)(a1 + 88) )
{
return 0;
}
else
{
return (unsigned int)js_parse_error(
(_QWORD *)a1,
(long long)"expecting '%c'",
59LL,
a12,
a13,
a14,
a2,
a3,
a4,
a5,
a6,
a7,
a8,
a9,
v15);
}
}
| js_parse_expect_semi:
SUB RSP,0x18
MOV qword ptr [RSP + 0x8],RDI
MOV RAX,qword ptr [RSP + 0x8]
CMP dword ptr [RAX + 0x20],0x3b
JZ 0x001ae59d
MOV RAX,qword ptr [RSP + 0x8]
CMP dword ptr [RAX + 0x20],-0x56
JZ 0x001ae575
MOV RAX,qword ptr [RSP + 0x8]
CMP dword ptr [RAX + 0x20],0x7d
JZ 0x001ae575
MOV RAX,qword ptr [RSP + 0x8]
CMP dword ptr [RAX + 0x58],0x0
JZ 0x001ae57f
LAB_001ae575:
MOV dword ptr [RSP + 0x14],0x0
JMP 0x001ae5ab
LAB_001ae57f:
MOV RDI,qword ptr [RSP + 0x8]
LEA RSI,[0x20ffcb]
MOV EDX,0x3b
MOV AL,0x0
CALL 0x00148690
MOV dword ptr [RSP + 0x14],EAX
JMP 0x001ae5ab
LAB_001ae59d:
MOV RDI,qword ptr [RSP + 0x8]
CALL 0x0019cfc0
MOV dword ptr [RSP + 0x14],EAX
LAB_001ae5ab:
MOV EAX,dword ptr [RSP + 0x14]
ADD RSP,0x18
RET
|
int4 js_parse_expect_semi(long param_1)
{
int4 local_4;
if (*(int *)(param_1 + 0x20) == 0x3b) {
local_4 = next_token(param_1);
}
else if (((*(int *)(param_1 + 0x20) == -0x56) || (*(int *)(param_1 + 0x20) == 0x7d)) ||
(*(int *)(param_1 + 0x58) != 0)) {
local_4 = 0;
}
else {
local_4 = js_parse_error(param_1,"expecting \'%c\'",0x3b);
}
return local_4;
}
| |
38,086 | js_parse_expect_semi | bluesky950520[P]quickjs/quickjs.c | static int js_parse_expect_semi(JSParseState *s)
{
if (s->token.val != ';') {
/* automatic insertion of ';' */
if (s->token.val == TOK_EOF || s->token.val == '}' || s->got_lf) {
return 0;
}
return js_parse_error(s, "expecting '%c'", ';');
}
return next_token(s);
} | O2 | c | js_parse_expect_semi:
movl 0x20(%rdi), %ecx
xorl %eax, %eax
cmpl $-0x56, %ecx
je 0x5a26e
cmpl $0x3b, %ecx
je 0x4fa4e
cmpl $0x7d, %ecx
je 0x5a26e
cmpl $0x0, 0x58(%rdi)
je 0x5a26f
retq
pushq %rax
leaq 0x2dc2a(%rip), %rsi # 0x87ea1
pushq $0x3b
popq %rdx
xorl %eax, %eax
callq 0x28457
pushq $-0x1
popq %rax
addq $0x8, %rsp
retq
| js_parse_expect_semi:
mov ecx, [rdi+20h]
xor eax, eax
cmp ecx, 0FFFFFFAAh
jz short locret_5A26E
cmp ecx, 3Bh ; ';'
jz next_token
cmp ecx, 7Dh ; '}'
jz short locret_5A26E
cmp dword ptr [rdi+58h], 0
jz short loc_5A26F
locret_5A26E:
retn
loc_5A26F:
push rax
lea rsi, aExpectingC; "expecting '%c'"
push 3Bh ; ';'
pop rdx
xor eax, eax
call js_parse_error
push 0FFFFFFFFFFFFFFFFh
pop rax
add rsp, 8
retn
| long long js_parse_expect_semi(
long long a1,
long long a2,
long long a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
__m128 a10,
__m128 a11,
long long a12,
long long a13,
long long a14)
{
long long v14; // rcx
long long result; // rax
v14 = *(unsigned int *)(a1 + 32);
result = 0LL;
if ( (_DWORD)v14 != -86 )
{
if ( (_DWORD)v14 == 59 )
{
return next_token(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, v14, a13, a14);
}
else if ( (_DWORD)v14 != 125 && !*(_DWORD *)(a1 + 88) )
{
js_parse_error((long long *)a1, (long long)"expecting '%c'", 59LL, v14, a13, a14, a4, a5, a6, a7, a8, a9, a10, a11, 0);
return -1LL;
}
}
return result;
}
| js_parse_expect_semi:
MOV ECX,dword ptr [RDI + 0x20]
XOR EAX,EAX
CMP ECX,-0x56
JZ 0x0015a26e
CMP ECX,0x3b
JZ 0x0014fa4e
CMP ECX,0x7d
JZ 0x0015a26e
CMP dword ptr [RDI + 0x58],0x0
JZ 0x0015a26f
LAB_0015a26e:
RET
LAB_0015a26f:
PUSH RAX
LEA RSI,[0x187ea1]
PUSH 0x3b
POP RDX
XOR EAX,EAX
CALL 0x00128457
PUSH -0x1
POP RAX
ADD RSP,0x8
RET
|
int8 js_parse_expect_semi(long *param_1)
{
uint *puVar1;
byte bVar2;
uint uVar3;
int iVar4;
int4 uVar5;
byte *pbVar6;
byte *pbVar7;
byte bVar8;
int8 uVar9;
int8 uVar10;
uint uVar11;
char *pcVar12;
int1 auVar13 [16];
int1 auStack_3f0 [912];
int8 uStack_60;
byte *pbStack_58;
byte *pbStack_50;
byte *pbStack_48;
int4 uStack_3c;
byte *pbStack_38;
iVar4 = (int)param_1[4];
if (iVar4 != -0x56) {
if (iVar4 == 0x3b) {
if (auStack_3f0 < *(int1 **)(*(long *)(*param_1 + 0x18) + 0xe8)) {
uStack_60 = 0x14fa80;
JS_ThrowStackOverflow();
return 0xffffffffffffffff;
}
puVar1 = (uint *)(param_1 + 4);
uStack_60 = 0x14fa94;
free_token(param_1,puVar1);
pbVar7 = (byte *)param_1[0xe];
param_1[0xc] = (long)pbVar7;
*(int4 *)(param_1 + 0xb) = 0;
param_1[1] = *(long *)((long)param_1 + 0x24);
pcVar12 = "invalid UTF-8 sequence";
pbStack_38 = pbVar7;
LAB_0014faba:
*(long *)((long)param_1 + 0x24) = param_1[2];
param_1[6] = (long)pbVar7;
bVar8 = *pbVar7;
uVar3 = (uint)bVar8;
switch(uVar3) {
case 0:
goto switchD_0014fadb_caseD_0;
default:
if ((char)bVar8 < '\0') {
uStack_60 = 0x14fbe5;
uVar3 = utf8_decode(pbVar7,&pbStack_48);
if (pbStack_48 != pbStack_38 + 1) {
pbStack_38 = pbStack_48;
if ((uVar3 & 0xfffffffe) == 0x2028) {
iVar4 = (int)param_1[2];
pbVar7 = pbStack_48;
goto LAB_0014fb28;
}
uStack_60 = 0x14fcad;
iVar4 = lre_is_space(uVar3);
pbVar7 = pbStack_38;
if (iVar4 != 0) goto LAB_0014fae4;
uStack_60 = 0x15025a;
iVar4 = lre_js_is_ident_first(uVar3);
if (iVar4 != 0) goto LAB_0014fd27;
pcVar12 = "unexpected character";
}
goto LAB_0014fe01;
}
LAB_0014fe6b:
uVar11 = (uint)bVar8;
goto LAB_00150336;
case 9:
case 0xb:
case 0xc:
case 0x20:
pbStack_38 = pbVar7 + 1;
pbVar7 = pbStack_38;
goto LAB_0014fae4;
case 10:
goto switchD_0014fadb_caseD_a;
case 0xd:
if (pbVar7[1] == 10) {
pbVar7 = pbVar7 + 1;
}
switchD_0014fadb_caseD_a:
pbVar7 = pbVar7 + 1;
iVar4 = (int)param_1[2];
LAB_0014fb28:
param_1[0x10] = (long)(pbVar7 + -1);
param_1[0x11] = (long)pbVar7;
*(int4 *)(param_1 + 0xb) = 1;
*(int *)(param_1 + 2) = iVar4 + 1;
pbStack_38 = pbVar7;
goto LAB_0014faba;
case 0x21:
if (pbVar7[1] != 0x3d) {
uVar11 = 0x21;
goto LAB_00150336;
}
if (pbVar7[2] == 0x3d) {
pbStack_38 = pbVar7 + 3;
*puVar1 = 0xffffffa0;
}
else {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff9f;
}
goto LAB_00150340;
case 0x22:
case 0x27:
uStack_60 = 0x14fe49;
iVar4 = js_parse_string(param_1,uVar3,1,pbVar7 + 1,puVar1,&pbStack_38);
if (iVar4 != 0) goto LAB_0014fe0e;
goto LAB_00150340;
case 0x23:
pbStack_38 = pbVar7 + 1;
bVar8 = pbVar7[1];
uVar3 = (uint)bVar8;
pbStack_48 = pbVar7 + 2;
if (bVar8 == 0x5c) {
if (*pbStack_48 == 0x75) {
uStack_60 = 0x14ff18;
uVar3 = lre_parse_escape(&pbStack_48,1);
}
else {
uVar3 = 0x5c;
}
}
else if ((char)bVar8 < '\0') {
uStack_60 = 0x1501a3;
uVar3 = utf8_decode(pbStack_38,&pbStack_48);
if (pbStack_48 == pbStack_38 + 1) goto LAB_0014fe01;
}
uStack_60 = 0x1503a9;
iVar4 = lre_js_is_ident_first(uVar3);
if (iVar4 == 0) {
pcVar12 = "invalid first character of private name";
goto LAB_0014fe01;
}
pbStack_38 = pbStack_48;
uStack_60 = 0x1503cb;
iVar4 = parse_ident(param_1,&pbStack_38,&uStack_3c,uVar3,1);
if (iVar4 == 0) goto LAB_0014fe0e;
*(int *)(param_1 + 7) = iVar4;
*(int4 *)(param_1 + 4) = 0xffffffa9;
goto LAB_00150340;
case 0x24:
case 0x41:
case 0x42:
case 0x43:
case 0x44:
case 0x45:
case 0x46:
case 0x47:
case 0x48:
case 0x49:
case 0x4a:
case 0x4b:
case 0x4c:
case 0x4d:
case 0x4e:
case 0x4f:
case 0x50:
case 0x51:
case 0x52:
case 0x53:
case 0x54:
case 0x55:
case 0x56:
case 0x57:
case 0x58:
case 0x59:
case 0x5a:
case 0x5f:
case 0x61:
case 0x62:
case 99:
case 100:
case 0x65:
case 0x66:
case 0x67:
case 0x68:
case 0x69:
case 0x6a:
case 0x6b:
case 0x6c:
case 0x6d:
case 0x6e:
case 0x6f:
case 0x70:
case 0x71:
case 0x72:
case 0x73:
case 0x74:
case 0x75:
case 0x76:
case 0x77:
case 0x78:
case 0x79:
case 0x7a:
param_1[0x11] = (long)pbVar7;
pbStack_38 = pbVar7 + 1;
LAB_0014fd27:
uStack_3c = 0;
goto LAB_0014fd2b;
case 0x25:
if (pbVar7[1] != 0x3d) {
uVar11 = 0x25;
goto LAB_00150336;
}
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff87;
goto LAB_00150340;
case 0x26:
if (pbVar7[1] == 0x26) {
if (pbVar7[2] == 0x3d) {
pbStack_38 = pbVar7 + 3;
*puVar1 = 0xffffff91;
}
else {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffffa1;
}
goto LAB_00150340;
}
if (pbVar7[1] != 0x3d) {
uVar11 = 0x26;
goto LAB_00150336;
}
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff8d;
goto LAB_00150340;
case 0x2a:
if (pbVar7[1] == 0x2a) {
if (pbVar7[2] == 0x3d) {
pbStack_38 = pbVar7 + 3;
*puVar1 = 0xffffff90;
}
else {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffffa3;
}
goto LAB_00150340;
}
if (pbVar7[1] != 0x3d) {
uVar11 = 0x2a;
goto LAB_00150336;
}
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff85;
goto LAB_00150340;
case 0x2b:
if (pbVar7[1] == 0x2b) {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff95;
goto LAB_00150340;
}
if (pbVar7[1] != 0x3d) {
uVar11 = 0x2b;
goto LAB_00150336;
}
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff88;
goto LAB_00150340;
case 0x2d:
if (pbVar7[1] != 0x2d) {
if (pbVar7[1] != 0x3d) goto LAB_0014fe6b;
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff89;
goto LAB_00150340;
}
if (((*(int *)((long)param_1 + 0x9c) == 0) || (pbVar7[2] != 0x3e)) ||
(((int)param_1[0xb] == 0 && (param_1[0xc] != param_1[0xd])))) {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff94;
goto LAB_00150340;
}
break;
case 0x2e:
if (pbVar7[1] == 0x2e) {
if (pbVar7[2] == 0x2e) {
pbStack_38 = pbVar7 + 3;
*puVar1 = 0xffffffa5;
goto LAB_00150340;
}
}
else if ((byte)(pbVar7[1] - 0x30) < 10) {
uStack_60 = 0x44;
uVar10 = uStack_60;
goto LAB_0014fd70;
}
uVar11 = 0x2e;
goto LAB_00150336;
case 0x2f:
bVar8 = pbVar7[1];
if (bVar8 == 0x2a) {
pbStack_38 = pbVar7 + 2;
LAB_0014fc21:
bVar8 = *pbStack_38;
if (bVar8 == 0x2a) {
if (pbStack_38[1] == 0x2f) goto LAB_0014fcbe;
}
else {
if (bVar8 == 10) {
*(int *)(param_1 + 2) = (int)param_1[2] + 1;
*(int4 *)(param_1 + 0xb) = 1;
param_1[0x10] = (long)pbStack_38;
param_1[0x11] = (long)(pbStack_38 + 1);
pbStack_38 = pbStack_38 + 1;
goto LAB_0014fc21;
}
if (bVar8 == 0xd) {
*(int4 *)(param_1 + 0xb) = 1;
}
else {
if (bVar8 == 0) {
if (pbStack_38 < (byte *)param_1[0xf]) goto LAB_0014fc79;
pcVar12 = "unexpected end of comment";
goto LAB_0014fe01;
}
if ((char)bVar8 < '\0') {
uStack_60 = 0x14fc92;
uVar3 = utf8_decode(pbStack_38,&pbStack_38);
if ((uVar3 & 0xfffffffe) == 0x2028) {
*(int4 *)(param_1 + 0xb) = 1;
}
goto LAB_0014fc21;
}
}
}
LAB_0014fc79:
pbStack_38 = pbStack_38 + 1;
goto LAB_0014fc21;
}
if (bVar8 != 0x2f) {
if (bVar8 == 0x3d) {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff86;
}
else {
pbStack_38 = pbVar7 + 1;
*puVar1 = 0x2f;
}
goto LAB_00150340;
}
pbVar7 = pbVar7 + 2;
pbStack_38 = pbVar7;
break;
case 0x30:
if (pbVar7[1] - 0x3a < 0xfffffff6) {
if (pbVar7[1] != 0x5f) {
uVar10 = 0xf4;
goto LAB_0014fd70;
}
pcVar12 = "Numeric separator can not be used after leading 0";
goto LAB_0014fe01;
}
if (*(short *)(param_1[0x12] + 0x84) < 0) {
pcVar12 = "Octal literals are not allowed in strict mode";
goto LAB_0014fe01;
}
uVar9 = 8;
bVar8 = 0x30;
pbVar6 = pbVar7;
while (pbVar6 = pbVar6 + 1, 0xfffffff5 < bVar8 - 0x3a) {
if ((bVar8 & 0xfe) == 0x38) {
uVar9 = 10;
}
bVar8 = *pbVar6;
}
uVar10 = 0;
pbStack_38 = pbVar7;
LAB_0014fd74:
uStack_60 = 0x14fd91;
pbStack_58 = pbVar7;
auVar13 = js_atof(*param_1,pbVar7,param_1[0xf] - (long)pbVar7,&pbStack_58,uVar9,uVar10);
pbStack_38 = pbStack_58;
if (auVar13._8_4_ != 6) {
if ((auVar13._0_8_ & 0x7fffffffffffffff) < 0x7ff0000000000001 || auVar13._8_8_ != 7) {
uStack_60 = 0x14fdd4;
uVar5 = utf8_decode(pbStack_58,&pbStack_48);
uStack_60 = 0x14fddb;
iVar4 = lre_js_is_ident_next(uVar5);
if (iVar4 == 0) {
*(int4 *)(param_1 + 4) = 0xffffff80;
*(int1 (*) [16])(param_1 + 7) = auVar13;
goto LAB_00150340;
}
}
uStack_60 = 0x14fdf1;
JS_FreeValue(*param_1,auVar13._0_8_,auVar13._8_8_);
pcVar12 = "invalid number literal";
LAB_0014fe01:
uStack_60 = 0x14fe0e;
js_parse_error(param_1,pcVar12);
}
LAB_0014fe0e:
*puVar1 = 0xffffffa8;
return 0xffffffffffffffff;
case 0x31:
case 0x32:
case 0x33:
case 0x34:
case 0x35:
case 0x36:
case 0x37:
case 0x38:
case 0x39:
uVar10 = 0xc4;
LAB_0014fd70:
uVar9 = 10;
goto LAB_0014fd74;
case 0x3c:
bVar2 = pbVar7[1];
if (bVar2 == 0x3c) {
if (pbVar7[2] == 0x3d) {
pbStack_38 = pbVar7 + 3;
*puVar1 = 0xffffff8a;
}
else {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff96;
}
goto LAB_00150340;
}
if (bVar2 == 0x3d) {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff9a;
goto LAB_00150340;
}
if ((((bVar2 != 0x21) || (*(int *)((long)param_1 + 0x9c) == 0)) || (pbVar7[2] != 0x2d)) ||
(pbVar7[3] != 0x2d)) goto LAB_0014fe6b;
break;
case 0x3d:
if (pbVar7[1] == 0x3e) {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffffa4;
goto LAB_00150340;
}
if (pbVar7[1] != 0x3d) {
uVar11 = 0x3d;
goto LAB_00150336;
}
if (pbVar7[2] == 0x3d) {
pbStack_38 = pbVar7 + 3;
*puVar1 = 0xffffff9e;
}
else {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff9d;
}
goto LAB_00150340;
case 0x3e:
if (pbVar7[1] == 0x3e) {
if (pbVar7[2] == 0x3d) {
pbStack_38 = pbVar7 + 3;
*puVar1 = 0xffffff8b;
}
else if (pbVar7[2] == 0x3e) {
if (pbVar7[3] == 0x3d) {
pbStack_38 = pbVar7 + 4;
*puVar1 = 0xffffff8c;
}
else {
pbStack_38 = pbVar7 + 3;
*puVar1 = 0xffffff98;
}
}
else {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff97;
}
goto LAB_00150340;
}
if (pbVar7[1] != 0x3d) {
uVar11 = 0x3e;
goto LAB_00150336;
}
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff9c;
goto LAB_00150340;
case 0x3f:
uVar11 = 0x3f;
if (pbVar7[1] == 0x2e) {
if ((byte)(pbVar7[2] - 0x30) < 10) goto LAB_00150336;
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffffa7;
}
else {
if (pbVar7[1] != 0x3f) goto LAB_00150336;
if (pbVar7[2] == 0x3d) {
pbStack_38 = pbVar7 + 3;
*puVar1 = 0xffffff93;
}
else {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffffa6;
}
}
goto LAB_00150340;
case 0x5c:
uVar11 = 0x5c;
if (pbVar7[1] != 0x75) goto LAB_00150336;
pbStack_50 = pbVar7 + 1;
uStack_60 = 0x14fff3;
uVar3 = lre_parse_escape(&pbStack_50,1);
pbVar7 = pbStack_38;
if ((int)uVar3 < 0) goto LAB_00150336;
uStack_60 = 0x150005;
iVar4 = lre_js_is_ident_first(uVar3);
pbVar7 = pbStack_38;
if (iVar4 == 0) goto LAB_00150336;
pbStack_38 = pbStack_50;
uStack_3c = 1;
LAB_0014fd2b:
uStack_60 = 0x14fd41;
iVar4 = parse_ident(param_1,&pbStack_38,&uStack_3c,uVar3,0);
if (iVar4 == 0) goto LAB_0014fe0e;
*(int *)(param_1 + 7) = iVar4;
*(int4 *)((long)param_1 + 0x3c) = uStack_3c;
*(int4 *)(param_1 + 8) = 0;
*(int4 *)(param_1 + 4) = 0xffffff83;
uStack_60 = 0x14fd65;
update_token_ident(param_1);
goto LAB_00150340;
case 0x5e:
if (pbVar7[1] != 0x3d) {
uVar11 = 0x5e;
goto LAB_00150336;
}
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff8e;
goto LAB_00150340;
case 0x60:
uStack_60 = 0x14fe81;
iVar4 = js_parse_template_part(param_1,pbVar7 + 1);
if (iVar4 != 0) goto LAB_0014fe0e;
pbStack_38 = (byte *)param_1[0xe];
goto LAB_00150340;
case 0x7c:
if (pbVar7[1] == 0x7c) {
if (pbVar7[2] == 0x3d) {
pbStack_38 = pbVar7 + 3;
*puVar1 = 0xffffff92;
}
else {
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffffa2;
}
goto LAB_00150340;
}
if (pbVar7[1] != 0x3d) {
uVar11 = 0x7c;
goto LAB_00150336;
}
pbStack_38 = pbVar7 + 2;
*puVar1 = 0xffffff8f;
goto LAB_00150340;
}
do {
while (bVar8 = *pbVar7, bVar8 == 0) {
if ((byte *)param_1[0xf] <= pbVar7) goto LAB_0014fae4;
LAB_0014fd10:
pbVar7 = pbVar7 + 1;
pbStack_38 = pbVar7;
}
if ((bVar8 == 10) || (bVar8 == 0xd)) break;
if (-1 < (char)bVar8) goto LAB_0014fd10;
uStack_60 = 0x14fcf3;
uVar3 = utf8_decode(pbVar7,&pbStack_38);
pbVar7 = pbStack_38;
} while ((uVar3 & 0xfffffffe) != 0x2028);
goto LAB_0014fae4;
}
if ((iVar4 != 0x7d) && ((int)param_1[0xb] == 0)) {
js_parse_error(param_1,"expecting \'%c\'",0x3b);
return 0xffffffffffffffff;
}
}
return 0;
LAB_0014fcbe:
pbStack_38 = pbStack_38 + 2;
pbVar7 = pbStack_38;
LAB_0014fae4:
param_1[0x11] = (long)pbVar7;
goto LAB_0014faba;
switchD_0014fadb_caseD_0:
uVar11 = 0;
if (pbVar7 < (byte *)param_1[0xf]) {
LAB_00150336:
*puVar1 = uVar11;
pbStack_38 = pbVar7 + 1;
}
else {
*puVar1 = 0xffffffaa;
}
LAB_00150340:
iVar4 = (int)param_1[0x11] - (int)param_1[0x10];
if (iVar4 < 2) {
iVar4 = 1;
}
*(int *)(param_1 + 5) = iVar4;
param_1[0xe] = (long)pbStack_38;
return 0;
}
| |
38,087 | my_readlink | eloqsql/mysys/my_symlink.c | int my_readlink(char *to, const char *filename, myf MyFlags)
{
#ifndef HAVE_READLINK
strmov(to,filename);
return 1;
#else
int result=0;
int length;
DBUG_ENTER("my_readlink");
if ((length=readlink(filename, to, FN_REFLEN-1)) < 0)
{
/* Don't give an error if this wasn't a symlink */
if ((my_errno=errno) == EINVAL)
{
result= 1;
strmov(to,filename);
}
else
{
if (MyFlags & MY_WME)
my_error(EE_CANT_READLINK, MYF(0), filename, errno);
result= -1;
}
}
else
to[length]=0;
DBUG_PRINT("exit" ,("result: %d", result));
DBUG_RETURN(result);
#endif /* HAVE_READLINK */
} | O3 | c | my_readlink:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r15
movq %rsi, %rbx
movq %rdi, %r14
movl $0x1ff, %edx # imm = 0x1FF
movq %rsi, %rdi
movq %r14, %rsi
callq 0x372a0
testl %eax, %eax
js 0x6ba92
andl $0x7fffffff, %eax # imm = 0x7FFFFFFF
movb $0x0, (%r14,%rax)
xorl %r14d, %r14d
jmp 0x6badf
callq 0x37a20
movq %rax, %r12
movl (%rax), %r13d
callq 0x6c47a
movl %r13d, (%rax)
cmpl $0x16, %r13d
jne 0x6babe
movq %r14, %rdi
movq %rbx, %rsi
callq 0x37420
movl $0x1, %r14d
jmp 0x6badf
movl $0xffffffff, %r14d # imm = 0xFFFFFFFF
testb $0x10, %r15b
je 0x6badf
movl (%r12), %ecx
movl $0x18, %edi
xorl %esi, %esi
movq %rbx, %rdx
xorl %eax, %eax
callq 0x677ff
movl %r14d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
| my_readlink:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
push rax
mov r15, rdx
mov rbx, rsi
mov r14, rdi
mov edx, 1FFh
mov rdi, rsi
mov rsi, r14
call _readlink
test eax, eax
js short loc_6BA92
and eax, 7FFFFFFFh
mov byte ptr [r14+rax], 0
xor r14d, r14d
jmp short loc_6BADF
loc_6BA92:
call ___errno_location
mov r12, rax
mov r13d, [rax]
call _my_thread_var
mov [rax], r13d
cmp r13d, 16h
jnz short loc_6BABE
mov rdi, r14
mov rsi, rbx
call _strcpy
mov r14d, 1
jmp short loc_6BADF
loc_6BABE:
mov r14d, 0FFFFFFFFh
test r15b, 10h
jz short loc_6BADF
mov ecx, [r12]
mov edi, 18h
xor esi, esi
mov rdx, rbx
xor eax, eax
call my_error
loc_6BADF:
mov eax, r14d
add rsp, 8
pop rbx
pop r12
pop r13
pop r14
pop r15
pop rbp
retn
| long long my_readlink(long long a1, long long a2, char a3)
{
int v4; // eax
unsigned int v5; // r14d
unsigned int *v6; // r12
unsigned int v7; // r13d
v4 = readlink(a2, a1, 511LL);
if ( v4 < 0 )
{
v6 = (unsigned int *)__errno_location(a2);
v7 = *v6;
*(_DWORD *)my_thread_var(a2) = v7;
if ( v7 == 22 )
{
strcpy(a1, a2);
return 1;
}
else
{
v5 = -1;
if ( (a3 & 0x10) != 0 )
my_error(0x18u, 0LL, a2, *v6);
}
}
else
{
*(_BYTE *)(a1 + (v4 & 0x7FFFFFFF)) = 0;
return 0;
}
return v5;
}
| my_readlink:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
PUSH RAX
MOV R15,RDX
MOV RBX,RSI
MOV R14,RDI
MOV EDX,0x1ff
MOV RDI,RSI
MOV RSI,R14
CALL 0x001372a0
TEST EAX,EAX
JS 0x0016ba92
AND EAX,0x7fffffff
MOV byte ptr [R14 + RAX*0x1],0x0
XOR R14D,R14D
JMP 0x0016badf
LAB_0016ba92:
CALL 0x00137a20
MOV R12,RAX
MOV R13D,dword ptr [RAX]
CALL 0x0016c47a
MOV dword ptr [RAX],R13D
CMP R13D,0x16
JNZ 0x0016babe
MOV RDI,R14
MOV RSI,RBX
CALL 0x00137420
MOV R14D,0x1
JMP 0x0016badf
LAB_0016babe:
MOV R14D,0xffffffff
TEST R15B,0x10
JZ 0x0016badf
MOV ECX,dword ptr [R12]
MOV EDI,0x18
XOR ESI,ESI
MOV RDX,RBX
XOR EAX,EAX
CALL 0x001677ff
LAB_0016badf:
MOV EAX,R14D
ADD RSP,0x8
POP RBX
POP R12
POP R13
POP R14
POP R15
POP RBP
RET
|
int8 my_readlink(char *param_1,char *param_2,ulong param_3)
{
int iVar1;
ssize_t sVar2;
int *piVar3;
int *piVar4;
int8 uVar5;
sVar2 = readlink(param_2,param_1,0x1ff);
if ((int)(uint)sVar2 < 0) {
piVar3 = __errno_location();
iVar1 = *piVar3;
piVar4 = (int *)_my_thread_var();
*piVar4 = iVar1;
if (iVar1 == 0x16) {
strcpy(param_1,param_2);
uVar5 = 1;
}
else {
uVar5 = 0xffffffff;
if ((param_3 & 0x10) != 0) {
my_error(0x18,0,param_2,*piVar3);
}
}
}
else {
param_1[(uint)sVar2 & 0x7fffffff] = '\0';
uVar5 = 0;
}
return uVar5;
}
| |
38,088 | translog_create_new_file | eloqsql/storage/maria/ma_loghandler.c | static my_bool translog_create_new_file()
{
TRANSLOG_FILE *file= (TRANSLOG_FILE*)my_malloc(PSI_INSTRUMENT_ME, sizeof(TRANSLOG_FILE),
MYF(0));
TRANSLOG_FILE *old= get_current_logfile();
uint32 file_no= LSN_FILE_NO(log_descriptor.horizon);
DBUG_ENTER("translog_create_new_file");
if (file == NULL)
goto error;
/*
Writes max_lsn to the file header before finishing it (there is no need
to lock file header buffer because it is still unfinished file, so only
one thread can finish the file and nobody interested of LSN of current
(unfinished) file, because no one can purge it).
*/
if (translog_max_lsn_to_header(old->handler.file, log_descriptor.max_lsn))
goto error;
mysql_rwlock_wrlock(&log_descriptor.open_files_lock);
DBUG_ASSERT(log_descriptor.max_file - log_descriptor.min_file + 1 ==
log_descriptor.open_files.elements);
DBUG_ASSERT(file_no == log_descriptor.max_file + 1);
if (allocate_dynamic(&log_descriptor.open_files,
log_descriptor.max_file - log_descriptor.min_file + 2))
goto error_lock;
/* this call just expand the array */
if (insert_dynamic(&log_descriptor.open_files, (uchar*)&file))
goto error_lock;
if ((file->handler.file= create_logfile_by_number_no_cache(file_no)) == -1)
goto error_lock;
translog_file_init(file, file_no, 0);
log_descriptor.max_file++;
{
char *start= (char*) dynamic_element(&log_descriptor.open_files, 0,
TRANSLOG_FILE**);
memmove(start + sizeof(TRANSLOG_FILE*), start,
sizeof(TRANSLOG_FILE*) *
(log_descriptor.max_file - log_descriptor.min_file + 1 - 1));
}
/* can't fail we because we expanded array */
set_dynamic(&log_descriptor.open_files, (uchar*)&file, 0);
DBUG_ASSERT(log_descriptor.max_file - log_descriptor.min_file + 1 ==
log_descriptor.open_files.elements);
mysql_rwlock_unlock(&log_descriptor.open_files_lock);
DBUG_PRINT("info", ("file_no: %lu", (ulong)file_no));
if (translog_write_file_header())
goto error;
if (ma_control_file_write_and_force(last_checkpoint_lsn, file_no,
max_trid_in_control_file,
recovery_failures))
goto error;
DBUG_RETURN(0);
error_lock:
mysql_rwlock_unlock(&log_descriptor.open_files_lock);
error:
translog_stop_writing();
my_free(file);
DBUG_RETURN(1);
} | O0 | c | translog_create_new_file:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
xorl %edi, %edi
movl $0x58, %esi
xorl %eax, %eax
movl %eax, %edx
callq 0xf3820
movq %rax, -0x10(%rbp)
callq 0x3ac90
movq %rax, -0x18(%rbp)
movq 0xc424fc(%rip), %rax # 0xc798b8
sarq $0x20, %rax
movl %eax, -0x1c(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0x373cf
jmp 0x3754a
movq -0x18(%rbp), %rax
movl 0x18(%rax), %edi
movq 0xc42523(%rip), %rsi # 0xc79900
callq 0x37570
cmpb $0x0, %al
je 0x373eb
jmp 0x3754a
leaq 0x44187e(%rip), %rdi # 0x478c70
addq $0x258, %rdi # imm = 0x258
leaq 0x11a282(%rip), %rsi # 0x151682
movl $0x687, %edx # imm = 0x687
callq 0x356f0
jmp 0x3740c
jmp 0x3740e
jmp 0x37410
movl 0x441aaa(%rip), %esi # 0x478ec0
subl 0x441aa8(%rip), %esi # 0x478ec4
addl $0x2, %esi
leaq 0x44184a(%rip), %rdi # 0x478c70
addq $0x228, %rdi # imm = 0x228
callq 0xda990
cmpb $0x0, %al
je 0x3743b
jmp 0x37537
leaq 0x44182e(%rip), %rdi # 0x478c70
addq $0x228, %rdi # imm = 0x228
leaq -0x10(%rbp), %rsi
callq 0xda680
cmpb $0x0, %al
je 0x3745b
jmp 0x37537
movl -0x1c(%rbp), %edi
callq 0x30860
movq -0x10(%rbp), %rcx
movl %eax, 0x18(%rcx)
cmpl $-0x1, %eax
jne 0x37474
jmp 0x37537
movq -0x10(%rbp), %rdi
movl -0x1c(%rbp), %esi
xorl %edx, %edx
callq 0x2ff80
movl 0x441a38(%rip), %eax # 0x478ec0
addl $0x1, %eax
movl %eax, 0x441a2f(%rip) # 0x478ec0
movq 0x441a00(%rip), %rax # 0x478e98
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rdi
addq $0x8, %rdi
movq -0x28(%rbp), %rsi
movl 0x441a12(%rip), %eax # 0x478ec0
subl 0x441a10(%rip), %eax # 0x478ec4
addl $0x1, %eax
subl $0x1, %eax
movl %eax, %eax
movl %eax, %edx
shlq $0x3, %rdx
callq 0x2a120
leaq 0x4417a2(%rip), %rdi # 0x478c70
addq $0x228, %rdi # imm = 0x228
leaq -0x10(%rbp), %rsi
xorl %edx, %edx
callq 0xda8d0
jmp 0x374e2
leaq 0x441787(%rip), %rdi # 0x478c70
addq $0x258, %rdi # imm = 0x258
callq 0x35760
jmp 0x374f7
callq 0x370d0
cmpb $0x0, %al
je 0x37502
jmp 0x3754a
leaq 0x440507(%rip), %rax # 0x477a10
movq (%rax), %rdi
movl -0x1c(%rbp), %esi
leaq 0x44050a(%rip), %rax # 0x477a20
movq (%rax), %rdx
leaq 0x440508(%rip), %rax # 0x477a28
movzbl (%rax), %ecx
callq 0x2c6a0
cmpl $0x0, %eax
je 0x3752f
jmp 0x3754a
jmp 0x37531
movb $0x0, -0x1(%rbp)
jmp 0x3755c
leaq 0x441732(%rip), %rdi # 0x478c70
addq $0x258, %rdi # imm = 0x258
callq 0x35760
callq 0x2d640
movq -0x10(%rbp), %rdi
callq 0xf3ba0
movb $0x1, -0x1(%rbp)
movb -0x1(%rbp), %al
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| translog_create_new_file:
push rbp
mov rbp, rsp
sub rsp, 30h
xor edi, edi
mov esi, 58h ; 'X'
xor eax, eax
mov edx, eax
call my_malloc
mov [rbp+var_10], rax
call get_current_logfile
mov [rbp+var_18], rax
mov rax, cs:qword_C798B8
sar rax, 20h
mov [rbp+var_1C], eax
cmp [rbp+var_10], 0
jnz short loc_373CF
jmp loc_3754A
loc_373CF:
mov rax, [rbp+var_18]
mov edi, [rax+18h]
mov rsi, cs:qword_C79900
call translog_max_lsn_to_header
cmp al, 0
jz short loc_373EB
jmp loc_3754A
loc_373EB:
lea rdi, log_descriptor
add rdi, 258h
lea rsi, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"...
mov edx, 687h
call inline_mysql_rwlock_wrlock
jmp short $+2
loc_3740C:
jmp short $+2
loc_3740E:
jmp short $+2
loc_37410:
mov esi, cs:dword_478EC0
sub esi, cs:dword_478EC4
add esi, 2
lea rdi, log_descriptor
add rdi, 228h
call allocate_dynamic
cmp al, 0
jz short loc_3743B
jmp loc_37537
loc_3743B:
lea rdi, log_descriptor
add rdi, 228h
lea rsi, [rbp+var_10]
call insert_dynamic
cmp al, 0
jz short loc_3745B
jmp loc_37537
loc_3745B:
mov edi, [rbp+var_1C]
call create_logfile_by_number_no_cache
mov rcx, [rbp+var_10]
mov [rcx+18h], eax
cmp eax, 0FFFFFFFFh
jnz short loc_37474
jmp loc_37537
loc_37474:
mov rdi, [rbp+var_10]
mov esi, [rbp+var_1C]
xor edx, edx
call translog_file_init
mov eax, cs:dword_478EC0
add eax, 1
mov cs:dword_478EC0, eax
mov rax, cs:qword_478E98
mov [rbp+var_28], rax
mov rdi, [rbp+var_28]
add rdi, 8
mov rsi, [rbp+var_28]
mov eax, cs:dword_478EC0
sub eax, cs:dword_478EC4
add eax, 1
sub eax, 1
mov eax, eax
mov edx, eax
shl rdx, 3
call _memmove
lea rdi, log_descriptor
add rdi, 228h
lea rsi, [rbp+var_10]
xor edx, edx
call set_dynamic
jmp short $+2
loc_374E2:
lea rdi, log_descriptor
add rdi, 258h
call inline_mysql_rwlock_unlock
jmp short $+2
loc_374F7:
call translog_write_file_header
cmp al, 0
jz short loc_37502
jmp short loc_3754A
loc_37502:
lea rax, last_checkpoint_lsn
mov rdi, [rax]
mov esi, [rbp+var_1C]
lea rax, max_trid_in_control_file
mov rdx, [rax]
lea rax, recovery_failures
movzx ecx, byte ptr [rax]
call ma_control_file_write_and_force
cmp eax, 0
jz short loc_3752F
jmp short loc_3754A
loc_3752F:
jmp short $+2
loc_37531:
mov [rbp+var_1], 0
jmp short loc_3755C
loc_37537:
lea rdi, log_descriptor
add rdi, 258h
call inline_mysql_rwlock_unlock
loc_3754A:
call translog_stop_writing
mov rdi, [rbp+var_10]
call my_free
mov [rbp+var_1], 1
loc_3755C:
mov al, [rbp+var_1]
add rsp, 30h
pop rbp
retn
| char translog_create_new_file()
{
long long v0; // rdx
long long v1; // rcx
int v2; // r8d
int v3; // r9d
int logfile_by_number_no_cache; // eax
long long v5; // rdx
unsigned int v7; // [rsp+14h] [rbp-1Ch]
long long current_logfile; // [rsp+18h] [rbp-18h]
long long v9; // [rsp+20h] [rbp-10h] BYREF
v9 = my_malloc(0LL, 88LL, 0LL);
current_logfile = get_current_logfile();
v7 = HIDWORD(qword_C798B8);
if ( !v9 || (unsigned __int8)translog_max_lsn_to_header(*(unsigned int *)(current_logfile + 24), qword_C79900) )
goto LABEL_10;
inline_mysql_rwlock_wrlock(
(long long)&log_descriptor[75],
(long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_loghandler.c",
0x687u);
if ( (unsigned __int8)allocate_dynamic(&log_descriptor[69], (unsigned int)(dword_478EC0 - dword_478EC4 + 2))
|| (unsigned __int8)insert_dynamic(&log_descriptor[69], &v9)
|| (logfile_by_number_no_cache = create_logfile_by_number_no_cache(v7, (long long)&v9, v0, v1, v2, v3),
*(_DWORD *)(v9 + 24) = logfile_by_number_no_cache,
logfile_by_number_no_cache == -1) )
{
inline_mysql_rwlock_unlock((long long)&log_descriptor[75]);
LABEL_10:
translog_stop_writing();
my_free(v9);
return 1;
}
translog_file_init(v9, v7, 0);
memmove(qword_478E98 + 8, qword_478E98, 8LL * (unsigned int)(++dword_478EC0 - dword_478EC4));
set_dynamic(&log_descriptor[69], &v9, 0LL);
inline_mysql_rwlock_unlock((long long)&log_descriptor[75]);
if ( translog_write_file_header((long long)&log_descriptor[75], (long long)&v9, v5)
|| (unsigned int)ma_control_file_write_and_force(
last_checkpoint_lsn,
v7,
max_trid_in_control_file,
recovery_failures) )
{
goto LABEL_10;
}
return 0;
}
| translog_create_new_file:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
XOR EDI,EDI
MOV ESI,0x58
XOR EAX,EAX
MOV EDX,EAX
CALL 0x001f3820
MOV qword ptr [RBP + -0x10],RAX
CALL 0x0013ac90
MOV qword ptr [RBP + -0x18],RAX
MOV RAX,qword ptr [0x00d798b8]
SAR RAX,0x20
MOV dword ptr [RBP + -0x1c],EAX
CMP qword ptr [RBP + -0x10],0x0
JNZ 0x001373cf
JMP 0x0013754a
LAB_001373cf:
MOV RAX,qword ptr [RBP + -0x18]
MOV EDI,dword ptr [RAX + 0x18]
MOV RSI,qword ptr [0x00d79900]
CALL 0x00137570
CMP AL,0x0
JZ 0x001373eb
JMP 0x0013754a
LAB_001373eb:
LEA RDI,[0x578c70]
ADD RDI,0x258
LEA RSI,[0x251682]
MOV EDX,0x687
CALL 0x001356f0
JMP 0x0013740c
LAB_0013740c:
JMP 0x0013740e
LAB_0013740e:
JMP 0x00137410
LAB_00137410:
MOV ESI,dword ptr [0x00578ec0]
SUB ESI,dword ptr [0x00578ec4]
ADD ESI,0x2
LEA RDI,[0x578c70]
ADD RDI,0x228
CALL 0x001da990
CMP AL,0x0
JZ 0x0013743b
JMP 0x00137537
LAB_0013743b:
LEA RDI,[0x578c70]
ADD RDI,0x228
LEA RSI,[RBP + -0x10]
CALL 0x001da680
CMP AL,0x0
JZ 0x0013745b
JMP 0x00137537
LAB_0013745b:
MOV EDI,dword ptr [RBP + -0x1c]
CALL 0x00130860
MOV RCX,qword ptr [RBP + -0x10]
MOV dword ptr [RCX + 0x18],EAX
CMP EAX,-0x1
JNZ 0x00137474
JMP 0x00137537
LAB_00137474:
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,dword ptr [RBP + -0x1c]
XOR EDX,EDX
CALL 0x0012ff80
MOV EAX,dword ptr [0x00578ec0]
ADD EAX,0x1
MOV dword ptr [0x00578ec0],EAX
MOV RAX,qword ptr [0x00578e98]
MOV qword ptr [RBP + -0x28],RAX
MOV RDI,qword ptr [RBP + -0x28]
ADD RDI,0x8
MOV RSI,qword ptr [RBP + -0x28]
MOV EAX,dword ptr [0x00578ec0]
SUB EAX,dword ptr [0x00578ec4]
ADD EAX,0x1
SUB EAX,0x1
MOV EAX,EAX
MOV EDX,EAX
SHL RDX,0x3
CALL 0x0012a120
LEA RDI,[0x578c70]
ADD RDI,0x228
LEA RSI,[RBP + -0x10]
XOR EDX,EDX
CALL 0x001da8d0
JMP 0x001374e2
LAB_001374e2:
LEA RDI,[0x578c70]
ADD RDI,0x258
CALL 0x00135760
JMP 0x001374f7
LAB_001374f7:
CALL 0x001370d0
CMP AL,0x0
JZ 0x00137502
JMP 0x0013754a
LAB_00137502:
LEA RAX,[0x577a10]
MOV RDI,qword ptr [RAX]
MOV ESI,dword ptr [RBP + -0x1c]
LEA RAX,[0x577a20]
MOV RDX,qword ptr [RAX]
LEA RAX,[0x577a28]
MOVZX ECX,byte ptr [RAX]
CALL 0x0012c6a0
CMP EAX,0x0
JZ 0x0013752f
JMP 0x0013754a
LAB_0013752f:
JMP 0x00137531
LAB_00137531:
MOV byte ptr [RBP + -0x1],0x0
JMP 0x0013755c
LAB_00137537:
LEA RDI,[0x578c70]
ADD RDI,0x258
CALL 0x00135760
LAB_0013754a:
CALL 0x0012d640
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x001f3ba0
MOV byte ptr [RBP + -0x1],0x1
LAB_0013755c:
MOV AL,byte ptr [RBP + -0x1]
ADD RSP,0x30
POP RBP
RET
|
int1 translog_create_new_file(void)
{
char cVar1;
int4 uVar2;
int iVar3;
long lVar4;
long local_18 [2];
local_18[0] = my_malloc(0,0x58,0);
lVar4 = get_current_logfile();
uVar2 = (int4)((ulong)DAT_00d798b8 >> 0x20);
if ((local_18[0] != 0) &&
(cVar1 = translog_max_lsn_to_header(*(int4 *)(lVar4 + 0x18),DAT_00d79900), cVar1 == '\0')
) {
inline_mysql_rwlock_wrlock
(&DAT_00578ec8,
"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_loghandler.c",0x687);
cVar1 = allocate_dynamic(&DAT_00578e98,(DAT_00578ec0 - DAT_00578ec4) + 2);
if ((cVar1 == '\0') && (cVar1 = insert_dynamic(&DAT_00578e98,local_18), cVar1 == '\0')) {
iVar3 = create_logfile_by_number_no_cache(uVar2);
*(int *)(local_18[0] + 0x18) = iVar3;
if (iVar3 != -1) {
translog_file_init(local_18[0],uVar2,0);
DAT_00578ec0 = DAT_00578ec0 + 1;
memmove((void *)((long)DAT_00578e98 + 8),DAT_00578e98,
(ulong)(uint)(DAT_00578ec0 - DAT_00578ec4) << 3);
set_dynamic(&DAT_00578e98,local_18,0);
inline_mysql_rwlock_unlock(&DAT_00578ec8);
cVar1 = translog_write_file_header();
if ((cVar1 == '\0') &&
(iVar3 = ma_control_file_write_and_force
(last_checkpoint_lsn,uVar2,max_trid_in_control_file,recovery_failures)
, iVar3 == 0)) {
return 0;
}
goto LAB_0013754a;
}
}
inline_mysql_rwlock_unlock(&DAT_00578ec8);
}
LAB_0013754a:
translog_stop_writing();
my_free(local_18[0]);
return 1;
}
| |
38,089 | my_string_metadata_get_mb | eloqsql/strings/ctype.c | static void
my_string_metadata_get_mb(MY_STRING_METADATA *metadata,
CHARSET_INFO *cs, const char *str, ulong length)
{
const char *strend= str + length;
for (my_string_metadata_init(metadata) ;
str < strend;
metadata->char_length++)
{
my_wc_t wc;
int mblen= my_ci_mb_wc(cs, &wc, (const uchar *) str, (const uchar *) strend);
if (mblen > 0) /* Assigned character */
{
if (wc > 0x7F)
metadata->repertoire|= MY_REPERTOIRE_EXTENDED;
str+= mblen;
}
else if (mblen == MY_CS_ILSEQ) /* Bad byte sequence */
{
metadata->repertoire|= MY_REPERTOIRE_EXTENDED;
str++;
}
else if (mblen > MY_CS_TOOSMALL) /* Unassigned character */
{
metadata->repertoire|= MY_REPERTOIRE_EXTENDED;
str+= (-mblen);
}
else /* Incomplete character, premature end-of-line */
{
metadata->repertoire|= MY_REPERTOIRE_EXTENDED; /* Just in case */
break;
}
}
} | O0 | c | my_string_metadata_get_mb:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x18(%rbp), %rax
addq -0x20(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x8(%rbp), %rdi
callq 0x6e4f0
movq -0x18(%rbp), %rax
cmpq -0x28(%rbp), %rax
jae 0x6d07d
movq -0x10(%rbp), %rax
movq 0xb8(%rax), %rax
movq 0x28(%rax), %rax
movq -0x10(%rbp), %rdi
movq -0x18(%rbp), %rdx
movq -0x28(%rbp), %rcx
leaq -0x30(%rbp), %rsi
callq *%rax
movl %eax, -0x34(%rbp)
cmpl $0x0, -0x34(%rbp)
jle 0x6d00c
cmpq $0x7f, -0x30(%rbp)
jbe 0x6cff9
movq -0x8(%rbp), %rax
movl 0x8(%rax), %ecx
orl $0x2, %ecx
movl %ecx, 0x8(%rax)
movl -0x34(%rbp), %ecx
movq -0x18(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
jmp 0x6d068
cmpl $0x0, -0x34(%rbp)
jne 0x6d02d
movq -0x8(%rbp), %rax
movl 0x8(%rax), %ecx
orl $0x2, %ecx
movl %ecx, 0x8(%rax)
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0x6d066
cmpl $-0x65, -0x34(%rbp)
jle 0x6d055
movq -0x8(%rbp), %rax
movl 0x8(%rax), %ecx
orl $0x2, %ecx
movl %ecx, 0x8(%rax)
xorl %ecx, %ecx
subl -0x34(%rbp), %ecx
movq -0x18(%rbp), %rax
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x18(%rbp)
jmp 0x6d064
movq -0x8(%rbp), %rax
movl 0x8(%rax), %ecx
orl $0x2, %ecx
movl %ecx, 0x8(%rax)
jmp 0x6d07d
jmp 0x6d066
jmp 0x6d068
jmp 0x6d06a
movq -0x8(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movq %rcx, (%rax)
jmp 0x6cfad
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
| my_string_metadata_get_mb:
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_18], rdx
mov [rbp+var_20], rcx
mov rax, [rbp+var_18]
add rax, [rbp+var_20]
mov [rbp+var_28], rax
mov rdi, [rbp+var_8]
call my_string_metadata_init
loc_6CFAD:
mov rax, [rbp+var_18]
cmp rax, [rbp+var_28]
jnb loc_6D07D
mov rax, [rbp+var_10]
mov rax, [rax+0B8h]
mov rax, [rax+28h]
mov rdi, [rbp+var_10]
mov rdx, [rbp+var_18]
mov rcx, [rbp+var_28]
lea rsi, [rbp+var_30]
call rax
mov [rbp+var_34], eax
cmp [rbp+var_34], 0
jle short loc_6D00C
cmp [rbp+var_30], 7Fh
jbe short loc_6CFF9
mov rax, [rbp+var_8]
mov ecx, [rax+8]
or ecx, 2
mov [rax+8], ecx
loc_6CFF9:
mov ecx, [rbp+var_34]
mov rax, [rbp+var_18]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_18], rax
jmp short loc_6D068
loc_6D00C:
cmp [rbp+var_34], 0
jnz short loc_6D02D
mov rax, [rbp+var_8]
mov ecx, [rax+8]
or ecx, 2
mov [rax+8], ecx
mov rax, [rbp+var_18]
add rax, 1
mov [rbp+var_18], rax
jmp short loc_6D066
loc_6D02D:
cmp [rbp+var_34], 0FFFFFF9Bh
jle short loc_6D055
mov rax, [rbp+var_8]
mov ecx, [rax+8]
or ecx, 2
mov [rax+8], ecx
xor ecx, ecx
sub ecx, [rbp+var_34]
mov rax, [rbp+var_18]
movsxd rcx, ecx
add rax, rcx
mov [rbp+var_18], rax
jmp short loc_6D064
loc_6D055:
mov rax, [rbp+var_8]
mov ecx, [rax+8]
or ecx, 2
mov [rax+8], ecx
jmp short loc_6D07D
loc_6D064:
jmp short $+2
loc_6D066:
jmp short $+2
loc_6D068:
jmp short $+2
loc_6D06A:
mov rax, [rbp+var_8]
mov rcx, [rax]
add rcx, 1
mov [rax], rcx
jmp loc_6CFAD
loc_6D07D:
add rsp, 40h
pop rbp
retn
| unsigned long long my_string_metadata_get_mb(unsigned long long a1, long long a2, unsigned long long a3, long long a4)
{
unsigned long long result; // rax
int v5; // [rsp+Ch] [rbp-34h]
unsigned long long v6; // [rsp+10h] [rbp-30h] BYREF
unsigned long long v7; // [rsp+18h] [rbp-28h]
long long v8; // [rsp+20h] [rbp-20h]
unsigned long long v9; // [rsp+28h] [rbp-18h]
long long v10; // [rsp+30h] [rbp-10h]
unsigned long long v11; // [rsp+38h] [rbp-8h]
v11 = a1;
v10 = a2;
v9 = a3;
v8 = a4;
v7 = a4 + a3;
my_string_metadata_init(a1);
while ( 1 )
{
result = v9;
if ( v9 >= v7 )
break;
v5 = (*(long long ( **)(long long, unsigned long long *, unsigned long long, unsigned long long))(*(_QWORD *)(v10 + 184) + 40LL))(
v10,
&v6,
v9,
v7);
if ( v5 <= 0 )
{
if ( v5 )
{
if ( v5 <= -101 )
{
result = v11;
*(_DWORD *)(v11 + 8) |= 2u;
return result;
}
*(_DWORD *)(v11 + 8) |= 2u;
v9 += -v5;
}
else
{
*(_DWORD *)(v11 + 8) |= 2u;
++v9;
}
}
else
{
if ( v6 > 0x7F )
*(_DWORD *)(v11 + 8) |= 2u;
v9 += v5;
}
++*(_QWORD *)v11;
}
return result;
}
| my_string_metadata_get_mb:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV qword ptr [RBP + -0x18],RDX
MOV qword ptr [RBP + -0x20],RCX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,qword ptr [RBP + -0x20]
MOV qword ptr [RBP + -0x28],RAX
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x0016e4f0
LAB_0016cfad:
MOV RAX,qword ptr [RBP + -0x18]
CMP RAX,qword ptr [RBP + -0x28]
JNC 0x0016d07d
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0xb8]
MOV RAX,qword ptr [RAX + 0x28]
MOV RDI,qword ptr [RBP + -0x10]
MOV RDX,qword ptr [RBP + -0x18]
MOV RCX,qword ptr [RBP + -0x28]
LEA RSI,[RBP + -0x30]
CALL RAX
MOV dword ptr [RBP + -0x34],EAX
CMP dword ptr [RBP + -0x34],0x0
JLE 0x0016d00c
CMP qword ptr [RBP + -0x30],0x7f
JBE 0x0016cff9
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x8]
OR ECX,0x2
MOV dword ptr [RAX + 0x8],ECX
LAB_0016cff9:
MOV ECX,dword ptr [RBP + -0x34]
MOV RAX,qword ptr [RBP + -0x18]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x18],RAX
JMP 0x0016d068
LAB_0016d00c:
CMP dword ptr [RBP + -0x34],0x0
JNZ 0x0016d02d
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x8]
OR ECX,0x2
MOV dword ptr [RAX + 0x8],ECX
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,0x1
MOV qword ptr [RBP + -0x18],RAX
JMP 0x0016d066
LAB_0016d02d:
CMP dword ptr [RBP + -0x34],-0x65
JLE 0x0016d055
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x8]
OR ECX,0x2
MOV dword ptr [RAX + 0x8],ECX
XOR ECX,ECX
SUB ECX,dword ptr [RBP + -0x34]
MOV RAX,qword ptr [RBP + -0x18]
MOVSXD RCX,ECX
ADD RAX,RCX
MOV qword ptr [RBP + -0x18],RAX
JMP 0x0016d064
LAB_0016d055:
MOV RAX,qword ptr [RBP + -0x8]
MOV ECX,dword ptr [RAX + 0x8]
OR ECX,0x2
MOV dword ptr [RAX + 0x8],ECX
JMP 0x0016d07d
LAB_0016d064:
JMP 0x0016d066
LAB_0016d066:
JMP 0x0016d068
LAB_0016d068:
JMP 0x0016d06a
LAB_0016d06a:
MOV RAX,qword ptr [RBP + -0x8]
MOV RCX,qword ptr [RAX]
ADD RCX,0x1
MOV qword ptr [RAX],RCX
JMP 0x0016cfad
LAB_0016d07d:
ADD RSP,0x40
POP RBP
RET
|
void my_string_metadata_get_mb(long *param_1,long param_2,ulong param_3,long param_4)
{
int iVar1;
ulong local_38;
ulong local_30;
long local_28;
ulong local_20;
long local_18;
long *local_10;
local_30 = param_3 + param_4;
local_28 = param_4;
local_20 = param_3;
local_18 = param_2;
local_10 = param_1;
my_string_metadata_init(param_1);
do {
if (local_30 <= local_20) {
return;
}
iVar1 = (**(code **)(*(long *)(local_18 + 0xb8) + 0x28))(local_18,&local_38,local_20,local_30);
if (iVar1 < 1) {
if (iVar1 == 0) {
*(uint *)(local_10 + 1) = *(uint *)(local_10 + 1) | 2;
local_20 = local_20 + 1;
}
else {
if (iVar1 < -100) {
*(uint *)(local_10 + 1) = *(uint *)(local_10 + 1) | 2;
return;
}
*(uint *)(local_10 + 1) = *(uint *)(local_10 + 1) | 2;
local_20 = local_20 + (long)-iVar1;
}
}
else {
if (0x7f < local_38) {
*(uint *)(local_10 + 1) = *(uint *)(local_10 + 1) | 2;
}
local_20 = local_20 + (long)iVar1;
}
*local_10 = *local_10 + 1;
} while( true );
}
| |
38,090 | ftxui::yflex_shrink(std::shared_ptr<ftxui::Node>) | Andrewchistyakov[P]flashcards_lyc/build_O1/_deps/ftxui-src/src/ftxui/dom/flex.cpp | Element yflex_shrink(Element child) {
return std::make_shared<Flex>(function_yflex_shrink, std::move(child));
} | O1 | cpp | ftxui::yflex_shrink(std::shared_ptr<ftxui::Node>):
pushq %r14
pushq %rbx
subq $0x18, %rsp
movq %rsi, %rdx
movq %rdi, %rbx
leaq 0x30(%rip), %rsi # 0x23bd1
leaq 0x8(%rsp), %r14
movq %r14, %rdi
callq 0x23876
movq (%r14), %rax
movq %rax, (%rbx)
xorl %eax, %eax
movq %rax, 0x8(%rbx)
movq 0x8(%r14), %rcx
movq %rax, 0x8(%r14)
movq %rcx, 0x8(%rbx)
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r14
retq
| _ZN5ftxui12yflex_shrinkESt10shared_ptrINS_4NodeEE:
push r14
push rbx
sub rsp, 18h
mov rdx, rsi
mov rbx, rdi
lea rsi, _ZN5ftxui12_GLOBAL__N_121function_yflex_shrinkERNS_11RequirementE; ftxui::`anonymous namespace'::function_yflex_shrink(ftxui::Requirement &)
lea r14, [rsp+28h+var_20]
mov rdi, r14
call _ZSt11make_sharedIN5ftxui12_GLOBAL__N_14FlexEJRFvRNS0_11RequirementEESt10shared_ptrINS0_4NodeEEEES7_IT_EDpOT0_; std::make_shared<ftxui::`anonymous namespace'::Flex,void (&)(ftxui::Requirement &),std::shared_ptr<ftxui::Node>>(void (&)(ftxui::Requirement &),std::shared_ptr<ftxui::Node> &&)
mov rax, [r14]
mov [rbx], rax
xor eax, eax
mov [rbx+8], rax
mov rcx, [r14+8]
mov [r14+8], rax
mov [rbx+8], rcx
mov rax, rbx
add rsp, 18h
pop rbx
pop r14
retn
| _QWORD * ftxui::yflex_shrink(_QWORD *a1, __int128 *a2)
{
_QWORD v3[4]; // [rsp+8h] [rbp-20h] BYREF
std::make_shared<ftxui::`anonymous namespace'::Flex,void (&)(ftxui::Requirement &),std::shared_ptr<ftxui::Node>>(
v3,
(long long)ftxui::`anonymous namespace'::function_yflex_shrink,
a2);
*a1 = v3[0];
a1[1] = 0LL;
a1[1] = v3[1];
return a1;
}
| yflex_shrink:
PUSH R14
PUSH RBX
SUB RSP,0x18
MOV RDX,RSI
MOV RBX,RDI
LEA RSI,[0x123bd1]
LEA R14,[RSP + 0x8]
MOV RDI,R14
CALL 0x00123876
MOV RAX,qword ptr [R14]
MOV qword ptr [RBX],RAX
XOR EAX,EAX
MOV qword ptr [RBX + 0x8],RAX
MOV RCX,qword ptr [R14 + 0x8]
MOV qword ptr [R14 + 0x8],RAX
MOV qword ptr [RBX + 0x8],RCX
MOV RAX,RBX
ADD RSP,0x18
POP RBX
POP R14
RET
|
/* ftxui::yflex_shrink(std::shared_ptr<ftxui::Node>) */
int8 * ftxui::yflex_shrink(int8 *param_1)
{
int8 local_20;
int8 local_18;
std::
make_shared<ftxui::(anonymous_namespace)::Flex,void(&)(ftxui::Requirement&),std::shared_ptr<ftxui::Node>>
((_func_void_Requirement_ptr *)&local_20,
(shared_ptr *)(anonymous_namespace)::function_yflex_shrink);
*param_1 = local_20;
param_1[1] = 0;
param_1[1] = local_18;
return param_1;
}
| |
38,091 | minja::Value::operator-(minja::Value const&) const | monkey531[P]llama/common/minja.hpp | Value operator-(const Value& rhs) const {
if (is_number_integer() && rhs.is_number_integer())
return get<int64_t>() - rhs.get<int64_t>();
else
return get<double>() - rhs.get<double>();
} | O1 | cpp | minja::Value::operator-(minja::Value const&) const:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdx, %r14
movq %rdi, %rbx
movb 0x40(%rsi), %al
addb $-0x5, %al
cmpb $0x1, %al
ja 0x7c68d
movb 0x40(%r14), %al
addb $-0x5, %al
cmpb $0x1, %al
ja 0x7c68d
movq %rsi, %rdi
callq 0x6c6fc
movq %rax, %r15
movq %r14, %rdi
callq 0x6c6fc
subq %rax, %r15
leaq 0x40(%rbx), %r14
xorpd %xmm0, %xmm0
movupd %xmm0, (%rbx)
movupd %xmm0, 0x10(%rbx)
movupd %xmm0, 0x20(%rbx)
movupd %xmm0, 0x30(%rbx)
movupd %xmm0, 0x40(%rbx)
movq %r14, %rdi
movq %r15, %rsi
callq 0x30f8a
jmp 0x7c6d9
movq %rsi, %rdi
callq 0x6c82e
movsd %xmm0, 0x8(%rsp)
movq %r14, %rdi
callq 0x6c82e
movsd 0x8(%rsp), %xmm1
subsd %xmm0, %xmm1
leaq 0x40(%rbx), %r14
xorpd %xmm0, %xmm0
movupd %xmm0, (%rbx)
movupd %xmm0, 0x10(%rbx)
movupd %xmm0, 0x20(%rbx)
movupd %xmm0, 0x30(%rbx)
movupd %xmm0, 0x40(%rbx)
movq %r14, %rdi
movapd %xmm1, %xmm0
callq 0x3054a
movq %r14, %rdi
movl $0x1, %esi
callq 0x28fd0
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
nop
| _ZNK5minja5ValuemiERKS0_:
push r15
push r14
push rbx
sub rsp, 10h
mov r14, rdx
mov rbx, rdi
mov al, [rsi+40h]
add al, 0FBh
cmp al, 1
ja short loc_7C68D
mov al, [r14+40h]
add al, 0FBh
cmp al, 1
ja short loc_7C68D
mov rdi, rsi
call _ZNK5minja5Value3getIlEET_v; minja::Value::get<long>(void)
mov r15, rax
mov rdi, r14
call _ZNK5minja5Value3getIlEET_v; minja::Value::get<long>(void)
sub r15, rax
lea r14, [rbx+40h]
xorpd xmm0, xmm0
movupd xmmword ptr [rbx], xmm0
movupd xmmword ptr [rbx+10h], xmm0
movupd xmmword ptr [rbx+20h], xmm0
movupd xmmword ptr [rbx+30h], xmm0
movupd xmmword ptr [rbx+40h], xmm0
mov rdi, r14
mov rsi, r15
call _ZN8nlohmann16json_abi_v3_11_36detail20external_constructorILNS1_7value_tE5EE9constructINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES8_IhSaIhEEvEEEEvRT_NSJ_16number_integer_tE; nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)5>::construct<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &,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>::number_integer_t)
jmp short loc_7C6D9
loc_7C68D:
mov rdi, rsi
call _ZNK5minja5Value3getIdEET_v; minja::Value::get<double>(void)
movsd [rsp+28h+var_20], xmm0
mov rdi, r14
call _ZNK5minja5Value3getIdEET_v; minja::Value::get<double>(void)
movsd xmm1, [rsp+28h+var_20]
subsd xmm1, xmm0
lea r14, [rbx+40h]
xorpd xmm0, xmm0
movupd xmmword ptr [rbx], xmm0
movupd xmmword ptr [rbx+10h], xmm0
movupd xmmword ptr [rbx+20h], xmm0
movupd xmmword ptr [rbx+30h], xmm0
movupd xmmword ptr [rbx+40h], xmm0
mov rdi, r14
movapd xmm0, xmm1
call _ZN8nlohmann16json_abi_v3_11_36detail20external_constructorILNS1_7value_tE7EE9constructINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES8_IhSaIhEEvEEEEvRT_NSJ_14number_float_tE; nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)7>::construct<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &,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>::number_float_t)
loc_7C6D9:
mov rdi, r14
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 rax, rbx
add rsp, 10h
pop rbx
pop r14
pop r15
retn
| long long minja::Value::operator-(long long a1, long long a2, long long a3)
{
long long v4; // r15
long long v5; // rax
char *v6; // r14
double v7; // xmm1_8
double v9; // [rsp+8h] [rbp-20h]
if ( (unsigned __int8)(*(_BYTE *)(a2 + 64) - 5) > 1u || (unsigned __int8)(*(_BYTE *)(a3 + 64) - 5) > 1u )
{
v9 = minja::Value::get<double>(a2);
v7 = v9 - minja::Value::get<double>(a3);
v6 = (char *)(a1 + 64);
*(_OWORD *)a1 = 0LL;
*(_OWORD *)(a1 + 16) = 0LL;
*(_OWORD *)(a1 + 32) = 0LL;
*(_OWORD *)(a1 + 48) = 0LL;
*(_OWORD *)(a1 + 64) = 0LL;
nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)7>::construct<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>>(
(unsigned __int8 *)(a1 + 64),
v7);
}
else
{
v4 = minja::Value::get<long>(a2);
v5 = minja::Value::get<long>(a3);
v6 = (char *)(a1 + 64);
*(_OWORD *)a1 = 0LL;
*(_OWORD *)(a1 + 16) = 0LL;
*(_OWORD *)(a1 + 32) = 0LL;
*(_OWORD *)(a1 + 48) = 0LL;
*(_OWORD *)(a1 + 64) = 0LL;
nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)5>::construct<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>>(
(unsigned __int8 *)(a1 + 64),
v4 - v5);
}
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant(v6);
return a1;
}
| operator-:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x10
MOV R14,RDX
MOV RBX,RDI
MOV AL,byte ptr [RSI + 0x40]
ADD AL,0xfb
CMP AL,0x1
JA 0x0017c68d
MOV AL,byte ptr [R14 + 0x40]
ADD AL,0xfb
CMP AL,0x1
JA 0x0017c68d
MOV RDI,RSI
CALL 0x0016c6fc
MOV R15,RAX
MOV RDI,R14
CALL 0x0016c6fc
SUB R15,RAX
LEA R14,[RBX + 0x40]
XORPD XMM0,XMM0
MOVUPD xmmword ptr [RBX],XMM0
MOVUPD xmmword ptr [RBX + 0x10],XMM0
MOVUPD xmmword ptr [RBX + 0x20],XMM0
MOVUPD xmmword ptr [RBX + 0x30],XMM0
MOVUPD xmmword ptr [RBX + 0x40],XMM0
MOV RDI,R14
MOV RSI,R15
CALL 0x00130f8a
JMP 0x0017c6d9
LAB_0017c68d:
MOV RDI,RSI
CALL 0x0016c82e
MOVSD qword ptr [RSP + 0x8],XMM0
MOV RDI,R14
CALL 0x0016c82e
MOVSD XMM1,qword ptr [RSP + 0x8]
SUBSD XMM1,XMM0
LEA R14,[RBX + 0x40]
XORPD XMM0,XMM0
MOVUPD xmmword ptr [RBX],XMM0
MOVUPD xmmword ptr [RBX + 0x10],XMM0
MOVUPD xmmword ptr [RBX + 0x20],XMM0
MOVUPD xmmword ptr [RBX + 0x30],XMM0
MOVUPD xmmword ptr [RBX + 0x40],XMM0
MOV RDI,R14
MOVAPD XMM0,XMM1
CALL 0x0013054a
LAB_0017c6d9:
MOV RDI,R14
MOV ESI,0x1
CALL 0x00128fd0
MOV RAX,RBX
ADD RSP,0x10
POP RBX
POP R14
POP R15
RET
|
/* minja::Value::TEMPNAMEPLACEHOLDERVALUE(minja::Value const&) const */
Value * __thiscall minja::Value::operator-(Value *this,Value *param_1)
{
long lVar1;
long lVar2;
Value *in_RDX;
double dVar3;
double dVar4;
if (((byte)((char)param_1[0x40] - 5U) < 2) && ((byte)((char)in_RDX[0x40] - 5U) < 2)) {
lVar1 = get<long>(param_1);
lVar2 = get<long>(in_RDX);
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
*(int8 *)(this + 0x10) = 0;
*(int8 *)(this + 0x18) = 0;
*(int8 *)(this + 0x20) = 0;
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x40) = 0;
*(int8 *)(this + 0x48) = 0;
nlohmann::json_abi_v3_11_3::detail::
external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)5>::
construct<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 + 0x40,lVar1 - lVar2);
}
else {
dVar3 = get<double>(param_1);
dVar4 = get<double>(in_RDX);
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
*(int8 *)(this + 0x10) = 0;
*(int8 *)(this + 0x18) = 0;
*(int8 *)(this + 0x20) = 0;
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x40) = 0;
*(int8 *)(this + 0x48) = 0;
nlohmann::json_abi_v3_11_3::detail::
external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)7>::
construct<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>>
(dVar3 - dVar4,this + 0x40);
}
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant((bool)((char)this + '@'));
return this;
}
| |
38,092 | minja::Value::operator-(minja::Value const&) const | monkey531[P]llama/common/minja.hpp | Value operator-(const Value& rhs) const {
if (is_number_integer() && rhs.is_number_integer())
return get<int64_t>() - rhs.get<int64_t>();
else
return get<double>() - rhs.get<double>();
} | O3 | cpp | minja::Value::operator-(minja::Value const&) const:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdx, %r14
movq %rdi, %rbx
movb 0x40(%rsi), %al
addb $-0x5, %al
cmpb $0x1, %al
ja 0x7a787
movb 0x40(%r14), %al
addb $-0x5, %al
cmpb $0x1, %al
ja 0x7a787
movq %rsi, %rdi
callq 0x6a970
movq %rax, %r15
movq %r14, %rdi
callq 0x6a970
subq %rax, %r15
leaq 0x40(%rbx), %r14
xorpd %xmm0, %xmm0
movupd %xmm0, (%rbx)
movupd %xmm0, 0x10(%rbx)
movupd %xmm0, 0x20(%rbx)
movupd %xmm0, 0x30(%rbx)
movupd %xmm0, 0x40(%rbx)
movq %r14, %rdi
movq %r15, %rsi
callq 0x301aa
jmp 0x7a7d3
movq %rsi, %rdi
callq 0x6aaba
movsd %xmm0, 0x8(%rsp)
movq %r14, %rdi
callq 0x6aaba
movsd 0x8(%rsp), %xmm1
subsd %xmm0, %xmm1
leaq 0x40(%rbx), %r14
xorpd %xmm0, %xmm0
movupd %xmm0, (%rbx)
movupd %xmm0, 0x10(%rbx)
movupd %xmm0, 0x20(%rbx)
movupd %xmm0, 0x30(%rbx)
movupd %xmm0, 0x40(%rbx)
movq %r14, %rdi
movapd %xmm1, %xmm0
callq 0x2f772
movq %r14, %rdi
movl $0x1, %esi
callq 0x284e2
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
nop
| _ZNK5minja5ValuemiERKS0_:
push r15
push r14
push rbx
sub rsp, 10h
mov r14, rdx
mov rbx, rdi
mov al, [rsi+40h]
add al, 0FBh
cmp al, 1
ja short loc_7A787
mov al, [r14+40h]
add al, 0FBh
cmp al, 1
ja short loc_7A787
mov rdi, rsi
call _ZNK5minja5Value3getIlEET_v; minja::Value::get<long>(void)
mov r15, rax
mov rdi, r14
call _ZNK5minja5Value3getIlEET_v; minja::Value::get<long>(void)
sub r15, rax
lea r14, [rbx+40h]
xorpd xmm0, xmm0
movupd xmmword ptr [rbx], xmm0
movupd xmmword ptr [rbx+10h], xmm0
movupd xmmword ptr [rbx+20h], xmm0
movupd xmmword ptr [rbx+30h], xmm0
movupd xmmword ptr [rbx+40h], xmm0
mov rdi, r14
mov rsi, r15
call _ZN8nlohmann16json_abi_v3_11_36detail20external_constructorILNS1_7value_tE5EE9constructINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES8_IhSaIhEEvEEEEvRT_NSJ_16number_integer_tE; nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)5>::construct<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &,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>::number_integer_t)
jmp short loc_7A7D3
loc_7A787:
mov rdi, rsi
call _ZNK5minja5Value3getIdEET_v; minja::Value::get<double>(void)
movsd [rsp+28h+var_20], xmm0
mov rdi, r14
call _ZNK5minja5Value3getIdEET_v; minja::Value::get<double>(void)
movsd xmm1, [rsp+28h+var_20]
subsd xmm1, xmm0
lea r14, [rbx+40h]
xorpd xmm0, xmm0
movupd xmmword ptr [rbx], xmm0
movupd xmmword ptr [rbx+10h], xmm0
movupd xmmword ptr [rbx+20h], xmm0
movupd xmmword ptr [rbx+30h], xmm0
movupd xmmword ptr [rbx+40h], xmm0
mov rdi, r14
movapd xmm0, xmm1
call _ZN8nlohmann16json_abi_v3_11_36detail20external_constructorILNS1_7value_tE7EE9constructINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES8_IhSaIhEEvEEEEvRT_NSJ_14number_float_tE; nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)7>::construct<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &,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>::number_float_t)
loc_7A7D3:
mov rdi, r14
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 rax, rbx
add rsp, 10h
pop rbx
pop r14
pop r15
retn
| long long minja::Value::operator-(long long a1, long long a2, long long a3)
{
long long v4; // r15
long long v5; // rax
char *v6; // r14
double v7; // xmm1_8
double v9; // [rsp+8h] [rbp-20h]
if ( (unsigned __int8)(*(_BYTE *)(a2 + 64) - 5) > 1u || (unsigned __int8)(*(_BYTE *)(a3 + 64) - 5) > 1u )
{
v9 = minja::Value::get<double>(a2);
v7 = v9 - minja::Value::get<double>(a3);
v6 = (char *)(a1 + 64);
*(_OWORD *)a1 = 0LL;
*(_OWORD *)(a1 + 16) = 0LL;
*(_OWORD *)(a1 + 32) = 0LL;
*(_OWORD *)(a1 + 48) = 0LL;
*(_OWORD *)(a1 + 64) = 0LL;
nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)7>::construct<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>>(
(unsigned __int8 *)(a1 + 64),
v7);
}
else
{
v4 = minja::Value::get<long>(a2);
v5 = minja::Value::get<long>(a3);
v6 = (char *)(a1 + 64);
*(_OWORD *)a1 = 0LL;
*(_OWORD *)(a1 + 16) = 0LL;
*(_OWORD *)(a1 + 32) = 0LL;
*(_OWORD *)(a1 + 48) = 0LL;
*(_OWORD *)(a1 + 64) = 0LL;
nlohmann::json_abi_v3_11_3::detail::external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)5>::construct<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>>(
(unsigned __int8 *)(a1 + 64),
v4 - v5);
}
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::assert_invariant(v6);
return a1;
}
| operator-:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x10
MOV R14,RDX
MOV RBX,RDI
MOV AL,byte ptr [RSI + 0x40]
ADD AL,0xfb
CMP AL,0x1
JA 0x0017a787
MOV AL,byte ptr [R14 + 0x40]
ADD AL,0xfb
CMP AL,0x1
JA 0x0017a787
MOV RDI,RSI
CALL 0x0016a970
MOV R15,RAX
MOV RDI,R14
CALL 0x0016a970
SUB R15,RAX
LEA R14,[RBX + 0x40]
XORPD XMM0,XMM0
MOVUPD xmmword ptr [RBX],XMM0
MOVUPD xmmword ptr [RBX + 0x10],XMM0
MOVUPD xmmword ptr [RBX + 0x20],XMM0
MOVUPD xmmword ptr [RBX + 0x30],XMM0
MOVUPD xmmword ptr [RBX + 0x40],XMM0
MOV RDI,R14
MOV RSI,R15
CALL 0x001301aa
JMP 0x0017a7d3
LAB_0017a787:
MOV RDI,RSI
CALL 0x0016aaba
MOVSD qword ptr [RSP + 0x8],XMM0
MOV RDI,R14
CALL 0x0016aaba
MOVSD XMM1,qword ptr [RSP + 0x8]
SUBSD XMM1,XMM0
LEA R14,[RBX + 0x40]
XORPD XMM0,XMM0
MOVUPD xmmword ptr [RBX],XMM0
MOVUPD xmmword ptr [RBX + 0x10],XMM0
MOVUPD xmmword ptr [RBX + 0x20],XMM0
MOVUPD xmmword ptr [RBX + 0x30],XMM0
MOVUPD xmmword ptr [RBX + 0x40],XMM0
MOV RDI,R14
MOVAPD XMM0,XMM1
CALL 0x0012f772
LAB_0017a7d3:
MOV RDI,R14
MOV ESI,0x1
CALL 0x001284e2
MOV RAX,RBX
ADD RSP,0x10
POP RBX
POP R14
POP R15
RET
|
/* minja::Value::TEMPNAMEPLACEHOLDERVALUE(minja::Value const&) const */
Value * __thiscall minja::Value::operator-(Value *this,Value *param_1)
{
long lVar1;
long lVar2;
Value *in_RDX;
double dVar3;
double dVar4;
if (((byte)((char)param_1[0x40] - 5U) < 2) && ((byte)((char)in_RDX[0x40] - 5U) < 2)) {
lVar1 = get<long>(param_1);
lVar2 = get<long>(in_RDX);
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
*(int8 *)(this + 0x10) = 0;
*(int8 *)(this + 0x18) = 0;
*(int8 *)(this + 0x20) = 0;
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x40) = 0;
*(int8 *)(this + 0x48) = 0;
nlohmann::json_abi_v3_11_3::detail::
external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)5>::
construct<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 + 0x40,lVar1 - lVar2);
}
else {
dVar3 = get<double>(param_1);
dVar4 = get<double>(in_RDX);
*(int8 *)this = 0;
*(int8 *)(this + 8) = 0;
*(int8 *)(this + 0x10) = 0;
*(int8 *)(this + 0x18) = 0;
*(int8 *)(this + 0x20) = 0;
*(int8 *)(this + 0x28) = 0;
*(int8 *)(this + 0x30) = 0;
*(int8 *)(this + 0x38) = 0;
*(int8 *)(this + 0x40) = 0;
*(int8 *)(this + 0x48) = 0;
nlohmann::json_abi_v3_11_3::detail::
external_constructor<(nlohmann::json_abi_v3_11_3::detail::value_t)7>::
construct<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>>
(dVar3 - dVar4,this + 0x40);
}
nlohmann::json_abi_v3_11_3::
basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>
::assert_invariant((bool)((char)this + '@'));
return this;
}
| |
38,093 | vsort | davidesantangelo[P]vsort/vsort.c | VSORT_API void vsort(int arr[], int n)
{
vsort_init(); // Ensure library is initialized
if (!arr || n <= 1)
return;
vsort_log_debug("Starting vsort (int) for %d elements.", n);
// Choose strategy based on size and platform capabilities
if (n < thresholds.parallel_threshold)
{
vsort_sequential_int(arr, n);
}
else
{
#if defined(VSORT_APPLE) && defined(__arm64__)
vsort_parallel_int(arr, n);
#else
vsort_log_info("Parallel sort not available on this platform, using sequential.");
vsort_sequential_int(arr, n);
#endif
}
vsort_log_debug("vsort (int) completed for %d elements.", n);
} | O0 | c | vsort:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
callq 0x1920
cmpq $0x0, 0x10(%rsp)
je 0x1a61
cmpl $0x1, 0xc(%rsp)
jg 0x1a63
jmp 0x1abf
movl 0xc(%rsp), %esi
leaq 0x37c2(%rip), %rdi # 0x5230
movb $0x0, %al
callq 0x4610
movl 0xc(%rsp), %eax
cmpl 0x6669(%rip), %eax # 0x80e8
jge 0x1a91
movq 0x10(%rsp), %rdi
movl 0xc(%rsp), %esi
callq 0x1ad0
jmp 0x1aad
leaq 0x37be(%rip), %rdi # 0x5256
movb $0x0, %al
callq 0x4560
movq 0x10(%rsp), %rdi
movl 0xc(%rsp), %esi
callq 0x1ad0
movl 0xc(%rsp), %esi
leaq 0x37de(%rip), %rdi # 0x5296
movb $0x0, %al
callq 0x4610
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
| vsort:
sub rsp, 18h
mov [rsp+18h+var_8], rdi
mov [rsp+18h+var_C], esi
call vsort_init
cmp [rsp+18h+var_8], 0
jz short loc_1A61
cmp [rsp+18h+var_C], 1
jg short loc_1A63
loc_1A61:
jmp short loc_1ABF
loc_1A63:
mov esi, [rsp+18h+var_C]
lea rdi, aStartingVsortI; "Starting vsort (int) for %d elements."
mov al, 0
call vsort_log_debug
mov eax, [rsp+18h+var_C]
cmp eax, cs:dword_70C8
jge short loc_1A91
mov rdi, [rsp+18h+var_8]
mov esi, [rsp+18h+var_C]
call vsort_sequential_int
jmp short loc_1AAD
loc_1A91:
lea rdi, aParallelSortNo; "Parallel sort not available on this pla"...
mov al, 0
call vsort_log_info
mov rdi, [rsp+18h+var_8]
mov esi, [rsp+18h+var_C]
call vsort_sequential_int
loc_1AAD:
mov esi, [rsp+18h+var_C]
lea rdi, aVsortIntComple; "vsort (int) completed for %d elements."
mov al, 0
call vsort_log_debug
loc_1ABF:
add rsp, 18h
retn
| long long vsort(long long a1, int a2)
{
int v2; // edx
int v3; // ecx
int v4; // r8d
int v5; // r9d
int v6; // edx
int v7; // ecx
int v8; // r8d
int v9; // r9d
int v10; // edx
int v11; // ecx
int v12; // r8d
int v13; // r9d
long long result; // rax
vsort_init();
if ( a1 && a2 > 1 )
{
vsort_log_debug((unsigned int)"Starting vsort (int) for %d elements.", a2, v2, v3, v4, v5);
if ( a2 >= dword_70C8 )
vsort_log_info(
(unsigned int)"Parallel sort not available on this platform, using sequential.",
a2,
v6,
v7,
v8,
v9);
vsort_sequential_int(a1, (unsigned int)a2);
return vsort_log_debug((unsigned int)"vsort (int) completed for %d elements.", a2, v10, v11, v12, v13);
}
return result;
}
| vsort:
SUB RSP,0x18
MOV qword ptr [RSP + 0x10],RDI
MOV dword ptr [RSP + 0xc],ESI
CALL 0x00101920
CMP qword ptr [RSP + 0x10],0x0
JZ 0x00101a61
CMP dword ptr [RSP + 0xc],0x1
JG 0x00101a63
LAB_00101a61:
JMP 0x00101abf
LAB_00101a63:
MOV ESI,dword ptr [RSP + 0xc]
LEA RDI,[0x104199]
MOV AL,0x0
CALL 0x00103de0
MOV EAX,dword ptr [RSP + 0xc]
CMP EAX,dword ptr [0x001070c8]
JGE 0x00101a91
MOV RDI,qword ptr [RSP + 0x10]
MOV ESI,dword ptr [RSP + 0xc]
CALL 0x00101ad0
JMP 0x00101aad
LAB_00101a91:
LEA RDI,[0x1041bf]
MOV AL,0x0
CALL 0x00103d30
MOV RDI,qword ptr [RSP + 0x10]
MOV ESI,dword ptr [RSP + 0xc]
CALL 0x00101ad0
LAB_00101aad:
MOV ESI,dword ptr [RSP + 0xc]
LEA RDI,[0x1041ff]
MOV AL,0x0
CALL 0x00103de0
LAB_00101abf:
ADD RSP,0x18
RET
|
void vsort(long param_1,int param_2)
{
vsort_init();
if ((param_1 != 0) && (1 < param_2)) {
vsort_log_debug("Starting vsort (int) for %d elements.",param_2);
if (param_2 < DAT_001070c8) {
vsort_sequential_int(param_1,param_2);
}
else {
vsort_log_info("Parallel sort not available on this platform, using sequential.");
vsort_sequential_int(param_1,param_2);
}
vsort_log_debug("vsort (int) completed for %d elements.",param_2);
}
return;
}
| |
38,094 | vsort | davidesantangelo[P]vsort/vsort.c | VSORT_API void vsort(int arr[], int n)
{
vsort_init(); // Ensure library is initialized
if (!arr || n <= 1)
return;
vsort_log_debug("Starting vsort (int) for %d elements.", n);
// Choose strategy based on size and platform capabilities
if (n < thresholds.parallel_threshold)
{
vsort_sequential_int(arr, n);
}
else
{
#if defined(VSORT_APPLE) && defined(__arm64__)
vsort_parallel_int(arr, n);
#else
vsort_log_info("Parallel sort not available on this platform, using sequential.");
vsort_sequential_int(arr, n);
#endif
}
vsort_log_debug("vsort (int) completed for %d elements.", n);
} | O3 | c | vsort:
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebx
movq %rdi, %r14
callq 0x19a4
testq %r14, %r14
sete %al
cmpl $0x2, %ebx
setl %cl
orb %al, %cl
je 0x11c6
addq $0x8, %rsp
popq %rbx
popq %r14
retq
leaq 0x2053(%rip), %rdi # 0x3220
movl %ebx, %esi
xorl %eax, %eax
callq 0x2d92
cmpl %ebx, 0x4f04(%rip) # 0x60e0
jg 0x11ec
leaq 0x2061(%rip), %rdi # 0x3246
xorl %eax, %eax
callq 0x2cff
movq %r14, %rdi
movl %ebx, %esi
callq 0x206d
leaq 0x2089(%rip), %rdi # 0x3286
movl %ebx, %esi
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
jmp 0x2d92
| vsort:
push r14
push rbx
push rax
mov ebx, esi
mov r14, rdi
call vsort_init
test r14, r14
setz al
cmp ebx, 2
setl cl
or cl, al
jz short loc_11C6
add rsp, 8
pop rbx
pop r14
retn
loc_11C6:
lea rdi, aStartingVsortI; "Starting vsort (int) for %d elements."
mov esi, ebx
xor eax, eax
call vsort_log_debug
cmp cs:thresholds_2, ebx
jg short loc_11EC
lea rdi, aParallelSortNo; "Parallel sort not available on this pla"...
xor eax, eax
call vsort_log_info
loc_11EC:
mov rdi, r14
mov esi, ebx
call vsort_sequential_int
lea rdi, aVsortIntComple; "vsort (int) completed for %d elements."
mov esi, ebx
xor eax, eax
add rsp, 8
pop rbx
pop r14
jmp vsort_log_debug
| char vsort(long long a1, int a2, long long a3, long long a4, long long a5, long long a6, char a7)
{
char v7; // al
int v8; // edx
int v9; // r8d
int v10; // r9d
char result; // al
int v12; // ecx
int v13; // edx
int v14; // ecx
int v15; // r8d
int v16; // r9d
int v17; // edx
int v18; // ecx
int v19; // r8d
int v20; // r9d
char v21; // [rsp-8h] [rbp-18h]
char v22; // [rsp-8h] [rbp-18h]
v21 = v7;
vsort_init();
result = a1 == 0;
LOBYTE(v12) = a1 == 0 || a2 < 2;
if ( !(_BYTE)v12 )
{
vsort_log_debug((unsigned int)"Starting vsort (int) for %d elements.", a2, v8, v12, v9, v10, v21);
if ( thresholds_2 <= a2 )
vsort_log_info(
(unsigned int)"Parallel sort not available on this platform, using sequential.",
a2,
v13,
v14,
v15,
v16,
v22);
vsort_sequential_int(a1, (unsigned int)a2);
return vsort_log_debug((unsigned int)"vsort (int) completed for %d elements.", a2, v17, v18, v19, v20, a7);
}
return result;
}
| _start:
ENDBR64
XOR EBP,EBP
MOV R9,RDX
POP RSI
MOV RDX,RSP
AND RSP,-0x10
PUSH RAX
PUSH RSP
XOR R8D,R8D
XOR ECX,ECX
LEA RDI,[0x10128c]
CALL qword ptr [0x00105fd0]
HLT
|
void processEntry _start(int8 param_1,int8 param_2)
{
int1 auStack_8 [8];
(*(code *)PTR___libc_start_main_00105fd0)(main,param_2,&stack0x00000008,0,0,param_1,auStack_8);
do {
/* WARNING: Do nothing block with infinite loop */
} while( true );
}
| |
38,095 | ggml_mul_mat | ngxson[P]ggml-easy/ggml/src/ggml.c | struct ggml_tensor * ggml_mul_mat(
struct ggml_context * ctx,
struct ggml_tensor * a,
struct ggml_tensor * b) {
GGML_ASSERT(ggml_can_mul_mat(a, b));
GGML_ASSERT(!ggml_is_transposed(a));
const int64_t ne[4] = { a->ne[1], b->ne[1], b->ne[2], b->ne[3] };
struct ggml_tensor * result = ggml_new_tensor(ctx, GGML_TYPE_F32, 4, ne);
result->op = GGML_OP_MUL_MAT;
result->src[0] = a;
result->src[1] = b;
return result;
} | O2 | c | ggml_mul_mat:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rdx, %rbx
movq %rsi, %r14
movq %rdi, %r15
movq %rsi, %rdi
movq %rdx, %rsi
callq 0x212b0
testb %al, %al
je 0x21273
movq 0x30(%r14), %rax
cmpq 0x38(%r14), %rax
ja 0x2128f
movq 0x18(%r14), %rax
movq %rsp, %rcx
movq %rax, (%rcx)
movups 0x18(%rbx), %xmm0
movups %xmm0, 0x8(%rcx)
movq 0x28(%rbx), %rax
movq %rax, 0x18(%rcx)
pushq $0x4
popq %rdx
movq %r15, %rdi
xorl %esi, %esi
callq 0x1c230
movl $0x1b, 0x50(%rax)
movq %r14, 0x98(%rax)
movq %rbx, 0xa0(%rax)
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
leaq 0x2a309(%rip), %rdi # 0x4b583
leaq 0x2a34d(%rip), %rdx # 0x4b5ce
leaq 0x2a523(%rip), %rcx # 0x4b7ab
movl $0xab7, %esi # imm = 0xAB7
jmp 0x212a9
leaq 0x2a2ed(%rip), %rdi # 0x4b583
leaq 0x2a331(%rip), %rdx # 0x4b5ce
leaq 0x2a51e(%rip), %rcx # 0x4b7c2
movl $0xab8, %esi # imm = 0xAB8
xorl %eax, %eax
callq 0x1e770
| ggml_mul_mat:
push r15
push r14
push rbx
sub rsp, 20h
mov rbx, rdx
mov r14, rsi
mov r15, rdi
mov rdi, rsi
mov rsi, rdx
call ggml_can_mul_mat
test al, al
jz short loc_21273
mov rax, [r14+30h]
cmp rax, [r14+38h]
ja short loc_2128F
mov rax, [r14+18h]
mov rcx, rsp
mov [rcx], rax
movups xmm0, xmmword ptr [rbx+18h]
movups xmmword ptr [rcx+8], xmm0
mov rax, [rbx+28h]
mov [rcx+18h], rax
push 4
pop rdx
mov rdi, r15
xor esi, esi
call _ggml_new_tensor
mov dword ptr [rax+50h], 1Bh
mov [rax+98h], r14
mov [rax+0A0h], rbx
add rsp, 20h
pop rbx
pop r14
pop r15
retn
loc_21273:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aGgmlCanMulMatA; "ggml_can_mul_mat(a, b)"
mov esi, 0AB7h
jmp short loc_212A9
loc_2128F:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aGgmlIsTranspos_0; "!ggml_is_transposed(a)"
mov esi, 0AB8h
loc_212A9:
xor eax, eax
call _ggml_abort
| long long ggml_mul_mat(
long long a1,
_QWORD *a2,
long long a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
double a8,
double a9,
__m128 a10,
__m128 a11)
{
long long v12; // r8
long long v13; // r9
__m128 v14; // xmm4
__m128 v15; // xmm5
long long result; // rax
const char *v17; // rcx
int v18; // esi
long long v19; // [rsp+0h] [rbp-38h] BYREF
__int128 v20; // [rsp+8h] [rbp-30h]
long long v21; // [rsp+18h] [rbp-20h]
if ( !(unsigned __int8)ggml_can_mul_mat(a2, a3) )
{
v17 = "ggml_can_mul_mat(a, b)";
v18 = 2743;
goto LABEL_6;
}
if ( a2[6] > a2[7] )
{
v17 = "!ggml_is_transposed(a)";
v18 = 2744;
LABEL_6:
ggml_abort(
"/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/ggml.c",
v18,
(long long)"GGML_ASSERT(%s) failed",
(long long)v17,
v12,
v13,
a4,
a5,
a6,
a7,
v14,
v15,
a10,
a11,
v19);
}
v19 = a2[3];
v20 = *(_OWORD *)(a3 + 24);
v21 = *(_QWORD *)(a3 + 40);
result = ggml_new_tensor(a1, 0LL, 4LL, (long long)&v19);
*(_DWORD *)(result + 80) = 27;
*(_QWORD *)(result + 152) = a2;
*(_QWORD *)(result + 160) = a3;
return result;
}
| ggml_mul_mat:
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0x20
MOV RBX,RDX
MOV R14,RSI
MOV R15,RDI
MOV RDI,RSI
MOV RSI,RDX
CALL 0x001212b0
TEST AL,AL
JZ 0x00121273
MOV RAX,qword ptr [R14 + 0x30]
CMP RAX,qword ptr [R14 + 0x38]
JA 0x0012128f
MOV RAX,qword ptr [R14 + 0x18]
MOV RCX,RSP
MOV qword ptr [RCX],RAX
MOVUPS XMM0,xmmword ptr [RBX + 0x18]
MOVUPS xmmword ptr [RCX + 0x8],XMM0
MOV RAX,qword ptr [RBX + 0x28]
MOV qword ptr [RCX + 0x18],RAX
PUSH 0x4
POP RDX
MOV RDI,R15
XOR ESI,ESI
CALL 0x0011c230
MOV dword ptr [RAX + 0x50],0x1b
MOV qword ptr [RAX + 0x98],R14
MOV qword ptr [RAX + 0xa0],RBX
ADD RSP,0x20
POP RBX
POP R14
POP R15
RET
LAB_00121273:
LEA RDI,[0x14b583]
LEA RDX,[0x14b5ce]
LEA RCX,[0x14b7ab]
MOV ESI,0xab7
JMP 0x001212a9
LAB_0012128f:
LEA RDI,[0x14b583]
LEA RDX,[0x14b5ce]
LEA RCX,[0x14b7c2]
MOV ESI,0xab8
LAB_001212a9:
XOR EAX,EAX
CALL 0x0011e770
|
void ggml_mul_mat(int8 param_1,long param_2,int8 param_3)
{
char cVar1;
long lVar2;
char *pcVar3;
int8 uVar4;
cVar1 = ggml_can_mul_mat(param_2,param_3);
if (cVar1 == '\0') {
pcVar3 = "ggml_can_mul_mat(a, b)";
uVar4 = 0xab7;
}
else {
if (*(ulong *)(param_2 + 0x30) <= *(ulong *)(param_2 + 0x38)) {
lVar2 = ggml_new_tensor(param_1,0,4);
*(int4 *)(lVar2 + 0x50) = 0x1b;
*(long *)(lVar2 + 0x98) = param_2;
*(int8 *)(lVar2 + 0xa0) = param_3;
return;
}
pcVar3 = "!ggml_is_transposed(a)";
uVar4 = 0xab8;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/ggml.c",uVar4,
"GGML_ASSERT(%s) failed",pcVar3);
}
| |
38,096 | ggml_mul_mat | ngxson[P]ggml-easy/ggml/src/ggml.c | struct ggml_tensor * ggml_mul_mat(
struct ggml_context * ctx,
struct ggml_tensor * a,
struct ggml_tensor * b) {
GGML_ASSERT(ggml_can_mul_mat(a, b));
GGML_ASSERT(!ggml_is_transposed(a));
const int64_t ne[4] = { a->ne[1], b->ne[1], b->ne[2], b->ne[3] };
struct ggml_tensor * result = ggml_new_tensor(ctx, GGML_TYPE_F32, 4, ne);
result->op = GGML_OP_MUL_MAT;
result->src[0] = a;
result->src[1] = b;
return result;
} | O3 | c | ggml_mul_mat:
pushq %r14
pushq %rbx
subq $0x28, %rsp
movq 0x10(%rsi), %rax
cmpq 0x10(%rdx), %rax
jne 0x1b26a
movq %rdx, %rbx
movq %rsi, %r14
movq 0x20(%rdx), %r8
movq %r8, %rax
cqto
idivq 0x20(%rsi)
testq %rdx, %rdx
jne 0x1b26a
movq 0x28(%rbx), %rsi
movq %rsi, %rax
cqto
idivq 0x28(%r14)
testq %rdx, %rdx
jne 0x1b26a
movq 0x30(%r14), %rax
cmpq 0x38(%r14), %rax
ja 0x1b286
movq 0x18(%r14), %rax
movq %rsp, %rcx
movq %rax, (%rcx)
movq 0x18(%rbx), %rax
movq %rax, 0x8(%rcx)
movq %r8, 0x10(%rcx)
movq %rsi, 0x18(%rcx)
xorl %esi, %esi
movl $0x4, %edx
xorl %r8d, %r8d
xorl %r9d, %r9d
callq 0x19c13
movl $0x1b, 0x50(%rax)
movq %r14, 0x98(%rax)
movq %rbx, 0xa0(%rax)
addq $0x28, %rsp
popq %rbx
popq %r14
retq
leaq 0x2f3a2(%rip), %rdi # 0x4a613
leaq 0x2f3e6(%rip), %rdx # 0x4a65e
leaq 0x2f5bc(%rip), %rcx # 0x4a83b
movl $0xab7, %esi # imm = 0xAB7
jmp 0x1b2a0
leaq 0x2f386(%rip), %rdi # 0x4a613
leaq 0x2f3ca(%rip), %rdx # 0x4a65e
leaq 0x2f5b7(%rip), %rcx # 0x4a852
movl $0xab8, %esi # imm = 0xAB8
xorl %eax, %eax
callq 0x17c60
| ggml_mul_mat:
push r14
push rbx
sub rsp, 28h
mov rax, [rsi+10h]
cmp rax, [rdx+10h]
jnz short loc_1B26A
mov rbx, rdx
mov r14, rsi
mov r8, [rdx+20h]
mov rax, r8
cqo
idiv qword ptr [rsi+20h]
test rdx, rdx
jnz short loc_1B26A
mov rsi, [rbx+28h]
mov rax, rsi
cqo
idiv qword ptr [r14+28h]
test rdx, rdx
jnz short loc_1B26A
mov rax, [r14+30h]
cmp rax, [r14+38h]
ja short loc_1B286
mov rax, [r14+18h]
mov rcx, rsp
mov [rcx], rax
mov rax, [rbx+18h]
mov [rcx+8], rax
mov [rcx+10h], r8
mov [rcx+18h], rsi
xor esi, esi
mov edx, 4
xor r8d, r8d
xor r9d, r9d
call ggml_new_tensor_impl
mov dword ptr [rax+50h], 1Bh
mov [rax+98h], r14
mov [rax+0A0h], rbx
add rsp, 28h
pop rbx
pop r14
retn
loc_1B26A:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aGgmlCanMulMatA; "ggml_can_mul_mat(a, b)"
mov esi, 0AB7h
jmp short loc_1B2A0
loc_1B286:
lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"...
lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed"
lea rcx, aGgmlIsTranspos_0; "!ggml_is_transposed(a)"
mov esi, 0AB8h
loc_1B2A0:
xor eax, eax
call _ggml_abort
| long long ggml_mul_mat(long long a1, _QWORD *a2, _QWORD *a3, long long a4, long long a5, int a6)
{
long long v8; // rsi
long long result; // rax
const char *v10; // rcx
int v11; // esi
_QWORD v12[7]; // [rsp+0h] [rbp-38h] BYREF
if ( a2[2] != a3[2] || (a5 = a3[4], a5 % a2[4]) || (v8 = a3[5], v8 % a2[5]) )
{
v10 = "ggml_can_mul_mat(a, b)";
v11 = 2743;
goto LABEL_8;
}
if ( a2[6] > a2[7] )
{
v10 = "!ggml_is_transposed(a)";
v11 = 2744;
LABEL_8:
ggml_abort(
(unsigned int)"/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/ggml.c",
v11,
(unsigned int)"GGML_ASSERT(%s) failed",
(_DWORD)v10,
a5,
a6);
}
v12[0] = a2[3];
v12[1] = a3[3];
v12[2] = a5;
v12[3] = v8;
result = ggml_new_tensor_impl(a1, 0, 4u, v12, 0LL, 0LL);
*(_DWORD *)(result + 80) = 27;
*(_QWORD *)(result + 152) = a2;
*(_QWORD *)(result + 160) = a3;
return result;
}
| ggml_mul_mat:
PUSH R14
PUSH RBX
SUB RSP,0x28
MOV RAX,qword ptr [RSI + 0x10]
CMP RAX,qword ptr [RDX + 0x10]
JNZ 0x0011b26a
MOV RBX,RDX
MOV R14,RSI
MOV R8,qword ptr [RDX + 0x20]
MOV RAX,R8
CQO
IDIV qword ptr [RSI + 0x20]
TEST RDX,RDX
JNZ 0x0011b26a
MOV RSI,qword ptr [RBX + 0x28]
MOV RAX,RSI
CQO
IDIV qword ptr [R14 + 0x28]
TEST RDX,RDX
JNZ 0x0011b26a
MOV RAX,qword ptr [R14 + 0x30]
CMP RAX,qword ptr [R14 + 0x38]
JA 0x0011b286
MOV RAX,qword ptr [R14 + 0x18]
MOV RCX,RSP
MOV qword ptr [RCX],RAX
MOV RAX,qword ptr [RBX + 0x18]
MOV qword ptr [RCX + 0x8],RAX
MOV qword ptr [RCX + 0x10],R8
MOV qword ptr [RCX + 0x18],RSI
XOR ESI,ESI
MOV EDX,0x4
XOR R8D,R8D
XOR R9D,R9D
CALL 0x00119c13
MOV dword ptr [RAX + 0x50],0x1b
MOV qword ptr [RAX + 0x98],R14
MOV qword ptr [RAX + 0xa0],RBX
ADD RSP,0x28
POP RBX
POP R14
RET
LAB_0011b26a:
LEA RDI,[0x14a613]
LEA RDX,[0x14a65e]
LEA RCX,[0x14a83b]
MOV ESI,0xab7
JMP 0x0011b2a0
LAB_0011b286:
LEA RDI,[0x14a613]
LEA RDX,[0x14a65e]
LEA RCX,[0x14a852]
MOV ESI,0xab8
LAB_0011b2a0:
XOR EAX,EAX
CALL 0x00117c60
|
void ggml_mul_mat(int8 param_1,long param_2,long param_3)
{
long lVar1;
char *pcVar2;
int8 uVar3;
int8 local_38;
int8 local_30;
long local_28;
long local_20;
if (((*(long *)(param_2 + 0x10) == *(long *)(param_3 + 0x10)) &&
(local_28 = *(long *)(param_3 + 0x20), local_28 % *(long *)(param_2 + 0x20) == 0)) &&
(local_20 = *(long *)(param_3 + 0x28), local_20 % *(long *)(param_2 + 0x28) == 0)) {
if (*(ulong *)(param_2 + 0x30) <= *(ulong *)(param_2 + 0x38)) {
local_38 = *(int8 *)(param_2 + 0x18);
local_30 = *(int8 *)(param_3 + 0x18);
lVar1 = ggml_new_tensor_impl(param_1,0,4,&local_38,0,0);
*(int4 *)(lVar1 + 0x50) = 0x1b;
*(long *)(lVar1 + 0x98) = param_2;
*(long *)(lVar1 + 0xa0) = param_3;
return;
}
pcVar2 = "!ggml_is_transposed(a)";
uVar3 = 0xab8;
}
else {
pcVar2 = "ggml_can_mul_mat(a, b)";
uVar3 = 0xab7;
}
/* WARNING: Subroutine does not return */
ggml_abort("/workspace/llm4binary/github/2025_star3/ngxson[P]ggml-easy/ggml/src/ggml.c",uVar3,
"GGML_ASSERT(%s) failed",pcVar2);
}
| |
38,097 | psi_mutex_trylock | eloqsql/mysys/my_thr_init.c | ATTRIBUTE_COLD int psi_mutex_trylock(mysql_mutex_t *that,
const char *file, uint line)
{
PSI_mutex_locker_state state;
PSI_mutex_locker *locker= PSI_MUTEX_CALL(start_mutex_wait)
(&state, that->m_psi, PSI_MUTEX_TRYLOCK, file, line);
# ifdef SAFE_MUTEX
int result= safe_mutex_lock(&that->m_mutex, TRUE, file, line);
# else
int result= pthread_mutex_trylock(&that->m_mutex);
# endif
if (locker)
PSI_MUTEX_CALL(end_mutex_wait)(locker, result);
return result;
} | O0 | c | psi_mutex_trylock:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
leaq 0x1b4e0e(%rip), %rax # 0x234258
movq (%rax), %rax
movq 0x190(%rax), %rax
movq -0x8(%rbp), %rcx
movq 0x40(%rcx), %rsi
movq -0x10(%rbp), %rcx
movl -0x14(%rbp), %r8d
leaq -0x48(%rbp), %rdi
movl $0x1, %edx
callq *%rax
movq %rax, -0x50(%rbp)
movq -0x8(%rbp), %rdi
callq 0x36430
movl %eax, -0x54(%rbp)
cmpq $0x0, -0x50(%rbp)
je 0x7f4a0
leaq 0x1b4dcb(%rip), %rax # 0x234258
movq (%rax), %rax
movq 0x198(%rax), %rax
movq -0x50(%rbp), %rdi
movl -0x54(%rbp), %esi
callq *%rax
movl -0x54(%rbp), %eax
addq $0x60, %rsp
popq %rbp
retq
nopl (%rax)
| psi_mutex_trylock:
push rbp
mov rbp, rsp
sub rsp, 60h
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov [rbp+var_14], edx
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+190h]
mov rcx, [rbp+var_8]
mov rsi, [rcx+40h]
mov rcx, [rbp+var_10]
mov r8d, [rbp+var_14]
lea rdi, [rbp+var_48]
mov edx, 1
call rax
mov [rbp+var_50], rax
mov rdi, [rbp+var_8]
call _pthread_mutex_trylock
mov [rbp+var_54], eax
cmp [rbp+var_50], 0
jz short loc_7F4A0
lea rax, PSI_server
mov rax, [rax]
mov rax, [rax+198h]
mov rdi, [rbp+var_50]
mov esi, [rbp+var_54]
call rax
loc_7F4A0:
mov eax, [rbp+var_54]
add rsp, 60h
pop rbp
retn
| long long psi_mutex_trylock(long long a1, long long a2, unsigned int a3)
{
unsigned int v4; // [rsp+Ch] [rbp-54h]
long long v5; // [rsp+10h] [rbp-50h]
_BYTE v6[52]; // [rsp+18h] [rbp-48h] BYREF
unsigned int v7; // [rsp+4Ch] [rbp-14h]
long long v8; // [rsp+50h] [rbp-10h]
long long v9; // [rsp+58h] [rbp-8h]
v9 = a1;
v8 = a2;
v7 = a3;
v5 = (*((long long ( **)(_BYTE *, _QWORD, long long, long long, _QWORD))PSI_server + 50))(
v6,
*(_QWORD *)(a1 + 64),
1LL,
a2,
a3);
v4 = pthread_mutex_trylock(v9);
if ( v5 )
(*((void ( **)(long long, _QWORD))PSI_server + 51))(v5, v4);
return v4;
}
| psi_mutex_trylock:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x60
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV dword ptr [RBP + -0x14],EDX
LEA RAX,[0x334258]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x190]
MOV RCX,qword ptr [RBP + -0x8]
MOV RSI,qword ptr [RCX + 0x40]
MOV RCX,qword ptr [RBP + -0x10]
MOV R8D,dword ptr [RBP + -0x14]
LEA RDI,[RBP + -0x48]
MOV EDX,0x1
CALL RAX
MOV qword ptr [RBP + -0x50],RAX
MOV RDI,qword ptr [RBP + -0x8]
CALL 0x00136430
MOV dword ptr [RBP + -0x54],EAX
CMP qword ptr [RBP + -0x50],0x0
JZ 0x0017f4a0
LEA RAX,[0x334258]
MOV RAX,qword ptr [RAX]
MOV RAX,qword ptr [RAX + 0x198]
MOV RDI,qword ptr [RBP + -0x50]
MOV ESI,dword ptr [RBP + -0x54]
CALL RAX
LAB_0017f4a0:
MOV EAX,dword ptr [RBP + -0x54]
ADD RSP,0x60
POP RBP
RET
|
int psi_mutex_trylock(pthread_mutex_t *param_1,int8 param_2,int4 param_3)
{
int iVar1;
long lVar2;
int1 local_50 [52];
int4 local_1c;
int8 local_18;
pthread_mutex_t *local_10;
local_1c = param_3;
local_18 = param_2;
local_10 = param_1;
lVar2 = (**(code **)(PSI_server + 400))
(local_50,*(int8 *)((long)param_1 + 0x40),1,param_2,param_3);
iVar1 = pthread_mutex_trylock(local_10);
if (lVar2 != 0) {
(**(code **)(PSI_server + 0x198))(lVar2,iVar1);
}
return iVar1;
}
| |
38,098 | google::protobuf::Descriptor::GetLocationPath(std::vector<int, std::allocator<int>>*) const | aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/descriptor.cc | void Descriptor::GetLocationPath(std::vector<int>* output) const {
if (containing_type()) {
containing_type()->GetLocationPath(output);
output->push_back(DescriptorProto::kNestedTypeFieldNumber);
output->push_back(index());
} else {
output->push_back(FileDescriptorProto::kMessageTypeFieldNumber);
output->push_back(index());
}
} | O0 | cpp | google::protobuf::Descriptor::GetLocationPath(std::vector<int, std::allocator<int>>*) const:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
movq 0x30(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0x76e70
cmpq $0x0, %rax
je 0x413ba
movq 0x10(%rsp), %rdi
callq 0x76e70
movq %rax, %rdi
movq 0x28(%rsp), %rsi
callq 0x41340
movq 0x28(%rsp), %rdi
movl $0x3, 0x24(%rsp)
leaq 0x24(%rsp), %rsi
callq 0x768b0
movq 0x10(%rsp), %rdi
movq 0x28(%rsp), %rax
movq %rax, 0x8(%rsp)
callq 0x76e80
movq 0x8(%rsp), %rdi
movl %eax, 0x20(%rsp)
leaq 0x20(%rsp), %rsi
callq 0x768b0
jmp 0x413f6
movq 0x28(%rsp), %rdi
movl $0x4, 0x1c(%rsp)
leaq 0x1c(%rsp), %rsi
callq 0x768b0
movq 0x10(%rsp), %rdi
movq 0x28(%rsp), %rax
movq %rax, (%rsp)
callq 0x76e80
movq (%rsp), %rdi
movl %eax, 0x18(%rsp)
leaq 0x18(%rsp), %rsi
callq 0x768b0
addq $0x38, %rsp
retq
nopl (%rax,%rax)
| _ZNK6google8protobuf10Descriptor15GetLocationPathEPSt6vectorIiSaIiEE:
sub rsp, 38h
mov [rsp+38h+var_8], rdi
mov [rsp+38h+var_10], rsi
mov rdi, [rsp+38h+var_8]; this
mov [rsp+38h+var_28], rdi
call _ZNK6google8protobuf10Descriptor15containing_typeEv; google::protobuf::Descriptor::containing_type(void)
cmp rax, 0
jz short loc_413BA
mov rdi, [rsp+38h+var_28]; this
call _ZNK6google8protobuf10Descriptor15containing_typeEv; google::protobuf::Descriptor::containing_type(void)
mov rdi, rax
mov rsi, [rsp+38h+var_10]
call _ZNK6google8protobuf10Descriptor15GetLocationPathEPSt6vectorIiSaIiEE; google::protobuf::Descriptor::GetLocationPath(std::vector<int> *)
mov rdi, [rsp+38h+var_10]
mov [rsp+38h+var_14], 3
lea rsi, [rsp+38h+var_14]
call _ZNSt6vectorIiSaIiEE9push_backEOi; std::vector<int>::push_back(int &&)
mov rdi, [rsp+38h+var_28]; this
mov rax, [rsp+38h+var_10]
mov [rsp+38h+var_30], rax
call _ZNK6google8protobuf10Descriptor5indexEv; google::protobuf::Descriptor::index(void)
mov rdi, [rsp+38h+var_30]
mov [rsp+38h+var_18], eax
lea rsi, [rsp+38h+var_18]
call _ZNSt6vectorIiSaIiEE9push_backEOi; std::vector<int>::push_back(int &&)
jmp short loc_413F6
loc_413BA:
mov rdi, [rsp+38h+var_10]
mov [rsp+38h+var_1C], 4
lea rsi, [rsp+38h+var_1C]
call _ZNSt6vectorIiSaIiEE9push_backEOi; std::vector<int>::push_back(int &&)
mov rdi, [rsp+38h+var_28]; this
mov rax, [rsp+38h+var_10]
mov [rsp+38h+var_38], rax
call _ZNK6google8protobuf10Descriptor5indexEv; google::protobuf::Descriptor::index(void)
mov rdi, [rsp+38h+var_38]
mov [rsp+38h+var_20], eax
lea rsi, [rsp+38h+var_20]
call _ZNSt6vectorIiSaIiEE9push_backEOi; std::vector<int>::push_back(int &&)
loc_413F6:
add rsp, 38h
retn
| long long google::protobuf::Descriptor::GetLocationPath(google::protobuf::Descriptor *a1, long long a2)
{
long long v2; // rax
long long v4; // [rsp+0h] [rbp-38h]
long long v5; // [rsp+8h] [rbp-30h]
int v6; // [rsp+18h] [rbp-20h] BYREF
int v7; // [rsp+1Ch] [rbp-1Ch] BYREF
int v8; // [rsp+20h] [rbp-18h] BYREF
int v9; // [rsp+24h] [rbp-14h] BYREF
long long v10; // [rsp+28h] [rbp-10h]
google::protobuf::Descriptor *v11; // [rsp+30h] [rbp-8h]
v11 = a1;
v10 = a2;
if ( google::protobuf::Descriptor::containing_type(a1) )
{
v2 = google::protobuf::Descriptor::containing_type(a1);
google::protobuf::Descriptor::GetLocationPath(v2, v10);
v9 = 3;
std::vector<int>::push_back(v10, &v9);
v5 = v10;
v8 = google::protobuf::Descriptor::index(a1);
return std::vector<int>::push_back(v5, &v8);
}
else
{
v7 = 4;
std::vector<int>::push_back(v10, &v7);
v4 = v10;
v6 = google::protobuf::Descriptor::index(a1);
return std::vector<int>::push_back(v4, &v6);
}
}
| GetLocationPath:
SUB RSP,0x38
MOV qword ptr [RSP + 0x30],RDI
MOV qword ptr [RSP + 0x28],RSI
MOV RDI,qword ptr [RSP + 0x30]
MOV qword ptr [RSP + 0x10],RDI
CALL 0x00176e70
CMP RAX,0x0
JZ 0x001413ba
MOV RDI,qword ptr [RSP + 0x10]
CALL 0x00176e70
MOV RDI,RAX
MOV RSI,qword ptr [RSP + 0x28]
CALL 0x00141340
MOV RDI,qword ptr [RSP + 0x28]
MOV dword ptr [RSP + 0x24],0x3
LEA RSI,[RSP + 0x24]
CALL 0x001768b0
MOV RDI,qword ptr [RSP + 0x10]
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RSP + 0x8],RAX
CALL 0x00176e80
MOV RDI,qword ptr [RSP + 0x8]
MOV dword ptr [RSP + 0x20],EAX
LEA RSI,[RSP + 0x20]
CALL 0x001768b0
JMP 0x001413f6
LAB_001413ba:
MOV RDI,qword ptr [RSP + 0x28]
MOV dword ptr [RSP + 0x1c],0x4
LEA RSI,[RSP + 0x1c]
CALL 0x001768b0
MOV RDI,qword ptr [RSP + 0x10]
MOV RAX,qword ptr [RSP + 0x28]
MOV qword ptr [RSP],RAX
CALL 0x00176e80
MOV RDI,qword ptr [RSP]
MOV dword ptr [RSP + 0x18],EAX
LEA RSI,[RSP + 0x18]
CALL 0x001768b0
LAB_001413f6:
ADD RSP,0x38
RET
|
/* google::protobuf::Descriptor::GetLocationPath(std::vector<int, std::allocator<int> >*) const */
void __thiscall google::protobuf::Descriptor::GetLocationPath(Descriptor *this,vector *param_1)
{
vector<int,std::allocator<int>> *pvVar1;
long lVar2;
Descriptor *this_00;
int local_20 [3];
int local_14;
vector<int,std::allocator<int>> *local_10;
Descriptor *local_8;
local_10 = (vector<int,std::allocator<int>> *)param_1;
local_8 = this;
lVar2 = containing_type(this);
if (lVar2 == 0) {
local_20[1] = 4;
std::vector<int,std::allocator<int>>::push_back(local_10,local_20 + 1);
pvVar1 = local_10;
local_20[0] = index(this);
std::vector<int,std::allocator<int>>::push_back(pvVar1,local_20);
}
else {
this_00 = (Descriptor *)containing_type(this);
GetLocationPath(this_00,(vector *)local_10);
local_14 = 3;
std::vector<int,std::allocator<int>>::push_back(local_10,&local_14);
pvVar1 = local_10;
local_20[2] = index(this);
std::vector<int,std::allocator<int>>::push_back(pvVar1,local_20 + 2);
}
return;
}
| |
38,099 | my_thread_init | eloqsql/mysys/my_thr_init.c | my_bool my_thread_init(void)
{
struct st_my_thread_var *tmp;
my_bool error=0;
if (!my_thread_global_init_done)
return 1; /* cannot proceed with uninitialized library */
#ifdef EXTRA_DEBUG_THREADS
fprintf(stderr,"my_thread_init(): pthread_self: %p\n", pthread_self());
#endif
if (my_thread_var)
{
#ifdef EXTRA_DEBUG_THREADS
fprintf(stderr,"my_thread_init() called more than once in thread 0x%lx\n",
(long) pthread_self());
#endif
goto end;
}
#ifdef _MSC_VER
install_sigabrt_handler();
#endif
if (!(tmp= (struct st_my_thread_var *) calloc(1, sizeof(*tmp))))
{
error= 1;
goto end;
}
set_mysys_var(tmp);
tmp->pthread_self= pthread_self();
my_thread_init_thr_mutex(tmp);
tmp->stack_ends_here= (char*)&tmp +
STACK_DIRECTION * (long)my_thread_stack_size;
mysql_mutex_lock(&THR_LOCK_threads);
tmp->id= tmp->dbug_id= ++thread_id;
++THR_thread_count;
mysql_mutex_unlock(&THR_LOCK_threads);
tmp->init= 1;
#ifndef DBUG_OFF
/* Generate unique name for thread */
(void) my_thread_name();
#endif
end:
return error;
} | O3 | c | my_thread_init:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movb $0x1, %bl
cmpb $0x1, 0xb671f8(%rip) # 0xc089f0
jne 0xa18d1
leaq 0xb671ef(%rip), %r15 # 0xc089f4
movl (%r15), %edi
callq 0x29860
testq %rax, %rax
jne 0xa18cf
movl $0x1, %edi
movl $0xf0, %esi
callq 0x296e0
movq %rax, -0x20(%rbp)
testq %rax, %rax
je 0xa18d1
movq %rax, %r14
movl (%r15), %edi
movq %rax, %rsi
callq 0x29310
callq 0x29580
movq %rax, 0xc8(%r14)
movq %r14, %rdi
callq 0xa16ef
leaq 0x2e3f75(%rip), %rax # 0x3857d0
leaq -0x20(%rbp), %rcx
addq (%rax), %rcx
movq %rcx, 0xb8(%r14)
leaq 0xb670b8(%rip), %rbx # 0xc08928
cmpq $0x0, 0x40(%rbx)
jne 0xa18de
leaq 0xb670aa(%rip), %rdi # 0xc08928
callq 0x29220
movq 0xb6716e(%rip), %rax # 0xc089f8
incq %rax
movq %rax, 0xb67164(%rip) # 0xc089f8
movq -0x20(%rbp), %rcx
movq %rax, 0xd8(%rcx)
movq %rax, 0xd0(%rcx)
leaq 0xb66e7b(%rip), %rax # 0xc08728
incl (%rax)
movq 0x40(%rbx), %rdi
testq %rdi, %rdi
jne 0xa18e5
leaq 0xb67069(%rip), %rdi # 0xc08928
callq 0x291e0
movq -0x20(%rbp), %rax
movb $0x1, 0xe8(%rax)
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
callq 0x2efac
jmp 0xa1883
leaq 0x2e4724(%rip), %rax # 0x386010
movq (%rax), %rax
callq *0x160(%rax)
jmp 0xa18b8
| my_thread_init:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
push rax
mov bl, 1
cmp cs:my_thread_global_init_done, 1
jnz loc_A18D1
lea r15, THR_KEY_mysys
mov edi, [r15]
call _pthread_getspecific
test rax, rax
jnz loc_A18CF
mov edi, 1
mov esi, 0F0h
call _calloc
mov [rbp+var_20], rax
test rax, rax
jz loc_A18D1
mov r14, rax
mov edi, [r15]
mov rsi, rax
call _pthread_setspecific
call _pthread_self
mov [r14+0C8h], rax
mov rdi, r14
call my_thread_init_thr_mutex
lea rax, my_thread_stack_size
lea rcx, [rbp+var_20]
add rcx, [rax]
mov [r14+0B8h], rcx
lea rbx, THR_LOCK_threads
cmp qword ptr [rbx+40h], 0
jnz short loc_A18DE
lea rdi, THR_LOCK_threads
call _pthread_mutex_lock
loc_A1883:
mov rax, cs:thread_id
inc rax
mov cs:thread_id, rax
mov rcx, [rbp+var_20]
mov [rcx+0D8h], rax
mov [rcx+0D0h], rax
lea rax, THR_thread_count
inc dword ptr [rax]
mov rdi, [rbx+40h]
test rdi, rdi
jnz short loc_A18E5
loc_A18B8:
lea rdi, THR_LOCK_threads
call _pthread_mutex_unlock
mov rax, [rbp+var_20]
mov byte ptr [rax+0E8h], 1
loc_A18CF:
xor ebx, ebx
loc_A18D1:
mov eax, ebx
add rsp, 8
pop rbx
pop r14
pop r15
pop rbp
retn
loc_A18DE:
call my_thread_init_cold_1
jmp short loc_A1883
loc_A18E5:
lea rax, PSI_server
mov rax, [rax]
call qword ptr [rax+160h]
jmp short loc_A18B8
| long long my_thread_init()
{
long long v0; // rax
unsigned int v1; // ebx
long long v2; // rax
long long v3; // r14
long long v4; // rdi
long long v5; // rax
long long v6; // rcx
_QWORD v8[4]; // [rsp+0h] [rbp-20h] BYREF
v8[0] = v0;
LOBYTE(v1) = 1;
if ( my_thread_global_init_done == 1 )
{
if ( pthread_getspecific(THR_KEY_mysys) )
return 0;
v2 = calloc(1LL, 240LL);
v8[0] = v2;
if ( v2 )
{
v3 = v2;
v4 = THR_KEY_mysys;
pthread_setspecific(THR_KEY_mysys, v2);
*(_QWORD *)(v3 + 200) = pthread_self(v4);
my_thread_init_thr_mutex(v3);
*(_QWORD *)(v3 + 184) = (char *)v8 + my_thread_stack_size;
if ( THR_LOCK_threads[8] )
my_thread_init_cold_1();
else
pthread_mutex_lock(THR_LOCK_threads);
v5 = thread_id + 1;
thread_id = v5;
v6 = v8[0];
*(_QWORD *)(v8[0] + 216LL) = v5;
*(_QWORD *)(v6 + 208) = v5;
++THR_thread_count;
if ( THR_LOCK_threads[8] )
PSI_server[44]();
pthread_mutex_unlock(THR_LOCK_threads);
*(_BYTE *)(v8[0] + 232LL) = 1;
return 0;
}
}
return v1;
}
| my_thread_init:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
PUSH RAX
MOV BL,0x1
CMP byte ptr [0x00d089f0],0x1
JNZ 0x001a18d1
LEA R15,[0xd089f4]
MOV EDI,dword ptr [R15]
CALL 0x00129860
TEST RAX,RAX
JNZ 0x001a18cf
MOV EDI,0x1
MOV ESI,0xf0
CALL 0x001296e0
MOV qword ptr [RBP + -0x20],RAX
TEST RAX,RAX
JZ 0x001a18d1
MOV R14,RAX
MOV EDI,dword ptr [R15]
MOV RSI,RAX
CALL 0x00129310
CALL 0x00129580
MOV qword ptr [R14 + 0xc8],RAX
MOV RDI,R14
CALL 0x001a16ef
LEA RAX,[0x4857d0]
LEA RCX,[RBP + -0x20]
ADD RCX,qword ptr [RAX]
MOV qword ptr [R14 + 0xb8],RCX
LEA RBX,[0xd08928]
CMP qword ptr [RBX + 0x40],0x0
JNZ 0x001a18de
LEA RDI,[0xd08928]
CALL 0x00129220
LAB_001a1883:
MOV RAX,qword ptr [0x00d089f8]
INC RAX
MOV qword ptr [0x00d089f8],RAX
MOV RCX,qword ptr [RBP + -0x20]
MOV qword ptr [RCX + 0xd8],RAX
MOV qword ptr [RCX + 0xd0],RAX
LEA RAX,[0xd08728]
INC dword ptr [RAX]
MOV RDI,qword ptr [RBX + 0x40]
TEST RDI,RDI
JNZ 0x001a18e5
LAB_001a18b8:
LEA RDI,[0xd08928]
CALL 0x001291e0
MOV RAX,qword ptr [RBP + -0x20]
MOV byte ptr [RAX + 0xe8],0x1
LAB_001a18cf:
XOR EBX,EBX
LAB_001a18d1:
MOV EAX,EBX
ADD RSP,0x8
POP RBX
POP R14
POP R15
POP RBP
RET
LAB_001a18de:
CALL 0x0012efac
JMP 0x001a1883
LAB_001a18e5:
LEA RAX,[0x486010]
MOV RAX,qword ptr [RAX]
CALL qword ptr [RAX + 0x160]
JMP 0x001a18b8
|
ulong my_thread_init(void)
{
void *pvVar1;
pthread_t pVar2;
long lVar3;
int8 unaff_RBX;
ulong uVar4;
void *local_28;
uVar4 = CONCAT71((int7)((ulong)unaff_RBX >> 8),1);
if (my_thread_global_init_done == '\x01') {
pvVar1 = pthread_getspecific(THR_KEY_mysys);
if (pvVar1 == (void *)0x0) {
pvVar1 = calloc(1,0xf0);
if (pvVar1 == (void *)0x0) goto LAB_001a18d1;
local_28 = pvVar1;
pthread_setspecific(THR_KEY_mysys,pvVar1);
pVar2 = pthread_self();
*(pthread_t *)((long)pvVar1 + 200) = pVar2;
my_thread_init_thr_mutex(pvVar1);
*(long *)((long)pvVar1 + 0xb8) = (long)&local_28 + my_thread_stack_size;
if (THR_LOCK_threads._64_8_ == 0) {
pthread_mutex_lock((pthread_mutex_t *)THR_LOCK_threads);
}
else {
my_thread_init_cold_1();
}
lVar3 = thread_id + 1;
thread_id = lVar3;
*(long *)((long)local_28 + 0xd8) = lVar3;
*(long *)((long)local_28 + 0xd0) = lVar3;
THR_thread_count = THR_thread_count + 1;
if (THR_LOCK_threads._64_8_ != 0) {
(**(code **)(PSI_server + 0x160))();
}
pthread_mutex_unlock((pthread_mutex_t *)THR_LOCK_threads);
*(int1 *)((long)local_28 + 0xe8) = 1;
}
uVar4 = 0;
}
LAB_001a18d1:
return uVar4 & 0xffffffff;
}
|
Subsets and Splits
C++ Functions With Standard Library Dependencies
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++ Standard Library Function Analysis
Filters C++ code examples that use standard library containers and types, providing useful insights into common programming patterns and data structures in the dataset.
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.