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
3,500
ggml_reshape
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c
struct ggml_tensor * ggml_reshape( struct ggml_context * ctx, struct ggml_tensor * a, struct ggml_tensor * b) { GGML_ASSERT(ggml_is_contiguous(a)); // as only the shape of b is relevant, and not its memory layout, b is allowed to be non contiguous. GGML_ASSERT(ggml_nelements(a) == ggml_nelements(b)); struct ggml_tensor * result = ggml_new_tensor_impl(ctx, a->type, GGML_MAX_DIMS, b->ne, a, 0); ggml_format_name(result, "%s (reshaped)", a->name); result->op = GGML_OP_RESHAPE; result->src[0] = a; return result; }
O3
c
ggml_reshape: pushq %r15 pushq %r14 pushq %rbx movq %rdx, %r14 movq %rsi, %rbx movq %rdi, %r15 movq %rsi, %rdi xorl %esi, %esi callq 0x1a0b9 testb %al, %al je 0x1c3f1 movq 0x18(%rbx), %rax imulq 0x10(%rbx), %rax imulq 0x20(%rbx), %rax imulq 0x28(%rbx), %rax movq 0x18(%r14), %rcx imulq 0x10(%r14), %rcx imulq 0x20(%r14), %rcx imulq 0x28(%r14), %rcx cmpq %rcx, %rax jne 0x1c40d addq $0x10, %r14 movl (%rbx), %esi movq %r15, %rdi movl $0x4, %edx movq %r14, %rcx movq %rbx, %r8 xorl %r9d, %r9d callq 0x1a57f movq %rax, %r14 leaq 0x100(%rbx), %rdx leaq 0x30692(%rip), %rsi # 0x4ca61 movq %rax, %rdi xorl %eax, %eax callq 0x17a60 movl $0x21, 0x50(%r14) movq %rbx, 0x98(%r14) movq %r14, %rax popq %rbx popq %r14 popq %r15 retq leaq 0x3021b(%rip), %rdi # 0x4c613 leaq 0x30266(%rip), %rdx # 0x4c665 leaq 0x3061e(%rip), %rcx # 0x4ca24 movl $0xbc6, %esi # imm = 0xBC6 jmp 0x1c427 leaq 0x301ff(%rip), %rdi # 0x4c613 leaq 0x3024a(%rip), %rdx # 0x4c665 leaq 0x30618(%rip), %rcx # 0x4ca3a movl $0xbc8, %esi # imm = 0xBC8 xorl %eax, %eax callq 0x17cd0
ggml_reshape: push r15 push r14 push rbx mov r14, rdx mov rbx, rsi mov r15, rdi mov rdi, rsi xor esi, esi call ggml_is_contiguous_n test al, al jz short loc_1C3F1 mov rax, [rbx+18h] imul rax, [rbx+10h] imul rax, [rbx+20h] imul rax, [rbx+28h] mov rcx, [r14+18h] imul rcx, [r14+10h] imul rcx, [r14+20h] imul rcx, [r14+28h] cmp rax, rcx jnz short loc_1C40D add r14, 10h mov esi, [rbx] mov rdi, r15 mov edx, 4 mov rcx, r14 mov r8, rbx xor r9d, r9d call ggml_new_tensor_impl mov r14, rax lea rdx, [rbx+100h] lea rsi, aSReshaped; "%s (reshaped)" mov rdi, rax xor eax, eax call _ggml_format_name mov dword ptr [r14+50h], 21h ; '!' mov [r14+98h], rbx mov rax, r14 pop rbx pop r14 pop r15 retn loc_1C3F1: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aGgmlIsContiguo_3; "ggml_is_contiguous(a)" mov esi, 0BC6h jmp short loc_1C427 loc_1C40D: lea rdi, aWorkspaceLlm4b; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aGgmlNelementsA_0; "ggml_nelements(a) == ggml_nelements(b)" mov esi, 0BC8h loc_1C427: xor eax, eax call _ggml_abort
long long ggml_reshape(long long a1, long long a2, long long *a3, double a4) { int v5; // r8d int v6; // r9d long long v7; // r14 const char *v9; // rcx int v10; // esi if ( !ggml_is_contiguous_n((unsigned int *)a2, 0) ) { v9 = "ggml_is_contiguous(a)"; v10 = 3014; goto LABEL_6; } if ( *(_QWORD *)(a2 + 40) * *(_QWORD *)(a2 + 32) * *(_QWORD *)(a2 + 16) * *(_QWORD *)(a2 + 24) != a3[5] * a3[4] * a3[2] * a3[3] ) { v9 = "ggml_nelements(a) == ggml_nelements(b)"; v10 = 3016; LABEL_6: ggml_abort( (unsigned int)"/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", v10, (unsigned int)"GGML_ASSERT(%s) failed", (_DWORD)v9, v5, v6); } v7 = ggml_new_tensor_impl(a1, *(_DWORD *)a2, 4u, a3 + 2, a2, 0LL, a4); ggml_format_name(v7, (long long)"%s (reshaped)"); *(_DWORD *)(v7 + 80) = 33; *(_QWORD *)(v7 + 152) = a2; return v7; }
ggml_reshape: PUSH R15 PUSH R14 PUSH RBX MOV R14,RDX MOV RBX,RSI MOV R15,RDI MOV RDI,RSI XOR ESI,ESI CALL 0x0011a0b9 TEST AL,AL JZ 0x0011c3f1 MOV RAX,qword ptr [RBX + 0x18] IMUL RAX,qword ptr [RBX + 0x10] IMUL RAX,qword ptr [RBX + 0x20] IMUL RAX,qword ptr [RBX + 0x28] MOV RCX,qword ptr [R14 + 0x18] IMUL RCX,qword ptr [R14 + 0x10] IMUL RCX,qword ptr [R14 + 0x20] IMUL RCX,qword ptr [R14 + 0x28] CMP RAX,RCX JNZ 0x0011c40d ADD R14,0x10 MOV ESI,dword ptr [RBX] MOV RDI,R15 MOV EDX,0x4 MOV RCX,R14 MOV R8,RBX XOR R9D,R9D CALL 0x0011a57f MOV R14,RAX LEA RDX,[RBX + 0x100] LEA RSI,[0x14ca61] MOV RDI,RAX XOR EAX,EAX CALL 0x00117a60 MOV dword ptr [R14 + 0x50],0x21 MOV qword ptr [R14 + 0x98],RBX MOV RAX,R14 POP RBX POP R14 POP R15 RET LAB_0011c3f1: LEA RDI,[0x14c613] LEA RDX,[0x14c665] LEA RCX,[0x14ca24] MOV ESI,0xbc6 JMP 0x0011c427 LAB_0011c40d: LEA RDI,[0x14c613] LEA RDX,[0x14c665] LEA RCX,[0x14ca3a] MOV ESI,0xbc8 LAB_0011c427: XOR EAX,EAX CALL 0x00117cd0
long ggml_reshape(int8 param_1,int4 *param_2,long param_3) { char cVar1; long lVar2; char *pcVar3; int8 uVar4; cVar1 = ggml_is_contiguous_n(param_2,0); if (cVar1 == '\0') { pcVar3 = "ggml_is_contiguous(a)"; uVar4 = 0xbc6; } else { if (*(long *)(param_2 + 6) * *(long *)(param_2 + 4) * *(long *)(param_2 + 8) * *(long *)(param_2 + 10) - *(long *)(param_3 + 0x18) * *(long *)(param_3 + 0x10) * *(long *)(param_3 + 0x20) * *(long *)(param_3 + 0x28) == 0) { lVar2 = ggml_new_tensor_impl(param_1,*param_2,4,param_3 + 0x10,param_2,0); ggml_format_name(lVar2,"%s (reshaped)",param_2 + 0x40); *(int4 *)(lVar2 + 0x50) = 0x21; *(int4 **)(lVar2 + 0x98) = param_2; return lVar2; } pcVar3 = "ggml_nelements(a) == ggml_nelements(b)"; uVar4 = 0xbc8; } /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml.c", uVar4,"GGML_ASSERT(%s) failed",pcVar3); }
3,501
js_map_set
bluesky950520[P]quickjs/quickjs.c
static JSValue js_map_set(JSContext *ctx, JSValue this_val, int argc, JSValue *argv, int magic) { JSMapState *s = JS_GetOpaque2(ctx, this_val, JS_CLASS_MAP + magic); JSMapRecord *mr; JSValue key, value; int is_set; if (!s) return JS_EXCEPTION; is_set = (magic & MAGIC_SET); key = map_normalize_key(ctx, argv[0]); if (s->is_weak && !is_valid_weakref_target(key)) return JS_ThrowTypeError(ctx, "invalid value used as %s key", is_set ? "WeakSet" : "WeakMap"); if (is_set) value = JS_UNDEFINED; else value = argv[1]; mr = map_find_record(ctx, s, key); if (mr) { JS_FreeValue(ctx, mr->value); } else { mr = map_add_record(ctx, s, key); if (!mr) return JS_EXCEPTION; } mr->value = js_dup(value); return js_dup(this_val); }
O0
c
js_map_set: subq $0xb8, %rsp movq %rsi, 0x98(%rsp) movq %rdx, 0xa0(%rsp) movq %rdi, 0x90(%rsp) movl %ecx, 0x8c(%rsp) movq %r8, 0x80(%rsp) movl %r9d, 0x7c(%rsp) movq 0x90(%rsp), %rdi movl 0x7c(%rsp), %ecx addl $0x23, %ecx movq 0x98(%rsp), %rsi movq 0xa0(%rsp), %rdx callq 0x3e6a0 movq %rax, 0x70(%rsp) cmpq $0x0, 0x70(%rsp) jne 0x83ca0 movl $0x0, 0xa8(%rsp) movq $0x6, 0xb0(%rsp) jmp 0x83e7a movl 0x7c(%rsp), %eax andl $0x1, %eax movl %eax, 0x44(%rsp) movq 0x90(%rsp), %rdi movq 0x80(%rsp), %rax movq (%rax), %rsi movq 0x8(%rax), %rdx callq 0x83ea0 movq %rax, 0x30(%rsp) movq %rdx, 0x38(%rsp) movq 0x30(%rsp), %rax movq %rax, 0x58(%rsp) movq 0x38(%rsp), %rax movq %rax, 0x60(%rsp) movq 0x70(%rsp), %rax cmpl $0x0, (%rax) je 0x83d47 movq 0x58(%rsp), %rdi movq 0x60(%rsp), %rsi callq 0x83f10 cmpl $0x0, %eax jne 0x83d47 movq 0x90(%rsp), %rdi movl 0x44(%rsp), %ecx leaq 0x90fae(%rip), %rdx # 0x114cc4 leaq 0x90f9f(%rip), %rax # 0x114cbc cmpl $0x0, %ecx cmovneq %rax, %rdx leaq 0x90f74(%rip), %rsi # 0x114c9f movb $0x0, %al callq 0x335f0 movq %rax, 0xa8(%rsp) movq %rdx, 0xb0(%rsp) jmp 0x83e7a cmpl $0x0, 0x44(%rsp) je 0x83d75 movl $0x0, 0x20(%rsp) movq $0x3, 0x28(%rsp) movq 0x20(%rsp), %rax movq %rax, 0x48(%rsp) movq 0x28(%rsp), %rax movq %rax, 0x50(%rsp) jmp 0x83d8f movq 0x80(%rsp), %rax movq 0x10(%rax), %rcx movq %rcx, 0x48(%rsp) movq 0x18(%rax), %rax movq %rax, 0x50(%rsp) movq 0x90(%rsp), %rdi movq 0x70(%rsp), %rsi movq 0x58(%rsp), %rdx movq 0x60(%rsp), %rcx callq 0x83f70 movq %rax, 0x68(%rsp) cmpq $0x0, 0x68(%rsp) je 0x83dd4 movq 0x90(%rsp), %rdi movq 0x68(%rsp), %rax movq 0x40(%rax), %rsi movq 0x48(%rax), %rdx callq 0x29f80 jmp 0x83e18 movq 0x90(%rsp), %rdi movq 0x70(%rsp), %rsi movq 0x58(%rsp), %rdx movq 0x60(%rsp), %rcx callq 0x84050 movq %rax, 0x68(%rsp) cmpq $0x0, 0x68(%rsp) jne 0x83e16 movl $0x0, 0xa8(%rsp) movq $0x6, 0xb0(%rsp) jmp 0x83e7a jmp 0x83e18 movq 0x68(%rsp), %rax movq %rax, 0x8(%rsp) movq 0x48(%rsp), %rdi movq 0x50(%rsp), %rsi callq 0x279c0 movq %rax, %rcx movq 0x8(%rsp), %rax movq %rcx, 0x10(%rsp) movq %rdx, 0x18(%rsp) movq 0x10(%rsp), %rcx movq %rcx, 0x40(%rax) movq 0x18(%rsp), %rcx movq %rcx, 0x48(%rax) movq 0x98(%rsp), %rdi movq 0xa0(%rsp), %rsi callq 0x279c0 movq %rax, 0xa8(%rsp) movq %rdx, 0xb0(%rsp) movq 0xa8(%rsp), %rax movq 0xb0(%rsp), %rdx addq $0xb8, %rsp retq nopw %cs:(%rax,%rax)
js_map_set: sub rsp, 0B8h mov [rsp+0B8h+var_20], rsi mov [rsp+0B8h+var_18], rdx mov [rsp+0B8h+var_28], rdi mov [rsp+0B8h+var_2C], ecx mov [rsp+0B8h+var_38], r8 mov [rsp+0B8h+var_3C], r9d mov rdi, [rsp+0B8h+var_28] mov ecx, [rsp+0B8h+var_3C] add ecx, 23h ; '#' mov rsi, [rsp+0B8h+var_20] mov rdx, [rsp+0B8h+var_18] call JS_GetOpaque2 mov [rsp+0B8h+var_48], rax cmp [rsp+0B8h+var_48], 0 jnz short loc_83CA0 mov dword ptr [rsp+0B8h+var_10], 0 mov [rsp+0B8h+var_8], 6 jmp loc_83E7A loc_83CA0: mov eax, [rsp+0B8h+var_3C] and eax, 1 mov [rsp+0B8h+var_74], eax mov rdi, [rsp+0B8h+var_28] mov rax, [rsp+0B8h+var_38] mov rsi, [rax] mov rdx, [rax+8] call map_normalize_key mov [rsp+0B8h+var_88], rax mov [rsp+0B8h+var_80], rdx mov rax, [rsp+0B8h+var_88] mov [rsp+0B8h+var_60], rax mov rax, [rsp+0B8h+var_80] mov [rsp+0B8h+var_58], rax mov rax, [rsp+0B8h+var_48] cmp dword ptr [rax], 0 jz short loc_83D47 mov rdi, [rsp+0B8h+var_60] mov rsi, [rsp+0B8h+var_58] call is_valid_weakref_target cmp eax, 0 jnz short loc_83D47 mov rdi, [rsp+0B8h+var_28] mov ecx, [rsp+0B8h+var_74] lea rdx, aWeakmap; "WeakMap" lea rax, aWeakset; "WeakSet" cmp ecx, 0 cmovnz rdx, rax lea rsi, aInvalidValueUs; "invalid value used as %s key" mov al, 0 call JS_ThrowTypeError mov [rsp+0B8h+var_10], rax mov [rsp+0B8h+var_8], rdx jmp loc_83E7A loc_83D47: cmp [rsp+0B8h+var_74], 0 jz short loc_83D75 mov dword ptr [rsp+0B8h+var_98], 0 mov [rsp+0B8h+var_90], 3 mov rax, [rsp+0B8h+var_98] mov [rsp+0B8h+var_70], rax mov rax, [rsp+0B8h+var_90] mov [rsp+0B8h+var_68], rax jmp short loc_83D8F loc_83D75: mov rax, [rsp+0B8h+var_38] mov rcx, [rax+10h] mov [rsp+0B8h+var_70], rcx mov rax, [rax+18h] mov [rsp+0B8h+var_68], rax loc_83D8F: mov rdi, [rsp+0B8h+var_28] mov rsi, [rsp+0B8h+var_48] mov rdx, [rsp+0B8h+var_60] mov rcx, [rsp+0B8h+var_58] call map_find_record mov [rsp+0B8h+var_50], rax cmp [rsp+0B8h+var_50], 0 jz short loc_83DD4 mov rdi, [rsp+0B8h+var_28] mov rax, [rsp+0B8h+var_50] mov rsi, [rax+40h] mov rdx, [rax+48h] call JS_FreeValue jmp short loc_83E18 loc_83DD4: mov rdi, [rsp+0B8h+var_28] mov rsi, [rsp+0B8h+var_48] mov rdx, [rsp+0B8h+var_60] mov rcx, [rsp+0B8h+var_58] call map_add_record mov [rsp+0B8h+var_50], rax cmp [rsp+0B8h+var_50], 0 jnz short loc_83E16 mov dword ptr [rsp+0B8h+var_10], 0 mov [rsp+0B8h+var_8], 6 jmp short loc_83E7A loc_83E16: jmp short $+2 loc_83E18: mov rax, [rsp+0B8h+var_50] mov [rsp+0B8h+var_B0], rax mov rdi, [rsp+0B8h+var_70] mov rsi, [rsp+0B8h+var_68] call js_dup mov rcx, rax mov rax, [rsp+0B8h+var_B0] mov [rsp+0B8h+var_A8], rcx mov [rsp+0B8h+var_A0], rdx mov rcx, [rsp+0B8h+var_A8] mov [rax+40h], rcx mov rcx, [rsp+0B8h+var_A0] mov [rax+48h], rcx mov rdi, [rsp+0B8h+var_20] mov rsi, [rsp+0B8h+var_18] call js_dup mov [rsp+0B8h+var_10], rax mov [rsp+0B8h+var_8], rdx loc_83E7A: mov rax, [rsp+0B8h+var_10] mov rdx, [rsp+0B8h+var_8] add rsp, 0B8h retn
_DWORD * js_map_set( long long a1, _DWORD *a2, unsigned int a3, __m128 a4, __m128 a5, __m128 a6, __m128 a7, double a8, double a9, __m128 a10, __m128 a11, long long a12, _QWORD *a13, int a14) { long long v14; // rdx long long v15; // r8 long long v16; // r9 __m128 v17; // xmm4 __m128 v18; // xmm5 const char *v19; // rdx long long v20; // rdx char v22; // [rsp+0h] [rbp-B8h] _DWORD *v23; // [rsp+20h] [rbp-98h] long long v24; // [rsp+30h] [rbp-88h] _DWORD *v25; // [rsp+48h] [rbp-70h] long long v26; // [rsp+50h] [rbp-68h] long long v27; // [rsp+60h] [rbp-58h] long long record; // [rsp+68h] [rbp-50h] _DWORD *Opaque2; // [rsp+70h] [rbp-48h] char v30; // [rsp+7Ch] [rbp-3Ch] long long v33; // [rsp+A8h] [rbp-10h] v30 = a14; Opaque2 = (_DWORD *)JS_GetOpaque2(a1, (long long)a2, a3, a14 + 35); if ( Opaque2 ) { v24 = map_normalize_key(a1, *a13, a13[1]); v27 = v14; if ( !*Opaque2 || (unsigned int)is_valid_weakref_target(v24, v14) ) { if ( (v30 & 1) != 0 ) { LODWORD(v23) = 0; v25 = v23; LODWORD(v26) = 3; } else { v25 = (_DWORD *)a13[2]; v26 = a13[3]; } record = map_find_record(a1, Opaque2, v24, v27); if ( record ) { JS_FreeValue(a1, *(_QWORD *)(record + 64), *(_QWORD *)(record + 72)); } else { record = map_add_record(a1, Opaque2, v24, v27); if ( !record ) { LODWORD(v33) = 0; return (_DWORD *)v33; } } *(_QWORD *)(record + 64) = js_dup(v25, v26); *(_QWORD *)(record + 72) = v20; return js_dup(a2, a3); } v19 = "WeakMap"; if ( (v30 & 1) != 0 ) v19 = "WeakSet"; return (_DWORD *)JS_ThrowTypeError( a1, (long long)"invalid value used as %s key", (long long)v19, v30 & 1, v15, v16, a4, a5, a6, a7, v17, v18, a10, a11, v22); } else { LODWORD(v33) = 0; } return (_DWORD *)v33; }
js_map_set: SUB RSP,0xb8 MOV qword ptr [RSP + 0x98],RSI MOV qword ptr [RSP + 0xa0],RDX MOV qword ptr [RSP + 0x90],RDI MOV dword ptr [RSP + 0x8c],ECX MOV qword ptr [RSP + 0x80],R8 MOV dword ptr [RSP + 0x7c],R9D MOV RDI,qword ptr [RSP + 0x90] MOV ECX,dword ptr [RSP + 0x7c] ADD ECX,0x23 MOV RSI,qword ptr [RSP + 0x98] MOV RDX,qword ptr [RSP + 0xa0] CALL 0x0013e6a0 MOV qword ptr [RSP + 0x70],RAX CMP qword ptr [RSP + 0x70],0x0 JNZ 0x00183ca0 MOV dword ptr [RSP + 0xa8],0x0 MOV qword ptr [RSP + 0xb0],0x6 JMP 0x00183e7a LAB_00183ca0: MOV EAX,dword ptr [RSP + 0x7c] AND EAX,0x1 MOV dword ptr [RSP + 0x44],EAX MOV RDI,qword ptr [RSP + 0x90] MOV RAX,qword ptr [RSP + 0x80] MOV RSI,qword ptr [RAX] MOV RDX,qword ptr [RAX + 0x8] CALL 0x00183ea0 MOV qword ptr [RSP + 0x30],RAX MOV qword ptr [RSP + 0x38],RDX MOV RAX,qword ptr [RSP + 0x30] MOV qword ptr [RSP + 0x58],RAX MOV RAX,qword ptr [RSP + 0x38] MOV qword ptr [RSP + 0x60],RAX MOV RAX,qword ptr [RSP + 0x70] CMP dword ptr [RAX],0x0 JZ 0x00183d47 MOV RDI,qword ptr [RSP + 0x58] MOV RSI,qword ptr [RSP + 0x60] CALL 0x00183f10 CMP EAX,0x0 JNZ 0x00183d47 MOV RDI,qword ptr [RSP + 0x90] MOV ECX,dword ptr [RSP + 0x44] LEA RDX,[0x214cc4] LEA RAX,[0x214cbc] CMP ECX,0x0 CMOVNZ RDX,RAX LEA RSI,[0x214c9f] MOV AL,0x0 CALL 0x001335f0 MOV qword ptr [RSP + 0xa8],RAX MOV qword ptr [RSP + 0xb0],RDX JMP 0x00183e7a LAB_00183d47: CMP dword ptr [RSP + 0x44],0x0 JZ 0x00183d75 MOV dword ptr [RSP + 0x20],0x0 MOV qword ptr [RSP + 0x28],0x3 MOV RAX,qword ptr [RSP + 0x20] MOV qword ptr [RSP + 0x48],RAX MOV RAX,qword ptr [RSP + 0x28] MOV qword ptr [RSP + 0x50],RAX JMP 0x00183d8f LAB_00183d75: MOV RAX,qword ptr [RSP + 0x80] MOV RCX,qword ptr [RAX + 0x10] MOV qword ptr [RSP + 0x48],RCX MOV RAX,qword ptr [RAX + 0x18] MOV qword ptr [RSP + 0x50],RAX LAB_00183d8f: MOV RDI,qword ptr [RSP + 0x90] MOV RSI,qword ptr [RSP + 0x70] MOV RDX,qword ptr [RSP + 0x58] MOV RCX,qword ptr [RSP + 0x60] CALL 0x00183f70 MOV qword ptr [RSP + 0x68],RAX CMP qword ptr [RSP + 0x68],0x0 JZ 0x00183dd4 MOV RDI,qword ptr [RSP + 0x90] MOV RAX,qword ptr [RSP + 0x68] MOV RSI,qword ptr [RAX + 0x40] MOV RDX,qword ptr [RAX + 0x48] CALL 0x00129f80 JMP 0x00183e18 LAB_00183dd4: MOV RDI,qword ptr [RSP + 0x90] MOV RSI,qword ptr [RSP + 0x70] MOV RDX,qword ptr [RSP + 0x58] MOV RCX,qword ptr [RSP + 0x60] CALL 0x00184050 MOV qword ptr [RSP + 0x68],RAX CMP qword ptr [RSP + 0x68],0x0 JNZ 0x00183e16 MOV dword ptr [RSP + 0xa8],0x0 MOV qword ptr [RSP + 0xb0],0x6 JMP 0x00183e7a LAB_00183e16: JMP 0x00183e18 LAB_00183e18: MOV RAX,qword ptr [RSP + 0x68] MOV qword ptr [RSP + 0x8],RAX MOV RDI,qword ptr [RSP + 0x48] MOV RSI,qword ptr [RSP + 0x50] CALL 0x001279c0 MOV RCX,RAX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RSP + 0x10],RCX MOV qword ptr [RSP + 0x18],RDX MOV RCX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0x40],RCX MOV RCX,qword ptr [RSP + 0x18] MOV qword ptr [RAX + 0x48],RCX MOV RDI,qword ptr [RSP + 0x98] MOV RSI,qword ptr [RSP + 0xa0] CALL 0x001279c0 MOV qword ptr [RSP + 0xa8],RAX MOV qword ptr [RSP + 0xb0],RDX LAB_00183e7a: MOV RAX,qword ptr [RSP + 0xa8] MOV RDX,qword ptr [RSP + 0xb0] ADD RSP,0xb8 RET
int1 [16] js_map_set(int8 param_1,int8 param_2,int8 param_3,int8 param_4, int8 *param_5,uint param_6) { int iVar1; int *piVar2; char *pcVar5; int1 auVar6 [16]; uint uStack_94; long local_70; int8 local_68; long local_50; int4 local_10; int4 uStack_c; int8 local_8; int8 uVar3; int8 uVar4; piVar2 = (int *)JS_GetOpaque2(param_1,param_2,param_3,param_6 + 0x23); if (piVar2 == (int *)0x0) { local_10 = 0; local_8 = 6; } else { auVar6 = map_normalize_key(param_1,*param_5,param_5[1]); uVar4 = auVar6._8_8_; uVar3 = auVar6._0_8_; if ((*piVar2 == 0) || (iVar1 = is_valid_weakref_target(uVar3,uVar4), iVar1 != 0)) { if ((param_6 & 1) == 0) { local_70 = param_5[2]; local_68 = param_5[3]; } else { local_70 = (ulong)uStack_94 << 0x20; local_68 = 3; } local_50 = map_find_record(param_1,piVar2,uVar3,uVar4); if (local_50 == 0) { local_50 = map_add_record(param_1,piVar2,uVar3,uVar4); if (local_50 == 0) { local_10 = 0; local_8 = 6; goto LAB_00183e7a; } } else { JS_FreeValue(param_1,*(int8 *)(local_50 + 0x40),*(int8 *)(local_50 + 0x48)); } auVar6 = js_dup(local_70,local_68); *(int1 (*) [16])(local_50 + 0x40) = auVar6; auVar6 = js_dup(param_2,param_3); local_8 = auVar6._8_8_; local_10 = auVar6._0_4_; uStack_c = auVar6._4_4_; } else { pcVar5 = "WeakMap"; if ((param_6 & 1) != 0) { pcVar5 = "WeakSet"; } auVar6 = JS_ThrowTypeError(param_1,"invalid value used as %s key",pcVar5); local_8 = auVar6._8_8_; local_10 = auVar6._0_4_; uStack_c = auVar6._4_4_; } } LAB_00183e7a: auVar6._4_4_ = uStack_c; auVar6._0_4_ = local_10; auVar6._8_8_ = local_8; return auVar6; }
3,502
pvio_socket_connect_sync_or_async
eloqsql/libmariadb/plugins/pvio/pvio_socket.c
static int pvio_socket_connect_sync_or_async(MARIADB_PVIO *pvio, const struct sockaddr *name, uint namelen) { MYSQL *mysql= pvio->mysql; if (mysql->options.extension && mysql->options.extension->async_context && mysql->options.extension->async_context->active) { /* even if we are not connected yet, application needs to check socket * via mysql_get_socket api call, so we need to assign pvio */ return pvio_socket_connect_async(pvio, name, namelen); } return pvio_socket_internal_connect(pvio, name, namelen); }
O0
c
pvio_socket_connect_sync_or_async: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) movq -0x10(%rbp), %rax movq 0x40(%rax), %rax movq %rax, -0x28(%rbp) movq -0x28(%rbp), %rax cmpq $0x0, 0x480(%rax) je 0x44adc movq -0x28(%rbp), %rax movq 0x480(%rax), %rax cmpq $0x0, 0x28(%rax) je 0x44adc movq -0x28(%rbp), %rax movq 0x480(%rax), %rax movq 0x28(%rax), %rax movsbl 0x14(%rax), %eax cmpl $0x0, %eax je 0x44adc movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movl -0x1c(%rbp), %edx callq 0x44b00 movl %eax, -0x4(%rbp) jmp 0x44af1 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movl -0x1c(%rbp), %eax movl %eax, %edx callq 0x44b70 movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x30, %rsp popq %rbp retq nopw (%rax,%rax)
pvio_socket_connect_sync_or_async: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_1C], edx mov rax, [rbp+var_10] mov rax, [rax+40h] mov [rbp+var_28], rax mov rax, [rbp+var_28] cmp qword ptr [rax+480h], 0 jz short loc_44ADC mov rax, [rbp+var_28] mov rax, [rax+480h] cmp qword ptr [rax+28h], 0 jz short loc_44ADC mov rax, [rbp+var_28] mov rax, [rax+480h] mov rax, [rax+28h] movsx eax, byte ptr [rax+14h] cmp eax, 0 jz short loc_44ADC mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov edx, [rbp+var_1C] call pvio_socket_connect_async mov [rbp+var_4], eax jmp short loc_44AF1 loc_44ADC: mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov eax, [rbp+var_1C] mov edx, eax call pvio_socket_internal_connect mov [rbp+var_4], eax loc_44AF1: mov eax, [rbp+var_4] add rsp, 30h pop rbp retn
long long pvio_socket_connect_sync_or_async(long long a1, long long a2, unsigned int a3) { long long v4; // [rsp+8h] [rbp-28h] v4 = *(_QWORD *)(a1 + 64); if ( *(_QWORD *)(v4 + 1152) && *(_QWORD *)(*(_QWORD *)(v4 + 1152) + 40LL) && *(_BYTE *)(*(_QWORD *)(*(_QWORD *)(v4 + 1152) + 40LL) + 20LL) ) { return (unsigned int)pvio_socket_connect_async(a1, a2, a3); } else { return (unsigned int)pvio_socket_internal_connect(a1, a2, a3); } }
pvio_socket_connect_sync_or_async: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV dword ptr [RBP + -0x1c],EDX MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x40] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x28] CMP qword ptr [RAX + 0x480],0x0 JZ 0x00144adc MOV RAX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RAX + 0x480] CMP qword ptr [RAX + 0x28],0x0 JZ 0x00144adc MOV RAX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RAX + 0x480] MOV RAX,qword ptr [RAX + 0x28] MOVSX EAX,byte ptr [RAX + 0x14] CMP EAX,0x0 JZ 0x00144adc MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] MOV EDX,dword ptr [RBP + -0x1c] CALL 0x00144b00 MOV dword ptr [RBP + -0x4],EAX JMP 0x00144af1 LAB_00144adc: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] MOV EAX,dword ptr [RBP + -0x1c] MOV EDX,EAX CALL 0x00144b70 MOV dword ptr [RBP + -0x4],EAX LAB_00144af1: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x30 POP RBP RET
int4 pvio_socket_connect_sync_or_async(long param_1,int8 param_2,int4 param_3) { long lVar1; int4 local_c; lVar1 = *(long *)(param_1 + 0x40); if (((*(long *)(lVar1 + 0x480) == 0) || (*(long *)(*(long *)(lVar1 + 0x480) + 0x28) == 0)) || (*(char *)(*(long *)(*(long *)(lVar1 + 0x480) + 0x28) + 0x14) == '\0')) { local_c = pvio_socket_internal_connect(param_1,param_2,param_3); } else { local_c = pvio_socket_connect_async(param_1,param_2,param_3); } return local_c; }
3,503
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 0x43f0d 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 0x31170 cmpb $0x22, %bpl je 0x43e0d movq %rsp, %rdi movl $0x27, %esi xorl %edx, %edx callq 0x198d0 cmpq $-0x1, %rax je 0x43e46 movq (%rsp), %rsi movq 0x8(%rsp), %rdx movq %rbx, %rdi callq 0x197c0 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x43e39 movq 0x10(%rsp), %rsi incq %rsi callq 0x196e0 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 0x197c0 movq 0x8(%rsp), %r15 decq %r15 cmpq $0x2, %r15 jb 0x43ef3 movl $0x1, %r12d leaq 0x20(%rsp), %r14 movq (%rsp), %rcx movb (%rcx,%r12), %al cmpb $0x5c, %al jne 0x43ea6 cmpb $0x22, 0x1(%rcx,%r12) jne 0x43ea6 movb $0x22, 0x20(%rsp) movl $0x1, %edx movq %rbx, %rdi movq %r14, %rsi callq 0x197c0 incq %r12 jmp 0x43eeb cmpb %bpl, %al jne 0x43ed7 movb $0x5c, 0x20(%rsp) movl $0x1, %edx movq %rbx, %rdi movq %r14, %rsi callq 0x197c0 movb %bpl, 0x20(%rsp) movl $0x1, %edx movq %rax, %rdi movq %r14, %rsi callq 0x197c0 jmp 0x43eeb movb %al, 0x20(%rsp) movl $0x1, %edx movq %rbx, %rdi movq %r14, %rsi callq 0x197c0 incq %r12 cmpq %r15, %r12 jb 0x43e78 leaq 0x20(%rsp), %rsi movb %bpl, (%rsi) movl $0x1, %edx movq %rbx, %rdi callq 0x197c0 jmp 0x43e1e movl $0x10, %edi callq 0x19380 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 0x31170 leaq 0x6d758(%rip), %rsi # 0xb1696 movq %rsp, %rdi leaq 0x20(%rsp), %rdx callq 0x29bdf movb $0x1, %bpl movq %rsp, %rsi movq %rbx, %rdi callq 0x19b00 xorl %ebp, %ebp movq 0xa108e(%rip), %rsi # 0xe4ff0 movq 0xa1007(%rip), %rdx # 0xe4f70 movq %rbx, %rdi callq 0x19bb0 movq %rax, %r14 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x43f97 movq 0x10(%rsp), %rsi incq %rsi callq 0x196e0 jmp 0x43f97 movq %rax, %r14 movb $0x1, %bpl leaq 0x30(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x43fba movq 0x30(%rsp), %rsi incq %rsi callq 0x196e0 jmp 0x43fba movq %rax, %r14 movb $0x1, %bpl testb %bpl, %bpl je 0x43fe9 movq %rbx, %rdi callq 0x19520 jmp 0x43fe9 jmp 0x43fcb movq %rax, %r14 leaq 0x10(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x43fe9 movq 0x10(%rsp), %rsi incq %rsi callq 0x196e0 movq %r14, %rdi callq 0x19c10 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_43F0D 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_43E0D 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_43E46 loc_43E0D: 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_43E1E: lea rax, [rsp+68h+var_58] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_43E39 mov rsi, [rsp+68h+var_58] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_43E39: add rsp, 40h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_43E46: 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_43EF3 mov r12d, 1 lea r14, [rsp+68h+var_48] loc_43E78: mov rcx, [rsp+68h+var_68] mov al, [rcx+r12] cmp al, 5Ch ; '\' jnz short loc_43EA6 cmp byte ptr [rcx+r12+1], 22h ; '"' jnz short loc_43EA6 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_43EEB loc_43EA6: cmp al, bpl jnz short loc_43ED7 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_43EEB loc_43ED7: 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_43EEB: inc r12 cmp r12, r15 jb short loc_43E78 loc_43EF3: 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_43E1E loc_43F0D: 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:lptinfo; 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_43F97 mov rsi, [rsp+68h+var_58] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_43F97 mov r14, rax mov bpl, 1 loc_43F97: lea rax, [rsp+68h+var_38] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_43FBA mov rsi, [rsp+68h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_43FBA mov r14, rax mov bpl, 1 loc_43FBA: test bpl, bpl jz short loc_43FE9 mov rdi, rbx; void * call ___cxa_free_exception jmp short loc_43FE9 jmp short $+2 loc_43FCB: mov r14, rax lea rax, [rsp+68h+var_58] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_43FE9 mov rsi, [rsp+68h+var_58] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_43FE9: 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 0x00143f0d 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 0x00131170 CMP BPL,0x22 JZ 0x00143e0d MOV RDI,RSP MOV ESI,0x27 XOR EDX,EDX CALL 0x001198d0 CMP RAX,-0x1 JZ 0x00143e46 LAB_00143e0d: MOV RSI,qword ptr [RSP] MOV RDX,qword ptr [RSP + 0x8] LAB_00143e16: MOV RDI,RBX CALL 0x001197c0 LAB_00143e1e: LEA RAX,[RSP + 0x10] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x00143e39 MOV RSI,qword ptr [RSP + 0x10] INC RSI CALL 0x001196e0 LAB_00143e39: ADD RSP,0x40 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_00143e46: LEA RSI,[RSP + 0x20] MOV byte ptr [RSI],BPL MOV EDX,0x1 MOV RDI,RBX CALL 0x001197c0 MOV R15,qword ptr [RSP + 0x8] DEC R15 CMP R15,0x2 JC 0x00143ef3 MOV R12D,0x1 LEA R14,[RSP + 0x20] LAB_00143e78: MOV RCX,qword ptr [RSP] MOV AL,byte ptr [RCX + R12*0x1] CMP AL,0x5c JNZ 0x00143ea6 CMP byte ptr [RCX + R12*0x1 + 0x1],0x22 JNZ 0x00143ea6 MOV byte ptr [RSP + 0x20],0x22 LAB_00143e91: MOV EDX,0x1 MOV RDI,RBX MOV RSI,R14 CALL 0x001197c0 INC R12 JMP 0x00143eeb LAB_00143ea6: CMP AL,BPL JNZ 0x00143ed7 MOV byte ptr [RSP + 0x20],0x5c MOV EDX,0x1 MOV RDI,RBX MOV RSI,R14 CALL 0x001197c0 MOV byte ptr [RSP + 0x20],BPL MOV EDX,0x1 MOV RDI,RAX MOV RSI,R14 CALL 0x001197c0 JMP 0x00143eeb LAB_00143ed7: MOV byte ptr [RSP + 0x20],AL MOV EDX,0x1 MOV RDI,RBX MOV RSI,R14 CALL 0x001197c0 LAB_00143eeb: INC R12 CMP R12,R15 JC 0x00143e78 LAB_00143ef3: LEA RSI,[RSP + 0x20] MOV byte ptr [RSI],BPL LAB_00143efb: MOV EDX,0x1 MOV RDI,RBX CALL 0x001197c0 LAB_00143f08: JMP 0x00143e1e LAB_00143f0d: MOV EDI,0x10 CALL 0x00119380 MOV RBX,RAX LAB_00143f1a: LEA RDI,[RSP + 0x20] MOV RSI,R14 MOV EDX,0xffffffff MOV ECX,0x20 XOR R8D,R8D XOR R9D,R9D CALL 0x00131170 LAB_00143f37: LEA RSI,[0x1b1696] MOV RDI,RSP LEA RDX,[RSP + 0x20] CALL 0x00129bdf MOV BPL,0x1 LAB_00143f4e: MOV RSI,RSP MOV RDI,RBX CALL 0x00119b00 XOR EBP,EBP MOV RSI,qword ptr [0x001e4ff0] MOV RDX,qword ptr [0x001e4f70] MOV RDI,RBX CALL 0x00119bb0
/* 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 00143f1a to 00143f36 has its CatchHandler @ 00143fb4 */ 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 00143f37 to 00143f4a has its CatchHandler @ 00143f91 */ std::operator+((char *)&local_68,(string *)"Value is not a string: "); /* try { // try from 00143f4e to 00143f70 has its CatchHandler @ 00143f71 */ std::runtime_error::runtime_error(this,(string *)&local_68); /* WARNING: Subroutine does not return */ __cxa_throw(this,PTR_typeinfo_001e4ff0,PTR__runtime_error_001e4f70); } 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 00143e91 to 00143eea has its CatchHandler @ 00143fcb */ 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 00143efb to 00143f07 has its CatchHandler @ 00143fc9 */ std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,local_48,1); goto LAB_00143e1e; } } /* try { // try from 00143e16 to 00143e5a has its CatchHandler @ 00143fc9 */ std::__ostream_insert<char,std::char_traits<char>>((ostream *)param_2,(char *)local_68,local_60); LAB_00143e1e: if (local_68 != local_58) { operator_delete(local_68,local_58[0] + 1); } return; }
3,504
net_field_length_ll
eloqsql/libmariadb/libmariadb/mariadb_lib.c
static unsigned long long net_field_length_ll(uchar **packet) { reg1 uchar *pos= *packet; if (*pos < 251) { (*packet)++; return (unsigned long long) *pos; } if (*pos == 251) { (*packet)++; return (unsigned long long) NULL_LENGTH; } if (*pos == 252) { (*packet)+=3; return (unsigned long long) uint2korr(pos+1); } if (*pos == 253) { (*packet)+=4; return (unsigned long long) uint3korr(pos+1); } (*packet)+=9; /* Must be 254 when here */ #ifdef NO_CLIENT_LONGLONG return (unsigned long long) uint4korr(pos+1); #else return (unsigned long long) uint8korr(pos+1); #endif }
O3
c
net_field_length_ll: pushq %rbp movq %rsp, %rbp movq (%rdi), %rax movzbl (%rax), %ecx cmpl $0xfa, %ecx ja 0x1d9ee leaq 0x1(%rax), %rcx movq %rcx, (%rdi) movzbl (%rax), %eax popq %rbp retq cmpl $0xfd, %ecx je 0x1da22 cmpl $0xfc, %ecx je 0x1da15 cmpl $0xfb, %ecx jne 0x1da39 incq %rax movq %rax, (%rdi) movq $-0x1, %rax jmp 0x1d9ec leaq 0x3(%rax), %rcx movq %rcx, (%rdi) movzwl 0x1(%rax), %eax jmp 0x1d9ec leaq 0x4(%rax), %rcx movq %rcx, (%rdi) movzwl 0x1(%rax), %ecx movzbl 0x3(%rax), %eax shll $0x10, %eax orq %rcx, %rax jmp 0x1d9ec leaq 0x9(%rax), %rcx movq %rcx, (%rdi) movq 0x1(%rax), %rax jmp 0x1d9ec
net_field_length_ll: push rbp mov rbp, rsp mov rax, [rdi] movzx ecx, byte ptr [rax] cmp ecx, 0FAh ja short loc_1D9EE lea rcx, [rax+1] mov [rdi], rcx movzx eax, byte ptr [rax] loc_1D9EC: pop rbp retn loc_1D9EE: cmp ecx, 0FDh jz short loc_1DA22 cmp ecx, 0FCh jz short loc_1DA15 cmp ecx, 0FBh jnz short loc_1DA39 inc rax mov [rdi], rax mov rax, 0FFFFFFFFFFFFFFFFh jmp short loc_1D9EC loc_1DA15: lea rcx, [rax+3] mov [rdi], rcx movzx eax, word ptr [rax+1] jmp short loc_1D9EC loc_1DA22: lea rcx, [rax+4] mov [rdi], rcx movzx ecx, word ptr [rax+1] movzx eax, byte ptr [rax+3] shl eax, 10h or rax, rcx jmp short loc_1D9EC loc_1DA39: lea rcx, [rax+9] mov [rdi], rcx mov rax, [rax+1] jmp short loc_1D9EC
unsigned long long net_field_length_ll(unsigned __int8 **a1) { unsigned __int8 *v1; // rax unsigned int v2; // ecx v1 = *a1; v2 = **a1; if ( v2 > 0xFA ) { switch ( v2 ) { case 0xFDu: *a1 = v1 + 4; return *(unsigned __int16 *)(v1 + 1) | (unsigned long long)(v1[3] << 16); case 0xFCu: *a1 = v1 + 3; return *(unsigned __int16 *)(v1 + 1); case 0xFBu: *a1 = v1 + 1; return -1LL; default: *a1 = v1 + 9; return *(_QWORD *)(v1 + 1); } } else { *a1 = v1 + 1; return *v1; } }
net_field_length_ll: PUSH RBP MOV RBP,RSP MOV RAX,qword ptr [RDI] MOVZX ECX,byte ptr [RAX] CMP ECX,0xfa JA 0x0011d9ee LEA RCX,[RAX + 0x1] MOV qword ptr [RDI],RCX MOVZX EAX,byte ptr [RAX] LAB_0011d9ec: POP RBP RET LAB_0011d9ee: CMP ECX,0xfd JZ 0x0011da22 CMP ECX,0xfc JZ 0x0011da15 CMP ECX,0xfb JNZ 0x0011da39 INC RAX MOV qword ptr [RDI],RAX MOV RAX,-0x1 JMP 0x0011d9ec LAB_0011da15: LEA RCX,[RAX + 0x3] MOV qword ptr [RDI],RCX MOVZX EAX,word ptr [RAX + 0x1] JMP 0x0011d9ec LAB_0011da22: LEA RCX,[RAX + 0x4] MOV qword ptr [RDI],RCX MOVZX ECX,word ptr [RAX + 0x1] MOVZX EAX,byte ptr [RAX + 0x3] SHL EAX,0x10 OR RAX,RCX JMP 0x0011d9ec LAB_0011da39: LEA RCX,[RAX + 0x9] MOV qword ptr [RDI],RCX MOV RAX,qword ptr [RAX + 0x1] JMP 0x0011d9ec
ulong net_field_length_ll(long *param_1) { byte bVar1; byte *pbVar2; ulong uVar3; pbVar2 = (byte *)*param_1; bVar1 = *pbVar2; if (bVar1 < 0xfb) { *param_1 = (long)(pbVar2 + 1); uVar3 = (ulong)*pbVar2; } else if (bVar1 == 0xfd) { *param_1 = (long)(pbVar2 + 4); uVar3 = (ulong)*(uint3 *)(pbVar2 + 1); } else if (bVar1 == 0xfc) { *param_1 = (long)(pbVar2 + 3); uVar3 = (ulong)*(ushort *)(pbVar2 + 1); } else if (bVar1 == 0xfb) { *param_1 = (long)(pbVar2 + 1); uVar3 = 0xffffffffffffffff; } else { *param_1 = (long)(pbVar2 + 9); uVar3 = *(ulong *)(pbVar2 + 1); } return uVar3; }
3,505
void nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::dump_integer<unsigned char, 0>(unsigned char)
hkr04[P]cpp-mcp/common/json.hpp
void dump_integer(NumberType x) { static constexpr std::array<std::array<char, 2>, 100> digits_to_99 { { {{'0', '0'}}, {{'0', '1'}}, {{'0', '2'}}, {{'0', '3'}}, {{'0', '4'}}, {{'0', '5'}}, {{'0', '6'}}, {{'0', '7'}}, {{'0', '8'}}, {{'0', '9'}}, {{'1', '0'}}, {{'1', '1'}}, {{'1', '2'}}, {{'1', '3'}}, {{'1', '4'}}, {{'1', '5'}}, {{'1', '6'}}, {{'1', '7'}}, {{'1', '8'}}, {{'1', '9'}}, {{'2', '0'}}, {{'2', '1'}}, {{'2', '2'}}, {{'2', '3'}}, {{'2', '4'}}, {{'2', '5'}}, {{'2', '6'}}, {{'2', '7'}}, {{'2', '8'}}, {{'2', '9'}}, {{'3', '0'}}, {{'3', '1'}}, {{'3', '2'}}, {{'3', '3'}}, {{'3', '4'}}, {{'3', '5'}}, {{'3', '6'}}, {{'3', '7'}}, {{'3', '8'}}, {{'3', '9'}}, {{'4', '0'}}, {{'4', '1'}}, {{'4', '2'}}, {{'4', '3'}}, {{'4', '4'}}, {{'4', '5'}}, {{'4', '6'}}, {{'4', '7'}}, {{'4', '8'}}, {{'4', '9'}}, {{'5', '0'}}, {{'5', '1'}}, {{'5', '2'}}, {{'5', '3'}}, {{'5', '4'}}, {{'5', '5'}}, {{'5', '6'}}, {{'5', '7'}}, {{'5', '8'}}, {{'5', '9'}}, {{'6', '0'}}, {{'6', '1'}}, {{'6', '2'}}, {{'6', '3'}}, {{'6', '4'}}, {{'6', '5'}}, {{'6', '6'}}, {{'6', '7'}}, {{'6', '8'}}, {{'6', '9'}}, {{'7', '0'}}, {{'7', '1'}}, {{'7', '2'}}, {{'7', '3'}}, {{'7', '4'}}, {{'7', '5'}}, {{'7', '6'}}, {{'7', '7'}}, {{'7', '8'}}, {{'7', '9'}}, {{'8', '0'}}, {{'8', '1'}}, {{'8', '2'}}, {{'8', '3'}}, {{'8', '4'}}, {{'8', '5'}}, {{'8', '6'}}, {{'8', '7'}}, {{'8', '8'}}, {{'8', '9'}}, {{'9', '0'}}, {{'9', '1'}}, {{'9', '2'}}, {{'9', '3'}}, {{'9', '4'}}, {{'9', '5'}}, {{'9', '6'}}, {{'9', '7'}}, {{'9', '8'}}, {{'9', '9'}}, } }; // special case for "0" if (x == 0) { o->write_character('0'); return; } // use a pointer to fill the buffer auto buffer_ptr = number_buffer.begin(); // NOLINT(llvm-qualified-auto,readability-qualified-auto,cppcoreguidelines-pro-type-vararg,hicpp-vararg) number_unsigned_t abs_value; unsigned int n_chars{}; if (is_negative_number(x)) { *buffer_ptr = '-'; abs_value = remove_sign(static_cast<number_integer_t>(x)); // account one more byte for the minus sign n_chars = 1 + count_digits(abs_value); } else { abs_value = static_cast<number_unsigned_t>(x); n_chars = count_digits(abs_value); } // spare 1 byte for '\0' JSON_ASSERT(n_chars < number_buffer.size() - 1); // jump to the end to generate the string from backward, // so we later avoid reversing the result buffer_ptr += n_chars; // Fast int2ascii implementation inspired by "Fastware" talk by Andrei Alexandrescu // See: https://www.youtube.com/watch?v=o4-CwDo2zpg while (abs_value >= 100) { const auto digits_index = static_cast<unsigned>((abs_value % 100)); abs_value /= 100; *(--buffer_ptr) = digits_to_99[digits_index][1]; *(--buffer_ptr) = digits_to_99[digits_index][0]; } if (abs_value >= 10) { const auto digits_index = static_cast<unsigned>(abs_value); *(--buffer_ptr) = digits_to_99[digits_index][1]; *(--buffer_ptr) = digits_to_99[digits_index][0]; } else { *(--buffer_ptr) = static_cast<char>('0' + abs_value); } o->write_characters(number_buffer.data(), n_chars); }
O0
cpp
void nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::dump_integer<unsigned char, 0>(unsigned char): subq $0x48, %rsp movb %sil, %al movq %rdi, 0x40(%rsp) movb %al, 0x3f(%rsp) movq 0x40(%rsp), %rax movq %rax, 0x10(%rsp) movzbl 0x3f(%rsp), %eax cmpl $0x0, %eax jne 0xd5270 movq 0x10(%rsp), %rdi callq 0xd43f0 movq %rax, %rdi movq (%rdi), %rax movl $0x30, %esi callq *(%rax) jmp 0xd5475 movq 0x10(%rsp), %rdi addq $0x10, %rdi callq 0xd60a0 movq 0x10(%rsp), %rdi movq %rax, 0x30(%rsp) movl $0x0, 0x24(%rsp) movzbl 0x3f(%rsp), %esi callq 0xd60b0 testb $0x1, %al jne 0xd52a0 jmp 0xd52d6 movq 0x10(%rsp), %rdi movq 0x30(%rsp), %rax movb $0x2d, (%rax) movzbl 0x3f(%rsp), %eax movl %eax, %esi callq 0xd60d0 movq 0x10(%rsp), %rdi movq %rax, 0x28(%rsp) movq 0x28(%rsp), %rsi callq 0xd60f0 addl $0x1, %eax movl %eax, 0x24(%rsp) jmp 0xd52f3 movq 0x10(%rsp), %rdi movzbl 0x3f(%rsp), %eax movq %rax, 0x28(%rsp) movq 0x28(%rsp), %rsi callq 0xd60f0 movl %eax, 0x24(%rsp) movl 0x24(%rsp), %ecx movq 0x30(%rsp), %rax movl %ecx, %ecx addq %rcx, %rax movq %rax, 0x30(%rsp) cmpq $0x64, 0x28(%rsp) jb 0xd53a9 movq 0x28(%rsp), %rax movl $0x64, %ecx xorl %edx, %edx divq %rcx movl %edx, %eax movl %eax, 0x20(%rsp) movq 0x28(%rsp), %rax movl $0x64, %ecx xorl %edx, %edx divq %rcx movq %rax, 0x28(%rsp) movl 0x20(%rsp), %eax movl %eax, %esi leaq 0x1686f(%rip), %rdi # 0xebbb7 callq 0xd6180 movq %rax, %rdi movl $0x1, %esi callq 0xd61b0 movb (%rax), %cl movq 0x30(%rsp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, 0x30(%rsp) movb %cl, -0x1(%rax) movl 0x20(%rsp), %eax movl %eax, %esi leaq 0x1683a(%rip), %rdi # 0xebbb7 callq 0xd6180 movq %rax, %rdi xorl %eax, %eax movl %eax, %esi callq 0xd61b0 movb (%rax), %cl movq 0x30(%rsp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, 0x30(%rsp) movb %cl, -0x1(%rax) jmp 0xd5306 cmpq $0xa, 0x28(%rsp) jb 0xd5425 movq 0x28(%rsp), %rax movl %eax, 0x1c(%rsp) movl 0x1c(%rsp), %eax movl %eax, %esi leaq 0x167f0(%rip), %rdi # 0xebbb7 callq 0xd6180 movq %rax, %rdi movl $0x1, %esi callq 0xd61b0 movb (%rax), %cl movq 0x30(%rsp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, 0x30(%rsp) movb %cl, -0x1(%rax) movl 0x1c(%rsp), %eax movl %eax, %esi leaq 0x167bb(%rip), %rdi # 0xebbb7 callq 0xd6180 movq %rax, %rdi xorl %eax, %eax movl %eax, %esi callq 0xd61b0 movb (%rax), %cl movq 0x30(%rsp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, 0x30(%rsp) movb %cl, -0x1(%rax) jmp 0xd5444 movq 0x28(%rsp), %rax addq $0x30, %rax movb %al, %cl movq 0x30(%rsp), %rax movq %rax, %rdx addq $-0x1, %rdx movq %rdx, 0x30(%rsp) movb %cl, -0x1(%rax) movq 0x10(%rsp), %rdi callq 0xd43f0 movq 0x10(%rsp), %rdi movq %rax, 0x8(%rsp) addq $0x10, %rdi callq 0xd61e0 movq 0x8(%rsp), %rdi movq %rax, %rsi movl 0x24(%rsp), %eax movl %eax, %edx movq (%rdi), %rax callq *0x8(%rax) addq $0x48, %rsp retq nopw (%rax,%rax)
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_: sub rsp, 48h mov al, sil mov [rsp+48h+var_8], rdi mov [rsp+48h+var_9], al mov rax, [rsp+48h+var_8] mov [rsp+48h+var_38], rax movzx eax, [rsp+48h+var_9] cmp eax, 0 jnz short loc_D5270 mov rdi, [rsp+48h+var_38] call _ZNKSt19__shared_ptr_accessIN8nlohmann16json_abi_v3_11_36detail23output_adapter_protocolIcEELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char>,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void) mov rdi, rax mov rax, [rdi] mov esi, 30h ; '0' call qword ptr [rax] jmp loc_D5475 loc_D5270: mov rdi, [rsp+48h+var_38] add rdi, 10h call _ZNSt5arrayIcLm64EE5beginEv; std::array<char,64ul>::begin(void) mov rdi, [rsp+48h+var_38] mov [rsp+48h+var_18], rax mov [rsp+48h+var_24], 0 movzx esi, [rsp+48h+var_9] call _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE18is_negative_numberIhTnNSt9enable_ifIXsr3std11is_unsignedIT_EE5valueEiE4typeELi0EEEbSJ_ test al, 1 jnz short loc_D52A0 jmp short loc_D52D6 loc_D52A0: mov rdi, [rsp+48h+var_38] mov rax, [rsp+48h+var_18] mov byte ptr [rax], 2Dh ; '-' movzx eax, [rsp+48h+var_9] mov esi, eax call _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE11remove_signEl; nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::remove_sign(long) mov rdi, [rsp+48h+var_38] mov [rsp+48h+var_20], rax mov rsi, [rsp+48h+var_20] call _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12count_digitsEm; nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::count_digits(ulong) add eax, 1 mov [rsp+48h+var_24], eax jmp short loc_D52F3 loc_D52D6: mov rdi, [rsp+48h+var_38] movzx eax, [rsp+48h+var_9] mov [rsp+48h+var_20], rax mov rsi, [rsp+48h+var_20] call _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12count_digitsEm; nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::count_digits(ulong) mov [rsp+48h+var_24], eax loc_D52F3: mov ecx, [rsp+48h+var_24] mov rax, [rsp+48h+var_18] mov ecx, ecx add rax, rcx mov [rsp+48h+var_18], rax loc_D5306: cmp [rsp+48h+var_20], 64h ; 'd' jb loc_D53A9 mov rax, [rsp+48h+var_20] mov ecx, 64h ; 'd' xor edx, edx div rcx mov eax, edx mov [rsp+48h+var_28], eax mov rax, [rsp+48h+var_20] mov ecx, 64h ; 'd' xor edx, edx div rcx mov [rsp+48h+var_20], rax mov eax, [rsp+48h+var_28] mov esi, eax lea rdi, _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 call _ZNKSt5arrayIS_IcLm2EELm100EEixEm; std::array<std::array<char,2ul>,100ul>::operator[](ulong) mov rdi, rax mov esi, 1 call _ZNKSt5arrayIcLm2EEixEm; std::array<char,2ul>::operator[](ulong) mov cl, [rax] mov rax, [rsp+48h+var_18] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rsp+48h+var_18], rdx mov [rax-1], cl mov eax, [rsp+48h+var_28] mov esi, eax lea rdi, _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 call _ZNKSt5arrayIS_IcLm2EELm100EEixEm; std::array<std::array<char,2ul>,100ul>::operator[](ulong) mov rdi, rax xor eax, eax mov esi, eax call _ZNKSt5arrayIcLm2EEixEm; std::array<char,2ul>::operator[](ulong) mov cl, [rax] mov rax, [rsp+48h+var_18] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rsp+48h+var_18], rdx mov [rax-1], cl jmp loc_D5306 loc_D53A9: cmp [rsp+48h+var_20], 0Ah jb short loc_D5425 mov rax, [rsp+48h+var_20] mov [rsp+48h+var_2C], eax mov eax, [rsp+48h+var_2C] mov esi, eax lea rdi, _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 call _ZNKSt5arrayIS_IcLm2EELm100EEixEm; std::array<std::array<char,2ul>,100ul>::operator[](ulong) mov rdi, rax mov esi, 1 call _ZNKSt5arrayIcLm2EEixEm; std::array<char,2ul>::operator[](ulong) mov cl, [rax] mov rax, [rsp+48h+var_18] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rsp+48h+var_18], rdx mov [rax-1], cl mov eax, [rsp+48h+var_2C] mov esi, eax lea rdi, _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 call _ZNKSt5arrayIS_IcLm2EELm100EEixEm; std::array<std::array<char,2ul>,100ul>::operator[](ulong) mov rdi, rax xor eax, eax mov esi, eax call _ZNKSt5arrayIcLm2EEixEm; std::array<char,2ul>::operator[](ulong) mov cl, [rax] mov rax, [rsp+48h+var_18] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rsp+48h+var_18], rdx mov [rax-1], cl jmp short loc_D5444 loc_D5425: mov rax, [rsp+48h+var_20] add rax, 30h ; '0' mov cl, al mov rax, [rsp+48h+var_18] mov rdx, rax add rdx, 0FFFFFFFFFFFFFFFFh mov [rsp+48h+var_18], rdx mov [rax-1], cl loc_D5444: mov rdi, [rsp+48h+var_38] call _ZNKSt19__shared_ptr_accessIN8nlohmann16json_abi_v3_11_36detail23output_adapter_protocolIcEELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv; std::__shared_ptr_access<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char>,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(void) mov rdi, [rsp+48h+var_38] mov [rsp+48h+var_40], rax add rdi, 10h call _ZNSt5arrayIcLm64EE4dataEv; std::array<char,64ul>::data(void) mov rdi, [rsp+48h+var_40] mov rsi, rax mov eax, [rsp+48h+var_24] mov edx, eax mov rax, [rdi] call qword ptr [rax+8] loc_D5475: add rsp, 48h retn
long long ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_( long long a1, unsigned __int8 a2) { long long ( ***v2)(_QWORD, long long); // rax long long v4; // rax long long v5; // rax long long v6; // rax long long v7; // rax long long v8; // rax long long v9; // [rsp+8h] [rbp-40h] unsigned int v10; // [rsp+20h] [rbp-28h] unsigned int v11; // [rsp+24h] [rbp-24h] unsigned long long v12; // [rsp+28h] [rbp-20h] _BYTE *v13; // [rsp+30h] [rbp-18h] _BYTE *v14; // [rsp+30h] [rbp-18h] if ( a2 ) { v13 = (_BYTE *)std::array<char,64ul>::begin(a1 + 16); if ( (ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE18is_negative_numberIhTnNSt9enable_ifIXsr3std11is_unsignedIT_EE5valueEiE4typeELi0EEEbSJ_( a1, a2) & 1) != 0 ) { *v13 = 45; v12 = nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::remove_sign( a1, a2); v11 = nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::count_digits( a1, v12) + 1; } else { v12 = a2; v11 = nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::count_digits( a1, a2); } v14 = &v13[v11]; while ( v12 >= 0x64 ) { v10 = v12 % 0x64; v12 /= 0x64uLL; v4 = std::array<std::array<char,2ul>,100ul>::operator[]( &ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99, v10); *(v14 - 1) = *(_BYTE *)std::array<char,2ul>::operator[](v4, 1LL); v5 = std::array<std::array<char,2ul>,100ul>::operator[]( &ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99, v10); v14 -= 2; *v14 = *(_BYTE *)std::array<char,2ul>::operator[](v5, 0LL); } if ( v12 < 0xA ) { *(v14 - 1) = v12 + 48; } else { v6 = std::array<std::array<char,2ul>,100ul>::operator[]( &ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99, (unsigned int)v12); *(v14 - 1) = *(_BYTE *)std::array<char,2ul>::operator[](v6, 1LL); v7 = std::array<std::array<char,2ul>,100ul>::operator[]( &ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99, (unsigned int)v12); *(v14 - 2) = *(_BYTE *)std::array<char,2ul>::operator[](v7, 0LL); } v9 = std::__shared_ptr_access<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char>,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(a1); v8 = std::array<char,64ul>::data(a1 + 16); return (*(long long ( **)(long long, long long, _QWORD))(*(_QWORD *)v9 + 8LL))(v9, v8, v11); } else { v2 = (long long ( ***)(_QWORD, long long))std::__shared_ptr_access<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char>,(__gnu_cxx::_Lock_policy)2,false,false>::operator->(a1); return (**v2)(v2, 48LL); } }
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_: SUB RSP,0x48 MOV AL,SIL MOV qword ptr [RSP + 0x40],RDI MOV byte ptr [RSP + 0x3f],AL MOV RAX,qword ptr [RSP + 0x40] MOV qword ptr [RSP + 0x10],RAX MOVZX EAX,byte ptr [RSP + 0x3f] CMP EAX,0x0 JNZ 0x001d5270 MOV RDI,qword ptr [RSP + 0x10] CALL 0x001d43f0 MOV RDI,RAX MOV RAX,qword ptr [RDI] MOV ESI,0x30 CALL qword ptr [RAX] JMP 0x001d5475 LAB_001d5270: MOV RDI,qword ptr [RSP + 0x10] ADD RDI,0x10 CALL 0x001d60a0 MOV RDI,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x30],RAX MOV dword ptr [RSP + 0x24],0x0 MOVZX ESI,byte ptr [RSP + 0x3f] CALL 0x001d60b0 TEST AL,0x1 JNZ 0x001d52a0 JMP 0x001d52d6 LAB_001d52a0: MOV RDI,qword ptr [RSP + 0x10] MOV RAX,qword ptr [RSP + 0x30] MOV byte ptr [RAX],0x2d MOVZX EAX,byte ptr [RSP + 0x3f] MOV ESI,EAX CALL 0x001d60d0 MOV RDI,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x28],RAX MOV RSI,qword ptr [RSP + 0x28] CALL 0x001d60f0 ADD EAX,0x1 MOV dword ptr [RSP + 0x24],EAX JMP 0x001d52f3 LAB_001d52d6: MOV RDI,qword ptr [RSP + 0x10] MOVZX EAX,byte ptr [RSP + 0x3f] MOV qword ptr [RSP + 0x28],RAX MOV RSI,qword ptr [RSP + 0x28] CALL 0x001d60f0 MOV dword ptr [RSP + 0x24],EAX LAB_001d52f3: MOV ECX,dword ptr [RSP + 0x24] MOV RAX,qword ptr [RSP + 0x30] MOV ECX,ECX ADD RAX,RCX MOV qword ptr [RSP + 0x30],RAX LAB_001d5306: CMP qword ptr [RSP + 0x28],0x64 JC 0x001d53a9 MOV RAX,qword ptr [RSP + 0x28] MOV ECX,0x64 XOR EDX,EDX DIV RCX MOV EAX,EDX MOV dword ptr [RSP + 0x20],EAX MOV RAX,qword ptr [RSP + 0x28] MOV ECX,0x64 XOR EDX,EDX DIV RCX MOV qword ptr [RSP + 0x28],RAX MOV EAX,dword ptr [RSP + 0x20] MOV ESI,EAX LEA RDI,[0x1ebbb7] CALL 0x001d6180 MOV RDI,RAX MOV ESI,0x1 CALL 0x001d61b0 MOV CL,byte ptr [RAX] MOV RAX,qword ptr [RSP + 0x30] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RSP + 0x30],RDX MOV byte ptr [RAX + -0x1],CL MOV EAX,dword ptr [RSP + 0x20] MOV ESI,EAX LEA RDI,[0x1ebbb7] CALL 0x001d6180 MOV RDI,RAX XOR EAX,EAX MOV ESI,EAX CALL 0x001d61b0 MOV CL,byte ptr [RAX] MOV RAX,qword ptr [RSP + 0x30] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RSP + 0x30],RDX MOV byte ptr [RAX + -0x1],CL JMP 0x001d5306 LAB_001d53a9: CMP qword ptr [RSP + 0x28],0xa JC 0x001d5425 MOV RAX,qword ptr [RSP + 0x28] MOV dword ptr [RSP + 0x1c],EAX MOV EAX,dword ptr [RSP + 0x1c] MOV ESI,EAX LEA RDI,[0x1ebbb7] CALL 0x001d6180 MOV RDI,RAX MOV ESI,0x1 CALL 0x001d61b0 MOV CL,byte ptr [RAX] MOV RAX,qword ptr [RSP + 0x30] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RSP + 0x30],RDX MOV byte ptr [RAX + -0x1],CL MOV EAX,dword ptr [RSP + 0x1c] MOV ESI,EAX LEA RDI,[0x1ebbb7] CALL 0x001d6180 MOV RDI,RAX XOR EAX,EAX MOV ESI,EAX CALL 0x001d61b0 MOV CL,byte ptr [RAX] MOV RAX,qword ptr [RSP + 0x30] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RSP + 0x30],RDX MOV byte ptr [RAX + -0x1],CL JMP 0x001d5444 LAB_001d5425: MOV RAX,qword ptr [RSP + 0x28] ADD RAX,0x30 MOV CL,AL MOV RAX,qword ptr [RSP + 0x30] MOV RDX,RAX ADD RDX,-0x1 MOV qword ptr [RSP + 0x30],RDX MOV byte ptr [RAX + -0x1],CL LAB_001d5444: MOV RDI,qword ptr [RSP + 0x10] CALL 0x001d43f0 MOV RDI,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x8],RAX ADD RDI,0x10 CALL 0x001d61e0 MOV RDI,qword ptr [RSP + 0x8] MOV RSI,RAX MOV EAX,dword ptr [RSP + 0x24] MOV EDX,EAX MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x8] LAB_001d5475: ADD RSP,0x48 RET
void _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_ (__shared_ptr_access<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char>,(__gnu_cxx::_Lock_policy)2,false,false> *param_1,byte param_2) { int1 auVar1 [16]; int iVar2; uint uVar3; int8 *puVar4; int1 *puVar5; ulong uVar6; array<char,2ul> *paVar7; long *plVar8; int8 uVar9; uint local_24; ulong local_20; int1 *local_18; if (param_2 == 0) { puVar4 = (int8 *) std:: __shared_ptr_access<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char>,(__gnu_cxx::_Lock_policy)2,false,false> ::operator->(param_1); (**(code **)*puVar4)(puVar4,0x30); } else { puVar5 = (int1 *)std::array<char,64ul>::begin((array<char,64ul> *)(param_1 + 0x10)); uVar6 = _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE18is_negative_numberIhTnNSt9enable_ifIXsr3std11is_unsignedIT_EE5valueEiE4typeELi0EEEbSJ_ (param_1,param_2); if ((uVar6 & 1) == 0) { local_20 = (ulong)param_2; local_24 = nlohmann::json_abi_v3_11_3::detail:: serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ::count_digits((serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *)param_1,local_20); } else { *puVar5 = 0x2d; local_20 = nlohmann::json_abi_v3_11_3::detail:: serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ::remove_sign((serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *)param_1,(ulong)param_2); iVar2 = nlohmann::json_abi_v3_11_3::detail:: serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ::count_digits((serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *)param_1,local_20); local_24 = iVar2 + 1; } local_18 = puVar5 + local_24; while (99 < local_20) { auVar1._8_8_ = 0; auVar1._0_8_ = local_20; uVar3 = SUB164(auVar1 % ZEXT816(100),0); local_20 = local_20 / 100; paVar7 = (array<char,2ul> *) std::array<std::array<char,2ul>,100ul>::operator[] ((array<std::array<char,2ul>,100ul> *) _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 ,(ulong)uVar3); puVar5 = (int1 *)std::array<char,2ul>::operator[](paVar7,1); local_18[-1] = *puVar5; paVar7 = (array<char,2ul> *) std::array<std::array<char,2ul>,100ul>::operator[] ((array<std::array<char,2ul>,100ul> *) _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 ,(ulong)uVar3); puVar5 = (int1 *)std::array<char,2ul>::operator[](paVar7,0); local_18[-2] = *puVar5; local_18 = local_18 + -2; } if (local_20 < 10) { local_18[-1] = (char)local_20 + '0'; } else { paVar7 = (array<char,2ul> *) std::array<std::array<char,2ul>,100ul>::operator[] ((array<std::array<char,2ul>,100ul> *) _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 ,local_20 & 0xffffffff); puVar5 = (int1 *)std::array<char,2ul>::operator[](paVar7,1); local_18[-1] = *puVar5; paVar7 = (array<char,2ul> *) std::array<std::array<char,2ul>,100ul>::operator[] ((array<std::array<char,2ul>,100ul> *) _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIhTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 ,local_20 & 0xffffffff); puVar5 = (int1 *)std::array<char,2ul>::operator[](paVar7,0); local_18[-2] = *puVar5; } plVar8 = (long *)std:: __shared_ptr_access<nlohmann::json_abi_v3_11_3::detail::output_adapter_protocol<char>,(__gnu_cxx::_Lock_policy)2,false,false> ::operator->(param_1); uVar9 = std::array<char,64ul>::data((array<char,64ul> *)(param_1 + 0x10)); (**(code **)(*plVar8 + 8))(plVar8,uVar9,local_24); } return; }
3,506
void nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::dump_integer<unsigned char, 0>(unsigned char)
hkr04[P]cpp-mcp/common/json.hpp
void dump_integer(NumberType x) { static constexpr std::array<std::array<char, 2>, 100> digits_to_99 { { {{'0', '0'}}, {{'0', '1'}}, {{'0', '2'}}, {{'0', '3'}}, {{'0', '4'}}, {{'0', '5'}}, {{'0', '6'}}, {{'0', '7'}}, {{'0', '8'}}, {{'0', '9'}}, {{'1', '0'}}, {{'1', '1'}}, {{'1', '2'}}, {{'1', '3'}}, {{'1', '4'}}, {{'1', '5'}}, {{'1', '6'}}, {{'1', '7'}}, {{'1', '8'}}, {{'1', '9'}}, {{'2', '0'}}, {{'2', '1'}}, {{'2', '2'}}, {{'2', '3'}}, {{'2', '4'}}, {{'2', '5'}}, {{'2', '6'}}, {{'2', '7'}}, {{'2', '8'}}, {{'2', '9'}}, {{'3', '0'}}, {{'3', '1'}}, {{'3', '2'}}, {{'3', '3'}}, {{'3', '4'}}, {{'3', '5'}}, {{'3', '6'}}, {{'3', '7'}}, {{'3', '8'}}, {{'3', '9'}}, {{'4', '0'}}, {{'4', '1'}}, {{'4', '2'}}, {{'4', '3'}}, {{'4', '4'}}, {{'4', '5'}}, {{'4', '6'}}, {{'4', '7'}}, {{'4', '8'}}, {{'4', '9'}}, {{'5', '0'}}, {{'5', '1'}}, {{'5', '2'}}, {{'5', '3'}}, {{'5', '4'}}, {{'5', '5'}}, {{'5', '6'}}, {{'5', '7'}}, {{'5', '8'}}, {{'5', '9'}}, {{'6', '0'}}, {{'6', '1'}}, {{'6', '2'}}, {{'6', '3'}}, {{'6', '4'}}, {{'6', '5'}}, {{'6', '6'}}, {{'6', '7'}}, {{'6', '8'}}, {{'6', '9'}}, {{'7', '0'}}, {{'7', '1'}}, {{'7', '2'}}, {{'7', '3'}}, {{'7', '4'}}, {{'7', '5'}}, {{'7', '6'}}, {{'7', '7'}}, {{'7', '8'}}, {{'7', '9'}}, {{'8', '0'}}, {{'8', '1'}}, {{'8', '2'}}, {{'8', '3'}}, {{'8', '4'}}, {{'8', '5'}}, {{'8', '6'}}, {{'8', '7'}}, {{'8', '8'}}, {{'8', '9'}}, {{'9', '0'}}, {{'9', '1'}}, {{'9', '2'}}, {{'9', '3'}}, {{'9', '4'}}, {{'9', '5'}}, {{'9', '6'}}, {{'9', '7'}}, {{'9', '8'}}, {{'9', '9'}}, } }; // special case for "0" if (x == 0) { o->write_character('0'); return; } // use a pointer to fill the buffer auto buffer_ptr = number_buffer.begin(); // NOLINT(llvm-qualified-auto,readability-qualified-auto,cppcoreguidelines-pro-type-vararg,hicpp-vararg) number_unsigned_t abs_value; unsigned int n_chars{}; if (is_negative_number(x)) { *buffer_ptr = '-'; abs_value = remove_sign(static_cast<number_integer_t>(x)); // account one more byte for the minus sign n_chars = 1 + count_digits(abs_value); } else { abs_value = static_cast<number_unsigned_t>(x); n_chars = count_digits(abs_value); } // spare 1 byte for '\0' JSON_ASSERT(n_chars < number_buffer.size() - 1); // jump to the end to generate the string from backward, // so we later avoid reversing the result buffer_ptr += n_chars; // Fast int2ascii implementation inspired by "Fastware" talk by Andrei Alexandrescu // See: https://www.youtube.com/watch?v=o4-CwDo2zpg while (abs_value >= 100) { const auto digits_index = static_cast<unsigned>((abs_value % 100)); abs_value /= 100; *(--buffer_ptr) = digits_to_99[digits_index][1]; *(--buffer_ptr) = digits_to_99[digits_index][0]; } if (abs_value >= 10) { const auto digits_index = static_cast<unsigned>(abs_value); *(--buffer_ptr) = digits_to_99[digits_index][1]; *(--buffer_ptr) = digits_to_99[digits_index][0]; } else { *(--buffer_ptr) = static_cast<char>('0' + abs_value); } o->write_characters(number_buffer.data(), n_chars); }
O1
cpp
void nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::dump_integer<unsigned char, 0>(unsigned char): testq %rsi, %rsi je 0x515e1 movq %rsi, %rcx leaq 0x10(%rdi), %rsi testq %rcx, %rcx js 0x515f1 movl $0x1, %r9d cmpq $0xa, %rcx jb 0x51665 movl $0x4, %r9d movabsq $0x346dc5d63886594b, %r10 # imm = 0x346DC5D63886594B movq %rcx, %r8 cmpq $0x63, %r8 jbe 0x5164e cmpq $0x3e7, %r8 # imm = 0x3E7 jbe 0x51654 cmpq $0x2710, %r8 # imm = 0x2710 jb 0x51665 movq %r8, %rax mulq %r10 shrq $0xb, %rdx addl $0x4, %r9d cmpq $0x1869f, %r8 # imm = 0x1869F movq %rdx, %r8 ja 0x5159a addl $-0x3, %r9d jmp 0x51665 movq (%rdi), %rdi movq (%rdi), %rax movq (%rax), %rax movl $0x30, %esi jmpq *%rax movb $0x2d, (%rsi) negq %rcx movl $0x1, %r9d cmpq $0xa, %rcx jb 0x51662 movl $0x4, %r9d movabsq $0x346dc5d63886594b, %r10 # imm = 0x346DC5D63886594B movq %rcx, %r8 cmpq $0x63, %r8 jbe 0x51659 cmpq $0x3e7, %r8 # imm = 0x3E7 jbe 0x5165f cmpq $0x2710, %r8 # imm = 0x2710 jb 0x51662 movq %r8, %rax mulq %r10 shrq $0xb, %rdx addl $0x4, %r9d cmpq $0x1869f, %r8 # imm = 0x1869F movq %rdx, %r8 ja 0x51616 addl $-0x3, %r9d jmp 0x51662 addl $-0x2, %r9d jmp 0x51665 decl %r9d jmp 0x51665 addl $-0x2, %r9d jmp 0x51662 decl %r9d incl %r9d pushq %rbx movl %r9d, %r8d leaq (%rsi,%r8), %r9 leaq 0xd403(%rip), %r10 # 0x5ea77 cmpq $0x64, %rcx jb 0x516b5 movabsq $0x28f5c28f5c28f5c3, %r11 # imm = 0x28F5C28F5C28F5C3 movq %rcx, %rax shrq $0x2, %rax mulq %r11 shrq $0x2, %rdx imull $0x64, %edx, %eax movl %ecx, %ebx subl %eax, %ebx movzwl (%r10,%rbx,2), %eax movw %ax, -0x2(%r9) addq $-0x2, %r9 cmpq $0x270f, %rcx # imm = 0x270F movq %rdx, %rcx ja 0x51684 jmp 0x516b8 movq %rcx, %rdx cmpq $0xa, %rdx jb 0x516d4 movb (%r10,%rdx,2), %al movb 0x1(%r10,%rdx,2), %cl movb %cl, -0x1(%r9) movq $-0x2, %rcx jmp 0x516e0 orb $0x30, %dl movq $-0x1, %rcx movl %edx, %eax movb %al, (%r9,%rcx) movq (%rdi), %rdi movq (%rdi), %rax movq 0x8(%rax), %rax movq %r8, %rdx popq %rbx jmpq *%rax
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_: test rsi, rsi jz short loc_515E1 mov rcx, rsi lea rsi, [rdi+10h] test rcx, rcx js short loc_515F1 mov r9d, 1 cmp rcx, 0Ah jb loc_51665 mov r9d, 4 mov r10, 346DC5D63886594Bh mov r8, rcx loc_5159A: cmp r8, 63h ; 'c' jbe loc_5164E cmp r8, 3E7h jbe loc_51654 cmp r8, 2710h jb loc_51665 mov rax, r8 mul r10 shr rdx, 0Bh add r9d, 4 cmp r8, 1869Fh mov r8, rdx ja short loc_5159A add r9d, 0FFFFFFFDh jmp loc_51665 loc_515E1: mov rdi, [rdi] mov rax, [rdi] mov rax, [rax] mov esi, 30h ; '0' jmp rax loc_515F1: mov byte ptr [rsi], 2Dh ; '-' neg rcx mov r9d, 1 cmp rcx, 0Ah jb short loc_51662 mov r9d, 4 mov r10, 346DC5D63886594Bh mov r8, rcx loc_51616: cmp r8, 63h ; 'c' jbe short loc_51659 cmp r8, 3E7h jbe short loc_5165F cmp r8, 2710h jb short loc_51662 mov rax, r8 mul r10 shr rdx, 0Bh add r9d, 4 cmp r8, 1869Fh mov r8, rdx ja short loc_51616 add r9d, 0FFFFFFFDh jmp short loc_51662 loc_5164E: add r9d, 0FFFFFFFEh jmp short loc_51665 loc_51654: dec r9d jmp short loc_51665 loc_51659: add r9d, 0FFFFFFFEh jmp short loc_51662 loc_5165F: dec r9d loc_51662: inc r9d loc_51665: push rbx mov r8d, r9d lea r9, [rsi+r8] lea r10, _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99; "000102030405060708091011121314151617181"... cmp rcx, 64h ; 'd' jb short loc_516B5 mov r11, 28F5C28F5C28F5C3h loc_51684: mov rax, rcx shr rax, 2 mul r11 shr rdx, 2 imul eax, edx, 64h ; 'd' mov ebx, ecx sub ebx, eax movzx eax, word ptr [r10+rbx*2] mov [r9-2], ax add r9, 0FFFFFFFFFFFFFFFEh cmp rcx, 270Fh mov rcx, rdx ja short loc_51684 jmp short loc_516B8 loc_516B5: mov rdx, rcx loc_516B8: cmp rdx, 0Ah jb short loc_516D4 mov al, [r10+rdx*2] mov cl, [r10+rdx*2+1] mov [r9-1], cl mov rcx, 0FFFFFFFFFFFFFFFEh jmp short loc_516E0 loc_516D4: or dl, 30h mov rcx, 0FFFFFFFFFFFFFFFFh mov eax, edx loc_516E0: mov [r9+rcx], al mov rdi, [rdi] mov rax, [rdi] mov rax, [rax+8] mov rdx, r8 pop rbx jmp rax
long long ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_( _QWORD *a1, unsigned long long a2) { unsigned long long v2; // rcx _BYTE *v3; // rsi unsigned int v4; // r9d unsigned long long v5; // r8 bool v6; // cc int v8; // r9d unsigned long long v9; // r8 long long v10; // r8 _BYTE *v11; // r9 unsigned long long v12; // rdx char v13; // al long long v14; // rcx if ( !a2 ) return (**(long long ( ***)(_QWORD, long long))*a1)(*a1, 48LL); v2 = a2; v3 = a1 + 2; if ( (v2 & 0x8000000000000000LL) != 0LL ) { *v3 = 45; v2 = -(long long)v2; v8 = 1; if ( v2 >= 0xA ) { v8 = 4; v9 = v2; while ( 1 ) { if ( v9 <= 0x63 ) { v8 -= 2; goto LABEL_22; } if ( v9 <= 0x3E7 ) break; if ( v9 < 0x2710 ) goto LABEL_22; v8 += 4; v6 = v9 <= 0x1869F; v9 /= 0x2710uLL; if ( v6 ) { v8 -= 3; goto LABEL_22; } } --v8; } LABEL_22: v4 = v8 + 1; } else { v4 = 1; if ( v2 >= 0xA ) { v4 = 4; v5 = v2; while ( 1 ) { if ( v5 <= 0x63 ) { v4 -= 2; goto LABEL_23; } if ( v5 <= 0x3E7 ) break; if ( v5 < 0x2710 ) goto LABEL_23; v4 += 4; v6 = v5 <= 0x1869F; v5 /= 0x2710uLL; if ( v6 ) { v4 -= 3; goto LABEL_23; } } --v4; } } LABEL_23: v10 = v4; v11 = &v3[v4]; if ( v2 < 0x64 ) { v12 = v2; } else { do { v12 = v2 / 0x64; *((_WORD *)v11 - 1) = *(_WORD *)&ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99[2 * (v2 % 0x64)]; v11 -= 2; v6 = v2 <= 0x270F; v2 /= 0x64uLL; } while ( !v6 ); } if ( v12 < 0xA ) { v14 = -1LL; v13 = v12 | 0x30; } else { v13 = ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99[2 * v12]; *(v11 - 1) = ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99[2 * v12 + 1]; v14 = -2LL; } v11[v14] = v13; return (*(long long ( **)(_QWORD, _BYTE *, long long))(*(_QWORD *)*a1 + 8LL))(*a1, v3, v10); }
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_: TEST RSI,RSI JZ 0x001515e1 MOV RCX,RSI LEA RSI,[RDI + 0x10] TEST RCX,RCX JS 0x001515f1 MOV R9D,0x1 CMP RCX,0xa JC 0x00151665 MOV R9D,0x4 MOV R10,0x346dc5d63886594b MOV R8,RCX LAB_0015159a: CMP R8,0x63 JBE 0x0015164e CMP R8,0x3e7 JBE 0x00151654 CMP R8,0x2710 JC 0x00151665 MOV RAX,R8 MUL R10 SHR RDX,0xb ADD R9D,0x4 CMP R8,0x1869f MOV R8,RDX JA 0x0015159a ADD R9D,-0x3 JMP 0x00151665 LAB_001515e1: MOV RDI,qword ptr [RDI] MOV RAX,qword ptr [RDI] MOV RAX,qword ptr [RAX] MOV ESI,0x30 JMP RAX LAB_001515f1: MOV byte ptr [RSI],0x2d NEG RCX MOV R9D,0x1 CMP RCX,0xa JC 0x00151662 MOV R9D,0x4 MOV R10,0x346dc5d63886594b MOV R8,RCX LAB_00151616: CMP R8,0x63 JBE 0x00151659 CMP R8,0x3e7 JBE 0x0015165f CMP R8,0x2710 JC 0x00151662 MOV RAX,R8 MUL R10 SHR RDX,0xb ADD R9D,0x4 CMP R8,0x1869f MOV R8,RDX JA 0x00151616 ADD R9D,-0x3 JMP 0x00151662 LAB_0015164e: ADD R9D,-0x2 JMP 0x00151665 LAB_00151654: DEC R9D JMP 0x00151665 LAB_00151659: ADD R9D,-0x2 JMP 0x00151662 LAB_0015165f: DEC R9D LAB_00151662: INC R9D LAB_00151665: PUSH RBX MOV R8D,R9D LEA R9,[RSI + R8*0x1] LEA R10,[0x15ea77] CMP RCX,0x64 JC 0x001516b5 MOV R11,0x28f5c28f5c28f5c3 LAB_00151684: MOV RAX,RCX SHR RAX,0x2 MUL R11 SHR RDX,0x2 IMUL EAX,EDX,0x64 MOV EBX,ECX SUB EBX,EAX MOVZX EAX,word ptr [R10 + RBX*0x2] MOV word ptr [R9 + -0x2],AX ADD R9,-0x2 CMP RCX,0x270f MOV RCX,RDX JA 0x00151684 JMP 0x001516b8 LAB_001516b5: MOV RDX,RCX LAB_001516b8: CMP RDX,0xa JC 0x001516d4 MOV AL,byte ptr [R10 + RDX*0x2] MOV CL,byte ptr [R10 + RDX*0x2 + 0x1] MOV byte ptr [R9 + -0x1],CL MOV RCX,-0x2 JMP 0x001516e0 LAB_001516d4: OR DL,0x30 MOV RCX,-0x1 MOV EAX,EDX LAB_001516e0: MOV byte ptr [R9 + RCX*0x1],AL MOV RDI,qword ptr [RDI] MOV RAX,qword ptr [RDI] MOV RAX,qword ptr [RAX + 0x8] MOV RDX,R8 POP RBX JMP RAX
void _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_ (int8 *param_1,ulong param_2) { int8 *puVar1; bool bVar2; uint uVar3; int iVar4; long lVar5; byte bVar6; ulong uVar7; uint uVar8; int iVar9; int1 *puVar10; if (param_2 == 0) { /* WARNING: Could not recover jumptable at 0x001515ef. Too many branches */ /* WARNING: Treating indirect jump as call */ (*(code *)**(int8 **)*param_1)((int8 *)*param_1,0x30); return; } puVar1 = param_1 + 2; if ((long)param_2 < 0) { *(int1 *)puVar1 = 0x2d; param_2 = -param_2; iVar9 = 1; if (9 < param_2) { uVar7 = param_2; iVar4 = 4; do { iVar9 = iVar4; if (uVar7 < 100) { iVar9 = iVar9 + -2; goto LAB_00151662; } if (uVar7 < 1000) { iVar9 = iVar9 + -1; goto LAB_00151662; } if (uVar7 < 10000) goto LAB_00151662; bVar2 = 99999 < uVar7; uVar7 = uVar7 / 10000; iVar4 = iVar9 + 4; } while (bVar2); iVar9 = iVar9 + 1; } LAB_00151662: uVar8 = iVar9 + 1; } else { uVar8 = 1; if (9 < param_2) { uVar7 = param_2; uVar3 = 4; do { uVar8 = uVar3; if (uVar7 < 100) { uVar8 = uVar8 - 2; goto LAB_00151665; } if (uVar7 < 1000) { uVar8 = uVar8 - 1; goto LAB_00151665; } if (uVar7 < 10000) goto LAB_00151665; bVar2 = 99999 < uVar7; uVar7 = uVar7 / 10000; uVar3 = uVar8 + 4; } while (bVar2); uVar8 = uVar8 + 1; } } LAB_00151665: puVar10 = (int1 *)((long)puVar1 + (ulong)uVar8); uVar7 = param_2; if (99 < param_2) { do { uVar7 = param_2 / 100; *(int2 *)(puVar10 + -2) = *(int2 *) ( _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 + (ulong)(uint)((int)param_2 + (int)uVar7 * -100) * 2); puVar10 = puVar10 + -2; bVar2 = 9999 < param_2; param_2 = uVar7; } while (bVar2); } if (uVar7 < 10) { bVar6 = (byte)uVar7 | 0x30; lVar5 = -1; } else { bVar6 = _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 [uVar7 * 2]; puVar10[-1] = _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 [uVar7 * 2 + 1]; lVar5 = -2; } puVar10[lVar5] = bVar6; /* WARNING: Could not recover jumptable at 0x001516f2. Too many branches */ /* WARNING: Treating indirect jump as call */ (**(code **)(*(long *)*param_1 + 8))((long *)*param_1,puVar1,(ulong)uVar8); return; }
3,507
void nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::dump_integer<unsigned char, 0>(unsigned char)
hkr04[P]cpp-mcp/common/json.hpp
void dump_integer(NumberType x) { static constexpr std::array<std::array<char, 2>, 100> digits_to_99 { { {{'0', '0'}}, {{'0', '1'}}, {{'0', '2'}}, {{'0', '3'}}, {{'0', '4'}}, {{'0', '5'}}, {{'0', '6'}}, {{'0', '7'}}, {{'0', '8'}}, {{'0', '9'}}, {{'1', '0'}}, {{'1', '1'}}, {{'1', '2'}}, {{'1', '3'}}, {{'1', '4'}}, {{'1', '5'}}, {{'1', '6'}}, {{'1', '7'}}, {{'1', '8'}}, {{'1', '9'}}, {{'2', '0'}}, {{'2', '1'}}, {{'2', '2'}}, {{'2', '3'}}, {{'2', '4'}}, {{'2', '5'}}, {{'2', '6'}}, {{'2', '7'}}, {{'2', '8'}}, {{'2', '9'}}, {{'3', '0'}}, {{'3', '1'}}, {{'3', '2'}}, {{'3', '3'}}, {{'3', '4'}}, {{'3', '5'}}, {{'3', '6'}}, {{'3', '7'}}, {{'3', '8'}}, {{'3', '9'}}, {{'4', '0'}}, {{'4', '1'}}, {{'4', '2'}}, {{'4', '3'}}, {{'4', '4'}}, {{'4', '5'}}, {{'4', '6'}}, {{'4', '7'}}, {{'4', '8'}}, {{'4', '9'}}, {{'5', '0'}}, {{'5', '1'}}, {{'5', '2'}}, {{'5', '3'}}, {{'5', '4'}}, {{'5', '5'}}, {{'5', '6'}}, {{'5', '7'}}, {{'5', '8'}}, {{'5', '9'}}, {{'6', '0'}}, {{'6', '1'}}, {{'6', '2'}}, {{'6', '3'}}, {{'6', '4'}}, {{'6', '5'}}, {{'6', '6'}}, {{'6', '7'}}, {{'6', '8'}}, {{'6', '9'}}, {{'7', '0'}}, {{'7', '1'}}, {{'7', '2'}}, {{'7', '3'}}, {{'7', '4'}}, {{'7', '5'}}, {{'7', '6'}}, {{'7', '7'}}, {{'7', '8'}}, {{'7', '9'}}, {{'8', '0'}}, {{'8', '1'}}, {{'8', '2'}}, {{'8', '3'}}, {{'8', '4'}}, {{'8', '5'}}, {{'8', '6'}}, {{'8', '7'}}, {{'8', '8'}}, {{'8', '9'}}, {{'9', '0'}}, {{'9', '1'}}, {{'9', '2'}}, {{'9', '3'}}, {{'9', '4'}}, {{'9', '5'}}, {{'9', '6'}}, {{'9', '7'}}, {{'9', '8'}}, {{'9', '9'}}, } }; // special case for "0" if (x == 0) { o->write_character('0'); return; } // use a pointer to fill the buffer auto buffer_ptr = number_buffer.begin(); // NOLINT(llvm-qualified-auto,readability-qualified-auto,cppcoreguidelines-pro-type-vararg,hicpp-vararg) number_unsigned_t abs_value; unsigned int n_chars{}; if (is_negative_number(x)) { *buffer_ptr = '-'; abs_value = remove_sign(static_cast<number_integer_t>(x)); // account one more byte for the minus sign n_chars = 1 + count_digits(abs_value); } else { abs_value = static_cast<number_unsigned_t>(x); n_chars = count_digits(abs_value); } // spare 1 byte for '\0' JSON_ASSERT(n_chars < number_buffer.size() - 1); // jump to the end to generate the string from backward, // so we later avoid reversing the result buffer_ptr += n_chars; // Fast int2ascii implementation inspired by "Fastware" talk by Andrei Alexandrescu // See: https://www.youtube.com/watch?v=o4-CwDo2zpg while (abs_value >= 100) { const auto digits_index = static_cast<unsigned>((abs_value % 100)); abs_value /= 100; *(--buffer_ptr) = digits_to_99[digits_index][1]; *(--buffer_ptr) = digits_to_99[digits_index][0]; } if (abs_value >= 10) { const auto digits_index = static_cast<unsigned>(abs_value); *(--buffer_ptr) = digits_to_99[digits_index][1]; *(--buffer_ptr) = digits_to_99[digits_index][0]; } else { *(--buffer_ptr) = static_cast<char>('0' + abs_value); } o->write_characters(number_buffer.data(), n_chars); }
O3
cpp
void nlohmann::json_abi_v3_11_3::detail::serializer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>::dump_integer<unsigned char, 0>(unsigned char): testq %rsi, %rsi je 0x50097 pushq %rbx movq %rsi, %rcx leaq 0x10(%rdi), %rsi testq %rcx, %rcx js 0x500a7 cmpq $0xa, %rcx jae 0x50110 leaq 0x11(%rdi), %r9 movl $0x1, %r8d jmp 0x501d9 movq (%rdi), %rdi movq (%rdi), %rax movq (%rax), %rax movl $0x30, %esi jmpq *%rax movb $0x2d, (%rsi) negq %rcx movl $0x1, %r9d cmpq $0xa, %rcx jb 0x5016f movl $0x4, %r9d movabsq $0x346dc5d63886594b, %r10 # imm = 0x346DC5D63886594B movq %rcx, %r8 cmpq $0x63, %r8 jbe 0x50166 cmpq $0x3e7, %r8 # imm = 0x3E7 jbe 0x5016c cmpq $0x2710, %r8 # imm = 0x2710 jb 0x5016f movq %r8, %rax mulq %r10 shrq $0xb, %rdx addl $0x4, %r9d cmpq $0x1869f, %r8 # imm = 0x1869F movq %rdx, %r8 ja 0x500d0 addl $-0x3, %r9d jmp 0x5016f movl $0x4, %r9d movabsq $0x346dc5d63886594b, %r10 # imm = 0x346DC5D63886594B movq %rcx, %r8 cmpq $0x63, %r8 jbe 0x5015b cmpq $0x3e7, %r8 # imm = 0x3E7 jbe 0x50161 cmpq $0x2710, %r8 # imm = 0x2710 jb 0x50172 movq %r8, %rax mulq %r10 shrq $0xb, %rdx addl $0x4, %r9d cmpq $0x1869f, %r8 # imm = 0x1869F movq %rdx, %r8 ja 0x50123 addl $-0x3, %r9d jmp 0x50172 addl $-0x2, %r9d jmp 0x50172 decl %r9d jmp 0x50172 addl $-0x2, %r9d jmp 0x5016f decl %r9d incl %r9d movl %r9d, %r8d leaq (%rsi,%r8), %r9 leaq 0xd6ec(%rip), %r10 # 0x5d86c cmpq $0x64, %rcx jb 0x501c1 movabsq $0x28f5c28f5c28f5c3, %r11 # imm = 0x28F5C28F5C28F5C3 movq %rcx, %rax shrq $0x2, %rax mulq %r11 shrq $0x2, %rdx imull $0x64, %edx, %eax movl %ecx, %ebx subl %eax, %ebx movzwl (%r10,%rbx,2), %eax movw %ax, -0x2(%r9) addq $-0x2, %r9 cmpq $0x270f, %rcx # imm = 0x270F movq %rdx, %rcx ja 0x50190 jmp 0x501c4 movq %rcx, %rdx cmpq $0xa, %rdx jb 0x501d6 movzwl (%r10,%rdx,2), %eax movw %ax, -0x2(%r9) jmp 0x501e0 movq %rdx, %rcx orb $0x30, %cl movb %cl, -0x1(%r9) movq (%rdi), %rdi movq (%rdi), %rax movq 0x8(%rax), %rax movq %r8, %rdx popq %rbx jmpq *%rax
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_: test rsi, rsi jz short loc_50097 push rbx mov rcx, rsi lea rsi, [rdi+10h] test rcx, rcx js short loc_500A7 cmp rcx, 0Ah jnb loc_50110 lea r9, [rdi+11h] mov r8d, 1 jmp loc_501D9 loc_50097: mov rdi, [rdi] mov rax, [rdi] mov rax, [rax] mov esi, 30h ; '0' jmp rax loc_500A7: mov byte ptr [rsi], 2Dh ; '-' neg rcx mov r9d, 1 cmp rcx, 0Ah jb loc_5016F mov r9d, 4 mov r10, 346DC5D63886594Bh mov r8, rcx loc_500D0: cmp r8, 63h ; 'c' jbe loc_50166 cmp r8, 3E7h jbe loc_5016C cmp r8, 2710h jb short loc_5016F mov rax, r8 mul r10 shr rdx, 0Bh add r9d, 4 cmp r8, 1869Fh mov r8, rdx ja short loc_500D0 add r9d, 0FFFFFFFDh jmp short loc_5016F loc_50110: mov r9d, 4 mov r10, 346DC5D63886594Bh mov r8, rcx loc_50123: cmp r8, 63h ; 'c' jbe short loc_5015B cmp r8, 3E7h jbe short loc_50161 cmp r8, 2710h jb short loc_50172 mov rax, r8 mul r10 shr rdx, 0Bh add r9d, 4 cmp r8, 1869Fh mov r8, rdx ja short loc_50123 add r9d, 0FFFFFFFDh jmp short loc_50172 loc_5015B: add r9d, 0FFFFFFFEh jmp short loc_50172 loc_50161: dec r9d jmp short loc_50172 loc_50166: add r9d, 0FFFFFFFEh jmp short loc_5016F loc_5016C: dec r9d loc_5016F: inc r9d loc_50172: mov r8d, r9d lea r9, [rsi+r8] lea r10, _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99; "000102030405060708091011121314151617181"... cmp rcx, 64h ; 'd' jb short loc_501C1 mov r11, 28F5C28F5C28F5C3h loc_50190: mov rax, rcx shr rax, 2 mul r11 shr rdx, 2 imul eax, edx, 64h ; 'd' mov ebx, ecx sub ebx, eax movzx eax, word ptr [r10+rbx*2] mov [r9-2], ax add r9, 0FFFFFFFFFFFFFFFEh cmp rcx, 270Fh mov rcx, rdx ja short loc_50190 jmp short loc_501C4 loc_501C1: mov rdx, rcx loc_501C4: cmp rdx, 0Ah jb short loc_501D6 movzx eax, word ptr [r10+rdx*2] mov [r9-2], ax jmp short loc_501E0 loc_501D6: mov rcx, rdx loc_501D9: or cl, 30h mov [r9-1], cl loc_501E0: mov rdi, [rdi] mov rax, [rdi] mov rax, [rax+8] mov rdx, r8 pop rbx jmp rax
long long ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_( _QWORD *a1, unsigned long long a2) { unsigned long long v2; // rcx _BYTE *v3; // rsi char *v4; // r9 long long v5; // r8 int v7; // r9d unsigned long long v8; // r8 bool v9; // cc unsigned int v10; // r9d unsigned long long v11; // r8 unsigned long long v12; // rdx if ( !a2 ) return (**(long long ( ***)(_QWORD, long long))*a1)(*a1, 48LL); v2 = a2; v3 = a1 + 2; if ( (v2 & 0x8000000000000000LL) != 0LL ) { *v3 = 45; v2 = -(long long)v2; v7 = 1; if ( v2 >= 0xA ) { v7 = 4; v8 = v2; while ( 1 ) { if ( v8 <= 0x63 ) { v7 -= 2; goto LABEL_23; } if ( v8 <= 0x3E7 ) break; if ( v8 < 0x2710 ) goto LABEL_23; v7 += 4; v9 = v8 <= 0x1869F; v8 /= 0x2710uLL; if ( v9 ) { v7 -= 3; goto LABEL_23; } } --v7; } LABEL_23: v10 = v7 + 1; } else { if ( v2 < 0xA ) { v4 = (char *)a1 + 17; v5 = 1LL; LABEL_31: LOBYTE(v2) = v2 | 0x30; *(v4 - 1) = v2; return (*(long long ( **)(_QWORD, _BYTE *, long long, unsigned long long))(*(_QWORD *)*a1 + 8LL))( *a1, v3, v5, v2); } v10 = 4; v11 = v2; while ( 1 ) { if ( v11 <= 0x63 ) { v10 -= 2; goto LABEL_24; } if ( v11 <= 0x3E7 ) break; if ( v11 < 0x2710 ) goto LABEL_24; v10 += 4; v9 = v11 <= 0x1869F; v11 /= 0x2710uLL; if ( v9 ) { v10 -= 3; goto LABEL_24; } } --v10; } LABEL_24: v5 = v10; v4 = &v3[v10]; if ( v2 < 0x64 ) { v12 = v2; } else { do { v12 = v2 / 0x64; *((_WORD *)v4 - 1) = *(_WORD *)&ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99[2 * (v2 % 0x64)]; v4 -= 2; v9 = v2 <= 0x270F; v2 /= 0x64uLL; } while ( !v9 ); } if ( v12 < 0xA ) { v2 = v12; goto LABEL_31; } *((_WORD *)v4 - 1) = *(_WORD *)&ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99[2 * v12]; return (*(long long ( **)(_QWORD, _BYTE *, long long, unsigned long long))(*(_QWORD *)*a1 + 8LL))(*a1, v3, v5, v2); }
_ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_: TEST RSI,RSI JZ 0x00150097 PUSH RBX MOV RCX,RSI LEA RSI,[RDI + 0x10] TEST RCX,RCX JS 0x001500a7 CMP RCX,0xa JNC 0x00150110 LEA R9,[RDI + 0x11] MOV R8D,0x1 JMP 0x001501d9 LAB_00150097: MOV RDI,qword ptr [RDI] MOV RAX,qword ptr [RDI] MOV RAX,qword ptr [RAX] MOV ESI,0x30 JMP RAX LAB_001500a7: MOV byte ptr [RSI],0x2d NEG RCX MOV R9D,0x1 CMP RCX,0xa JC 0x0015016f MOV R9D,0x4 MOV R10,0x346dc5d63886594b MOV R8,RCX LAB_001500d0: CMP R8,0x63 JBE 0x00150166 CMP R8,0x3e7 JBE 0x0015016c CMP R8,0x2710 JC 0x0015016f MOV RAX,R8 MUL R10 SHR RDX,0xb ADD R9D,0x4 CMP R8,0x1869f MOV R8,RDX JA 0x001500d0 ADD R9D,-0x3 JMP 0x0015016f LAB_00150110: MOV R9D,0x4 MOV R10,0x346dc5d63886594b MOV R8,RCX LAB_00150123: CMP R8,0x63 JBE 0x0015015b CMP R8,0x3e7 JBE 0x00150161 CMP R8,0x2710 JC 0x00150172 MOV RAX,R8 MUL R10 SHR RDX,0xb ADD R9D,0x4 CMP R8,0x1869f MOV R8,RDX JA 0x00150123 ADD R9D,-0x3 JMP 0x00150172 LAB_0015015b: ADD R9D,-0x2 JMP 0x00150172 LAB_00150161: DEC R9D JMP 0x00150172 LAB_00150166: ADD R9D,-0x2 JMP 0x0015016f LAB_0015016c: DEC R9D LAB_0015016f: INC R9D LAB_00150172: MOV R8D,R9D LEA R9,[RSI + R8*0x1] LEA R10,[0x15d86c] CMP RCX,0x64 JC 0x001501c1 MOV R11,0x28f5c28f5c28f5c3 LAB_00150190: MOV RAX,RCX SHR RAX,0x2 MUL R11 SHR RDX,0x2 IMUL EAX,EDX,0x64 MOV EBX,ECX SUB EBX,EAX MOVZX EAX,word ptr [R10 + RBX*0x2] MOV word ptr [R9 + -0x2],AX ADD R9,-0x2 CMP RCX,0x270f MOV RCX,RDX JA 0x00150190 JMP 0x001501c4 LAB_001501c1: MOV RDX,RCX LAB_001501c4: CMP RDX,0xa JC 0x001501d6 MOVZX EAX,word ptr [R10 + RDX*0x2] MOV word ptr [R9 + -0x2],AX JMP 0x001501e0 LAB_001501d6: MOV RCX,RDX LAB_001501d9: OR CL,0x30 MOV byte ptr [R9 + -0x1],CL LAB_001501e0: MOV RDI,qword ptr [RDI] MOV RAX,qword ptr [RDI] MOV RAX,qword ptr [RAX + 0x8] MOV RDX,R8 POP RBX JMP RAX
void _ZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_ (int8 *param_1,ulong param_2) { int8 *puVar1; bool bVar2; int iVar3; uint uVar4; ulong uVar5; ulong uVar6; int iVar7; uint uVar8; int1 *puVar9; if (param_2 == 0) { /* WARNING: Could not recover jumptable at 0x001500a5. Too many branches */ /* WARNING: Treating indirect jump as call */ (*(code *)**(int8 **)*param_1)((int8 *)*param_1,0x30); return; } puVar1 = param_1 + 2; if ((long)param_2 < 0) { *(int1 *)puVar1 = 0x2d; param_2 = -param_2; iVar7 = 1; if (9 < param_2) { uVar6 = param_2; iVar3 = 4; do { iVar7 = iVar3; if (uVar6 < 100) { iVar7 = iVar7 + -2; goto LAB_0015016f; } if (uVar6 < 1000) { iVar7 = iVar7 + -1; goto LAB_0015016f; } if (uVar6 < 10000) goto LAB_0015016f; bVar2 = 99999 < uVar6; uVar6 = uVar6 / 10000; iVar3 = iVar7 + 4; } while (bVar2); iVar7 = iVar7 + 1; } LAB_0015016f: uVar8 = iVar7 + 1; LAB_00150172: uVar6 = (ulong)uVar8; puVar9 = (int1 *)((long)puVar1 + uVar6); if (99 < param_2) { do { uVar5 = param_2 / 100; *(int2 *)(puVar9 + -2) = *(int2 *) ( _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 + (ulong)(uint)((int)param_2 + (int)uVar5 * -100) * 2); puVar9 = puVar9 + -2; bVar2 = 9999 < param_2; param_2 = uVar5; } while (bVar2); } if (9 < param_2) { *(int2 *)(puVar9 + -2) = *(int2 *) ( _ZZN8nlohmann16json_abi_v3_11_36detail10serializerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE12dump_integerIlTnNSt9enable_ifIXoooooosr3std11is_integralIT_EE5valuesr3std7is_sameISJ_mEE5valuesr3std7is_sameISJ_lEE5valuesr3std7is_sameISJ_hEE5valueEiE4typeELi0EEEvSJ_E12digits_to_99 + param_2 * 2); goto LAB_001501e0; } } else { if (9 < param_2) { uVar6 = param_2; uVar4 = 4; do { uVar8 = uVar4; if (uVar6 < 100) { uVar8 = uVar8 - 2; goto LAB_00150172; } if (uVar6 < 1000) { uVar8 = uVar8 - 1; goto LAB_00150172; } if (uVar6 < 10000) goto LAB_00150172; bVar2 = 99999 < uVar6; uVar6 = uVar6 / 10000; uVar4 = uVar8 + 4; } while (bVar2); uVar8 = uVar8 + 1; goto LAB_00150172; } puVar9 = (int1 *)((long)param_1 + 0x11); uVar6 = 1; } puVar9[-1] = (byte)param_2 | 0x30; LAB_001501e0: /* WARNING: Could not recover jumptable at 0x001501ee. Too many branches */ /* WARNING: Treating indirect jump as call */ (**(code **)(*(long *)*param_1 + 8))((long *)*param_1,puVar1,uVar6); return; }
3,508
trnman_destroy
eloqsql/storage/maria/trnman.c
void trnman_destroy() { DBUG_ENTER("trnman_destroy"); if (short_trid_to_active_trn == NULL) /* trnman already destroyed */ DBUG_VOID_RETURN; DBUG_ASSERT(trid_to_trn.count == 0); DBUG_ASSERT(trnman_active_transactions == 0); DBUG_ASSERT(trnman_committed_transactions == 0); DBUG_ASSERT(active_list_max.prev == &active_list_min); DBUG_ASSERT(active_list_min.next == &active_list_max); DBUG_ASSERT(committed_list_max.prev == &committed_list_min); DBUG_ASSERT(committed_list_min.next == &committed_list_max); while (pool) { TRN *trn= pool; pool= pool->next; DBUG_ASSERT(trn->wt == NULL); mysql_mutex_destroy(&trn->state_lock); my_free(trn); } lf_hash_destroy(&trid_to_trn); DBUG_PRINT("info", ("mysql_mutex_destroy LOCK_trn_list")); mysql_mutex_destroy(&LOCK_trn_list); my_free(short_trid_to_active_trn+1); short_trid_to_active_trn= NULL; DBUG_VOID_RETURN; }
O3
c
trnman_destroy: cmpq $0x0, 0xba4e23(%rip) # 0xc081f0 je 0x63487 pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx movq 0xba50e7(%rip), %rbx # 0xc084c8 testq %rbx, %rbx je 0x6342c leaq 0x32be6b(%rip), %r14 # 0x38f258 movq 0x68(%rbx), %rax movq %rax, 0xba50d0(%rip) # 0xc084c8 movq 0x50(%rbx), %rdi testq %rdi, %rdi je 0x6340f movq (%r14), %rax callq *0x48(%rax) movq $0x0, 0x50(%rbx) leaq 0x10(%rbx), %rdi callq 0x2a0e0 movq %rbx, %rdi callq 0xa6612 movq 0xba50a1(%rip), %rbx # 0xc084c8 testq %rbx, %rbx jne 0x633ed leaq 0xba50a5(%rip), %rdi # 0xc084d8 callq 0xac99a movq 0xba51a1(%rip), %rdi # 0xc085e0 testq %rdi, %rdi je 0x6345c leaq 0x32be0d(%rip), %rax # 0x38f258 movq (%rax), %rax callq *0x48(%rax) movq $0x0, 0xba5184(%rip) # 0xc085e0 leaq 0xba513d(%rip), %rdi # 0xc085a0 callq 0x2a0e0 movq 0xba4d81(%rip), %rdi # 0xc081f0 addq $0x8, %rdi callq 0xa6612 movq $0x0, 0xba4d6d(%rip) # 0xc081f0 popq %rbx popq %r14 popq %rbp retq
trnman_destroy: cmp cs:short_trid_to_active_trn, 0 jz locret_63487 push rbp mov rbp, rsp push r14 push rbx mov rbx, cs:pool test rbx, rbx jz short loc_6342C lea r14, PSI_server loc_633ED: mov rax, [rbx+68h] mov cs:pool, rax mov rdi, [rbx+50h] test rdi, rdi jz short loc_6340F mov rax, [r14] call qword ptr [rax+48h] mov qword ptr [rbx+50h], 0 loc_6340F: lea rdi, [rbx+10h] call _pthread_mutex_destroy mov rdi, rbx call my_free mov rbx, cs:pool test rbx, rbx jnz short loc_633ED loc_6342C: lea rdi, trid_to_trn call lf_hash_destroy mov rdi, cs:qword_C085E0 test rdi, rdi jz short loc_6345C lea rax, PSI_server mov rax, [rax] call qword ptr [rax+48h] mov cs:qword_C085E0, 0 loc_6345C: lea rdi, LOCK_trn_list call _pthread_mutex_destroy mov rdi, cs:short_trid_to_active_trn add rdi, 8 call my_free mov cs:short_trid_to_active_trn, 0 pop rbx pop r14 pop rbp locret_63487: retn
long long trnman_destroy() { long long i; // rbx long long result; // rax if ( short_trid_to_active_trn ) { for ( i = pool; pool; i = pool ) { pool = *(_QWORD *)(i + 104); if ( *(_QWORD *)(i + 80) ) { PSI_server[9](); *(_QWORD *)(i + 80) = 0LL; } pthread_mutex_destroy(i + 16); my_free(i); } lf_hash_destroy(&trid_to_trn); if ( qword_C085E0 ) { PSI_server[9](); qword_C085E0 = 0LL; } pthread_mutex_destroy(&LOCK_trn_list); result = my_free(short_trid_to_active_trn + 8); short_trid_to_active_trn = 0LL; } return result; }
trnman_destroy: CMP qword ptr [0x00d081f0],0x0 JZ 0x00163487 PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX MOV RBX,qword ptr [0x00d084c8] TEST RBX,RBX JZ 0x0016342c LEA R14,[0x48f258] LAB_001633ed: MOV RAX,qword ptr [RBX + 0x68] MOV qword ptr [0x00d084c8],RAX MOV RDI,qword ptr [RBX + 0x50] TEST RDI,RDI JZ 0x0016340f MOV RAX,qword ptr [R14] CALL qword ptr [RAX + 0x48] MOV qword ptr [RBX + 0x50],0x0 LAB_0016340f: LEA RDI,[RBX + 0x10] CALL 0x0012a0e0 MOV RDI,RBX CALL 0x001a6612 MOV RBX,qword ptr [0x00d084c8] TEST RBX,RBX JNZ 0x001633ed LAB_0016342c: LEA RDI,[0xd084d8] CALL 0x001ac99a MOV RDI,qword ptr [0x00d085e0] TEST RDI,RDI JZ 0x0016345c LEA RAX,[0x48f258] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x48] MOV qword ptr [0x00d085e0],0x0 LAB_0016345c: LEA RDI,[0xd085a0] CALL 0x0012a0e0 MOV RDI,qword ptr [0x00d081f0] ADD RDI,0x8 CALL 0x001a6612 MOV qword ptr [0x00d081f0],0x0 POP RBX POP R14 POP RBP LAB_00163487: RET
void trnman_destroy(void) { long lVar1; if (short_trid_to_active_trn != 0) { lVar1 = pool; if (pool != 0) { do { pool = *(long *)(lVar1 + 0x68); if (*(long *)(lVar1 + 0x50) != 0) { (**(code **)(PSI_server + 0x48))(); *(int8 *)(lVar1 + 0x50) = 0; } pthread_mutex_destroy((pthread_mutex_t *)(lVar1 + 0x10)); my_free(lVar1); lVar1 = pool; } while (pool != 0); } lf_hash_destroy(trid_to_trn); if (LOCK_trn_list._64_8_ != 0) { (**(code **)(PSI_server + 0x48))(); LOCK_trn_list._64_8_ = 0; } pthread_mutex_destroy((pthread_mutex_t *)LOCK_trn_list); my_free(short_trid_to_active_trn + 8); short_trid_to_active_trn = 0; } return; }
3,509
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>> nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::erase<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, 0>(nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>)
llama.cpp/common/json.hpp
IteratorType erase(IteratorType pos) { // make sure iterator fits the current value if (JSON_HEDLEY_UNLIKELY(this != pos.m_object)) { JSON_THROW(invalid_iterator::create(202, "iterator does not fit current value", this)); } IteratorType result = end(); switch (m_data.m_type) { case value_t::boolean: case value_t::number_float: case value_t::number_integer: case value_t::number_unsigned: case value_t::string: case value_t::binary: { if (JSON_HEDLEY_UNLIKELY(!pos.m_it.primitive_iterator.is_begin())) { JSON_THROW(invalid_iterator::create(205, "iterator out of range", this)); } if (is_string()) { AllocatorType<string_t> alloc; std::allocator_traits<decltype(alloc)>::destroy(alloc, m_data.m_value.string); std::allocator_traits<decltype(alloc)>::deallocate(alloc, m_data.m_value.string, 1); m_data.m_value.string = nullptr; } else if (is_binary()) { AllocatorType<binary_t> alloc; std::allocator_traits<decltype(alloc)>::destroy(alloc, m_data.m_value.binary); std::allocator_traits<decltype(alloc)>::deallocate(alloc, m_data.m_value.binary, 1); m_data.m_value.binary = nullptr; } m_data.m_type = value_t::null; assert_invariant(); break; } case value_t::object: { result.m_it.object_iterator = m_data.m_value.object->erase(pos.m_it.object_iterator); break; } case value_t::array: { result.m_it.array_iterator = m_data.m_value.array->erase(pos.m_it.array_iterator); break; } case value_t::null: case value_t::discarded: default: JSON_THROW(type_error::create(307, detail::concat("cannot use erase() with ", type_name()), this)); } return result; }
O3
cpp
nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>> nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::erase<nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>, 0>(nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>): pushq %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x30, %rsp movq %rsi, %r14 cmpq %rsi, (%rdx) jne 0x8bb0b movq %rdx, %r15 movq %rdi, %rbx movq %r14, (%rdi) xorps %xmm0, %xmm0 movups %xmm0, 0x8(%rdi) movabsq $-0x8000000000000000, %rax # imm = 0x8000000000000000 movq %rax, 0x18(%rdi) callq 0x8ca22 movzbl (%r14), %eax leal -0x3(%rax), %ecx cmpl $0x6, %ecx jae 0x8ba78 cmpq $0x0, 0x18(%r15) jne 0x8bb6e cmpl $0x8, %eax je 0x8ba99 cmpl $0x3, %eax jne 0x8bacc leaq 0x8(%r14), %r15 movq 0x8(%r14), %rdi movq (%rdi), %rax leaq 0x10(%rdi), %rcx cmpq %rcx, %rax je 0x8ba71 movq (%rcx), %rsi incq %rsi movq %rax, %rdi callq 0x21190 movq (%r15), %rdi movl $0x20, %esi jmp 0x8bac0 cmpl $0x1, %eax je 0x8baed cmpl $0x2, %eax jne 0x8bbce movq 0x8(%r14), %rdi movq 0x10(%r15), %rsi callq 0x8d0e2 movq %rax, 0x10(%rbx) jmp 0x8badd leaq 0x8(%r14), %r15 movq 0x8(%r14), %rdi movq (%rdi), %rax testq %rax, %rax je 0x8babb movq 0x10(%rdi), %rsi subq %rax, %rsi movq %rax, %rdi callq 0x21190 movq (%r15), %rdi movl $0x28, %esi callq 0x21190 movq $0x0, (%r15) movb $0x0, (%r14) movq %r14, %rdi movl $0x1, %esi callq 0x875ae movq %rbx, %rax addq $0x30, %rsp popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq movq %rbx, %r12 addq $0x8, %r12 movq 0x8(%r14), %rdi movq 0x8(%r15), %rsi leaq 0x30(%rsi), %rdx callq 0x8cc7e movq %rax, (%r12) jmp 0x8badd movl $0x20, %edi callq 0x216d0 movq %rax, %rbx leaq 0x18(%rsp), %r15 movq %r15, -0x10(%r15) leaq 0x90fb7(%rip), %rsi # 0x11cadf leaq 0x90fd3(%rip), %rdx # 0x11cb02 leaq 0x8(%rsp), %rdi callq 0x28f28 movb $0x1, %bpl leaq 0x8(%rsp), %rdx movq %rbx, %rdi movl $0xca, %esi movq %r14, %rcx callq 0x8c84a xorl %ebp, %ebp leaq 0xd74a6(%rip), %rsi # 0x163000 leaq -0x12f79(%rip), %rdx # 0x78be8 movq %rbx, %rdi callq 0x21b60 jmp 0x8bc2c movl $0x20, %edi callq 0x216d0 movq %rax, %rbx leaq 0x18(%rsp), %r15 movq %r15, -0x10(%r15) leaq 0x90f78(%rip), %rsi # 0x11cb03 leaq 0x90f86(%rip), %rdx # 0x11cb18 leaq 0x8(%rsp), %rdi callq 0x28f28 movb $0x1, %bpl leaq 0x8(%rsp), %rdx movq %rbx, %rdi movl $0xcd, %esi movq %r14, %rcx callq 0x8c84a xorl %ebp, %ebp leaq 0xd7443(%rip), %rsi # 0x163000 leaq -0x12fdc(%rip), %rdx # 0x78be8 movq %rbx, %rdi callq 0x21b60 jmp 0x8bc2c movl $0x20, %edi callq 0x216d0 movq %rax, %rbx movq %r14, %rdi callq 0x8cc60 leaq 0x28(%rsp), %rdx movq %rax, (%rdx) leaq 0x90f27(%rip), %rsi # 0x11cb19 leaq 0x8(%rsp), %rdi callq 0x7c930 movb $0x1, %bpl leaq 0x8(%rsp), %rdx movq %rbx, %rdi movl $0x133, %esi # imm = 0x133 movq %r14, %rcx callq 0x8ca88 xorl %ebp, %ebp leaq 0xd7423(%rip), %rsi # 0x163040 leaq -0x1303c(%rip), %rdx # 0x78be8 movq %rbx, %rdi callq 0x21b60 movq %rax, %r14 leaq 0x18(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi jne 0x8bc52 jmp 0x8bc5f jmp 0x8bc66 jmp 0x8bc45 jmp 0x8bc66 movq %rax, %r14 movq 0x8(%rsp), %rdi cmpq %r15, %rdi je 0x8bc5f movq 0x18(%rsp), %rsi incq %rsi callq 0x21190 testb %bpl, %bpl jne 0x8bc69 jmp 0x8bc71 movq %rax, %r14 movq %rbx, %rdi callq 0x22080 movq %r14, %rdi callq 0x21c20 nop
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_: push rbp; __int64 push r15; int push r14; void * push r12; int push rbx; __int64 sub rsp, 30h mov r14, rsi cmp [rdx], rsi jnz loc_8BB0B mov r15, rdx mov rbx, rdi mov [rdi], r14 xorps xmm0, xmm0 movups xmmword ptr [rdi+8], xmm0 mov rax, 8000000000000000h mov [rdi+18h], rax call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE7set_endEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::set_end(void) movzx eax, byte ptr [r14] lea ecx, [rax-3] cmp ecx, 6 jnb short loc_8BA78 cmp qword ptr [r15+18h], 0 jnz loc_8BB6E cmp eax, 8 jz short loc_8BA99 cmp eax, 3 jnz loc_8BACC lea r15, [r14+8] mov rdi, [r14+8] mov rax, [rdi] lea rcx, [rdi+10h] cmp rax, rcx jz short loc_8BA71 mov rsi, [rcx] inc rsi; unsigned __int64 mov rdi, rax; void * call __ZdlPvm; operator delete(void *,ulong) mov rdi, [r15] loc_8BA71: mov esi, 20h ; ' ' jmp short loc_8BAC0 loc_8BA78: cmp eax, 1 jz short loc_8BAED cmp eax, 2 jnz loc_8BBCE mov rdi, [r14+8] mov rsi, [r15+10h] call _ZNSt6vectorIN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapES_NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES_IhSaIhEEvEESaISD_EE8_M_eraseEN9__gnu_cxx17__normal_iteratorIPSD_SF_EE; std::vector<nlohmann::json_abi_v3_11_3::basic_json<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>>::_M_erase(__gnu_cxx::__normal_iterator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>*,std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>) mov [rbx+10h], rax jmp short loc_8BADD loc_8BA99: lea r15, [r14+8] mov rdi, [r14+8] mov rax, [rdi] test rax, rax jz short loc_8BABB mov rsi, [rdi+10h] sub rsi, rax; unsigned __int64 mov rdi, rax; void * call __ZdlPvm; operator delete(void *,ulong) mov rdi, [r15]; void * loc_8BABB: mov esi, 28h ; '('; unsigned __int64 loc_8BAC0: call __ZdlPvm; operator delete(void *,ulong) mov qword ptr [r15], 0 loc_8BACC: mov byte ptr [r14], 0 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) loc_8BADD: mov rax, rbx add rsp, 30h pop rbx pop r12 pop r14 pop r15 pop rbp retn loc_8BAED: mov r12, rbx add r12, 8 mov rdi, [r14+8] mov rsi, [r15+8] lea rdx, [rsi+30h] call _ZN8nlohmann16json_abi_v3_11_311ordered_mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEENS0_10basic_jsonIS1_St6vectorS7_blmdSaNS0_14adl_serializerES9_IhSaIhEEvEESt4lessIvESaISt4pairIKS7_SD_EEE5eraseEN9__gnu_cxx17__normal_iteratorIPSI_S9_ISI_SJ_EEESP_; nlohmann::json_abi_v3_11_3::ordered_map<std::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>,std::less<void>,std::allocator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>::erase(__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>*,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>,__gnu_cxx::__normal_iterator<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>*,std::vector<std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>>) mov [r12], rax jmp short loc_8BADD loc_8BB0B: mov edi, 20h ; ' '; thrown_size call ___cxa_allocate_exception mov rbx, rax lea r15, [rsp+58h+var_40] mov [r15-10h], r15 lea rsi, aIteratorDoesNo; "iterator does not fit current value" lea rdx, aIteratorDoesNo+23h; "" lea rdi, [rsp+58h+var_50] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) mov bpl, 1 lea rdx, [rsp+58h+var_50] mov rdi, rbx; this mov esi, 0CAh; int mov rcx, r14 call _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ xor ebp, ebp lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail16invalid_iteratorE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw jmp loc_8BC2C loc_8BB6E: mov edi, 20h ; ' '; thrown_size call ___cxa_allocate_exception mov rbx, rax lea r15, [rsp+58h+var_40] mov [r15-10h], r15 lea rsi, aIteratorOutOfR; "iterator out of range" lea rdx, aIteratorOutOfR+15h; "" lea rdi, [rsp+58h+var_50] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) mov bpl, 1 lea rdx, [rsp+58h+var_50] mov rdi, rbx; this mov esi, 0CDh; int mov rcx, r14 call _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ xor ebp, ebp lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail16invalid_iteratorE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw jmp short loc_8BC2C loc_8BBCE: 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+58h+var_30] mov [rdx], rax lea rsi, aCannotUseErase; "cannot use erase() with " lea rdi, [rsp+58h+var_50] call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJRA25_KcPS9_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,char const(&)[25],char const*>(char const(&)[25],char const* &&) mov bpl, 1 lea rdx, [rsp+58h+var_50] mov rdi, rbx; this mov esi, 133h; int mov rcx, r14 call _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ xor ebp, ebp lea rsi, _ZTIN8nlohmann16json_abi_v3_11_36detail10type_errorE; lptinfo lea rdx, _ZN8nlohmann16json_abi_v3_11_36detail9exceptionD2Ev; void (*)(void *) mov rdi, rbx; void * call ___cxa_throw loc_8BC2C: mov r14, rax lea rax, [rsp+58h+var_40] mov rdi, [rax-10h] cmp rdi, rax jnz short loc_8BC52 jmp short loc_8BC5F jmp short loc_8BC66 jmp short loc_8BC45 jmp short loc_8BC66 loc_8BC45: mov r14, rax mov rdi, [rsp+58h+var_50]; void * cmp rdi, r15 jz short loc_8BC5F loc_8BC52: mov rsi, [rsp+58h+var_40] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_8BC5F: test bpl, bpl jnz short loc_8BC69 jmp short loc_8BC71 loc_8BC66: mov r14, rax loc_8BC69: mov rdi, rbx; void * call ___cxa_free_exception loc_8BC71: mov rdi, r14 call __Unwind_Resume
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_: PUSH RBP PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x30 MOV R14,RSI CMP qword ptr [RDX],RSI JNZ 0x0018bb0b MOV R15,RDX MOV RBX,RDI MOV qword ptr [RDI],R14 XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI + 0x8],XMM0 MOV RAX,-0x8000000000000000 MOV qword ptr [RDI + 0x18],RAX CALL 0x0018ca22 MOVZX EAX,byte ptr [R14] LEA ECX,[RAX + -0x3] CMP ECX,0x6 JNC 0x0018ba78 CMP qword ptr [R15 + 0x18],0x0 JNZ 0x0018bb6e CMP EAX,0x8 JZ 0x0018ba99 CMP EAX,0x3 JNZ 0x0018bacc LEA R15,[R14 + 0x8] MOV RDI,qword ptr [R14 + 0x8] MOV RAX,qword ptr [RDI] LEA RCX,[RDI + 0x10] CMP RAX,RCX JZ 0x0018ba71 MOV RSI,qword ptr [RCX] INC RSI MOV RDI,RAX CALL 0x00121190 MOV RDI,qword ptr [R15] LAB_0018ba71: MOV ESI,0x20 JMP 0x0018bac0 LAB_0018ba78: CMP EAX,0x1 JZ 0x0018baed CMP EAX,0x2 JNZ 0x0018bbce MOV RDI,qword ptr [R14 + 0x8] MOV RSI,qword ptr [R15 + 0x10] CALL 0x0018d0e2 MOV qword ptr [RBX + 0x10],RAX JMP 0x0018badd LAB_0018ba99: LEA R15,[R14 + 0x8] MOV RDI,qword ptr [R14 + 0x8] MOV RAX,qword ptr [RDI] TEST RAX,RAX JZ 0x0018babb MOV RSI,qword ptr [RDI + 0x10] SUB RSI,RAX MOV RDI,RAX CALL 0x00121190 MOV RDI,qword ptr [R15] LAB_0018babb: MOV ESI,0x28 LAB_0018bac0: CALL 0x00121190 MOV qword ptr [R15],0x0 LAB_0018bacc: MOV byte ptr [R14],0x0 MOV RDI,R14 MOV ESI,0x1 CALL 0x001875ae LAB_0018badd: MOV RAX,RBX ADD RSP,0x30 POP RBX POP R12 POP R14 POP R15 POP RBP RET LAB_0018baed: MOV R12,RBX ADD R12,0x8 MOV RDI,qword ptr [R14 + 0x8] MOV RSI,qword ptr [R15 + 0x8] LEA RDX,[RSI + 0x30] CALL 0x0018cc7e MOV qword ptr [R12],RAX JMP 0x0018badd LAB_0018bb0b: MOV EDI,0x20 CALL 0x001216d0 MOV RBX,RAX LEA R15,[RSP + 0x18] MOV qword ptr [R15 + -0x10],R15 LAB_0018bb21: LEA RSI,[0x21cadf] LEA RDX,[0x21cb02] LEA RDI,[RSP + 0x8] CALL 0x00128f28 MOV BPL,0x1 LAB_0018bb3c: LEA RDX,[RSP + 0x8] MOV RDI,RBX MOV ESI,0xca MOV RCX,R14 CALL 0x0018c84a XOR EBP,EBP LEA RSI,[0x263000] LEA RDX,[0x178be8] MOV RDI,RBX CALL 0x00121b60 LAB_0018bb6e: MOV EDI,0x20 CALL 0x001216d0 MOV RBX,RAX LEA R15,[RSP + 0x18] MOV qword ptr [R15 + -0x10],R15 LAB_0018bb84: LEA RSI,[0x21cb03] LEA RDX,[0x21cb18] LEA RDI,[RSP + 0x8] CALL 0x00128f28 MOV BPL,0x1 LAB_0018bb9f: LEA RDX,[RSP + 0x8] MOV RDI,RBX MOV ESI,0xcd MOV RCX,R14 CALL 0x0018c84a XOR EBP,EBP LEA RSI,[0x263000] LEA RDX,[0x178be8] MOV RDI,RBX CALL 0x00121b60 LAB_0018bbce: MOV EDI,0x20 CALL 0x001216d0 MOV RBX,RAX MOV RDI,R14 CALL 0x0018cc60 LEA RDX,[RSP + 0x28] MOV qword ptr [RDX],RAX LAB_0018bbeb: LEA RSI,[0x21cb19] LEA RDI,[RSP + 0x8] CALL 0x0017c930 MOV BPL,0x1 LAB_0018bbff: LEA RDX,[RSP + 0x8] MOV RDI,RBX MOV ESI,0x133 MOV RCX,R14 CALL 0x0018ca88 XOR EBP,EBP LEA RSI,[0x263040] LEA RDX,[0x178be8] MOV RDI,RBX CALL 0x00121b60
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>> * _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE5eraseINS0_6detail9iter_implISD_EETnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISJ_NSG_IKSD_EEEE5valueEiE4typeELi0EEESJ_SJ_ (iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> *param_1, basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *param_2,long *param_3) { basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> bVar1; void *pvVar2; int8 uVar3; ulong uVar4; int8 *puVar5; int1 *local_50 [2]; int1 local_40 [16]; char *local_30; if ((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *)*param_3 != param_2) { uVar3 = __cxa_allocate_exception(0x20); local_50[0] = local_40; /* try { // try from 0018bb21 to 0018bb38 has its CatchHandler @ 0018bc66 */ std::__cxx11::string::_M_construct<char_const*> (local_50,"iterator does not fit current value",""); /* try { // try from 0018bb3c to 0018bb68 has its CatchHandler @ 0018bc45 */ _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ (uVar3,0xca,local_50,param_2); /* WARNING: Subroutine does not return */ __cxa_throw(uVar3,&nlohmann::json_abi_v3_11_3::detail::invalid_iterator::typeinfo, nlohmann::json_abi_v3_11_3::detail::exception::~exception); } *(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> **)param_1 = param_2; *(int8 *)(param_1 + 8) = 0; *(int8 *)(param_1 + 0x10) = 0; *(int8 *)(param_1 + 0x18) = 0x8000000000000000; nlohmann::json_abi_v3_11_3::detail:: iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ::set_end(param_1); bVar1 = *param_2; if (5 < (byte)bVar1 - 3) { if (bVar1 == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x1) { uVar3 = nlohmann::json_abi_v3_11_3:: ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> ::erase(*(ordered_map<std::__cxx11::string,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::less<void>,std::allocator<std::pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>>> **)(param_2 + 8),param_3[1],param_3[1] + 0x30); *(int8 *)(param_1 + 8) = uVar3; return 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> )0x2) { uVar3 = std:: vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>> ::_M_erase(*(vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>> **)(param_2 + 8),param_3[2]); *(int8 *)(param_1 + 0x10) = uVar3; return param_1; } uVar3 = __cxa_allocate_exception(0x20); local_30 = (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_2); /* try { // try from 0018bbeb to 0018bbfb has its CatchHandler @ 0018bc3f */ nlohmann::json_abi_v3_11_3::detail::concat<std::__cxx11::string,char_const(&)[25],char_const*> ((detail *)local_50,"cannot use erase() with ",&local_30); /* try { // try from 0018bbff to 0018bc2b has its CatchHandler @ 0018bc2c */ _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ (uVar3,0x133,local_50,param_2); /* WARNING: Subroutine does not return */ __cxa_throw(uVar3,&nlohmann::json_abi_v3_11_3::detail::type_error::typeinfo, nlohmann::json_abi_v3_11_3::detail::exception::~exception); } if (param_3[3] != 0) { uVar3 = __cxa_allocate_exception(0x20); local_50[0] = local_40; /* try { // try from 0018bb84 to 0018bb9b has its CatchHandler @ 0018bc43 */ std::__cxx11::string::_M_construct<char_const*>(local_50,"iterator out of range",""); /* try { // try from 0018bb9f to 0018bbcb has its CatchHandler @ 0018bc41 */ _ZN8nlohmann16json_abi_v3_11_36detail16invalid_iterator6createIPNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEETnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKSC_SJ_ (uVar3,0xcd,local_50,param_2); /* WARNING: Subroutine does not return */ __cxa_throw(uVar3,&nlohmann::json_abi_v3_11_3::detail::invalid_iterator::typeinfo, nlohmann::json_abi_v3_11_3::detail::exception::~exception); } 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> )0x8) { puVar5 = *(int8 **)(param_2 + 8); pvVar2 = (void *)*puVar5; if (pvVar2 != (void *)0x0) { operator_delete(pvVar2,puVar5[2] - (long)pvVar2); puVar5 = *(int8 **)(param_2 + 8); } uVar4 = 0x28; } 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> )0x3) goto LAB_0018bacc; puVar5 = *(int8 **)(param_2 + 8); if ((long *)*puVar5 != puVar5 + 2) { operator_delete((long *)*puVar5,puVar5[2] + 1); puVar5 = *(int8 **)(param_2 + 8); } uVar4 = 0x20; } operator_delete(puVar5,uVar4); *(int8 *)(param_2 + 8) = 0; LAB_0018bacc: *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> )0x0; 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(param_2,0)); return param_1; }
3,510
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::push_back(std::initializer_list<nlohmann::json_abi_v3_11_3::detail::json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>)
monkey531[P]llama/common/json.hpp
void push_back(initializer_list_t init) { if (is_object() && init.size() == 2 && (*init.begin())->is_string()) { basic_json&& key = init.begin()->moved_or_copied(); push_back(typename object_t::value_type( std::move(key.get_ref<string_t&>()), (init.begin() + 1)->moved_or_copied())); } else { push_back(basic_json(init)); } }
O2
cpp
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::push_back(std::initializer_list<nlohmann::json_abi_v3_11_3::detail::json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>>): pushq %r15 pushq %r14 pushq %rbx subq $0x50, %rsp movq %rsi, %r14 movq %rdi, %rbx cmpb $0x1, (%rdi) sete %al cmpq $0x2, %rdx sete %cl andb %al, %cl cmpb $0x1, %cl jne 0x5dae0 movq 0x10(%r14), %rax testq %rax, %rax cmoveq %r14, %rax cmpb $0x3, (%rax) jne 0x5dae0 leaq 0x10(%rsp), %r15 movq %r15, %rdi movq %r14, %rsi callq 0x7985e movq %r15, %rdi callq 0x8a4b2 movq %rax, %r15 addq $0x18, %r14 movq %rsp, %rdi movq %r14, %rsi callq 0x7985e leaq 0x20(%rsp), %r14 movq %rsp, %rdx movq %r14, %rdi movq %r15, %rsi callq 0x8a224 movq %rbx, %rdi movq %r14, %rsi callq 0x8a158 leaq 0x20(%rsp), %rdi callq 0x440dc movq %rsp, %rdi callq 0x3ecc6 leaq 0x10(%rsp), %rdi jmp 0x5db07 leaq 0x20(%rsp), %r15 pushq $0x1 popq %rcx pushq $0x2 popq %r8 movq %r15, %rdi movq %r14, %rsi callq 0x5e02c movq %rbx, %rdi movq %r15, %rsi callq 0x8a24a leaq 0x20(%rsp), %rdi callq 0x3ecc6 addq $0x50, %rsp popq %rbx popq %r14 popq %r15 retq movq %rax, %rbx leaq 0x20(%rsp), %rdi callq 0x440dc movq %rsp, %rdi callq 0x3ecc6 jmp 0x5db32 jmp 0x5db2f movq %rax, %rbx leaq 0x10(%rsp), %rdi jmp 0x5db41 movq %rax, %rbx leaq 0x20(%rsp), %rdi callq 0x3ecc6 movq %rbx, %rdi callq 0x24030
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9push_backESt16initializer_listINS0_6detail8json_refISD_EEE: push r15 push r14 push rbx sub rsp, 50h mov r14, rsi mov rbx, rdi cmp byte ptr [rdi], 1 setz al cmp rdx, 2 setz cl and cl, al cmp cl, 1 jnz short loc_5DAE0 mov rax, [r14+10h] test rax, rax cmovz rax, r14 cmp byte ptr [rax], 3 jnz short loc_5DAE0 lea r15, [rsp+68h+var_58] mov rdi, r15 mov rsi, r14 call _ZNK8nlohmann16json_abi_v3_11_36detail8json_refINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE15moved_or_copiedEv; nlohmann::json_abi_v3_11_3::detail::json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::moved_or_copied(void) mov rdi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE12get_ref_implIRS9_SD_EET_RT0_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::get_ref_impl<std::string&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> &) mov r15, rax add r14, 18h mov rdi, rsp mov rsi, r14 call _ZNK8nlohmann16json_abi_v3_11_36detail8json_refINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE15moved_or_copiedEv; nlohmann::json_abi_v3_11_3::detail::json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::moved_or_copied(void) lea r14, [rsp+68h+var_48] mov rdx, rsp mov rdi, r14 mov rsi, r15 call _ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEEC2IS5_SF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ mov rdi, rbx mov rsi, r14 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9push_backERKSt4pairIKS9_SD_E; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::push_back(std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>> const&) lea rdi, [rsp+68h+var_48]; void * call _ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEED2Ev; std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::~pair() mov rdi, rsp call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::~basic_json() lea rdi, [rsp+68h+var_58] jmp short loc_5DB07 loc_5DAE0: lea r15, [rsp+68h+var_48] push 1 pop rcx push 2 pop r8 mov rdi, r15 mov rsi, r14 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2ESt16initializer_listINS0_6detail8json_refISD_EEEbNSF_7value_tE; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::basic_json(std::initializer_list<nlohmann::json_abi_v3_11_3::detail::json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>>,bool,nlohmann::json_abi_v3_11_3::detail::value_t) mov rdi, rbx mov rsi, r15 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE9push_backEOSD_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::push_back(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>&&) lea rdi, [rsp+68h+var_48] loc_5DB07: call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::~basic_json() add rsp, 50h pop rbx pop r14 pop r15 retn mov rbx, rax lea rdi, [rsp+arg_18]; void * call _ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEED2Ev; std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>::~pair() mov rdi, rsp call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::~basic_json() jmp short loc_5DB32 jmp short $+2 loc_5DB2F: mov rbx, rax loc_5DB32: lea rdi, [rsp+arg_8] jmp short loc_5DB41 mov rbx, rax lea rdi, [rsp+arg_18] loc_5DB41: call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvED2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::~basic_json() mov rdi, rbx call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::push_back( _BYTE *a1, long long a2, long long a3) { _BYTE *v3; // rax long long v4; // r15 _BYTE *v5; // rdi _BYTE v7[16]; // [rsp+0h] [rbp-68h] BYREF _BYTE v8[16]; // [rsp+10h] [rbp-58h] BYREF _BYTE v9[72]; // [rsp+20h] [rbp-48h] BYREF if ( *a1 != 1 || a3 != 2 ) goto LABEL_6; v3 = *(_BYTE **)(a2 + 16); if ( !v3 ) v3 = (_BYTE *)a2; if ( *v3 == 3 ) { nlohmann::json_abi_v3_11_3::detail::json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::moved_or_copied( v8, a2); v4 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::get_ref_impl<std::string&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>(v8); nlohmann::json_abi_v3_11_3::detail::json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::moved_or_copied( v7, a2 + 24); ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEEC2IS5_SF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_( v9, v4, v7); nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::push_back( a1, v9); std::pair<std::string const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>::~pair(v9); nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::~basic_json((long long)v7); v5 = v8; } else { LABEL_6: nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::basic_json( v9, a2, a3, 1LL, 2LL); nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::push_back( a1, v9); v5 = v9; } return nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::~basic_json((long long)v5); }
push_back: PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x50 MOV R14,RSI MOV RBX,RDI CMP byte ptr [RDI],0x1 SETZ AL CMP RDX,0x2 SETZ CL AND CL,AL CMP CL,0x1 JNZ 0x0015dae0 MOV RAX,qword ptr [R14 + 0x10] TEST RAX,RAX CMOVZ RAX,R14 CMP byte ptr [RAX],0x3 JNZ 0x0015dae0 LEA R15,[RSP + 0x10] MOV RDI,R15 MOV RSI,R14 CALL 0x0017985e LAB_0015da8f: MOV RDI,R15 CALL 0x0018a4b2 MOV R15,RAX ADD R14,0x18 LAB_0015da9e: MOV RDI,RSP MOV RSI,R14 CALL 0x0017985e LEA R14,[RSP + 0x20] MOV RDX,RSP MOV RDI,R14 MOV RSI,R15 CALL 0x0018a224 LAB_0015dabc: MOV RDI,RBX MOV RSI,R14 CALL 0x0018a158 LAB_0015dac7: LEA RDI,[RSP + 0x20] CALL 0x001440dc MOV RDI,RSP CALL 0x0013ecc6 LEA RDI,[RSP + 0x10] JMP 0x0015db07 LAB_0015dae0: LEA R15,[RSP + 0x20] PUSH 0x1 POP RCX PUSH 0x2 POP R8 MOV RDI,R15 MOV RSI,R14 CALL 0x0015e02c LAB_0015daf7: MOV RDI,RBX MOV RSI,R15 CALL 0x0018a24a LAB_0015db02: LEA RDI,[RSP + 0x20] LAB_0015db07: CALL 0x0013ecc6 ADD RSP,0x50 POP RBX POP R14 POP R15 RET
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>::push_back(std::initializer_list<nlohmann::json_abi_v3_11_3::detail::json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> > >) */ void nlohmann::json_abi_v3_11_3:: basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::push_back(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *param_1,char *param_2,long param_3) { char *pcVar1; string *psVar2; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *this; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> abStack_68 [16]; basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> local_58 [16]; pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> local_48 [48]; if (param_3 == 2 && *param_1 == (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> )0x1) { pcVar1 = *(char **)(param_2 + 0x10); if (*(char **)(param_2 + 0x10) == (char *)0x0) { pcVar1 = param_2; } if (*pcVar1 == '\x03') { detail:: json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ::moved_or_copied(); /* try { // try from 0015da8f to 0015da96 has its CatchHandler @ 0015db2f */ psVar2 = get_ref_impl<std::__cxx11::string&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> (local_58); /* try { // try from 0015da9e to 0015daa8 has its CatchHandler @ 0015db2d */ detail:: json_ref<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ::moved_or_copied(); _ZNSt4pairIKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEN8nlohmann16json_abi_v3_11_310basic_jsonINS8_11ordered_mapESt6vectorS5_blmdSaNS8_14adl_serializerESB_IhSaIhEEvEEEC2IS5_SF_TnNSt9enable_ifIXaaclsr5_PCCPE22_MoveConstructiblePairIT_T0_EEclsr5_PCCPE30_ImplicitlyMoveConvertiblePairISJ_SK_EEEbE4typeELb1EEEOSJ_OSK_ (local_48,psVar2,abStack_68); /* try { // try from 0015dabc to 0015dac6 has its CatchHandler @ 0015db16 */ push_back(param_1,local_48); std:: pair<std::__cxx11::string_const,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> ::~pair(local_48); ~basic_json(abStack_68); this = local_58; goto LAB_0015db07; } } basic_json(local_48,param_2,param_3,1,2); /* try { // try from 0015daf7 to 0015db01 has its CatchHandler @ 0015db39 */ push_back(param_1,local_48); this = (basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *)local_48; LAB_0015db07: ~basic_json(this); return; }
3,511
matrix_d_identity
tsotchke[P]eshkol/src/core/utils/vector.c
MatrixD* matrix_d_identity(Arena* arena, size_t dim) { assert(arena != NULL); assert(dim > 0 && dim <= VECTOR_MAX_DIM); MatrixD* mat = matrix_d_create(arena, dim, dim); if (!mat) { return NULL; } // Set the diagonal elements to 1 for (size_t i = 0; i < dim; i++) { mat->data[i][i] = 1.0; } return mat; }
O0
c
matrix_d_identity: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) cmpq $0x0, -0x10(%rbp) je 0x7179 jmp 0x7198 leaq 0x52fa(%rip), %rdi # 0xc47a leaq 0x6239(%rip), %rsi # 0xd3c0 movl $0x4ac, %edx # imm = 0x4AC leaq 0x69c6(%rip), %rcx # 0xdb59 callq 0x10b0 cmpq $0x0, -0x18(%rbp) jbe 0x71a8 cmpq $0x4, -0x18(%rbp) ja 0x71a8 jmp 0x71c7 leaq 0x628d(%rip), %rdi # 0xd43c leaq 0x620a(%rip), %rsi # 0xd3c0 movl $0x4ad, %edx # imm = 0x4AD leaq 0x6997(%rip), %rcx # 0xdb59 callq 0x10b0 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x18(%rbp), %rdx callq 0x5820 movq %rax, -0x20(%rbp) cmpq $0x0, -0x20(%rbp) jne 0x71ed movq $0x0, -0x8(%rbp) jmp 0x7235 movq $0x0, -0x28(%rbp) movq -0x28(%rbp), %rax cmpq -0x18(%rbp), %rax jae 0x722d movq -0x20(%rbp), %rax movq -0x28(%rbp), %rcx shlq $0x5, %rcx addq %rcx, %rax movq -0x28(%rbp), %rcx movsd 0x619e(%rip), %xmm0 # 0xd3b8 movsd %xmm0, (%rax,%rcx,8) movq -0x28(%rbp), %rax addq $0x1, %rax movq %rax, -0x28(%rbp) jmp 0x71f5 movq -0x20(%rbp), %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax addq $0x30, %rsp popq %rbp retq nop
matrix_d_identity: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi cmp [rbp+var_10], 0 jz short loc_7179 jmp short loc_7198 loc_7179: lea rdi, aArenaNull; "arena != NULL" lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... mov edx, 4ACh lea rcx, aMatrixdMatrixD_0; "MatrixD *matrix_d_identity(Arena *, siz"... call ___assert_fail loc_7198: cmp [rbp+var_18], 0 jbe short loc_71A8 cmp [rbp+var_18], 4 ja short loc_71A8 jmp short loc_71C7 loc_71A8: lea rdi, aDim0DimVectorM; "dim > 0 && dim <= VECTOR_MAX_DIM" lea rsi, aWorkspaceLlm4b_1; "/workspace/llm4binary/github/2025_star3"... mov edx, 4ADh lea rcx, aMatrixdMatrixD_0; "MatrixD *matrix_d_identity(Arena *, siz"... call ___assert_fail loc_71C7: mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov rdx, [rbp+var_18] call matrix_d_create mov [rbp+var_20], rax cmp [rbp+var_20], 0 jnz short loc_71ED mov [rbp+var_8], 0 jmp short loc_7235 loc_71ED: mov [rbp+var_28], 0 loc_71F5: mov rax, [rbp+var_28] cmp rax, [rbp+var_18] jnb short loc_722D mov rax, [rbp+var_20] mov rcx, [rbp+var_28] shl rcx, 5 add rax, rcx mov rcx, [rbp+var_28] movsd xmm0, cs:qword_D3B8 movsd qword ptr [rax+rcx*8], xmm0 mov rax, [rbp+var_28] add rax, 1 mov [rbp+var_28], rax jmp short loc_71F5 loc_722D: mov rax, [rbp+var_20] mov [rbp+var_8], rax loc_7235: mov rax, [rbp+var_8] add rsp, 30h pop rbp retn
long long matrix_d_identity(_QWORD *a1, unsigned long long a2) { unsigned long long i; // [rsp+8h] [rbp-28h] long long v4; // [rsp+10h] [rbp-20h] if ( !a1 ) __assert_fail( "arena != NULL", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c", 1196LL, "MatrixD *matrix_d_identity(Arena *, size_t)"); if ( !a2 || a2 > 4 ) __assert_fail( "dim > 0 && dim <= VECTOR_MAX_DIM", "/workspace/llm4binary/github/2025_star3/tsotchke[P]eshkol/src/core/utils/vector.c", 1197LL, "MatrixD *matrix_d_identity(Arena *, size_t)"); v4 = matrix_d_create(a1, a2, a2); if ( !v4 ) return 0LL; for ( i = 0LL; i < a2; ++i ) *(_QWORD *)(32 * i + v4 + 8 * i) = 0x3FF0000000000000LL; return v4; }
matrix_d_identity: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI CMP qword ptr [RBP + -0x10],0x0 JZ 0x00107179 JMP 0x00107198 LAB_00107179: LEA RDI,[0x10c468] LEA RSI,[0x10d398] MOV EDX,0x4ac LEA RCX,[0x10db1f] CALL 0x001010b0 LAB_00107198: CMP qword ptr [RBP + -0x18],0x0 JBE 0x001071a8 CMP qword ptr [RBP + -0x18],0x4 JA 0x001071a8 JMP 0x001071c7 LAB_001071a8: LEA RDI,[0x10d402] LEA RSI,[0x10d398] MOV EDX,0x4ad LEA RCX,[0x10db1f] CALL 0x001010b0 LAB_001071c7: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] MOV RDX,qword ptr [RBP + -0x18] CALL 0x00105820 MOV qword ptr [RBP + -0x20],RAX CMP qword ptr [RBP + -0x20],0x0 JNZ 0x001071ed MOV qword ptr [RBP + -0x8],0x0 JMP 0x00107235 LAB_001071ed: MOV qword ptr [RBP + -0x28],0x0 LAB_001071f5: MOV RAX,qword ptr [RBP + -0x28] CMP RAX,qword ptr [RBP + -0x18] JNC 0x0010722d MOV RAX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x28] SHL RCX,0x5 ADD RAX,RCX MOV RCX,qword ptr [RBP + -0x28] MOVSD XMM0,qword ptr [0x0010d390] MOVSD qword ptr [RAX + RCX*0x8],XMM0 MOV RAX,qword ptr [RBP + -0x28] ADD RAX,0x1 MOV qword ptr [RBP + -0x28],RAX JMP 0x001071f5 LAB_0010722d: MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x8],RAX LAB_00107235: MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x30 POP RBP RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ long matrix_d_identity(long param_1,ulong param_2) { ulong local_30; long local_10; if (param_1 == 0) { /* WARNING: Subroutine does not return */ __assert_fail("arena != NULL","/workspace/llm4binary/github2025/eshkol/src/core/utils/vector.c", 0x4ac,"MatrixD *matrix_d_identity(Arena *, size_t)"); } if ((param_2 != 0) && (param_2 < 5)) { local_10 = matrix_d_create(param_1,param_2,param_2); if (local_10 == 0) { local_10 = 0; } else { for (local_30 = 0; local_30 < param_2; local_30 = local_30 + 1) { *(int8 *)(local_10 + local_30 * 0x28) = _DAT_0010d390; } } return local_10; } /* WARNING: Subroutine does not return */ __assert_fail("dim > 0 && dim <= VECTOR_MAX_DIM", "/workspace/llm4binary/github2025/eshkol/src/core/utils/vector.c",0x4ad, "MatrixD *matrix_d_identity(Arena *, size_t)"); }
3,512
copy_uca_collation
eloqsql/mysys/charset.c
static void copy_uca_collation(struct charset_info_st *to, CHARSET_INFO *from, CHARSET_INFO *loaded) { to->cset= from->cset; to->coll= from->coll; /* Single-level UCA collation have strnxfrm_multiple=8. In case of a multi-level UCA collation we use strnxfrm_multiply=4. That means MY_COLLATION_HANDLER::strnfrmlen() will request the caller to allocate a buffer smaller size for each level, for performance purpose, and to fit longer VARCHARs to @@max_sort_length. This makes filesort produce non-precise order for some rare Unicode characters that produce more than 4 weights (long expansions). UCA requires 2 bytes per weight multiplied by the number of levels. In case of a 2-level collation, each character requires 4*2=8 bytes. Therefore, the longest VARCHAR that fits into the default @@max_sort_length is 1024/8=VARCHAR(128). With strnxfrm_multiply==8, only VARCHAR(64) would fit. Note, the built-in collation utf8_thai_520_w2 also uses strnxfrm_multiply=4, for the same purpose. TODO: we could add a new LDML syntax to choose strxfrm_multiply value. */ to->strxfrm_multiply= loaded->levels_for_order > 1 ? 4 : from->strxfrm_multiply; to->min_sort_char= from->min_sort_char; to->max_sort_char= from->max_sort_char; to->mbminlen= from->mbminlen; to->mbmaxlen= from->mbmaxlen; to->caseup_multiply= from->caseup_multiply; to->casedn_multiply= from->casedn_multiply; to->state|= MY_CS_AVAILABLE | MY_CS_LOADED | MY_CS_STRNXFRM | MY_CS_UNICODE; }
O3
c
copy_uca_collation: pushq %rbp movq %rsp, %rbp movq 0xb8(%rsi), %rax movq %rax, 0xb8(%rdi) movq 0xc0(%rsi), %rax movq %rax, 0xc0(%rdi) movl $0x4, %eax cmpb $0x1, 0xb2(%rdx) ja 0xae157 movl 0x90(%rsi), %eax movl %eax, 0x90(%rdi) movq 0xa0(%rsi), %rax movq %rax, 0xa0(%rdi) movq 0xa8(%rsi), %rax movq %rax, 0xa8(%rdi) movl 0x98(%rsi), %eax movl %eax, 0x98(%rdi) movl 0x9c(%rsi), %eax movl %eax, 0x9c(%rdi) movb 0x94(%rsi), %al movb %al, 0x94(%rdi) movb 0x95(%rsi), %al movb %al, 0x95(%rdi) orl $0x2c8, 0xc(%rdi) # imm = 0x2C8 popq %rbp retq
copy_uca_collation: push rbp mov rbp, rsp mov rax, [rsi+0B8h] mov [rdi+0B8h], rax mov rax, [rsi+0C0h] mov [rdi+0C0h], rax mov eax, 4 cmp byte ptr [rdx+0B2h], 1 ja short loc_AE157 mov eax, [rsi+90h] loc_AE157: mov [rdi+90h], eax mov rax, [rsi+0A0h] mov [rdi+0A0h], rax mov rax, [rsi+0A8h] mov [rdi+0A8h], rax mov eax, [rsi+98h] mov [rdi+98h], eax mov eax, [rsi+9Ch] mov [rdi+9Ch], eax mov al, [rsi+94h] mov [rdi+94h], al mov al, [rsi+95h] mov [rdi+95h], al or dword ptr [rdi+0Ch], 2C8h pop rbp retn
char copy_uca_collation(long long a1, long long a2, long long a3) { int v3; // eax char result; // al *(_QWORD *)(a1 + 184) = *(_QWORD *)(a2 + 184); *(_QWORD *)(a1 + 192) = *(_QWORD *)(a2 + 192); v3 = 4; if ( *(_BYTE *)(a3 + 178) <= 1u ) v3 = *(_DWORD *)(a2 + 144); *(_DWORD *)(a1 + 144) = v3; *(_QWORD *)(a1 + 160) = *(_QWORD *)(a2 + 160); *(_QWORD *)(a1 + 168) = *(_QWORD *)(a2 + 168); *(_DWORD *)(a1 + 152) = *(_DWORD *)(a2 + 152); *(_DWORD *)(a1 + 156) = *(_DWORD *)(a2 + 156); *(_BYTE *)(a1 + 148) = *(_BYTE *)(a2 + 148); result = *(_BYTE *)(a2 + 149); *(_BYTE *)(a1 + 149) = result; *(_DWORD *)(a1 + 12) |= 0x2C8u; return result; }
copy_uca_collation: PUSH RBP MOV RBP,RSP MOV RAX,qword ptr [RSI + 0xb8] MOV qword ptr [RDI + 0xb8],RAX MOV RAX,qword ptr [RSI + 0xc0] MOV qword ptr [RDI + 0xc0],RAX MOV EAX,0x4 CMP byte ptr [RDX + 0xb2],0x1 JA 0x001ae157 MOV EAX,dword ptr [RSI + 0x90] LAB_001ae157: MOV dword ptr [RDI + 0x90],EAX MOV RAX,qword ptr [RSI + 0xa0] MOV qword ptr [RDI + 0xa0],RAX MOV RAX,qword ptr [RSI + 0xa8] MOV qword ptr [RDI + 0xa8],RAX MOV EAX,dword ptr [RSI + 0x98] MOV dword ptr [RDI + 0x98],EAX MOV EAX,dword ptr [RSI + 0x9c] MOV dword ptr [RDI + 0x9c],EAX MOV AL,byte ptr [RSI + 0x94] MOV byte ptr [RDI + 0x94],AL MOV AL,byte ptr [RSI + 0x95] MOV byte ptr [RDI + 0x95],AL OR dword ptr [RDI + 0xc],0x2c8 POP RBP RET
void copy_uca_collation(long param_1,long param_2,long param_3) { int4 uVar1; *(int8 *)(param_1 + 0xb8) = *(int8 *)(param_2 + 0xb8); *(int8 *)(param_1 + 0xc0) = *(int8 *)(param_2 + 0xc0); uVar1 = 4; if (*(byte *)(param_3 + 0xb2) < 2) { uVar1 = *(int4 *)(param_2 + 0x90); } *(int4 *)(param_1 + 0x90) = uVar1; *(int8 *)(param_1 + 0xa0) = *(int8 *)(param_2 + 0xa0); *(int8 *)(param_1 + 0xa8) = *(int8 *)(param_2 + 0xa8); *(int4 *)(param_1 + 0x98) = *(int4 *)(param_2 + 0x98); *(int4 *)(param_1 + 0x9c) = *(int4 *)(param_2 + 0x9c); *(int1 *)(param_1 + 0x94) = *(int1 *)(param_2 + 0x94); *(int1 *)(param_1 + 0x95) = *(int1 *)(param_2 + 0x95); *(uint *)(param_1 + 0xc) = *(uint *)(param_1 + 0xc) | 0x2c8; return; }
3,513
maria_collect_stats_nonulls_first
eloqsql/storage/maria/ma_check.c
static void maria_collect_stats_nonulls_first(HA_KEYSEG *keyseg, ulonglong *notnull, const uchar *key) { size_t first_null, kp; first_null= ha_find_null(keyseg, key) - keyseg; /* All prefix tuples that don't include keypart_{first_null} are not-null tuples (and all others aren't), increment counters for them. */ for (kp= 0; kp < first_null; kp++) notnull[kp]++; }
O3
c
maria_collect_stats_nonulls_first: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx movq %rsi, %rbx movq %rdi, %r14 movq %rdx, %rsi callq 0xc2fc5 subq %r14, %rax je 0x6f146 sarq $0x5, %rax cmpq $0x1, %rax adcq $0x0, %rax xorl %ecx, %ecx incq (%rbx,%rcx,8) incq %rcx cmpq %rcx, %rax jne 0x6f13a popq %rbx popq %r14 popq %rbp retq
maria_collect_stats_nonulls_first: push rbp mov rbp, rsp push r14 push rbx mov rbx, rsi mov r14, rdi mov rsi, rdx call ha_find_null sub rax, r14 jz short loc_6F146 sar rax, 5 cmp rax, 1 adc rax, 0 xor ecx, ecx loc_6F13A: inc qword ptr [rbx+rcx*8] inc rcx cmp rax, rcx jnz short loc_6F13A loc_6F146: pop rbx pop r14 pop rbp retn
long long maria_collect_stats_nonulls_first(long long a1, long long a2, long long a3) { long long result; // rax long long v4; // rcx result = ha_find_null(a1, a3) - a1; if ( result ) { result = (result >> 5 == 0) + (result >> 5); v4 = 0LL; do ++*(_QWORD *)(a2 + 8 * v4++); while ( result != v4 ); } return result; }
maria_collect_stats_nonulls_first: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX MOV RBX,RSI MOV R14,RDI MOV RSI,RDX CALL 0x001c2fc5 SUB RAX,R14 JZ 0x0016f146 SAR RAX,0x5 CMP RAX,0x1 ADC RAX,0x0 XOR ECX,ECX LAB_0016f13a: INC qword ptr [RBX + RCX*0x8] INC RCX CMP RAX,RCX JNZ 0x0016f13a LAB_0016f146: POP RBX POP R14 POP RBP RET
void maria_collect_stats_nonulls_first(long param_1,long param_2,int8 param_3) { long *plVar1; long lVar2; long lVar3; lVar2 = ha_find_null(param_1,param_3); if (lVar2 - param_1 != 0) { lVar2 = lVar2 - param_1 >> 5; lVar3 = 0; do { plVar1 = (long *)(param_2 + lVar3 * 8); *plVar1 = *plVar1 + 1; lVar3 = lVar3 + 1; } while (lVar2 + (ulong)(lVar2 == 0) != lVar3); } return; }
3,514
translog_wait_for_writers
eloqsql/storage/maria/ma_loghandler.c
static void translog_wait_for_writers(struct st_translog_buffer *buffer) { DBUG_ENTER("translog_wait_for_writers"); DBUG_PRINT("enter", ("Buffer #%u %p copies in progress: %u " "is closing %u File: %d size: %lu", (uint) buffer->buffer_no, buffer, (uint) buffer->copy_to_buffer_in_progress, (uint) buffer->is_closing_buffer, (buffer->file ? buffer->file->handler.file : -1), (ulong) buffer->size)); translog_buffer_lock_assert_owner(buffer); while (buffer->copy_to_buffer_in_progress) { DBUG_PRINT("info", ("wait for writers... buffer: #%u %p", (uint) buffer->buffer_no, buffer)); DBUG_ASSERT(buffer->file != NULL); mysql_cond_wait(&buffer->waiting_filling_buffer, &buffer->mutex); DBUG_PRINT("info", ("wait for writers done buffer: #%u %p", (uint) buffer->buffer_no, buffer)); } DBUG_VOID_RETURN; }
O0
c
translog_wait_for_writers: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) jmp 0x95b2e jmp 0x95b30 movq -0x8(%rbp), %rax cmpl $0x0, 0x100078(%rax) je 0x95b70 jmp 0x95b3f jmp 0x95b41 jmp 0x95b43 jmp 0x95b45 movq -0x8(%rbp), %rdi addq $0x100040, %rdi # imm = 0x100040 movq -0x8(%rbp), %rsi addq $0x100090, %rsi # imm = 0x100090 leaq 0xc40e6(%rip), %rdx # 0x159c48 movl $0x806, %ecx # imm = 0x806 callq 0x8cca0 jmp 0x95b6e jmp 0x95b30 jmp 0x95b72 jmp 0x95b74 addq $0x10, %rsp popq %rbp retq nopw (%rax,%rax)
translog_wait_for_writers: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi jmp short $+2 loc_95B2E: jmp short $+2 loc_95B30: mov rax, [rbp+var_8] cmp dword ptr [rax+100078h], 0 jz short loc_95B70 jmp short $+2 loc_95B3F: jmp short $+2 loc_95B41: jmp short $+2 loc_95B43: jmp short $+2 loc_95B45: mov rdi, [rbp+var_8] add rdi, 100040h mov rsi, [rbp+var_8] add rsi, 100090h lea rdx, aWorkspaceLlm4b_24; "/workspace/llm4binary/github2025/eloqsq"... mov ecx, 806h call inline_mysql_cond_wait_1 jmp short $+2 loc_95B6E: jmp short loc_95B30 loc_95B70: jmp short $+2 loc_95B72: jmp short $+2 loc_95B74: add rsp, 10h pop rbp retn
long long translog_wait_for_writers(long long a1) { long long result; // rax while ( 1 ) { result = a1; if ( !*(_DWORD *)(a1 + 1048696) ) break; inline_mysql_cond_wait_1( a1 + 1048640, a1 + 1048720, (long long)"/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_loghandler.c", 0x806u); } return result; }
translog_wait_for_writers: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI JMP 0x00195b2e LAB_00195b2e: JMP 0x00195b30 LAB_00195b30: MOV RAX,qword ptr [RBP + -0x8] CMP dword ptr [RAX + 0x100078],0x0 JZ 0x00195b70 JMP 0x00195b3f LAB_00195b3f: JMP 0x00195b41 LAB_00195b41: JMP 0x00195b43 LAB_00195b43: JMP 0x00195b45 LAB_00195b45: MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x100040 MOV RSI,qword ptr [RBP + -0x8] ADD RSI,0x100090 LEA RDX,[0x259c48] MOV ECX,0x806 CALL 0x0018cca0 JMP 0x00195b6e LAB_00195b6e: JMP 0x00195b30 LAB_00195b70: JMP 0x00195b72 LAB_00195b72: JMP 0x00195b74 LAB_00195b74: ADD RSP,0x10 POP RBP RET
void translog_wait_for_writers(long param_1) { while (*(int *)((long)&Elf64_Phdr_ARRAY_00100040[1].p_type + param_1) != 0) { inline_mysql_cond_wait ((long)&Elf64_Phdr_ARRAY_00100040[0].p_type + param_1,param_1 + 0x100090, "/workspace/llm4binary/github2025/eloqsql/storage/maria/ma_loghandler.c",0x806); } return; }
3,515
ma_scan_end_block_record
eloqsql/storage/maria/ma_blockrec.c
void _ma_scan_end_block_record(MARIA_HA *info) { DBUG_ENTER("_ma_scan_end_block_record"); my_free(info->scan.bitmap_buff); info->scan.bitmap_buff= 0; if (info->scan_save) { my_free(info->scan_save); info->scan_save= 0; } DBUG_VOID_RETURN; }
O0
c
ma_scan_end_block_record: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq -0x8(%rbp), %rax movq 0x220(%rax), %rdi callq 0xf5590 movq -0x8(%rbp), %rax movq $0x0, 0x220(%rax) movq -0x8(%rbp), %rax cmpq $0x0, 0x280(%rax) je 0x5aba8 movq -0x8(%rbp), %rax movq 0x280(%rax), %rdi callq 0xf5590 movq -0x8(%rbp), %rax movq $0x0, 0x280(%rax) jmp 0x5abaa jmp 0x5abac addq $0x10, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
_ma_scan_end_block_record: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi mov rax, [rbp+var_8] mov rdi, [rax+220h] call my_free mov rax, [rbp+var_8] mov qword ptr [rax+220h], 0 mov rax, [rbp+var_8] cmp qword ptr [rax+280h], 0 jz short loc_5ABA8 mov rax, [rbp+var_8] mov rdi, [rax+280h] call my_free mov rax, [rbp+var_8] mov qword ptr [rax+280h], 0 loc_5ABA8: jmp short $+2 loc_5ABAA: jmp short $+2 loc_5ABAC: add rsp, 10h pop rbp retn
long long ma_scan_end_block_record(long long a1) { long long result; // rax my_free(*(_QWORD *)(a1 + 544)); *(_QWORD *)(a1 + 544) = 0LL; result = a1; if ( *(_QWORD *)(a1 + 640) ) { my_free(*(_QWORD *)(a1 + 640)); result = a1; *(_QWORD *)(a1 + 640) = 0LL; } return result; }
_ma_scan_end_block_record: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX + 0x220] CALL 0x001f5590 MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0x220],0x0 MOV RAX,qword ptr [RBP + -0x8] CMP qword ptr [RAX + 0x280],0x0 JZ 0x0015aba8 MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX + 0x280] CALL 0x001f5590 MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0x280],0x0 LAB_0015aba8: JMP 0x0015abaa LAB_0015abaa: JMP 0x0015abac LAB_0015abac: ADD RSP,0x10 POP RBP RET
void _ma_scan_end_block_record(long param_1) { my_free(*(int8 *)(param_1 + 0x220)); *(int8 *)(param_1 + 0x220) = 0; if (*(long *)(param_1 + 0x280) != 0) { my_free(*(int8 *)(param_1 + 0x280)); *(int8 *)(param_1 + 0x280) = 0; } return; }
3,516
unicode_prop
bluesky950520[P]quickjs/libunicode.c
int unicode_prop(CharRange *cr, const char *prop_name) { int prop_idx, ret; prop_idx = unicode_find_name(unicode_prop_name_table, prop_name); if (prop_idx < 0) return -2; prop_idx += UNICODE_PROP_ASCII_Hex_Digit; ret = 0; switch(prop_idx) { case UNICODE_PROP_ASCII: if (cr_add_interval(cr, 0x00, 0x7f + 1)) return -1; break; case UNICODE_PROP_Any: if (cr_add_interval(cr, 0x00000, 0x10ffff + 1)) return -1; break; case UNICODE_PROP_Assigned: ret = unicode_prop_ops(cr, POP_GC, M(Cn), POP_INVERT, POP_END); break; case UNICODE_PROP_Math: ret = unicode_prop_ops(cr, POP_GC, M(Sm), POP_PROP, UNICODE_PROP_Other_Math, POP_UNION, POP_END); break; case UNICODE_PROP_Lowercase: ret = unicode_prop_ops(cr, POP_GC, M(Ll), POP_PROP, UNICODE_PROP_Other_Lowercase, POP_UNION, POP_END); break; case UNICODE_PROP_Uppercase: ret = unicode_prop_ops(cr, POP_GC, M(Lu), POP_PROP, UNICODE_PROP_Other_Uppercase, POP_UNION, POP_END); break; case UNICODE_PROP_Cased: ret = unicode_prop_ops(cr, POP_GC, M(Lu) | M(Ll) | M(Lt), POP_PROP, UNICODE_PROP_Other_Uppercase, POP_UNION, POP_PROP, UNICODE_PROP_Other_Lowercase, POP_UNION, POP_END); break; case UNICODE_PROP_Alphabetic: ret = unicode_prop_ops(cr, POP_GC, M(Lu) | M(Ll) | M(Lt) | M(Lm) | M(Lo) | M(Nl), POP_PROP, UNICODE_PROP_Other_Uppercase, POP_UNION, POP_PROP, UNICODE_PROP_Other_Lowercase, POP_UNION, POP_PROP, UNICODE_PROP_Other_Alphabetic, POP_UNION, POP_END); break; case UNICODE_PROP_Grapheme_Base: ret = unicode_prop_ops(cr, POP_GC, M(Cc) | M(Cf) | M(Cs) | M(Co) | M(Cn) | M(Zl) | M(Zp) | M(Me) | M(Mn), POP_PROP, UNICODE_PROP_Other_Grapheme_Extend, POP_UNION, POP_INVERT, POP_END); break; case UNICODE_PROP_Grapheme_Extend: ret = unicode_prop_ops(cr, POP_GC, M(Me) | M(Mn), POP_PROP, UNICODE_PROP_Other_Grapheme_Extend, POP_UNION, POP_END); break; case UNICODE_PROP_XID_Start: ret = unicode_prop_ops(cr, POP_GC, M(Lu) | M(Ll) | M(Lt) | M(Lm) | M(Lo) | M(Nl), POP_PROP, UNICODE_PROP_Other_ID_Start, POP_UNION, POP_PROP, UNICODE_PROP_Pattern_Syntax, POP_PROP, UNICODE_PROP_Pattern_White_Space, POP_UNION, POP_PROP, UNICODE_PROP_XID_Start1, POP_UNION, POP_INVERT, POP_INTER, POP_END); break; case UNICODE_PROP_XID_Continue: ret = unicode_prop_ops(cr, POP_GC, M(Lu) | M(Ll) | M(Lt) | M(Lm) | M(Lo) | M(Nl) | M(Mn) | M(Mc) | M(Nd) | M(Pc), POP_PROP, UNICODE_PROP_Other_ID_Start, POP_UNION, POP_PROP, UNICODE_PROP_Other_ID_Continue, POP_UNION, POP_PROP, UNICODE_PROP_Pattern_Syntax, POP_PROP, UNICODE_PROP_Pattern_White_Space, POP_UNION, POP_PROP, UNICODE_PROP_XID_Continue1, POP_UNION, POP_INVERT, POP_INTER, POP_END); break; case UNICODE_PROP_Changes_When_Uppercased: ret = unicode_case1(cr, CASE_U); break; case UNICODE_PROP_Changes_When_Lowercased: ret = unicode_case1(cr, CASE_L); break; case UNICODE_PROP_Changes_When_Casemapped: ret = unicode_case1(cr, CASE_U | CASE_L | CASE_F); break; case UNICODE_PROP_Changes_When_Titlecased: ret = unicode_prop_ops(cr, POP_CASE, CASE_U, POP_PROP, UNICODE_PROP_Changes_When_Titlecased1, POP_XOR, POP_END); break; case UNICODE_PROP_Changes_When_Casefolded: ret = unicode_prop_ops(cr, POP_CASE, CASE_F, POP_PROP, UNICODE_PROP_Changes_When_Casefolded1, POP_XOR, POP_END); break; case UNICODE_PROP_Changes_When_NFKC_Casefolded: ret = unicode_prop_ops(cr, POP_CASE, CASE_F, POP_PROP, UNICODE_PROP_Changes_When_NFKC_Casefolded1, POP_XOR, POP_END); break; /* we use the existing tables */ case UNICODE_PROP_ID_Continue: ret = unicode_prop_ops(cr, POP_PROP, UNICODE_PROP_ID_Start, POP_PROP, UNICODE_PROP_ID_Continue1, POP_XOR, POP_END); break; default: if (prop_idx >= countof(unicode_prop_table)) return -2; ret = unicode_prop1(cr, prop_idx); break; } return ret; }
O0
c
unicode_prop: subq $0x98, %rsp movq %rdi, 0x88(%rsp) movq %rsi, 0x80(%rsp) movq 0x80(%rsp), %rsi leaq 0xf0aa(%rip), %rdi # 0x11bd30 callq 0x10c030 movl %eax, 0x7c(%rsp) cmpl $0x0, 0x7c(%rsp) jge 0x10cca6 movl $0xfffffffe, 0x94(%rsp) # imm = 0xFFFFFFFE jmp 0x10d1c2 movl 0x7c(%rsp), %eax addl $0x10, %eax movl %eax, 0x7c(%rsp) movl $0x0, 0x78(%rsp) movl 0x7c(%rsp), %eax addl $-0x34, %eax movl %eax, %ecx movq %rcx, 0x70(%rsp) subl $0x14, %eax ja 0x10d18a movq 0x70(%rsp), %rax leaq 0xc0ac(%rip), %rcx # 0x118d88 movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0x80, %edx callq 0x10c120 cmpl $0x0, %eax je 0x10cd0e movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF jmp 0x10d1c2 jmp 0x10d1b7 movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0x110000, %edx # imm = 0x110000 callq 0x10c120 cmpl $0x0, %eax je 0x10cd3c movl $0xffffffff, 0x94(%rsp) # imm = 0xFFFFFFFF jmp 0x10d1c2 jmp 0x10d1b7 movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0x1, %edx movl $0x6, %ecx movl $0x7, %r8d movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0x1000, %edx # imm = 0x1000 movl $0x1, %r8d movl $0x3, %r9d movl %r8d, %ecx movl $0x7, (%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0x4, %edx movl $0x1, %ecx movl $0x3, %r9d movl %r9d, %r8d movl $0x7, (%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0x2, %edx movl $0x1, %ecx movl $0x4, %r8d movl $0x3, %r9d movl $0x7, (%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0xe, %edx movl $0x1, %ecx movl $0x4, %r8d movl $0x3, %r9d movl $0x1, (%rsp) movl $0x3, 0x8(%rsp) movl $0x3, 0x10(%rsp) movl $0x7, 0x18(%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0x43e, %edx # imm = 0x43E movl $0x1, %ecx movl $0x4, %r8d movl $0x3, %r9d movl $0x1, (%rsp) movl $0x3, 0x8(%rsp) movl $0x3, 0x10(%rsp) movl $0x1, 0x18(%rsp) movl $0x2, 0x20(%rsp) movl $0x3, 0x28(%rsp) movl $0x7, 0x30(%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0x3f000141, %edx # imm = 0x3F000141 movl $0x1, %ecx movl $0x5, %r8d movl $0x3, %r9d movl $0x6, (%rsp) movl $0x7, 0x8(%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0x140, %edx # imm = 0x140 movl $0x1, %ecx movl $0x5, %r8d movl $0x3, %r9d movl $0x7, (%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0x43e, %edx # imm = 0x43E movl $0x1, %ecx movl $0x7, %r8d movl $0x3, %r9d movl $0x1, (%rsp) movl $0x1f, 0x8(%rsp) movl $0x1, 0x10(%rsp) movl $0x20, 0x18(%rsp) movl $0x3, 0x20(%rsp) movl $0x1, 0x28(%rsp) movl $0xb, 0x30(%rsp) movl $0x3, 0x38(%rsp) movl $0x6, 0x40(%rsp) movl $0x4, 0x48(%rsp) movl $0x7, 0x50(%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi xorl %esi, %esi movl $0x106fe, %edx # imm = 0x106FE movl $0x1, %ecx movl $0x7, %r8d movl $0x3, %r9d movl $0x1, (%rsp) movl $0x8, 0x8(%rsp) movl $0x3, 0x10(%rsp) movl $0x1, 0x18(%rsp) movl $0x1f, 0x20(%rsp) movl $0x1, 0x28(%rsp) movl $0x20, 0x30(%rsp) movl $0x3, 0x38(%rsp) movl $0x1, 0x40(%rsp) movl $0xc, 0x48(%rsp) movl $0x3, 0x50(%rsp) movl $0x6, 0x58(%rsp) movl $0x4, 0x60(%rsp) movl $0x7, 0x68(%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi movl $0x1, %esi callq 0x10c590 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi movl $0x2, %esi callq 0x10c590 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi movl $0x7, %esi callq 0x10c590 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi movl $0x2, %esi movl $0x1, %ecx movl $0xd, %r8d movl $0x5, %r9d movl %ecx, %edx movl $0x7, (%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi movl $0x2, %esi movl $0x4, %edx movl $0x1, %ecx movl $0xe, %r8d movl $0x5, %r9d movl $0x7, (%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi movl $0x2, %esi movl $0x4, %edx movl $0x1, %ecx movl $0xf, %r8d movl $0x5, %r9d movl $0x7, (%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movq 0x88(%rsp), %rdi movl $0x1, %ecx movl $0x32, %edx movl $0xa, %r8d movl $0x5, %r9d movl %ecx, %esi movl $0x7, (%rsp) movb $0x0, %al callq 0x10d1e0 movl %eax, 0x78(%rsp) jmp 0x10d1b7 movslq 0x7c(%rsp), %rax cmpq $0x34, %rax jb 0x10d1a2 movl $0xfffffffe, 0x94(%rsp) # imm = 0xFFFFFFFE jmp 0x10d1c2 movq 0x88(%rsp), %rdi movl 0x7c(%rsp), %esi callq 0x10d7c0 movl %eax, 0x78(%rsp) movl 0x78(%rsp), %eax movl %eax, 0x94(%rsp) movl 0x94(%rsp), %eax addq $0x98, %rsp retq nopw %cs:(%rax,%rax)
unicode_prop: sub rsp, 98h mov [rsp+98h+var_10], rdi mov [rsp+98h+var_18], rsi mov rsi, [rsp+98h+var_18] lea rdi, unicode_prop_name_table; "ASCII_Hex_Digit,AHex" call unicode_find_name mov [rsp+98h+var_1C], eax cmp [rsp+98h+var_1C], 0 jge short loc_10CCA6 mov [rsp+98h+var_4], 0FFFFFFFEh jmp loc_10D1C2 loc_10CCA6: mov eax, [rsp+98h+var_1C] add eax, 10h mov [rsp+98h+var_1C], eax mov [rsp+98h+var_20], 0 mov eax, [rsp+98h+var_1C] add eax, 0FFFFFFCCh; switch 21 cases mov ecx, eax mov [rsp+98h+var_28], rcx sub eax, 14h ja def_10CCE3; jumptable 000000000010CCE3 default case, cases 66,67 mov rax, [rsp+98h+var_28] lea rcx, jpt_10CCE3 movsxd rax, ds:(jpt_10CCE3 - 118D88h)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_10CCE5: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 52 xor esi, esi mov edx, 80h call cr_add_interval cmp eax, 0 jz short loc_10CD0E mov [rsp+98h+var_4], 0FFFFFFFFh jmp loc_10D1C2 loc_10CD0E: jmp loc_10D1B7 loc_10CD13: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 54 xor esi, esi mov edx, 110000h call cr_add_interval cmp eax, 0 jz short loc_10CD3C mov [rsp+98h+var_4], 0FFFFFFFFh jmp loc_10D1C2 loc_10CD3C: jmp loc_10D1B7 loc_10CD41: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 55 xor esi, esi mov edx, 1 mov ecx, 6 mov r8d, 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10CD6B: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 69 xor esi, esi mov edx, 1000h mov r8d, 1 mov r9d, 3 mov ecx, r8d mov [rsp+98h+var_98], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10CDA0: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 68 xor esi, esi mov edx, 4 mov ecx, 1 mov r9d, 3 mov r8d, r9d mov [rsp+98h+var_98], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10CDD4: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 70 xor esi, esi mov edx, 2 mov ecx, 1 mov r8d, 4 mov r9d, 3 mov [rsp+98h+var_98], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10CE0B: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 56 xor esi, esi mov edx, 0Eh mov ecx, 1 mov r8d, 4 mov r9d, 3 mov [rsp+98h+var_98], 1 mov [rsp+98h+var_90], 3 mov [rsp+98h+var_88], 3 mov [rsp+98h+var_80], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10CE5A: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 53 xor esi, esi mov edx, 43Eh mov ecx, 1 mov r8d, 4 mov r9d, 3 mov [rsp+98h+var_98], 1 mov [rsp+98h+var_90], 3 mov [rsp+98h+var_88], 3 mov [rsp+98h+var_80], 1 mov [rsp+98h+var_78], 2 mov [rsp+98h+var_70], 3 mov [rsp+98h+var_68], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10CEC1: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 63 xor esi, esi mov edx, 3F000141h mov ecx, 1 mov r8d, 5 mov r9d, 3 mov [rsp+98h+var_98], 6 mov [rsp+98h+var_90], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10CF00: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 64 xor esi, esi mov edx, 140h mov ecx, 1 mov r8d, 5 mov r9d, 3 mov [rsp+98h+var_98], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10CF37: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 72 xor esi, esi mov edx, 43Eh mov ecx, 1 mov r8d, 7 mov r9d, 3 mov [rsp+98h+var_98], 1 mov [rsp+98h+var_90], 1Fh mov [rsp+98h+var_88], 1 mov [rsp+98h+var_80], 20h ; ' ' mov [rsp+98h+var_78], 3 mov [rsp+98h+var_70], 1 mov [rsp+98h+var_68], 0Bh mov [rsp+98h+var_60], 3 mov [rsp+98h+var_58], 6 mov [rsp+98h+var_50], 4 mov [rsp+98h+var_48], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10CFBE: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 71 xor esi, esi mov edx, 106FEh mov ecx, 1 mov r8d, 7 mov r9d, 3 mov [rsp+98h+var_98], 1 mov [rsp+98h+var_90], 8 mov [rsp+98h+var_88], 3 mov [rsp+98h+var_80], 1 mov [rsp+98h+var_78], 1Fh mov [rsp+98h+var_70], 1 mov [rsp+98h+var_68], 20h ; ' ' mov [rsp+98h+var_60], 3 mov [rsp+98h+var_58], 1 mov [rsp+98h+var_50], 0Ch mov [rsp+98h+var_48], 3 mov [rsp+98h+var_40], 6 mov [rsp+98h+var_38], 4 mov [rsp+98h+var_30], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10D05D: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 62 mov esi, 1 call unicode_case1 mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10D078: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 59 mov esi, 2 call unicode_case1 mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10D093: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 58 mov esi, 7 call unicode_case1 mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10D0AE: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 61 mov esi, 2 mov ecx, 1 mov r8d, 0Dh mov r9d, 5 mov edx, ecx mov [rsp+98h+var_98], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10D0E5: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 57 mov esi, 2 mov edx, 4 mov ecx, 1 mov r8d, 0Eh mov r9d, 5 mov [rsp+98h+var_98], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp loc_10D1B7 loc_10D11F: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 60 mov esi, 2 mov edx, 4 mov ecx, 1 mov r8d, 0Fh mov r9d, 5 mov [rsp+98h+var_98], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp short loc_10D1B7 loc_10D156: mov rdi, [rsp+98h+var_10]; jumptable 000000000010CCE3 case 65 mov ecx, 1 mov edx, 32h ; '2' mov r8d, 0Ah mov r9d, 5 mov esi, ecx mov [rsp+98h+var_98], 7 mov al, 0 call unicode_prop_ops mov [rsp+98h+var_20], eax jmp short loc_10D1B7 def_10CCE3: movsxd rax, [rsp+98h+var_1C]; jumptable 000000000010CCE3 default case, cases 66,67 cmp rax, 34h ; '4' jb short loc_10D1A2 mov [rsp+98h+var_4], 0FFFFFFFEh jmp short loc_10D1C2 loc_10D1A2: mov rdi, [rsp+98h+var_10] mov esi, [rsp+98h+var_1C] call unicode_prop1 mov [rsp+98h+var_20], eax loc_10D1B7: mov eax, [rsp+98h+var_20] mov [rsp+98h+var_4], eax loc_10D1C2: mov eax, [rsp+98h+var_4] add rsp, 98h retn
long long unicode_prop(long long a1, long long a2) { int v2; // r9d unsigned int v4; // [rsp+78h] [rbp-20h] int name; // [rsp+7Ch] [rbp-1Ch] int v6; // [rsp+7Ch] [rbp-1Ch] unsigned int v7; // [rsp+94h] [rbp-4h] name = unicode_find_name("ASCII_Hex_Digit,AHex", a2); if ( name >= 0 ) { v6 = name + 16; v4 = 0; switch ( v6 ) { case '4': if ( !(unsigned int)cr_add_interval(a1, 0, 128) ) goto LABEL_30; return (unsigned int)-1; case '5': v4 = unicode_prop_ops(a1, 0, 1086, 1, 4, 3); goto LABEL_30; case '6': if ( !(unsigned int)cr_add_interval(a1, 0, 1114112) ) goto LABEL_30; v7 = -1; break; case '7': v4 = unicode_prop_ops(a1, 0, 1, 6, 7, v2); goto LABEL_30; case '8': v4 = unicode_prop_ops(a1, 0, 14, 1, 4, 3); goto LABEL_30; case '9': v4 = unicode_prop_ops(a1, 2, 4, 1, 14, 5); goto LABEL_30; case ':': v4 = unicode_case1(a1, 7); goto LABEL_30; case ';': v4 = unicode_case1(a1, 2); goto LABEL_30; case '<': v4 = unicode_prop_ops(a1, 2, 4, 1, 15, 5); goto LABEL_30; case '=': v4 = unicode_prop_ops(a1, 2, 1, 1, 13, 5); goto LABEL_30; case '>': v4 = unicode_case1(a1, 1); goto LABEL_30; case '?': v4 = unicode_prop_ops(a1, 0, 1056964929, 1, 5, 3); goto LABEL_30; case '@': v4 = unicode_prop_ops(a1, 0, 320, 1, 5, 3); goto LABEL_30; case 'A': v4 = unicode_prop_ops(a1, 1, 50, 1, 10, 5); goto LABEL_30; case 'D': v4 = unicode_prop_ops(a1, 0, 4, 1, 3, 3); goto LABEL_30; case 'E': v4 = unicode_prop_ops(a1, 0, 4096, 1, 1, 3); goto LABEL_30; case 'F': v4 = unicode_prop_ops(a1, 0, 2, 1, 4, 3); goto LABEL_30; case 'G': v4 = unicode_prop_ops(a1, 0, 67326, 1, 7, 3); goto LABEL_30; case 'H': v4 = unicode_prop_ops(a1, 0, 1086, 1, 7, 3); goto LABEL_30; default: if ( (unsigned long long)v6 < 0x34 ) { v4 = unicode_prop1(a1, (unsigned int)v6); LABEL_30: v7 = v4; } else { v7 = -2; } break; } } else { return (unsigned int)-2; } return v7; }
3,517
unicode_prop
bluesky950520[P]quickjs/libunicode.c
int unicode_prop(CharRange *cr, const char *prop_name) { int prop_idx, ret; prop_idx = unicode_find_name(unicode_prop_name_table, prop_name); if (prop_idx < 0) return -2; prop_idx += UNICODE_PROP_ASCII_Hex_Digit; ret = 0; switch(prop_idx) { case UNICODE_PROP_ASCII: if (cr_add_interval(cr, 0x00, 0x7f + 1)) return -1; break; case UNICODE_PROP_Any: if (cr_add_interval(cr, 0x00000, 0x10ffff + 1)) return -1; break; case UNICODE_PROP_Assigned: ret = unicode_prop_ops(cr, POP_GC, M(Cn), POP_INVERT, POP_END); break; case UNICODE_PROP_Math: ret = unicode_prop_ops(cr, POP_GC, M(Sm), POP_PROP, UNICODE_PROP_Other_Math, POP_UNION, POP_END); break; case UNICODE_PROP_Lowercase: ret = unicode_prop_ops(cr, POP_GC, M(Ll), POP_PROP, UNICODE_PROP_Other_Lowercase, POP_UNION, POP_END); break; case UNICODE_PROP_Uppercase: ret = unicode_prop_ops(cr, POP_GC, M(Lu), POP_PROP, UNICODE_PROP_Other_Uppercase, POP_UNION, POP_END); break; case UNICODE_PROP_Cased: ret = unicode_prop_ops(cr, POP_GC, M(Lu) | M(Ll) | M(Lt), POP_PROP, UNICODE_PROP_Other_Uppercase, POP_UNION, POP_PROP, UNICODE_PROP_Other_Lowercase, POP_UNION, POP_END); break; case UNICODE_PROP_Alphabetic: ret = unicode_prop_ops(cr, POP_GC, M(Lu) | M(Ll) | M(Lt) | M(Lm) | M(Lo) | M(Nl), POP_PROP, UNICODE_PROP_Other_Uppercase, POP_UNION, POP_PROP, UNICODE_PROP_Other_Lowercase, POP_UNION, POP_PROP, UNICODE_PROP_Other_Alphabetic, POP_UNION, POP_END); break; case UNICODE_PROP_Grapheme_Base: ret = unicode_prop_ops(cr, POP_GC, M(Cc) | M(Cf) | M(Cs) | M(Co) | M(Cn) | M(Zl) | M(Zp) | M(Me) | M(Mn), POP_PROP, UNICODE_PROP_Other_Grapheme_Extend, POP_UNION, POP_INVERT, POP_END); break; case UNICODE_PROP_Grapheme_Extend: ret = unicode_prop_ops(cr, POP_GC, M(Me) | M(Mn), POP_PROP, UNICODE_PROP_Other_Grapheme_Extend, POP_UNION, POP_END); break; case UNICODE_PROP_XID_Start: ret = unicode_prop_ops(cr, POP_GC, M(Lu) | M(Ll) | M(Lt) | M(Lm) | M(Lo) | M(Nl), POP_PROP, UNICODE_PROP_Other_ID_Start, POP_UNION, POP_PROP, UNICODE_PROP_Pattern_Syntax, POP_PROP, UNICODE_PROP_Pattern_White_Space, POP_UNION, POP_PROP, UNICODE_PROP_XID_Start1, POP_UNION, POP_INVERT, POP_INTER, POP_END); break; case UNICODE_PROP_XID_Continue: ret = unicode_prop_ops(cr, POP_GC, M(Lu) | M(Ll) | M(Lt) | M(Lm) | M(Lo) | M(Nl) | M(Mn) | M(Mc) | M(Nd) | M(Pc), POP_PROP, UNICODE_PROP_Other_ID_Start, POP_UNION, POP_PROP, UNICODE_PROP_Other_ID_Continue, POP_UNION, POP_PROP, UNICODE_PROP_Pattern_Syntax, POP_PROP, UNICODE_PROP_Pattern_White_Space, POP_UNION, POP_PROP, UNICODE_PROP_XID_Continue1, POP_UNION, POP_INVERT, POP_INTER, POP_END); break; case UNICODE_PROP_Changes_When_Uppercased: ret = unicode_case1(cr, CASE_U); break; case UNICODE_PROP_Changes_When_Lowercased: ret = unicode_case1(cr, CASE_L); break; case UNICODE_PROP_Changes_When_Casemapped: ret = unicode_case1(cr, CASE_U | CASE_L | CASE_F); break; case UNICODE_PROP_Changes_When_Titlecased: ret = unicode_prop_ops(cr, POP_CASE, CASE_U, POP_PROP, UNICODE_PROP_Changes_When_Titlecased1, POP_XOR, POP_END); break; case UNICODE_PROP_Changes_When_Casefolded: ret = unicode_prop_ops(cr, POP_CASE, CASE_F, POP_PROP, UNICODE_PROP_Changes_When_Casefolded1, POP_XOR, POP_END); break; case UNICODE_PROP_Changes_When_NFKC_Casefolded: ret = unicode_prop_ops(cr, POP_CASE, CASE_F, POP_PROP, UNICODE_PROP_Changes_When_NFKC_Casefolded1, POP_XOR, POP_END); break; /* we use the existing tables */ case UNICODE_PROP_ID_Continue: ret = unicode_prop_ops(cr, POP_PROP, UNICODE_PROP_ID_Start, POP_PROP, UNICODE_PROP_ID_Continue1, POP_XOR, POP_END); break; default: if (prop_idx >= countof(unicode_prop_table)) return -2; ret = unicode_prop1(cr, prop_idx); break; } return ret; }
O3
c
unicode_prop: pushq %rbx movq %rdi, %rbx leaq 0xd1e2(%rip), %rdi # 0xad890 callq 0x9fd60 movl %eax, %esi movl $0xfffffffe, %eax # imm = 0xFFFFFFFE testl %esi, %esi js 0xa0a07 leal -0x24(%rsi), %ecx cmpl $0x14, %ecx ja 0xa0a09 leaq 0xa23f(%rip), %rdx # 0xaa914 movslq (%rdx,%rcx,4), %rcx addq %rdx, %rcx jmpq *%rcx movl (%rbx), %eax leal 0x2(%rax), %esi cmpl 0x4(%rbx), %esi jle 0xa0701 movq %rbx, %rdi callq 0x9ef7b movl %eax, %ecx movl $0xffffffff, %eax # imm = 0xFFFFFFFF testl %ecx, %ecx jne 0xa0a07 movl (%rbx), %eax movq 0x8(%rbx), %rcx leal 0x1(%rax), %edx movl %edx, (%rbx) cltq movl $0x0, (%rcx,%rax,4) movslq (%rbx), %rax leal 0x1(%rax), %edx movl %edx, (%rbx) movl $0x80, (%rcx,%rax,4) jmp 0xa08ee subq $0x8, %rsp movl $0x3, %r11d movl $0x1, %r10d movq %rbx, %rdi xorl %esi, %esi movl $0x43e, %edx # imm = 0x43E movl $0x1, %ecx movl $0x7, %r8d movl $0x3, %r9d xorl %eax, %eax pushq $0x7 pushq $0x4 pushq $0x6 pushq %r11 pushq $0xb pushq %r10 pushq %r11 pushq $0x20 pushq %r10 pushq $0x1f pushq %r10 callq 0xa0a1a addq $0x60, %rsp jmp 0xa0a07 subq $0x8, %rsp movq %rbx, %rdi movl $0x1, %esi movl $0x32, %edx movl $0x1, %ecx movl $0xa, %r8d jmp 0xa0983 movq %rbx, %rdi movl $0x1, %esi jmp 0xa0907 movl $0x3, %r10d movq %rbx, %rdi xorl %esi, %esi movl $0xe, %edx movl $0x1, %ecx movl $0x4, %r8d movl $0x3, %r9d xorl %eax, %eax pushq $0x7 pushq %r10 pushq %r10 pushq $0x1 callq 0xa0a1a addq $0x20, %rsp jmp 0xa0a07 subq $0x8, %rsp movq %rbx, %rdi xorl %esi, %esi movl $0x140, %edx # imm = 0x140 movl $0x1, %ecx movl $0x5, %r8d jmp 0xa09f4 subq $0x8, %rsp movl $0x3, %r10d movl $0x1, %r11d movq %rbx, %rdi xorl %esi, %esi movl $0x43e, %edx # imm = 0x43E movl $0x1, %ecx movl $0x4, %r8d movl $0x3, %r9d xorl %eax, %eax pushq $0x7 pushq %r10 pushq $0x2 pushq %r11 pushq %r10 pushq %r10 pushq %r11 callq 0xa0a1a addq $0x40, %rsp jmp 0xa0a07 subq $0x8, %rsp movq %rbx, %rdi movl $0x2, %esi movl $0x4, %edx movl $0x1, %ecx movl $0xe, %r8d jmp 0xa0983 movq %rbx, %rdi xorl %esi, %esi movl $0x3f000141, %edx # imm = 0x3F000141 movl $0x1, %ecx movl $0x5, %r8d movl $0x3, %r9d xorl %eax, %eax pushq $0x7 pushq $0x6 jmp 0xa09fe movq %rbx, %rdi xorl %esi, %esi movl $0x1, %edx movl $0x6, %ecx movl $0x7, %r8d xorl %eax, %eax popq %rbx jmp 0xa0a1a movl (%rbx), %eax leal 0x2(%rax), %esi cmpl 0x4(%rbx), %esi jle 0xa08cd movq %rbx, %rdi callq 0x9ef7b movl %eax, %ecx movl $0xffffffff, %eax # imm = 0xFFFFFFFF testl %ecx, %ecx jne 0xa0a07 movl (%rbx), %eax movq 0x8(%rbx), %rcx leal 0x1(%rax), %edx movl %edx, (%rbx) cltq movl $0x0, (%rcx,%rax,4) movslq (%rbx), %rax leal 0x1(%rax), %edx movl %edx, (%rbx) movl $0x110000, (%rcx,%rax,4) # imm = 0x110000 xorl %eax, %eax jmp 0xa0a07 movq %rbx, %rdi movl $0x7, %esi jmp 0xa0907 movq %rbx, %rdi movl $0x2, %esi popq %rbx jmp 0xa025e subq $0x8, %rsp movq %rbx, %rdi xorl %esi, %esi movl $0x4, %edx movl $0x1, %ecx movl $0x3, %r8d jmp 0xa09f4 subq $0x8, %rsp movq %rbx, %rdi xorl %esi, %esi movl $0x1000, %edx # imm = 0x1000 movl $0x1, %ecx movl $0x1, %r8d jmp 0xa09f4 subq $0x8, %rsp movq %rbx, %rdi movl $0x2, %esi movl $0x1, %edx movl $0x1, %ecx movl $0xd, %r8d jmp 0xa0983 subq $0x8, %rsp movq %rbx, %rdi movl $0x2, %esi movl $0x4, %edx movl $0x1, %ecx movl $0xf, %r8d movl $0x5, %r9d jmp 0xa09fa movl $0x3, %r11d movl $0x1, %r10d movq %rbx, %rdi xorl %esi, %esi movl $0x106fe, %edx # imm = 0x106FE movl $0x1, %ecx movl $0x7, %r8d movl $0x3, %r9d xorl %eax, %eax pushq $0x7 pushq $0x4 pushq $0x6 pushq %r11 pushq $0xc pushq %r10 pushq %r11 pushq $0x20 pushq %r10 pushq $0x1f pushq %r10 pushq %r11 pushq $0x8 pushq %r10 callq 0xa0a1a addq $0x70, %rsp jmp 0xa0a07 subq $0x8, %rsp movq %rbx, %rdi xorl %esi, %esi movl $0x2, %edx movl $0x1, %ecx movl $0x4, %r8d movl $0x3, %r9d xorl %eax, %eax pushq $0x7 callq 0xa0a1a addq $0x10, %rsp popq %rbx retq cmpl $0x23, %esi ja 0xa0a07 addl $0x10, %esi movq %rbx, %rdi popq %rbx jmp 0xa0d63
unicode_prop: push rbx mov rbx, rdi lea rdi, unicode_prop_name_table; "ASCII_Hex_Digit,AHex" call unicode_find_name mov esi, eax mov eax, 0FFFFFFFEh test esi, esi js loc_A0A07 lea ecx, [rsi-24h]; switch 21 cases cmp ecx, 14h ja def_A06DC; jumptable 00000000000A06DC default case, cases 50,51 lea rdx, jpt_A06DC movsxd rcx, ds:(jpt_A06DC - 0AA914h)[rdx+rcx*4] add rcx, rdx jmp rcx; switch jump loc_A06DE: mov eax, [rbx]; jumptable 00000000000A06DC case 36 lea esi, [rax+2] cmp esi, [rbx+4] jle short loc_A0701 mov rdi, rbx call cr_realloc mov ecx, eax mov eax, 0FFFFFFFFh test ecx, ecx jnz loc_A0A07 mov eax, [rbx] loc_A0701: mov rcx, [rbx+8] lea edx, [rax+1] mov [rbx], edx cdqe mov dword ptr [rcx+rax*4], 0 movsxd rax, dword ptr [rbx] lea edx, [rax+1] mov [rbx], edx mov dword ptr [rcx+rax*4], 80h jmp loc_A08EE loc_A0727: sub rsp, 8; jumptable 00000000000A06DC case 56 mov r11d, 3 mov r10d, 1 mov rdi, rbx xor esi, esi mov edx, 43Eh mov ecx, 1 mov r8d, 7 mov r9d, 3 xor eax, eax push 7 push 4 push 6 push r11 push 0Bh push r10 push r11 push 20h ; ' ' push r10 push 1Fh push r10 call unicode_prop_ops add rsp, 60h jmp loc_A0A07 loc_A0778: sub rsp, 8; jumptable 00000000000A06DC case 49 mov rdi, rbx mov esi, 1 mov edx, 32h ; '2' mov ecx, 1 mov r8d, 0Ah jmp loc_A0983 loc_A0799: mov rdi, rbx; jumptable 00000000000A06DC case 46 mov esi, 1 jmp loc_A0907 loc_A07A6: mov r10d, 3; jumptable 00000000000A06DC case 40 mov rdi, rbx xor esi, esi mov edx, 0Eh mov ecx, 1 mov r8d, 4 mov r9d, 3 xor eax, eax push 7 push r10 push r10 push 1 call unicode_prop_ops add rsp, 20h jmp loc_A0A07 loc_A07DF: sub rsp, 8; jumptable 00000000000A06DC case 48 mov rdi, rbx xor esi, esi mov edx, 140h mov ecx, 1 mov r8d, 5 jmp loc_A09F4 loc_A07FD: sub rsp, 8; jumptable 00000000000A06DC case 37 mov r10d, 3 mov r11d, 1 mov rdi, rbx xor esi, esi mov edx, 43Eh mov ecx, 1 mov r8d, 4 mov r9d, 3 xor eax, eax push 7 push r10 push 2 push r11 push r10 push r10 push r11 call unicode_prop_ops add rsp, 40h jmp loc_A0A07 loc_A0846: sub rsp, 8; jumptable 00000000000A06DC case 41 mov rdi, rbx mov esi, 2 mov edx, 4 mov ecx, 1 mov r8d, 0Eh jmp loc_A0983 loc_A0867: mov rdi, rbx; jumptable 00000000000A06DC case 47 xor esi, esi mov edx, 3F000141h mov ecx, 1 mov r8d, 5 mov r9d, 3 xor eax, eax push 7 push 6 jmp loc_A09FE loc_A088D: mov rdi, rbx; jumptable 00000000000A06DC case 39 xor esi, esi mov edx, 1 mov ecx, 6 mov r8d, 7 xor eax, eax pop rbx jmp unicode_prop_ops loc_A08AA: mov eax, [rbx]; jumptable 00000000000A06DC case 38 lea esi, [rax+2] cmp esi, [rbx+4] jle short loc_A08CD mov rdi, rbx call cr_realloc mov ecx, eax mov eax, 0FFFFFFFFh test ecx, ecx jnz loc_A0A07 mov eax, [rbx] loc_A08CD: mov rcx, [rbx+8] lea edx, [rax+1] mov [rbx], edx cdqe mov dword ptr [rcx+rax*4], 0 movsxd rax, dword ptr [rbx] lea edx, [rax+1] mov [rbx], edx mov dword ptr [rcx+rax*4], 110000h loc_A08EE: xor eax, eax jmp loc_A0A07 loc_A08F5: mov rdi, rbx; jumptable 00000000000A06DC case 42 mov esi, 7 jmp short loc_A0907 loc_A08FF: mov rdi, rbx; jumptable 00000000000A06DC case 43 mov esi, 2 loc_A0907: pop rbx jmp unicode_case1 loc_A090D: sub rsp, 8; jumptable 00000000000A06DC case 52 mov rdi, rbx xor esi, esi mov edx, 4 mov ecx, 1 mov r8d, 3 jmp loc_A09F4 loc_A092B: sub rsp, 8; jumptable 00000000000A06DC case 53 mov rdi, rbx xor esi, esi mov edx, 1000h mov ecx, 1 mov r8d, 1 jmp loc_A09F4 loc_A0949: sub rsp, 8; jumptable 00000000000A06DC case 45 mov rdi, rbx mov esi, 2 mov edx, 1 mov ecx, 1 mov r8d, 0Dh jmp short loc_A0983 loc_A0967: sub rsp, 8; jumptable 00000000000A06DC case 44 mov rdi, rbx mov esi, 2 mov edx, 4 mov ecx, 1 mov r8d, 0Fh loc_A0983: mov r9d, 5 jmp short loc_A09FA loc_A098B: mov r11d, 3; jumptable 00000000000A06DC case 55 mov r10d, 1 mov rdi, rbx xor esi, esi mov edx, 106FEh mov ecx, 1 mov r8d, 7 mov r9d, 3 xor eax, eax push 7 push 4 push 6 push r11 push 0Ch push r10 push r11 push 20h ; ' ' push r10 push 1Fh push r10 push r11 push 8 push r10 call unicode_prop_ops add rsp, 70h jmp short loc_A0A07 loc_A09DB: sub rsp, 8; jumptable 00000000000A06DC case 54 mov rdi, rbx xor esi, esi mov edx, 2 mov ecx, 1 mov r8d, 4 loc_A09F4: mov r9d, 3 loc_A09FA: xor eax, eax push 7 loc_A09FE: call unicode_prop_ops add rsp, 10h loc_A0A07: pop rbx retn def_A06DC: cmp esi, 23h ; '#'; jumptable 00000000000A06DC default case, cases 50,51 ja short loc_A0A07 add esi, 10h mov rdi, rbx pop rbx jmp unicode_prop1
long long unicode_prop(int *a1, long long a2) { int name; // esi int v3; // r9d long long result; // rax int v5; // eax int v6; // esi int v7; // ecx long long v8; // rcx long long v9; // rax int v10; // esi int v11; // edx int v12; // r8d int v13; // eax int v14; // esi int v15; // ecx long long v16; // rcx long long v17; // rax int v18; // r9d name = unicode_find_name("ASCII_Hex_Digit,AHex", a2); result = 4294967294LL; if ( name >= 0 ) { switch ( name ) { case '$': v5 = *a1; v6 = *a1 + 2; if ( v6 <= a1[1] ) goto LABEL_6; v7 = cr_realloc((long long)a1, v6); result = 0xFFFFFFFFLL; if ( !v7 ) { v5 = *a1; LABEL_6: v8 = *((_QWORD *)a1 + 1); *a1 = v5 + 1; *(_DWORD *)(v8 + 4LL * v5) = 0; v9 = *a1; *a1 = v9 + 1; *(_DWORD *)(v8 + 4 * v9) = 128; return 0LL; } return result; case '%': return unicode_prop_ops((_DWORD)a1, 0, 1086, 1, 4, 3, 1LL, 3LL, 3LL, 1LL, 2LL, 3LL, 7LL); case '&': v13 = *a1; v14 = *a1 + 2; if ( v14 <= a1[1] ) goto LABEL_19; v15 = cr_realloc((long long)a1, v14); result = 0xFFFFFFFFLL; if ( !v15 ) { v13 = *a1; LABEL_19: v16 = *((_QWORD *)a1 + 1); *a1 = v13 + 1; *(_DWORD *)(v16 + 4LL * v13) = 0; v17 = *a1; *a1 = v17 + 1; *(_DWORD *)(v16 + 4 * v17) = 1114112; return 0LL; } return result; case '\'': return unicode_prop_ops((_DWORD)a1, 0, 1, 6, 7, v3); case '(': return unicode_prop_ops((_DWORD)a1, 0, 14, 1, 4, 3, 1LL, 3LL, 3LL, 7LL); case ')': v10 = 2; v11 = 4; v12 = 14; goto LABEL_28; case '*': return unicode_case1(a1, 7); case '+': return unicode_case1(a1, 2); case ',': v10 = 2; v11 = 4; v12 = 15; goto LABEL_28; case '-': v10 = 2; v11 = 1; v12 = 13; goto LABEL_28; case '.': return unicode_case1(a1, 1); case '/': return unicode_prop_ops((_DWORD)a1, 0, 1056964929, 1, 5, 3, 6LL, 7LL); case '0': v10 = 0; v11 = 320; v12 = 5; goto LABEL_31; case '1': v10 = 1; v11 = 50; v12 = 10; LABEL_28: v18 = 5; goto LABEL_32; case '4': v10 = 0; v11 = 4; v12 = 3; goto LABEL_31; case '5': v10 = 0; v11 = 4096; v12 = 1; goto LABEL_31; case '6': v10 = 0; v11 = 2; v12 = 4; LABEL_31: v18 = 3; LABEL_32: result = unicode_prop_ops((_DWORD)a1, v10, v11, 1, v12, v18, 7LL); break; case '7': result = unicode_prop_ops( (_DWORD)a1, 0, 67326, 1, 7, 3, 1LL, 8LL, 3LL, 1LL, 31LL, 1LL, 32LL, 3LL, 1LL, 12LL, 3LL, 6LL, 4LL, 7LL); break; case '8': result = unicode_prop_ops( (_DWORD)a1, 0, 1086, 1, 7, 3, 1LL, 31LL, 1LL, 32LL, 3LL, 1LL, 11LL, 3LL, 6LL, 4LL, 7LL); break; default: if ( (unsigned int)name <= 0x23 ) result = unicode_prop1(a1, (unsigned int)(name + 16)); break; } } return result; }
unicode_prop: PUSH RBX MOV RBX,RDI LEA RDI,[0x1ad890] CALL 0x0019fd60 MOV ESI,EAX MOV EAX,0xfffffffe TEST ESI,ESI JS 0x001a0a07 LEA ECX,[RSI + -0x24] CMP ECX,0x14 JA 0x001a0a09 LEA RDX,[0x1aa914] MOVSXD RCX,dword ptr [RDX + RCX*0x4] ADD RCX,RDX switchD: JMP RCX caseD_24: MOV EAX,dword ptr [RBX] LEA ESI,[RAX + 0x2] CMP ESI,dword ptr [RBX + 0x4] JLE 0x001a0701 MOV RDI,RBX CALL 0x0019ef7b MOV ECX,EAX MOV EAX,0xffffffff TEST ECX,ECX JNZ 0x001a0a07 MOV EAX,dword ptr [RBX] LAB_001a0701: MOV RCX,qword ptr [RBX + 0x8] LEA EDX,[RAX + 0x1] MOV dword ptr [RBX],EDX CDQE MOV dword ptr [RCX + RAX*0x4],0x0 MOVSXD RAX,dword ptr [RBX] LEA EDX,[RAX + 0x1] MOV dword ptr [RBX],EDX MOV dword ptr [RCX + RAX*0x4],0x80 JMP 0x001a08ee caseD_38: SUB RSP,0x8 MOV R11D,0x3 MOV R10D,0x1 MOV RDI,RBX XOR ESI,ESI MOV EDX,0x43e MOV ECX,0x1 MOV R8D,0x7 MOV R9D,0x3 XOR EAX,EAX PUSH 0x7 PUSH 0x4 PUSH 0x6 PUSH R11 PUSH 0xb PUSH R10 PUSH R11 PUSH 0x20 PUSH R10 PUSH 0x1f PUSH R10 CALL 0x001a0a1a ADD RSP,0x60 JMP 0x001a0a07 caseD_31: SUB RSP,0x8 MOV RDI,RBX MOV ESI,0x1 MOV EDX,0x32 MOV ECX,0x1 MOV R8D,0xa JMP 0x001a0983 caseD_2e: MOV RDI,RBX MOV ESI,0x1 JMP 0x001a0907 caseD_28: MOV R10D,0x3 MOV RDI,RBX XOR ESI,ESI MOV EDX,0xe MOV ECX,0x1 MOV R8D,0x4 MOV R9D,0x3 XOR EAX,EAX PUSH 0x7 PUSH R10 PUSH R10 PUSH 0x1 CALL 0x001a0a1a ADD RSP,0x20 JMP 0x001a0a07 caseD_30: SUB RSP,0x8 MOV RDI,RBX XOR ESI,ESI MOV EDX,0x140 MOV ECX,0x1 MOV R8D,0x5 JMP 0x001a09f4 caseD_25: SUB RSP,0x8 MOV R10D,0x3 MOV R11D,0x1 MOV RDI,RBX XOR ESI,ESI MOV EDX,0x43e MOV ECX,0x1 MOV R8D,0x4 MOV R9D,0x3 XOR EAX,EAX PUSH 0x7 PUSH R10 PUSH 0x2 PUSH R11 PUSH R10 PUSH R10 PUSH R11 CALL 0x001a0a1a ADD RSP,0x40 JMP 0x001a0a07 caseD_29: SUB RSP,0x8 MOV RDI,RBX MOV ESI,0x2 MOV EDX,0x4 MOV ECX,0x1 MOV R8D,0xe JMP 0x001a0983 caseD_2f: MOV RDI,RBX XOR ESI,ESI MOV EDX,0x3f000141 MOV ECX,0x1 MOV R8D,0x5 MOV R9D,0x3 XOR EAX,EAX PUSH 0x7 PUSH 0x6 JMP 0x001a09fe caseD_27: MOV RDI,RBX XOR ESI,ESI MOV EDX,0x1 MOV ECX,0x6 MOV R8D,0x7 XOR EAX,EAX POP RBX JMP 0x001a0a1a caseD_26: MOV EAX,dword ptr [RBX] LEA ESI,[RAX + 0x2] CMP ESI,dword ptr [RBX + 0x4] JLE 0x001a08cd MOV RDI,RBX CALL 0x0019ef7b MOV ECX,EAX MOV EAX,0xffffffff TEST ECX,ECX JNZ 0x001a0a07 MOV EAX,dword ptr [RBX] LAB_001a08cd: MOV RCX,qword ptr [RBX + 0x8] LEA EDX,[RAX + 0x1] MOV dword ptr [RBX],EDX CDQE MOV dword ptr [RCX + RAX*0x4],0x0 MOVSXD RAX,dword ptr [RBX] LEA EDX,[RAX + 0x1] MOV dword ptr [RBX],EDX MOV dword ptr [RCX + RAX*0x4],0x110000 LAB_001a08ee: XOR EAX,EAX JMP 0x001a0a07 caseD_2a: MOV RDI,RBX MOV ESI,0x7 JMP 0x001a0907 caseD_2b: MOV RDI,RBX MOV ESI,0x2 LAB_001a0907: POP RBX JMP 0x001a025e caseD_34: SUB RSP,0x8 MOV RDI,RBX XOR ESI,ESI MOV EDX,0x4 MOV ECX,0x1 MOV R8D,0x3 JMP 0x001a09f4 caseD_35: SUB RSP,0x8 MOV RDI,RBX XOR ESI,ESI MOV EDX,0x1000 MOV ECX,0x1 MOV R8D,0x1 JMP 0x001a09f4 caseD_2d: SUB RSP,0x8 MOV RDI,RBX MOV ESI,0x2 MOV EDX,0x1 MOV ECX,0x1 MOV R8D,0xd JMP 0x001a0983 caseD_2c: SUB RSP,0x8 MOV RDI,RBX MOV ESI,0x2 MOV EDX,0x4 MOV ECX,0x1 MOV R8D,0xf LAB_001a0983: MOV R9D,0x5 JMP 0x001a09fa caseD_37: MOV R11D,0x3 MOV R10D,0x1 MOV RDI,RBX XOR ESI,ESI MOV EDX,0x106fe MOV ECX,0x1 MOV R8D,0x7 MOV R9D,0x3 XOR EAX,EAX PUSH 0x7 PUSH 0x4 PUSH 0x6 PUSH R11 PUSH 0xc PUSH R10 PUSH R11 PUSH 0x20 PUSH R10 PUSH 0x1f PUSH R10 PUSH R11 PUSH 0x8 PUSH R10 CALL 0x001a0a1a ADD RSP,0x70 JMP 0x001a0a07 caseD_36: SUB RSP,0x8 MOV RDI,RBX XOR ESI,ESI MOV EDX,0x2 MOV ECX,0x1 MOV R8D,0x4 LAB_001a09f4: MOV R9D,0x3 LAB_001a09fa: XOR EAX,EAX PUSH 0x7 LAB_001a09fe: CALL 0x001a0a1a ADD RSP,0x10 LAB_001a0a07: POP RBX RET caseD_32: CMP ESI,0x23 JA 0x001a0a07 ADD ESI,0x10 MOV RDI,RBX POP RBX JMP 0x001a0d63
int8 unicode_prop(int *param_1) { long lVar1; uint uVar2; int iVar3; int8 uVar4; int8 uVar5; int8 uVar6; int8 uVar7; int8 uVar8; uVar2 = unicode_find_name("ASCII_Hex_Digit,AHex"); uVar4 = 0xfffffffe; if ((int)uVar2 < 0) { return 0xfffffffe; } switch(uVar2) { case 0x24: iVar3 = *param_1; if (param_1[1] < iVar3 + 2) { iVar3 = cr_realloc(param_1); if (iVar3 != 0) { return 0xffffffff; } iVar3 = *param_1; } lVar1 = *(long *)(param_1 + 2); *param_1 = iVar3 + 1; *(int4 *)(lVar1 + (long)iVar3 * 4) = 0; iVar3 = *param_1; *param_1 = iVar3 + 1; *(int4 *)(lVar1 + (long)iVar3 * 4) = 0x80; goto LAB_001a08ee; case 0x25: uVar4 = unicode_prop_ops(param_1,0,0x43e,1,4,3,1,3,3,1,2,3,7); break; case 0x26: iVar3 = *param_1; if (param_1[1] < iVar3 + 2) { iVar3 = cr_realloc(param_1); if (iVar3 != 0) { return 0xffffffff; } iVar3 = *param_1; } lVar1 = *(long *)(param_1 + 2); *param_1 = iVar3 + 1; *(int4 *)(lVar1 + (long)iVar3 * 4) = 0; iVar3 = *param_1; *param_1 = iVar3 + 1; *(int4 *)(lVar1 + (long)iVar3 * 4) = 0x110000; LAB_001a08ee: uVar4 = 0; break; case 0x27: uVar4 = unicode_prop_ops(param_1,0,1,6,7); return uVar4; case 0x28: uVar4 = unicode_prop_ops(param_1,0,0xe,1,4,3,1,3,3,7); break; case 0x29: uVar5 = 2; uVar4 = 4; uVar6 = 0xe; goto LAB_001a0983; case 0x2a: uVar4 = 7; goto LAB_001a0907; case 0x2b: uVar4 = 2; goto LAB_001a0907; case 0x2c: uVar5 = 2; uVar4 = 4; uVar6 = 0xf; goto LAB_001a0983; case 0x2d: uVar5 = 2; uVar4 = 1; uVar6 = 0xd; goto LAB_001a0983; case 0x2e: uVar4 = 1; LAB_001a0907: uVar4 = unicode_case1(param_1,uVar4); return uVar4; case 0x2f: uVar5 = 0; uVar4 = 0x3f000141; uVar6 = 5; uVar7 = 3; uVar8 = 6; goto LAB_001a09fe; case 0x30: uVar4 = 0x140; uVar6 = 5; goto LAB_001a09f4; case 0x31: uVar5 = 1; uVar4 = 0x32; uVar6 = 10; LAB_001a0983: uVar7 = 5; LAB_001a09fa: uVar8 = 7; LAB_001a09fe: uVar4 = unicode_prop_ops(param_1,uVar5,uVar4,1,uVar6,uVar7,uVar8); break; default: if (uVar2 < 0x24) { uVar4 = unicode_prop1(param_1,uVar2 + 0x10); return uVar4; } break; case 0x34: uVar4 = 4; uVar6 = 3; goto LAB_001a09f4; case 0x35: uVar4 = 0x1000; uVar6 = 1; goto LAB_001a09f4; case 0x36: uVar4 = 2; uVar6 = 4; LAB_001a09f4: uVar5 = 0; uVar7 = 3; goto LAB_001a09fa; case 0x37: uVar4 = unicode_prop_ops(param_1,0,0x106fe,1,7,3,1,8,3,1,0x1f,1,0x20,3,1,0xc,3,6,4,7); break; case 0x38: uVar4 = unicode_prop_ops(param_1,0,0x43e,1,7,3,1,0x1f,1,0x20,3,1,0xb,3,6,4,7); } return uVar4; }
3,518
my_strnxfrm_tis620
eloqsql/strings/ctype-tis620.c
static size_t my_strnxfrm_tis620(CHARSET_INFO *cs, uchar *dst, size_t dstlen, uint nweights, const uchar *src, size_t srclen, uint flags) { size_t len, dstlen0= dstlen; len= MY_MIN(dstlen, srclen); memcpy(dst, src, len); len= thai2sortable(dst, len); set_if_smaller(dstlen, nweights); set_if_smaller(len, dstlen); len= my_strxfrm_pad_desc_and_reverse(cs, dst, dst + len, dst + dstlen, (uint)(dstlen - len), flags, 0); if ((flags & MY_STRXFRM_PAD_TO_MAXLEN) && len < dstlen0) { size_t fill_length= dstlen0 - len; my_ci_fill(cs, (char*) dst + len, fill_length, cs->pad_char); len= dstlen0; } return len; }
O3
c
my_strnxfrm_tis620: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %r9, %r13 movl %ecx, %r12d movq %rdx, %rbx movq %rsi, %r14 movq %rdi, %r15 cmpq %r9, %rdx cmovbq %rdx, %r13 movq %rsi, %rdi movq %r8, %rsi movq %r13, %rdx callq 0x2a250 movq %r14, %rdi movq %r13, %rsi callq 0x3950b movl %r12d, %r8d cmpq %rbx, %r8 cmovaeq %rbx, %r8 cmpq %r8, %r13 cmovaeq %r8, %r13 leaq (%r14,%r13), %rdx leaq (%r14,%r8), %rcx subl %r13d, %r8d movl $0x0, (%rsp) movq %r15, %rdi movq %r14, %rsi movl 0x10(%rbp), %r12d movl %r12d, %r9d callq 0x36274 testb %r12b, %r12b jns 0x394fc movq %rbx, %rdx subq %rax, %rdx jbe 0x394fc addq %rax, %r14 movzbl 0xb0(%r15), %ecx movq 0xb8(%r15), %rax movq %r15, %rdi movq %r14, %rsi callq *0x78(%rax) movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_strnxfrm_tis620: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r13, r9 mov r12d, ecx mov rbx, rdx mov r14, rsi mov r15, rdi cmp rdx, r9 cmovb r13, rdx mov rdi, rsi mov rsi, r8 mov rdx, r13 call _memcpy mov rdi, r14 mov rsi, r13 call thai2sortable mov r8d, r12d cmp r8, rbx cmovnb r8, rbx cmp r13, r8 cmovnb r13, r8 lea rdx, [r14+r13] lea rcx, [r14+r8] sub r8d, r13d mov [rsp+30h+var_30], 0 mov rdi, r15 mov rsi, r14 mov r12d, [rbp+arg_0] mov r9d, r12d call my_strxfrm_pad_desc_and_reverse test r12b, r12b jns short loc_394FC mov rdx, rbx sub rdx, rax jbe short loc_394FC add r14, rax movzx ecx, byte ptr [r15+0B0h] mov rax, [r15+0B8h] mov rdi, r15 mov rsi, r14 call qword ptr [rax+78h] mov rax, rbx loc_394FC: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
unsigned long long my_strnxfrm_tis620( long long a1, long long a2, unsigned long long a3, unsigned int a4, long long a5, unsigned long long a6, unsigned int a7) { unsigned long long v7; // r13 unsigned long long v10; // r8 unsigned long long result; // rax v7 = a6; if ( a3 < a6 ) v7 = a3; memcpy(a2, a5, v7); thai2sortable(a2, v7); v10 = a4; if ( a4 >= a3 ) v10 = a3; if ( v7 >= v10 ) v7 = v10; result = my_strxfrm_pad_desc_and_reverse(a1, a2, a2 + v7, a2 + v10, (int)v10 - (int)v7, a7, 0); if ( (a7 & 0x80u) != 0 && a3 > result ) { (*(void ( **)(long long, unsigned long long, unsigned long long, _QWORD))(*(_QWORD *)(a1 + 184) + 120LL))( a1, result + a2, a3 - result, *(unsigned __int8 *)(a1 + 176)); return a3; } return result; }
my_strnxfrm_tis620: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R13,R9 MOV R12D,ECX MOV RBX,RDX MOV R14,RSI MOV R15,RDI CMP RDX,R9 CMOVC R13,RDX MOV RDI,RSI MOV RSI,R8 MOV RDX,R13 CALL 0x0012a250 MOV RDI,R14 MOV RSI,R13 CALL 0x0013950b MOV R8D,R12D CMP R8,RBX CMOVNC R8,RBX CMP R13,R8 CMOVNC R13,R8 LEA RDX,[R14 + R13*0x1] LEA RCX,[R14 + R8*0x1] SUB R8D,R13D MOV dword ptr [RSP],0x0 MOV RDI,R15 MOV RSI,R14 MOV R12D,dword ptr [RBP + 0x10] MOV R9D,R12D CALL 0x00136274 TEST R12B,R12B JNS 0x001394fc MOV RDX,RBX SUB RDX,RAX JBE 0x001394fc ADD R14,RAX MOVZX ECX,byte ptr [R15 + 0xb0] MOV RAX,qword ptr [R15 + 0xb8] MOV RDI,R15 MOV RSI,R14 CALL qword ptr [RAX + 0x78] MOV RAX,RBX LAB_001394fc: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
ulong my_strnxfrm_tis620(long param_1,void *param_2,ulong param_3,uint param_4,void *param_5, ulong param_6,int4 param_7) { int8 in_RAX; ulong uVar1; uint uVar2; uVar2 = (uint)((ulong)in_RAX >> 0x20); if (param_3 < param_6) { param_6 = param_3; } memcpy(param_2,param_5,param_6); thai2sortable(param_2,param_6); uVar1 = (ulong)param_4; if (param_3 <= param_4) { uVar1 = param_3; } if (uVar1 <= param_6) { param_6 = uVar1; } uVar1 = my_strxfrm_pad_desc_and_reverse (param_1,param_2,(long)param_2 + param_6,(long)param_2 + uVar1, (int)uVar1 - (int)param_6,param_7,(ulong)uVar2 << 0x20); if (((char)param_7 < '\0') && (uVar1 <= param_3 && param_3 - uVar1 != 0)) { (**(code **)(*(long *)(param_1 + 0xb8) + 0x78)) (param_1,(long)param_2 + uVar1,param_3 - uVar1,*(int1 *)(param_1 + 0xb0)); uVar1 = param_3; } return uVar1; }
3,519
ha_find_null
eloqsql/mysys/my_compare.c
HA_KEYSEG *ha_find_null(HA_KEYSEG *keyseg, const uchar *a) { for (; (enum ha_base_keytype) keyseg->type != HA_KEYTYPE_END; keyseg++) { const uchar *end; if (keyseg->null_bit) { if (!*a++) return keyseg; } end= a+ keyseg->length; switch ((enum ha_base_keytype) keyseg->type) { case HA_KEYTYPE_TEXT: case HA_KEYTYPE_BINARY: case HA_KEYTYPE_BIT: if (keyseg->flag & HA_SPACE_PACK) { int a_length; get_key_length(a_length, a); a += a_length; break; } else a= end; break; case HA_KEYTYPE_VARTEXT1: case HA_KEYTYPE_VARTEXT2: case HA_KEYTYPE_VARBINARY1: case HA_KEYTYPE_VARBINARY2: { int a_length; get_key_length(a_length, a); a+= a_length; break; } case HA_KEYTYPE_NUM: if (keyseg->flag & HA_SPACE_PACK) { int alength= *a++; end= a+alength; } a= end; break; case HA_KEYTYPE_INT8: case HA_KEYTYPE_SHORT_INT: case HA_KEYTYPE_USHORT_INT: case HA_KEYTYPE_LONG_INT: case HA_KEYTYPE_ULONG_INT: case HA_KEYTYPE_INT24: case HA_KEYTYPE_UINT24: #ifdef HAVE_LONG_LONG case HA_KEYTYPE_LONGLONG: case HA_KEYTYPE_ULONGLONG: #endif case HA_KEYTYPE_FLOAT: case HA_KEYTYPE_DOUBLE: a= end; break; case HA_KEYTYPE_END: /* purecov: inspected */ /* keep compiler happy */ DBUG_ASSERT(0); break; } } return keyseg; }
O0
c
ha_find_null: pushq %rbp movq %rsp, %rbp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x10(%rbp), %rax movzbl 0x18(%rax), %eax cmpl $0x0, %eax je 0xf2702 movq -0x10(%rbp), %rax cmpb $0x0, 0x19(%rax) je 0xf257a movq -0x18(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x18(%rbp) cmpb $0x0, (%rax) jne 0xf2578 movq -0x10(%rbp), %rax movq %rax, -0x8(%rbp) jmp 0xf270a jmp 0xf257a movq -0x18(%rbp), %rax movq -0x10(%rbp), %rcx movzwl 0x14(%rcx), %ecx addq %rcx, %rax movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rax movzbl 0x18(%rax), %eax movq %rax, -0x38(%rbp) subq $0x13, %rax ja 0xf26ef movq -0x38(%rbp), %rax leaq 0x67282(%rip), %rcx # 0x159830 movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax movq -0x10(%rbp), %rax movzwl 0x12(%rax), %eax andl $0x1, %eax cmpl $0x0, %eax je 0xf262f movq -0x18(%rbp), %rax movzbl (%rax), %eax cmpl $0xff, %eax je 0xf25ec movq -0x18(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x18(%rbp) movzbl (%rax), %eax movl %eax, -0x24(%rbp) jmp 0xf2619 movq -0x18(%rbp), %rax movzbl 0x2(%rax), %eax movzwl %ax, %eax movq -0x18(%rbp), %rcx movzbl 0x1(%rcx), %ecx movzwl %cx, %ecx shll $0x8, %ecx orl %ecx, %eax movzwl %ax, %eax movl %eax, -0x24(%rbp) movq -0x18(%rbp), %rax addq $0x3, %rax movq %rax, -0x18(%rbp) movl -0x24(%rbp), %ecx movq -0x18(%rbp), %rax movslq %ecx, %rcx addq %rcx, %rax movq %rax, -0x18(%rbp) jmp 0xf26ef movq -0x20(%rbp), %rax movq %rax, -0x18(%rbp) jmp 0xf26ef movq -0x18(%rbp), %rax movzbl (%rax), %eax cmpl $0xff, %eax je 0xf2661 movq -0x18(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x18(%rbp) movzbl (%rax), %eax movl %eax, -0x28(%rbp) jmp 0xf268e movq -0x18(%rbp), %rax movzbl 0x2(%rax), %eax movzwl %ax, %eax movq -0x18(%rbp), %rcx movzbl 0x1(%rcx), %ecx movzwl %cx, %ecx shll $0x8, %ecx orl %ecx, %eax movzwl %ax, %eax movl %eax, -0x28(%rbp) movq -0x18(%rbp), %rax addq $0x3, %rax movq %rax, -0x18(%rbp) movl -0x28(%rbp), %ecx movq -0x18(%rbp), %rax movslq %ecx, %rcx addq %rcx, %rax movq %rax, -0x18(%rbp) jmp 0xf26ef movq -0x10(%rbp), %rax movzwl 0x12(%rax), %eax andl $0x1, %eax cmpl $0x0, %eax je 0xf26d5 movq -0x18(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x18(%rbp) movzbl (%rax), %eax movl %eax, -0x2c(%rbp) movq -0x18(%rbp), %rax movslq -0x2c(%rbp), %rcx addq %rcx, %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rax movq %rax, -0x18(%rbp) jmp 0xf26ef movq -0x20(%rbp), %rax movq %rax, -0x18(%rbp) jmp 0xf26ef jmp 0xf26eb jmp 0xf26ed jmp 0xf26ef jmp 0xf26f1 movq -0x10(%rbp), %rax addq $0x20, %rax movq %rax, -0x10(%rbp) jmp 0xf253c movq -0x10(%rbp), %rax movq %rax, -0x8(%rbp) movq -0x8(%rbp), %rax popq %rbp retq
ha_find_null: push rbp mov rbp, rsp mov [rbp+var_10], rdi mov [rbp+var_18], rsi loc_F253C: mov rax, [rbp+var_10] movzx eax, byte ptr [rax+18h] cmp eax, 0 jz loc_F2702 mov rax, [rbp+var_10] cmp byte ptr [rax+19h], 0 jz short loc_F257A mov rax, [rbp+var_18] mov rcx, rax add rcx, 1 mov [rbp+var_18], rcx cmp byte ptr [rax], 0 jnz short loc_F2578 mov rax, [rbp+var_10] mov [rbp+var_8], rax jmp loc_F270A loc_F2578: jmp short $+2 loc_F257A: mov rax, [rbp+var_18] mov rcx, [rbp+var_10] movzx ecx, word ptr [rcx+14h] add rax, rcx mov [rbp+var_20], rax mov rax, [rbp+var_10] movzx eax, byte ptr [rax+18h] mov [rbp+var_38], rax sub rax, 13h; switch 20 cases ja def_F25B5; jumptable 00000000000F25B5 default case mov rax, [rbp+var_38] lea rcx, jpt_F25B5 movsxd rax, ds:(jpt_F25B5 - 159830h)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_F25B7: mov rax, [rbp+var_10]; jumptable 00000000000F25B5 cases 1,2,19 movzx eax, word ptr [rax+12h] and eax, 1 cmp eax, 0 jz short loc_F262F mov rax, [rbp+var_18] movzx eax, byte ptr [rax] cmp eax, 0FFh jz short loc_F25EC mov rax, [rbp+var_18] mov rcx, rax add rcx, 1 mov [rbp+var_18], rcx movzx eax, byte ptr [rax] mov [rbp+var_24], eax jmp short loc_F2619 loc_F25EC: mov rax, [rbp+var_18] movzx eax, byte ptr [rax+2] movzx eax, ax mov rcx, [rbp+var_18] movzx ecx, byte ptr [rcx+1] movzx ecx, cx shl ecx, 8 or eax, ecx movzx eax, ax mov [rbp+var_24], eax mov rax, [rbp+var_18] add rax, 3 mov [rbp+var_18], rax loc_F2619: mov ecx, [rbp+var_24] mov rax, [rbp+var_18] movsxd rcx, ecx add rax, rcx mov [rbp+var_18], rax jmp def_F25B5; jumptable 00000000000F25B5 default case loc_F262F: mov rax, [rbp+var_20] mov [rbp+var_18], rax jmp def_F25B5; jumptable 00000000000F25B5 default case loc_F263C: mov rax, [rbp+var_18]; jumptable 00000000000F25B5 cases 15-18 movzx eax, byte ptr [rax] cmp eax, 0FFh jz short loc_F2661 mov rax, [rbp+var_18] mov rcx, rax add rcx, 1 mov [rbp+var_18], rcx movzx eax, byte ptr [rax] mov [rbp+var_28], eax jmp short loc_F268E loc_F2661: mov rax, [rbp+var_18] movzx eax, byte ptr [rax+2] movzx eax, ax mov rcx, [rbp+var_18] movzx ecx, byte ptr [rcx+1] movzx ecx, cx shl ecx, 8 or eax, ecx movzx eax, ax mov [rbp+var_28], eax mov rax, [rbp+var_18] add rax, 3 mov [rbp+var_18], rax loc_F268E: mov ecx, [rbp+var_28] mov rax, [rbp+var_18] movsxd rcx, ecx add rax, rcx mov [rbp+var_18], rax jmp short def_F25B5; jumptable 00000000000F25B5 default case loc_F26A1: mov rax, [rbp+var_10]; jumptable 00000000000F25B5 case 7 movzx eax, word ptr [rax+12h] and eax, 1 cmp eax, 0 jz short loc_F26D5 mov rax, [rbp+var_18] mov rcx, rax add rcx, 1 mov [rbp+var_18], rcx movzx eax, byte ptr [rax] mov [rbp+var_2C], eax mov rax, [rbp+var_18] movsxd rcx, [rbp+var_2C] add rax, rcx mov [rbp+var_20], rax loc_F26D5: mov rax, [rbp+var_20] mov [rbp+var_18], rax jmp short def_F25B5; jumptable 00000000000F25B5 default case loc_F26DF: mov rax, [rbp+var_20]; jumptable 00000000000F25B5 cases 3-6,8-14 mov [rbp+var_18], rax jmp short def_F25B5; jumptable 00000000000F25B5 default case loc_F26E9: jmp short $+2; jumptable 00000000000F25B5 case 0 loc_F26EB: jmp short $+2 loc_F26ED: jmp short $+2; jumptable 00000000000F25B5 default case def_F25B5: jmp short $+2; jumptable 00000000000F25B5 default case loc_F26F1: mov rax, [rbp+var_10] add rax, 20h ; ' ' mov [rbp+var_10], rax jmp loc_F253C loc_F2702: mov rax, [rbp+var_10] mov [rbp+var_8], rax loc_F270A: mov rax, [rbp+var_8] pop rbp retn
long long ha_find_null(long long a1, unsigned __int8 *a2) { unsigned __int8 *v2; // rax unsigned __int8 *v3; // rax unsigned __int8 *v4; // rax int v6; // [rsp+10h] [rbp-28h] int v7; // [rsp+14h] [rbp-24h] long long v8; // [rsp+18h] [rbp-20h] unsigned __int8 *v10; // [rsp+20h] [rbp-18h] unsigned __int8 *v11; // [rsp+20h] [rbp-18h] while ( *(_BYTE *)(a1 + 24) ) { if ( *(_BYTE *)(a1 + 25) ) { v2 = a2++; if ( !*v2 ) return a1; } v8 = (long long)&a2[*(unsigned __int16 *)(a1 + 20)]; switch ( *(_BYTE *)(a1 + 24) ) { case 1: case 2: case 0x13: if ( (*(_WORD *)(a1 + 18) & 1) != 0 ) { if ( *a2 == 255 ) { v7 = _byteswap_ushort(*(_WORD *)(a2 + 1)); v10 = a2 + 3; } else { v3 = a2; v10 = a2 + 1; v7 = *v3; } a2 = &v10[v7]; } else { a2 += *(unsigned __int16 *)(a1 + 20); } break; case 3: case 4: case 5: case 6: case 8: case 9: case 0xA: case 0xB: case 0xC: case 0xD: case 0xE: a2 += *(unsigned __int16 *)(a1 + 20); break; case 7: if ( (*(_WORD *)(a1 + 18) & 1) != 0 ) v8 = (long long)&a2[*a2 + 1]; a2 = (unsigned __int8 *)v8; break; case 0xF: case 0x10: case 0x11: case 0x12: if ( *a2 == 255 ) { v6 = _byteswap_ushort(*(_WORD *)(a2 + 1)); v11 = a2 + 3; } else { v4 = a2; v11 = a2 + 1; v6 = *v4; } a2 = &v11[v6]; break; default: break; } a1 += 32LL; } return a1; }
ha_find_null: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI LAB_001f253c: MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x18] CMP EAX,0x0 JZ 0x001f2702 MOV RAX,qword ptr [RBP + -0x10] CMP byte ptr [RAX + 0x19],0x0 JZ 0x001f257a MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x18],RCX CMP byte ptr [RAX],0x0 JNZ 0x001f2578 MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x8],RAX JMP 0x001f270a LAB_001f2578: JMP 0x001f257a LAB_001f257a: MOV RAX,qword ptr [RBP + -0x18] MOV RCX,qword ptr [RBP + -0x10] MOVZX ECX,word ptr [RCX + 0x14] ADD RAX,RCX MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0x18] MOV qword ptr [RBP + -0x38],RAX SUB RAX,0x13 JA 0x001f26ef MOV RAX,qword ptr [RBP + -0x38] LEA RCX,[0x259830] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_1: MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,word ptr [RAX + 0x12] AND EAX,0x1 CMP EAX,0x0 JZ 0x001f262f MOV RAX,qword ptr [RBP + -0x18] MOVZX EAX,byte ptr [RAX] CMP EAX,0xff JZ 0x001f25ec MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x18],RCX MOVZX EAX,byte ptr [RAX] MOV dword ptr [RBP + -0x24],EAX JMP 0x001f2619 LAB_001f25ec: MOV RAX,qword ptr [RBP + -0x18] MOVZX EAX,byte ptr [RAX + 0x2] MOVZX EAX,AX MOV RCX,qword ptr [RBP + -0x18] MOVZX ECX,byte ptr [RCX + 0x1] MOVZX ECX,CX SHL ECX,0x8 OR EAX,ECX MOVZX EAX,AX MOV dword ptr [RBP + -0x24],EAX MOV RAX,qword ptr [RBP + -0x18] ADD RAX,0x3 MOV qword ptr [RBP + -0x18],RAX LAB_001f2619: MOV ECX,dword ptr [RBP + -0x24] MOV RAX,qword ptr [RBP + -0x18] MOVSXD RCX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x18],RAX JMP 0x001f26ef LAB_001f262f: MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x18],RAX JMP 0x001f26ef caseD_f: MOV RAX,qword ptr [RBP + -0x18] MOVZX EAX,byte ptr [RAX] CMP EAX,0xff JZ 0x001f2661 MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x18],RCX MOVZX EAX,byte ptr [RAX] MOV dword ptr [RBP + -0x28],EAX JMP 0x001f268e LAB_001f2661: MOV RAX,qword ptr [RBP + -0x18] MOVZX EAX,byte ptr [RAX + 0x2] MOVZX EAX,AX MOV RCX,qword ptr [RBP + -0x18] MOVZX ECX,byte ptr [RCX + 0x1] MOVZX ECX,CX SHL ECX,0x8 OR EAX,ECX MOVZX EAX,AX MOV dword ptr [RBP + -0x28],EAX MOV RAX,qword ptr [RBP + -0x18] ADD RAX,0x3 MOV qword ptr [RBP + -0x18],RAX LAB_001f268e: MOV ECX,dword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x18] MOVSXD RCX,ECX ADD RAX,RCX MOV qword ptr [RBP + -0x18],RAX JMP 0x001f26ef caseD_7: MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,word ptr [RAX + 0x12] AND EAX,0x1 CMP EAX,0x0 JZ 0x001f26d5 MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x18],RCX MOVZX EAX,byte ptr [RAX] MOV dword ptr [RBP + -0x2c],EAX MOV RAX,qword ptr [RBP + -0x18] MOVSXD RCX,dword ptr [RBP + -0x2c] ADD RAX,RCX MOV qword ptr [RBP + -0x20],RAX LAB_001f26d5: MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x18],RAX JMP 0x001f26ef caseD_3: MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x18],RAX JMP 0x001f26ef caseD_0: JMP 0x001f26eb LAB_001f26eb: JMP 0x001f26ed LAB_001f26ed: JMP 0x001f26ef default: JMP 0x001f26f1 LAB_001f26f1: MOV RAX,qword ptr [RBP + -0x10] ADD RAX,0x20 MOV qword ptr [RBP + -0x10],RAX JMP 0x001f253c LAB_001f2702: MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x8],RAX LAB_001f270a: MOV RAX,qword ptr [RBP + -0x8] POP RBP RET
long ha_find_null(long param_1,byte *param_2) { byte bVar1; byte *pbVar2; uint local_30; uint local_2c; byte *local_28; byte *local_20; long local_18; local_20 = param_2; local_18 = param_1; while ((*(char *)(local_18 + 0x18) != '\0' && ((*(char *)(local_18 + 0x19) == '\0' || (bVar1 = *local_20, local_20 = local_20 + 1, bVar1 != 0))))) { local_28 = local_20 + *(ushort *)(local_18 + 0x14); pbVar2 = local_20; switch(*(int1 *)(local_18 + 0x18)) { case 0: break; case 1: case 2: case 0x13: pbVar2 = local_28; if ((*(ushort *)(local_18 + 0x12) & 1) != 0) { if (*local_20 == 0xff) { local_2c = (uint)CONCAT11(local_20[1],local_20[2]); local_20 = local_20 + 3; } else { local_2c = (uint)*local_20; local_20 = local_20 + 1; } pbVar2 = local_20 + (int)local_2c; } break; case 3: case 4: case 5: case 6: case 8: case 9: case 10: case 0xb: case 0xc: case 0xd: case 0xe: pbVar2 = local_28; break; case 7: if ((*(ushort *)(local_18 + 0x12) & 1) != 0) { local_28 = local_20 + (long)(int)(uint)*local_20 + 1; } local_20 = local_28; pbVar2 = local_20; break; case 0xf: case 0x10: case 0x11: case 0x12: if (*local_20 == 0xff) { local_30 = (uint)CONCAT11(local_20[1],local_20[2]); local_20 = local_20 + 3; } else { local_30 = (uint)*local_20; local_20 = local_20 + 1; } pbVar2 = local_20 + (int)local_30; } local_20 = pbVar2; local_18 = local_18 + 0x20; } return local_18; }
3,520
ha_find_null
eloqsql/mysys/my_compare.c
HA_KEYSEG *ha_find_null(HA_KEYSEG *keyseg, const uchar *a) { for (; (enum ha_base_keytype) keyseg->type != HA_KEYTYPE_END; keyseg++) { const uchar *end; if (keyseg->null_bit) { if (!*a++) return keyseg; } end= a+ keyseg->length; switch ((enum ha_base_keytype) keyseg->type) { case HA_KEYTYPE_TEXT: case HA_KEYTYPE_BINARY: case HA_KEYTYPE_BIT: if (keyseg->flag & HA_SPACE_PACK) { int a_length; get_key_length(a_length, a); a += a_length; break; } else a= end; break; case HA_KEYTYPE_VARTEXT1: case HA_KEYTYPE_VARTEXT2: case HA_KEYTYPE_VARBINARY1: case HA_KEYTYPE_VARBINARY2: { int a_length; get_key_length(a_length, a); a+= a_length; break; } case HA_KEYTYPE_NUM: if (keyseg->flag & HA_SPACE_PACK) { int alength= *a++; end= a+alength; } a= end; break; case HA_KEYTYPE_INT8: case HA_KEYTYPE_SHORT_INT: case HA_KEYTYPE_USHORT_INT: case HA_KEYTYPE_LONG_INT: case HA_KEYTYPE_ULONG_INT: case HA_KEYTYPE_INT24: case HA_KEYTYPE_UINT24: #ifdef HAVE_LONG_LONG case HA_KEYTYPE_LONGLONG: case HA_KEYTYPE_ULONGLONG: #endif case HA_KEYTYPE_FLOAT: case HA_KEYTYPE_DOUBLE: a= end; break; case HA_KEYTYPE_END: /* purecov: inspected */ /* keep compiler happy */ DBUG_ASSERT(0); break; } } return keyseg; }
O3
c
ha_find_null: movq %rdi, %rax movb 0x18(%rdi), %dl testb %dl, %dl je 0x9f317 pushq %rbp movq %rsp, %rbp leaq 0x42b62(%rip), %rcx # 0xe1dfc cmpb $0x0, 0x19(%rax) je 0x9f2a8 cmpb $0x0, (%rsi) je 0x9f316 incq %rsi movzbl %dl, %edx decl %edx cmpl $0x12, %edx ja 0x9f2f1 movzwl 0x14(%rax), %edi addq %rsi, %rdi movslq (%rcx,%rdx,4), %rdx addq %rcx, %rdx jmpq *%rdx testb $0x1, 0x12(%rax) je 0x9f2f4 movzbl (%rsi), %edx cmpq $0xff, %rdx je 0x9f2db movl $0x1, %edi jmp 0x9f2eb movzwl 0x1(%rsi), %edx rolw $0x8, %dx movzwl %dx, %edx movl $0x3, %edi addq %rdi, %rsi addq %rdx, %rsi movq %rsi, %rdi movb 0x38(%rax), %dl addq $0x20, %rax movq %rdi, %rsi testb %dl, %dl jne 0x9f29a jmp 0x9f316 testb $0x1, 0x12(%rax) je 0x9f2f4 movzbl (%rsi), %edx leaq (%rsi,%rdx), %rdi incq %rdi jmp 0x9f2f4 popq %rbp retq
ha_find_null: mov rax, rdi mov dl, [rdi+18h] test dl, dl jz locret_9F317 push rbp mov rbp, rsp lea rcx, jpt_9F2C0 loc_9F29A: cmp byte ptr [rax+19h], 0 jz short loc_9F2A8 cmp byte ptr [rsi], 0 jz short loc_9F316 inc rsi loc_9F2A8: movzx edx, dl dec edx; switch 19 cases cmp edx, 12h ja short def_9F2C0; jumptable 000000000009F2C0 default case movzx edi, word ptr [rax+14h] add rdi, rsi movsxd rdx, ds:(jpt_9F2C0 - 0E1DFCh)[rcx+rdx*4] add rdx, rcx jmp rdx; switch jump loc_9F2C2: test byte ptr [rax+12h], 1; jumptable 000000000009F2C0 cases 1,2,19 jz short loc_9F2F4; jumptable 000000000009F2C0 cases 3-6,8-14 loc_9F2C8: movzx edx, byte ptr [rsi]; jumptable 000000000009F2C0 cases 15-18 cmp rdx, 0FFh jz short loc_9F2DB mov edi, 1 jmp short loc_9F2EB loc_9F2DB: movzx edx, word ptr [rsi+1] rol dx, 8 movzx edx, dx mov edi, 3 loc_9F2EB: add rsi, rdi add rsi, rdx def_9F2C0: mov rdi, rsi; jumptable 000000000009F2C0 default case loc_9F2F4: mov dl, [rax+38h]; jumptable 000000000009F2C0 cases 3-6,8-14 add rax, 20h ; ' ' mov rsi, rdi test dl, dl jnz short loc_9F29A jmp short loc_9F316 loc_9F304: test byte ptr [rax+12h], 1; jumptable 000000000009F2C0 case 7 jz short loc_9F2F4; jumptable 000000000009F2C0 cases 3-6,8-14 movzx edx, byte ptr [rsi] lea rdi, [rsi+rdx] inc rdi jmp short loc_9F2F4; jumptable 000000000009F2C0 cases 3-6,8-14 loc_9F316: pop rbp locret_9F317: retn
long long ha_find_null(long long a1, unsigned __int8 *a2) { long long result; // rax char i; // dl long long v4; // rdi long long v5; // rdx long long v6; // rdi result = a1; for ( i = *(_BYTE *)(a1 + 24); i; a2 = (unsigned __int8 *)v4 ) { if ( *(_BYTE *)(result + 25) ) { if ( !*a2 ) return result; ++a2; } v4 = (long long)&a2[*(unsigned __int16 *)(result + 20)]; switch ( i ) { case 1: case 2: case 19: if ( (*(_BYTE *)(result + 18) & 1) != 0 ) goto LABEL_7; break; case 3: case 4: case 5: case 6: case 8: case 9: case 10: case 11: case 12: case 13: case 14: break; case 7: if ( (*(_BYTE *)(result + 18) & 1) != 0 ) v4 = (long long)&a2[*a2 + 1]; break; case 15: case 16: case 17: case 18: LABEL_7: v5 = *a2; if ( v5 == 255 ) { v5 = (unsigned __int16)__ROL2__(*(_WORD *)(a2 + 1), 8); v6 = 3LL; } else { v6 = 1LL; } a2 += v5 + v6; goto LABEL_11; default: LABEL_11: v4 = (long long)a2; break; } i = *(_BYTE *)(result + 56); result += 32LL; } return result; }
ha_find_null: MOV RAX,RDI MOV DL,byte ptr [RDI + 0x18] TEST DL,DL JZ 0x0019f317 PUSH RBP MOV RBP,RSP LEA RCX,[0x1e1dfc] LAB_0019f29a: CMP byte ptr [RAX + 0x19],0x0 JZ 0x0019f2a8 CMP byte ptr [RSI],0x0 JZ 0x0019f316 INC RSI LAB_0019f2a8: MOVZX EDX,DL DEC EDX CMP EDX,0x12 JA 0x0019f2f1 MOVZX EDI,word ptr [RAX + 0x14] ADD RDI,RSI MOVSXD RDX,dword ptr [RCX + RDX*0x4] ADD RDX,RCX switchD: JMP RDX caseD_1: TEST byte ptr [RAX + 0x12],0x1 JZ 0x0019f2f4 caseD_f: MOVZX EDX,byte ptr [RSI] CMP RDX,0xff JZ 0x0019f2db MOV EDI,0x1 JMP 0x0019f2eb LAB_0019f2db: MOVZX EDX,word ptr [RSI + 0x1] ROL DX,0x8 MOVZX EDX,DX MOV EDI,0x3 LAB_0019f2eb: ADD RSI,RDI ADD RSI,RDX LAB_0019f2f1: MOV RDI,RSI caseD_3: MOV DL,byte ptr [RAX + 0x38] ADD RAX,0x20 MOV RSI,RDI TEST DL,DL JNZ 0x0019f29a JMP 0x0019f316 caseD_7: TEST byte ptr [RAX + 0x12],0x1 JZ 0x0019f2f4 MOVZX EDX,byte ptr [RSI] LEA RDI,[RSI + RDX*0x1] INC RDI JMP 0x0019f2f4 LAB_0019f316: POP RBP LAB_0019f317: RET
void ha_find_null(long param_1,byte *param_2) { byte bVar1; ulong uVar2; byte *pbVar3; long lVar4; bVar1 = *(byte *)(param_1 + 0x18); do { if (bVar1 == 0) { return; } if (*(char *)(param_1 + 0x19) != '\0') { if (*param_2 == 0) { return; } param_2 = param_2 + 1; } pbVar3 = param_2; if (bVar1 - 1 < 0x13) { pbVar3 = param_2 + *(ushort *)(param_1 + 0x14); switch((uint)bVar1) { case 1: case 2: case 0x13: if ((*(byte *)(param_1 + 0x12) & 1) != 0) goto switchD_0019f2c0_caseD_f; break; case 7: if ((*(byte *)(param_1 + 0x12) & 1) != 0) { pbVar3 = param_2 + (ulong)*param_2 + 1; } break; case 0xf: case 0x10: case 0x11: case 0x12: switchD_0019f2c0_caseD_f: uVar2 = (ulong)*param_2; if (uVar2 == 0xff) { uVar2 = (ulong)(ushort)(*(ushort *)(param_2 + 1) << 8 | *(ushort *)(param_2 + 1) >> 8); lVar4 = 3; } else { lVar4 = 1; } pbVar3 = param_2 + uVar2 + lVar4; } } bVar1 = *(byte *)(param_1 + 0x38); param_1 = param_1 + 0x20; param_2 = pbVar3; } while( true ); }
3,521
google::protobuf::compiler::java::MessageGenerator::MessageGenerator(google::protobuf::Descriptor const*)
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/compiler/java/message.cc
MessageGenerator::MessageGenerator(const Descriptor* descriptor) : descriptor_(descriptor) { for (int i = 0; i < descriptor_->field_count(); i++) { if (IsRealOneof(descriptor_->field(i))) { oneofs_.insert(descriptor_->field(i)->containing_oneof()); } } }
O3
cpp
google::protobuf::compiler::java::MessageGenerator::MessageGenerator(google::protobuf::Descriptor const*): pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x10, %rsp leaq 0x1cf57c(%rip), %rax # 0x278978 movq %rax, (%rdi) movq %rsi, 0x8(%rdi) leaq 0x18(%rdi), %rax movl $0x0, 0x18(%rdi) xorl %ecx, %ecx movq %rcx, 0x20(%rdi) movq %rax, 0x28(%rdi) movq %rax, 0x30(%rdi) movq %rcx, 0x38(%rdi) cmpl $0x0, 0x4(%rsi) jle 0xa948a movq %rdi, %rbx leaq 0x10(%rdi), %r14 movl $0x28, %r12d xorl %r13d, %r13d leaq 0x8(%rsp), %r15 movq 0x28(%rsi), %rax testb $0x10, -0x27(%rax,%r12) sete %cl movq (%rax,%r12), %rax testq %rax, %rax sete %dl orb %cl, %dl jne 0xa947a cmpl $0x1, 0x4(%rax) jne 0xa9466 movq 0x20(%rax), %rcx testb $0x2, 0x1(%rcx) jne 0xa947a movq %rax, 0x8(%rsp) movq %r14, %rdi movq %r15, %rsi callq 0xaf242 movq 0x8(%rbx), %rsi incq %r13 movslq 0x4(%rsi), %rax addq $0x48, %r12 cmpq %rax, %r13 jl 0xa943b addq $0x10, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq movq %rax, %rbx movq %r14, %rdi callq 0xaf1f8 movq %rbx, %rdi callq 0x1f860 nop
_ZN6google8protobuf8compiler4java16MessageGeneratorC2EPKNS0_10DescriptorE: push r15 push r14 push r13 push r12 push rbx sub rsp, 10h lea rax, off_278978 mov [rdi], rax mov [rdi+8], rsi lea rax, [rdi+18h] mov dword ptr [rdi+18h], 0 xor ecx, ecx mov [rdi+20h], rcx mov [rdi+28h], rax mov [rdi+30h], rax mov [rdi+38h], rcx cmp dword ptr [rsi+4], 0 jle short loc_A948A mov rbx, rdi lea r14, [rdi+10h] mov r12d, 28h ; '(' xor r13d, r13d lea r15, [rsp+38h+var_30] loc_A943B: mov rax, [rsi+28h] test byte ptr [rax+r12-27h], 10h setz cl mov rax, [rax+r12] test rax, rax setz dl or dl, cl jnz short loc_A947A cmp dword ptr [rax+4], 1 jnz short loc_A9466 mov rcx, [rax+20h] test byte ptr [rcx+1], 2 jnz short loc_A947A loc_A9466: mov [rsp+38h+var_30], rax mov rdi, r14 mov rsi, r15 call _ZNSt8_Rb_treeIPKN6google8protobuf15OneofDescriptorES4_St9_IdentityIS4_ESt4lessIS4_ESaIS4_EE16_M_insert_uniqueIS4_EESt4pairISt17_Rb_tree_iteratorIS4_EbEOT_; std::_Rb_tree<google::protobuf::OneofDescriptor const*,google::protobuf::OneofDescriptor const*,std::_Identity<google::protobuf::OneofDescriptor const*>,std::less<google::protobuf::OneofDescriptor const*>,std::allocator<google::protobuf::OneofDescriptor const*>>::_M_insert_unique<google::protobuf::OneofDescriptor const*>(google::protobuf::OneofDescriptor const* &&) mov rsi, [rbx+8] loc_A947A: inc r13 movsxd rax, dword ptr [rsi+4] add r12, 48h ; 'H' cmp r13, rax jl short loc_A943B loc_A948A: add rsp, 10h pop rbx pop r12 pop r13 pop r14 pop r15 retn mov rbx, rax mov rdi, r14 call _ZNSt8_Rb_treeIPKN6google8protobuf15OneofDescriptorES4_St9_IdentityIS4_ESt4lessIS4_ESaIS4_EED2Ev; std::_Rb_tree<google::protobuf::OneofDescriptor const*,google::protobuf::OneofDescriptor const*,std::_Identity<google::protobuf::OneofDescriptor const*>,std::less<google::protobuf::OneofDescriptor const*>,std::allocator<google::protobuf::OneofDescriptor const*>>::~_Rb_tree() mov rdi, rbx call __Unwind_Resume
long long google::protobuf::compiler::java::MessageGenerator::MessageGenerator( google::protobuf::compiler::java::MessageGenerator *this, const google::protobuf::Descriptor *a2) { long long result; // rax long long v3; // r12 long long v4; // r13 long long v5; // rax bool v6; // cl long long v7; // rax _QWORD v8[6]; // [rsp+8h] [rbp-30h] BYREF *(_QWORD *)this = &off_278978; *((_QWORD *)this + 1) = a2; result = (long long)this + 24; *((_DWORD *)this + 6) = 0; *((_QWORD *)this + 4) = 0LL; *((_QWORD *)this + 5) = (char *)this + 24; *((_QWORD *)this + 6) = (char *)this + 24; *((_QWORD *)this + 7) = 0LL; if ( *((int *)a2 + 1) > 0 ) { v3 = 40LL; v4 = 0LL; do { v5 = *((_QWORD *)a2 + 5); v6 = (*(_BYTE *)(v5 + v3 - 39) & 0x10) == 0; v7 = *(_QWORD *)(v5 + v3); if ( !v6 && v7 != 0 && (*(_DWORD *)(v7 + 4) != 1 || (*(_BYTE *)(*(_QWORD *)(v7 + 32) + 1LL) & 2) == 0) ) { v8[0] = v7; std::_Rb_tree<google::protobuf::OneofDescriptor const*,google::protobuf::OneofDescriptor const*,std::_Identity<google::protobuf::OneofDescriptor const*>,std::less<google::protobuf::OneofDescriptor const*>,std::allocator<google::protobuf::OneofDescriptor const*>>::_M_insert_unique<google::protobuf::OneofDescriptor const*>( (char *)this + 16, v8); a2 = (const google::protobuf::Descriptor *)*((_QWORD *)this + 1); } ++v4; result = *((int *)a2 + 1); v3 += 72LL; } while ( v4 < result ); } return result; }
MessageGenerator: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x10 LEA RAX,[0x378978] MOV qword ptr [RDI],RAX MOV qword ptr [RDI + 0x8],RSI LEA RAX,[RDI + 0x18] MOV dword ptr [RDI + 0x18],0x0 XOR ECX,ECX MOV qword ptr [RDI + 0x20],RCX MOV qword ptr [RDI + 0x28],RAX MOV qword ptr [RDI + 0x30],RAX MOV qword ptr [RDI + 0x38],RCX CMP dword ptr [RSI + 0x4],0x0 JLE 0x001a948a MOV RBX,RDI LEA R14,[RDI + 0x10] MOV R12D,0x28 XOR R13D,R13D LEA R15,[RSP + 0x8] LAB_001a943b: MOV RAX,qword ptr [RSI + 0x28] TEST byte ptr [RAX + R12*0x1 + -0x27],0x10 SETZ CL MOV RAX,qword ptr [RAX + R12*0x1] TEST RAX,RAX SETZ DL OR DL,CL JNZ 0x001a947a CMP dword ptr [RAX + 0x4],0x1 JNZ 0x001a9466 MOV RCX,qword ptr [RAX + 0x20] TEST byte ptr [RCX + 0x1],0x2 JNZ 0x001a947a LAB_001a9466: MOV qword ptr [RSP + 0x8],RAX LAB_001a946b: MOV RDI,R14 MOV RSI,R15 CALL 0x001af242 LAB_001a9476: MOV RSI,qword ptr [RBX + 0x8] LAB_001a947a: INC R13 MOVSXD RAX,dword ptr [RSI + 0x4] ADD R12,0x48 CMP R13,RAX JL 0x001a943b LAB_001a948a: ADD RSP,0x10 POP RBX POP R12 POP R13 POP R14 POP R15 RET
/* google::protobuf::compiler::java::MessageGenerator::MessageGenerator(google::protobuf::Descriptor const*) */ void __thiscall google::protobuf::compiler::java::MessageGenerator::MessageGenerator (MessageGenerator *this,Descriptor *param_1) { long lVar1; long lVar2; OneofDescriptor *local_30; *(int ***)this = &PTR__MessageGenerator_00378978; *(Descriptor **)(this + 8) = param_1; *(int4 *)(this + 0x18) = 0; *(int8 *)(this + 0x20) = 0; *(MessageGenerator **)(this + 0x28) = this + 0x18; *(MessageGenerator **)(this + 0x30) = this + 0x18; *(int8 *)(this + 0x38) = 0; if (0 < *(int *)(param_1 + 4)) { lVar1 = 0x28; lVar2 = 0; do { local_30 = *(OneofDescriptor **)(*(long *)(param_1 + 0x28) + lVar1); if ((local_30 != (OneofDescriptor *)0x0 && (*(byte *)(*(long *)(param_1 + 0x28) + -0x27 + lVar1) & 0x10) != 0) && ((*(int *)(local_30 + 4) != 1 || ((*(byte *)(*(long *)(local_30 + 0x20) + 1) & 2) == 0)))) { /* try { // try from 001a946b to 001a9475 has its CatchHandler @ 001a9498 */ std:: _Rb_tree<google::protobuf::OneofDescriptor_const*,google::protobuf::OneofDescriptor_const*,std::_Identity<google::protobuf::OneofDescriptor_const*>,std::less<google::protobuf::OneofDescriptor_const*>,std::allocator<google::protobuf::OneofDescriptor_const*>> ::_M_insert_unique<google::protobuf::OneofDescriptor_const*> ((_Rb_tree<google::protobuf::OneofDescriptor_const*,google::protobuf::OneofDescriptor_const*,std::_Identity<google::protobuf::OneofDescriptor_const*>,std::less<google::protobuf::OneofDescriptor_const*>,std::allocator<google::protobuf::OneofDescriptor_const*>> *)(this + 0x10),&local_30); param_1 = *(Descriptor **)(this + 8); } lVar2 = lVar2 + 1; lVar1 = lVar1 + 0x48; } while (lVar2 < *(int *)(param_1 + 4)); } return; }
3,522
nglog::InstallPrefixFormatter(void (*)(std::ostream&, nglog::LogMessage const&, void*), void*)
ng-log[P]ng-log/src/logging.cc
void InstallPrefixFormatter(PrefixFormatterCallback callback, void* data) { if (callback != nullptr) { g_prefix_formatter = std::make_unique<PrefixFormatter>(callback, data); } else { g_prefix_formatter = nullptr; } }
O2
cpp
nglog::InstallPrefixFormatter(void (*)(std::ostream&, nglog::LogMessage const&, void*), void*): testq %rdi, %rdi je 0xc35e pushq %r14 pushq %rbx pushq %rax movq %rsi, %rbx movq %rdi, %r14 pushq $0x18 popq %rdi callq 0x75a0 andl $0x0, (%rax) movq %r14, 0x8(%rax) movq %rbx, 0x10(%rax) movq %rsp, %rbx andq $0x0, (%rbx) movq %rax, %rdi callq 0xdbf2 movq %rbx, %rdi callq 0x8f1a addq $0x8, %rsp popq %rbx popq %r14 retq xorl %edi, %edi jmp 0xdbf2
_ZN5nglog22InstallPrefixFormatterEPFvRSoRKNS_10LogMessageEPvES4_: test rdi, rdi jz short loc_C35E push r14 push rbx push rax mov rbx, rsi mov r14, rdi push 18h pop rdi; unsigned __int64 call __Znwm; operator new(ulong) and dword ptr [rax], 0 mov [rax+8], r14 mov [rax+10h], rbx mov rbx, rsp and qword ptr [rbx], 0 mov rdi, rax call _ZNSt15__uniq_ptr_implIN5nglog12_GLOBAL__N_115PrefixFormatterESt14default_deleteIS2_EE5resetEPS2_; std::__uniq_ptr_impl<nglog::`anonymous namespace'::PrefixFormatter,std::default_delete<nglog::`anonymous namespace'::PrefixFormatter>>::reset(nglog::`anonymous namespace'::PrefixFormatter*) mov rdi, rbx; void * call _ZNSt10unique_ptrIN5nglog12_GLOBAL__N_115PrefixFormatterESt14default_deleteIS2_EED2Ev; std::unique_ptr<nglog::`anonymous namespace'::PrefixFormatter>::~unique_ptr() add rsp, 8 pop rbx pop r14 retn loc_C35E: xor edi, edi jmp _ZNSt15__uniq_ptr_implIN5nglog12_GLOBAL__N_115PrefixFormatterESt14default_deleteIS2_EE5resetEPS2_; std::__uniq_ptr_impl<nglog::`anonymous namespace'::PrefixFormatter,std::default_delete<nglog::`anonymous namespace'::PrefixFormatter>>::reset(nglog::`anonymous namespace'::PrefixFormatter*)
void nglog::InstallPrefixFormatter( nglog *this, void (*a2)(std::ostream *, const nglog::LogMessage *, void *), void *a3) { long long v3; // rax long long v4; // rdx void *v5; // [rsp-18h] [rbp-18h] BYREF if ( this ) { v3 = operator new(0x18uLL); *(_DWORD *)v3 = 0; *(_QWORD *)(v3 + 8) = this; *(_QWORD *)(v3 + 16) = a2; v5 = 0LL; std::__uniq_ptr_impl<nglog::`anonymous namespace'::PrefixFormatter,std::default_delete<nglog::`anonymous namespace'::PrefixFormatter>>::reset( v3, a2, v4); std::unique_ptr<nglog::`anonymous namespace'::PrefixFormatter>::~unique_ptr(&v5); } else { std::__uniq_ptr_impl<nglog::`anonymous namespace'::PrefixFormatter,std::default_delete<nglog::`anonymous namespace'::PrefixFormatter>>::reset( 0LL, a2, a3); } }
InstallPrefixFormatter: TEST RDI,RDI JZ 0x0010c35e PUSH R14 PUSH RBX PUSH RAX MOV RBX,RSI MOV R14,RDI PUSH 0x18 POP RDI CALL 0x001075a0 AND dword ptr [RAX],0x0 MOV qword ptr [RAX + 0x8],R14 MOV qword ptr [RAX + 0x10],RBX MOV RBX,RSP AND qword ptr [RBX],0x0 MOV RDI,RAX CALL 0x0010dbf2 MOV RDI,RBX CALL 0x00108f1a ADD RSP,0x8 POP RBX POP R14 RET LAB_0010c35e: XOR EDI,EDI JMP 0x0010dbf2
/* nglog::InstallPrefixFormatter(void (*)(std::ostream&, nglog::LogMessage const&, void*), void*) */ void nglog::InstallPrefixFormatter (_func_void_ostream_ptr_LogMessage_ptr_void_ptr *param_1,void *param_2) { PrefixFormatter *pPVar1; int8 local_18; if (param_1 != (_func_void_ostream_ptr_LogMessage_ptr_void_ptr *)0x0) { pPVar1 = (PrefixFormatter *)operator_new(0x18); *(int4 *)pPVar1 = 0; *(_func_void_ostream_ptr_LogMessage_ptr_void_ptr **)(pPVar1 + 8) = param_1; *(void **)(pPVar1 + 0x10) = param_2; local_18 = 0; std:: __uniq_ptr_impl<nglog::(anonymous_namespace)::PrefixFormatter,std::default_delete<nglog::(anonymous_namespace)::PrefixFormatter>> ::reset(pPVar1); std:: unique_ptr<nglog::(anonymous_namespace)::PrefixFormatter,std::default_delete<nglog::(anonymous_namespace)::PrefixFormatter>> ::~unique_ptr((unique_ptr<nglog::(anonymous_namespace)::PrefixFormatter,std::default_delete<nglog::(anonymous_namespace)::PrefixFormatter>> *)&local_18); return; } std:: __uniq_ptr_impl<nglog::(anonymous_namespace)::PrefixFormatter,std::default_delete<nglog::(anonymous_namespace)::PrefixFormatter>> ::reset((PrefixFormatter *)0x0); return; }
3,523
delete_tails
eloqsql/storage/maria/ma_blockrec.c
static my_bool delete_tails(MARIA_HA *info, MARIA_RECORD_POS *tails) { my_bool res= 0; DBUG_ENTER("delete_tails"); for (; *tails; tails++) { if (delete_head_or_tail(info, ma_recordpos_to_page(*tails), ma_recordpos_to_dir_entry(*tails), 0, 1)) res= 1; } DBUG_RETURN(res); }
O0
c
delete_tails: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movb $0x0, -0x11(%rbp) movq -0x10(%rbp), %rax cmpq $0x0, (%rax) je 0x580d1 movq -0x8(%rbp), %rax movq %rax, -0x28(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rdi callq 0x57400 movq %rax, -0x20(%rbp) movq -0x10(%rbp), %rax movq (%rax), %rdi callq 0x57420 movq -0x28(%rbp), %rdi movq -0x20(%rbp), %rsi movl %eax, %edx xorl %ecx, %ecx movl $0x1, %r8d callq 0x57060 cmpb $0x0, %al je 0x580c1 movb $0x1, -0x11(%rbp) jmp 0x580c3 movq -0x10(%rbp), %rax addq $0x8, %rax movq %rax, -0x10(%rbp) jmp 0x58074 jmp 0x580d3 movb -0x11(%rbp), %al movb %al, -0x29(%rbp) movb -0x29(%rbp), %al addq $0x30, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
delete_tails: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_11], 0 loc_58074: mov rax, [rbp+var_10] cmp qword ptr [rax], 0 jz short loc_580D1 mov rax, [rbp+var_8] mov [rbp+var_28], rax mov rax, [rbp+var_10] mov rdi, [rax] call ma_recordpos_to_page mov [rbp+var_20], rax mov rax, [rbp+var_10] mov rdi, [rax] call ma_recordpos_to_dir_entry mov rdi, [rbp+var_28] mov rsi, [rbp+var_20] mov edx, eax xor ecx, ecx mov r8d, 1 call delete_head_or_tail cmp al, 0 jz short loc_580C1 mov [rbp+var_11], 1 loc_580C1: jmp short $+2 loc_580C3: mov rax, [rbp+var_10] add rax, 8 mov [rbp+var_10], rax jmp short loc_58074 loc_580D1: jmp short $+2 loc_580D3: mov al, [rbp+var_11] mov [rbp+var_29], al mov al, [rbp+var_29] add rsp, 30h pop rbp retn
char delete_tails(long long *a1, unsigned long long *a2) { unsigned int v2; // eax unsigned long long v4; // [rsp+10h] [rbp-20h] char v5; // [rsp+1Fh] [rbp-11h] v5 = 0; while ( *a2 ) { v4 = ma_recordpos_to_page(*a2); v2 = ma_recordpos_to_dir_entry(*a2); if ( delete_head_or_tail(a1, v4, v2, 0, 1) ) v5 = 1; ++a2; } return v5; }
delete_tails: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV byte ptr [RBP + -0x11],0x0 LAB_00158074: MOV RAX,qword ptr [RBP + -0x10] CMP qword ptr [RAX],0x0 JZ 0x001580d1 MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX] CALL 0x00157400 MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX] CALL 0x00157420 MOV RDI,qword ptr [RBP + -0x28] MOV RSI,qword ptr [RBP + -0x20] MOV EDX,EAX XOR ECX,ECX MOV R8D,0x1 CALL 0x00157060 CMP AL,0x0 JZ 0x001580c1 MOV byte ptr [RBP + -0x11],0x1 LAB_001580c1: JMP 0x001580c3 LAB_001580c3: MOV RAX,qword ptr [RBP + -0x10] ADD RAX,0x8 MOV qword ptr [RBP + -0x10],RAX JMP 0x00158074 LAB_001580d1: JMP 0x001580d3 LAB_001580d3: MOV AL,byte ptr [RBP + -0x11] MOV byte ptr [RBP + -0x29],AL MOV AL,byte ptr [RBP + -0x29] ADD RSP,0x30 POP RBP RET
int1 delete_tails(int8 param_1,long *param_2) { char cVar1; int4 uVar2; int8 uVar3; int1 local_19; long *local_18; local_19 = 0; for (local_18 = param_2; *local_18 != 0; local_18 = local_18 + 1) { uVar3 = ma_recordpos_to_page(*local_18); uVar2 = ma_recordpos_to_dir_entry(*local_18); cVar1 = delete_head_or_tail(param_1,uVar3,uVar2,0,1); if (cVar1 != '\0') { local_19 = 1; } } return local_19; }
3,524
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>::operator=(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>)
monkey531[P]llama/common/json.hpp
basic_json& operator=(basic_json other) noexcept ( std::is_nothrow_move_constructible<value_t>::value&& std::is_nothrow_move_assignable<value_t>::value&& std::is_nothrow_move_constructible<json_value>::value&& std::is_nothrow_move_assignable<json_value>::value&& std::is_nothrow_move_assignable<json_base_class_t>::value ) { // check that passed value is valid other.assert_invariant(); using std::swap; swap(m_data.m_type, other.m_data.m_type); swap(m_data.m_value, other.m_data.m_value); json_base_class_t::operator=(std::move(other)); set_parents(); assert_invariant(); return *this; }
O2
cpp
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::operator=(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>): pushq %rbp pushq %r14 pushq %rbx movq %rsi, %rbx movq %rdi, %r14 pushq $0x1 popq %rbp movq %rsi, %rdi movl %ebp, %esi callq 0x3d8e2 movb (%r14), %al movb (%rbx), %cl movb %cl, (%r14) movb %al, (%rbx) movq 0x8(%r14), %rax movq 0x8(%rbx), %rcx movq %rcx, 0x8(%r14) movq %rax, 0x8(%rbx) movq %r14, %rdi movl %ebp, %esi callq 0x3d8e2 movq %r14, %rax popq %rbx popq %r14 popq %rbp retq nop
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEaSESD_: push rbp push r14 push rbx mov rbx, rsi mov r14, rdi push 1 pop rbp mov rdi, rsi mov esi, ebp 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 al, [r14] mov cl, [rbx] mov [r14], cl mov [rbx], al mov rax, [r14+8] mov rcx, [rbx+8] mov [r14+8], rcx mov [rbx+8], rax mov rdi, r14 mov esi, ebp 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, r14 pop rbx pop r14 pop rbp retn
long long nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::operator=( long long a1, long long a2) { char v2; // al long long v3; // rax 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 *)a2); v2 = *(_BYTE *)a1; *(_BYTE *)a1 = *(_BYTE *)a2; *(_BYTE *)a2 = v2; v3 = *(_QWORD *)(a1 + 8); *(_QWORD *)(a1 + 8) = *(_QWORD *)(a2 + 8); *(_QWORD *)(a2 + 8) = v3; 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); return a1; }
operator=: PUSH RBP PUSH R14 PUSH RBX MOV RBX,RSI MOV R14,RDI PUSH 0x1 POP RBP MOV RDI,RSI MOV ESI,EBP CALL 0x0013d8e2 MOV AL,byte ptr [R14] MOV CL,byte ptr [RBX] MOV byte ptr [R14],CL MOV byte ptr [RBX],AL MOV RAX,qword ptr [R14 + 0x8] MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [R14 + 0x8],RCX MOV qword ptr [RBX + 0x8],RAX MOV RDI,R14 MOV ESI,EBP CALL 0x0013d8e2 MOV RAX,R14 POP RBX POP R14 POP RBP RET
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>::TEMPNAMEPLACEHOLDERVALUE(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>) */ basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> * __thiscall nlohmann::json_abi_v3_11_3:: basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::operator=(basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *this,basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *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; assert_invariant(SUB81(param_2,0)); bVar1 = *this; *this = *param_2; *param_2 = bVar1; uVar2 = *(int8 *)(this + 8); *(int8 *)(this + 8) = *(int8 *)(param_2 + 8); *(int8 *)(param_2 + 8) = uVar2; assert_invariant(SUB81(this,0)); return this; }
3,525
Rows_log_event::read_write_bitmaps_cmp(TABLE*)
eloqsql/sql/log_event.h
bool read_write_bitmaps_cmp(TABLE *table) { bool res= FALSE; switch (get_general_type_code()) { case DELETE_ROWS_EVENT: res= bitmap_cmp(get_cols(), table->read_set); break; case UPDATE_ROWS_EVENT: res= (bitmap_cmp(get_cols(), table->read_set) && bitmap_cmp(get_cols_ai(), table->rpl_write_set)); break; case WRITE_ROWS_EVENT: res= bitmap_cmp(get_cols(), table->rpl_write_set); break; default: /* We should just compare bitmaps for Delete, Write or Update rows events. */ DBUG_ASSERT(0); } return res; }
O0
c
Rows_log_event::read_write_bitmaps_cmp(TABLE*): pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq -0x8(%rbp), %rdi movq %rdi, -0x20(%rbp) movb $0x0, -0x11(%rbp) movq (%rdi), %rax movq 0x80(%rax), %rax callq *%rax movl %eax, %ecx movl %ecx, -0x18(%rbp) subl $0x1e, %eax je 0x986f31 jmp 0x986e98 movl -0x18(%rbp), %eax subl $0x1f, %eax je 0x986edb jmp 0x986ea2 movl -0x18(%rbp), %eax subl $0x20, %eax jne 0x986f59 jmp 0x986eb0 movq -0x20(%rbp), %rdi callq 0x986f70 movq %rax, %rdi movq -0x10(%rbp), %rax movq 0x1f0(%rax), %rsi callq 0x9794d0 cmpb $0x0, %al setne %al andb $0x1, %al movb %al, -0x11(%rbp) jmp 0x986f5f movq -0x20(%rbp), %rdi callq 0x986f70 movq %rax, %rdi movq -0x10(%rbp), %rax movq 0x1f0(%rax), %rsi callq 0x9794d0 movb %al, %cl xorl %eax, %eax cmpb $0x0, %cl movb %al, -0x21(%rbp) je 0x986f27 movq -0x20(%rbp), %rdi callq 0x986f90 movq %rax, %rdi movq -0x10(%rbp), %rax movq 0x200(%rax), %rsi callq 0x9794d0 cmpb $0x0, %al setne %al movb %al, -0x21(%rbp) movb -0x21(%rbp), %al andb $0x1, %al movb %al, -0x11(%rbp) jmp 0x986f5f movq -0x20(%rbp), %rdi callq 0x986f70 movq %rax, %rdi movq -0x10(%rbp), %rax movq 0x200(%rax), %rsi callq 0x9794d0 cmpb $0x0, %al setne %al andb $0x1, %al movb %al, -0x11(%rbp) jmp 0x986f5f jmp 0x986f5b jmp 0x986f5d jmp 0x986f5f movb -0x11(%rbp), %al andb $0x1, %al addq $0x30, %rsp popq %rbp retq nopw (%rax,%rax)
_ZN14Rows_log_event22read_write_bitmaps_cmpEP5TABLE: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov rdi, [rbp+var_8] mov [rbp+var_20], rdi mov [rbp+var_11], 0 mov rax, [rdi] mov rax, [rax+80h] call rax mov ecx, eax mov [rbp+var_18], ecx sub eax, 1Eh jz loc_986F31 jmp short $+2 loc_986E98: mov eax, [rbp+var_18] sub eax, 1Fh jz short loc_986EDB jmp short $+2 loc_986EA2: mov eax, [rbp+var_18] sub eax, 20h ; ' ' jnz loc_986F59 jmp short $+2 loc_986EB0: mov rdi, [rbp+var_20]; this call _ZNK14Rows_log_event8get_colsEv; Rows_log_event::get_cols(void) mov rdi, rax mov rax, [rbp+var_10] mov rsi, [rax+1F0h] call _ZL10bitmap_cmpPK9st_bitmapS1_; bitmap_cmp(st_bitmap const*,st_bitmap const*) cmp al, 0 setnz al and al, 1 mov [rbp+var_11], al jmp loc_986F5F loc_986EDB: mov rdi, [rbp+var_20]; this call _ZNK14Rows_log_event8get_colsEv; Rows_log_event::get_cols(void) mov rdi, rax mov rax, [rbp+var_10] mov rsi, [rax+1F0h] call _ZL10bitmap_cmpPK9st_bitmapS1_; bitmap_cmp(st_bitmap const*,st_bitmap const*) mov cl, al xor eax, eax cmp cl, 0 mov [rbp+var_21], al jz short loc_986F27 mov rdi, [rbp+var_20]; this call _ZNK14Rows_log_event11get_cols_aiEv; Rows_log_event::get_cols_ai(void) mov rdi, rax mov rax, [rbp+var_10] mov rsi, [rax+200h] call _ZL10bitmap_cmpPK9st_bitmapS1_; bitmap_cmp(st_bitmap const*,st_bitmap const*) cmp al, 0 setnz al mov [rbp+var_21], al loc_986F27: mov al, [rbp+var_21] and al, 1 mov [rbp+var_11], al jmp short loc_986F5F loc_986F31: mov rdi, [rbp+var_20]; this call _ZNK14Rows_log_event8get_colsEv; Rows_log_event::get_cols(void) mov rdi, rax mov rax, [rbp+var_10] mov rsi, [rax+200h] call _ZL10bitmap_cmpPK9st_bitmapS1_; bitmap_cmp(st_bitmap const*,st_bitmap const*) cmp al, 0 setnz al and al, 1 mov [rbp+var_11], al jmp short loc_986F5F loc_986F59: jmp short $+2 loc_986F5B: jmp short $+2 loc_986F5D: jmp short $+2 loc_986F5F: mov al, [rbp+var_11] and al, 1 add rsp, 30h pop rbp retn
bool Rows_log_event::read_write_bitmaps_cmp(Rows_log_event *this, TABLE *a2) { long long v2; // rax long long v3; // rax long long cols_ai; // rax long long cols; // rax bool v7; // [rsp+Fh] [rbp-21h] int v8; // [rsp+18h] [rbp-18h] bool v9; // [rsp+1Fh] [rbp-11h] v9 = 0; v8 = (*(long long ( **)(Rows_log_event *))(*(_QWORD *)this + 128LL))(this); switch ( v8 ) { case 30: cols = Rows_log_event::get_cols(this); v9 = bitmap_cmp(cols, *((_QWORD *)a2 + 64)); break; case 31: v3 = Rows_log_event::get_cols(this); v7 = 0; if ( bitmap_cmp(v3, *((_QWORD *)a2 + 62)) ) { cols_ai = Rows_log_event::get_cols_ai(this); v7 = bitmap_cmp(cols_ai, *((_QWORD *)a2 + 64)); } v9 = v7; break; case 32: v2 = Rows_log_event::get_cols(this); v9 = bitmap_cmp(v2, *((_QWORD *)a2 + 62)); break; } return v9; }
lower_bound: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV RDI,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x28],RDI CALL 0x00986710 MOV RDI,qword ptr [RBP + -0x28] MOV qword ptr [RBP + -0x20],RAX CALL 0x00986f40 MOV RDI,qword ptr [RBP + -0x28] MOV RSI,qword ptr [RBP + -0x20] MOV RDX,RAX MOV RCX,qword ptr [RBP + -0x18] CALL 0x00986eb0 MOV qword ptr [RBP + -0x8],RAX MOV RAX,qword ptr [RBP + -0x8] ADD RSP,0x30 POP RBP RET
/* std::_Rb_tree<unsigned int, std::pair<unsigned int const, unsigned int>, std::_Select1st<std::pair<unsigned int const, unsigned int> >, std::less<unsigned int>, std::allocator<std::pair<unsigned int const, unsigned int> > >::lower_bound(unsigned int const&) */ int8 __thiscall std:: _Rb_tree<unsigned_int,std::pair<unsigned_int_const,unsigned_int>,std::_Select1st<std::pair<unsigned_int_const,unsigned_int>>,std::less<unsigned_int>,std::allocator<std::pair<unsigned_int_const,unsigned_int>>> ::lower_bound(_Rb_tree<unsigned_int,std::pair<unsigned_int_const,unsigned_int>,std::_Select1st<std::pair<unsigned_int_const,unsigned_int>>,std::less<unsigned_int>,std::allocator<std::pair<unsigned_int_const,unsigned_int>>> *this,uint *param_1) { _Rb_tree_node *p_Var1; _Rb_tree_node_base *p_Var2; int8 uVar3; p_Var1 = (_Rb_tree_node *)_M_begin(this); p_Var2 = (_Rb_tree_node_base *)_M_end(this); uVar3 = _M_lower_bound(this,p_Var1,p_Var2,param_1); return uVar3; }
3,526
common_kv_cache_dump_view_seqs(llama_kv_cache_view const&, int)
monkey531[P]llama/common/common.cpp
void common_kv_cache_dump_view_seqs(const llama_kv_cache_view & view, int row_size) { static const char slot_chars[] = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"; printf("=== Dumping KV cache. total cells %d, max sequences per cell %d, populated cells %d, total tokens in cache %d, largest empty slot=%d @ %d\n", view.n_cells, view.n_seq_max, view.used_cells, view.token_count, view.max_contiguous, view.max_contiguous_idx); std::unordered_map<llama_seq_id, size_t> seqs; llama_kv_cache_view_cell * c_curr = view.cells; llama_seq_id * cs_curr = view.cells_sequences; for (int i = 0; i < view.n_cells; i++, c_curr++, cs_curr += view.n_seq_max) { for (int j = 0; j < view.n_seq_max; j++) { if (cs_curr[j] < 0) { continue; } if (seqs.find(cs_curr[j]) == seqs.end()) { if (seqs.size() + 1 >= sizeof(slot_chars)) { break; } const size_t sz = seqs.size(); seqs[cs_curr[j]] = sz; } } if (seqs.size() + 1 >= sizeof(slot_chars)) { break; } } printf("=== Sequence legend: "); for (const auto & it : seqs) { printf("%zu=%d, ", it.second, it.first); } printf("'+'=other sequence ids"); c_curr = view.cells; cs_curr = view.cells_sequences; for (int i = 0; i < view.n_cells; i++, c_curr++, cs_curr += view.n_seq_max) { if (i % row_size == 0) { printf("\n%5d: ", i); } for (int j = 0; j < view.n_seq_max; j++) { if (cs_curr[j] >= 0) { const auto & it = seqs.find(cs_curr[j]); putchar(it != seqs.end() ? int(slot_chars[it->second]) : '+'); } else { putchar('.'); } } putchar(' '); } printf("\n=== Done dumping\n"); }
O3
cpp
common_kv_cache_dump_view_seqs(llama_kv_cache_view const&, int): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x58, %rsp movl %esi, 0x14(%rsp) movq %rdi, %r14 movl (%rdi), %esi movl 0x4(%rdi), %edx movl 0xc(%rdi), %ecx movl 0x8(%rdi), %r8d movl 0x10(%rdi), %r9d movl 0x14(%rdi), %eax movl %eax, (%rsp) leaq 0x858da(%rip), %rdi # 0xa8815 movq $0x0, 0x18(%rsp) xorl %eax, %eax callq 0x18070 leaq 0x50(%rsp), %rax movq %rax, -0x30(%rax) movq $0x1, -0x28(%rax) xorps %xmm0, %xmm0 movups %xmm0, -0x20(%rax) movl $0x3f800000, -0x10(%rax) # imm = 0x3F800000 movups %xmm0, -0x8(%rax) cmpl $0x0, (%r14) jle 0x22ffe movq 0x20(%r14), %rbp movl 0x4(%r14), %eax leaq 0x20(%rsp), %r15 xorl %ebx, %ebx testl %eax, %eax jle 0x22fda movq %rbp, %r12 xorl %r13d, %r13d cmpl $0x0, (%r12) js 0x22fc5 movq %r15, %rdi movq %r12, %rsi callq 0x7e422 testq %rax, %rax jne 0x22fc5 movq 0x38(%rsp), %rbx leaq -0x3e(%rbx), %rax cmpq $-0x3f, %rax jb 0x22fda movq %r15, %rdi movq %r12, %rsi callq 0x7e47e movq %rbx, (%rax) incq %r13 movslq 0x4(%r14), %rax addq $0x4, %r12 cmpq %rax, %r13 jl 0x22f91 movq 0x38(%rsp), %rbx leaq -0x3e(%rbx), %rax cmpq $-0x3f, %rax jb 0x22ffe movq 0x18(%rsp), %rcx incl %ecx movslq 0x4(%r14), %rax leaq (%rbp,%rax,4), %rbp movq %rcx, 0x18(%rsp) cmpl (%r14), %ecx jl 0x22f87 leaq 0x8589b(%rip), %rdi # 0xa88a0 xorl %eax, %eax callq 0x18070 movq 0x30(%rsp), %rbx testq %rbx, %rbx je 0x23036 leaq 0x85899(%rip), %r15 # 0xa88b6 movq 0x10(%rbx), %rsi movl 0x8(%rbx), %edx movq %r15, %rdi xorl %eax, %eax callq 0x18070 movq (%rbx), %rbx testq %rbx, %rbx jne 0x2301d leaq 0x85882(%rip), %rdi # 0xa88bf xorl %eax, %eax callq 0x18070 cmpl $0x0, (%r14) jle 0x230e6 movq 0x20(%r14), %r15 leaq 0x20(%rsp), %r12 xorl %ebp, %ebp movl %ebp, %eax cltd idivl 0x14(%rsp) testl %edx, %edx jne 0x23074 leaq 0x857a3(%rip), %rdi # 0xa880e movl %ebp, %esi xorl %eax, %eax callq 0x18070 cmpl $0x0, 0x4(%r14) jle 0x230c9 movq %r15, %r13 xorl %ebx, %ebx cmpl $0x0, (%r13) js 0x230a8 movq %r12, %rdi movq %r13, %rsi callq 0x7e422 testq %rax, %rax je 0x230af movq 0x10(%rax), %rax leaq 0x897ee(%rip), %rcx # 0xac890 movsbl (%rax,%rcx), %edi jmp 0x230b4 movl $0x2e, %edi jmp 0x230b4 movl $0x2b, %edi callq 0x18900 incq %rbx movslq 0x4(%r14), %rax addq $0x4, %r13 cmpq %rax, %rbx jl 0x23080 movl $0x20, %edi callq 0x18900 incl %ebp movslq 0x4(%r14), %rax leaq (%r15,%rax,4), %r15 cmpl (%r14), %ebp jl 0x23059 leaq 0x8974c(%rip), %rdi # 0xac839 callq 0x18a00 leaq 0x20(%rsp), %rdi callq 0x7b874 addq $0x58, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq jmp 0x2310f jmp 0x2310f movq %rax, %rbx leaq 0x20(%rsp), %rdi callq 0x7b874 movq %rbx, %rdi callq 0x18bb0
_Z30common_kv_cache_dump_view_seqsRK19llama_kv_cache_viewi: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 58h mov [rsp+88h+var_74], esi mov r14, rdi mov esi, [rdi] mov edx, [rdi+4] mov ecx, [rdi+0Ch] mov r8d, [rdi+8] mov r9d, [rdi+10h] mov eax, [rdi+14h] mov [rsp+88h+var_88], eax lea rdi, aDumpingKvCache_0; "=== Dumping KV cache. total cells %d, m"... mov [rsp+88h+var_70], 0 xor eax, eax call _printf lea rax, [rsp+88h+var_38] mov [rax-30h], rax mov qword ptr [rax-28h], 1 xorps xmm0, xmm0 movups xmmword ptr [rax-20h], xmm0 mov dword ptr [rax-10h], 3F800000h movups xmmword ptr [rax-8], xmm0 cmp dword ptr [r14], 0 jle loc_22FFE mov rbp, [r14+20h] mov eax, [r14+4] lea r15, [rsp+88h+var_68] xor ebx, ebx loc_22F87: test eax, eax jle short loc_22FDA mov r12, rbp xor r13d, r13d loc_22F91: cmp dword ptr [r12], 0 js short loc_22FC5 mov rdi, r15 mov rsi, r12 call _ZNSt10_HashtableIiSt4pairIKimESaIS2_ENSt8__detail10_Select1stESt8equal_toIiESt4hashIiENS4_18_Mod_range_hashingENS4_20_Default_ranged_hashENS4_20_Prime_rehash_policyENS4_17_Hashtable_traitsILb0ELb0ELb1EEEE4findERS1_; std::_Hashtable<int,std::pair<int const,ulong>,std::allocator<std::pair<int const,ulong>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>>::find(int const&) test rax, rax jnz short loc_22FC5 mov rbx, [rsp+88h+var_50] lea rax, [rbx-3Eh] cmp rax, 0FFFFFFFFFFFFFFC1h jb short loc_22FDA mov rdi, r15 mov rsi, r12 call _ZNSt8__detail9_Map_baseIiSt4pairIKimESaIS3_ENS_10_Select1stESt8equal_toIiESt4hashIiENS_18_Mod_range_hashingENS_20_Default_ranged_hashENS_20_Prime_rehash_policyENS_17_Hashtable_traitsILb0ELb0ELb1EEELb1EEixERS2_; std::__detail::_Map_base<int,std::pair<int const,ulong>,std::allocator<std::pair<int const,ulong>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>,true>::operator[](int const&) mov [rax], rbx loc_22FC5: inc r13 movsxd rax, dword ptr [r14+4] add r12, 4 cmp r13, rax jl short loc_22F91 mov rbx, [rsp+88h+var_50] loc_22FDA: lea rax, [rbx-3Eh] cmp rax, 0FFFFFFFFFFFFFFC1h jb short loc_22FFE mov rcx, [rsp+88h+var_70] inc ecx movsxd rax, dword ptr [r14+4] lea rbp, [rbp+rax*4+0] mov [rsp+88h+var_70], rcx cmp ecx, [r14] jl short loc_22F87 loc_22FFE: lea rdi, aSequenceLegend; "=== Sequence legend: " xor eax, eax call _printf mov rbx, [rsp+88h+var_58] test rbx, rbx jz short loc_23036 lea r15, aZuD; "%zu=%d, " loc_2301D: mov rsi, [rbx+10h] mov edx, [rbx+8] mov rdi, r15 xor eax, eax call _printf mov rbx, [rbx] test rbx, rbx jnz short loc_2301D loc_23036: lea rdi, aOtherSequenceI; "'+'=other sequence ids" xor eax, eax call _printf cmp dword ptr [r14], 0 jle loc_230E6 mov r15, [r14+20h] lea r12, [rsp+88h+var_68] xor ebp, ebp loc_23059: mov eax, ebp cdq idiv [rsp+88h+var_74] test edx, edx jnz short loc_23074 lea rdi, a5d; "\n%5d: " mov esi, ebp xor eax, eax call _printf loc_23074: cmp dword ptr [r14+4], 0 jle short loc_230C9 mov r13, r15 xor ebx, ebx loc_23080: cmp dword ptr [r13+0], 0 js short loc_230A8 mov rdi, r12 mov rsi, r13 call _ZNSt10_HashtableIiSt4pairIKimESaIS2_ENSt8__detail10_Select1stESt8equal_toIiESt4hashIiENS4_18_Mod_range_hashingENS4_20_Default_ranged_hashENS4_20_Prime_rehash_policyENS4_17_Hashtable_traitsILb0ELb0ELb1EEEE4findERS1_; std::_Hashtable<int,std::pair<int const,ulong>,std::allocator<std::pair<int const,ulong>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>>::find(int const&) test rax, rax jz short loc_230AF mov rax, [rax+10h] lea rcx, _ZZ30common_kv_cache_dump_view_seqsRK19llama_kv_cache_viewiE10slot_chars; "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabc"... movsx edi, byte ptr [rax+rcx] jmp short loc_230B4 loc_230A8: mov edi, 2Eh ; '.' jmp short loc_230B4 loc_230AF: mov edi, 2Bh ; '+' loc_230B4: call _putchar inc rbx movsxd rax, dword ptr [r14+4] add r13, 4 cmp rbx, rax jl short loc_23080 loc_230C9: mov edi, 20h ; ' ' call _putchar inc ebp movsxd rax, dword ptr [r14+4] lea r15, [r15+rax*4] cmp ebp, [r14] jl loc_23059 loc_230E6: lea rdi, aDoneDumping; "\n=== Done dumping" call _puts lea rdi, [rsp+88h+var_68] call _ZNSt10_HashtableIiSt4pairIKimESaIS2_ENSt8__detail10_Select1stESt8equal_toIiESt4hashIiENS4_18_Mod_range_hashingENS4_20_Default_ranged_hashENS4_20_Prime_rehash_policyENS4_17_Hashtable_traitsILb0ELb0ELb1EEEED2Ev; std::_Hashtable<int,std::pair<int const,ulong>,std::allocator<std::pair<int const,ulong>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>>::~_Hashtable() add rsp, 58h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn jmp short loc_2310F jmp short $+2 loc_2310F: mov rbx, rax lea rdi, [rsp+arg_18] call _ZNSt10_HashtableIiSt4pairIKimESaIS2_ENSt8__detail10_Select1stESt8equal_toIiESt4hashIiENS4_18_Mod_range_hashingENS4_20_Default_ranged_hashENS4_20_Prime_rehash_policyENS4_17_Hashtable_traitsILb0ELb0ELb1EEEED2Ev; std::_Hashtable<int,std::pair<int const,ulong>,std::allocator<std::pair<int const,ulong>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>>::~_Hashtable() mov rdi, rbx call __Unwind_Resume
long long common_kv_cache_dump_view_seqs(long long a1, int a2) { int *v3; // rbp long long v4; // rax long long v5; // rbx int *v6; // r12 long long v7; // r13 long long *i; // rbx int *v9; // r15 int v10; // ebp int *v11; // r13 long long v12; // rbx long long v13; // rax long long v14; // rdi int v16; // [rsp+18h] [rbp-70h] _QWORD v17[2]; // [rsp+20h] [rbp-68h] BYREF __int128 v18; // [rsp+30h] [rbp-58h] int v19; // [rsp+40h] [rbp-48h] __int128 v20; // [rsp+48h] [rbp-40h] BYREF v16 = 0; printf( "=== Dumping KV cache. total cells %d, max sequences per cell %d, populated cells %d, total tokens in cache %d, large" "st empty slot=%d @ %d\n", *(_DWORD *)a1, *(_DWORD *)(a1 + 4), *(_DWORD *)(a1 + 12), *(_DWORD *)(a1 + 8), *(_DWORD *)(a1 + 16), *(_DWORD *)(a1 + 20)); v17[0] = (char *)&v20 + 8; v17[1] = 1LL; v18 = 0LL; v19 = 1065353216; v20 = 0LL; if ( *(int *)a1 > 0 ) { v3 = *(int **)(a1 + 32); LODWORD(v4) = *(_DWORD *)(a1 + 4); v5 = 0LL; do { if ( (int)v4 > 0 ) { v6 = v3; v7 = 0LL; do { if ( *v6 >= 0 && !std::_Hashtable<int,std::pair<int const,unsigned long>,std::allocator<std::pair<int const,unsigned long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>>::find( v17, v6) ) { v5 = *((_QWORD *)&v18 + 1); if ( (unsigned long long)(*((_QWORD *)&v18 + 1) - 62LL) < 0xFFFFFFFFFFFFFFC1LL ) goto LABEL_11; *(_QWORD *)std::__detail::_Map_base<int,std::pair<int const,unsigned long>,std::allocator<std::pair<int const,unsigned long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>,true>::operator[]( v17, v6) = v5; } ++v7; ++v6; } while ( v7 < *(int *)(a1 + 4) ); v5 = *((_QWORD *)&v18 + 1); } LABEL_11: if ( (unsigned long long)(v5 - 62) < 0xFFFFFFFFFFFFFFC1LL ) break; v4 = *(int *)(a1 + 4); v3 += v4; ++v16; } while ( v16 < *(_DWORD *)a1 ); } printf("=== Sequence legend: "); for ( i = (long long *)v18; i; i = (long long *)*i ) printf("%zu=%d, ", i[2], *((_DWORD *)i + 2)); printf("'+'=other sequence ids"); if ( *(int *)a1 > 0 ) { v9 = *(int **)(a1 + 32); v10 = 0; do { if ( !(v10 % a2) ) printf("\n%5d: ", v10); if ( *(int *)(a1 + 4) > 0 ) { v11 = v9; v12 = 0LL; do { if ( *v11 < 0 ) { v14 = 46LL; } else { v13 = std::_Hashtable<int,std::pair<int const,unsigned long>,std::allocator<std::pair<int const,unsigned long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>>::find( v17, v11); if ( v13 ) v14 = (unsigned int)common_kv_cache_dump_view_seqs(llama_kv_cache_view const&,int)::slot_chars[*(_QWORD *)(v13 + 16)]; else v14 = 43LL; } putchar(v14); ++v12; ++v11; } while ( v12 < *(int *)(a1 + 4) ); } putchar(32LL); ++v10; v9 += *(int *)(a1 + 4); } while ( v10 < *(_DWORD *)a1 ); } puts("\n=== Done dumping"); return std::_Hashtable<int,std::pair<int const,unsigned long>,std::allocator<std::pair<int const,unsigned long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>>::~_Hashtable(v17); }
common_kv_cache_dump_view_seqs: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x58 MOV dword ptr [RSP + 0x14],ESI MOV R14,RDI MOV ESI,dword ptr [RDI] MOV EDX,dword ptr [RDI + 0x4] MOV ECX,dword ptr [RDI + 0xc] MOV R8D,dword ptr [RDI + 0x8] MOV R9D,dword ptr [RDI + 0x10] MOV EAX,dword ptr [RDI + 0x14] MOV dword ptr [RSP],EAX LEA RDI,[0x1a8815] MOV qword ptr [RSP + 0x18],0x0 XOR EAX,EAX CALL 0x00118070 LEA RAX,[RSP + 0x50] MOV qword ptr [RAX + -0x30],RAX MOV qword ptr [RAX + -0x28],0x1 XORPS XMM0,XMM0 MOVUPS xmmword ptr [RAX + -0x20],XMM0 MOV dword ptr [RAX + -0x10],0x3f800000 MOVUPS xmmword ptr [RAX + -0x8],XMM0 CMP dword ptr [R14],0x0 JLE 0x00122ffe MOV RBP,qword ptr [R14 + 0x20] MOV EAX,dword ptr [R14 + 0x4] LEA R15,[RSP + 0x20] XOR EBX,EBX LAB_00122f87: TEST EAX,EAX JLE 0x00122fda MOV R12,RBP XOR R13D,R13D LAB_00122f91: CMP dword ptr [R12],0x0 JS 0x00122fc5 LAB_00122f98: MOV RDI,R15 MOV RSI,R12 CALL 0x0017e422 TEST RAX,RAX JNZ 0x00122fc5 MOV RBX,qword ptr [RSP + 0x38] LEA RAX,[RBX + -0x3e] CMP RAX,-0x3f JC 0x00122fda LAB_00122fb7: MOV RDI,R15 MOV RSI,R12 CALL 0x0017e47e MOV qword ptr [RAX],RBX LAB_00122fc5: INC R13 MOVSXD RAX,dword ptr [R14 + 0x4] ADD R12,0x4 CMP R13,RAX JL 0x00122f91 MOV RBX,qword ptr [RSP + 0x38] LAB_00122fda: LEA RAX,[RBX + -0x3e] CMP RAX,-0x3f JC 0x00122ffe MOV RCX,qword ptr [RSP + 0x18] INC ECX MOVSXD RAX,dword ptr [R14 + 0x4] LEA RBP,[RBP + RAX*0x4] MOV qword ptr [RSP + 0x18],RCX CMP ECX,dword ptr [R14] JL 0x00122f87 LAB_00122ffe: LEA RDI,[0x1a88a0] XOR EAX,EAX CALL 0x00118070 MOV RBX,qword ptr [RSP + 0x30] TEST RBX,RBX JZ 0x00123036 LEA R15,[0x1a88b6] LAB_0012301d: MOV RSI,qword ptr [RBX + 0x10] MOV EDX,dword ptr [RBX + 0x8] MOV RDI,R15 XOR EAX,EAX CALL 0x00118070 MOV RBX,qword ptr [RBX] TEST RBX,RBX JNZ 0x0012301d LAB_00123036: LEA RDI,[0x1a88bf] XOR EAX,EAX CALL 0x00118070 CMP dword ptr [R14],0x0 JLE 0x001230e6 MOV R15,qword ptr [R14 + 0x20] LEA R12,[RSP + 0x20] XOR EBP,EBP LAB_00123059: MOV EAX,EBP CDQ IDIV dword ptr [RSP + 0x14] TEST EDX,EDX JNZ 0x00123074 LEA RDI,[0x1a880e] MOV ESI,EBP XOR EAX,EAX CALL 0x00118070 LAB_00123074: CMP dword ptr [R14 + 0x4],0x0 JLE 0x001230c9 MOV R13,R15 XOR EBX,EBX LAB_00123080: CMP dword ptr [R13],0x0 JS 0x001230a8 LAB_00123087: MOV RDI,R12 MOV RSI,R13 CALL 0x0017e422 LAB_00123092: TEST RAX,RAX JZ 0x001230af MOV RAX,qword ptr [RAX + 0x10] LEA RCX,[0x1ac890] MOVSX EDI,byte ptr [RAX + RCX*0x1] JMP 0x001230b4 LAB_001230a8: MOV EDI,0x2e JMP 0x001230b4 LAB_001230af: MOV EDI,0x2b LAB_001230b4: CALL 0x00118900 INC RBX MOVSXD RAX,dword ptr [R14 + 0x4] ADD R13,0x4 CMP RBX,RAX JL 0x00123080 LAB_001230c9: MOV EDI,0x20 CALL 0x00118900 INC EBP MOVSXD RAX,dword ptr [R14 + 0x4] LEA R15,[R15 + RAX*0x4] CMP EBP,dword ptr [R14] JL 0x00123059 LAB_001230e6: LEA RDI,[0x1ac839] CALL 0x00118a00 LEA RDI,[RSP + 0x20] CALL 0x0017b874 ADD RSP,0x58 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* common_kv_cache_dump_view_seqs(llama_kv_cache_view const&, int) */ void common_kv_cache_dump_view_seqs(llama_kv_cache_view *param_1,int param_2) { int8 *puVar1; long lVar2; long *plVar3; ulong uVar4; int iVar5; long lVar6; uint uVar7; int *piVar8; int *piVar9; long lVar10; int8 *local_68; int8 local_60; int8 *local_58; long lStack_50; int4 local_48; int8 local_40; int8 uStack_38; iVar5 = 0; printf("=== Dumping KV cache. total cells %d, max sequences per cell %d, populated cells %d, total tokens in cache %d, largest empty slot=%d @ %d\n" ,(ulong)*(uint *)param_1,(ulong)*(uint *)(param_1 + 4),(ulong)*(uint *)(param_1 + 0xc), (ulong)*(uint *)(param_1 + 8),(ulong)*(uint *)(param_1 + 0x10), *(int4 *)(param_1 + 0x14)); local_68 = &uStack_38; local_60 = 1; local_58 = (int8 *)0x0; lStack_50 = 0; local_48 = 0x3f800000; local_40 = 0; uStack_38 = 0; if (0 < *(int *)param_1) { piVar8 = *(int **)(param_1 + 0x20); uVar4 = (ulong)*(uint *)(param_1 + 4); lVar6 = 0; do { if (0 < (int)uVar4) { lVar10 = 0; piVar9 = piVar8; do { /* try { // try from 00122f98 to 00122fa2 has its CatchHandler @ 0012310d */ if ((-1 < *piVar9) && (lVar2 = std:: _Hashtable<int,std::pair<int_const,unsigned_long>,std::allocator<std::pair<int_const,unsigned_long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>> ::find((_Hashtable<int,std::pair<int_const,unsigned_long>,std::allocator<std::pair<int_const,unsigned_long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>> *)&local_68,piVar9), lVar6 = lStack_50, lVar2 == 0)) { if (lStack_50 - 0x3eU < 0xffffffffffffffc1) break; /* try { // try from 00122fb7 to 00122fc1 has its CatchHandler @ 0012310b */ plVar3 = (long *)std::__detail:: _Map_base<int,std::pair<int_const,unsigned_long>,std::allocator<std::pair<int_const,unsigned_long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>,true> ::operator[]((_Map_base<int,std::pair<int_const,unsigned_long>,std::allocator<std::pair<int_const,unsigned_long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>,true> *)&local_68,piVar9); *plVar3 = lVar6; } lVar10 = lVar10 + 1; piVar9 = piVar9 + 1; lVar6 = lStack_50; } while (lVar10 < *(int *)(param_1 + 4)); } if (lVar6 - 0x3eU < 0xffffffffffffffc1) break; iVar5 = iVar5 + 1; uVar4 = (ulong)*(int *)(param_1 + 4); piVar8 = piVar8 + uVar4; } while (iVar5 < *(int *)param_1); } printf("=== Sequence legend: "); for (puVar1 = local_58; puVar1 != (int8 *)0x0; puVar1 = (int8 *)*puVar1) { printf("%zu=%d, ",puVar1[2],(ulong)*(uint *)(puVar1 + 1)); } printf("\'+\'=other sequence ids"); if (0 < *(int *)param_1) { piVar8 = *(int **)(param_1 + 0x20); uVar7 = 0; do { if ((int)uVar7 % param_2 == 0) { printf("\n%5d: ",(ulong)uVar7); } if (0 < *(int *)(param_1 + 4)) { lVar6 = 0; piVar9 = piVar8; do { if (*piVar9 < 0) { iVar5 = 0x2e; } else { /* try { // try from 00123087 to 00123091 has its CatchHandler @ 0012310f */ lVar10 = std:: _Hashtable<int,std::pair<int_const,unsigned_long>,std::allocator<std::pair<int_const,unsigned_long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>> ::find((_Hashtable<int,std::pair<int_const,unsigned_long>,std::allocator<std::pair<int_const,unsigned_long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>> *)&local_68,piVar9); if (lVar10 == 0) { iVar5 = 0x2b; } else { iVar5 = (int)"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz" [*(long *)(lVar10 + 0x10)]; } } putchar(iVar5); lVar6 = lVar6 + 1; piVar9 = piVar9 + 1; } while (lVar6 < *(int *)(param_1 + 4)); } putchar(0x20); uVar7 = uVar7 + 1; piVar8 = piVar8 + *(int *)(param_1 + 4); } while ((int)uVar7 < *(int *)param_1); } puts("\n=== Done dumping"); std:: _Hashtable<int,std::pair<int_const,unsigned_long>,std::allocator<std::pair<int_const,unsigned_long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>> ::~_Hashtable((_Hashtable<int,std::pair<int_const,unsigned_long>,std::allocator<std::pair<int_const,unsigned_long>>,std::__detail::_Select1st,std::equal_to<int>,std::hash<int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,false,true>> *)&local_68); return; }
3,527
Acore::Crypto::SRP6::_B(BigNumber const&, BigNumber const&)
SylCore-WoTLK/src/common/Cryptography/Authentication/SRP6.h
static EphemeralKey _B(BigNumber const& b, BigNumber const& v) { return ((_g.ModExp(b, _N) + (v * 3)) % N).ToByteArray<EPHEMERAL_KEY_LENGTH>(); }
O3
c
Acore::Crypto::SRP6::_B(BigNumber const&, BigNumber const&): pushq %r14 pushq %rbx subq $0x38, %rsp movq %rdx, %r14 movq %rsi, %rdx movq %rdi, %rbx leaq 0xbdc13(%rip), %rsi # 0x16d970 leaq 0xbdc14(%rip), %rcx # 0x16d978 leaq 0x20(%rsp), %rdi callq 0xaed9e leaq 0x10(%rsp), %rdi movl $0x3, %esi callq 0x5479e leaq 0x18(%rsp), %rdi leaq 0x10(%rsp), %rdx movq %r14, %rsi callq 0xaff72 leaq 0x28(%rsp), %rdi leaq 0x20(%rsp), %rsi leaq 0x18(%rsp), %rdx callq 0xb0174 leaq 0xbdba6(%rip), %rsi # 0x16d950 leaq 0x8(%rsp), %rdi movl $0x1, %edx callq 0xafad0 leaq 0x30(%rsp), %rdi leaq 0x28(%rsp), %rsi leaq 0x8(%rsp), %rdx callq 0xafe8c leaq 0x30(%rsp), %rdi movl $0x20, %edx movq %rbx, %rsi movl $0x1, %ecx callq 0xaee4e leaq 0x30(%rsp), %rdi callq 0xaeb6c leaq 0x8(%rsp), %rdi callq 0xaeb6c leaq 0x28(%rsp), %rdi callq 0xaeb6c leaq 0x18(%rsp), %rdi callq 0xaeb6c leaq 0x10(%rsp), %rdi callq 0xaeb6c leaq 0x20(%rsp), %rdi callq 0xaeb6c movq %rbx, %rax addq $0x38, %rsp popq %rbx popq %r14 retq movq %rax, %rbx leaq 0x30(%rsp), %rdi callq 0xaeb6c jmp 0xafe3d movq %rax, %rbx leaq 0x8(%rsp), %rdi callq 0xaeb6c jmp 0xafe4c movq %rax, %rbx leaq 0x28(%rsp), %rdi callq 0xaeb6c jmp 0xafe5b movq %rax, %rbx leaq 0x18(%rsp), %rdi callq 0xaeb6c jmp 0xafe6a movq %rax, %rbx leaq 0x10(%rsp), %rdi callq 0xaeb6c leaq 0x20(%rsp), %rdi callq 0xaeb6c movq %rbx, %rdi callq 0x1bba0 movq %rax, %rbx jmp 0xafe74 nop
_ZN5Acore6Crypto4SRP62_BERK9BigNumberS4_: push r14 push rbx sub rsp, 38h mov r14, rdx mov rdx, rsi; BigNumber * mov rbx, rdi lea rsi, _ZN5Acore6Crypto4SRP62_gE; BigNumber * lea rcx, _ZN5Acore6Crypto4SRP62_NE; Acore::Crypto::SRP6::_N lea rdi, [rsp+48h+var_28]; this call _ZNK9BigNumber6ModExpERKS_S1_; BigNumber::ModExp(BigNumber const&,BigNumber const&) lea rdi, [rsp+48h+var_38]; this mov esi, 3; int call _ZN9BigNumberC2Ei; BigNumber::BigNumber(int) lea rdi, [rsp+48h+var_30]; this lea rdx, [rsp+48h+var_38] mov rsi, r14 call _ZNK9BigNumbermlERKS_; BigNumber::operator*(BigNumber const&) lea rdi, [rsp+48h+var_20]; this lea rsi, [rsp+48h+var_28] lea rdx, [rsp+48h+var_30] call _ZNK9BigNumberplERKS_; BigNumber::operator+(BigNumber const&) lea rsi, _ZN5Acore6Crypto4SRP61NE; unsigned __int8 * lea rdi, [rsp+48h+var_40]; this mov edx, 1; bool call _ZN9BigNumberC2ILm32EEERKSt5arrayIhXT_EEb; BigNumber::BigNumber<32ul>(std::array<uchar,32ul> const&,bool) lea rdi, [rsp+48h+var_18]; this lea rsi, [rsp+48h+var_20] lea rdx, [rsp+48h+var_40] call _ZNK9BigNumberrmERKS_; BigNumber::operator%(BigNumber const&) lea rdi, [rsp+48h+var_18]; this mov edx, 20h ; ' '; unsigned __int64 mov rsi, rbx; unsigned __int8 * mov ecx, 1; bool call _ZNK9BigNumber8GetBytesEPhmb; BigNumber::GetBytes(uchar *,ulong,bool) lea rdi, [rsp+48h+var_18]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() lea rdi, [rsp+48h+var_40]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() lea rdi, [rsp+48h+var_20]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() lea rdi, [rsp+48h+var_30]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() lea rdi, [rsp+48h+var_38]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() lea rdi, [rsp+48h+var_28]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() mov rax, rbx add rsp, 38h pop rbx pop r14 retn mov rbx, rax lea rdi, [rsp+arg_28]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() jmp short loc_AFE3D mov rbx, rax loc_AFE3D: lea rdi, [rsp+arg_0]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() jmp short loc_AFE4C mov rbx, rax loc_AFE4C: lea rdi, [rsp+arg_20]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() jmp short loc_AFE5B mov rbx, rax loc_AFE5B: lea rdi, [rsp+arg_10]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() jmp short loc_AFE6A mov rbx, rax loc_AFE6A: lea rdi, [rsp+arg_8]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() loc_AFE74: lea rdi, [rsp+arg_18]; void * call _ZN9BigNumberD2Ev; BigNumber::~BigNumber() mov rdi, rbx call __Unwind_Resume mov rbx, rax jmp short loc_AFE74
Acore::Crypto::SRP6 * Acore::Crypto::SRP6::_B( Acore::Crypto::SRP6 *this, const BigNumber *a2, const BigNumber *a3) { char v4; // [rsp+0h] [rbp-48h] char v5; // [rsp+0h] [rbp-48h] char v6; // [rsp+0h] [rbp-48h] long long v7; // [rsp+8h] [rbp-40h] BYREF long long v8; // [rsp+10h] [rbp-38h] BYREF long long v9; // [rsp+18h] [rbp-30h] BYREF long long v10; // [rsp+20h] [rbp-28h] BYREF long long v11; // [rsp+28h] [rbp-20h] BYREF _QWORD v12[3]; // [rsp+30h] [rbp-18h] BYREF BigNumber::ModExp((BigNumber *)&v10, (const BigNumber *)&Acore::Crypto::SRP6::_g, a2, &Acore::Crypto::SRP6::_N); BigNumber::BigNumber((BigNumber *)&v8, 3); BigNumber::operator*((BigNumber *)&v9, v4); BigNumber::operator+((BigNumber *)&v11, v5); BigNumber::BigNumber<32ul>((BigNumber *)&v7, &Acore::Crypto::SRP6::N, 1); BigNumber::operator%((BigNumber *)v12, v6); BigNumber::GetBytes((BigNumber *)v12, (unsigned __int8 *)this, 32LL, 1); BigNumber::~BigNumber(v12); BigNumber::~BigNumber(&v7); BigNumber::~BigNumber(&v11); BigNumber::~BigNumber(&v9); BigNumber::~BigNumber(&v8); BigNumber::~BigNumber(&v10); return this; }
_B: PUSH R14 PUSH RBX SUB RSP,0x38 MOV R14,RDX MOV RDX,RSI MOV RBX,RDI LEA RSI,[0x26d970] LEA RCX,[0x26d978] LEA RDI,[RSP + 0x20] CALL 0x001aed9e LAB_001afd6e: LEA RDI,[RSP + 0x10] MOV ESI,0x3 CALL 0x0015479e LAB_001afd7d: LEA RDI,[RSP + 0x18] LEA RDX,[RSP + 0x10] MOV RSI,R14 CALL 0x001aff72 LAB_001afd8f: LEA RDI,[RSP + 0x28] LEA RSI,[RSP + 0x20] LEA RDX,[RSP + 0x18] CALL 0x001b0174 LAB_001afda3: LEA RSI,[0x26d950] LEA RDI,[RSP + 0x8] MOV EDX,0x1 CALL 0x001afad0 LAB_001afdb9: LEA RDI,[RSP + 0x30] LEA RSI,[RSP + 0x28] LEA RDX,[RSP + 0x8] CALL 0x001afe8c LAB_001afdcd: LEA RDI,[RSP + 0x30] MOV EDX,0x20 MOV RSI,RBX MOV ECX,0x1 CALL 0x001aee4e LAB_001afde4: LEA RDI,[RSP + 0x30] CALL 0x001aeb6c LEA RDI,[RSP + 0x8] CALL 0x001aeb6c LEA RDI,[RSP + 0x28] CALL 0x001aeb6c LEA RDI,[RSP + 0x18] CALL 0x001aeb6c LEA RDI,[RSP + 0x10] CALL 0x001aeb6c LEA RDI,[RSP + 0x20] CALL 0x001aeb6c MOV RAX,RBX ADD RSP,0x38 POP RBX POP R14 RET
/* Acore::Crypto::SRP6::_B(BigNumber const&, BigNumber const&) */ SRP6 * __thiscall Acore::Crypto::SRP6::_B(SRP6 *this,BigNumber *param_1,BigNumber *param_2) { BigNumber local_40 [8]; BigNumber local_38 [8]; BigNumber local_30 [8]; BigNumber local_28 [8]; BigNumber local_20 [8]; BigNumber local_18 [8]; BigNumber::ModExp(local_28,(BigNumber *)&_g); /* try { // try from 001afd6e to 001afd7c has its CatchHandler @ 001afe86 */ BigNumber::BigNumber(local_38,3); /* try { // try from 001afd7d to 001afd8e has its CatchHandler @ 001afe67 */ BigNumber::operator*(local_30,param_2); /* try { // try from 001afd8f to 001afda2 has its CatchHandler @ 001afe58 */ BigNumber::operator+(local_20,local_28); /* try { // try from 001afda3 to 001afdb8 has its CatchHandler @ 001afe49 */ BigNumber::BigNumber<32ul>(local_40,(array *)N,true); /* try { // try from 001afdb9 to 001afdcc has its CatchHandler @ 001afe3a */ BigNumber::operator%(local_18,local_20); /* try { // try from 001afdcd to 001afde3 has its CatchHandler @ 001afe2b */ BigNumber::GetBytes(local_18,(uchar *)this,0x20,true); BigNumber::~BigNumber(local_18); BigNumber::~BigNumber(local_40); BigNumber::~BigNumber(local_20); BigNumber::~BigNumber(local_30); BigNumber::~BigNumber(local_38); BigNumber::~BigNumber(local_28); return this; }
3,528
tree_walk_left_root_right
eloqsql/mysys/tree.c
static int tree_walk_left_root_right(TREE *tree, TREE_ELEMENT *element, tree_walk_action action, void *argument) { int error; if (element->left) /* Not null_element */ { if ((error=tree_walk_left_root_right(tree,element->left,action, argument)) == 0 && (error=(*action)(ELEMENT_KEY(tree,element), (element_count) element->count, argument)) == 0) error=tree_walk_left_root_right(tree,element->right,action,argument); return error; } return 0; }
O3
c
tree_walk_left_root_right: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %rsi, %r12 movq (%rsi), %rsi xorl %eax, %eax testq %rsi, %rsi je 0xa6299 movq %rcx, %r14 movq %rdx, %r15 movq %rdi, %r13 movl $0x7fffffff, %ebx # imm = 0x7FFFFFFF movq %r13, %rdi movq %r15, %rdx movq %r14, %rcx callq 0xa6227 testl %eax, %eax jne 0xa6299 movl 0x208(%r13), %edi testq %rdi, %rdi je 0xa6273 addq %r12, %rdi jmp 0xa6278 movq 0x18(%r12), %rdi movl 0x10(%r12), %esi andl %ebx, %esi movq %r14, %rdx callq *%r15 testl %eax, %eax jne 0xa6299 movq 0x8(%r12), %r12 movq (%r12), %rsi testq %rsi, %rsi jne 0xa6250 xorl %eax, %eax addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
tree_walk_left_root_right: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx push rax mov r12, rsi mov rsi, [rsi] xor eax, eax test rsi, rsi jz short loc_A6299 mov r14, rcx mov r15, rdx mov r13, rdi mov ebx, 7FFFFFFFh loc_A6250: mov rdi, r13 mov rdx, r15 mov rcx, r14 call tree_walk_left_root_right test eax, eax jnz short loc_A6299 mov edi, [r13+208h] test rdi, rdi jz short loc_A6273 add rdi, r12 jmp short loc_A6278 loc_A6273: mov rdi, [r12+18h] loc_A6278: mov esi, [r12+10h] and esi, ebx mov rdx, r14 call r15 test eax, eax jnz short loc_A6299 mov r12, [r12+8] mov rsi, [r12] test rsi, rsi jnz short loc_A6250 xor eax, eax loc_A6299: add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long tree_walk_left_root_right( long long a1, long long *a2, long long ( *a3)(long long *, long long, long long), long long a4) { long long *v4; // r12 long long v5; // rsi long long result; // rax long long *v10; // rdi v4 = a2; v5 = *a2; result = 0LL; if ( v5 ) { while ( 1 ) { result = tree_walk_left_root_right(a1, v5, a3, a4); if ( (_DWORD)result ) break; v10 = *(_DWORD *)(a1 + 520) ? (long long *)((char *)v4 + *(unsigned int *)(a1 + 520)) : (long long *)v4[3]; result = a3(v10, v4[2] & 0x7FFFFFFF, a4); if ( (_DWORD)result ) break; v4 = (long long *)v4[1]; v5 = *v4; if ( !*v4 ) return 0LL; } } return result; }
tree_walk_left_root_right: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R12,RSI MOV RSI,qword ptr [RSI] XOR EAX,EAX TEST RSI,RSI JZ 0x001a6299 MOV R14,RCX MOV R15,RDX MOV R13,RDI MOV EBX,0x7fffffff LAB_001a6250: MOV RDI,R13 MOV RDX,R15 MOV RCX,R14 CALL 0x001a6227 TEST EAX,EAX JNZ 0x001a6299 MOV EDI,dword ptr [R13 + 0x208] TEST RDI,RDI JZ 0x001a6273 ADD RDI,R12 JMP 0x001a6278 LAB_001a6273: MOV RDI,qword ptr [R12 + 0x18] LAB_001a6278: MOV ESI,dword ptr [R12 + 0x10] AND ESI,EBX MOV RDX,R14 CALL R15 TEST EAX,EAX JNZ 0x001a6299 MOV R12,qword ptr [R12 + 0x8] MOV RSI,qword ptr [R12] TEST RSI,RSI JNZ 0x001a6250 XOR EAX,EAX LAB_001a6299: ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 tree_walk_left_root_right(long param_1,long *param_2,code *param_3,int8 param_4) { int8 uVar1; long lVar2; lVar2 = *param_2; while( true ) { if (lVar2 == 0) { return 0; } uVar1 = tree_walk_left_root_right(param_1,lVar2,param_3,param_4); if ((int)uVar1 != 0) break; if ((ulong)*(uint *)(param_1 + 0x208) == 0) { lVar2 = param_2[3]; } else { lVar2 = (ulong)*(uint *)(param_1 + 0x208) + (long)param_2; } uVar1 = (*param_3)(lVar2,*(uint *)(param_2 + 2) & 0x7fffffff,param_4); if ((int)uVar1 != 0) { return uVar1; } param_2 = (long *)param_2[1]; lVar2 = *param_2; } return uVar1; }
3,529
end_pagecache
eloqsql/storage/maria/ma_pagecache.c
void end_pagecache(PAGECACHE *pagecache, my_bool cleanup) { DBUG_ENTER("end_pagecache"); DBUG_PRINT("enter", ("key_cache: %p", pagecache)); if (!pagecache->inited) DBUG_VOID_RETURN; if (pagecache->disk_blocks > 0) { #ifndef DBUG_OFF check_pagecache_is_cleaned_up(pagecache); #endif if (pagecache->block_mem) { my_large_free(pagecache->block_mem, pagecache->mem_size); pagecache->block_mem= NULL; my_free(pagecache->block_root); pagecache->block_root= NULL; } pagecache->disk_blocks= -1; /* Reset blocks_changed to be safe if flush_all_key_blocks is called */ pagecache->blocks_changed= 0; } DBUG_PRINT("status", ("used: %zu changed: %zu w_requests: %llu " "writes: %llu r_requests: %llu reads: %llu", pagecache->blocks_used, pagecache->global_blocks_changed, pagecache->global_cache_w_requests, pagecache->global_cache_write, pagecache->global_cache_r_requests, pagecache->global_cache_read)); if (cleanup) { my_hash_free(&pagecache->files_in_flush); mysql_mutex_destroy(&pagecache->cache_lock); pagecache->inited= pagecache->can_be_used= 0; PAGECACHE_DEBUG_CLOSE; } DBUG_VOID_RETURN; }
O3
c
end_pagecache: cmpb $0x0, 0x1a8(%rdi) je 0x3a0ac pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movl %esi, %r14d movq %rdi, %rbx cmpq $0x0, 0x40(%rdi) jle 0x3a050 movq 0xb0(%rbx), %rdi testq %rdi, %rdi je 0x3a040 movq (%rbx), %rsi callq 0xa7ea7 xorl %r15d, %r15d movq %r15, 0xb0(%rbx) movq 0xa8(%rbx), %rdi callq 0x9ff6e movq %r15, 0xa8(%rbx) movq $-0x1, 0x40(%rbx) movq $0x0, 0x58(%rbx) testb %r14b, %r14b je 0x3a0a2 leaq 0x1b0(%rbx), %rdi callq 0x939dd leaq 0xc8(%rbx), %r14 movq 0x108(%rbx), %rdi testq %rdi, %rdi je 0x3a08c leaq 0x34bf95(%rip), %rax # 0x386010 movq (%rax), %rax callq *0x48(%rax) movq $0x0, 0x108(%rbx) movq %r14, %rdi callq 0x290c0 xorl %eax, %eax movb %al, 0x1aa(%rbx) movb %al, 0x1a8(%rbx) addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
end_pagecache: cmp byte ptr [rdi+1A8h], 0 jz locret_3A0AC push rbp mov rbp, rsp push r15 push r14 push rbx push rax mov r14d, esi mov rbx, rdi cmp qword ptr [rdi+40h], 0 jle short loc_3A050 mov rdi, [rbx+0B0h] test rdi, rdi jz short loc_3A040 mov rsi, [rbx] call my_large_free xor r15d, r15d mov [rbx+0B0h], r15 mov rdi, [rbx+0A8h] call my_free mov [rbx+0A8h], r15 loc_3A040: mov qword ptr [rbx+40h], 0FFFFFFFFFFFFFFFFh mov qword ptr [rbx+58h], 0 loc_3A050: test r14b, r14b jz short loc_3A0A2 lea rdi, [rbx+1B0h] call my_hash_free lea r14, [rbx+0C8h] mov rdi, [rbx+108h] test rdi, rdi jz short loc_3A08C lea rax, PSI_server mov rax, [rax] call qword ptr [rax+48h] mov qword ptr [rbx+108h], 0 loc_3A08C: mov rdi, r14 call _pthread_mutex_destroy xor eax, eax mov [rbx+1AAh], al mov [rbx+1A8h], al loc_3A0A2: add rsp, 8 pop rbx pop r14 pop r15 pop rbp locret_3A0AC: retn
long long end_pagecache(long long a1, char a2) { long long v3; // rdi long long result; // rax long long v5; // rdi if ( *(_BYTE *)(a1 + 424) ) { if ( *(long long *)(a1 + 64) > 0 ) { v3 = *(_QWORD *)(a1 + 176); if ( v3 ) { my_large_free(v3, *(_QWORD *)a1); *(_QWORD *)(a1 + 176) = 0LL; result = my_free(*(_QWORD *)(a1 + 168)); *(_QWORD *)(a1 + 168) = 0LL; } *(_QWORD *)(a1 + 64) = -1LL; *(_QWORD *)(a1 + 88) = 0LL; } if ( a2 ) { my_hash_free(a1 + 432); v5 = *(_QWORD *)(a1 + 264); if ( v5 ) { ((void ( *)(long long))PSI_server[9])(v5); *(_QWORD *)(a1 + 264) = 0LL; } pthread_mutex_destroy(a1 + 200); result = 0LL; *(_BYTE *)(a1 + 426) = 0; *(_BYTE *)(a1 + 424) = 0; } } return result; }
end_pagecache: CMP byte ptr [RDI + 0x1a8],0x0 JZ 0x0013a0ac PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV R14D,ESI MOV RBX,RDI CMP qword ptr [RDI + 0x40],0x0 JLE 0x0013a050 MOV RDI,qword ptr [RBX + 0xb0] TEST RDI,RDI JZ 0x0013a040 MOV RSI,qword ptr [RBX] CALL 0x001a7ea7 XOR R15D,R15D MOV qword ptr [RBX + 0xb0],R15 MOV RDI,qword ptr [RBX + 0xa8] CALL 0x0019ff6e MOV qword ptr [RBX + 0xa8],R15 LAB_0013a040: MOV qword ptr [RBX + 0x40],-0x1 MOV qword ptr [RBX + 0x58],0x0 LAB_0013a050: TEST R14B,R14B JZ 0x0013a0a2 LEA RDI,[RBX + 0x1b0] CALL 0x001939dd LEA R14,[RBX + 0xc8] MOV RDI,qword ptr [RBX + 0x108] TEST RDI,RDI JZ 0x0013a08c LEA RAX,[0x486010] MOV RAX,qword ptr [RAX] CALL qword ptr [RAX + 0x48] MOV qword ptr [RBX + 0x108],0x0 LAB_0013a08c: MOV RDI,R14 CALL 0x001290c0 XOR EAX,EAX MOV byte ptr [RBX + 0x1aa],AL MOV byte ptr [RBX + 0x1a8],AL LAB_0013a0a2: ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP LAB_0013a0ac: RET
void end_pagecache(int8 *param_1,char param_2) { if (*(char *)(param_1 + 0x35) != '\0') { if (0 < (long)param_1[8]) { if (param_1[0x16] != 0) { my_large_free(param_1[0x16],*param_1); param_1[0x16] = 0; my_free(param_1[0x15]); param_1[0x15] = 0; } param_1[8] = 0xffffffffffffffff; param_1[0xb] = 0; } if (param_2 != '\0') { my_hash_free(param_1 + 0x36); if (param_1[0x21] != 0) { (**(code **)(PSI_server + 0x48))(); param_1[0x21] = 0; } pthread_mutex_destroy((pthread_mutex_t *)(param_1 + 0x19)); *(int1 *)((long)param_1 + 0x1aa) = 0; *(int1 *)(param_1 + 0x35) = 0; } } return; }
3,530
directory_file_name
eloqsql/mysys/my_lib.c
static char *directory_file_name (char * dst, const char *src) { /* Process as Unix format: just remove test the final slash. */ char *end; DBUG_ASSERT(strlen(src) < (FN_REFLEN + 1)); if (src[0] == 0) src= (char*) "."; /* Use empty as current */ end= strnmov(dst, src, FN_REFLEN + 1); if (end[-1] != FN_LIBCHAR) { *end++= FN_LIBCHAR; /* Add last '/' */ *end='\0'; } return end; }
O0
c
directory_file_name: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) jmp 0x2f362 movq -0x10(%rbp), %rax movsbl (%rax), %eax cmpl $0x0, %eax jne 0x2f379 leaq 0x4af98(%rip), %rax # 0x7a30d movq %rax, -0x10(%rbp) movq -0x8(%rbp), %rdi movq -0x10(%rbp), %rsi movl $0x201, %edx # imm = 0x201 callq 0x77560 movq %rax, -0x18(%rbp) movq -0x18(%rbp), %rax movsbl -0x1(%rax), %eax cmpl $0x2f, %eax je 0x2f3b5 movq -0x18(%rbp), %rax movq %rax, %rcx addq $0x1, %rcx movq %rcx, -0x18(%rbp) movb $0x2f, (%rax) movq -0x18(%rbp), %rax movb $0x0, (%rax) movq -0x18(%rbp), %rax addq $0x20, %rsp popq %rbp retq nop
directory_file_name: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_8], rdi mov [rbp+var_10], rsi jmp short $+2 loc_2F362: mov rax, [rbp+var_10] movsx eax, byte ptr [rax] cmp eax, 0 jnz short loc_2F379 lea rax, asc_7A30C+1; "." mov [rbp+var_10], rax loc_2F379: mov rdi, [rbp+var_8] mov rsi, [rbp+var_10] mov edx, 201h call strnmov mov [rbp+var_18], rax mov rax, [rbp+var_18] movsx eax, byte ptr [rax-1] cmp eax, 2Fh ; '/' jz short loc_2F3B5 mov rax, [rbp+var_18] mov rcx, rax add rcx, 1 mov [rbp+var_18], rcx mov byte ptr [rax], 2Fh ; '/' mov rax, [rbp+var_18] mov byte ptr [rax], 0 loc_2F3B5: mov rax, [rbp+var_18] add rsp, 20h pop rbp retn
_BYTE * directory_file_name(long long a1, char *a2) { _BYTE *v2; // rax _BYTE *v4; // [rsp+8h] [rbp-18h] char *v5; // [rsp+10h] [rbp-10h] v5 = a2; if ( !*a2 ) v5 = "."; v4 = (_BYTE *)strnmov(a1, v5, 513LL); if ( *(v4 - 1) != 47 ) { v2 = v4++; *v2 = 47; *v4 = 0; } return v4; }
directory_file_name: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI JMP 0x0012f362 LAB_0012f362: MOV RAX,qword ptr [RBP + -0x10] MOVSX EAX,byte ptr [RAX] CMP EAX,0x0 JNZ 0x0012f379 LEA RAX,[0x17a30d] MOV qword ptr [RBP + -0x10],RAX LAB_0012f379: MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x10] MOV EDX,0x201 CALL 0x00177560 MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x18] MOVSX EAX,byte ptr [RAX + -0x1] CMP EAX,0x2f JZ 0x0012f3b5 MOV RAX,qword ptr [RBP + -0x18] MOV RCX,RAX ADD RCX,0x1 MOV qword ptr [RBP + -0x18],RCX MOV byte ptr [RAX],0x2f MOV RAX,qword ptr [RBP + -0x18] MOV byte ptr [RAX],0x0 LAB_0012f3b5: MOV RAX,qword ptr [RBP + -0x18] ADD RSP,0x20 POP RBP RET
int1 * directory_file_name(int8 param_1,char *param_2) { int1 *puVar1; int1 *local_20; char *local_18; local_18 = param_2; if (*param_2 == '\0') { local_18 = "."; } puVar1 = (int1 *)strnmov(param_1,local_18,0x201); local_20 = puVar1; if (puVar1[-1] != '/') { local_20 = puVar1 + 1; *puVar1 = 0x2f; *local_20 = 0; } return local_20; }
3,531
common_chat_params_init_command_r7b(minja::chat_template const&, common_chat_inputs const&)
monkey531[P]llama/common/chat.cpp
static common_chat_params common_chat_params_init_command_r7b(const common_chat_template & tmpl, const struct common_chat_inputs & inputs) { common_chat_params data; data.grammar_lazy = inputs.tool_choice != "required"; data.grammar = build_grammar([&](const common_grammar_builder & builder) { auto schemas = json::array(); foreach_function(inputs.tools, [&](const json & tool) { const auto & function = tool["function"]; schemas.push_back({ {"type", "object"}, {"properties", { {"tool_call_id", { {"type", "string"}, // Command-R's template expects an integer string. {"pattern", "^[0-9]{1,10}$"}, }}, {"tool_name", { {"type", "string"}, {"const", function["name"]}, }}, {"parameters", function["parameters"]}, }}, {"required", json::array({"tool_call_id", "tool_name", "parameters"})}, }); }); auto schema = json { {"type", "array"}, {"items", schemas.size() == 1 ? schemas[0] : json {{"anyOf", schemas}}}, {"minItems", 1}, }; if (!inputs.parallel_tool_calls) { schema["maxItems"] = 1; } builder.add_rule("root", "\"<|START_ACTION|>\" " + builder.add_schema("tool_calls", schema) + " \"<|END_ACTION|>\""); }, grammar_options); data.grammar_triggers.push_back({"<|START_ACTION|>", /* .at_start = */ false}); data.preserved_tokens = { "<|START_RESPONSE|>", "<|END_RESPONSE|>", "<|START_THINKING|>", "<|END_THINKING|>", "<|END_ACTION|>", }; data.prompt = tmpl.apply(inputs.messages, inputs.tools.empty() ? json() : inputs.tools, inputs.add_generation_prompt); data.format = COMMON_CHAT_FORMAT_COMMAND_R7B; return data; }
O3
cpp
common_chat_params_init_command_r7b(minja::chat_template const&, common_chat_inputs const&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xe8, %rsp movq %rdx, %r14 movq %rsi, %rbp movq %rdi, %rbx movl $0x0, (%rdi) xorl %r15d, %r15d movb %r15b, 0x8(%rdi) movq %r15, 0x10(%rdi) leaq 0x28(%rdi), %rax movq %rax, 0x18(%rdi) movq %r15, 0x20(%rdi) movb %r15b, 0x28(%rdi) movb %r15b, 0x38(%rdi) xorps %xmm0, %xmm0 movups %xmm0, 0x40(%rdi) movups %xmm0, 0x50(%rdi) movups %xmm0, 0x60(%rdi) movups %xmm0, 0x70(%rdi) movq %r15, 0x80(%rdi) leaq 0x20(%rdx), %rdi leaq 0x1f94f(%rip), %rsi # 0x114d51 callq 0xc9159 movb %al, 0x38(%rbx) leaq 0x8(%rsp), %rsi movq %r15, 0x8(%rsi) movq %r14, (%rsi) leaq 0xe49d(%rip), %rax # 0x1038ba movq %rax, 0x18(%rsi) leaq 0xed12(%rip), %rax # 0x10413a movq %rax, 0x10(%rsi) leaq 0x2581d(%rip), %rdx # 0x11ac50 leaq 0x38(%rsp), %rdi callq 0xdf158 leaq 0x18(%rbx), %rdi leaq 0x38(%rsp), %r12 movq %r12, %rsi callq 0x1dee0 movq (%r12), %rdi leaq 0x48(%rsp), %r15 cmpq %r15, %rdi je 0xf5469 movq 0x48(%rsp), %rsi incq %rsi callq 0x1dc50 movq 0x18(%rsp), %rax testq %rax, %rax je 0xf5482 leaq 0x8(%rsp), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax leaq 0x38(%rsp), %rdi movq %r15, (%rdi) leaq 0x268ab(%rip), %rsi # 0x11bd3c leaq 0x268b4(%rip), %rdx # 0x11bd4c callq 0x26926 leaq 0x40(%rbx), %rdi leaq 0x38(%rsp), %rsi movb $0x0, 0x20(%rsi) callq 0x107e8c movq 0x38(%rsp), %rdi cmpq %r15, %rdi je 0xf54c6 movq 0x48(%rsp), %rsi incq %rsi callq 0x1dc50 leaq 0x38(%rsp), %r12 movq %r15, (%r12) leaq 0x26d31(%rip), %rsi # 0x11c207 leaq 0x26d3c(%rip), %rdx # 0x11c219 movq %r12, %rdi callq 0x26926 leaq 0x58(%rsp), %r13 leaq 0x68(%rsp), %rax movq %rax, -0x10(%rax) leaq 0x26d20(%rip), %rsi # 0x11c21a leaq 0x26d29(%rip), %rdx # 0x11c22a movq %r13, %rdi callq 0x26926 leaq 0x78(%rsp), %r13 leaq 0x88(%rsp), %rax movq %rax, -0x10(%rax) leaq 0x26d0a(%rip), %rsi # 0x11c22b leaq 0x26d15(%rip), %rdx # 0x11c23d movq %r13, %rdi callq 0x26926 leaq 0x98(%rsp), %r13 leaq 0xa8(%rsp), %rax movq %rax, -0x10(%rax) leaq 0x26cf3(%rip), %rsi # 0x11c23e leaq 0x26cfc(%rip), %rdx # 0x11c24e movq %r13, %rdi callq 0x26926 leaq 0xb8(%rsp), %r13 leaq 0xc8(%rsp), %r15 movq %r15, -0x10(%r15) leaq 0x26cda(%rip), %rsi # 0x11c24f leaq 0x26ce1(%rip), %rdx # 0x11c25d movq %r13, %rdi callq 0x26926 leaq 0x58(%rbx), %rdi leaq 0xd8(%rsp), %r12 leaq 0x38(%rsp), %rsi movq %r12, %rdx callq 0x10826e movq $-0xa0, %r12 movq -0x10(%r15), %rdi cmpq %rdi, %r15 je 0xf55b8 movq (%r15), %rsi incq %rsi callq 0x1dc50 addq $-0x20, %r15 addq $0x20, %r12 jne 0xf55a4 movzbl 0x10(%r14), %eax testl %eax, %eax leaq 0x48(%rsp), %r15 je 0xf55f7 cmpl $0x2, %eax je 0xf55da cmpl $0x1, %eax jne 0xf55e7 movq 0x18(%r14), %rax movq (%rax), %rcx cmpq 0x8(%rax), %rcx je 0xf55f7 leaq 0x10(%r14), %rsi leaq 0x8(%rsp), %rdi callq 0x8e664 jmp 0xf5605 movb $0x0, 0x8(%rsp) movq $0x0, 0x10(%rsp) movzbl 0x68(%r14), %r8d leaq 0x28(%rsp), %r9 movb $0x0, (%r9) movq $0x0, 0x8(%r9) movl $0x1, (%rsp) leaq 0x38(%rsp), %rdi leaq 0x8(%rsp), %rcx movq %rbp, %rsi movq %r14, %rdx callq 0xc5878 leaq 0xd8(%rsp), %rdi leaq 0x38(%rsp), %rsi callq 0xa3c0a movb 0x8(%rbx), %al leaq 0xd8(%rsp), %rdi movb (%rdi), %cl movb %cl, 0x8(%rbx) movb %al, (%rdi) movq 0x10(%rbx), %rax movq 0x8(%rdi), %rcx movq %rcx, 0x10(%rbx) movq %rax, 0x8(%rdi) callq 0x8eb30 movq 0x38(%rsp), %rdi cmpq %r15, %rdi je 0xf5687 movq 0x48(%rsp), %rsi incq %rsi callq 0x1dc50 leaq 0x28(%rsp), %rdi callq 0x8eb30 leaq 0x8(%rsp), %rdi callq 0x8eb30 movl $0xa, (%rbx) addq $0xe8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq jmp 0xf5756 jmp 0xf5787 movq %rax, %r14 movq 0x38(%rsp), %rdi cmpq %r15, %rdi je 0xf56dc movq 0x48(%rsp), %rsi incq %rsi callq 0x1dc50 jmp 0xf56dc movq %rax, %r14 leaq 0x28(%rsp), %rdi callq 0x8eb30 leaq 0x8(%rsp), %rdi callq 0x8eb30 jmp 0xf5759 movq %rax, %r14 leaq 0x38(%rsp), %rsi movq %r12, %rdi callq 0x20521 jmp 0xf5759 jmp 0xf570a jmp 0xf570a jmp 0xf570a movq %rax, %r14 addq $-0x10, %r13 movq -0x10(%r13), %rdi cmpq %rdi, %r13 je 0xf5726 movq (%r13), %rsi incq %rsi callq 0x1dc50 leaq -0x20(%r13), %rax addq $-0x10, %r13 cmpq %r12, %r13 movq %rax, %r13 jne 0xf5711 jmp 0xf5759 jmp 0xf5756 movq %rax, %r14 movq 0x38(%rsp), %rdi cmpq %r15, %rdi je 0xf5759 movq 0x48(%rsp), %rsi incq %rsi callq 0x1dc50 jmp 0xf5759 movq %rax, %r14 movq %rbx, %rdi callq 0xa273c movq %r14, %rdi callq 0x1e660 movq %rax, %r14 movq 0x18(%rsp), %rax testq %rax, %rax je 0xf5759 leaq 0x8(%rsp), %rdi movq %rdi, %rsi movl $0x3, %edx callq *%rax jmp 0xf5759 movq %rax, %rdi callq 0x26531
_ZL35common_chat_params_init_command_r7bRKN5minja13chat_templateERK18common_chat_inputs: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0E8h mov r14, rdx mov rbp, rsi mov rbx, rdi mov dword ptr [rdi], 0 xor r15d, r15d mov [rdi+8], r15b mov [rdi+10h], r15 lea rax, [rdi+28h] mov [rdi+18h], rax mov [rdi+20h], r15 mov [rdi+28h], r15b mov [rdi+38h], r15b xorps xmm0, xmm0 movups xmmword ptr [rdi+40h], xmm0 movups xmmword ptr [rdi+50h], xmm0 movups xmmword ptr [rdi+60h], xmm0 movups xmmword ptr [rdi+70h], xmm0 mov [rdi+80h], r15 lea rdi, [rdx+20h] lea rsi, aRequired; "required" call _ZN8nlohmann16json_abi_v3_11_3neIPKcTnNSt9enable_ifIXsr3std9is_scalarIT_EE5valueEiE4typeELi0EEEbRKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerESA_IhSaIhEEvEES5_ mov [rbx+38h], al lea rsi, [rsp+118h+var_110] mov [rsi+8], r15 mov [rsi], r14 lea rax, _ZNSt17_Function_handlerIFvRK22common_grammar_builderEZL35common_chat_params_init_command_r7bRKN5minja13chat_templateERK18common_chat_inputsE3$_0E9_M_invokeERKSt9_Any_dataS2_; std::_Function_handler<void ()(common_grammar_builder const&),common_chat_params_init_command_r7b(minja::chat_template const&,common_chat_inputs const&)::$_0>::_M_invoke(std::_Any_data const&,common_grammar_builder const&) mov [rsi+18h], rax lea rax, _ZNSt17_Function_handlerIFvRK22common_grammar_builderEZL35common_chat_params_init_command_r7bRKN5minja13chat_templateERK18common_chat_inputsE3$_0E10_M_managerERSt9_Any_dataRKSD_St18_Manager_operation; std::_Function_handler<void ()(common_grammar_builder const&),common_chat_params_init_command_r7b(minja::chat_template const&,common_chat_inputs const&)::$_0>::_M_manager(std::_Any_data &,std::_Any_data const&,std::_Manager_operation) mov [rsi+10h], rax lea rdx, _ZL15grammar_options; grammar_options lea rdi, [rsp+118h+var_E0] call _Z13build_grammarB5cxx11RKSt8functionIFvRK22common_grammar_builderEERK22common_grammar_options; build_grammar(std::function<void ()(common_grammar_builder const&)> const&,common_grammar_options const&) lea rdi, [rbx+18h] lea r12, [rsp+118h+var_E0] mov rsi, r12 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_; std::string::operator=(std::string&&) mov rdi, [r12]; void * lea r15, [rsp+118h+var_D0] cmp rdi, r15 jz short loc_F5469 mov rsi, [rsp+118h+var_D0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_F5469: mov rax, [rsp+118h+var_100] test rax, rax jz short loc_F5482 lea rdi, [rsp+118h+var_110] mov rsi, rdi mov edx, 3 call rax loc_F5482: lea rdi, [rsp+118h+var_E0] mov [rdi], r15 lea rsi, aEndThinkingSta+10h; "<|START_ACTION|>" lea rdx, aEndThinkingSta+20h; "" call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) lea rdi, [rbx+40h] lea rsi, [rsp+118h+var_E0] mov byte ptr [rsi+20h], 0 call _ZNSt6vectorI22common_grammar_triggerSaIS0_EE12emplace_backIJS0_EEERS0_DpOT_; std::vector<common_grammar_trigger>::emplace_back<common_grammar_trigger>(common_grammar_trigger &&) mov rdi, [rsp+118h+var_E0]; void * cmp rdi, r15 jz short loc_F54C6 mov rsi, [rsp+118h+var_D0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_F54C6: lea r12, [rsp+118h+var_E0] mov [r12], r15 lea rsi, aStartResponse; "<|START_RESPONSE|>" lea rdx, aStartResponse+12h; "" 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) lea r13, [rsp+118h+var_C0] lea rax, [rsp+118h+var_B0] mov [rax-10h], rax lea rsi, aEndResponse; "<|END_RESPONSE|>" lea rdx, aEndResponse+10h; "" mov rdi, r13 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) lea r13, [rsp+118h+var_A0] lea rax, [rsp+118h+var_90] mov [rax-10h], rax lea rsi, aStartThinking; "<|START_THINKING|>" lea rdx, aStartThinking+12h; "" mov rdi, r13 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) lea r13, [rsp+118h+var_80] lea rax, [rsp+118h+var_70] mov [rax-10h], rax lea rsi, aEndThinking; "<|END_THINKING|>" lea rdx, aEndThinking+10h; "" mov rdi, r13 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) lea r13, [rsp+118h+var_60] lea r15, [rsp+118h+var_50] mov [r15-10h], r15 lea rsi, aEndAction; "<|END_ACTION|>" lea rdx, aEndAction+0Eh; "" mov rdi, r13 call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPKcEEvT_S8_St20forward_iterator_tag; std::string::_M_construct<char const*>(char const*,char const*,std::forward_iterator_tag) lea rdi, [rbx+58h] lea r12, [rsp+118h+var_40] lea rsi, [rsp+118h+var_E0] mov rdx, r12 call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE13_M_assign_auxIPKS5_EEvT_SB_St20forward_iterator_tag; std::vector<std::string>::_M_assign_aux<std::string const*>(std::string const*,std::string const*,std::forward_iterator_tag) mov r12, 0FFFFFFFFFFFFFF60h loc_F55A4: mov rdi, [r15-10h]; void * cmp r15, rdi jz short loc_F55B8 mov rsi, [r15] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_F55B8: add r15, 0FFFFFFFFFFFFFFE0h add r12, 20h ; ' ' jnz short loc_F55A4 movzx eax, byte ptr [r14+10h] test eax, eax lea r15, [rsp+118h+var_D0] jz short loc_F55F7 cmp eax, 2 jz short loc_F55DA cmp eax, 1 jnz short loc_F55E7 loc_F55DA: mov rax, [r14+18h] mov rcx, [rax] cmp rcx, [rax+8] jz short loc_F55F7 loc_F55E7: lea rsi, [r14+10h] lea rdi, [rsp+118h+var_110] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2ERKSD_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::basic_json(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&) jmp short loc_F5605 loc_F55F7: mov [rsp+118h+var_110], 0 mov [rsp+118h+var_108], 0 loc_F5605: movzx r8d, byte ptr [r14+68h] lea r9, [rsp+118h+var_F0] mov byte ptr [r9], 0 mov qword ptr [r9+8], 0 mov [rsp+118h+var_118], 1 lea rdi, [rsp+118h+var_E0] lea rcx, [rsp+118h+var_110] mov rsi, rbp mov rdx, r14 call _ZNK5minja13chat_template5applyERKN8nlohmann16json_abi_v3_11_310basic_jsonINS2_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS2_14adl_serializerES5_IhSaIhEEvEESH_bSH_b; minja::chat_template::apply(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,bool,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,bool) lea rdi, [rsp+118h+var_40] lea rsi, [rsp+118h+var_E0] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IS9_S9_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SG_EE5valueEiE4typeELi0EEEOT_ mov al, [rbx+8] lea rdi, [rsp+118h+var_40] mov cl, [rdi] mov [rbx+8], cl mov [rdi], al mov rax, [rbx+10h] mov rcx, [rdi+8] mov [rbx+10h], rcx mov [rdi+8], rax 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, [rsp+118h+var_E0]; void * cmp rdi, r15 jz short loc_F5687 mov rsi, [rsp+118h+var_D0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_F5687: lea rdi, [rsp+118h+var_F0] 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() lea rdi, [rsp+118h+var_110] 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 dword ptr [rbx], 0Ah add rsp, 0E8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn jmp loc_F5756 jmp loc_F5787 mov r14, rax mov rdi, [rsp+118h+var_E0]; void * cmp rdi, r15 jz short loc_F56DC mov rsi, [rsp+118h+var_D0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_F56DC mov r14, rax loc_F56DC: lea rdi, [rsp+118h+var_F0] 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() lea rdi, [rsp+118h+var_110] call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4dataD2Ev; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::data::~data() jmp short loc_F5759 mov r14, rax lea rsi, [rsp+118h+var_E0] mov rdi, r12 call _ZL35common_chat_params_init_command_r7bRKN5minja13chat_templateERK18common_chat_inputs_cold_1; common_chat_params_init_command_r7b(minja::chat_template const&,common_chat_inputs const&) [clone] jmp short loc_F5759 jmp short loc_F570A jmp short loc_F570A jmp short $+2 loc_F570A: mov r14, rax add r13, 0FFFFFFFFFFFFFFF0h loc_F5711: mov rdi, [r13-10h]; void * cmp r13, rdi jz short loc_F5726 mov rsi, [r13+0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_F5726: lea rax, [r13-20h] add r13, 0FFFFFFFFFFFFFFF0h cmp r13, r12 mov r13, rax jnz short loc_F5711 jmp short loc_F5759 jmp short loc_F5756 mov r14, rax mov rdi, [rsp+118h+var_E0]; void * cmp rdi, r15 jz short loc_F5759 mov rsi, [rsp+118h+var_D0] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_F5759 loc_F5756: mov r14, rax loc_F5759: mov rdi, rbx; this call _ZN18common_chat_paramsD2Ev; common_chat_params::~common_chat_params() mov rdi, r14 call __Unwind_Resume mov r14, rax mov rax, [rsp+118h+var_100] test rax, rax jz short loc_F5759 lea rdi, [rsp+118h+var_110] mov rsi, rdi mov edx, 3 call rax jmp short loc_F5759 loc_F5787: mov rdi, rax call __clang_call_terminate
long long common_chat_params_init_command_r7b( const minja::chat_template *a1, const common_chat_inputs *a2, long long a3) { long long v5; // rcx int v6; // r8d int v7; // r9d _QWORD *v8; // r15 long long v9; // r12 _QWORD *v10; // rdi int v11; // eax int v12; // r8d char v13; // al long long v14; // rax long long result; // rax long long v16; // [rsp+8h] [rbp-110h] BYREF long long v17; // [rsp+10h] [rbp-108h] long long ( *v18)(); // [rsp+18h] [rbp-100h] long long ( *v19)(); // [rsp+20h] [rbp-F8h] _BYTE v20[8]; // [rsp+28h] [rbp-F0h] BYREF long long v21; // [rsp+30h] [rbp-E8h] void *v22[2]; // [rsp+38h] [rbp-E0h] BYREF _QWORD v23[2]; // [rsp+48h] [rbp-D0h] BYREF char *v24; // [rsp+58h] [rbp-C0h] BYREF char v25; // [rsp+68h] [rbp-B0h] BYREF char *v26; // [rsp+78h] [rbp-A0h] BYREF char v27; // [rsp+88h] [rbp-90h] BYREF char *v28; // [rsp+98h] [rbp-80h] BYREF char v29; // [rsp+A8h] [rbp-70h] BYREF _BYTE *v30; // [rsp+B8h] [rbp-60h] BYREF _BYTE v31[16]; // [rsp+C8h] [rbp-50h] BYREF char v32[8]; // [rsp+D8h] [rbp-40h] BYREF long long v33; // [rsp+E0h] [rbp-38h] *(_DWORD *)a1 = 0; *((_BYTE *)a1 + 8) = 0; *((_QWORD *)a1 + 2) = 0LL; *((_QWORD *)a1 + 3) = (char *)a1 + 40; *((_QWORD *)a1 + 4) = 0LL; *((_BYTE *)a1 + 40) = 0; *((_BYTE *)a1 + 56) = 0; *((_OWORD *)a1 + 4) = 0LL; *((_OWORD *)a1 + 5) = 0LL; *((_OWORD *)a1 + 6) = 0LL; *((_OWORD *)a1 + 7) = 0LL; *((_QWORD *)a1 + 16) = 0LL; *((_BYTE *)a1 + 56) = ZN8nlohmann16json_abi_v3_11_3neIPKcTnNSt9enable_ifIXsr3std9is_scalarIT_EE5valueEiE4typeELi0EEEbRKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerESA_IhSaIhEEvEES5_( a3 + 32, (long long)"required"); v17 = 0LL; v16 = a3; v19 = std::_Function_handler<void ()(common_grammar_builder const&),common_chat_params_init_command_r7b(minja::chat_template const&,common_chat_inputs const&)::$_0>::_M_invoke; v18 = std::_Function_handler<void ()(common_grammar_builder const&),common_chat_params_init_command_r7b(minja::chat_template const&,common_chat_inputs const&)::$_0>::_M_manager; build_grammar[abi:cxx11]((long long)v22, (long long)&v16, grammar_options, v5, v6, v7); std::string::operator=((char *)a1 + 24, v22); if ( v22[0] != v23 ) operator delete(v22[0], v23[0] + 1LL); if ( v18 ) ((void ( *)(long long *, long long *, long long))v18)(&v16, &v16, 3LL); v22[0] = v23; std::string::_M_construct<char const*>((long long)v22, "<|START_ACTION|>", (long long)""); LOBYTE(v24) = 0; std::vector<common_grammar_trigger>::emplace_back<common_grammar_trigger>((char *)a1 + 64); if ( v22[0] != v23 ) operator delete(v22[0], v23[0] + 1LL); v22[0] = v23; std::string::_M_construct<char const*>((long long)v22, "<|START_RESPONSE|>", (long long)""); v24 = &v25; std::string::_M_construct<char const*>((long long)&v24, "<|END_RESPONSE|>", (long long)""); v26 = &v27; std::string::_M_construct<char const*>((long long)&v26, "<|START_THINKING|>", (long long)""); v28 = &v29; std::string::_M_construct<char const*>((long long)&v28, "<|END_THINKING|>", (long long)""); v8 = v31; v30 = v31; std::string::_M_construct<char const*>((long long)&v30, "<|END_ACTION|>", (long long)""); std::vector<std::string>::_M_assign_aux<std::string const*>((char *)a1 + 88, v22, v32); v9 = -160LL; do { v10 = (_QWORD *)*(v8 - 2); if ( v8 != v10 ) operator delete(v10, *v8 + 1LL); v8 -= 4; v9 += 32LL; } while ( v9 ); v11 = *(unsigned __int8 *)(a3 + 16); if ( !*(_BYTE *)(a3 + 16) || (v11 == 2 || v11 == 1) && **(_QWORD **)(a3 + 24) == *(_QWORD *)(*(_QWORD *)(a3 + 24) + 8LL) ) { LOBYTE(v16) = 0; v17 = 0LL; } else { nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::basic_json( (unsigned __int8 *)&v16, (unsigned __int8 *)(a3 + 16)); } v12 = *(unsigned __int8 *)(a3 + 104); v20[0] = 0; v21 = 0LL; minja::chat_template::apply((long long)v22, a2, (unsigned __int8 *)a3, (unsigned __int8 *)&v16, v12, v20, 1); ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IS9_S9_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SG_EE5valueEiE4typeELi0EEEOT_(v32); v13 = *((_BYTE *)a1 + 8); *((_BYTE *)a1 + 8) = v32[0]; v32[0] = v13; v14 = *((_QWORD *)a1 + 2); *((_QWORD *)a1 + 2) = v33; v33 = v14; 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(v32); if ( v22[0] != v23 ) operator delete(v22[0], v23[0] + 1LL); nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(v20); result = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::data::~data(&v16); *(_DWORD *)a1 = 10; return result; }
common_chat_params_init_command_r7b: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xe8 MOV R14,RDX MOV RBP,RSI MOV RBX,RDI MOV dword ptr [RDI],0x0 XOR R15D,R15D MOV byte ptr [RDI + 0x8],R15B MOV qword ptr [RDI + 0x10],R15 LEA RAX,[RDI + 0x28] MOV qword ptr [RDI + 0x18],RAX MOV qword ptr [RDI + 0x20],R15 MOV byte ptr [RDI + 0x28],R15B MOV byte ptr [RDI + 0x38],R15B XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI + 0x40],XMM0 MOVUPS xmmword ptr [RDI + 0x50],XMM0 MOVUPS xmmword ptr [RDI + 0x60],XMM0 MOVUPS xmmword ptr [RDI + 0x70],XMM0 MOV qword ptr [RDI + 0x80],R15 LEA RDI,[RDX + 0x20] LEA RSI,[0x214d51] CALL 0x001c9159 MOV byte ptr [RBX + 0x38],AL LEA RSI,[RSP + 0x8] MOV qword ptr [RSI + 0x8],R15 MOV qword ptr [RSI],R14 LEA RAX,[0x2038ba] MOV qword ptr [RSI + 0x18],RAX LEA RAX,[0x20413a] MOV qword ptr [RSI + 0x10],RAX LAB_001f542c: LEA RDX,[0x21ac50] LEA RDI,[RSP + 0x38] CALL 0x001df158 LEA RDI,[RBX + 0x18] LEA R12,[RSP + 0x38] MOV RSI,R12 CALL 0x0011dee0 MOV RDI,qword ptr [R12] LEA R15,[RSP + 0x48] CMP RDI,R15 JZ 0x001f5469 MOV RSI,qword ptr [RSP + 0x48] INC RSI CALL 0x0011dc50 LAB_001f5469: MOV RAX,qword ptr [RSP + 0x18] TEST RAX,RAX JZ 0x001f5482 LAB_001f5473: LEA RDI,[RSP + 0x8] MOV RSI,RDI MOV EDX,0x3 CALL RAX LAB_001f5482: LEA RDI,[RSP + 0x38] MOV qword ptr [RDI],R15 LAB_001f548a: LEA RSI,[0x21bd3c] LEA RDX,[0x21bd4c] CALL 0x00126926 LEA RDI,[RBX + 0x40] LEA RSI,[RSP + 0x38] MOV byte ptr [RSI + 0x20],0x0 LAB_001f54aa: CALL 0x00207e8c MOV RDI,qword ptr [RSP + 0x38] CMP RDI,R15 JZ 0x001f54c6 MOV RSI,qword ptr [RSP + 0x48] INC RSI CALL 0x0011dc50 LAB_001f54c6: LEA R12,[RSP + 0x38] MOV qword ptr [R12],R15 LAB_001f54cf: LEA RSI,[0x21c207] LEA RDX,[0x21c219] MOV RDI,R12 CALL 0x00126926 LEA R13,[RSP + 0x58] LEA RAX,[RSP + 0x68] MOV qword ptr [RAX + -0x10],RAX LAB_001f54f3: LEA RSI,[0x21c21a] LEA RDX,[0x21c22a] MOV RDI,R13 CALL 0x00126926 LEA R13,[RSP + 0x78] LEA RAX,[RSP + 0x88] MOV qword ptr [RAX + -0x10],RAX LAB_001f551a: LEA RSI,[0x21c22b] LEA RDX,[0x21c23d] MOV RDI,R13 CALL 0x00126926 LEA R13,[RSP + 0x98] LEA RAX,[RSP + 0xa8] MOV qword ptr [RAX + -0x10],RAX LAB_001f5544: LEA RSI,[0x21c23e] LEA RDX,[0x21c24e] MOV RDI,R13 CALL 0x00126926 LEA R13,[RSP + 0xb8] LEA R15,[RSP + 0xc8] MOV qword ptr [R15 + -0x10],R15 LAB_001f556e: LEA RSI,[0x21c24f] LEA RDX,[0x21c25d] MOV RDI,R13 CALL 0x00126926 LEA RDI,[RBX + 0x58] LEA R12,[RSP + 0xd8] LAB_001f5590: LEA RSI,[RSP + 0x38] MOV RDX,R12 CALL 0x0020826e MOV R12,-0xa0 LAB_001f55a4: MOV RDI,qword ptr [R15 + -0x10] CMP R15,RDI JZ 0x001f55b8 MOV RSI,qword ptr [R15] INC RSI CALL 0x0011dc50 LAB_001f55b8: ADD R15,-0x20 ADD R12,0x20 JNZ 0x001f55a4 MOVZX EAX,byte ptr [R14 + 0x10] TEST EAX,EAX LEA R15,[RSP + 0x48] JZ 0x001f55f7 CMP EAX,0x2 JZ 0x001f55da CMP EAX,0x1 JNZ 0x001f55e7 LAB_001f55da: MOV RAX,qword ptr [R14 + 0x18] MOV RCX,qword ptr [RAX] CMP RCX,qword ptr [RAX + 0x8] JZ 0x001f55f7 LAB_001f55e7: LEA RSI,[R14 + 0x10] LEA RDI,[RSP + 0x8] CALL 0x0018e664 JMP 0x001f5605 LAB_001f55f7: MOV byte ptr [RSP + 0x8],0x0 MOV qword ptr [RSP + 0x10],0x0 LAB_001f5605: MOVZX R8D,byte ptr [R14 + 0x68] LEA R9,[RSP + 0x28] MOV byte ptr [R9],0x0 MOV qword ptr [R9 + 0x8],0x0 LAB_001f561b: MOV dword ptr [RSP],0x1 LEA RDI,[RSP + 0x38] LEA RCX,[RSP + 0x8] MOV RSI,RBP MOV RDX,R14 CALL 0x001c5878 LAB_001f5637: LEA RDI,[RSP + 0xd8] LEA RSI,[RSP + 0x38] CALL 0x001a3c0a LAB_001f5649: MOV AL,byte ptr [RBX + 0x8] LEA RDI,[RSP + 0xd8] MOV CL,byte ptr [RDI] MOV byte ptr [RBX + 0x8],CL MOV byte ptr [RDI],AL MOV RAX,qword ptr [RBX + 0x10] MOV RCX,qword ptr [RDI + 0x8] MOV qword ptr [RBX + 0x10],RCX MOV qword ptr [RDI + 0x8],RAX CALL 0x0018eb30 MOV RDI,qword ptr [RSP + 0x38] CMP RDI,R15 JZ 0x001f5687 MOV RSI,qword ptr [RSP + 0x48] INC RSI CALL 0x0011dc50 LAB_001f5687: LEA RDI,[RSP + 0x28] CALL 0x0018eb30 LEA RDI,[RSP + 0x8] CALL 0x0018eb30 MOV dword ptr [RBX],0xa ADD RSP,0xe8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* common_chat_params_init_command_r7b(minja::chat_template const&, common_chat_inputs const&) */ void common_chat_params_init_command_r7b(chat_template *param_1,common_chat_inputs *param_2) { char cVar1; int8 uVar2; chat_template cVar3; ulong in_RDX; long lVar4; long *plVar5; ulong local_110 [2]; code *local_100; code *local_f8; data local_f0 [8]; int8 local_e8; long *local_e0 [2]; long local_d0 [2]; int1 *local_c0 [2]; int1 local_b0 [16]; int1 *local_a0 [2]; int1 local_90 [16]; int1 *local_80 [2]; int1 local_70 [16]; long *local_60 [2]; long local_50 [2]; chat_template local_40 [8]; int8 local_38; *(int4 *)param_1 = 0; param_1[8] = (chat_template)0x0; *(int8 *)(param_1 + 0x10) = 0; *(chat_template **)(param_1 + 0x18) = param_1 + 0x28; *(int8 *)(param_1 + 0x20) = 0; param_1[0x28] = (chat_template)0x0; param_1[0x38] = (chat_template)0x0; *(int8 *)(param_1 + 0x40) = 0; *(int8 *)(param_1 + 0x48) = 0; *(int8 *)(param_1 + 0x50) = 0; *(int8 *)(param_1 + 0x58) = 0; *(int8 *)(param_1 + 0x60) = 0; *(int8 *)(param_1 + 0x68) = 0; *(int8 *)(param_1 + 0x70) = 0; *(int8 *)(param_1 + 0x78) = 0; *(int8 *)(param_1 + 0x80) = 0; cVar3 = (chat_template) _ZN8nlohmann16json_abi_v3_11_3neIPKcTnNSt9enable_ifIXsr3std9is_scalarIT_EE5valueEiE4typeELi0EEEbRKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerESA_IhSaIhEEvEES5_ (in_RDX + 0x20,"required"); param_1[0x38] = cVar3; local_110[1] = 0; local_f8 = std:: _Function_handler<void(common_grammar_builder_const&),common_chat_params_init_command_r7b(minja::chat_template_const&,common_chat_inputs_const&)::$_0> ::_M_invoke; local_100 = std:: _Function_handler<void(common_grammar_builder_const&),common_chat_params_init_command_r7b(minja::chat_template_const&,common_chat_inputs_const&)::$_0> ::_M_manager; /* try { // try from 001f542c to 001f543c has its CatchHandler @ 001f5769 */ local_110[0] = in_RDX; build_grammar_abi_cxx11_((function *)local_e0,(common_grammar_options *)local_110); std::__cxx11::string::operator=((string *)(param_1 + 0x18),(string *)local_e0); if (local_e0[0] != local_d0) { operator_delete(local_e0[0],local_d0[0] + 1); } if (local_100 != (code *)0x0) { /* try { // try from 001f5473 to 001f5481 has its CatchHandler @ 001f56b8 */ (*local_100)(local_110,local_110,3); } local_e0[0] = local_d0; /* try { // try from 001f548a to 001f549c has its CatchHandler @ 001f5756 */ std::__cxx11::string::_M_construct<char_const*>(local_e0,"<|START_ACTION|>",""); local_c0[0] = (int1 *)((ulong)local_c0[0] & 0xffffffffffffff00); /* try { // try from 001f54aa to 001f54ae has its CatchHandler @ 001f573a */ std::vector<common_grammar_trigger,std::allocator<common_grammar_trigger>>:: emplace_back<common_grammar_trigger> ((vector<common_grammar_trigger,std::allocator<common_grammar_trigger>> *) (param_1 + 0x40),(common_grammar_trigger *)local_e0); if (local_e0[0] != local_d0) { operator_delete(local_e0[0],local_d0[0] + 1); } local_e0[0] = local_d0; /* try { // try from 001f54cf to 001f54e4 has its CatchHandler @ 001f5738 */ std::__cxx11::string::_M_construct<char_const*>(local_e0,"<|START_RESPONSE|>",""); local_c0[0] = local_b0; /* try { // try from 001f54f3 to 001f5508 has its CatchHandler @ 001f570a */ std::__cxx11::string::_M_construct<char_const*>(local_c0,"<|END_RESPONSE|>",""); local_a0[0] = local_90; /* try { // try from 001f551a to 001f552f has its CatchHandler @ 001f5708 */ std::__cxx11::string::_M_construct<char_const*>(local_a0,"<|START_THINKING|>",""); local_80[0] = local_70; /* try { // try from 001f5544 to 001f5559 has its CatchHandler @ 001f5706 */ std::__cxx11::string::_M_construct<char_const*>(local_80,"<|END_THINKING|>",""); plVar5 = local_50; local_60[0] = plVar5; /* try { // try from 001f556e to 001f5583 has its CatchHandler @ 001f5704 */ std::__cxx11::string::_M_construct<char_const*>(local_60,"<|END_ACTION|>",""); /* try { // try from 001f5590 to 001f559c has its CatchHandler @ 001f56f2 */ std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>:: _M_assign_aux<std::__cxx11::string_const*>(param_1 + 0x58,local_e0,local_40); lVar4 = -0xa0; do { if (plVar5 != (long *)plVar5[-2]) { operator_delete((long *)plVar5[-2],*plVar5 + 1); } plVar5 = plVar5 + -4; lVar4 = lVar4 + 0x20; } while (lVar4 != 0); cVar1 = *(char *)(in_RDX + 0x10); if ((cVar1 == '\0') || (((cVar1 == '\x02' || (cVar1 == '\x01')) && (**(long **)(in_RDX + 0x18) == (*(long **)(in_RDX + 0x18))[1])))) { local_110[0] = local_110[0] & 0xffffffffffffff00; local_110[1] = 0; } else { /* try { // try from 001f55e7 to 001f55f4 has its CatchHandler @ 001f56b3 */ 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> ::basic_json((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *)local_110,(basic_json *)(in_RDX + 0x10)); } local_f0[0] = (data)0x0; local_e8 = 0; /* try { // try from 001f561b to 001f5636 has its CatchHandler @ 001f56d9 */ minja::chat_template::apply ((basic_json *)local_e0,(basic_json *)param_2,SUB81(in_RDX,0),(basic_json *)local_110, *(bool *)(in_RDX + 0x68)); /* try { // try from 001f5637 to 001f5648 has its CatchHandler @ 001f56bd */ _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEC2IS9_S9_TnNSt9enable_ifIXaantsr6detail13is_basic_jsonIT0_EE5valuesr6detail18is_compatible_typeISD_SG_EE5valueEiE4typeELi0EEEOT_ (local_40,local_e0); cVar3 = param_1[8]; param_1[8] = local_40[0]; uVar2 = *(int8 *)(param_1 + 0x10); *(int8 *)(param_1 + 0x10) = local_38; local_40[0] = cVar3; local_38 = uVar2; nlohmann::json_abi_v3_11_3:: basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::data::~data((data *)local_40); if (local_e0[0] != local_d0) { operator_delete(local_e0[0],local_d0[0] + 1); } 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_f0); nlohmann::json_abi_v3_11_3:: basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::data::~data((data *)local_110); *(int4 *)param_1 = 10; return; }
3,532
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 0x96e53 movb 0x40(%r14), %al addb $-0x5, %al cmpb $0x1, %al ja 0x96e53 movq %rsi, %rdi callq 0x860e2 movq %rax, %r15 movq %r14, %rdi callq 0x860e2 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 0x603aa jmp 0x96e9f movq %rsi, %rdi callq 0x8622c movsd %xmm0, 0x8(%rsp) movq %r14, %rdi callq 0x8622c 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 0x5f972 movq %r14, %rdi movl $0x1, %esi callq 0x586c0 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_96E53 mov al, [r14+40h] add al, 0FBh cmp al, 1 ja short loc_96E53 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_96E9F loc_96E53: 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_96E9F: 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 0x00196e53 MOV AL,byte ptr [R14 + 0x40] ADD AL,0xfb CMP AL,0x1 JA 0x00196e53 MOV RDI,RSI CALL 0x001860e2 MOV R15,RAX MOV RDI,R14 CALL 0x001860e2 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 0x001603aa JMP 0x00196e9f LAB_00196e53: MOV RDI,RSI CALL 0x0018622c MOVSD qword ptr [RSP + 0x8],XMM0 MOV RDI,R14 CALL 0x0018622c 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 0x0015f972 LAB_00196e9f: MOV RDI,R14 MOV ESI,0x1 CALL 0x001586c0 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; }
3,533
copy_uca_collation
eloqsql/mysys/charset.c
static void copy_uca_collation(struct charset_info_st *to, CHARSET_INFO *from, CHARSET_INFO *loaded) { to->cset= from->cset; to->coll= from->coll; /* Single-level UCA collation have strnxfrm_multiple=8. In case of a multi-level UCA collation we use strnxfrm_multiply=4. That means MY_COLLATION_HANDLER::strnfrmlen() will request the caller to allocate a buffer smaller size for each level, for performance purpose, and to fit longer VARCHARs to @@max_sort_length. This makes filesort produce non-precise order for some rare Unicode characters that produce more than 4 weights (long expansions). UCA requires 2 bytes per weight multiplied by the number of levels. In case of a 2-level collation, each character requires 4*2=8 bytes. Therefore, the longest VARCHAR that fits into the default @@max_sort_length is 1024/8=VARCHAR(128). With strnxfrm_multiply==8, only VARCHAR(64) would fit. Note, the built-in collation utf8_thai_520_w2 also uses strnxfrm_multiply=4, for the same purpose. TODO: we could add a new LDML syntax to choose strxfrm_multiply value. */ to->strxfrm_multiply= loaded->levels_for_order > 1 ? 4 : from->strxfrm_multiply; to->min_sort_char= from->min_sort_char; to->max_sort_char= from->max_sort_char; to->mbminlen= from->mbminlen; to->mbmaxlen= from->mbmaxlen; to->caseup_multiply= from->caseup_multiply; to->casedn_multiply= from->casedn_multiply; to->state|= MY_CS_AVAILABLE | MY_CS_LOADED | MY_CS_STRNXFRM | MY_CS_UNICODE; }
O0
c
copy_uca_collation: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x10(%rbp), %rax movq 0xb8(%rax), %rcx movq -0x8(%rbp), %rax movq %rcx, 0xb8(%rax) movq -0x10(%rbp), %rax movq 0xc0(%rax), %rcx movq -0x8(%rbp), %rax movq %rcx, 0xc0(%rax) movq -0x18(%rbp), %rax movzbl 0xb2(%rax), %eax cmpl $0x1, %eax jle 0xdccf6 movl $0x4, %eax movl %eax, -0x1c(%rbp) jmp 0xdcd03 movq -0x10(%rbp), %rax movl 0x90(%rax), %eax movl %eax, -0x1c(%rbp) movl -0x1c(%rbp), %ecx movq -0x8(%rbp), %rax movl %ecx, 0x90(%rax) movq -0x10(%rbp), %rax movq 0xa0(%rax), %rcx movq -0x8(%rbp), %rax movq %rcx, 0xa0(%rax) movq -0x10(%rbp), %rax movq 0xa8(%rax), %rcx movq -0x8(%rbp), %rax movq %rcx, 0xa8(%rax) movq -0x10(%rbp), %rax movl 0x98(%rax), %ecx movq -0x8(%rbp), %rax movl %ecx, 0x98(%rax) movq -0x10(%rbp), %rax movl 0x9c(%rax), %ecx movq -0x8(%rbp), %rax movl %ecx, 0x9c(%rax) movq -0x10(%rbp), %rax movb 0x94(%rax), %cl movq -0x8(%rbp), %rax movb %cl, 0x94(%rax) movq -0x10(%rbp), %rax movb 0x95(%rax), %cl movq -0x8(%rbp), %rax movb %cl, 0x95(%rax) movq -0x8(%rbp), %rax movl 0xc(%rax), %ecx orl $0x2c8, %ecx # imm = 0x2C8 movl %ecx, 0xc(%rax) popq %rbp retq nop
copy_uca_collation: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_10] mov rcx, [rax+0B8h] mov rax, [rbp+var_8] mov [rax+0B8h], rcx mov rax, [rbp+var_10] mov rcx, [rax+0C0h] mov rax, [rbp+var_8] mov [rax+0C0h], rcx mov rax, [rbp+var_18] movzx eax, byte ptr [rax+0B2h] cmp eax, 1 jle short loc_DCCF6 mov eax, 4 mov [rbp+var_1C], eax jmp short loc_DCD03 loc_DCCF6: mov rax, [rbp+var_10] mov eax, [rax+90h] mov [rbp+var_1C], eax loc_DCD03: mov ecx, [rbp+var_1C] mov rax, [rbp+var_8] mov [rax+90h], ecx mov rax, [rbp+var_10] mov rcx, [rax+0A0h] mov rax, [rbp+var_8] mov [rax+0A0h], rcx mov rax, [rbp+var_10] mov rcx, [rax+0A8h] mov rax, [rbp+var_8] mov [rax+0A8h], rcx mov rax, [rbp+var_10] mov ecx, [rax+98h] mov rax, [rbp+var_8] mov [rax+98h], ecx mov rax, [rbp+var_10] mov ecx, [rax+9Ch] mov rax, [rbp+var_8] mov [rax+9Ch], ecx mov rax, [rbp+var_10] mov cl, [rax+94h] mov rax, [rbp+var_8] mov [rax+94h], cl mov rax, [rbp+var_10] mov cl, [rax+95h] mov rax, [rbp+var_8] mov [rax+95h], cl mov rax, [rbp+var_8] mov ecx, [rax+0Ch] or ecx, 2C8h mov [rax+0Ch], ecx pop rbp retn
long long copy_uca_collation(long long a1, long long a2, long long a3) { long long result; // rax int v4; // [rsp+0h] [rbp-1Ch] *(_QWORD *)(a1 + 184) = *(_QWORD *)(a2 + 184); *(_QWORD *)(a1 + 192) = *(_QWORD *)(a2 + 192); if ( *(unsigned __int8 *)(a3 + 178) <= 1u ) v4 = *(_DWORD *)(a2 + 144); else v4 = 4; *(_DWORD *)(a1 + 144) = v4; *(_QWORD *)(a1 + 160) = *(_QWORD *)(a2 + 160); *(_QWORD *)(a1 + 168) = *(_QWORD *)(a2 + 168); *(_DWORD *)(a1 + 152) = *(_DWORD *)(a2 + 152); *(_DWORD *)(a1 + 156) = *(_DWORD *)(a2 + 156); *(_BYTE *)(a1 + 148) = *(_BYTE *)(a2 + 148); *(_BYTE *)(a1 + 149) = *(_BYTE *)(a2 + 149); result = a1; *(_DWORD *)(a1 + 12) |= 0x2C8u; return result; }
copy_uca_collation: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0xb8] MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0xb8],RCX MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0xc0] MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0xc0],RCX MOV RAX,qword ptr [RBP + -0x18] MOVZX EAX,byte ptr [RAX + 0xb2] CMP EAX,0x1 JLE 0x001dccf6 MOV EAX,0x4 MOV dword ptr [RBP + -0x1c],EAX JMP 0x001dcd03 LAB_001dccf6: MOV RAX,qword ptr [RBP + -0x10] MOV EAX,dword ptr [RAX + 0x90] MOV dword ptr [RBP + -0x1c],EAX LAB_001dcd03: MOV ECX,dword ptr [RBP + -0x1c] MOV RAX,qword ptr [RBP + -0x8] MOV dword ptr [RAX + 0x90],ECX MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0xa0] MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0xa0],RCX MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0xa8] MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0xa8],RCX MOV RAX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RAX + 0x98] MOV RAX,qword ptr [RBP + -0x8] MOV dword ptr [RAX + 0x98],ECX MOV RAX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RAX + 0x9c] MOV RAX,qword ptr [RBP + -0x8] MOV dword ptr [RAX + 0x9c],ECX MOV RAX,qword ptr [RBP + -0x10] MOV CL,byte ptr [RAX + 0x94] MOV RAX,qword ptr [RBP + -0x8] MOV byte ptr [RAX + 0x94],CL MOV RAX,qword ptr [RBP + -0x10] MOV CL,byte ptr [RAX + 0x95] MOV RAX,qword ptr [RBP + -0x8] MOV byte ptr [RAX + 0x95],CL MOV RAX,qword ptr [RBP + -0x8] MOV ECX,dword ptr [RAX + 0xc] OR ECX,0x2c8 MOV dword ptr [RAX + 0xc],ECX POP RBP RET
void copy_uca_collation(long param_1,long param_2,long param_3) { int4 local_24; *(int8 *)(param_1 + 0xb8) = *(int8 *)(param_2 + 0xb8); *(int8 *)(param_1 + 0xc0) = *(int8 *)(param_2 + 0xc0); if (*(byte *)(param_3 + 0xb2) < 2) { local_24 = *(int4 *)(param_2 + 0x90); } else { local_24 = 4; } *(int4 *)(param_1 + 0x90) = local_24; *(int8 *)(param_1 + 0xa0) = *(int8 *)(param_2 + 0xa0); *(int8 *)(param_1 + 0xa8) = *(int8 *)(param_2 + 0xa8); *(int4 *)(param_1 + 0x98) = *(int4 *)(param_2 + 0x98); *(int4 *)(param_1 + 0x9c) = *(int4 *)(param_2 + 0x9c); *(int1 *)(param_1 + 0x94) = *(int1 *)(param_2 + 0x94); *(int1 *)(param_1 + 0x95) = *(int1 *)(param_2 + 0x95); *(uint *)(param_1 + 0xc) = *(uint *)(param_1 + 0xc) | 0x2c8; return; }
3,534
copy_uca_collation
eloqsql/mysys/charset.c
static void copy_uca_collation(struct charset_info_st *to, CHARSET_INFO *from, CHARSET_INFO *loaded) { to->cset= from->cset; to->coll= from->coll; /* Single-level UCA collation have strnxfrm_multiple=8. In case of a multi-level UCA collation we use strnxfrm_multiply=4. That means MY_COLLATION_HANDLER::strnfrmlen() will request the caller to allocate a buffer smaller size for each level, for performance purpose, and to fit longer VARCHARs to @@max_sort_length. This makes filesort produce non-precise order for some rare Unicode characters that produce more than 4 weights (long expansions). UCA requires 2 bytes per weight multiplied by the number of levels. In case of a 2-level collation, each character requires 4*2=8 bytes. Therefore, the longest VARCHAR that fits into the default @@max_sort_length is 1024/8=VARCHAR(128). With strnxfrm_multiply==8, only VARCHAR(64) would fit. Note, the built-in collation utf8_thai_520_w2 also uses strnxfrm_multiply=4, for the same purpose. TODO: we could add a new LDML syntax to choose strxfrm_multiply value. */ to->strxfrm_multiply= loaded->levels_for_order > 1 ? 4 : from->strxfrm_multiply; to->min_sort_char= from->min_sort_char; to->max_sort_char= from->max_sort_char; to->mbminlen= from->mbminlen; to->mbmaxlen= from->mbmaxlen; to->caseup_multiply= from->caseup_multiply; to->casedn_multiply= from->casedn_multiply; to->state|= MY_CS_AVAILABLE | MY_CS_LOADED | MY_CS_STRNXFRM | MY_CS_UNICODE; }
O3
c
copy_uca_collation: pushq %rbp movq %rsp, %rbp movq 0xb8(%rsi), %rax movq %rax, 0xb8(%rdi) movq 0xc0(%rsi), %rax movq %rax, 0xc0(%rdi) movl $0x4, %eax cmpb $0x1, 0xb2(%rdx) ja 0x934f3 movl 0x90(%rsi), %eax movl %eax, 0x90(%rdi) movq 0xa0(%rsi), %rax movq %rax, 0xa0(%rdi) movq 0xa8(%rsi), %rax movq %rax, 0xa8(%rdi) movl 0x98(%rsi), %eax movl %eax, 0x98(%rdi) movl 0x9c(%rsi), %eax movl %eax, 0x9c(%rdi) movb 0x94(%rsi), %al movb %al, 0x94(%rdi) movb 0x95(%rsi), %al movb %al, 0x95(%rdi) orl $0x2c8, 0xc(%rdi) # imm = 0x2C8 popq %rbp retq
copy_uca_collation: push rbp mov rbp, rsp mov rax, [rsi+0B8h] mov [rdi+0B8h], rax mov rax, [rsi+0C0h] mov [rdi+0C0h], rax mov eax, 4 cmp byte ptr [rdx+0B2h], 1 ja short loc_934F3 mov eax, [rsi+90h] loc_934F3: mov [rdi+90h], eax mov rax, [rsi+0A0h] mov [rdi+0A0h], rax mov rax, [rsi+0A8h] mov [rdi+0A8h], rax mov eax, [rsi+98h] mov [rdi+98h], eax mov eax, [rsi+9Ch] mov [rdi+9Ch], eax mov al, [rsi+94h] mov [rdi+94h], al mov al, [rsi+95h] mov [rdi+95h], al or dword ptr [rdi+0Ch], 2C8h pop rbp retn
char copy_uca_collation(long long a1, long long a2, long long a3) { int v3; // eax char result; // al *(_QWORD *)(a1 + 184) = *(_QWORD *)(a2 + 184); *(_QWORD *)(a1 + 192) = *(_QWORD *)(a2 + 192); v3 = 4; if ( *(_BYTE *)(a3 + 178) <= 1u ) v3 = *(_DWORD *)(a2 + 144); *(_DWORD *)(a1 + 144) = v3; *(_QWORD *)(a1 + 160) = *(_QWORD *)(a2 + 160); *(_QWORD *)(a1 + 168) = *(_QWORD *)(a2 + 168); *(_DWORD *)(a1 + 152) = *(_DWORD *)(a2 + 152); *(_DWORD *)(a1 + 156) = *(_DWORD *)(a2 + 156); *(_BYTE *)(a1 + 148) = *(_BYTE *)(a2 + 148); result = *(_BYTE *)(a2 + 149); *(_BYTE *)(a1 + 149) = result; *(_DWORD *)(a1 + 12) |= 0x2C8u; return result; }
copy_uca_collation: PUSH RBP MOV RBP,RSP MOV RAX,qword ptr [RSI + 0xb8] MOV qword ptr [RDI + 0xb8],RAX MOV RAX,qword ptr [RSI + 0xc0] MOV qword ptr [RDI + 0xc0],RAX MOV EAX,0x4 CMP byte ptr [RDX + 0xb2],0x1 JA 0x001934f3 MOV EAX,dword ptr [RSI + 0x90] LAB_001934f3: MOV dword ptr [RDI + 0x90],EAX MOV RAX,qword ptr [RSI + 0xa0] MOV qword ptr [RDI + 0xa0],RAX MOV RAX,qword ptr [RSI + 0xa8] MOV qword ptr [RDI + 0xa8],RAX MOV EAX,dword ptr [RSI + 0x98] MOV dword ptr [RDI + 0x98],EAX MOV EAX,dword ptr [RSI + 0x9c] MOV dword ptr [RDI + 0x9c],EAX MOV AL,byte ptr [RSI + 0x94] MOV byte ptr [RDI + 0x94],AL MOV AL,byte ptr [RSI + 0x95] MOV byte ptr [RDI + 0x95],AL OR dword ptr [RDI + 0xc],0x2c8 POP RBP RET
void copy_uca_collation(long param_1,long param_2,long param_3) { int4 uVar1; *(int8 *)(param_1 + 0xb8) = *(int8 *)(param_2 + 0xb8); *(int8 *)(param_1 + 0xc0) = *(int8 *)(param_2 + 0xc0); uVar1 = 4; if (*(byte *)(param_3 + 0xb2) < 2) { uVar1 = *(int4 *)(param_2 + 0x90); } *(int4 *)(param_1 + 0x90) = uVar1; *(int8 *)(param_1 + 0xa0) = *(int8 *)(param_2 + 0xa0); *(int8 *)(param_1 + 0xa8) = *(int8 *)(param_2 + 0xa8); *(int4 *)(param_1 + 0x98) = *(int4 *)(param_2 + 0x98); *(int4 *)(param_1 + 0x9c) = *(int4 *)(param_2 + 0x9c); *(int1 *)(param_1 + 0x94) = *(int1 *)(param_2 + 0x94); *(int1 *)(param_1 + 0x95) = *(int1 *)(param_2 + 0x95); *(uint *)(param_1 + 0xc) = *(uint *)(param_1 + 0xc) | 0x2c8; return; }
3,535
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> nlohmann::json_abi_v3_11_2::detail::exception::diagnostics<nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>>(nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>> const*)
7CodeWizard[P]stablediffusion/thirdparty/json.hpp
static std::string diagnostics(const BasicJsonType* leaf_element) { #if JSON_DIAGNOSTICS std::vector<std::string> tokens; for (const auto* current = leaf_element; current != nullptr && current->m_parent != nullptr; current = current->m_parent) { switch (current->m_parent->type()) { case value_t::array: { for (std::size_t i = 0; i < current->m_parent->m_value.array->size(); ++i) { if (&current->m_parent->m_value.array->operator[](i) == current) { tokens.emplace_back(std::to_string(i)); break; } } break; } case value_t::object: { for (const auto& element : *current->m_parent->m_value.object) { if (&element.second == current) { tokens.emplace_back(element.first.c_str()); break; } } break; } case value_t::null: // LCOV_EXCL_LINE case value_t::string: // LCOV_EXCL_LINE case value_t::boolean: // LCOV_EXCL_LINE case value_t::number_integer: // LCOV_EXCL_LINE case value_t::number_unsigned: // LCOV_EXCL_LINE case value_t::number_float: // LCOV_EXCL_LINE case value_t::binary: // LCOV_EXCL_LINE case value_t::discarded: // LCOV_EXCL_LINE default: // LCOV_EXCL_LINE break; // LCOV_EXCL_LINE } } if (tokens.empty()) { return ""; } auto str = std::accumulate(tokens.rbegin(), tokens.rend(), std::string{}, [](const std::string & a, const std::string & b) { return concat(a, '/', detail::escape(b)); }); return concat('(', str, ") "); #else static_cast<void>(leaf_element); return ""; #endif }
O0
cpp
std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> nlohmann::json_abi_v3_11_2::detail::exception::diagnostics<nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>>>(nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>> const*): subq $0x48, %rsp movq %rdi, 0x10(%rsp) movq %rdi, %rax movq %rax, 0x8(%rsp) movq %rdi, 0x40(%rsp) movq %rsi, 0x38(%rsp) leaq 0x37(%rsp), %rdi movq %rdi, 0x18(%rsp) callq 0xbd40 movq 0x10(%rsp), %rdi movq 0x18(%rsp), %rdx leaq 0xbef53(%rip), %rsi # 0x186f7e callq 0x30260 jmp 0xc8032 leaq 0x37(%rsp), %rdi callq 0xb820 movq 0x8(%rsp), %rax addq $0x48, %rsp retq movq %rax, %rcx movl %edx, %eax movq %rcx, 0x28(%rsp) movl %eax, 0x24(%rsp) leaq 0x37(%rsp), %rdi callq 0xb820 movq 0x28(%rsp), %rdi callq 0xbd30 nopl (%rax,%rax)
_ZN8nlohmann16json_abi_v3_11_26detail9exception11diagnosticsINS0_10basic_jsonISt3mapSt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEEEEESC_PKT_: sub rsp, 48h mov [rsp+48h+var_38], rdi mov rax, rdi mov [rsp+48h+var_40], rax mov [rsp+48h+var_8], rdi mov [rsp+48h+var_10], rsi lea rdi, [rsp+48h+var_11] mov [rsp+48h+var_30], rdi call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void) mov rdi, [rsp+48h+var_38] mov rdx, [rsp+48h+var_30] lea rsi, dword_186F7E call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) jmp short $+2 loc_C8032: lea rdi, [rsp+48h+var_11] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() mov rax, [rsp+48h+var_40] add rsp, 48h retn mov rcx, rax mov eax, edx mov [rsp+arg_20], rcx mov [rsp+arg_1C], eax lea rdi, [rsp+arg_2F] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() mov rdi, [rsp+arg_20] call __Unwind_Resume
long long nlohmann::json_abi_v3_11_2::detail::exception::diagnostics<nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned char>>>( long long a1, long long a2) { char v3; // [rsp+37h] [rbp-11h] BYREF long long v4; // [rsp+38h] [rbp-10h] long long v5; // [rsp+40h] [rbp-8h] v5 = a1; v4 = a2; std::allocator<char>::allocator(); std::string::basic_string<std::allocator<char>>(a1, (long long)&dword_186F7E, (long long)&v3); std::allocator<char>::~allocator(&v3); return a1; }
diagnostics<nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>>: SUB RSP,0x48 MOV qword ptr [RSP + 0x10],RDI MOV RAX,RDI MOV qword ptr [RSP + 0x8],RAX MOV qword ptr [RSP + 0x40],RDI MOV qword ptr [RSP + 0x38],RSI LEA RDI,[RSP + 0x37] MOV qword ptr [RSP + 0x18],RDI CALL 0x0010bd40 MOV RDI,qword ptr [RSP + 0x10] MOV RDX,qword ptr [RSP + 0x18] LAB_001c8024: LEA RSI,[0x286f7e] CALL 0x00130260 LAB_001c8030: JMP 0x001c8032 LAB_001c8032: LEA RDI,[RSP + 0x37] CALL 0x0010b820 MOV RAX,qword ptr [RSP + 0x8] ADD RSP,0x48 RET
/* std::__cxx11::string nlohmann::json_abi_v3_11_2::detail::exception::diagnostics<nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> > > >(nlohmann::json_abi_v3_11_2::basic_json<std::map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_2::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> > > const*) */ exception * __thiscall nlohmann::json_abi_v3_11_2::detail::exception:: diagnostics<nlohmann::json_abi_v3_11_2::basic_json<std::map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_2::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>>> (exception *this,basic_json *param_1) { allocator local_11; basic_json *local_10; exception *local_8; local_10 = param_1; local_8 = this; std::allocator<char>::allocator(); /* try { // try from 001c8024 to 001c802f has its CatchHandler @ 001c8046 */ std::__cxx11::string::string<std::allocator<char>>((string *)this,"",&local_11); std::allocator<char>::~allocator((allocator<char> *)&local_11); return this; }
3,536
inline_mysql_mutex_init
eloqsql/include/mysql/psi/mysql_thread.h
static inline int inline_mysql_mutex_init( #ifdef HAVE_PSI_MUTEX_INTERFACE PSI_mutex_key key, #endif mysql_mutex_t *that, const pthread_mutexattr_t *attr #ifdef SAFE_MUTEX , const char *src_name, const char *src_file, uint src_line #endif ) { #ifdef HAVE_PSI_MUTEX_INTERFACE that->m_psi= PSI_MUTEX_CALL(init_mutex)(key, &that->m_mutex); #else that->m_psi= NULL; #endif #ifdef COROUTINE_ENABLED that->l.data= that; that->l.prev= that->l.next= NULL; #endif #ifdef SAFE_MUTEX return safe_mutex_init(&that->m_mutex, attr, src_name, src_file, src_line); #else return pthread_mutex_init(&that->m_mutex, attr); #endif }
O0
c
inline_mysql_mutex_init: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movl %edi, -0x4(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) leaq 0x23ccfe(%rip), %rax # 0x301fb8 movq (%rax), %rax movq 0x40(%rax), %rax movl -0x4(%rbp), %edi movq -0x10(%rbp), %rsi callq *%rax movq %rax, %rcx movq -0x10(%rbp), %rax movq %rcx, 0x40(%rax) movq -0x10(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x38(%rax) movq -0x10(%rbp), %rax movq $0x0, 0x30(%rax) movq -0x10(%rbp), %rax movq $0x0, 0x28(%rax) movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0x60450 addq $0x20, %rsp popq %rbp retq nopl (%rax)
inline_mysql_mutex_init_0: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_4], edi mov [rbp+var_10], rsi mov [rbp+var_18], rdx lea rax, PSI_server mov rax, [rax] mov rax, [rax+40h] mov edi, [rbp+var_4] mov rsi, [rbp+var_10] call rax mov rcx, rax mov rax, [rbp+var_10] mov [rax+40h], rcx mov rcx, [rbp+var_10] mov rax, [rbp+var_10] mov [rax+38h], rcx mov rax, [rbp+var_10] mov qword ptr [rax+30h], 0 mov rax, [rbp+var_10] mov qword ptr [rax+28h], 0 mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] call _pthread_mutex_init add rsp, 20h pop rbp retn
long long inline_mysql_mutex_init_0(unsigned int a1, _QWORD *a2, long long a3) { a2[8] = (*((long long ( **)(_QWORD, _QWORD *))PSI_server + 8))(a1, a2); a2[7] = a2; a2[6] = 0LL; a2[5] = 0LL; return pthread_mutex_init(a2, a3); }
inline_mysql_mutex_init: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV dword ptr [RBP + -0x4],EDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX LEA RAX,[0x401fb8] MOV RAX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x40] MOV EDI,dword ptr [RBP + -0x4] MOV RSI,qword ptr [RBP + -0x10] CALL RAX MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x40],RCX MOV RCX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x38],RCX MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x30],0x0 MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x28],0x0 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] CALL 0x00160450 ADD RSP,0x20 POP RBP RET
void inline_mysql_mutex_init (int4 param_1,pthread_mutex_t *param_2,pthread_mutexattr_t *param_3) { int8 uVar1; uVar1 = (**(code **)(PSI_server + 0x40))(param_1,param_2); *(int8 *)((long)param_2 + 0x40) = uVar1; *(pthread_mutex_t **)((long)param_2 + 0x38) = param_2; *(int8 *)((long)param_2 + 0x30) = 0; param_2[1].__align = 0; pthread_mutex_init(param_2,param_3); return; }
3,537
js_loadScript
bluesky950520[P]quickjs/quickjs-libc.c
static JSValue js_loadScript(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { uint8_t *buf; const char *filename; JSValue ret; size_t buf_len; filename = JS_ToCString(ctx, argv[0]); if (!filename) return JS_EXCEPTION; buf = js_load_file(ctx, &buf_len, filename); if (!buf) { JS_ThrowReferenceError(ctx, "could not load '%s'", filename); JS_FreeCString(ctx, filename); return JS_EXCEPTION; } ret = JS_Eval(ctx, (char *)buf, buf_len, filename, JS_EVAL_TYPE_GLOBAL); js_free(ctx, buf); JS_FreeCString(ctx, filename); return ret; }
O0
c
js_loadScript: subq $0x88, %rsp movq %rsi, 0x68(%rsp) movq %rdx, 0x70(%rsp) movq %rdi, 0x60(%rsp) movl %ecx, 0x5c(%rsp) movq %r8, 0x50(%rsp) movq 0x60(%rsp), %rdi movq 0x50(%rsp), %rax movq (%rax), %rsi movq 0x8(%rax), %rdx callq 0x13520 movq %rax, 0x40(%rsp) cmpq $0x0, 0x40(%rsp) jne 0x13c2b movl $0x0, 0x78(%rsp) movq $0x6, 0x80(%rsp) jmp 0x13d02 movq 0x60(%rsp), %rdi movq 0x40(%rsp), %rdx leaq 0x28(%rsp), %rsi callq 0xec10 movq %rax, 0x48(%rsp) cmpq $0x0, 0x48(%rsp) jne 0x13c93 movq 0x60(%rsp), %rdi movq 0x40(%rsp), %rdx leaq 0xf49cd(%rip), %rsi # 0x10862a movb $0x0, %al callq 0x2c130 movq %rax, 0x18(%rsp) movq %rdx, 0x20(%rsp) movq 0x60(%rsp), %rdi movq 0x40(%rsp), %rsi callq 0x28b90 movl $0x0, 0x78(%rsp) movq $0x6, 0x80(%rsp) jmp 0x13d02 movq 0x60(%rsp), %rdi movq 0x48(%rsp), %rsi movq 0x28(%rsp), %rdx movq 0x40(%rsp), %rcx xorl %r8d, %r8d callq 0x49a40 movq %rax, 0x8(%rsp) movq %rdx, 0x10(%rsp) movq 0x8(%rsp), %rax movq %rax, 0x30(%rsp) movq 0x10(%rsp), %rax movq %rax, 0x38(%rsp) movq 0x60(%rsp), %rdi movq 0x48(%rsp), %rsi callq 0x20af0 movq 0x60(%rsp), %rdi movq 0x40(%rsp), %rsi callq 0x28b90 movq 0x30(%rsp), %rax movq %rax, 0x78(%rsp) movq 0x38(%rsp), %rax movq %rax, 0x80(%rsp) movq 0x78(%rsp), %rax movq 0x80(%rsp), %rdx addq $0x88, %rsp retq nopw (%rax,%rax)
js_loadScript: sub rsp, 88h mov [rsp+88h+var_20], rsi mov [rsp+88h+var_18], rdx mov [rsp+88h+var_28], rdi mov [rsp+88h+var_2C], ecx mov [rsp+88h+var_38], r8 mov rdi, [rsp+88h+var_28] mov rax, [rsp+88h+var_38] mov rsi, [rax] mov rdx, [rax+8] call JS_ToCString mov [rsp+88h+var_48], rax cmp [rsp+88h+var_48], 0 jnz short loc_13C2B mov dword ptr [rsp+88h+var_10], 0 mov [rsp+88h+var_8], 6 jmp loc_13D02 loc_13C2B: mov rdi, [rsp+88h+var_28] mov rdx, [rsp+88h+var_48] lea rsi, [rsp+88h+var_60] call js_load_file mov [rsp+88h+var_40], rax cmp [rsp+88h+var_40], 0 jnz short loc_13C93 mov rdi, [rsp+88h+var_28] mov rdx, [rsp+88h+var_48] lea rsi, aCouldNotLoadS; "could not load '%s'" mov al, 0 call JS_ThrowReferenceError mov [rsp+88h+var_70], rax mov [rsp+88h+var_68], rdx mov rdi, [rsp+88h+var_28] mov rsi, [rsp+88h+var_48] call JS_FreeCString mov dword ptr [rsp+88h+var_10], 0 mov [rsp+88h+var_8], 6 jmp short loc_13D02 loc_13C93: mov rdi, [rsp+88h+var_28] mov rsi, [rsp+88h+var_40] mov rdx, [rsp+88h+var_60] mov rcx, [rsp+88h+var_48] xor r8d, r8d call JS_Eval mov [rsp+88h+var_80], rax mov [rsp+88h+var_78], rdx mov rax, [rsp+88h+var_80] mov [rsp+88h+var_58], rax mov rax, [rsp+88h+var_78] mov [rsp+88h+var_50], rax mov rdi, [rsp+88h+var_28] mov rsi, [rsp+88h+var_40] call js_free mov rdi, [rsp+88h+var_28] mov rsi, [rsp+88h+var_48] call JS_FreeCString mov rax, [rsp+88h+var_58] mov [rsp+88h+var_10], rax mov rax, [rsp+88h+var_50] mov [rsp+88h+var_8], rax loc_13D02: mov rax, [rsp+88h+var_10] mov rdx, [rsp+88h+var_8] add rsp, 88h retn
long long js_loadScript(long long a1, long long a2, long long a3, int a4, long long *a5) { int v5; // ecx int v6; // r8d int v7; // r9d long long v8; // rdx long long v10; // [rsp+28h] [rbp-60h] BYREF long long v11; // [rsp+30h] [rbp-58h] long long v12; // [rsp+38h] [rbp-50h] long long v13; // [rsp+40h] [rbp-48h] long long v14; // [rsp+48h] [rbp-40h] long long *v15; // [rsp+50h] [rbp-38h] int v16; // [rsp+5Ch] [rbp-2Ch] long long v17; // [rsp+60h] [rbp-28h] long long v18; // [rsp+68h] [rbp-20h] long long v19; // [rsp+70h] [rbp-18h] long long v20; // [rsp+78h] [rbp-10h] long long v21; // [rsp+80h] [rbp-8h] v18 = a2; v19 = a3; v17 = a1; v16 = a4; v15 = a5; v13 = JS_ToCString(a1, *a5, a5[1]); if ( v13 ) { v14 = js_load_file(v17, &v10, v13); if ( v14 ) { v11 = JS_Eval(v17, v14, v10, v13, 0LL); v12 = v8; js_free(v17, v14); JS_FreeCString(v17, v13); v20 = v11; v21 = v12; } else { JS_ThrowReferenceError(v17, (unsigned int)"could not load '%s'", v13, v5, v6, v7); JS_FreeCString(v17, v13); LODWORD(v20) = 0; v21 = 6LL; } } else { LODWORD(v20) = 0; v21 = 6LL; } return v20; }
js_loadScript: SUB RSP,0x88 MOV qword ptr [RSP + 0x68],RSI MOV qword ptr [RSP + 0x70],RDX MOV qword ptr [RSP + 0x60],RDI MOV dword ptr [RSP + 0x5c],ECX MOV qword ptr [RSP + 0x50],R8 MOV RDI,qword ptr [RSP + 0x60] MOV RAX,qword ptr [RSP + 0x50] MOV RSI,qword ptr [RAX] MOV RDX,qword ptr [RAX + 0x8] CALL 0x00113520 MOV qword ptr [RSP + 0x40],RAX CMP qword ptr [RSP + 0x40],0x0 JNZ 0x00113c2b MOV dword ptr [RSP + 0x78],0x0 MOV qword ptr [RSP + 0x80],0x6 JMP 0x00113d02 LAB_00113c2b: MOV RDI,qword ptr [RSP + 0x60] MOV RDX,qword ptr [RSP + 0x40] LEA RSI,[RSP + 0x28] CALL 0x0010ec10 MOV qword ptr [RSP + 0x48],RAX CMP qword ptr [RSP + 0x48],0x0 JNZ 0x00113c93 MOV RDI,qword ptr [RSP + 0x60] MOV RDX,qword ptr [RSP + 0x40] LEA RSI,[0x20862a] MOV AL,0x0 CALL 0x0012c130 MOV qword ptr [RSP + 0x18],RAX MOV qword ptr [RSP + 0x20],RDX MOV RDI,qword ptr [RSP + 0x60] MOV RSI,qword ptr [RSP + 0x40] CALL 0x00128b90 MOV dword ptr [RSP + 0x78],0x0 MOV qword ptr [RSP + 0x80],0x6 JMP 0x00113d02 LAB_00113c93: MOV RDI,qword ptr [RSP + 0x60] MOV RSI,qword ptr [RSP + 0x48] MOV RDX,qword ptr [RSP + 0x28] MOV RCX,qword ptr [RSP + 0x40] XOR R8D,R8D CALL 0x00149a40 MOV qword ptr [RSP + 0x8],RAX MOV qword ptr [RSP + 0x10],RDX MOV RAX,qword ptr [RSP + 0x8] MOV qword ptr [RSP + 0x30],RAX MOV RAX,qword ptr [RSP + 0x10] MOV qword ptr [RSP + 0x38],RAX MOV RDI,qword ptr [RSP + 0x60] MOV RSI,qword ptr [RSP + 0x48] CALL 0x00120af0 MOV RDI,qword ptr [RSP + 0x60] MOV RSI,qword ptr [RSP + 0x40] CALL 0x00128b90 MOV RAX,qword ptr [RSP + 0x30] MOV qword ptr [RSP + 0x78],RAX MOV RAX,qword ptr [RSP + 0x38] MOV qword ptr [RSP + 0x80],RAX LAB_00113d02: MOV RAX,qword ptr [RSP + 0x78] MOV RDX,qword ptr [RSP + 0x80] ADD RSP,0x88 RET
int1 [16] js_loadScript(int8 param_1,int8 param_2,int8 param_3,int4 param_4, int8 *param_5) { int1 auVar1 [16]; int8 local_60; int1 local_58 [16]; long local_48; long local_40; int8 *local_38; int4 local_2c; int8 local_28; int8 local_20; int8 local_18; int4 local_10; int4 uStack_c; int8 local_8; local_38 = param_5; local_2c = param_4; local_28 = param_1; local_20 = param_2; local_18 = param_3; local_48 = JS_ToCString(param_1,*param_5,param_5[1]); if (local_48 == 0) { local_10 = 0; local_8 = 6; } else { local_40 = js_load_file(local_28,&local_60,local_48); if (local_40 == 0) { JS_ThrowReferenceError(local_28,"could not load \'%s\'",local_48); JS_FreeCString(local_28,local_48); local_10 = 0; local_8 = 6; } else { local_58 = JS_Eval(local_28,local_40,local_60,local_48,0); js_free(local_28,local_40); JS_FreeCString(local_28,local_48); local_10 = local_58._0_4_; uStack_c = local_58._4_4_; local_8 = local_58._8_8_; } } auVar1._4_4_ = uStack_c; auVar1._0_4_ = local_10; auVar1._8_8_ = local_8; return auVar1; }
3,538
js_loadScript
bluesky950520[P]quickjs/quickjs-libc.c
static JSValue js_loadScript(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { uint8_t *buf; const char *filename; JSValue ret; size_t buf_len; filename = JS_ToCString(ctx, argv[0]); if (!filename) return JS_EXCEPTION; buf = js_load_file(ctx, &buf_len, filename); if (!buf) { JS_ThrowReferenceError(ctx, "could not load '%s'", filename); JS_FreeCString(ctx, filename); return JS_EXCEPTION; } ret = JS_Eval(ctx, (char *)buf, buf_len, filename, JS_EVAL_TYPE_GLOBAL); js_free(ctx, buf); JS_FreeCString(ctx, filename); return ret; }
O1
c
js_loadScript: pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x10, %rsp movq %rdi, %r14 movq (%r8), %rdx movq 0x8(%r8), %rcx xorl %r12d, %r12d xorl %esi, %esi xorl %r8d, %r8d callq 0x1ffe3 movl $0x6, %ebx testq %rax, %rax je 0x1643b movq %rax, %r15 leaq 0x8(%rsp), %rsi movq %r14, %rdi movq %rax, %rdx callq 0x13b34 testq %rax, %rax je 0x16419 movq %rax, %r12 movq 0x8(%rsp), %rdx movq %r14, %rdi movq %rax, %rsi movq %r15, %rcx xorl %r8d, %r8d callq 0x30926 movq %rax, %r13 movq %rdx, %rbx movq %r14, %rdi movq %r12, %rsi callq 0x1bf85 movq %r14, %rdi movq %r15, %rsi callq 0x202c9 movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000 andq %r13, %rax movl %r13d, %r12d jmp 0x1643d leaq 0x84172(%rip), %rsi # 0x9a592 xorl %r12d, %r12d movq %r14, %rdi movq %r15, %rdx xorl %eax, %eax callq 0x219e9 movq %r14, %rdi movq %r15, %rsi callq 0x202c9 xorl %eax, %eax orq %rax, %r12 movq %r12, %rax movq %rbx, %rdx addq $0x10, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq
js_loadScript: push r15 push r14 push r13 push r12 push rbx sub rsp, 10h mov r14, rdi mov rdx, [r8] mov rcx, [r8+8] xor r12d, r12d xor esi, esi xor r8d, r8d call JS_ToCStringLen2 mov ebx, 6 test rax, rax jz loc_1643B mov r15, rax lea rsi, [rsp+38h+var_30] mov rdi, r14 mov rdx, rax call js_load_file test rax, rax jz short loc_16419 mov r12, rax mov rdx, [rsp+38h+var_30] mov rdi, r14 mov rsi, rax mov rcx, r15 xor r8d, r8d call JS_Eval mov r13, rax mov rbx, rdx mov rdi, r14 mov rsi, r12 call js_free mov rdi, r14 mov rsi, r15 call JS_FreeCString mov rax, 0FFFFFFFF00000000h and rax, r13 mov r12d, r13d jmp short loc_1643D loc_16419: lea rsi, aCouldNotLoadS; "could not load '%s'" xor r12d, r12d mov rdi, r14 mov rdx, r15 xor eax, eax call JS_ThrowReferenceError mov rdi, r14 mov rsi, r15 call JS_FreeCString loc_1643B: xor eax, eax loc_1643D: or r12, rax mov rax, r12 mov rdx, rbx add rsp, 10h pop rbx pop r12 pop r13 pop r14 pop r15 retn
unsigned long long js_loadScript(long long a1, long long a2, long long a3, long long a4, _QWORD *a5) { long long v5; // r12 long long v6; // rax long long v7; // r15 long long file; // rax int v9; // ecx int v10; // r8d int v11; // r9d long long v12; // r12 long long v13; // r13 unsigned long long v14; // rax long long v16[6]; // [rsp+8h] [rbp-30h] BYREF v5 = 0LL; v6 = JS_ToCStringLen2(a1, 0LL, *a5, a5[1], 0LL); if ( !v6 ) goto LABEL_5; v7 = v6; file = js_load_file(a1, v16, v6); if ( !file ) { v5 = 0LL; JS_ThrowReferenceError(a1, (unsigned int)"could not load '%s'", v7, v9, v10, v11); JS_FreeCString(a1, v7); LABEL_5: v14 = 0LL; return v14 | v5; } v12 = file; v13 = JS_Eval(a1, file, v16[0], v7, 0LL); js_free(a1, v12); JS_FreeCString(a1, v7); v14 = v13 & 0xFFFFFFFF00000000LL; v5 = (unsigned int)v13; return v14 | v5; }
js_loadScript: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x10 MOV R14,RDI MOV RDX,qword ptr [R8] MOV RCX,qword ptr [R8 + 0x8] XOR R12D,R12D XOR ESI,ESI XOR R8D,R8D CALL 0x0011ffe3 MOV EBX,0x6 TEST RAX,RAX JZ 0x0011643b MOV R15,RAX LEA RSI,[RSP + 0x8] MOV RDI,R14 MOV RDX,RAX CALL 0x00113b34 TEST RAX,RAX JZ 0x00116419 MOV R12,RAX MOV RDX,qword ptr [RSP + 0x8] MOV RDI,R14 MOV RSI,RAX MOV RCX,R15 XOR R8D,R8D CALL 0x00130926 MOV R13,RAX MOV RBX,RDX MOV RDI,R14 MOV RSI,R12 CALL 0x0011bf85 MOV RDI,R14 MOV RSI,R15 CALL 0x001202c9 MOV RAX,-0x100000000 AND RAX,R13 MOV R12D,R13D JMP 0x0011643d LAB_00116419: LEA RSI,[0x19a592] XOR R12D,R12D MOV RDI,R14 MOV RDX,R15 XOR EAX,EAX CALL 0x001219e9 MOV RDI,R14 MOV RSI,R15 CALL 0x001202c9 LAB_0011643b: XOR EAX,EAX LAB_0011643d: OR R12,RAX MOV RAX,R12 MOV RDX,RBX ADD RSP,0x10 POP RBX POP R12 POP R13 POP R14 POP R15 RET
int1 [16] js_loadScript(int8 param_1) { long lVar1; long lVar2; ulong uVar3; int8 uVar4; int8 *in_R8; ulong uVar5; int1 auVar6 [16]; int8 local_30; lVar1 = JS_ToCStringLen2(param_1,0,*in_R8,in_R8[1],0); uVar4 = 6; if (lVar1 != 0) { lVar2 = js_load_file(param_1,&local_30,lVar1); if (lVar2 != 0) { auVar6 = JS_Eval(param_1,lVar2,local_30,lVar1,0); uVar4 = auVar6._8_8_; js_free(param_1,lVar2); JS_FreeCString(param_1,lVar1); uVar3 = auVar6._0_8_ & 0xffffffff00000000; uVar5 = auVar6._0_8_ & 0xffffffff; goto LAB_0011643d; } JS_ThrowReferenceError(param_1,"could not load \'%s\'",lVar1); JS_FreeCString(param_1,lVar1); } uVar5 = 0; uVar3 = 0; LAB_0011643d: auVar6._8_8_ = uVar4; auVar6._0_8_ = uVar5 | uVar3; return auVar6; }
3,539
js_loadScript
bluesky950520[P]quickjs/quickjs-libc.c
static JSValue js_loadScript(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { uint8_t *buf; const char *filename; JSValue ret; size_t buf_len; filename = JS_ToCString(ctx, argv[0]); if (!filename) return JS_EXCEPTION; buf = js_load_file(ctx, &buf_len, filename); if (!buf) { JS_ThrowReferenceError(ctx, "could not load '%s'", filename); JS_FreeCString(ctx, filename); return JS_EXCEPTION; } ret = JS_Eval(ctx, (char *)buf, buf_len, filename, JS_EVAL_TYPE_GLOBAL); js_free(ctx, buf); JS_FreeCString(ctx, filename); return ret; }
O2
c
js_loadScript: pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x10, %rsp movq %rdi, %r14 movq (%r8), %rsi movq 0x8(%r8), %rdx callq 0x10ef0 pushq $0x6 popq %rbx testq %rax, %rax je 0x1129d movq %rax, %r15 leaq 0x8(%rsp), %rsi movq %r14, %rdi movq %rax, %rdx callq 0xeb90 testq %rax, %rax je 0x112a2 movq %rax, %r12 movq 0x8(%rsp), %rdx movq %r14, %rdi movq %rax, %rsi movq %r15, %rcx xorl %r8d, %r8d callq 0x28e8d movq %rax, %r13 movq %rdx, %rbx movq %r14, %rdi movq %r12, %rsi callq 0x166f2 movq %r14, %rdi movq %r15, %rsi callq 0x1a4db movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000 andq %r13, %rax movl %r13d, %r12d jmp 0x112c6 xorl %r12d, %r12d jmp 0x112c4 leaq 0x70295(%rip), %rsi # 0x8153e xorl %r12d, %r12d movq %r14, %rdi movq %r15, %rdx xorl %eax, %eax callq 0x1bb63 movq %r14, %rdi movq %r15, %rsi callq 0x1a4db xorl %eax, %eax orq %rax, %r12 movq %r12, %rax movq %rbx, %rdx addq $0x10, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq
js_loadScript: push r15 push r14 push r13 push r12 push rbx sub rsp, 10h mov r14, rdi mov rsi, [r8] mov rdx, [r8+8] call JS_ToCString push 6 pop rbx test rax, rax jz short loc_1129D mov r15, rax lea rsi, [rsp+38h+var_30] mov rdi, r14 mov rdx, rax call js_load_file test rax, rax jz short loc_112A2 mov r12, rax mov rdx, [rsp+38h+var_30] mov rdi, r14 mov rsi, rax mov rcx, r15 xor r8d, r8d call JS_Eval mov r13, rax mov rbx, rdx mov rdi, r14 mov rsi, r12 call js_free mov rdi, r14 mov rsi, r15 call JS_FreeCString mov rax, 0FFFFFFFF00000000h and rax, r13 mov r12d, r13d jmp short loc_112C6 loc_1129D: xor r12d, r12d jmp short loc_112C4 loc_112A2: lea rsi, aCouldNotLoadS; "could not load '%s'" xor r12d, r12d mov rdi, r14 mov rdx, r15 xor eax, eax call JS_ThrowReferenceError mov rdi, r14 mov rsi, r15 call JS_FreeCString loc_112C4: xor eax, eax loc_112C6: or r12, rax mov rax, r12 mov rdx, rbx add rsp, 10h pop rbx pop r12 pop r13 pop r14 pop r15 retn
unsigned long long js_loadScript(long long a1, long long a2, long long a3, long long a4, long long *a5) { long long v5; // rax long long v6; // r15 long long file; // rax int v8; // ecx int v9; // r8d int v10; // r9d long long v11; // r12 long long v12; // r13 unsigned long long v13; // rax long long v14; // r12 long long v16[6]; // [rsp+8h] [rbp-30h] BYREF v5 = JS_ToCString(a1, *a5, a5[1]); if ( !v5 ) { v14 = 0LL; LABEL_6: v13 = 0LL; return v13 | v14; } v6 = v5; file = js_load_file(a1, v16, v5); if ( !file ) { v14 = 0LL; JS_ThrowReferenceError(a1, (unsigned int)"could not load '%s'", v6, v8, v9, v10); JS_FreeCString(a1, v6); goto LABEL_6; } v11 = file; v12 = JS_Eval(a1, file, v16[0], v6, 0LL); js_free(a1, v11); JS_FreeCString(a1, v6); v13 = v12 & 0xFFFFFFFF00000000LL; v14 = (unsigned int)v12; return v13 | v14; }
js_loadScript: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x10 MOV R14,RDI MOV RSI,qword ptr [R8] MOV RDX,qword ptr [R8 + 0x8] CALL 0x00110ef0 PUSH 0x6 POP RBX TEST RAX,RAX JZ 0x0011129d MOV R15,RAX LEA RSI,[RSP + 0x8] MOV RDI,R14 MOV RDX,RAX CALL 0x0010eb90 TEST RAX,RAX JZ 0x001112a2 MOV R12,RAX MOV RDX,qword ptr [RSP + 0x8] MOV RDI,R14 MOV RSI,RAX MOV RCX,R15 XOR R8D,R8D CALL 0x00128e8d MOV R13,RAX MOV RBX,RDX MOV RDI,R14 MOV RSI,R12 CALL 0x001166f2 MOV RDI,R14 MOV RSI,R15 CALL 0x0011a4db MOV RAX,-0x100000000 AND RAX,R13 MOV R12D,R13D JMP 0x001112c6 LAB_0011129d: XOR R12D,R12D JMP 0x001112c4 LAB_001112a2: LEA RSI,[0x18153e] XOR R12D,R12D MOV RDI,R14 MOV RDX,R15 XOR EAX,EAX CALL 0x0011bb63 MOV RDI,R14 MOV RSI,R15 CALL 0x0011a4db LAB_001112c4: XOR EAX,EAX LAB_001112c6: OR R12,RAX MOV RAX,R12 MOV RDX,RBX ADD RSP,0x10 POP RBX POP R12 POP R13 POP R14 POP R15 RET
int1 [16] js_loadScript(int8 param_1) { long lVar1; long lVar2; ulong uVar3; int8 uVar4; int8 *in_R8; ulong uVar5; int1 auVar6 [16]; int8 local_30; lVar1 = JS_ToCString(param_1,*in_R8,in_R8[1]); uVar4 = 6; if (lVar1 != 0) { lVar2 = js_load_file(param_1,&local_30,lVar1); if (lVar2 != 0) { auVar6 = JS_Eval(param_1,lVar2,local_30,lVar1,0); uVar4 = auVar6._8_8_; js_free(param_1,lVar2); JS_FreeCString(param_1,lVar1); uVar3 = auVar6._0_8_ & 0xffffffff00000000; uVar5 = auVar6._0_8_ & 0xffffffff; goto LAB_001112c6; } JS_ThrowReferenceError(param_1,"could not load \'%s\'",lVar1); JS_FreeCString(param_1,lVar1); } uVar5 = 0; uVar3 = 0; LAB_001112c6: auVar6._8_8_ = uVar4; auVar6._0_8_ = uVar5 | uVar3; return auVar6; }
3,540
js_loadScript
bluesky950520[P]quickjs/quickjs-libc.c
static JSValue js_loadScript(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { uint8_t *buf; const char *filename; JSValue ret; size_t buf_len; filename = JS_ToCString(ctx, argv[0]); if (!filename) return JS_EXCEPTION; buf = js_load_file(ctx, &buf_len, filename); if (!buf) { JS_ThrowReferenceError(ctx, "could not load '%s'", filename); JS_FreeCString(ctx, filename); return JS_EXCEPTION; } ret = JS_Eval(ctx, (char *)buf, buf_len, filename, JS_EVAL_TYPE_GLOBAL); js_free(ctx, buf); JS_FreeCString(ctx, filename); return ret; }
O3
c
js_loadScript: pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x10, %rsp movq %rdi, %r14 movq (%r8), %rdx movq 0x8(%r8), %rcx xorl %r12d, %r12d xorl %esi, %esi xorl %r8d, %r8d callq 0x20717 movl $0x6, %ebx testq %rax, %rax je 0x16e0c movq %rax, %r15 leaq 0x8(%rsp), %rsi movq %r14, %rdi movq %rax, %rdx callq 0x14574 testq %rax, %rax je 0x16dea movq %rax, %r12 movq 0x8(%rsp), %rdx movq %r14, %rdi movq %rax, %rsi movq %r15, %rcx xorl %r8d, %r8d callq 0x319d6 movq %rax, %r13 movq %rdx, %rbx movq %r14, %rdi movq %r12, %rsi callq 0x1c845 movq %r14, %rdi movq %r15, %rsi callq 0x209ed movabsq $-0x100000000, %rax # imm = 0xFFFFFFFF00000000 andq %r13, %rax movl %r13d, %r12d jmp 0x16e0e leaq 0x8674d(%rip), %rsi # 0x9d53e xorl %r12d, %r12d movq %r14, %rdi movq %r15, %rdx xorl %eax, %eax callq 0x221e5 movq %r14, %rdi movq %r15, %rsi callq 0x209ed xorl %eax, %eax orq %rax, %r12 movq %r12, %rax movq %rbx, %rdx addq $0x10, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq
js_loadScript: push r15 push r14 push r13 push r12 push rbx sub rsp, 10h mov r14, rdi mov rdx, [r8] mov rcx, [r8+8] xor r12d, r12d xor esi, esi xor r8d, r8d call JS_ToCStringLen2 mov ebx, 6 test rax, rax jz loc_16E0C mov r15, rax lea rsi, [rsp+38h+var_30] mov rdi, r14 mov rdx, rax call js_load_file test rax, rax jz short loc_16DEA mov r12, rax mov rdx, [rsp+38h+var_30] mov rdi, r14 mov rsi, rax mov rcx, r15 xor r8d, r8d call JS_Eval mov r13, rax mov rbx, rdx mov rdi, r14 mov rsi, r12 call js_free mov rdi, r14 mov rsi, r15 call JS_FreeCString mov rax, 0FFFFFFFF00000000h and rax, r13 mov r12d, r13d jmp short loc_16E0E loc_16DEA: lea rsi, aCouldNotLoadS; "could not load '%s'" xor r12d, r12d mov rdi, r14 mov rdx, r15 xor eax, eax call JS_ThrowReferenceError mov rdi, r14 mov rsi, r15 call JS_FreeCString loc_16E0C: xor eax, eax loc_16E0E: or r12, rax mov rax, r12 mov rdx, rbx add rsp, 10h pop rbx pop r12 pop r13 pop r14 pop r15 retn
unsigned long long js_loadScript(long long a1, long long a2, long long a3, long long a4, _QWORD *a5) { long long v5; // r12 long long v6; // rax long long v7; // r15 long long file; // rax int v9; // ecx int v10; // r8d int v11; // r9d long long v12; // r12 long long v13; // r13 unsigned long long v14; // rax long long v16[6]; // [rsp+8h] [rbp-30h] BYREF v5 = 0LL; v6 = JS_ToCStringLen2(a1, 0LL, *a5, a5[1], 0LL); if ( !v6 ) goto LABEL_5; v7 = v6; file = js_load_file(a1, v16, v6); if ( !file ) { v5 = 0LL; JS_ThrowReferenceError(a1, (unsigned int)"could not load '%s'", v7, v9, v10, v11); JS_FreeCString(a1, v7); LABEL_5: v14 = 0LL; return v14 | v5; } v12 = file; v13 = JS_Eval(a1, file, v16[0], v7, 0LL); js_free(a1, v12); JS_FreeCString(a1, v7); v14 = v13 & 0xFFFFFFFF00000000LL; v5 = (unsigned int)v13; return v14 | v5; }
js_loadScript: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x10 MOV R14,RDI MOV RDX,qword ptr [R8] MOV RCX,qword ptr [R8 + 0x8] XOR R12D,R12D XOR ESI,ESI XOR R8D,R8D CALL 0x00120717 MOV EBX,0x6 TEST RAX,RAX JZ 0x00116e0c MOV R15,RAX LEA RSI,[RSP + 0x8] MOV RDI,R14 MOV RDX,RAX CALL 0x00114574 TEST RAX,RAX JZ 0x00116dea MOV R12,RAX MOV RDX,qword ptr [RSP + 0x8] MOV RDI,R14 MOV RSI,RAX MOV RCX,R15 XOR R8D,R8D CALL 0x001319d6 MOV R13,RAX MOV RBX,RDX MOV RDI,R14 MOV RSI,R12 CALL 0x0011c845 MOV RDI,R14 MOV RSI,R15 CALL 0x001209ed MOV RAX,-0x100000000 AND RAX,R13 MOV R12D,R13D JMP 0x00116e0e LAB_00116dea: LEA RSI,[0x19d53e] XOR R12D,R12D MOV RDI,R14 MOV RDX,R15 XOR EAX,EAX CALL 0x001221e5 MOV RDI,R14 MOV RSI,R15 CALL 0x001209ed LAB_00116e0c: XOR EAX,EAX LAB_00116e0e: OR R12,RAX MOV RAX,R12 MOV RDX,RBX ADD RSP,0x10 POP RBX POP R12 POP R13 POP R14 POP R15 RET
int1 [16] js_loadScript(int8 param_1) { long lVar1; long lVar2; ulong uVar3; int8 uVar4; int8 *in_R8; ulong uVar5; int1 auVar6 [16]; int8 local_30; lVar1 = JS_ToCStringLen2(param_1,0,*in_R8,in_R8[1],0); uVar4 = 6; if (lVar1 != 0) { lVar2 = js_load_file(param_1,&local_30,lVar1); if (lVar2 != 0) { auVar6 = JS_Eval(param_1,lVar2,local_30,lVar1,0); uVar4 = auVar6._8_8_; js_free(param_1,lVar2); JS_FreeCString(param_1,lVar1); uVar3 = auVar6._0_8_ & 0xffffffff00000000; uVar5 = auVar6._0_8_ & 0xffffffff; goto LAB_00116e0e; } JS_ThrowReferenceError(param_1,"could not load \'%s\'",lVar1); JS_FreeCString(param_1,lVar1); } uVar5 = 0; uVar3 = 0; LAB_00116e0e: auVar6._8_8_ = uVar4; auVar6._0_8_ = uVar5 | uVar3; return auVar6; }
3,541
minja::ElifTemplateToken::~ElifTemplateToken()
monkey531[P]llama/common/minja.hpp
ElifTemplateToken(const Location & location, SpaceHandling pre, SpaceHandling post, std::shared_ptr<Expression> && c) : TemplateToken(Type::Elif, location, pre, post), condition(std::move(c)) {}
O1
cpp
minja::ElifTemplateToken::~ElifTemplateToken(): pushq %rbx movq %rdi, %rbx leaq 0x9aa0b(%rip), %rax # 0x157b58 addq $0x10, %rax movq %rax, (%rdi) movq 0x38(%rdi), %rdi testq %rdi, %rdi je 0xbd162 callq 0x520bc leaq 0x9a16f(%rip), %rax # 0x1572d8 addq $0x10, %rax movq %rax, (%rbx) movq 0x18(%rbx), %rdi testq %rdi, %rdi je 0xbd17f popq %rbx jmp 0x520bc popq %rbx retq nop
_ZN5minja17ElifTemplateTokenD2Ev: push rbx mov rbx, rdi lea rax, _ZTVN5minja17ElifTemplateTokenE; `vtable for'minja::ElifTemplateToken add rax, 10h mov [rdi], rax mov rdi, [rdi+38h] test rdi, rdi jz short loc_BD162 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_BD162: lea rax, _ZTVN5minja13TemplateTokenE; `vtable for'minja::TemplateToken add rax, 10h mov [rbx], rax mov rdi, [rbx+18h] test rdi, rdi jz short loc_BD17F pop rbx jmp _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_BD17F: pop rbx retn
void minja::ElifTemplateToken::~ElifTemplateToken(minja::ElifTemplateToken *this) { volatile signed __int32 *v2; // rdi volatile signed __int32 *v3; // rdi *(_QWORD *)this = &`vtable for'minja::ElifTemplateToken + 2; v2 = (volatile signed __int32 *)*((_QWORD *)this + 7); if ( v2 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v2); *(_QWORD *)this = &`vtable for'minja::TemplateToken + 2; v3 = (volatile signed __int32 *)*((_QWORD *)this + 3); if ( v3 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v3); }
~ElifTemplateToken: PUSH RBX MOV RBX,RDI LEA RAX,[0x257b58] ADD RAX,0x10 MOV qword ptr [RDI],RAX MOV RDI,qword ptr [RDI + 0x38] TEST RDI,RDI JZ 0x001bd162 CALL 0x001520bc LAB_001bd162: LEA RAX,[0x2572d8] ADD RAX,0x10 MOV qword ptr [RBX],RAX MOV RDI,qword ptr [RBX + 0x18] TEST RDI,RDI JZ 0x001bd17f POP RBX JMP 0x001520bc LAB_001bd17f: POP RBX RET
/* minja::ElifTemplateToken::~ElifTemplateToken() */ void __thiscall minja::ElifTemplateToken::~ElifTemplateToken(ElifTemplateToken *this) { *(int ***)this = &PTR__ElifTemplateToken_00257b68; if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x38) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x38)); } *(int ***)this = &PTR__TemplateToken_002572e8; if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x18) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x18)); return; } return; }
3,542
minja::ElifTemplateToken::~ElifTemplateToken()
monkey531[P]llama/common/minja.hpp
ElifTemplateToken(const Location & location, SpaceHandling pre, SpaceHandling post, std::shared_ptr<Expression> && c) : TemplateToken(Type::Elif, location, pre, post), condition(std::move(c)) {}
O3
cpp
minja::ElifTemplateToken::~ElifTemplateToken(): pushq %rbx movq %rdi, %rbx leaq 0x98ae9(%rip), %rax # 0x154b58 addq $0x10, %rax movq %rax, (%rdi) movq 0x38(%rdi), %rdi testq %rdi, %rdi je 0xbc084 callq 0x516f8 leaq 0x9824d(%rip), %rax # 0x1542d8 addq $0x10, %rax movq %rax, (%rbx) movq 0x18(%rbx), %rdi testq %rdi, %rdi je 0xbc0a1 popq %rbx jmp 0x516f8 popq %rbx retq nop
_ZN5minja17ElifTemplateTokenD2Ev: push rbx mov rbx, rdi lea rax, _ZTVN5minja17ElifTemplateTokenE; `vtable for'minja::ElifTemplateToken add rax, 10h mov [rdi], rax mov rdi, [rdi+38h] test rdi, rdi jz short loc_BC084 call _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_BC084: lea rax, _ZTVN5minja13TemplateTokenE; `vtable for'minja::TemplateToken add rax, 10h mov [rbx], rax mov rdi, [rbx+18h] test rdi, rdi jz short loc_BC0A1 pop rbx jmp _ZNSt16_Sp_counted_baseILN9__gnu_cxx12_Lock_policyE2EE10_M_releaseEv; std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(void) loc_BC0A1: pop rbx retn
void minja::ElifTemplateToken::~ElifTemplateToken(minja::ElifTemplateToken *this) { volatile signed __int32 *v2; // rdi volatile signed __int32 *v3; // rdi *(_QWORD *)this = &`vtable for'minja::ElifTemplateToken + 2; v2 = (volatile signed __int32 *)*((_QWORD *)this + 7); if ( v2 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v2); *(_QWORD *)this = &`vtable for'minja::TemplateToken + 2; v3 = (volatile signed __int32 *)*((_QWORD *)this + 3); if ( v3 ) std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release(v3); }
~ElifTemplateToken: PUSH RBX MOV RBX,RDI LEA RAX,[0x254b58] ADD RAX,0x10 MOV qword ptr [RDI],RAX MOV RDI,qword ptr [RDI + 0x38] TEST RDI,RDI JZ 0x001bc084 CALL 0x001516f8 LAB_001bc084: LEA RAX,[0x2542d8] ADD RAX,0x10 MOV qword ptr [RBX],RAX MOV RDI,qword ptr [RBX + 0x18] TEST RDI,RDI JZ 0x001bc0a1 POP RBX JMP 0x001516f8 LAB_001bc0a1: POP RBX RET
/* minja::ElifTemplateToken::~ElifTemplateToken() */ void __thiscall minja::ElifTemplateToken::~ElifTemplateToken(ElifTemplateToken *this) { *(int ***)this = &PTR__ElifTemplateToken_00254b68; if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x38) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x38)); } *(int ***)this = &PTR__TemplateToken_002542e8; if (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x18) != (_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> *)0x0) { std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (*(_Sp_counted_base<(__gnu_cxx::_Lock_policy)2> **)(this + 0x18)); return; } return; }
3,543
fmt::v10::appender fmt::v10::detail::write_codepoint<4ul, char, fmt::v10::appender>(fmt::v10::appender, char, unsigned int)
aimrt_mujoco_sim/_deps/fmt-src/include/fmt/format.h
auto write_codepoint(OutputIt out, char prefix, uint32_t cp) -> OutputIt { *out++ = static_cast<Char>('\\'); *out++ = static_cast<Char>(prefix); Char buf[width]; fill_n(buf, width, static_cast<Char>('0')); format_uint<4>(buf, cp, width); return copy_str<Char>(buf, buf + width, out); }
O0
c
fmt::v10::appender fmt::v10::detail::write_codepoint<4ul, char, fmt::v10::appender>(fmt::v10::appender, char, unsigned int): subq $0x48, %rsp movb %sil, %al movq %rdi, 0x38(%rsp) movb %al, 0x37(%rsp) movl %edx, 0x30(%rsp) movb $0x5c, 0x2f(%rsp) leaq 0x38(%rsp), %rdi xorl %esi, %esi callq 0xc6910 movq %rax, 0x20(%rsp) leaq 0x20(%rsp), %rdi callq 0xc6940 leaq 0x2e(%rsp), %rdi leaq 0x2f(%rsp), %rsi callq 0xc6950 movb 0x37(%rsp), %al movb %al, 0x1e(%rsp) leaq 0x38(%rsp), %rdi xorl %esi, %esi callq 0xc6910 movq %rax, 0x10(%rsp) leaq 0x10(%rsp), %rdi callq 0xc6940 leaq 0x1d(%rsp), %rdi leaq 0x1e(%rsp), %rsi callq 0xc6950 leaq 0xb(%rsp), %rdi movl $0x4, %esi movl $0x30, %edx callq 0xa6c20 leaq 0xb(%rsp), %rdi movl 0x30(%rsp), %esi movl $0x4, %edx xorl %ecx, %ecx callq 0xa6c80 leaq 0xb(%rsp), %rdi leaq 0xb(%rsp), %rsi addq $0x4, %rsi movq 0x38(%rsp), %rax movq %rax, (%rsp) movq (%rsp), %rdx callq 0xc73f0 movq %rax, 0x40(%rsp) movq 0x40(%rsp), %rax addq $0x48, %rsp retq nopl (%rax)
_ZN3fmt3v106detail15write_codepointILm4EcNS1_17counting_iteratorEEET1_S4_cj: sub rsp, 48h mov al, sil mov [rsp+48h+var_10], rdi mov [rsp+48h+var_11], al mov [rsp+48h+var_18], edx mov [rsp+48h+var_19], 5Ch ; '\' lea rdi, [rsp+48h+var_10] xor esi, esi call _ZN3fmt3v106detail17counting_iteratorppEi; fmt::v10::detail::counting_iterator::operator++(int) mov [rsp+48h+var_28], rax lea rdi, [rsp+48h+var_28] call _ZNK3fmt3v106detail17counting_iteratordeEv; fmt::v10::detail::counting_iterator::operator*(void) lea rdi, [rsp+48h+var_1A] lea rsi, [rsp+48h+var_19] call _ZN3fmt3v106detail17counting_iterator10value_typeaSIcEEvRKT_; fmt::v10::detail::counting_iterator::value_type::operator=<char>(char const&) mov al, [rsp+48h+var_11] mov [rsp+48h+var_2A], al lea rdi, [rsp+48h+var_10] xor esi, esi call _ZN3fmt3v106detail17counting_iteratorppEi; fmt::v10::detail::counting_iterator::operator++(int) mov [rsp+48h+var_38], rax lea rdi, [rsp+48h+var_38] call _ZNK3fmt3v106detail17counting_iteratordeEv; fmt::v10::detail::counting_iterator::operator*(void) lea rdi, [rsp+48h+var_2B] lea rsi, [rsp+48h+var_2A] call _ZN3fmt3v106detail17counting_iterator10value_typeaSIcEEvRKT_; fmt::v10::detail::counting_iterator::value_type::operator=<char>(char const&) lea rdi, [rsp+48h+var_3D] mov esi, 4 mov edx, 30h ; '0' call _ZN3fmt3v106detail6fill_nIcmEEPT_S4_T0_c; fmt::v10::detail::fill_n<char,ulong>(char *,ulong,char) lea rdi, [rsp+48h+var_3D] mov esi, [rsp+48h+var_18] mov edx, 4 xor ecx, ecx call _ZN3fmt3v106detail11format_uintILj4EcjEEPT0_S4_T1_ib; fmt::v10::detail::format_uint<4u,char,uint>(char *,uint,int,bool) lea rdi, [rsp+48h+var_3D] lea rsi, [rsp+48h+var_3D] add rsi, 4 mov rax, [rsp+48h+var_10] mov [rsp+48h+var_48], rax mov rdx, [rsp+48h+var_48] call _ZN3fmt3v106detail8copy_strIcPcNS1_17counting_iteratorEEET1_T0_S6_S5_; fmt::v10::detail::copy_str<char,char *,fmt::v10::detail::counting_iterator>(char *,char *,fmt::v10::detail::counting_iterator) mov [rsp+48h+var_8], rax mov rax, [rsp+48h+var_8] add rsp, 48h retn
long long fmt::v10::detail::write_codepoint<4ul,char,fmt::v10::detail::counting_iterator>( long long a1, char a2, unsigned int a3) { _BYTE v4[4]; // [rsp+Bh] [rbp-3Dh] BYREF _BYTE v5[17]; // [rsp+Fh] [rbp-39h] BYREF long long v6; // [rsp+20h] [rbp-28h] char v7; // [rsp+2Fh] [rbp-19h] unsigned int v8; // [rsp+30h] [rbp-18h] char v9; // [rsp+37h] [rbp-11h] long long v10; // [rsp+38h] [rbp-10h] BYREF v10 = a1; v9 = a2; v8 = a3; v7 = 92; v6 = fmt::v10::detail::counting_iterator::operator++(&v10); fmt::v10::detail::counting_iterator::operator*(); fmt::v10::detail::counting_iterator::value_type::operator=<char>(); v5[15] = a2; *(_QWORD *)&v5[1] = fmt::v10::detail::counting_iterator::operator++(&v10); fmt::v10::detail::counting_iterator::operator*(); fmt::v10::detail::counting_iterator::value_type::operator=<char>(); fmt::v10::detail::fill_n<char,unsigned long>((long long)v4, 4LL, 0x30u); fmt::v10::detail::format_uint<4u,char,unsigned int>((long long)v4, v8, 4, 0); return fmt::v10::detail::copy_str<char,char *,fmt::v10::detail::counting_iterator>(v4, v5, v10); }
write_codepoint<4ul,char,fmt::v10::detail::counting_iterator>: SUB RSP,0x48 MOV AL,SIL MOV qword ptr [RSP + 0x38],RDI MOV byte ptr [RSP + 0x37],AL MOV dword ptr [RSP + 0x30],EDX MOV byte ptr [RSP + 0x2f],0x5c LEA RDI,[RSP + 0x38] XOR ESI,ESI CALL 0x001c6910 MOV qword ptr [RSP + 0x20],RAX LEA RDI,[RSP + 0x20] CALL 0x001c6940 LEA RDI,[RSP + 0x2e] LEA RSI,[RSP + 0x2f] CALL 0x001c6950 MOV AL,byte ptr [RSP + 0x37] MOV byte ptr [RSP + 0x1e],AL LEA RDI,[RSP + 0x38] XOR ESI,ESI CALL 0x001c6910 MOV qword ptr [RSP + 0x10],RAX LEA RDI,[RSP + 0x10] CALL 0x001c6940 LEA RDI,[RSP + 0x1d] LEA RSI,[RSP + 0x1e] CALL 0x001c6950 LEA RDI,[RSP + 0xb] MOV ESI,0x4 MOV EDX,0x30 CALL 0x001a6c20 LEA RDI,[RSP + 0xb] MOV ESI,dword ptr [RSP + 0x30] MOV EDX,0x4 XOR ECX,ECX CALL 0x001a6c80 LEA RDI,[RSP + 0xb] LEA RSI,[RSP + 0xb] ADD RSI,0x4 MOV RAX,qword ptr [RSP + 0x38] MOV qword ptr [RSP],RAX MOV RDX,qword ptr [RSP] CALL 0x001c73f0 MOV qword ptr [RSP + 0x40],RAX MOV RAX,qword ptr [RSP + 0x40] ADD RSP,0x48 RET
/* fmt::v10::detail::counting_iterator fmt::v10::detail::write_codepoint<4ul, char, fmt::v10::detail::counting_iterator>(fmt::v10::detail::counting_iterator, char, unsigned int) */ int8 fmt::v10::detail::write_codepoint<4ul,char,fmt::v10::detail::counting_iterator> (int8 param_1,char param_2,uint param_3) { int8 uVar1; char local_3d [4]; int1 uStack_39; int8 local_38; value_type local_2b; char local_2a [2]; int8 local_28; value_type local_1a; char local_19; uint local_18; char local_11; int8 local_10 [2]; local_19 = '\\'; local_18 = param_3; local_11 = param_2; local_10[0] = param_1; local_28 = counting_iterator::operator++((counting_iterator *)local_10,0); counting_iterator::operator*((counting_iterator *)&local_28); counting_iterator::value_type::operator=(&local_1a,&local_19); local_2a[0] = local_11; local_38 = counting_iterator::operator++((counting_iterator *)local_10,0); counting_iterator::operator*((counting_iterator *)&local_38); counting_iterator::value_type::operator=(&local_2b,local_2a); fill_n<char,unsigned_long>(local_3d,4,'0'); format_uint<4u,char,unsigned_int>(local_3d,local_18,4,false); uVar1 = copy_str<char,char*,fmt::v10::detail::counting_iterator>(local_3d,&uStack_39,local_10[0]); return uVar1; }
3,544
fmt::v10::appender fmt::v10::detail::write_codepoint<4ul, char, fmt::v10::appender>(fmt::v10::appender, char, unsigned int)
aimrt_mujoco_sim/_deps/fmt-src/include/fmt/format.h
auto write_codepoint(OutputIt out, char prefix, uint32_t cp) -> OutputIt { *out++ = static_cast<Char>('\\'); *out++ = static_cast<Char>(prefix); Char buf[width]; fill_n(buf, width, static_cast<Char>('0')); format_uint<4>(buf, cp, width); return copy_str<Char>(buf, buf + width, out); }
O3
c
fmt::v10::appender fmt::v10::detail::write_codepoint<4ul, char, fmt::v10::appender>(fmt::v10::appender, char, unsigned int): pushq %rbp pushq %r14 pushq %rbx subq $0x10, %rsp movl %edx, %ebp movl %esi, %r14d movq %rdi, %rbx movq 0x10(%rdi), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rdi) jae 0x3746a movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb $0x5c, (%rcx,%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi cmpq %rsi, 0x18(%rbx) jae 0x37494 movq (%rbx), %rax movq %rbx, %rdi callq *(%rax) movq 0x10(%rbx), %rax leaq 0x1(%rax), %rsi movq 0x8(%rbx), %rcx movq %rsi, 0x10(%rbx) movb %r14b, (%rcx,%rax) leaq 0x10(%rsp), %rdx movw $0x3030, -0x2(%rdx) # imm = 0x3030 leaq 0xf(%rsp), %rax leaq 0x12a29e(%rip), %rcx # 0x161755 movl %ebp, %esi movl %ebp, %edi andl $0xf, %edi movb (%rdi,%rcx), %dil movb %dil, (%rax) shrl $0x4, %esi decq %rax cmpl $0xf, %ebp movl %esi, %ebp ja 0x374b9 leaq 0xe(%rsp), %rsi movq %rbx, %rdi callq 0x348f8 movq %rbx, %rax addq $0x10, %rsp popq %rbx popq %r14 popq %rbp retq
_ZN3fmt3v106detail15write_codepointILm2EcNS0_8appenderEEET1_S4_cj: push rbp push r14 push rbx sub rsp, 10h mov ebp, edx mov r14d, esi mov rbx, rdi mov rax, [rdi+10h] lea rsi, [rax+1] cmp [rdi+18h], rsi jnb short loc_3746A mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_3746A: mov rcx, [rbx+8] mov [rbx+10h], rsi mov byte ptr [rcx+rax], 5Ch ; '\' mov rax, [rbx+10h] lea rsi, [rax+1] cmp [rbx+18h], rsi jnb short loc_37494 mov rax, [rbx] mov rdi, rbx call qword ptr [rax] mov rax, [rbx+10h] lea rsi, [rax+1] loc_37494: mov rcx, [rbx+8] mov [rbx+10h], rsi mov [rcx+rax], r14b lea rdx, [rsp+28h+var_18] mov word ptr [rdx-2], 3030h lea rax, [rsp+28h+var_19] lea rcx, a0123456789abcd_0; "0123456789abcdef" mov esi, ebp loc_374B9: mov edi, ebp and edi, 0Fh mov dil, [rdi+rcx] mov [rax], dil shr esi, 4 dec rax cmp ebp, 0Fh mov ebp, esi ja short loc_374B9 lea rsi, [rsp+28h+var_1A] mov rdi, rbx call _ZN3fmt3v106detail6bufferIcE6appendIcEEvPKT_S7_; fmt::v10::detail::buffer<char>::append<char>(char const*,char const*) mov rax, rbx add rsp, 10h pop rbx pop r14 pop rbp retn
long long fmt::v10::detail::write_codepoint<2ul,char,fmt::v10::appender>(long long a1, char a2, unsigned int a3) { long long v5; // rax long long v6; // rsi long long v7; // rcx long long v8; // rax long long v9; // rsi long long v10; // rcx _BYTE *v11; // rax unsigned int v12; // esi bool v13; // cc __int16 v15; // [rsp+Eh] [rbp-1Ah] BYREF _BYTE v16[24]; // [rsp+10h] [rbp-18h] BYREF v5 = *(_QWORD *)(a1 + 16); v6 = v5 + 1; if ( *(_QWORD *)(a1 + 24) < (unsigned long long)(v5 + 1) ) { (**(void ( ***)(long long))a1)(a1); v5 = *(_QWORD *)(a1 + 16); v6 = v5 + 1; } v7 = *(_QWORD *)(a1 + 8); *(_QWORD *)(a1 + 16) = v6; *(_BYTE *)(v7 + v5) = 92; v8 = *(_QWORD *)(a1 + 16); v9 = v8 + 1; if ( *(_QWORD *)(a1 + 24) < (unsigned long long)(v8 + 1) ) { (**(void ( ***)(long long))a1)(a1); v8 = *(_QWORD *)(a1 + 16); v9 = v8 + 1; } v10 = *(_QWORD *)(a1 + 8); *(_QWORD *)(a1 + 16) = v9; *(_BYTE *)(v10 + v8) = a2; v15 = 12336; v11 = (char *)&v15 + 1; v12 = a3; do { *v11 = a0123456789abcd_0[a3 & 0xF]; v12 >>= 4; --v11; v13 = a3 <= 0xF; a3 = v12; } while ( !v13 ); fmt::v10::detail::buffer<char>::append<char>(a1, (long long)&v15, (long long)v16); return a1; }
write_codepoint<2ul,char,fmt::v10::appender>: PUSH RBP PUSH R14 PUSH RBX SUB RSP,0x10 MOV EBP,EDX MOV R14D,ESI MOV RBX,RDI MOV RAX,qword ptr [RDI + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RDI + 0x18],RSI JNC 0x0013746a MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_0013746a: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],0x5c MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] CMP qword ptr [RBX + 0x18],RSI JNC 0x00137494 MOV RAX,qword ptr [RBX] MOV RDI,RBX CALL qword ptr [RAX] MOV RAX,qword ptr [RBX + 0x10] LEA RSI,[RAX + 0x1] LAB_00137494: MOV RCX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x10],RSI MOV byte ptr [RCX + RAX*0x1],R14B LEA RDX,[RSP + 0x10] MOV word ptr [RDX + -0x2],0x3030 LEA RAX,[RSP + 0xf] LEA RCX,[0x261755] MOV ESI,EBP LAB_001374b9: MOV EDI,EBP AND EDI,0xf MOV DIL,byte ptr [RDI + RCX*0x1] MOV byte ptr [RAX],DIL SHR ESI,0x4 DEC RAX CMP EBP,0xf MOV EBP,ESI JA 0x001374b9 LEA RSI,[RSP + 0xe] MOV RDI,RBX CALL 0x001348f8 MOV RAX,RBX ADD RSP,0x10 POP RBX POP R14 POP RBP RET
/* fmt::v10::appender fmt::v10::detail::write_codepoint<2ul, char, fmt::v10::appender>(fmt::v10::appender, char, unsigned int) */ buffer<char> * fmt::v10::detail::write_codepoint<2ul,char,fmt::v10::appender> (buffer<char> *param_1,int1 param_2,ulong param_3) { long lVar1; char *pcVar2; uint uVar3; ulong uVar4; char local_1a [2]; lVar1 = *(long *)(param_1 + 0x10); uVar4 = lVar1 + 1; if (*(ulong *)(param_1 + 0x18) < uVar4) { (*(code *)**(int8 **)param_1)(param_1); lVar1 = *(long *)(param_1 + 0x10); uVar4 = lVar1 + 1; } *(ulong *)(param_1 + 0x10) = uVar4; *(int1 *)(*(long *)(param_1 + 8) + lVar1) = 0x5c; lVar1 = *(long *)(param_1 + 0x10); uVar4 = lVar1 + 1; if (*(ulong *)(param_1 + 0x18) < uVar4) { (*(code *)**(int8 **)param_1)(param_1); lVar1 = *(long *)(param_1 + 0x10); uVar4 = lVar1 + 1; } *(ulong *)(param_1 + 0x10) = uVar4; *(int1 *)(*(long *)(param_1 + 8) + lVar1) = param_2; local_1a[0] = '0'; local_1a[1] = '0'; pcVar2 = local_1a + 1; param_3 = param_3 & 0xffffffff; do { uVar3 = (uint)param_3; *pcVar2 = "0123456789abcdef"[uVar3 & 0xf]; param_3 = param_3 >> 4; pcVar2 = pcVar2 + -1; } while (0xf < uVar3); buffer<char>::append<char>(param_1,local_1a,&stack0xffffffffffffffe8); return param_1; }
3,545
ok1
eloqsql/unittest/mytap/tap.c
void ok1(int const pass) { va_list ap; memset(&ap, 0, sizeof(ap)); if (!pass && *g_test.todo == '\0') ++g_test.failed; vemit_tap(pass, NULL, ap); if (*g_test.todo != '\0') emit_dir("todo", g_test.todo); emit_endl(); }
O3
c
ok1: pushq %rbp movq %rsp, %rbp pushq %rbx subq $0x18, %rsp xorps %xmm0, %xmm0 movaps %xmm0, -0x20(%rbp) movq $0x0, -0x10(%rbp) testl %edi, %edi jne 0x9150e cmpb $0x0, 0xb6e516(%rip) # 0xbffa1c jne 0x9150e incl 0xb6e50a(%rip) # 0xbffa18 leaq -0x20(%rbp), %rdx xorl %esi, %esi callq 0x91435 cmpb $0x0, 0xb6e4fc(%rip) # 0xbffa1c je 0x91555 movq 0x2f2a7f(%rip), %rbx # 0x383fa8 movq (%rbx), %rdi leaq 0x4aa9d(%rip), %rdx # 0xdbfd0 leaq 0x4aa25(%rip), %rcx # 0xdbf5f leaq 0xb6e4db(%rip), %r8 # 0xbffa1c movl $0x1, %esi xorl %eax, %eax callq 0x29200 movq (%rbx), %rdi callq 0x29400 movq 0x2f2a4c(%rip), %rbx # 0x383fa8 movq (%rbx), %rdi leaq 0x4e8b2(%rip), %rdx # 0xdfe18 movl $0x1, %esi xorl %eax, %eax callq 0x29200 movq (%rbx), %rdi callq 0x29400 addq $0x18, %rsp popq %rbx popq %rbp retq
ok1: push rbp mov rbp, rsp push rbx sub rsp, 18h xorps xmm0, xmm0 movaps [rbp+var_20], xmm0 mov [rbp+var_10], 0 test edi, edi jnz short loc_9150E cmp cs:byte_BFFA1C, 0 jnz short loc_9150E inc cs:dword_BFFA18 loc_9150E: lea rdx, [rbp+var_20] xor esi, esi call vemit_tap cmp cs:byte_BFFA1C, 0 jz short loc_91555 mov rbx, cs:stdout_ptr mov rdi, [rbx] lea rdx, aSS; " # %s %s" lea rcx, aTodo; "todo" lea r8, byte_BFFA1C mov esi, 1 xor eax, eax call ___fprintf_chk mov rdi, [rbx] call _fflush loc_91555: mov rbx, cs:stdout_ptr mov rdi, [rbx] lea rdx, asc_DFE15+3; "\n" mov esi, 1 xor eax, eax call ___fprintf_chk mov rdi, [rbx] call _fflush add rsp, 18h pop rbx pop rbp retn
long long ok1(int a1) { long long v1; // rcx long long v2; // r8 long long v3; // r9 __int128 v5; // [rsp+0h] [rbp-20h] BYREF long long v6; // [rsp+10h] [rbp-10h] v5 = 0LL; v6 = 0LL; if ( !a1 && !byte_BFFA1C ) ++dword_BFFA18; vemit_tap(a1, 0LL, (long long)&v5); if ( byte_BFFA1C ) { __fprintf_chk(stdout, 1LL, " # %s %s", "todo", &byte_BFFA1C); fflush(stdout); } __fprintf_chk(stdout, 1LL, "\n", v1, v2, v3, v5, v6); return fflush(stdout); }
ok1: PUSH RBP MOV RBP,RSP PUSH RBX SUB RSP,0x18 XORPS XMM0,XMM0 MOVAPS xmmword ptr [RBP + -0x20],XMM0 MOV qword ptr [RBP + -0x10],0x0 TEST EDI,EDI JNZ 0x0019150e CMP byte ptr [0x00cffa1c],0x0 JNZ 0x0019150e INC dword ptr [0x00cffa18] LAB_0019150e: LEA RDX,[RBP + -0x20] XOR ESI,ESI CALL 0x00191435 CMP byte ptr [0x00cffa1c],0x0 JZ 0x00191555 MOV RBX,qword ptr [0x00483fa8] MOV RDI,qword ptr [RBX] LEA RDX,[0x1dbfd0] LEA RCX,[0x1dbf5f] LEA R8,[0xcffa1c] MOV ESI,0x1 XOR EAX,EAX CALL 0x00129200 MOV RDI,qword ptr [RBX] CALL 0x00129400 LAB_00191555: MOV RBX,qword ptr [0x00483fa8] MOV RDI,qword ptr [RBX] LEA RDX,[0x1dfe18] MOV ESI,0x1 XOR EAX,EAX CALL 0x00129200 MOV RDI,qword ptr [RBX] CALL 0x00129400 ADD RSP,0x18 POP RBX POP RBP RET
void ok1(int8 param_1) { int *puVar1; int8 local_28; int8 uStack_20; int8 local_18; local_28 = 0; uStack_20 = 0; local_18 = 0; if (((int)param_1 == 0) && (DAT_00cffa1c == '\0')) { DAT_00cffa18 = DAT_00cffa18 + 1; } vemit_tap(param_1,0,&local_28); puVar1 = PTR_stdout_00483fa8; if (DAT_00cffa1c != '\0') { __fprintf_chk(*(int8 *)PTR_stdout_00483fa8,1," # %s %s",&DAT_001dbf5f,&DAT_00cffa1c); fflush(*(FILE **)puVar1); } puVar1 = PTR_stdout_00483fa8; __fprintf_chk(*(int8 *)PTR_stdout_00483fa8,1,&DAT_001dfe18); fflush(*(FILE **)puVar1); return; }
3,546
handle_posted_message
bluesky950520[P]quickjs/quickjs-libc.c
static int handle_posted_message(JSRuntime *rt, JSContext *ctx, JSWorkerMessageHandler *port) { JSWorkerMessagePipe *ps = port->recv_pipe; int ret; struct list_head *el; JSWorkerMessage *msg; JSValue obj, data_obj, func, retval; pthread_mutex_lock(&ps->mutex); if (!list_empty(&ps->msg_queue)) { el = ps->msg_queue.next; msg = list_entry(el, JSWorkerMessage, link); /* remove the message from the queue */ list_del(&msg->link); if (list_empty(&ps->msg_queue)) { uint8_t buf[16]; int ret; for(;;) { ret = read(ps->read_fd, buf, sizeof(buf)); if (ret >= 0) break; if (errno != EAGAIN && errno != EINTR) break; } } pthread_mutex_unlock(&ps->mutex); data_obj = JS_ReadObject(ctx, msg->data, msg->data_len, JS_READ_OBJ_SAB | JS_READ_OBJ_REFERENCE); js_free_message(msg); if (JS_IsException(data_obj)) goto fail; obj = JS_NewObject(ctx); if (JS_IsException(obj)) { JS_FreeValue(ctx, data_obj); goto fail; } JS_DefinePropertyValueStr(ctx, obj, "data", data_obj, JS_PROP_C_W_E); /* 'func' might be destroyed when calling itself (if it frees the handler), so must take extra care */ func = JS_DupValue(ctx, port->on_message_func); retval = JS_Call(ctx, func, JS_UNDEFINED, 1, &obj); JS_FreeValue(ctx, obj); JS_FreeValue(ctx, func); if (JS_IsException(retval)) { fail: js_std_dump_error(ctx); } else { JS_FreeValue(ctx, retval); } ret = 1; } else { pthread_mutex_unlock(&ps->mutex); ret = 0; } return ret; }
O0
c
handle_posted_message: subq $0xe8, %rsp movq %rdi, 0xe0(%rsp) movq %rsi, 0xd8(%rsp) movq %rdx, 0xd0(%rsp) movq 0xd0(%rsp), %rax movq 0x10(%rax), %rax movq %rax, 0xc8(%rsp) movq 0xc8(%rsp), %rdi addq $0x8, %rdi callq 0xe980 movq 0xc8(%rsp), %rdi addq $0x30, %rdi callq 0x17700 cmpl $0x0, %eax jne 0x1de27 movq 0xc8(%rsp), %rax movq 0x38(%rax), %rax movq %rax, 0xb8(%rsp) movq 0xb8(%rsp), %rax movq %rax, 0xb0(%rsp) movq 0xb0(%rsp), %rdi callq 0x17050 movq 0xc8(%rsp), %rdi addq $0x30, %rdi callq 0x17700 cmpl $0x0, %eax je 0x1dbc8 jmp 0x1db87 movq 0xc8(%rsp), %rax movl 0x40(%rax), %edi leaq 0x60(%rsp), %rsi movl $0x10, %edx callq 0xe470 movl %eax, 0x5c(%rsp) cmpl $0x0, 0x5c(%rsp) jl 0x1dbae jmp 0x1dbc6 callq 0xe0b0 cmpl $0xb, (%rax) je 0x1dbc4 callq 0xe0b0 cmpl $0x4, (%rax) je 0x1dbc4 jmp 0x1dbc6 jmp 0x1db87 jmp 0x1dbc8 movq 0xc8(%rsp), %rdi addq $0x8, %rdi callq 0xe650 movq 0xd8(%rsp), %rdi movq 0xb0(%rsp), %rax movq 0x10(%rax), %rsi movq 0xb0(%rsp), %rax movq 0x18(%rax), %rdx movl $0xc, %ecx callq 0x4cab0 movq %rax, 0x48(%rsp) movq %rdx, 0x50(%rsp) movq 0x48(%rsp), %rax movq %rax, 0x90(%rsp) movq 0x50(%rsp), %rax movq %rax, 0x98(%rsp) movq 0xb0(%rsp), %rdi callq 0x1d700 movq 0x90(%rsp), %rdi movq 0x98(%rsp), %rsi callq 0x10390 cmpl $0x0, %eax je 0x1dc53 jmp 0x1ddf4 movq 0xd8(%rsp), %rdi callq 0x2a570 movq %rax, 0x38(%rsp) movq %rdx, 0x40(%rsp) movq 0x38(%rsp), %rax movq %rax, 0xa0(%rsp) movq 0x40(%rsp), %rax movq %rax, 0xa8(%rsp) movq 0xa0(%rsp), %rdi movq 0xa8(%rsp), %rsi callq 0x10390 cmpl $0x0, %eax je 0x1dcc0 movq 0xd8(%rsp), %rdi movq 0x90(%rsp), %rsi movq 0x98(%rsp), %rdx callq 0x23c90 jmp 0x1ddf4 movq 0xd8(%rsp), %rdi movq 0xa0(%rsp), %rsi movq 0xa8(%rsp), %rdx movq 0x90(%rsp), %r8 movq 0x98(%rsp), %r9 leaq 0xec582(%rip), %rcx # 0x10a271 movl $0x7, (%rsp) callq 0x374e0 movq 0xd8(%rsp), %rdi movq 0xd0(%rsp), %rax movq 0x18(%rax), %rsi movq 0x20(%rax), %rdx callq 0x21690 movq %rax, 0x28(%rsp) movq %rdx, 0x30(%rsp) movq 0x28(%rsp), %rax movq %rax, 0x80(%rsp) movq 0x30(%rsp), %rax movq %rax, 0x88(%rsp) movq 0xd8(%rsp), %rdi movl $0x0, 0x8(%rsp) movq $0x3, 0x10(%rsp) movq 0x80(%rsp), %rsi movq 0x88(%rsp), %rdx movq 0x8(%rsp), %rcx movq 0x10(%rsp), %r8 movl $0x1, %r9d leaq 0xa0(%rsp), %rax movq %rax, (%rsp) callq 0x3a050 movq %rax, 0x18(%rsp) movq %rdx, 0x20(%rsp) movq 0x18(%rsp), %rax movq %rax, 0x70(%rsp) movq 0x20(%rsp), %rax movq %rax, 0x78(%rsp) movq 0xd8(%rsp), %rdi movq 0xa0(%rsp), %rsi movq 0xa8(%rsp), %rdx callq 0x23c90 movq 0xd8(%rsp), %rdi movq 0x80(%rsp), %rsi movq 0x88(%rsp), %rdx callq 0x23c90 movq 0x70(%rsp), %rdi movq 0x78(%rsp), %rsi callq 0x10390 cmpl $0x0, %eax je 0x1de03 jmp 0x1ddf4 movq 0xd8(%rsp), %rdi callq 0x11950 jmp 0x1de1a movq 0xd8(%rsp), %rdi movq 0x70(%rsp), %rsi movq 0x78(%rsp), %rdx callq 0x23c90 movl $0x1, 0xc4(%rsp) jmp 0x1de43 movq 0xc8(%rsp), %rdi addq $0x8, %rdi callq 0xe650 movl $0x0, 0xc4(%rsp) movl 0xc4(%rsp), %eax addq $0xe8, %rsp retq nopw %cs:(%rax,%rax)
handle_posted_message: sub rsp, 0E8h mov [rsp+0E8h+var_8], rdi mov [rsp+0E8h+var_10], rsi mov [rsp+0E8h+var_18], rdx mov rax, [rsp+0E8h+var_18] mov rax, [rax+10h] mov [rsp+0E8h+var_20], rax mov rdi, [rsp+0E8h+var_20] add rdi, 8 call _pthread_mutex_lock mov rdi, [rsp+0E8h+var_20] add rdi, 30h ; '0' call list_empty cmp eax, 0 jnz loc_1DE27 mov rax, [rsp+0E8h+var_20] mov rax, [rax+38h] mov [rsp+0E8h+var_30], rax mov rax, [rsp+0E8h+var_30] mov [rsp+0E8h+var_38], rax mov rdi, [rsp+0E8h+var_38] call list_del mov rdi, [rsp+0E8h+var_20] add rdi, 30h ; '0' call list_empty cmp eax, 0 jz short loc_1DBC8 jmp short $+2 loc_1DB87: mov rax, [rsp+0E8h+var_20] mov edi, [rax+40h] lea rsi, [rsp+0E8h+var_88] mov edx, 10h call _read mov [rsp+0E8h+var_8C], eax cmp [rsp+0E8h+var_8C], 0 jl short loc_1DBAE jmp short loc_1DBC6 loc_1DBAE: call ___errno_location cmp dword ptr [rax], 0Bh jz short loc_1DBC4 call ___errno_location cmp dword ptr [rax], 4 jz short loc_1DBC4 jmp short loc_1DBC6 loc_1DBC4: jmp short loc_1DB87 loc_1DBC6: jmp short $+2 loc_1DBC8: mov rdi, [rsp+0E8h+var_20] add rdi, 8 call _pthread_mutex_unlock mov rdi, [rsp+0E8h+var_10] mov rax, [rsp+0E8h+var_38] mov rsi, [rax+10h] mov rax, [rsp+0E8h+var_38] mov rdx, [rax+18h] mov ecx, 0Ch call JS_ReadObject mov [rsp+0E8h+var_A0], rax mov [rsp+0E8h+var_98], rdx mov rax, [rsp+0E8h+var_A0] mov [rsp+0E8h+var_58], rax mov rax, [rsp+0E8h+var_98] mov [rsp+0E8h+var_50], rax mov rdi, [rsp+0E8h+var_38] call js_free_message mov rdi, [rsp+0E8h+var_58] mov rsi, [rsp+0E8h+var_50] call JS_IsException_0 cmp eax, 0 jz short loc_1DC53 jmp loc_1DDF4 loc_1DC53: mov rdi, [rsp+0E8h+var_10] call JS_NewObject mov [rsp+0E8h+var_B0], rax mov [rsp+0E8h+var_A8], rdx mov rax, [rsp+0E8h+var_B0] mov [rsp+0E8h+var_48], rax mov rax, [rsp+0E8h+var_A8] mov [rsp+0E8h+var_40], rax mov rdi, [rsp+0E8h+var_48] mov rsi, [rsp+0E8h+var_40] call JS_IsException_0 cmp eax, 0 jz short loc_1DCC0 mov rdi, [rsp+0E8h+var_10] mov rsi, [rsp+0E8h+var_58] mov rdx, [rsp+0E8h+var_50] call JS_FreeValue jmp loc_1DDF4 loc_1DCC0: mov rdi, [rsp+0E8h+var_10] mov rsi, [rsp+0E8h+var_48] mov rdx, [rsp+0E8h+var_40] mov r8, [rsp+0E8h+var_58] mov r9, [rsp+0E8h+var_50] lea rcx, aData; "data" mov dword ptr [rsp+0E8h+var_E8], 7 call JS_DefinePropertyValueStr mov rdi, [rsp+0E8h+var_10] mov rax, [rsp+0E8h+var_18] mov rsi, [rax+18h] mov rdx, [rax+20h] call JS_DupValue mov [rsp+0E8h+var_C0], rax mov [rsp+0E8h+var_B8], rdx mov rax, [rsp+0E8h+var_C0] mov [rsp+0E8h+var_68], rax mov rax, [rsp+0E8h+var_B8] mov [rsp+0E8h+var_60], rax mov rdi, [rsp+0E8h+var_10] mov dword ptr [rsp+0E8h+var_E0], 0 mov [rsp+0E8h+var_D8], 3 mov rsi, [rsp+0E8h+var_68] mov rdx, [rsp+0E8h+var_60] mov rcx, [rsp+0E8h+var_E0] mov r8, [rsp+0E8h+var_D8] mov r9d, 1 lea rax, [rsp+0E8h+var_48] mov [rsp+0E8h+var_E8], rax call JS_Call mov [rsp+0E8h+var_D0], rax mov [rsp+0E8h+var_C8], rdx mov rax, [rsp+0E8h+var_D0] mov [rsp+0E8h+var_78], rax mov rax, [rsp+0E8h+var_C8] mov [rsp+0E8h+var_70], rax mov rdi, [rsp+0E8h+var_10] mov rsi, [rsp+0E8h+var_48] mov rdx, [rsp+0E8h+var_40] call JS_FreeValue mov rdi, [rsp+0E8h+var_10] mov rsi, [rsp+0E8h+var_68] mov rdx, [rsp+0E8h+var_60] call JS_FreeValue mov rdi, [rsp+0E8h+var_78] mov rsi, [rsp+0E8h+var_70] call JS_IsException_0 cmp eax, 0 jz short loc_1DE03 jmp short $+2 loc_1DDF4: mov rdi, [rsp+0E8h+var_10] call js_std_dump_error jmp short loc_1DE1A loc_1DE03: mov rdi, [rsp+0E8h+var_10] mov rsi, [rsp+0E8h+var_78] mov rdx, [rsp+0E8h+var_70] call JS_FreeValue loc_1DE1A: mov [rsp+0E8h+var_24], 1 jmp short loc_1DE43 loc_1DE27: mov rdi, [rsp+0E8h+var_20] add rdi, 8 call _pthread_mutex_unlock mov [rsp+0E8h+var_24], 0 loc_1DE43: mov eax, [rsp+0E8h+var_24] add rsp, 0E8h retn
long long handle_posted_message(long long a1, long long a2, long long a3) { long long v3; // rdx long long v4; // rdx long long v5; // rdx long long v6; // rdx _BYTE v8[16]; // [rsp+60h] [rbp-88h] BYREF long long v9; // [rsp+70h] [rbp-78h] long long v10; // [rsp+78h] [rbp-70h] long long v11; // [rsp+80h] [rbp-68h] long long v12; // [rsp+88h] [rbp-60h] long long Object; // [rsp+90h] [rbp-58h] long long v14; // [rsp+98h] [rbp-50h] long long v15; // [rsp+A0h] [rbp-48h] BYREF long long v16; // [rsp+A8h] [rbp-40h] _QWORD *v17; // [rsp+B0h] [rbp-38h] _QWORD *v18; // [rsp+B8h] [rbp-30h] long long v20; // [rsp+C8h] [rbp-20h] long long v21; // [rsp+D0h] [rbp-18h] long long v22; // [rsp+D8h] [rbp-10h] long long v23; // [rsp+E0h] [rbp-8h] v23 = a1; v22 = a2; v21 = a3; v20 = *(_QWORD *)(a3 + 16); pthread_mutex_lock(v20 + 8); if ( list_empty(v20 + 48) ) { pthread_mutex_unlock(v20 + 8); return 0; } v18 = *(_QWORD **)(v20 + 56); v17 = v18; list_del(v18); if ( list_empty(v20 + 48) ) { while ( (int)read(*(unsigned int *)(v20 + 64), v8, 16LL) < 0 && (*(_DWORD *)__errno_location() == 11 || *(_DWORD *)__errno_location() == 4) ) ; } pthread_mutex_unlock(v20 + 8); Object = JS_ReadObject(v22, v17[2], v17[3], 12LL); v14 = v3; js_free_message(v17); if ( !JS_IsException_0(Object, v14) ) { v15 = JS_NewObject(v22); v16 = v4; if ( JS_IsException_0(v15, v4) ) { JS_FreeValue(v22, Object, v14); } else { JS_DefinePropertyValueStr(v22, v15, v16, (unsigned int)"data", Object, v14, 7); v11 = JS_DupValue(v22, *(_QWORD *)(v21 + 24), *(_QWORD *)(v21 + 32)); v12 = v5; v9 = JS_Call(v22, v11, v5, 0, 3, 1, (long long)&v15); v10 = v6; JS_FreeValue(v22, v15, v16); JS_FreeValue(v22, v11, v12); if ( !JS_IsException_0(v9, v10) ) { JS_FreeValue(v22, v9, v10); return 1; } } } js_std_dump_error(v22); return 1; }
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 0x0011db3c 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 0x0013d0a0 CMP EAX,0x0 JZ 0x0011db3a MOV dword ptr [RSP + 0x38],0x0 MOV qword ptr [RSP + 0x40],0x6 JMP 0x0011dbd6 LAB_0011db3a: JMP 0x0011db44 LAB_0011db3c: MOV dword ptr [RSP + 0xc],0x1ff LAB_0011db44: MOV RDI,qword ptr [RSP + 0x20] MOV RAX,qword ptr [RSP + 0x10] MOV RSI,qword ptr [RAX] MOV RDX,qword ptr [RAX + 0x8] CALL 0x00118960 MOV qword ptr [RSP],RAX CMP qword ptr [RSP],0x0 JNZ 0x0011db78 MOV dword ptr [RSP + 0x38],0x0 MOV qword ptr [RSP + 0x40],0x6 JMP 0x0011dbd6 LAB_0011db78: MOV RDI,qword ptr [RSP] MOV ESI,dword ptr [RSP + 0xc] CALL 0x00111130 MOVSXD RDI,EAX CALL 0x00117bd0 MOV dword ptr [RSP + 0x8],EAX MOV RDI,qword ptr [RSP + 0x20] MOV RSI,qword ptr [RSP] CALL 0x0012dfd0 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_0011dbd6: 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_0011dbd6; } } __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_0011dbd6: auVar1._4_4_ = uStack_2c; auVar1._0_4_ = local_30; auVar1._8_8_ = local_28; return auVar1; }
3,547
my_strtoull
eloqsql/libmariadb/libmariadb/ma_stmt_codec.c
static unsigned long long my_strtoull(const char *str, size_t len, const char **end, int *err) { unsigned long long val = 0; const char *p = str; const char *end_str = p + len; for (; p < end_str; p++) { if (*p < '0' || *p > '9') break; if (val > ULONGLONG_MAX /10 || val*10 > ULONGLONG_MAX - (*p - '0')) { *err = ERANGE; break; } val = val * 10 + *p -'0'; } if (p == str) /* Did not parse anything.*/ *err = ERANGE; *end = p; return val; }
O0
c
my_strtoull: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq %rcx, -0x20(%rbp) movq $0x0, -0x28(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x30(%rbp) movq -0x30(%rbp), %rax addq -0x10(%rbp), %rax movq %rax, -0x38(%rbp) movq -0x30(%rbp), %rax cmpq -0x38(%rbp), %rax jae 0x49fee movq -0x30(%rbp), %rax movsbl (%rax), %eax cmpl $0x30, %eax jl 0x49f86 movq -0x30(%rbp), %rax movsbl (%rax), %eax cmpl $0x39, %eax jle 0x49f88 jmp 0x49fee movabsq $0x1999999999999999, %rax # imm = 0x1999999999999999 cmpq %rax, -0x28(%rbp) ja 0x49fb9 imulq $0xa, -0x28(%rbp), %rax movq -0x30(%rbp), %rcx movsbl (%rcx), %ecx subl $0x30, %ecx movslq %ecx, %rdx movq $-0x1, %rcx subq %rdx, %rcx cmpq %rcx, %rax jbe 0x49fc5 movq -0x20(%rbp), %rax movl $0x22, (%rax) jmp 0x49fee imulq $0xa, -0x28(%rbp), %rax movq -0x30(%rbp), %rcx movsbq (%rcx), %rcx addq %rcx, %rax subq $0x30, %rax movq %rax, -0x28(%rbp) movq -0x30(%rbp), %rax addq $0x1, %rax movq %rax, -0x30(%rbp) jmp 0x49f60 movq -0x30(%rbp), %rax cmpq -0x8(%rbp), %rax jne 0x4a002 movq -0x20(%rbp), %rax movl $0x22, (%rax) movq -0x30(%rbp), %rcx movq -0x18(%rbp), %rax movq %rcx, (%rax) movq -0x28(%rbp), %rax popq %rbp retq nopw %cs:(%rax,%rax)
my_strtoull: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov [rbp+var_20], rcx mov [rbp+var_28], 0 mov rax, [rbp+var_8] mov [rbp+var_30], rax mov rax, [rbp+var_30] add rax, [rbp+var_10] mov [rbp+var_38], rax loc_49F60: mov rax, [rbp+var_30] cmp rax, [rbp+var_38] jnb loc_49FEE mov rax, [rbp+var_30] movsx eax, byte ptr [rax] cmp eax, 30h ; '0' jl short loc_49F86 mov rax, [rbp+var_30] movsx eax, byte ptr [rax] cmp eax, 39h ; '9' jle short loc_49F88 loc_49F86: jmp short loc_49FEE loc_49F88: mov rax, 1999999999999999h cmp [rbp+var_28], rax ja short loc_49FB9 imul rax, [rbp+var_28], 0Ah mov rcx, [rbp+var_30] movsx ecx, byte ptr [rcx] sub ecx, 30h ; '0' movsxd rdx, ecx mov rcx, 0FFFFFFFFFFFFFFFFh sub rcx, rdx cmp rax, rcx jbe short loc_49FC5 loc_49FB9: mov rax, [rbp+var_20] mov dword ptr [rax], 22h ; '"' jmp short loc_49FEE loc_49FC5: imul rax, [rbp+var_28], 0Ah mov rcx, [rbp+var_30] movsx rcx, byte ptr [rcx] add rax, rcx sub rax, 30h ; '0' mov [rbp+var_28], rax mov rax, [rbp+var_30] add rax, 1 mov [rbp+var_30], rax jmp loc_49F60 loc_49FEE: mov rax, [rbp+var_30] cmp rax, [rbp+var_8] jnz short loc_4A002 mov rax, [rbp+var_20] mov dword ptr [rax], 22h ; '"' loc_4A002: mov rcx, [rbp+var_30] mov rax, [rbp+var_18] mov [rax], rcx mov rax, [rbp+var_28] pop rbp retn
unsigned long long my_strtoull(char *a1, long long a2, char **a3, _DWORD *a4) { char *i; // [rsp+8h] [rbp-30h] unsigned long long v6; // [rsp+10h] [rbp-28h] v6 = 0LL; for ( i = a1; i < &a1[a2] && *i >= 48 && *i <= 57; ++i ) { if ( v6 > 0x1999999999999999LL || 10 * v6 > -1LL - (*i - 48) ) { *a4 = 34; break; } v6 = *i + 10 * v6 - 48; } if ( i == a1 ) *a4 = 34; *a3 = i; return v6; }
my_strtoull: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV qword ptr [RBP + -0x20],RCX MOV qword ptr [RBP + -0x28],0x0 MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x30] ADD RAX,qword ptr [RBP + -0x10] MOV qword ptr [RBP + -0x38],RAX LAB_00149f60: MOV RAX,qword ptr [RBP + -0x30] CMP RAX,qword ptr [RBP + -0x38] JNC 0x00149fee MOV RAX,qword ptr [RBP + -0x30] MOVSX EAX,byte ptr [RAX] CMP EAX,0x30 JL 0x00149f86 MOV RAX,qword ptr [RBP + -0x30] MOVSX EAX,byte ptr [RAX] CMP EAX,0x39 JLE 0x00149f88 LAB_00149f86: JMP 0x00149fee LAB_00149f88: MOV RAX,0x1999999999999999 CMP qword ptr [RBP + -0x28],RAX JA 0x00149fb9 IMUL RAX,qword ptr [RBP + -0x28],0xa MOV RCX,qword ptr [RBP + -0x30] MOVSX ECX,byte ptr [RCX] SUB ECX,0x30 MOVSXD RDX,ECX MOV RCX,-0x1 SUB RCX,RDX CMP RAX,RCX JBE 0x00149fc5 LAB_00149fb9: MOV RAX,qword ptr [RBP + -0x20] MOV dword ptr [RAX],0x22 JMP 0x00149fee LAB_00149fc5: IMUL RAX,qword ptr [RBP + -0x28],0xa MOV RCX,qword ptr [RBP + -0x30] MOVSX RCX,byte ptr [RCX] ADD RAX,RCX SUB RAX,0x30 MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x30] ADD RAX,0x1 MOV qword ptr [RBP + -0x30],RAX JMP 0x00149f60 LAB_00149fee: MOV RAX,qword ptr [RBP + -0x30] CMP RAX,qword ptr [RBP + -0x8] JNZ 0x0014a002 MOV RAX,qword ptr [RBP + -0x20] MOV dword ptr [RAX],0x22 LAB_0014a002: MOV RCX,qword ptr [RBP + -0x30] MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX],RCX MOV RAX,qword ptr [RBP + -0x28] POP RBP RET
ulong my_strtoull(char *param_1,long param_2,int8 *param_3,int4 *param_4) { ulong uVar1; char *local_38; ulong local_30; local_30 = 0; local_38 = param_1; while( true ) { if (((param_1 + param_2 <= local_38) || (*local_38 < '0')) || ('9' < *local_38)) goto LAB_00149fee; if ((0x1999999999999999 < local_30) || (uVar1 = -(long)(*local_38 + -0x30) - 1, uVar1 <= local_30 * 10 && local_30 * 10 - uVar1 != 0 )) break; local_30 = (local_30 * 10 + (long)*local_38) - 0x30; local_38 = local_38 + 1; } *param_4 = 0x22; LAB_00149fee: if (local_38 == param_1) { *param_4 = 0x22; } *param_3 = local_38; return local_30; }
3,548
SchemaConverter::_generate_union_rule(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::vector<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<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>>> const&)
monkey531[P]llama/common/json-schema-to-grammar.cpp
std::string _generate_union_rule(const std::string & name, const std::vector<json> & alt_schemas) { std::vector<std::string> rules; for (size_t i = 0; i < alt_schemas.size(); i++) { rules.push_back(visit(alt_schemas[i], name + (name.empty() ? "alternative-" : "-") + std::to_string(i))); } return string_join(rules, " | "); }
O2
cpp
SchemaConverter::_generate_union_rule(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::vector<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<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&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0xb8, %rsp movq %rcx, %r14 movq %rdx, 0x18(%rsp) movq %rsi, 0x10(%rsp) movq %rdi, 0x8(%rsp) xorps %xmm0, %xmm0 leaq 0x20(%rsp), %rax movaps %xmm0, (%rax) andq $0x0, 0x10(%rax) xorl %r13d, %r13d xorl %ebp, %ebp movq (%r14), %rbx movq 0x8(%r14), %rax subq %rbx, %rax sarq $0x4, %rax cmpq %rax, %rbp jae 0x85ff5 movq 0x18(%rsp), %rsi cmpq $0x0, 0x8(%rsi) leaq 0x10b1e(%rip), %rdx # 0x96a7e leaq 0x10c4f(%rip), %rax # 0x96bb6 cmoveq %rax, %rdx leaq 0x58(%rsp), %rdi callq 0x61d6d leaq 0x78(%rsp), %r12 movq %r12, %rdi movq %rbp, %rsi callq 0x456fd leaq 0x98(%rsp), %r15 movq %r15, %rdi leaq 0x58(%rsp), %rsi movq %r12, %rdx callq 0x283cb addq %r13, %rbx leaq 0x38(%rsp), %r12 movq %r12, %rdi movq 0x10(%rsp), %rsi movq %rbx, %rdx movq %r15, %rcx callq 0x84094 leaq 0x20(%rsp), %rdi movq %r12, %rsi callq 0x6d408 movq %r12, %rdi callq 0x20d88 movq %r15, %rdi callq 0x20d88 leaq 0x78(%rsp), %rdi callq 0x20d88 leaq 0x58(%rsp), %rdi callq 0x20d88 incq %rbp addq $0x10, %r13 jmp 0x85f38 leaq 0x10d78(%rip), %rsi # 0x96d74 leaq 0x38(%rsp), %rdi leaq 0x98(%rsp), %rdx callq 0x22836 leaq 0x20(%rsp), %rsi leaq 0x38(%rsp), %rdx movq 0x8(%rsp), %rbx movq %rbx, %rdi callq 0x23822 leaq 0x38(%rsp), %rdi callq 0x20d88 leaq 0x20(%rsp), %rdi callq 0x28432 movq %rbx, %rax addq $0xb8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movq %rax, %rbx leaq 0x38(%rsp), %rdi jmp 0x86092 jmp 0x86099 movq %rax, %rbx leaq 0x38(%rsp), %rdi callq 0x20d88 jmp 0x8606c movq %rax, %rbx leaq 0x98(%rsp), %rdi callq 0x20d88 jmp 0x86083 movq %rax, %rbx jmp 0x8608d movq %rax, %rbx leaq 0x78(%rsp), %rdi callq 0x20d88 leaq 0x58(%rsp), %rdi callq 0x20d88 jmp 0x8609c movq %rax, %rbx leaq 0x20(%rsp), %rdi callq 0x28432 movq %rbx, %rdi callq 0x20ba0
_ZN15SchemaConverter20_generate_union_ruleERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEERKSt6vectorIN8nlohmann16json_abi_v3_11_310basic_jsonINSA_11ordered_mapES8_S5_blmdSaNSA_14adl_serializerES8_IhSaIhEEvEESaISG_EE: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 0B8h mov r14, rcx mov [rsp+0E8h+var_D0], rdx mov [rsp+0E8h+var_D8], rsi mov [rsp+0E8h+var_E0], rdi xorps xmm0, xmm0 lea rax, [rsp+0E8h+var_C8] movaps xmmword ptr [rax], xmm0 and qword ptr [rax+10h], 0 xor r13d, r13d xor ebp, ebp loc_85F38: mov rbx, [r14] mov rax, [r14+8] sub rax, rbx sar rax, 4 cmp rbp, rax jnb loc_85FF5 mov rsi, [rsp+0E8h+var_D0] cmp qword ptr [rsi+8], 0 lea rdx, asc_96A7D+1; "-" lea rax, aAlternative; "alternative-" cmovz rdx, rax lea rdi, [rsp+0E8h+var_90] call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EERKS8_PKS5_; std::operator+<char>(std::string const&,char const*) lea r12, [rsp+0E8h+var_70] mov rdi, r12; this mov rsi, rbp; unsigned __int64 call _ZNSt7__cxx119to_stringEm; std::to_string(ulong) lea r15, [rsp+0E8h+var_50] mov rdi, r15 lea rsi, [rsp+0E8h+var_90] mov rdx, r12 call _ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEOS8_S9_; std::operator+<char>(std::string&&,std::string&) add rbx, r13 lea r12, [rsp+0E8h+var_B0] mov rdi, r12 mov rsi, [rsp+0E8h+var_D8] mov rdx, rbx mov rcx, r15 call _ZN15SchemaConverter5visitERKN8nlohmann16json_abi_v3_11_310basic_jsonINS1_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS1_14adl_serializerES4_IhSaIhEEvEERKSA_; SchemaConverter::visit(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&,std::string const&) lea rdi, [rsp+0E8h+var_C8] mov rsi, r12 call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE12emplace_backIJS5_EEERS5_DpOT_; std::vector<std::string>::emplace_back<std::string>(std::string &&) mov rdi, r12; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdi, r15; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rsp+0E8h+var_70]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rsp+0E8h+var_90]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() inc rbp add r13, 10h jmp loc_85F38 loc_85FF5: lea rsi, asc_96D73+1; " | " lea rdi, [rsp+0E8h+var_B0] lea rdx, [rsp+0E8h+var_50] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) lea rsi, [rsp+0E8h+var_C8] lea rdx, [rsp+0E8h+var_B0] mov rbx, [rsp+0E8h+var_E0] mov rdi, rbx call _Z11string_joinRKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EERKS5_; string_join(std::vector<std::string> const&,std::string const&) lea rdi, [rsp+0E8h+var_B0]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() lea rdi, [rsp+0E8h+var_C8] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() mov rax, rbx add rsp, 0B8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn mov rbx, rax lea rdi, [rsp+arg_30] jmp short loc_86092 jmp short loc_86099 mov rbx, rax lea rdi, [rsp+arg_30]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_8606C mov rbx, rax loc_8606C: lea rdi, [rsp+arg_90]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_86083 mov rbx, rax jmp short loc_8608D mov rbx, rax loc_86083: lea rdi, [rsp+arg_70]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() loc_8608D: lea rdi, [rsp+arg_50]; void * loc_86092: call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_8609C loc_86099: mov rbx, rax loc_8609C: lea rdi, [rsp+arg_18] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EED2Ev; std::vector<std::string>::~vector() mov rdi, rbx call __Unwind_Resume
long long SchemaConverter::_generate_union_rule(long long a1, long long a2, long long a3, long long *a4) { long long v5; // r13 unsigned long long i; // rbp long long v7; // rbx char *v8; // rdx __int128 v11; // [rsp+20h] [rbp-C8h] BYREF long long v12; // [rsp+30h] [rbp-B8h] _QWORD v13[4]; // [rsp+38h] [rbp-B0h] BYREF _QWORD v14[4]; // [rsp+58h] [rbp-90h] BYREF _QWORD v15[4]; // [rsp+78h] [rbp-70h] BYREF _BYTE v16[80]; // [rsp+98h] [rbp-50h] BYREF v11 = 0LL; v12 = 0LL; v5 = 0LL; for ( i = 0LL; ; ++i ) { v7 = *a4; if ( i >= (a4[1] - *a4) >> 4 ) break; v8 = "-"; if ( !*(_QWORD *)(a3 + 8) ) v8 = "alternative-"; std::operator+<char>((long long)v14, a3, (long long)v8); std::to_string((std::__cxx11 *)v15, i); std::operator+<char>((long long)v16, v14, v15); SchemaConverter::visit(v13, a2, v5 + v7, (long long)v16, (__m128d)0LL); std::vector<std::string>::emplace_back<std::string>((long long)&v11, (long long)v13); std::string::~string(v13); std::string::~string(v16); std::string::~string(v15); std::string::~string(v14); v5 += 16LL; } std::string::basic_string<std::allocator<char>>(v13, (long long)" | "); string_join(a1, (long long *)&v11, (long long)v13); std::string::~string(v13); std::vector<std::string>::~vector((long long)&v11); return a1; }
_generate_union_rule: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0xb8 MOV R14,RCX MOV qword ptr [RSP + 0x18],RDX MOV qword ptr [RSP + 0x10],RSI MOV qword ptr [RSP + 0x8],RDI XORPS XMM0,XMM0 LEA RAX,[RSP + 0x20] MOVAPS xmmword ptr [RAX],XMM0 AND qword ptr [RAX + 0x10],0x0 XOR R13D,R13D XOR EBP,EBP LAB_00185f38: MOV RBX,qword ptr [R14] MOV RAX,qword ptr [R14 + 0x8] SUB RAX,RBX SAR RAX,0x4 CMP RBP,RAX JNC 0x00185ff5 MOV RSI,qword ptr [RSP + 0x18] CMP qword ptr [RSI + 0x8],0x0 LEA RDX,[0x196a7e] LEA RAX,[0x196bb6] CMOVZ RDX,RAX LAB_00185f6b: LEA RDI,[RSP + 0x58] CALL 0x00161d6d LAB_00185f75: LEA R12,[RSP + 0x78] MOV RDI,R12 MOV RSI,RBP CALL 0x001456fd LAB_00185f85: LEA R15,[RSP + 0x98] MOV RDI,R15 LEA RSI,[RSP + 0x58] MOV RDX,R12 CALL 0x001283cb LAB_00185f9d: ADD RBX,R13 LEA R12,[RSP + 0x38] MOV RDI,R12 MOV RSI,qword ptr [RSP + 0x10] MOV RDX,RBX MOV RCX,R15 CALL 0x00184094 LAB_00185fb8: LEA RDI,[RSP + 0x20] MOV RSI,R12 CALL 0x0016d408 MOV RDI,R12 CALL 0x00120d88 MOV RDI,R15 CALL 0x00120d88 LEA RDI,[RSP + 0x78] CALL 0x00120d88 LEA RDI,[RSP + 0x58] CALL 0x00120d88 INC RBP ADD R13,0x10 JMP 0x00185f38 LAB_00185ff5: LEA RSI,[0x196d74] LEA RDI,[RSP + 0x38] LEA RDX,[RSP + 0x98] CALL 0x00122836 LAB_0018600e: LEA RSI,[RSP + 0x20] LEA RDX,[RSP + 0x38] MOV RBX,qword ptr [RSP + 0x8] MOV RDI,RBX CALL 0x00123822 LAB_00186025: LEA RDI,[RSP + 0x38] CALL 0x00120d88 LEA RDI,[RSP + 0x20] CALL 0x00128432 MOV RAX,RBX ADD RSP,0xb8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* SchemaConverter::_generate_union_rule(std::__cxx11::string const&, std::vector<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>, std::allocator<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> > > const&) */ string * SchemaConverter::_generate_union_rule(string *param_1,vector *param_2) { long *in_RCX; char *in_RDX; ulong uVar1; int8 local_c8; int8 uStack_c0; int8 local_b8; string local_b0 [32]; string local_90 [32]; __cxx11 local_70 [32]; string local_50 [32]; local_c8 = 0; uStack_c0 = 0; local_b8 = 0; for (uVar1 = 0; uVar1 < (ulong)(in_RCX[1] - *in_RCX >> 4); uVar1 = uVar1 + 1) { /* try { // try from 00185f6b to 00185f74 has its CatchHandler @ 00186099 */ std::operator+(local_90,in_RDX); /* try { // try from 00185f75 to 00185f84 has its CatchHandler @ 0018607b */ std::__cxx11::to_string(local_70,uVar1); /* try { // try from 00185f85 to 00185f9c has its CatchHandler @ 00186080 */ std::operator+(local_50,local_90); /* try { // try from 00185f9d to 00185fb7 has its CatchHandler @ 00186069 */ visit(local_b0,(string *)param_2); /* try { // try from 00185fb8 to 00185fc4 has its CatchHandler @ 0018605a */ std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>:: emplace_back<std::__cxx11::string> ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)&local_c8, local_b0); std::__cxx11::string::~string(local_b0); std::__cxx11::string::~string(local_50); std::__cxx11::string::~string((string *)local_70); std::__cxx11::string::~string(local_90); } /* try { // try from 00185ff5 to 0018600d has its CatchHandler @ 00186058 */ std::__cxx11::string::string<std::allocator<char>>(local_b0," | ",(allocator *)local_50); /* try { // try from 0018600e to 00186024 has its CatchHandler @ 0018604e */ string_join((vector *)param_1,(string *)&local_c8); std::__cxx11::string::~string(local_b0); std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::~vector ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)&local_c8); return param_1; }
3,549
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 0x2cb138(%rip), %r15 # 0x2ef820 movq (%r15), %rax movq 0x90(%rdi), %rsi leaq -0x48(%rbp), %rdi xorl %edx, %edx callq *0x1a0(%rax) movq %rax, %rbx movq %r14, %rdi callq 0x2733c movl %eax, %r14d testq %rbx, %rbx je 0x24720 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_24720 mov rax, [r15] mov rdi, rbx mov esi, r14d call qword ptr [rax+1A8h] loc_24720: 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[0] + 52))( v6, *(_QWORD *)(a1 + 144), 0LL, a2, a3); v4 = my_rw_rdlock(a1); if ( v3 ) (*((void ( **)(long long, _QWORD))PSI_server[0] + 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,[0x3ef820] 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 0x0012733c MOV R14D,EAX TEST RBX,RBX JZ 0x00124720 MOV RAX,qword ptr [R15] MOV RDI,RBX MOV ESI,R14D CALL qword ptr [RAX + 0x1a8] LAB_00124720: 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; }
3,550
bother::deinit()
untodesu[P]voxelius/game/client/bother.cc
void bother::deinit(void) { enet_host_destroy(bother_host); bother_dispatcher.clear(); bother_set.clear(); }
O1
cpp
bother::deinit(): pushq %r14 pushq %rbx pushq %rax movq 0x22dc4b(%rip), %rdi # 0x25d5a8 callq 0x17f54d movq 0x22db97(%rip), %rbx # 0x25d500 movq 0x22db98(%rip), %r14 # 0x25d508 cmpq %r14, %rbx je 0x2f985 movq 0x10(%rbx), %rdi movq (%rdi), %rax callq *0x20(%rax) addq $0x20, %rbx jmp 0x2f970 leaq 0x22db94(%rip), %rdi # 0x25d520 addq $0x8, %rsp popq %rbx popq %r14 jmp 0x30150
_ZN6bother6deinitEv: push r14 push rbx push rax mov rdi, cs:_ZL11bother_host; bother_host call enet_host_destroy mov rbx, cs:qword_25D500 mov r14, cs:qword_25D508 loc_2F970: cmp rbx, r14 jz short loc_2F985 mov rdi, [rbx+10h] mov rax, [rdi] call qword ptr [rax+20h] add rbx, 20h ; ' ' jmp short loc_2F970 loc_2F985: lea rdi, _ZL10bother_set; bother_set add rsp, 8 pop rbx pop r14 jmp _ZNSt10_HashtableIjjSaIjENSt8__detail9_IdentityESt8equal_toIjESt4hashIjENS1_18_Mod_range_hashingENS1_20_Default_ranged_hashENS1_20_Prime_rehash_policyENS1_17_Hashtable_traitsILb0ELb1ELb1EEEE5clearEv; std::_Hashtable<uint,uint,std::allocator<uint>,std::__detail::_Identity,std::equal_to<uint>,std::hash<uint>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,true,true>>::clear(void)
long long bother::deinit(bother *this) { long long v1; // rbx long long v2; // r14 enet_host_destroy(bother_host); v1 = qword_25D500; v2 = qword_25D508; while ( v1 != v2 ) { (*(void ( **)(_QWORD))(**(_QWORD **)(v1 + 16) + 32LL))(*(_QWORD *)(v1 + 16)); v1 += 32LL; } return std::_Hashtable<unsigned int,unsigned int,std::allocator<unsigned int>,std::__detail::_Identity,std::equal_to<unsigned int>,std::hash<unsigned int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,true,true>>::clear(bother_set); }
deinit: PUSH R14 PUSH RBX PUSH RAX MOV RDI,qword ptr [0x0035d5a8] CALL 0x0027f54d MOV RBX,qword ptr [0x0035d500] MOV R14,qword ptr [0x0035d508] LAB_0012f970: CMP RBX,R14 JZ 0x0012f985 MOV RDI,qword ptr [RBX + 0x10] MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x20] ADD RBX,0x20 JMP 0x0012f970 LAB_0012f985: LEA RDI,[0x35d520] ADD RSP,0x8 POP RBX POP R14 JMP 0x00130150
/* bother::deinit() */ void bother::deinit(void) { int8 uVar1; long lVar2; enet_host_destroy(bother_host); uVar1 = bother_dispatcher._32_8_; for (lVar2 = bother_dispatcher._24_8_; lVar2 != uVar1; lVar2 = lVar2 + 0x20) { (**(code **)(**(long **)(lVar2 + 0x10) + 0x20))(); } std:: _Hashtable<unsigned_int,unsigned_int,std::allocator<unsigned_int>,std::__detail::_Identity,std::equal_to<unsigned_int>,std::hash<unsigned_int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,true,true>> ::clear((_Hashtable<unsigned_int,unsigned_int,std::allocator<unsigned_int>,std::__detail::_Identity,std::equal_to<unsigned_int>,std::hash<unsigned_int>,std::__detail::_Mod_range_hashing,std::__detail::_Default_ranged_hash,std::__detail::_Prime_rehash_policy,std::__detail::_Hashtable_traits<false,true,true>> *)bother_set); return; }
3,551
js_os_signal
bluesky950520[P]quickjs/quickjs-libc.c
static JSValue js_os_signal(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { JSRuntime *rt = JS_GetRuntime(ctx); JSThreadState *ts = js_get_thread_state(rt); JSOSSignalHandler *sh; uint32_t sig_num; JSValue func; sighandler_t handler; if (!is_main_thread(rt)) return JS_ThrowTypeError(ctx, "signal handler can only be set in the main thread"); if (JS_ToUint32(ctx, &sig_num, argv[0])) return JS_EXCEPTION; if (sig_num >= 64) return JS_ThrowRangeError(ctx, "invalid signal number"); func = argv[1]; /* func = null: SIG_DFL, func = undefined, SIG_IGN */ if (JS_IsNull(func) || JS_IsUndefined(func)) { sh = find_sh(ts, sig_num); if (sh) { free_sh(JS_GetRuntime(ctx), sh); } if (JS_IsNull(func)) handler = SIG_DFL; else handler = SIG_IGN; signal(sig_num, handler); } else { if (!JS_IsFunction(ctx, func)) return JS_ThrowTypeError(ctx, "not a function"); sh = find_sh(ts, sig_num); if (!sh) { sh = js_mallocz(ctx, sizeof(*sh)); if (!sh) return JS_EXCEPTION; sh->sig_num = sig_num; list_add_tail(&sh->link, &ts->os_signal_handlers); } JS_FreeValue(ctx, sh->func); sh->func = JS_DupValue(ctx, func); signal(sig_num, os_signal_handler); } return JS_UNDEFINED; }
O0
c
js_os_signal: subq $0x88, %rsp movq %rsi, 0x68(%rsp) movq %rdx, 0x70(%rsp) movq %rdi, 0x60(%rsp) movl %ecx, 0x5c(%rsp) movq %r8, 0x50(%rsp) movq 0x60(%rsp), %rdi callq 0x26c40 movq %rax, 0x48(%rsp) movq 0x48(%rsp), %rdi callq 0x10310 movq %rax, 0x40(%rsp) movq 0x48(%rsp), %rdi callq 0x16530 cmpl $0x0, %eax jne 0x17941 movq 0x60(%rsp), %rdi leaq 0xf10c9(%rip), %rsi # 0x1089f1 movb $0x0, %al callq 0x2c040 movq %rax, 0x78(%rsp) movq %rdx, 0x80(%rsp) jmp 0x17b7b movq 0x60(%rsp), %rdi movq 0x50(%rsp), %rax movq (%rax), %rdx movq 0x8(%rax), %rcx leaq 0x34(%rsp), %rsi callq 0x1baa0 cmpl $0x0, %eax je 0x1797a movl $0x0, 0x78(%rsp) movq $0x6, 0x80(%rsp) jmp 0x17b7b cmpl $0x40, 0x34(%rsp) jb 0x179a6 movq 0x60(%rsp), %rdi leaq 0xf1096(%rip), %rsi # 0x108a23 movb $0x0, %al callq 0x283b0 movq %rax, 0x78(%rsp) movq %rdx, 0x80(%rsp) jmp 0x17b7b movq 0x50(%rsp), %rax movq 0x10(%rax), %rcx movq %rcx, 0x20(%rsp) movq 0x18(%rax), %rax movq %rax, 0x28(%rsp) movq 0x20(%rsp), %rdi movq 0x28(%rsp), %rsi callq 0x15560 cmpl $0x0, %eax jne 0x179e5 movq 0x20(%rsp), %rdi movq 0x28(%rsp), %rsi callq 0x10670 cmpl $0x0, %eax je 0x17a53 movq 0x40(%rsp), %rdi movl 0x34(%rsp), %esi callq 0x1bae0 movq %rax, 0x38(%rsp) cmpq $0x0, 0x38(%rsp) je 0x17a17 movq 0x60(%rsp), %rdi callq 0x26c40 movq %rax, %rdi movq 0x38(%rsp), %rsi callq 0x103a0 movq 0x20(%rsp), %rdi movq 0x28(%rsp), %rsi callq 0x15560 cmpl $0x0, %eax je 0x17a36 movq $0x0, 0x18(%rsp) jmp 0x17a40 movl $0x1, %eax movq %rax, 0x18(%rsp) movl 0x34(%rsp), %edi movq 0x18(%rsp), %rsi callq 0xe510 jmp 0x17b67 movq 0x60(%rsp), %rdi movq 0x20(%rsp), %rsi movq 0x28(%rsp), %rdx callq 0x2d250 cmpl $0x0, %eax jne 0x17a91 movq 0x60(%rsp), %rdi leaq 0xf614c(%rip), %rsi # 0x10dbc4 movb $0x0, %al callq 0x2c040 movq %rax, 0x78(%rsp) movq %rdx, 0x80(%rsp) jmp 0x17b7b movq 0x40(%rsp), %rdi movl 0x34(%rsp), %esi callq 0x1bae0 movq %rax, 0x38(%rsp) cmpq $0x0, 0x38(%rsp) jne 0x17b00 movq 0x60(%rsp), %rdi movl $0x28, %esi callq 0x20a70 movq %rax, 0x38(%rsp) cmpq $0x0, 0x38(%rsp) jne 0x17ae1 movl $0x0, 0x78(%rsp) movq $0x6, 0x80(%rsp) jmp 0x17b7b movl 0x34(%rsp), %ecx movq 0x38(%rsp), %rax movl %ecx, 0x10(%rax) movq 0x38(%rsp), %rdi movq 0x40(%rsp), %rsi addq $0x10, %rsi callq 0x16460 movq 0x60(%rsp), %rdi movq 0x38(%rsp), %rax movq 0x18(%rax), %rsi movq 0x20(%rax), %rdx callq 0x229d0 movq 0x38(%rsp), %rax movq %rax, (%rsp) movq 0x60(%rsp), %rdi movq 0x20(%rsp), %rsi movq 0x28(%rsp), %rdx callq 0x203d0 movq %rax, %rcx movq (%rsp), %rax movq %rcx, 0x8(%rsp) movq %rdx, 0x10(%rsp) movq 0x8(%rsp), %rcx movq %rcx, 0x18(%rax) movq 0x10(%rsp), %rcx movq %rcx, 0x20(%rax) movl 0x34(%rsp), %edi leaq 0x3fee(%rip), %rsi # 0x1bb50 callq 0xe510 movl $0x0, 0x78(%rsp) movq $0x3, 0x80(%rsp) movq 0x78(%rsp), %rax movq 0x80(%rsp), %rdx addq $0x88, %rsp retq
js_os_signal: sub rsp, 88h mov [rsp+88h+var_20], rsi mov [rsp+88h+var_18], rdx mov [rsp+88h+var_28], rdi mov [rsp+88h+var_2C], ecx mov [rsp+88h+var_38], r8 mov rdi, [rsp+88h+var_28] call JS_GetRuntime mov [rsp+88h+var_40], rax mov rdi, [rsp+88h+var_40] call js_get_thread_state mov [rsp+88h+var_48], rax mov rdi, [rsp+88h+var_40] call is_main_thread cmp eax, 0 jnz short loc_17941 mov rdi, [rsp+88h+var_28] lea rsi, aSignalHandlerC; "signal handler can only be set in the m"... mov al, 0 call JS_ThrowTypeError mov [rsp+88h+var_10], rax mov [rsp+88h+var_8], rdx jmp loc_17B7B loc_17941: mov rdi, [rsp+88h+var_28] mov rax, [rsp+88h+var_38] mov rdx, [rax] mov rcx, [rax+8] lea rsi, [rsp+88h+var_54] call JS_ToUint32 cmp eax, 0 jz short loc_1797A mov dword ptr [rsp+88h+var_10], 0 mov [rsp+88h+var_8], 6 jmp loc_17B7B loc_1797A: cmp [rsp+88h+var_54], 40h ; '@' jb short loc_179A6 mov rdi, [rsp+88h+var_28] lea rsi, aInvalidSignalN; "invalid signal number" mov al, 0 call JS_ThrowRangeError mov [rsp+88h+var_10], rax mov [rsp+88h+var_8], rdx jmp loc_17B7B loc_179A6: mov rax, [rsp+88h+var_38] mov rcx, [rax+10h] mov [rsp+88h+var_68], rcx mov rax, [rax+18h] mov [rsp+88h+var_60], rax mov rdi, [rsp+88h+var_68] mov rsi, [rsp+88h+var_60] call JS_IsNull cmp eax, 0 jnz short loc_179E5 mov rdi, [rsp+88h+var_68] mov rsi, [rsp+88h+var_60] call JS_IsUndefined cmp eax, 0 jz short loc_17A53 loc_179E5: mov rdi, [rsp+88h+var_48] mov esi, [rsp+88h+var_54] call find_sh mov [rsp+88h+var_50], rax cmp [rsp+88h+var_50], 0 jz short loc_17A17 mov rdi, [rsp+88h+var_28] call JS_GetRuntime mov rdi, rax mov rsi, [rsp+88h+var_50] call free_sh loc_17A17: mov rdi, [rsp+88h+var_68] mov rsi, [rsp+88h+var_60] call JS_IsNull cmp eax, 0 jz short loc_17A36 mov [rsp+88h+var_70], 0 jmp short loc_17A40 loc_17A36: mov eax, 1 mov [rsp+88h+var_70], rax loc_17A40: mov edi, [rsp+88h+var_54] mov rsi, [rsp+88h+var_70] call _signal jmp loc_17B67 loc_17A53: mov rdi, [rsp+88h+var_28] mov rsi, [rsp+88h+var_68] mov rdx, [rsp+88h+var_60] call JS_IsFunction cmp eax, 0 jnz short loc_17A91 mov rdi, [rsp+88h+var_28] lea rsi, aSetAddIsNotAFu+0Bh; "not a function" mov al, 0 call JS_ThrowTypeError mov [rsp+88h+var_10], rax mov [rsp+88h+var_8], rdx jmp loc_17B7B loc_17A91: mov rdi, [rsp+88h+var_48] mov esi, [rsp+88h+var_54] call find_sh mov [rsp+88h+var_50], rax cmp [rsp+88h+var_50], 0 jnz short loc_17B00 mov rdi, [rsp+88h+var_28] mov esi, 28h ; '(' call js_mallocz mov [rsp+88h+var_50], rax cmp [rsp+88h+var_50], 0 jnz short loc_17AE1 mov dword ptr [rsp+88h+var_10], 0 mov [rsp+88h+var_8], 6 jmp loc_17B7B loc_17AE1: mov ecx, [rsp+88h+var_54] mov rax, [rsp+88h+var_50] mov [rax+10h], ecx mov rdi, [rsp+88h+var_50] mov rsi, [rsp+88h+var_48] add rsi, 10h call list_add_tail loc_17B00: mov rdi, [rsp+88h+var_28] mov rax, [rsp+88h+var_50] mov rsi, [rax+18h] mov rdx, [rax+20h] call JS_FreeValue mov rax, [rsp+88h+var_50] mov [rsp+88h+var_88], rax mov rdi, [rsp+88h+var_28] mov rsi, [rsp+88h+var_68] mov rdx, [rsp+88h+var_60] call JS_DupValue mov rcx, rax mov rax, [rsp+88h+var_88] mov [rsp+88h+var_80], rcx mov [rsp+88h+var_78], rdx mov rcx, [rsp+88h+var_80] mov [rax+18h], rcx mov rcx, [rsp+88h+var_78] mov [rax+20h], rcx mov edi, [rsp+88h+var_54] lea rsi, os_signal_handler call _signal loc_17B67: mov dword ptr [rsp+88h+var_10], 0 mov [rsp+88h+var_8], 3 loc_17B7B: mov rax, [rsp+88h+var_10] mov rdx, [rsp+88h+var_8] add rsp, 88h retn
long long js_os_signal(long long a1, long long a2, long long a3, int a4, _QWORD *a5) { int v5; // edx int v6; // ecx int v7; // r8d int v8; // r9d int v9; // edx int v10; // ecx int v11; // r8d int v12; // r9d int v13; // edx int v14; // ecx int v15; // r8d int v16; // r9d long long v17; // rdx int v18; // edx int v19; // ecx int v20; // r8d int v21; // r9d long long v22; // rdx long long v23; // rax int v24; // edx int v25; // ecx int v26; // r8d int v27; // r9d long long v28; // rdx long long v29; // rdx long long v31; // [rsp+0h] [rbp-88h] long long v32; // [rsp+20h] [rbp-68h] long long v33; // [rsp+28h] [rbp-60h] unsigned int v34; // [rsp+34h] [rbp-54h] BYREF long long sh; // [rsp+38h] [rbp-50h] long long thread_state; // [rsp+40h] [rbp-48h] long long Runtime; // [rsp+48h] [rbp-40h] _QWORD *v38; // [rsp+50h] [rbp-38h] int v39; // [rsp+5Ch] [rbp-2Ch] long long v40; // [rsp+60h] [rbp-28h] long long v41; // [rsp+68h] [rbp-20h] long long v42; // [rsp+70h] [rbp-18h] long long v43; // [rsp+78h] [rbp-10h] long long v44; // [rsp+80h] [rbp-8h] v41 = a2; v42 = a3; v40 = a1; v39 = a4; v38 = a5; Runtime = JS_GetRuntime(a1); thread_state = js_get_thread_state(Runtime, a2, v5, v6, v7, v8); if ( is_main_thread(Runtime, a2, v9, v10, v11, v12) ) { if ( (unsigned int)JS_ToUint32(v40, &v34, *v38, v38[1]) ) { LODWORD(v43) = 0; v44 = 6LL; } else { if ( v34 < 0x40 ) { v32 = v38[2]; v33 = v38[3]; if ( JS_IsNull(v32, v33) || JS_IsUndefined(v32, v33) ) { sh = find_sh(thread_state, v34); if ( sh ) { v23 = JS_GetRuntime(v40); free_sh(v23, sh); } if ( JS_IsNull(v32, v33) ) signal(v34, 0LL); else signal(v34, 1LL); } else { if ( !(unsigned int)JS_IsFunction(v40, v32, v33) ) { v43 = JS_ThrowTypeError(v40, (unsigned int)"not a function", v24, v25, v26, v27); v44 = v28; return v43; } sh = find_sh(thread_state, v34); if ( !sh ) { sh = js_mallocz(v40, 40LL); if ( !sh ) { LODWORD(v43) = 0; v44 = 6LL; return v43; } *(_DWORD *)(sh + 16) = v34; list_add_tail(sh, (_QWORD *)(thread_state + 16)); } JS_FreeValue(v40, *(_QWORD *)(sh + 24), *(_QWORD *)(sh + 32)); v31 = sh; *(_QWORD *)(v31 + 24) = JS_DupValue(v40, v32, v33); *(_QWORD *)(v31 + 32) = v29; signal(v34, os_signal_handler); } LODWORD(v43) = 0; v44 = 3LL; return v43; } v43 = JS_ThrowRangeError(v40, (unsigned int)"invalid signal number", v18, v19, v20, v21); v44 = v22; } } else { v43 = JS_ThrowTypeError(v40, (unsigned int)"signal handler can only be set in the main thread", v13, v14, v15, v16); v44 = v17; } return v43; }
js_os_signal: SUB RSP,0x88 MOV qword ptr [RSP + 0x68],RSI MOV qword ptr [RSP + 0x70],RDX MOV qword ptr [RSP + 0x60],RDI MOV dword ptr [RSP + 0x5c],ECX MOV qword ptr [RSP + 0x50],R8 MOV RDI,qword ptr [RSP + 0x60] CALL 0x00126c40 MOV qword ptr [RSP + 0x48],RAX MOV RDI,qword ptr [RSP + 0x48] CALL 0x00110310 MOV qword ptr [RSP + 0x40],RAX MOV RDI,qword ptr [RSP + 0x48] CALL 0x00116530 CMP EAX,0x0 JNZ 0x00117941 MOV RDI,qword ptr [RSP + 0x60] LEA RSI,[0x2089f1] MOV AL,0x0 CALL 0x0012c040 MOV qword ptr [RSP + 0x78],RAX MOV qword ptr [RSP + 0x80],RDX JMP 0x00117b7b LAB_00117941: MOV RDI,qword ptr [RSP + 0x60] MOV RAX,qword ptr [RSP + 0x50] MOV RDX,qword ptr [RAX] MOV RCX,qword ptr [RAX + 0x8] LEA RSI,[RSP + 0x34] CALL 0x0011baa0 CMP EAX,0x0 JZ 0x0011797a MOV dword ptr [RSP + 0x78],0x0 MOV qword ptr [RSP + 0x80],0x6 JMP 0x00117b7b LAB_0011797a: CMP dword ptr [RSP + 0x34],0x40 JC 0x001179a6 MOV RDI,qword ptr [RSP + 0x60] LEA RSI,[0x208a23] MOV AL,0x0 CALL 0x001283b0 MOV qword ptr [RSP + 0x78],RAX MOV qword ptr [RSP + 0x80],RDX JMP 0x00117b7b LAB_001179a6: MOV RAX,qword ptr [RSP + 0x50] MOV RCX,qword ptr [RAX + 0x10] MOV qword ptr [RSP + 0x20],RCX MOV RAX,qword ptr [RAX + 0x18] MOV qword ptr [RSP + 0x28],RAX MOV RDI,qword ptr [RSP + 0x20] MOV RSI,qword ptr [RSP + 0x28] CALL 0x00115560 CMP EAX,0x0 JNZ 0x001179e5 MOV RDI,qword ptr [RSP + 0x20] MOV RSI,qword ptr [RSP + 0x28] CALL 0x00110670 CMP EAX,0x0 JZ 0x00117a53 LAB_001179e5: MOV RDI,qword ptr [RSP + 0x40] MOV ESI,dword ptr [RSP + 0x34] CALL 0x0011bae0 MOV qword ptr [RSP + 0x38],RAX CMP qword ptr [RSP + 0x38],0x0 JZ 0x00117a17 MOV RDI,qword ptr [RSP + 0x60] CALL 0x00126c40 MOV RDI,RAX MOV RSI,qword ptr [RSP + 0x38] CALL 0x001103a0 LAB_00117a17: MOV RDI,qword ptr [RSP + 0x20] MOV RSI,qword ptr [RSP + 0x28] CALL 0x00115560 CMP EAX,0x0 JZ 0x00117a36 MOV qword ptr [RSP + 0x18],0x0 JMP 0x00117a40 LAB_00117a36: MOV EAX,0x1 MOV qword ptr [RSP + 0x18],RAX LAB_00117a40: MOV EDI,dword ptr [RSP + 0x34] MOV RSI,qword ptr [RSP + 0x18] CALL 0x0010e510 JMP 0x00117b67 LAB_00117a53: MOV RDI,qword ptr [RSP + 0x60] MOV RSI,qword ptr [RSP + 0x20] MOV RDX,qword ptr [RSP + 0x28] CALL 0x0012d250 CMP EAX,0x0 JNZ 0x00117a91 MOV RDI,qword ptr [RSP + 0x60] LEA RSI,[0x20dbc4] MOV AL,0x0 CALL 0x0012c040 MOV qword ptr [RSP + 0x78],RAX MOV qword ptr [RSP + 0x80],RDX JMP 0x00117b7b LAB_00117a91: MOV RDI,qword ptr [RSP + 0x40] MOV ESI,dword ptr [RSP + 0x34] CALL 0x0011bae0 MOV qword ptr [RSP + 0x38],RAX CMP qword ptr [RSP + 0x38],0x0 JNZ 0x00117b00 MOV RDI,qword ptr [RSP + 0x60] MOV ESI,0x28 CALL 0x00120a70 MOV qword ptr [RSP + 0x38],RAX CMP qword ptr [RSP + 0x38],0x0 JNZ 0x00117ae1 MOV dword ptr [RSP + 0x78],0x0 MOV qword ptr [RSP + 0x80],0x6 JMP 0x00117b7b LAB_00117ae1: MOV ECX,dword ptr [RSP + 0x34] MOV RAX,qword ptr [RSP + 0x38] MOV dword ptr [RAX + 0x10],ECX MOV RDI,qword ptr [RSP + 0x38] MOV RSI,qword ptr [RSP + 0x40] ADD RSI,0x10 CALL 0x00116460 LAB_00117b00: MOV RDI,qword ptr [RSP + 0x60] MOV RAX,qword ptr [RSP + 0x38] MOV RSI,qword ptr [RAX + 0x18] MOV RDX,qword ptr [RAX + 0x20] CALL 0x001229d0 MOV RAX,qword ptr [RSP + 0x38] MOV qword ptr [RSP],RAX MOV RDI,qword ptr [RSP + 0x60] MOV RSI,qword ptr [RSP + 0x20] MOV RDX,qword ptr [RSP + 0x28] CALL 0x001203d0 MOV RCX,RAX MOV RAX,qword ptr [RSP] MOV qword ptr [RSP + 0x8],RCX MOV qword ptr [RSP + 0x10],RDX MOV RCX,qword ptr [RSP + 0x8] MOV qword ptr [RAX + 0x18],RCX MOV RCX,qword ptr [RSP + 0x10] MOV qword ptr [RAX + 0x20],RCX MOV EDI,dword ptr [RSP + 0x34] LEA RSI,[0x11bb50] CALL 0x0010e510 LAB_00117b67: MOV dword ptr [RSP + 0x78],0x0 MOV qword ptr [RSP + 0x80],0x3 LAB_00117b7b: MOV RAX,qword ptr [RSP + 0x78] MOV RDX,qword ptr [RSP + 0x80] ADD RSP,0x88 RET
int1 [16] js_os_signal(int8 param_1,int8 param_2,int8 param_3,int4 param_4, int8 *param_5) { int8 uVar1; int8 uVar2; long lVar3; int iVar4; int8 uVar5; int1 auVar6 [16]; __sighandler_t local_70; uint local_54; long local_50; long local_48; int8 local_40; int8 *local_38; int4 local_2c; int8 local_28; int8 local_20; int8 local_18; int4 local_10; int4 uStack_c; int8 local_8; local_38 = param_5; local_2c = param_4; local_28 = param_1; local_20 = param_2; local_18 = param_3; local_40 = JS_GetRuntime(param_1); local_48 = js_get_thread_state(local_40); iVar4 = is_main_thread(local_40); if (iVar4 == 0) { auVar6 = JS_ThrowTypeError(local_28,"signal handler can only be set in the main thread"); local_8 = auVar6._8_8_; local_10 = auVar6._0_4_; uStack_c = auVar6._4_4_; } else { iVar4 = JS_ToUint32(local_28,&local_54,*local_38,local_38[1]); if (iVar4 == 0) { if (local_54 < 0x40) { uVar1 = local_38[2]; uVar2 = local_38[3]; iVar4 = JS_IsNull(uVar1,uVar2); if ((iVar4 == 0) && (iVar4 = JS_IsUndefined(uVar1,uVar2), iVar4 == 0)) { iVar4 = JS_IsFunction(local_28,uVar1,uVar2); if (iVar4 == 0) { auVar6 = JS_ThrowTypeError(local_28,"not a function"); local_8 = auVar6._8_8_; local_10 = auVar6._0_4_; uStack_c = auVar6._4_4_; goto LAB_00117b7b; } local_50 = find_sh(local_48,local_54); if (local_50 == 0) { local_50 = js_mallocz(local_28,0x28); if (local_50 == 0) { local_10 = 0; local_8 = 6; goto LAB_00117b7b; } *(uint *)(local_50 + 0x10) = local_54; list_add_tail(local_50,local_48 + 0x10); } JS_FreeValue(local_28,*(int8 *)(local_50 + 0x18),*(int8 *)(local_50 + 0x20)); lVar3 = local_50; auVar6 = JS_DupValue(local_28,uVar1,uVar2); *(int1 (*) [16])(lVar3 + 0x18) = auVar6; signal(local_54,os_signal_handler); } else { local_50 = find_sh(local_48,local_54); if (local_50 != 0) { uVar5 = JS_GetRuntime(local_28); free_sh(uVar5,local_50); } iVar4 = JS_IsNull(uVar1,uVar2); local_70 = (__sighandler_t)(ulong)(iVar4 == 0); signal(local_54,local_70); } local_10 = 0; local_8 = 3; } else { auVar6 = JS_ThrowRangeError(local_28,"invalid signal number"); local_8 = auVar6._8_8_; local_10 = auVar6._0_4_; uStack_c = auVar6._4_4_; } } else { local_10 = 0; local_8 = 6; } } LAB_00117b7b: auVar6._4_4_ = uStack_c; auVar6._0_4_ = local_10; auVar6._8_8_ = local_8; return auVar6; }
3,552
js_os_signal
bluesky950520[P]quickjs/quickjs-libc.c
static JSValue js_os_signal(JSContext *ctx, JSValue this_val, int argc, JSValue *argv) { JSRuntime *rt = JS_GetRuntime(ctx); JSThreadState *ts = js_get_thread_state(rt); JSOSSignalHandler *sh; uint32_t sig_num; JSValue func; sighandler_t handler; if (!is_main_thread(rt)) return JS_ThrowTypeError(ctx, "signal handler can only be set in the main thread"); if (JS_ToUint32(ctx, &sig_num, argv[0])) return JS_EXCEPTION; if (sig_num >= 64) return JS_ThrowRangeError(ctx, "invalid signal number"); func = argv[1]; /* func = null: SIG_DFL, func = undefined, SIG_IGN */ if (JS_IsNull(func) || JS_IsUndefined(func)) { sh = find_sh(ts, sig_num); if (sh) { free_sh(JS_GetRuntime(ctx), sh); } if (JS_IsNull(func)) handler = SIG_DFL; else handler = SIG_IGN; signal(sig_num, handler); } else { if (!JS_IsFunction(ctx, func)) return JS_ThrowTypeError(ctx, "not a function"); sh = find_sh(ts, sig_num); if (!sh) { sh = js_mallocz(ctx, sizeof(*sh)); if (!sh) return JS_EXCEPTION; sh->sig_num = sig_num; list_add_tail(&sh->link, &ts->os_signal_handlers); } JS_FreeValue(ctx, sh->func); sh->func = JS_DupValue(ctx, func); signal(sig_num, os_signal_handler); } return JS_UNDEFINED; }
O1
c
js_os_signal: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx pushq %rax movq %r8, %r12 movq %rdi, %rbx callq 0x1f16a movq %rax, %r14 xorl %edi, %edi movq %rax, %rsi xorl %eax, %eax callq 0x399df movq %rax, %r13 xorl %edi, %edi movq %r14, %rsi xorl %eax, %eax callq 0x399df cmpq $0x0, 0x68(%rax) je 0x183f5 leaq 0x82580(%rip), %rsi # 0x9a959 movq %rbx, %rdi xorl %eax, %eax callq 0x21953 movq %rdx, %r14 movabsq $-0x100000000, %rcx # imm = 0xFFFFFFFF00000000 andq %rax, %rcx jmp 0x18419 movq (%r12), %rdx movq 0x8(%r12), %rcx leaq 0x4(%rsp), %rsi movq %rbx, %rdi callq 0x26d9c movl $0x6, %r14d testl %eax, %eax je 0x18430 xorl %eax, %eax xorl %ecx, %ecx movl %eax, %eax orq %rcx, %rax movq %r14, %rdx addq $0x8, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movl 0x4(%rsp), %eax cmpl $0x40, %eax jb 0x1844c leaq 0x8254b(%rip), %rsi # 0x9a98b movq %rbx, %rdi xorl %eax, %eax callq 0x1fec9 jmp 0x183e3 movq 0x18(%r12), %r15 movl %r15d, %ecx andl $-0x2, %ecx cmpl $0x2, %ecx jne 0x18483 movl %r15d, %r15d movq %r13, %rcx addq $0x10, %rcx movq 0x18(%r13), %r14 cmpq %rcx, %r14 je 0x18531 cmpl %eax, 0x10(%r14) je 0x18534 movq 0x8(%r14), %r14 jmp 0x1846a movq 0x10(%r12), %r12 movq %rbx, %rdi movq %r12, %rsi movq %r15, %rdx callq 0x221aa testl %eax, %eax je 0x1856a movq %r13, %rbp addq $0x10, %rbp movq 0x18(%r13), %r13 cmpq %rbp, %r13 je 0x184c1 movl 0x4(%rsp), %eax cmpl %eax, 0x10(%r13) je 0x184c4 movq 0x8(%r13), %r13 cmpq %rbp, %r13 jne 0x184b2 xorl %r13d, %r13d testq %r13, %r13 jne 0x184fe movl $0x28, %esi movq %rbx, %rdi callq 0xed7d testq %rax, %rax je 0x18415 movq %rax, %r13 movl 0x4(%rsp), %eax movl %eax, 0x10(%r13) movq (%rbp), %rax movq %r13, 0x8(%rax) movq %rax, (%r13) movq %rbp, 0x8(%r13) movq %r13, (%rbp) movq 0x18(%r13), %rsi movq 0x20(%r13), %rdx movq %rbx, %rdi callq 0x1cc9f movq %rbx, %rdi movq %r12, %rsi movq %r15, %rdx callq 0x1be46 movq %rax, 0x18(%r13) movq %rdx, 0x20(%r13) movl 0x4(%rsp), %edi leaq 0x19c6(%rip), %rsi # 0x19ef5 jmp 0x1855a xorl %r14d, %r14d testq %r14, %r14 je 0x1854c movq %rbx, %rdi callq 0x1f16a movq %rax, %rdi movq %r14, %rsi callq 0x14749 xorl %esi, %esi cmpl $0x2, %r15d setne %sil movl 0x4(%rsp), %edi callq 0xe510 movl $0x3, %r14d jmp 0x18415 leaq 0x86657(%rip), %rsi # 0x9ebc8 jmp 0x183d9
js_os_signal: push rbp push r15 push r14 push r13 push r12 push rbx push rax mov r12, r8 mov rbx, rdi call JS_GetRuntime mov r14, rax xor edi, edi mov rsi, rax xor eax, eax call js_std_cmd mov r13, rax xor edi, edi mov rsi, r14 xor eax, eax call js_std_cmd cmp qword ptr [rax+68h], 0 jz short loc_183F5 lea rsi, aSignalHandlerC; "signal handler can only be set in the m"... loc_183D9: mov rdi, rbx xor eax, eax call JS_ThrowTypeError loc_183E3: mov r14, rdx mov rcx, 0FFFFFFFF00000000h and rcx, rax jmp short loc_18419 loc_183F5: mov rdx, [r12] mov rcx, [r12+8] lea rsi, [rsp+38h+var_34] mov rdi, rbx call JS_ToInt32 mov r14d, 6 test eax, eax jz short loc_18430 loc_18415: xor eax, eax xor ecx, ecx loc_18419: mov eax, eax or rax, rcx mov rdx, r14 add rsp, 8 pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_18430: mov eax, [rsp+38h+var_34] cmp eax, 40h ; '@' jb short loc_1844C lea rsi, aInvalidSignalN; "invalid signal number" mov rdi, rbx xor eax, eax call JS_ThrowRangeError jmp short loc_183E3 loc_1844C: mov r15, [r12+18h] mov ecx, r15d and ecx, 0FFFFFFFEh cmp ecx, 2 jnz short loc_18483 mov r15d, r15d mov rcx, r13 add rcx, 10h mov r14, [r13+18h] loc_1846A: cmp r14, rcx jz loc_18531 cmp [r14+10h], eax jz loc_18534 mov r14, [r14+8] jmp short loc_1846A loc_18483: mov r12, [r12+10h] mov rdi, rbx mov rsi, r12 mov rdx, r15 call JS_IsFunction test eax, eax jz loc_1856A mov rbp, r13 add rbp, 10h mov r13, [r13+18h] cmp r13, rbp jz short loc_184C1 mov eax, [rsp+38h+var_34] loc_184B2: cmp [r13+10h], eax jz short loc_184C4 mov r13, [r13+8] cmp r13, rbp jnz short loc_184B2 loc_184C1: xor r13d, r13d loc_184C4: test r13, r13 jnz short loc_184FE mov esi, 28h ; '(' mov rdi, rbx call js_mallocz test rax, rax jz loc_18415 mov r13, rax mov eax, [rsp+38h+var_34] mov [r13+10h], eax mov rax, [rbp+0] mov [rax+8], r13 mov [r13+0], rax mov [r13+8], rbp mov [rbp+0], r13 loc_184FE: mov rsi, [r13+18h] mov rdx, [r13+20h] mov rdi, rbx call JS_FreeValue mov rdi, rbx mov rsi, r12 mov rdx, r15 call JS_DupValue mov [r13+18h], rax mov [r13+20h], rdx mov edi, [rsp+38h+var_34] lea rsi, os_signal_handler jmp short loc_1855A loc_18531: xor r14d, r14d loc_18534: test r14, r14 jz short loc_1854C mov rdi, rbx call JS_GetRuntime mov rdi, rax mov rsi, r14 call free_sh loc_1854C: xor esi, esi cmp r15d, 2 setnz sil mov edi, [rsp+38h+var_34] loc_1855A: call _signal mov r14d, 3 jmp loc_18415 loc_1856A: lea rsi, aSetAddIsNotAFu+0Bh; "not a function" jmp loc_183D9
unsigned long long js_os_signal(long long a1, long long a2, long long a3, long long a4, _QWORD *a5) { long long v5; // rax int Runtime; // r14d int v8; // edx int v9; // ecx int v10; // r8d int v11; // r9d long long v12; // r13 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; // rsi long long v22; // rax unsigned long long v23; // rcx int v24; // edx int v25; // ecx int v26; // r8d int v27; // r9d long long v29; // r15 long long i; // r14 long long v31; // r12 long long *v32; // rbp long long v33; // r13 long long v34; // rax long long v35; // rax long long v36; // rdx long long v37; // rdi unsigned long long v38; // rsi long long v39; // rax unsigned int v40[13]; // [rsp+0h] [rbp-34h] BYREF v40[0] = HIDWORD(v5); Runtime = JS_GetRuntime(a1); v12 = js_std_cmd(0, Runtime, v8, v9, v10, v11); if ( !*(_QWORD *)(js_std_cmd(0, Runtime, v13, v14, v15, v16) + 104) ) { if ( (unsigned int)JS_ToInt32(a1, v40, *a5, a5[1]) ) { LABEL_6: LODWORD(v22) = 0; v23 = 0LL; return v23 | (unsigned int)v22; } if ( v40[0] >= 0x40 ) { v22 = JS_ThrowRangeError(a1, (unsigned int)"invalid signal number", v24, v25, v26, v27); goto LABEL_4; } v29 = a5[3]; if ( (a5[3] & 0xFFFFFFFE) == 2 ) { for ( i = *(_QWORD *)(v12 + 24); i != v12 + 16; i = *(_QWORD *)(i + 8) ) { if ( *(_DWORD *)(i + 16) == v40[0] ) goto LABEL_25; } i = 0LL; LABEL_25: if ( i ) { v39 = JS_GetRuntime(a1); free_sh(v39, (long long *)i); } v38 = (_DWORD)v29 != 2; v37 = v40[0]; } else { v31 = a5[2]; if ( !(unsigned int)JS_IsFunction(a1, v31, v29) ) { v21 = "not a function"; goto LABEL_3; } v32 = (long long *)(v12 + 16); v33 = *(_QWORD *)(v12 + 24); if ( (long long *)v33 == v32 ) { LABEL_19: v33 = 0LL; } else { while ( *(_DWORD *)(v33 + 16) != v40[0] ) { v33 = *(_QWORD *)(v33 + 8); if ( (long long *)v33 == v32 ) goto LABEL_19; } } if ( !v33 ) { v34 = js_mallocz(a1, 0x28uLL); if ( !v34 ) goto LABEL_6; v33 = v34; *(_DWORD *)(v34 + 16) = v40[0]; v35 = *v32; *(_QWORD *)(v35 + 8) = v33; *(_QWORD *)v33 = v35; *(_QWORD *)(v33 + 8) = v32; *v32 = v33; } JS_FreeValue(a1, *(_QWORD *)(v33 + 24), *(_QWORD *)(v33 + 32)); *(_QWORD *)(v33 + 24) = JS_DupValue(a1, v31, v29); *(_QWORD *)(v33 + 32) = v36; v37 = v40[0]; v38 = (unsigned long long)os_signal_handler; } signal(v37, v38); goto LABEL_6; } v21 = "signal handler can only be set in the main thread"; LABEL_3: v22 = JS_ThrowTypeError(a1, (_DWORD)v21, v17, v18, v19, v20); LABEL_4: v23 = v22 & 0xFFFFFFFF00000000LL; return v23 | (unsigned int)v22; }
js_os_signal: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX PUSH RAX MOV R12,R8 MOV RBX,RDI CALL 0x0011f16a MOV R14,RAX XOR EDI,EDI MOV RSI,RAX XOR EAX,EAX CALL 0x001399df MOV R13,RAX XOR EDI,EDI MOV RSI,R14 XOR EAX,EAX CALL 0x001399df CMP qword ptr [RAX + 0x68],0x0 JZ 0x001183f5 LEA RSI,[0x19a959] LAB_001183d9: MOV RDI,RBX XOR EAX,EAX CALL 0x00121953 LAB_001183e3: MOV R14,RDX MOV RCX,-0x100000000 AND RCX,RAX JMP 0x00118419 LAB_001183f5: MOV RDX,qword ptr [R12] MOV RCX,qword ptr [R12 + 0x8] LEA RSI,[RSP + 0x4] MOV RDI,RBX CALL 0x00126d9c MOV R14D,0x6 TEST EAX,EAX JZ 0x00118430 LAB_00118415: XOR EAX,EAX XOR ECX,ECX LAB_00118419: MOV EAX,EAX OR RAX,RCX MOV RDX,R14 ADD RSP,0x8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00118430: MOV EAX,dword ptr [RSP + 0x4] CMP EAX,0x40 JC 0x0011844c LEA RSI,[0x19a98b] MOV RDI,RBX XOR EAX,EAX CALL 0x0011fec9 JMP 0x001183e3 LAB_0011844c: MOV R15,qword ptr [R12 + 0x18] MOV ECX,R15D AND ECX,0xfffffffe CMP ECX,0x2 JNZ 0x00118483 MOV R15D,R15D MOV RCX,R13 ADD RCX,0x10 MOV R14,qword ptr [R13 + 0x18] LAB_0011846a: CMP R14,RCX JZ 0x00118531 CMP dword ptr [R14 + 0x10],EAX JZ 0x00118534 MOV R14,qword ptr [R14 + 0x8] JMP 0x0011846a LAB_00118483: MOV R12,qword ptr [R12 + 0x10] MOV RDI,RBX MOV RSI,R12 MOV RDX,R15 CALL 0x001221aa TEST EAX,EAX JZ 0x0011856a MOV RBP,R13 ADD RBP,0x10 MOV R13,qword ptr [R13 + 0x18] CMP R13,RBP JZ 0x001184c1 MOV EAX,dword ptr [RSP + 0x4] LAB_001184b2: CMP dword ptr [R13 + 0x10],EAX JZ 0x001184c4 MOV R13,qword ptr [R13 + 0x8] CMP R13,RBP JNZ 0x001184b2 LAB_001184c1: XOR R13D,R13D LAB_001184c4: TEST R13,R13 JNZ 0x001184fe MOV ESI,0x28 MOV RDI,RBX CALL 0x0010ed7d TEST RAX,RAX JZ 0x00118415 MOV R13,RAX MOV EAX,dword ptr [RSP + 0x4] MOV dword ptr [R13 + 0x10],EAX MOV RAX,qword ptr [RBP] MOV qword ptr [RAX + 0x8],R13 MOV qword ptr [R13],RAX MOV qword ptr [R13 + 0x8],RBP MOV qword ptr [RBP],R13 LAB_001184fe: MOV RSI,qword ptr [R13 + 0x18] MOV RDX,qword ptr [R13 + 0x20] MOV RDI,RBX CALL 0x0011cc9f MOV RDI,RBX MOV RSI,R12 MOV RDX,R15 CALL 0x0011be46 MOV qword ptr [R13 + 0x18],RAX MOV qword ptr [R13 + 0x20],RDX MOV EDI,dword ptr [RSP + 0x4] LEA RSI,[0x119ef5] JMP 0x0011855a LAB_00118531: XOR R14D,R14D LAB_00118534: TEST R14,R14 JZ 0x0011854c MOV RDI,RBX CALL 0x0011f16a MOV RDI,RAX MOV RSI,R14 CALL 0x00114749 LAB_0011854c: XOR ESI,ESI CMP R15D,0x2 SETNZ SIL MOV EDI,dword ptr [RSP + 0x4] LAB_0011855a: CALL 0x0010e510 MOV R14D,0x3 JMP 0x00118415 LAB_0011856a: LEA RSI,[0x19ebc8] JMP 0x001183d9
int1 [16] js_os_signal(int8 param_1) { int iVar1; int8 in_RAX; int8 uVar2; long lVar3; long lVar4; long *plVar5; int8 uVar6; ulong uVar7; long *plVar8; char *pcVar9; code *__handler; int8 *in_R8; int1 auVar10 [16]; int1 auVar11 [16]; uint local_34; local_34 = (uint)((ulong)in_RAX >> 0x20); uVar2 = JS_GetRuntime(); lVar3 = js_std_cmd(0,uVar2); lVar4 = js_std_cmd(0,uVar2); if (*(long *)(lVar4 + 0x68) == 0) { iVar1 = JS_ToInt32(param_1,&local_34,*in_R8,in_R8[1]); uVar7 = 6; if (iVar1 == 0) { if (0x3f < local_34) { auVar10 = JS_ThrowRangeError(param_1,"invalid signal number"); goto LAB_001183e3; } uVar2 = in_R8[3]; if (((uint)uVar2 & 0xfffffffe) == 2) { for (lVar4 = *(long *)(lVar3 + 0x18); lVar4 != lVar3 + 0x10; lVar4 = *(long *)(lVar4 + 8)) { if (*(uint *)(lVar4 + 0x10) == local_34) goto LAB_00118534; } lVar4 = 0; LAB_00118534: if (lVar4 != 0) { uVar6 = JS_GetRuntime(param_1); free_sh(uVar6,lVar4); } __handler = (code *)(ulong)((uint)uVar2 != 2); } else { uVar6 = in_R8[2]; iVar1 = JS_IsFunction(param_1,uVar6,uVar2); if (iVar1 == 0) { pcVar9 = "not a function"; goto LAB_001183d9; } plVar8 = (long *)(lVar3 + 0x10); for (plVar5 = *(long **)(lVar3 + 0x18); plVar5 != plVar8; plVar5 = (long *)plVar5[1]) { if (*(uint *)(plVar5 + 2) == local_34) goto LAB_001184c4; } plVar5 = (long *)0x0; LAB_001184c4: if (plVar5 == (long *)0x0) { plVar5 = (long *)js_mallocz(param_1,0x28); if (plVar5 == (long *)0x0) goto LAB_00118415; *(uint *)(plVar5 + 2) = local_34; lVar3 = *plVar8; *(long **)(lVar3 + 8) = plVar5; *plVar5 = lVar3; plVar5[1] = (long)plVar8; *plVar8 = (long)plVar5; } JS_FreeValue(param_1,plVar5[3],plVar5[4]); auVar10 = JS_DupValue(param_1,uVar6,uVar2); *(int1 (*) [16])(plVar5 + 3) = auVar10; __handler = os_signal_handler; } signal(local_34,__handler); uVar7 = 3; } LAB_00118415: auVar10._8_8_ = 0; auVar10._0_8_ = uVar7; auVar10 = auVar10 << 0x40; uVar7 = 0; } else { pcVar9 = "signal handler can only be set in the main thread"; LAB_001183d9: auVar10 = JS_ThrowTypeError(param_1,pcVar9); LAB_001183e3: uVar7 = auVar10._0_8_ & 0xffffffff00000000; } auVar11._0_8_ = auVar10._0_8_ & 0xffffffff | uVar7; auVar11._8_8_ = auVar10._8_8_; return auVar11; }
3,553
my_lengthsp_mb2
eloqsql/strings/ctype-ucs2.c
static size_t my_lengthsp_mb2(CHARSET_INFO *cs __attribute__((unused)), const char *ptr, size_t length) { const char *end= ptr + length; while (end > ptr + 1 && end[-1] == ' ' && end[-2] == '\0') end-= 2; return (size_t) (end - ptr); }
O0
c
my_lengthsp_mb2: pushq %rbp movq %rsp, %rbp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x10(%rbp), %rax addq -0x18(%rbp), %rax movq %rax, -0x20(%rbp) movq -0x20(%rbp), %rcx movq -0x10(%rbp), %rdx addq $0x1, %rdx xorl %eax, %eax cmpq %rdx, %rcx movb %al, -0x21(%rbp) jbe 0x61825 movq -0x20(%rbp), %rax movsbl -0x1(%rax), %ecx xorl %eax, %eax cmpl $0x20, %ecx movb %al, -0x21(%rbp) jne 0x61825 movq -0x20(%rbp), %rax movsbl -0x2(%rax), %eax cmpl $0x0, %eax sete %al movb %al, -0x21(%rbp) movb -0x21(%rbp), %al testb $0x1, %al jne 0x6182e jmp 0x6183c movq -0x20(%rbp), %rax addq $-0x2, %rax movq %rax, -0x20(%rbp) jmp 0x617ec movq -0x20(%rbp), %rax movq -0x10(%rbp), %rcx subq %rcx, %rax popq %rbp retq nopl (%rax)
my_lengthsp_mb2: push rbp mov rbp, rsp mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_10] add rax, [rbp+var_18] mov [rbp+var_20], rax loc_617EC: mov rcx, [rbp+var_20] mov rdx, [rbp+var_10] add rdx, 1 xor eax, eax cmp rcx, rdx mov [rbp+var_21], al jbe short loc_61825 mov rax, [rbp+var_20] movsx ecx, byte ptr [rax-1] xor eax, eax cmp ecx, 20h ; ' ' mov [rbp+var_21], al jnz short loc_61825 mov rax, [rbp+var_20] movsx eax, byte ptr [rax-2] cmp eax, 0 setz al mov [rbp+var_21], al loc_61825: mov al, [rbp+var_21] test al, 1 jnz short loc_6182E jmp short loc_6183C loc_6182E: mov rax, [rbp+var_20] add rax, 0FFFFFFFFFFFFFFFEh mov [rbp+var_20], rax jmp short loc_617EC loc_6183C: mov rax, [rbp+var_20] mov rcx, [rbp+var_10] sub rax, rcx pop rbp retn
long long my_lengthsp_mb2(long long a1, long long a2, long long a3) { bool v4; // [rsp+1h] [rbp-21h] unsigned long long i; // [rsp+2h] [rbp-20h] for ( i = a3 + a2; ; i -= 2LL ) { v4 = 0; if ( i > a2 + 1 ) { v4 = 0; if ( *(_BYTE *)(i - 1) == 32 ) v4 = *(_BYTE *)(i - 2) == 0; } if ( !v4 ) break; } return i - a2; }
my_lengthsp_mb2: PUSH RBP MOV RBP,RSP MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x10] ADD RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x20],RAX LAB_001617ec: MOV RCX,qword ptr [RBP + -0x20] MOV RDX,qword ptr [RBP + -0x10] ADD RDX,0x1 XOR EAX,EAX CMP RCX,RDX MOV byte ptr [RBP + -0x21],AL JBE 0x00161825 MOV RAX,qword ptr [RBP + -0x20] MOVSX ECX,byte ptr [RAX + -0x1] XOR EAX,EAX CMP ECX,0x20 MOV byte ptr [RBP + -0x21],AL JNZ 0x00161825 MOV RAX,qword ptr [RBP + -0x20] MOVSX EAX,byte ptr [RAX + -0x2] CMP EAX,0x0 SETZ AL MOV byte ptr [RBP + -0x21],AL LAB_00161825: MOV AL,byte ptr [RBP + -0x21] TEST AL,0x1 JNZ 0x0016182e JMP 0x0016183c LAB_0016182e: MOV RAX,qword ptr [RBP + -0x20] ADD RAX,-0x2 MOV qword ptr [RBP + -0x20],RAX JMP 0x001617ec LAB_0016183c: MOV RAX,qword ptr [RBP + -0x20] MOV RCX,qword ptr [RBP + -0x10] SUB RAX,RCX POP RBP RET
long my_lengthsp_mb2(int8 param_1,long param_2,long param_3) { bool bVar1; int8 local_28; local_28 = param_2 + param_3; while( true ) { bVar1 = false; if ((param_2 + 1U < local_28) && (bVar1 = false, *(char *)(local_28 - 1) == ' ')) { bVar1 = *(char *)(local_28 - 2) == '\0'; } if (!bVar1) break; local_28 = local_28 - 2; } return local_28 - param_2; }
3,554
my_b_seq_read
eloqsql/mysys/mf_iocache.c
static int _my_b_seq_read(IO_CACHE *info, uchar *Buffer, size_t Count) { size_t length, diff_length, save_count, max_length; my_off_t pos_in_file; save_count=Count; lock_append_buffer(info); /* pos_in_file always point on where info->buffer was read */ if ((pos_in_file=info->pos_in_file + (size_t) (info->read_end - info->buffer)) >= info->end_of_file) goto read_append_buffer; /* With read-append cache we must always do a seek before we read, because the write could have moved the file pointer astray */ if (mysql_file_seek(info->file, pos_in_file, MY_SEEK_SET, MYF(0)) == MY_FILEPOS_ERROR) { info->error= -1; unlock_append_buffer(info); return (1); } info->seek_not_done=0; diff_length= (size_t) (pos_in_file & (IO_SIZE-1)); /* now the second stage begins - read from file descriptor */ if (Count >= (size_t) (IO_SIZE+(IO_SIZE-diff_length))) { /* Fill first intern buffer */ size_t read_length; length= IO_ROUND_DN(Count) - diff_length; if ((read_length= mysql_file_read(info->file,Buffer, length, info->myflags)) == (size_t) -1) { info->error= -1; unlock_append_buffer(info); return 1; } Count-=read_length; Buffer+=read_length; pos_in_file+=read_length; if (read_length != length) { /* We only got part of data; Read the rest of the data from the write buffer */ goto read_append_buffer; } diff_length=0; } max_length= info->read_length-diff_length; if (max_length > (info->end_of_file - pos_in_file)) max_length= (size_t) (info->end_of_file - pos_in_file); if (!max_length) { if (Count) goto read_append_buffer; length=0; /* Didn't read any more chars */ } else { length= mysql_file_read(info->file,info->buffer, max_length, info->myflags); if (length == (size_t) -1) { info->error= -1; unlock_append_buffer(info); return 1; } if (length < Count) { memcpy(Buffer, info->buffer, length); Count -= length; Buffer += length; /* added the line below to make DBUG_ASSERT(pos_in_file==info->end_of_file) pass. otherwise this does not appear to be needed */ pos_in_file += length; goto read_append_buffer; } } unlock_append_buffer(info); info->read_pos=info->buffer+Count; info->read_end=info->buffer+length; info->pos_in_file=pos_in_file; memcpy(Buffer,info->buffer,(size_t) Count); return 0; read_append_buffer: /* Read data from the current write buffer. Count should never be == 0 here (The code will work even if count is 0) */ { /* First copy the data to Count */ size_t len_in_buff = (size_t) (info->write_pos - info->append_read_pos); size_t copy_len; size_t transfer_len; DBUG_ASSERT(info->append_read_pos <= info->write_pos); copy_len=MY_MIN(Count, len_in_buff); memcpy(Buffer, info->append_read_pos, copy_len); info->append_read_pos += copy_len; Count -= copy_len; if (Count) info->error= (int) (save_count - Count); /* Fill read buffer with data from write buffer */ memcpy(info->buffer, info->append_read_pos, (size_t) (transfer_len=len_in_buff - copy_len)); info->read_pos= info->buffer; info->read_end= info->buffer+transfer_len; info->append_read_pos=info->write_pos; info->pos_in_file=pos_in_file+copy_len; info->end_of_file+=len_in_buff; } unlock_append_buffer(info); return Count ? 1 : 0; }
O0
c
my_b_seq_read: pushq %rbp movq %rsp, %rbp subq $0x70, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x20(%rbp), %rax movq %rax, -0x38(%rbp) movq -0x10(%rbp), %rdi addq $0x50, %rdi leaq 0x7147b(%rip), %rsi # 0x155096 movl $0x54c, %edx # imm = 0x54C callq 0xe30f0 movq -0x10(%rbp), %rax movq (%rax), %rax movq -0x10(%rbp), %rcx movq 0x18(%rcx), %rcx movq -0x10(%rbp), %rdx movq 0x20(%rdx), %rdx subq %rdx, %rcx addq %rcx, %rax movq %rax, -0x48(%rbp) movq -0x10(%rbp), %rcx cmpq 0x8(%rcx), %rax jb 0xe3c55 jmp 0xe3efc movq -0x10(%rbp), %rax movl 0xd4(%rax), %edx movq -0x48(%rbp), %rcx leaq 0x7142c(%rip), %rdi # 0x155096 movl $0x557, %esi # imm = 0x557 xorl %r8d, %r8d xorl %eax, %eax movl %eax, %r9d callq 0xe1b90 cmpq $-0x1, %rax jne 0xe3ca9 movq -0x10(%rbp), %rax movl $0xffffffff, 0xe4(%rax) # imm = 0xFFFFFFFF movq -0x10(%rbp), %rdi addq $0x50, %rdi callq 0xe3220 movl $0x1, -0x4(%rbp) jmp 0xe401e movq -0x10(%rbp), %rax movl $0x0, 0xe0(%rax) movq -0x48(%rbp), %rax andq $0xfff, %rax # imm = 0xFFF movq %rax, -0x30(%rbp) movq -0x20(%rbp), %rax movl $0x1000, %ecx # imm = 0x1000 subq -0x30(%rbp), %rcx addq $0x1000, %rcx # imm = 0x1000 cmpq %rcx, %rax jb 0xe3d95 movabsq $0xfffff000, %rax # imm = 0xFFFFF000 andq -0x20(%rbp), %rax subq -0x30(%rbp), %rax movq %rax, -0x28(%rbp) movq -0x10(%rbp), %rax movl 0xd4(%rax), %edx movq -0x18(%rbp), %rcx movq -0x28(%rbp), %r8 movq -0x10(%rbp), %rax movq 0xf8(%rax), %r9 leaq 0x7137a(%rip), %rdi # 0x155096 movl $0x569, %esi # imm = 0x569 callq 0xe45a0 movq %rax, -0x50(%rbp) cmpq $-0x1, %rax jne 0xe3d57 movq -0x10(%rbp), %rax movl $0xffffffff, 0xe4(%rax) # imm = 0xFFFFFFFF movq -0x10(%rbp), %rdi addq $0x50, %rdi callq 0xe3220 movl $0x1, -0x4(%rbp) jmp 0xe401e movq -0x50(%rbp), %rcx movq -0x20(%rbp), %rax subq %rcx, %rax movq %rax, -0x20(%rbp) movq -0x50(%rbp), %rax addq -0x18(%rbp), %rax movq %rax, -0x18(%rbp) movq -0x50(%rbp), %rax addq -0x48(%rbp), %rax movq %rax, -0x48(%rbp) movq -0x50(%rbp), %rax cmpq -0x28(%rbp), %rax je 0xe3d8d jmp 0xe3efc movq $0x0, -0x30(%rbp) movq -0x10(%rbp), %rax movq 0xf0(%rax), %rax subq -0x30(%rbp), %rax movq %rax, -0x40(%rbp) movq -0x40(%rbp), %rax movq -0x10(%rbp), %rcx movq 0x8(%rcx), %rcx subq -0x48(%rbp), %rcx cmpq %rcx, %rax jbe 0xe3dcd movq -0x10(%rbp), %rax movq 0x8(%rax), %rax subq -0x48(%rbp), %rax movq %rax, -0x40(%rbp) cmpq $0x0, -0x40(%rbp) jne 0xe3ded cmpq $0x0, -0x20(%rbp) je 0xe3de0 jmp 0xe3efc movq $0x0, -0x28(%rbp) jmp 0xe3e9b movq -0x10(%rbp), %rax movl 0xd4(%rax), %edx movq -0x10(%rbp), %rax movq 0x20(%rax), %rcx movq -0x40(%rbp), %r8 movq -0x10(%rbp), %rax movq 0xf8(%rax), %r9 leaq 0x71281(%rip), %rdi # 0x155096 movl $0x589, %esi # imm = 0x589 callq 0xe45a0 movq %rax, -0x28(%rbp) cmpq $-0x1, -0x28(%rbp) jne 0xe3e51 movq -0x10(%rbp), %rax movl $0xffffffff, 0xe4(%rax) # imm = 0xFFFFFFFF movq -0x10(%rbp), %rdi addq $0x50, %rdi callq 0xe3220 movl $0x1, -0x4(%rbp) jmp 0xe401e movq -0x28(%rbp), %rax cmpq -0x20(%rbp), %rax jae 0xe3e99 movq -0x18(%rbp), %rdi movq -0x10(%rbp), %rax movq 0x20(%rax), %rsi movq -0x28(%rbp), %rdx callq 0x29090 movq -0x28(%rbp), %rcx movq -0x20(%rbp), %rax subq %rcx, %rax movq %rax, -0x20(%rbp) movq -0x28(%rbp), %rax addq -0x18(%rbp), %rax movq %rax, -0x18(%rbp) movq -0x28(%rbp), %rax addq -0x48(%rbp), %rax movq %rax, -0x48(%rbp) jmp 0xe3efc jmp 0xe3e9b movq -0x10(%rbp), %rdi addq $0x50, %rdi callq 0xe3220 movq -0x10(%rbp), %rax movq 0x20(%rax), %rcx addq -0x20(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x10(%rax) movq -0x10(%rbp), %rax movq 0x20(%rax), %rcx addq -0x28(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x18(%rax) movq -0x48(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, (%rax) movq -0x18(%rbp), %rdi movq -0x10(%rbp), %rax movq 0x20(%rax), %rsi movq -0x20(%rbp), %rdx callq 0x29090 movl $0x0, -0x4(%rbp) jmp 0xe401e movq -0x10(%rbp), %rax movq 0x40(%rax), %rax movq -0x10(%rbp), %rcx movq 0x38(%rcx), %rcx subq %rcx, %rax movq %rax, -0x58(%rbp) jmp 0xe3f15 movq -0x20(%rbp), %rax cmpq -0x58(%rbp), %rax jae 0xe3f29 movq -0x20(%rbp), %rax movq %rax, -0x70(%rbp) jmp 0xe3f31 movq -0x58(%rbp), %rax movq %rax, -0x70(%rbp) movq -0x70(%rbp), %rax movq %rax, -0x60(%rbp) movq -0x18(%rbp), %rdi movq -0x10(%rbp), %rax movq 0x38(%rax), %rsi movq -0x60(%rbp), %rdx callq 0x29090 movq -0x60(%rbp), %rcx movq -0x10(%rbp), %rax addq 0x38(%rax), %rcx movq %rcx, 0x38(%rax) movq -0x60(%rbp), %rcx movq -0x20(%rbp), %rax subq %rcx, %rax movq %rax, -0x20(%rbp) cmpq $0x0, -0x20(%rbp) je 0xe3f88 movq -0x38(%rbp), %rax subq -0x20(%rbp), %rax movl %eax, %ecx movq -0x10(%rbp), %rax movl %ecx, 0xe4(%rax) movq -0x10(%rbp), %rax movq 0x20(%rax), %rdi movq -0x10(%rbp), %rax movq 0x38(%rax), %rsi movq -0x58(%rbp), %rdx subq -0x60(%rbp), %rdx movq %rdx, -0x68(%rbp) callq 0x29090 movq -0x10(%rbp), %rax movq 0x20(%rax), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x10(%rax) movq -0x10(%rbp), %rax movq 0x20(%rax), %rcx addq -0x68(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x18(%rax) movq -0x10(%rbp), %rax movq 0x40(%rax), %rcx movq -0x10(%rbp), %rax movq %rcx, 0x38(%rax) movq -0x48(%rbp), %rcx addq -0x60(%rbp), %rcx movq -0x10(%rbp), %rax movq %rcx, (%rax) movq -0x58(%rbp), %rcx movq -0x10(%rbp), %rax addq 0x8(%rax), %rcx movq %rcx, 0x8(%rax) movq -0x10(%rbp), %rdi addq $0x50, %rdi callq 0xe3220 movq -0x20(%rbp), %rdx xorl %eax, %eax movl $0x1, %ecx cmpq $0x0, %rdx cmovnel %ecx, %eax movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x70, %rsp popq %rbp retq nopw (%rax,%rax)
_my_b_seq_read: push rbp mov rbp, rsp sub rsp, 70h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov rax, [rbp+var_20] mov [rbp+var_38], rax mov rdi, [rbp+var_10] add rdi, 50h ; 'P' lea rsi, aWorkspaceLlm4b_37; "/workspace/llm4binary/github2025/eloqsq"... mov edx, 54Ch call inline_mysql_mutex_lock_24 mov rax, [rbp+var_10] mov rax, [rax] mov rcx, [rbp+var_10] mov rcx, [rcx+18h] mov rdx, [rbp+var_10] mov rdx, [rdx+20h] sub rcx, rdx add rax, rcx mov [rbp+var_48], rax mov rcx, [rbp+var_10] cmp rax, [rcx+8] jb short loc_E3C55 jmp loc_E3EFC loc_E3C55: mov rax, [rbp+var_10] mov edx, [rax+0D4h] mov rcx, [rbp+var_48] lea rdi, aWorkspaceLlm4b_37; "/workspace/llm4binary/github2025/eloqsq"... mov esi, 557h xor r8d, r8d xor eax, eax mov r9d, eax call inline_mysql_file_seek_6 cmp rax, 0FFFFFFFFFFFFFFFFh jnz short loc_E3CA9 mov rax, [rbp+var_10] mov dword ptr [rax+0E4h], 0FFFFFFFFh mov rdi, [rbp+var_10] add rdi, 50h ; 'P' call inline_mysql_mutex_unlock_25 mov [rbp+var_4], 1 jmp loc_E401E loc_E3CA9: mov rax, [rbp+var_10] mov dword ptr [rax+0E0h], 0 mov rax, [rbp+var_48] and rax, 0FFFh mov [rbp+var_30], rax mov rax, [rbp+var_20] mov ecx, 1000h sub rcx, [rbp+var_30] add rcx, 1000h cmp rax, rcx jb loc_E3D95 mov rax, 0FFFFF000h and rax, [rbp+var_20] sub rax, [rbp+var_30] mov [rbp+var_28], rax mov rax, [rbp+var_10] mov edx, [rax+0D4h] mov rcx, [rbp+var_18] mov r8, [rbp+var_28] mov rax, [rbp+var_10] mov r9, [rax+0F8h] lea rdi, aWorkspaceLlm4b_37; "/workspace/llm4binary/github2025/eloqsq"... mov esi, 569h call inline_mysql_file_read_5 mov [rbp+var_50], rax cmp rax, 0FFFFFFFFFFFFFFFFh jnz short loc_E3D57 mov rax, [rbp+var_10] mov dword ptr [rax+0E4h], 0FFFFFFFFh mov rdi, [rbp+var_10] add rdi, 50h ; 'P' call inline_mysql_mutex_unlock_25 mov [rbp+var_4], 1 jmp loc_E401E loc_E3D57: mov rcx, [rbp+var_50] mov rax, [rbp+var_20] sub rax, rcx mov [rbp+var_20], rax mov rax, [rbp+var_50] add rax, [rbp+var_18] mov [rbp+var_18], rax mov rax, [rbp+var_50] add rax, [rbp+var_48] mov [rbp+var_48], rax mov rax, [rbp+var_50] cmp rax, [rbp+var_28] jz short loc_E3D8D jmp loc_E3EFC loc_E3D8D: mov [rbp+var_30], 0 loc_E3D95: mov rax, [rbp+var_10] mov rax, [rax+0F0h] sub rax, [rbp+var_30] mov [rbp+var_40], rax mov rax, [rbp+var_40] mov rcx, [rbp+var_10] mov rcx, [rcx+8] sub rcx, [rbp+var_48] cmp rax, rcx jbe short loc_E3DCD mov rax, [rbp+var_10] mov rax, [rax+8] sub rax, [rbp+var_48] mov [rbp+var_40], rax loc_E3DCD: cmp [rbp+var_40], 0 jnz short loc_E3DED cmp [rbp+var_20], 0 jz short loc_E3DE0 jmp loc_E3EFC loc_E3DE0: mov [rbp+var_28], 0 jmp loc_E3E9B loc_E3DED: mov rax, [rbp+var_10] mov edx, [rax+0D4h] mov rax, [rbp+var_10] mov rcx, [rax+20h] mov r8, [rbp+var_40] mov rax, [rbp+var_10] mov r9, [rax+0F8h] lea rdi, aWorkspaceLlm4b_37; "/workspace/llm4binary/github2025/eloqsq"... mov esi, 589h call inline_mysql_file_read_5 mov [rbp+var_28], rax cmp [rbp+var_28], 0FFFFFFFFFFFFFFFFh jnz short loc_E3E51 mov rax, [rbp+var_10] mov dword ptr [rax+0E4h], 0FFFFFFFFh mov rdi, [rbp+var_10] add rdi, 50h ; 'P' call inline_mysql_mutex_unlock_25 mov [rbp+var_4], 1 jmp loc_E401E loc_E3E51: mov rax, [rbp+var_28] cmp rax, [rbp+var_20] jnb short loc_E3E99 mov rdi, [rbp+var_18] mov rax, [rbp+var_10] mov rsi, [rax+20h] mov rdx, [rbp+var_28] call _memcpy mov rcx, [rbp+var_28] mov rax, [rbp+var_20] sub rax, rcx mov [rbp+var_20], rax mov rax, [rbp+var_28] add rax, [rbp+var_18] mov [rbp+var_18], rax mov rax, [rbp+var_28] add rax, [rbp+var_48] mov [rbp+var_48], rax jmp short loc_E3EFC loc_E3E99: jmp short $+2 loc_E3E9B: mov rdi, [rbp+var_10] add rdi, 50h ; 'P' call inline_mysql_mutex_unlock_25 mov rax, [rbp+var_10] mov rcx, [rax+20h] add rcx, [rbp+var_20] mov rax, [rbp+var_10] mov [rax+10h], rcx mov rax, [rbp+var_10] mov rcx, [rax+20h] add rcx, [rbp+var_28] mov rax, [rbp+var_10] mov [rax+18h], rcx mov rcx, [rbp+var_48] mov rax, [rbp+var_10] mov [rax], rcx mov rdi, [rbp+var_18] mov rax, [rbp+var_10] mov rsi, [rax+20h] mov rdx, [rbp+var_20] call _memcpy mov [rbp+var_4], 0 jmp loc_E401E loc_E3EFC: mov rax, [rbp+var_10] mov rax, [rax+40h] mov rcx, [rbp+var_10] mov rcx, [rcx+38h] sub rax, rcx mov [rbp+var_58], rax jmp short $+2 loc_E3F15: mov rax, [rbp+var_20] cmp rax, [rbp+var_58] jnb short loc_E3F29 mov rax, [rbp+var_20] mov [rbp+var_70], rax jmp short loc_E3F31 loc_E3F29: mov rax, [rbp+var_58] mov [rbp+var_70], rax loc_E3F31: mov rax, [rbp+var_70] mov [rbp+var_60], rax mov rdi, [rbp+var_18] mov rax, [rbp+var_10] mov rsi, [rax+38h] mov rdx, [rbp+var_60] call _memcpy mov rcx, [rbp+var_60] mov rax, [rbp+var_10] add rcx, [rax+38h] mov [rax+38h], rcx mov rcx, [rbp+var_60] mov rax, [rbp+var_20] sub rax, rcx mov [rbp+var_20], rax cmp [rbp+var_20], 0 jz short loc_E3F88 mov rax, [rbp+var_38] sub rax, [rbp+var_20] mov ecx, eax mov rax, [rbp+var_10] mov [rax+0E4h], ecx loc_E3F88: mov rax, [rbp+var_10] mov rdi, [rax+20h] mov rax, [rbp+var_10] mov rsi, [rax+38h] mov rdx, [rbp+var_58] sub rdx, [rbp+var_60] mov [rbp+var_68], rdx call _memcpy mov rax, [rbp+var_10] mov rcx, [rax+20h] mov rax, [rbp+var_10] mov [rax+10h], rcx mov rax, [rbp+var_10] mov rcx, [rax+20h] add rcx, [rbp+var_68] mov rax, [rbp+var_10] mov [rax+18h], rcx mov rax, [rbp+var_10] mov rcx, [rax+40h] mov rax, [rbp+var_10] mov [rax+38h], rcx mov rcx, [rbp+var_48] add rcx, [rbp+var_60] mov rax, [rbp+var_10] mov [rax], rcx mov rcx, [rbp+var_58] mov rax, [rbp+var_10] add rcx, [rax+8] mov [rax+8], rcx mov rdi, [rbp+var_10] add rdi, 50h ; 'P' call inline_mysql_mutex_unlock_25 mov rdx, [rbp+var_20] xor eax, eax mov ecx, 1 cmp rdx, 0 cmovnz eax, ecx mov [rbp+var_4], eax loc_E401E: mov eax, [rbp+var_4] add rsp, 70h pop rbp retn
_BOOL8 my_b_seq_read(long long a1, long long a2, unsigned long long a3) { unsigned long long v4; // [rsp+0h] [rbp-70h] unsigned long long v5; // [rsp+18h] [rbp-58h] long long v6; // [rsp+20h] [rbp-50h] unsigned long long v7; // [rsp+28h] [rbp-48h] unsigned long long v8; // [rsp+30h] [rbp-40h] int v9; // [rsp+38h] [rbp-38h] unsigned long long v10; // [rsp+40h] [rbp-30h] unsigned long long v11; // [rsp+48h] [rbp-28h] unsigned long long v12; // [rsp+48h] [rbp-28h] unsigned long long v13; // [rsp+50h] [rbp-20h] unsigned long long v14; // [rsp+50h] [rbp-20h] long long v15; // [rsp+58h] [rbp-18h] v15 = a2; v13 = a3; v9 = a3; inline_mysql_mutex_lock_24(a1 + 80, (long long)"/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c", 0x54Cu); v7 = *(_QWORD *)(a1 + 24) - *(_QWORD *)(a1 + 32) + *(_QWORD *)a1; if ( v7 >= *(_QWORD *)(a1 + 8) ) goto LABEL_18; if ( inline_mysql_file_seek_6( (long long)"/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c", 0x557u, *(_DWORD *)(a1 + 212), v7, 0, 0LL) == -1 ) goto LABEL_14; *(_DWORD *)(a1 + 224) = 0; v10 = v7 & 0xFFF; if ( v13 >= 4096 - v10 + 4096 ) { v11 = ((unsigned int)v13 & 0xFFFFF000) - v10; v6 = inline_mysql_file_read_5( "/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c", 1385LL, *(unsigned int *)(a1 + 212), a2, v11, *(_QWORD *)(a1 + 248)); if ( v6 == -1 ) goto LABEL_14; v13 -= v6; v15 = a2 + v6; v7 += v6; if ( v6 != v11 ) goto LABEL_18; v10 = 0LL; } v8 = *(_QWORD *)(a1 + 240) - v10; if ( v8 > *(_QWORD *)(a1 + 8) - v7 ) v8 = *(_QWORD *)(a1 + 8) - v7; if ( v8 ) { v12 = inline_mysql_file_read_5( "/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c", 1417LL, *(unsigned int *)(a1 + 212), *(_QWORD *)(a1 + 32), v8, *(_QWORD *)(a1 + 248)); if ( v12 == -1LL ) { LABEL_14: *(_DWORD *)(a1 + 228) = -1; inline_mysql_mutex_unlock_25(a1 + 80); return 1; } if ( v12 >= v13 ) { LABEL_17: inline_mysql_mutex_unlock_25(a1 + 80); *(_QWORD *)(a1 + 16) = v13 + *(_QWORD *)(a1 + 32); *(_QWORD *)(a1 + 24) = v12 + *(_QWORD *)(a1 + 32); *(_QWORD *)a1 = v7; memcpy(v15, *(_QWORD *)(a1 + 32), v13); return 0; } memcpy(v15, *(_QWORD *)(a1 + 32), v12); v13 -= v12; v15 += v12; v7 += v12; } else if ( !v13 ) { v12 = 0LL; goto LABEL_17; } LABEL_18: v5 = *(_QWORD *)(a1 + 64) - *(_QWORD *)(a1 + 56); if ( v13 >= v5 ) v4 = *(_QWORD *)(a1 + 64) - *(_QWORD *)(a1 + 56); else v4 = v13; memcpy(v15, *(_QWORD *)(a1 + 56), v4); *(_QWORD *)(a1 + 56) += v4; v14 = v13 - v4; if ( v14 ) *(_DWORD *)(a1 + 228) = v9 - v14; memcpy(*(_QWORD *)(a1 + 32), *(_QWORD *)(a1 + 56), v5 - v4); *(_QWORD *)(a1 + 16) = *(_QWORD *)(a1 + 32); *(_QWORD *)(a1 + 24) = v5 - v4 + *(_QWORD *)(a1 + 32); *(_QWORD *)(a1 + 56) = *(_QWORD *)(a1 + 64); *(_QWORD *)a1 = v4 + v7; *(_QWORD *)(a1 + 8) += v5; inline_mysql_mutex_unlock_25(a1 + 80); return v14 != 0; }
_my_b_seq_read: PUSH RBP MOV RBP,RSP SUB RSP,0x70 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x38],RAX MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x50 LEA RSI,[0x255096] MOV EDX,0x54c CALL 0x001e30f0 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV RCX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RCX + 0x18] MOV RDX,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RDX + 0x20] SUB RCX,RDX ADD RAX,RCX MOV qword ptr [RBP + -0x48],RAX MOV RCX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RCX + 0x8] JC 0x001e3c55 JMP 0x001e3efc LAB_001e3c55: MOV RAX,qword ptr [RBP + -0x10] MOV EDX,dword ptr [RAX + 0xd4] MOV RCX,qword ptr [RBP + -0x48] LEA RDI,[0x255096] MOV ESI,0x557 XOR R8D,R8D XOR EAX,EAX MOV R9D,EAX CALL 0x001e1b90 CMP RAX,-0x1 JNZ 0x001e3ca9 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0xe4],0xffffffff MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x50 CALL 0x001e3220 MOV dword ptr [RBP + -0x4],0x1 JMP 0x001e401e LAB_001e3ca9: MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0xe0],0x0 MOV RAX,qword ptr [RBP + -0x48] AND RAX,0xfff MOV qword ptr [RBP + -0x30],RAX MOV RAX,qword ptr [RBP + -0x20] MOV ECX,0x1000 SUB RCX,qword ptr [RBP + -0x30] ADD RCX,0x1000 CMP RAX,RCX JC 0x001e3d95 MOV RAX,0xfffff000 AND RAX,qword ptr [RBP + -0x20] SUB RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x28],RAX MOV RAX,qword ptr [RBP + -0x10] MOV EDX,dword ptr [RAX + 0xd4] MOV RCX,qword ptr [RBP + -0x18] MOV R8,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x10] MOV R9,qword ptr [RAX + 0xf8] LEA RDI,[0x255096] MOV ESI,0x569 CALL 0x001e45a0 MOV qword ptr [RBP + -0x50],RAX CMP RAX,-0x1 JNZ 0x001e3d57 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0xe4],0xffffffff MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x50 CALL 0x001e3220 MOV dword ptr [RBP + -0x4],0x1 JMP 0x001e401e LAB_001e3d57: MOV RCX,qword ptr [RBP + -0x50] MOV RAX,qword ptr [RBP + -0x20] SUB RAX,RCX MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x50] ADD RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x50] ADD RAX,qword ptr [RBP + -0x48] MOV qword ptr [RBP + -0x48],RAX MOV RAX,qword ptr [RBP + -0x50] CMP RAX,qword ptr [RBP + -0x28] JZ 0x001e3d8d JMP 0x001e3efc LAB_001e3d8d: MOV qword ptr [RBP + -0x30],0x0 LAB_001e3d95: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0xf0] SUB RAX,qword ptr [RBP + -0x30] MOV qword ptr [RBP + -0x40],RAX MOV RAX,qword ptr [RBP + -0x40] MOV RCX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RCX + 0x8] SUB RCX,qword ptr [RBP + -0x48] CMP RAX,RCX JBE 0x001e3dcd MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x8] SUB RAX,qword ptr [RBP + -0x48] MOV qword ptr [RBP + -0x40],RAX LAB_001e3dcd: CMP qword ptr [RBP + -0x40],0x0 JNZ 0x001e3ded CMP qword ptr [RBP + -0x20],0x0 JZ 0x001e3de0 JMP 0x001e3efc LAB_001e3de0: MOV qword ptr [RBP + -0x28],0x0 JMP 0x001e3e9b LAB_001e3ded: MOV RAX,qword ptr [RBP + -0x10] MOV EDX,dword ptr [RAX + 0xd4] MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0x20] MOV R8,qword ptr [RBP + -0x40] MOV RAX,qword ptr [RBP + -0x10] MOV R9,qword ptr [RAX + 0xf8] LEA RDI,[0x255096] MOV ESI,0x589 CALL 0x001e45a0 MOV qword ptr [RBP + -0x28],RAX CMP qword ptr [RBP + -0x28],-0x1 JNZ 0x001e3e51 MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0xe4],0xffffffff MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x50 CALL 0x001e3220 MOV dword ptr [RBP + -0x4],0x1 JMP 0x001e401e LAB_001e3e51: MOV RAX,qword ptr [RBP + -0x28] CMP RAX,qword ptr [RBP + -0x20] JNC 0x001e3e99 MOV RDI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RAX + 0x20] MOV RDX,qword ptr [RBP + -0x28] CALL 0x00129090 MOV RCX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x20] SUB RAX,RCX MOV qword ptr [RBP + -0x20],RAX MOV RAX,qword ptr [RBP + -0x28] ADD RAX,qword ptr [RBP + -0x18] MOV qword ptr [RBP + -0x18],RAX MOV RAX,qword ptr [RBP + -0x28] ADD RAX,qword ptr [RBP + -0x48] MOV qword ptr [RBP + -0x48],RAX JMP 0x001e3efc LAB_001e3e99: JMP 0x001e3e9b LAB_001e3e9b: MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x50 CALL 0x001e3220 MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0x20] ADD RCX,qword ptr [RBP + -0x20] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x10],RCX MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0x20] ADD RCX,qword ptr [RBP + -0x28] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x18],RCX MOV RCX,qword ptr [RBP + -0x48] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX],RCX MOV RDI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RAX + 0x20] MOV RDX,qword ptr [RBP + -0x20] CALL 0x00129090 MOV dword ptr [RBP + -0x4],0x0 JMP 0x001e401e LAB_001e3efc: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x40] MOV RCX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RCX + 0x38] SUB RAX,RCX MOV qword ptr [RBP + -0x58],RAX JMP 0x001e3f15 LAB_001e3f15: MOV RAX,qword ptr [RBP + -0x20] CMP RAX,qword ptr [RBP + -0x58] JNC 0x001e3f29 MOV RAX,qword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x70],RAX JMP 0x001e3f31 LAB_001e3f29: MOV RAX,qword ptr [RBP + -0x58] MOV qword ptr [RBP + -0x70],RAX LAB_001e3f31: MOV RAX,qword ptr [RBP + -0x70] MOV qword ptr [RBP + -0x60],RAX MOV RDI,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RAX + 0x38] MOV RDX,qword ptr [RBP + -0x60] CALL 0x00129090 MOV RCX,qword ptr [RBP + -0x60] MOV RAX,qword ptr [RBP + -0x10] ADD RCX,qword ptr [RAX + 0x38] MOV qword ptr [RAX + 0x38],RCX MOV RCX,qword ptr [RBP + -0x60] MOV RAX,qword ptr [RBP + -0x20] SUB RAX,RCX MOV qword ptr [RBP + -0x20],RAX CMP qword ptr [RBP + -0x20],0x0 JZ 0x001e3f88 MOV RAX,qword ptr [RBP + -0x38] SUB RAX,qword ptr [RBP + -0x20] MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x10] MOV dword ptr [RAX + 0xe4],ECX LAB_001e3f88: MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x20] MOV RAX,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RAX + 0x38] MOV RDX,qword ptr [RBP + -0x58] SUB RDX,qword ptr [RBP + -0x60] MOV qword ptr [RBP + -0x68],RDX CALL 0x00129090 MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0x20] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x10],RCX MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0x20] ADD RCX,qword ptr [RBP + -0x68] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x18],RCX MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0x40] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX + 0x38],RCX MOV RCX,qword ptr [RBP + -0x48] ADD RCX,qword ptr [RBP + -0x60] MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX],RCX MOV RCX,qword ptr [RBP + -0x58] MOV RAX,qword ptr [RBP + -0x10] ADD RCX,qword ptr [RAX + 0x8] MOV qword ptr [RAX + 0x8],RCX MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x50 CALL 0x001e3220 MOV RDX,qword ptr [RBP + -0x20] XOR EAX,EAX MOV ECX,0x1 CMP RDX,0x0 CMOVNZ EAX,ECX MOV dword ptr [RBP + -0x4],EAX LAB_001e401e: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x70 POP RBP RET
bool _my_b_seq_read(ulong *param_1,void *param_2,ulong param_3) { long lVar1; ulong uVar2; long lVar3; size_t local_78; ulong local_50; ulong local_48; ulong local_38; ulong local_30; ulong local_28; void *local_20; inline_mysql_mutex_lock (param_1 + 10,"/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",0x54c); local_50 = *param_1 + (param_1[3] - param_1[4]); local_28 = param_3; local_20 = param_2; if (local_50 < param_1[1]) { lVar3 = inline_mysql_file_seek ("/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",0x557, *(int4 *)((long)param_1 + 0xd4),local_50,0,0); if (lVar3 == -1) { *(int4 *)((long)param_1 + 0xe4) = 0xffffffff; inline_mysql_mutex_unlock(param_1 + 10); return true; } *(int4 *)(param_1 + 0x1c) = 0; local_38 = local_50 & 0xfff; if (0x2000 - local_38 <= param_3) { lVar3 = (param_3 & 0xfffff000) - local_38; lVar1 = inline_mysql_file_read ("/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",0x569, *(int4 *)((long)param_1 + 0xd4),param_2,lVar3,param_1[0x1f]); if (lVar1 == -1) { *(int4 *)((long)param_1 + 0xe4) = 0xffffffff; inline_mysql_mutex_unlock(param_1 + 10); return true; } local_28 = param_3 - lVar1; local_20 = (void *)(lVar1 + (long)param_2); local_50 = lVar1 + local_50; if (lVar1 != lVar3) goto LAB_001e3efc; local_38 = 0; } local_48 = param_1[0x1e] - local_38; if (param_1[1] - local_50 < local_48) { local_48 = param_1[1] - local_50; } if (local_48 == 0) { if (local_28 == 0) { local_30 = 0; LAB_001e3e9b: inline_mysql_mutex_unlock(param_1 + 10); param_1[2] = param_1[4] + local_28; param_1[3] = param_1[4] + local_30; *param_1 = local_50; memcpy(local_20,(void *)param_1[4],local_28); return false; } } else { local_30 = inline_mysql_file_read ("/workspace/llm4binary/github2025/eloqsql/mysys/mf_iocache.c",0x589, *(int4 *)((long)param_1 + 0xd4),param_1[4],local_48,param_1[0x1f]) ; if (local_30 == 0xffffffffffffffff) { *(int4 *)((long)param_1 + 0xe4) = 0xffffffff; inline_mysql_mutex_unlock(param_1 + 10); return true; } if (local_28 <= local_30) goto LAB_001e3e9b; memcpy(local_20,(void *)param_1[4],local_30); local_28 = local_28 - local_30; local_20 = (void *)(local_30 + (long)local_20); local_50 = local_30 + local_50; } } LAB_001e3efc: uVar2 = param_1[8] - param_1[7]; local_78 = uVar2; if (local_28 < uVar2) { local_78 = local_28; } memcpy(local_20,(void *)param_1[7],local_78); param_1[7] = local_78 + param_1[7]; lVar3 = local_28 - local_78; if (lVar3 != 0) { *(int *)((long)param_1 + 0xe4) = (int)param_3 - (int)lVar3; } memcpy((void *)param_1[4],(void *)param_1[7],uVar2 - local_78); param_1[2] = param_1[4]; param_1[3] = param_1[4] + (uVar2 - local_78); param_1[7] = param_1[8]; *param_1 = local_50 + local_78; param_1[1] = uVar2 + param_1[1]; inline_mysql_mutex_unlock(param_1 + 10); return lVar3 != 0; }
3,555
nlohmann::json_abi_v3_11_3::detail::type_error nlohmann::json_abi_v3_11_3::detail::type_error::create<std::nullptr_t, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::nullptr_t)
msxemulator/build_O0/_deps/picotool-src/lib/nlohmann_json/single_include/nlohmann/json.hpp
static type_error create(int id_, const std::string& what_arg, BasicJsonContext context) { const std::string w = concat(exception::name("type_error", id_), exception::diagnostics(context), what_arg); return {id_, w.c_str()}; }
O0
cpp
nlohmann::json_abi_v3_11_3::detail::type_error nlohmann::json_abi_v3_11_3::detail::type_error::create<std::nullptr_t, 0>(int, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, std::nullptr_t): subq $0xd8, %rsp movq %rdi, 0x8(%rsp) movq %rdi, %rax movq %rax, 0x10(%rsp) movq %rdi, 0xd0(%rsp) movl %esi, 0xcc(%rsp) movq %rdx, 0xc0(%rsp) movq %rcx, 0xb8(%rsp) leaq 0x57(%rsp), %rdi movq %rdi, 0x18(%rsp) callq 0xf9f0 movq 0x18(%rsp), %rdx leaq 0x89aa4(%rip), %rsi # 0x1719e2 leaq 0x58(%rsp), %rdi callq 0xf7c0 jmp 0xe7f4a movl 0xcc(%rsp), %edx leaq 0x78(%rsp), %rdi leaq 0x58(%rsp), %rsi callq 0x9af00 jmp 0xe7f62 xorl %eax, %eax movl %eax, %esi leaq 0x20(%rsp), %rdi callq 0xd1110 jmp 0xe7f72 movq 0xc0(%rsp), %rcx leaq 0x98(%rsp), %rdi leaq 0x78(%rsp), %rsi leaq 0x20(%rsp), %rdx callq 0x9ae40 jmp 0xe7f93 leaq 0x20(%rsp), %rdi callq 0xfb10 leaq 0x78(%rsp), %rdi callq 0xfb10 leaq 0x58(%rsp), %rdi callq 0xfb10 leaq 0x57(%rsp), %rdi callq 0xf630 movl 0xcc(%rsp), %eax movl %eax, 0x4(%rsp) leaq 0x98(%rsp), %rdi callq 0xf280 movq 0x8(%rsp), %rdi movl 0x4(%rsp), %esi movq %rax, %rdx callq 0x9b020 jmp 0xe7fe6 leaq 0x98(%rsp), %rdi callq 0xfb10 movq 0x10(%rsp), %rax addq $0xd8, %rsp retq movq %rax, %rcx movl %edx, %eax movq %rcx, 0x48(%rsp) movl %eax, 0x44(%rsp) jmp 0xe805c movq %rax, %rcx movl %edx, %eax movq %rcx, 0x48(%rsp) movl %eax, 0x44(%rsp) jmp 0xe8052 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x48(%rsp) movl %eax, 0x44(%rsp) jmp 0xe8048 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x48(%rsp) movl %eax, 0x44(%rsp) leaq 0x20(%rsp), %rdi callq 0xfb10 leaq 0x78(%rsp), %rdi callq 0xfb10 leaq 0x58(%rsp), %rdi callq 0xfb10 leaq 0x57(%rsp), %rdi callq 0xf630 jmp 0xe8083 movq %rax, %rcx movl %edx, %eax movq %rcx, 0x48(%rsp) movl %eax, 0x44(%rsp) leaq 0x98(%rsp), %rdi callq 0xfb10 movq 0x48(%rsp), %rdi callq 0xf9e0 nopl (%rax)
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_: sub rsp, 0D8h mov [rsp+0D8h+var_D0], rdi; int mov rax, rdi mov qword ptr [rsp+0D8h+var_C8], rax; int mov [rsp+0D8h+var_8], rdi mov [rsp+0D8h+var_C], esi mov qword ptr [rsp+0D8h+var_18], rdx mov [rsp+0D8h+var_20], rcx lea rdi, [rsp+0D8h+var_81] mov qword ptr [rsp+0D8h+var_C0], rdi; int call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void) mov rdx, qword ptr [rsp+0D8h+var_C0] lea rsi, aTypeError; "type_error" lea rdi, [rsp+0D8h+var_81+1] call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1EPKcRKS3_; std::string::basic_string(char const*,std::allocator<char> const&) jmp short $+2 loc_E7F4A: mov edx, [rsp+0D8h+var_C] lea rdi, [rsp+0D8h+var_60]; int lea rsi, [rsp+0D8h+var_81+1] call _ZN8nlohmann16json_abi_v3_11_36detail9exception4nameERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEi; nlohmann::json_abi_v3_11_3::detail::exception::name(std::string const&,int) jmp short $+2 loc_E7F62: xor eax, eax mov esi, eax lea rdi, [rsp+0D8h+var_B8] call _ZN8nlohmann16json_abi_v3_11_36detail9exception11diagnosticsB5cxx11EDn; nlohmann::json_abi_v3_11_3::detail::exception::diagnostics(decltype(nullptr)) jmp short $+2 loc_E7F72: mov rcx, qword ptr [rsp+0D8h+var_18]; int lea rdi, [rsp+0D8h+var_40]; int lea rsi, [rsp+0D8h+var_60]; int lea rdx, [rsp+0D8h+var_B8]; int call _ZN8nlohmann16json_abi_v3_11_36detail6concatINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEJS8_S8_RKS8_EEET_DpOT0_; nlohmann::json_abi_v3_11_3::detail::concat<std::string,std::string,std::string,std::string const&>(std::string,std::string,std::string const&) jmp short $+2 loc_E7F93: lea rdi, [rsp+0D8h+var_B8]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() lea rdi, [rsp+0D8h+var_60]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() lea rdi, [rsp+0D8h+var_81+1]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() lea rdi, [rsp+0D8h+var_81] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() mov eax, [rsp+0D8h+var_C] mov [rsp+0D8h+var_D4], eax lea rdi, [rsp+0D8h+var_40] call __ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv; std::string::c_str(void) mov rdi, [rsp+0D8h+var_D0]; this mov esi, [rsp+0D8h+var_D4]; int mov rdx, rax; char * call _ZN8nlohmann16json_abi_v3_11_36detail10type_errorC2EiPKc; nlohmann::json_abi_v3_11_3::detail::type_error::type_error(int,char const*) jmp short $+2 loc_E7FE6: lea rdi, [rsp+0D8h+var_40]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() mov rax, qword ptr [rsp+0D8h+var_C8] add rsp, 0D8h retn mov rcx, rax mov eax, edx mov [rsp+arg_40], rcx mov [rsp+arg_3C], eax jmp short loc_E805C mov rcx, rax mov eax, edx mov [rsp+arg_40], rcx mov [rsp+arg_3C], eax jmp short loc_E8052 mov rcx, rax mov eax, edx mov [rsp+arg_40], rcx mov [rsp+arg_3C], eax jmp short loc_E8048 mov rcx, rax mov eax, edx mov [rsp+arg_40], rcx mov [rsp+arg_3C], eax lea rdi, [rsp+arg_18]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_E8048: lea rdi, [rsp+arg_70]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_E8052: lea rdi, [rsp+arg_50]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_E805C: lea rdi, [rsp+arg_4F] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() jmp short loc_E8083 mov rcx, rax mov eax, edx mov [rsp+arg_40], rcx mov [rsp+arg_3C], eax lea rdi, [rsp+arg_90]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_E8083: mov rdi, [rsp+arg_40] call __Unwind_Resume
nlohmann::json_abi_v3_11_3::detail::type_error * ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_( nlohmann::json_abi_v3_11_3::detail::type_error *a1, long long a2, long long a3, long long a4) { const char *v4; // rax int v6; // [rsp+4h] [rbp-D4h] int v7[13]; // [rsp+20h] [rbp-B8h] BYREF int v8[8]; // [rsp+57h] [rbp-81h] BYREF int v9[8]; // [rsp+78h] [rbp-60h] BYREF int v10[8]; // [rsp+98h] [rbp-40h] BYREF long long v11; // [rsp+B8h] [rbp-20h] int v12[2]; // [rsp+C0h] [rbp-18h] int v13; // [rsp+CCh] [rbp-Ch] nlohmann::json_abi_v3_11_3::detail::type_error *v14; // [rsp+D0h] [rbp-8h] v14 = a1; v13 = a2; *(_QWORD *)v12 = a3; v11 = a4; std::allocator<char>::allocator(v8, a2); std::string::basic_string((char *)v8 + 1, "type_error", v8); nlohmann::json_abi_v3_11_3::detail::exception::name(v9, (long long)v8 + 1, v13); nlohmann::json_abi_v3_11_3::detail::exception::diagnostics[abi:cxx11]((long long)v7, 0LL); nlohmann::json_abi_v3_11_3::detail::concat<std::string,std::string,std::string,std::string const&>( (long long)v10, (long long)v9, (long long)v7, *(long long *)v12); std::string::~string(v7); std::string::~string(v9); std::string::~string((char *)v8 + 1); std::allocator<char>::~allocator(v8); v6 = v13; v4 = (const char *)std::string::c_str(v10); nlohmann::json_abi_v3_11_3::detail::type_error::type_error(a1, v6, v4); std::string::~string(v10); return a1; }
_ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_: SUB RSP,0xd8 MOV qword ptr [RSP + 0x8],RDI MOV RAX,RDI MOV qword ptr [RSP + 0x10],RAX MOV qword ptr [RSP + 0xd0],RDI MOV dword ptr [RSP + 0xcc],ESI MOV qword ptr [RSP + 0xc0],RDX MOV qword ptr [RSP + 0xb8],RCX LEA RDI,[RSP + 0x57] MOV qword ptr [RSP + 0x18],RDI CALL 0x0010f9f0 MOV RDX,qword ptr [RSP + 0x18] LAB_001e7f37: LEA RSI,[0x2719e2] LEA RDI,[RSP + 0x58] CALL 0x0010f7c0 JMP 0x001e7f4a LAB_001e7f4a: MOV EDX,dword ptr [RSP + 0xcc] LAB_001e7f51: LEA RDI,[RSP + 0x78] LEA RSI,[RSP + 0x58] CALL 0x0019af00 JMP 0x001e7f62 LAB_001e7f62: XOR EAX,EAX MOV ESI,EAX LEA RDI,[RSP + 0x20] CALL 0x001d1110 JMP 0x001e7f72 LAB_001e7f72: MOV RCX,qword ptr [RSP + 0xc0] LAB_001e7f7a: LEA RDI,[RSP + 0x98] LEA RSI,[RSP + 0x78] LEA RDX,[RSP + 0x20] CALL 0x0019ae40 JMP 0x001e7f93 LAB_001e7f93: LEA RDI,[RSP + 0x20] CALL 0x0010fb10 LEA RDI,[RSP + 0x78] CALL 0x0010fb10 LEA RDI,[RSP + 0x58] CALL 0x0010fb10 LEA RDI,[RSP + 0x57] CALL 0x0010f630 MOV EAX,dword ptr [RSP + 0xcc] MOV dword ptr [RSP + 0x4],EAX LEA RDI,[RSP + 0x98] CALL 0x0010f280 MOV RDI,qword ptr [RSP + 0x8] MOV ESI,dword ptr [RSP + 0x4] MOV RDX,RAX LAB_001e7fdf: CALL 0x0019b020 LAB_001e7fe4: JMP 0x001e7fe6 LAB_001e7fe6: LEA RDI,[RSP + 0x98] CALL 0x0010fb10 MOV RAX,qword ptr [RSP + 0x10] ADD RSP,0xd8 RET
type_error * _ZN8nlohmann16json_abi_v3_11_36detail10type_error6createIDnTnNSt9enable_ifIXsr21is_basic_json_contextIT_EE5valueEiE4typeELi0EEES2_iRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES5_ (type_error *param_1,int param_2,string *param_3,int8 param_4) { int iVar1; char *pcVar2; exception local_b8 [55]; allocator local_81; string local_80 [32]; exception local_60 [32]; detail local_40 [32]; int8 local_20; string *local_18; int local_c; type_error *local_8; local_20 = param_4; local_18 = param_3; local_c = param_2; local_8 = param_1; std::allocator<char>::allocator(); /* try { // try from 001e7f37 to 001e7f47 has its CatchHandler @ 001e8000 */ std::__cxx11::string::string(local_80,"type_error",&local_81); /* try { // try from 001e7f51 to 001e7f5f has its CatchHandler @ 001e8010 */ nlohmann::json_abi_v3_11_3::detail::exception::name(local_60,local_80,local_c); /* try { // try from 001e7f62 to 001e7f6f has its CatchHandler @ 001e8020 */ nlohmann::json_abi_v3_11_3::detail::exception::diagnostics_abi_cxx11_ (local_b8,(_func_decltype_nullptr *)0x0); /* try { // try from 001e7f7a to 001e7f90 has its CatchHandler @ 001e8030 */ nlohmann::json_abi_v3_11_3::detail:: concat<std::__cxx11::string,std::__cxx11::string,std::__cxx11::string,std::__cxx11::string_const&> (local_40,(string *)local_60,(string *)local_b8,local_18); std::__cxx11::string::~string((string *)local_b8); std::__cxx11::string::~string((string *)local_60); std::__cxx11::string::~string(local_80); std::allocator<char>::~allocator((allocator<char> *)&local_81); iVar1 = local_c; pcVar2 = (char *)std::__cxx11::string::c_str(); /* try { // try from 001e7fdf to 001e7fe3 has its CatchHandler @ 001e8068 */ nlohmann::json_abi_v3_11_3::detail::type_error::type_error(param_1,iVar1,pcVar2); std::__cxx11::string::~string((string *)local_40); return param_1; }
3,556
fini_one_value
eloqsql/mysys/my_getopt.c
static void fini_one_value(const struct my_option *option, void *variable, longlong value __attribute__ ((unused))) { DBUG_ENTER("fini_one_value"); switch ((option->var_type & GET_TYPE_MASK)) { case GET_STR_ALLOC: my_free(*((char**) variable)); *((char**) variable)= NULL; break; default: /* dummy default to avoid compiler warnings */ break; } DBUG_VOID_RETURN; }
O0
c
fini_one_value: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax movl 0x30(%rax), %eax andl $0x3f, %eax subl $0xa, %eax jne 0xb9b6e jmp 0xb9b55 movq -0x10(%rbp), %rax movq (%rax), %rdi callq 0xbe980 movq -0x10(%rbp), %rax movq $0x0, (%rax) jmp 0xb9b70 jmp 0xb9b70 jmp 0xb9b72 jmp 0xb9b74 addq $0x20, %rsp popq %rbp retq nopw (%rax,%rax)
fini_one_value: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_8] mov eax, [rax+30h] and eax, 3Fh sub eax, 0Ah jnz short loc_B9B6E jmp short $+2 loc_B9B55: mov rax, [rbp+var_10] mov rdi, [rax] call my_free mov rax, [rbp+var_10] mov qword ptr [rax], 0 jmp short loc_B9B70 loc_B9B6E: jmp short $+2 loc_B9B70: jmp short $+2 loc_B9B72: jmp short $+2 loc_B9B74: add rsp, 20h pop rbp retn
_QWORD * fini_one_value(long long a1, _QWORD *a2) { _QWORD *result; // rax result = (_QWORD *)((*(_DWORD *)(a1 + 48) & 0x3Fu) - 10); if ( (*(_DWORD *)(a1 + 48) & 0x3F) == 0xA ) { my_free(*a2); result = a2; *a2 = 0LL; } return result; }
fini_one_value: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x8] MOV EAX,dword ptr [RAX + 0x30] AND EAX,0x3f SUB EAX,0xa JNZ 0x001b9b6e JMP 0x001b9b55 LAB_001b9b55: MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX] CALL 0x001be980 MOV RAX,qword ptr [RBP + -0x10] MOV qword ptr [RAX],0x0 JMP 0x001b9b70 LAB_001b9b6e: JMP 0x001b9b70 LAB_001b9b70: JMP 0x001b9b72 LAB_001b9b72: JMP 0x001b9b74 LAB_001b9b74: ADD RSP,0x20 POP RBP RET
void fini_one_value(long param_1,int8 *param_2) { if ((*(uint *)(param_1 + 0x30) & 0x3f) == 10) { my_free(*param_2); *param_2 = 0; } return; }
3,557
print_result
eloqsql/client/mysqlcheck.c
static void print_result() { MYSQL_RES *res; MYSQL_ROW row; char prev[(NAME_LEN+9)*3+2]; char prev_alter[MAX_ALTER_STR_SIZE]; size_t length_of_db= strlen(sock->db); my_bool found_error=0, table_rebuild=0; DYNAMIC_ARRAY *array4repair= &tables4repair; DBUG_ENTER("print_result"); res = mysql_use_result(sock); prev[0] = '\0'; prev_alter[0]= 0; while ((row = mysql_fetch_row(res))) { int changed = strcmp(prev, row[0]); my_bool status = !strcmp(row[2], "status"); if (status) { /* if there was an error with the table, we have --auto-repair set, and this isn't a repair op, then add the table to the tables4repair list */ if (found_error && opt_auto_repair && what_to_do != DO_REPAIR && strcmp(row[3],"OK")) { if (table_rebuild) { if (prev_alter[0]) insert_dynamic(&alter_table_cmds, (uchar*) prev_alter); else insert_table_name(&tables4rebuild, prev, length_of_db); } else insert_table_name(array4repair, prev, length_of_db); } array4repair= &tables4repair; found_error=0; table_rebuild=0; prev_alter[0]= 0; if (opt_silent) continue; } if (status && changed) printf("%-50s %s", row[0], row[3]); else if (!status && changed) { /* If the error message includes REPAIR TABLE, we assume it means we have to run upgrade on it. In this case we write a nicer message than "Please do "REPAIR TABLE""... */ if (!strcmp(row[2],"error") && strstr(row[3],"REPAIR ")) { printf("%-50s %s", row[0], "Needs upgrade"); array4repair= strstr(row[3], "VIEW") ? &views4repair : &tables4repair; } else printf("%s\n%-9s: %s", row[0], row[2], row[3]); if (opt_auto_repair && strcmp(row[2],"note")) { found_error=1; if (opt_auto_repair && strstr(row[3], "ALTER TABLE") != NULL) table_rebuild=1; } } else printf("%-9s: %s", row[2], row[3]); strmov(prev, row[0]); putchar('\n'); } /* add the last table to be repaired to the list */ if (found_error && opt_auto_repair && what_to_do != DO_REPAIR) { if (table_rebuild) { if (prev_alter[0]) insert_dynamic(&alter_table_cmds, prev_alter); else insert_table_name(&tables4rebuild, prev, length_of_db); } else insert_table_name(array4repair, prev, length_of_db); } mysql_free_result(res); DBUG_VOID_RETURN; }
O0
c
print_result: pushq %rbp movq %rsp, %rbp subq $0x20360, %rsp # imm = 0x20360 movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq 0x3b21c1(%rip), %rax # 0x3eb780 movq 0x2e8(%rax), %rdi callq 0x363e0 movq %rax, -0x20348(%rbp) movb $0x0, -0x20349(%rbp) movb $0x0, -0x2034a(%rbp) leaq 0x3b1b51(%rip), %rax # 0x3eb138 movq %rax, -0x20358(%rbp) movq 0x3b218b(%rip), %rdi # 0x3eb780 callq 0x40fc0 movq %rax, -0x20338(%rbp) movb $0x0, -0x330(%rbp) movb $0x0, -0x20330(%rbp) movq -0x20338(%rbp), %rdi callq 0x43ae0 movq %rax, -0x20340(%rbp) cmpq $0x0, %rax je 0x3991a leaq -0x330(%rbp), %rdi movq -0x20340(%rbp), %rax movq (%rax), %rsi callq 0x36830 movl %eax, -0x2035c(%rbp) movq -0x20340(%rbp), %rax movq 0x10(%rax), %rdi leaq 0x91574(%rip), %rsi # 0xcabce callq 0x36830 cmpl $0x0, %eax setne %al xorb $-0x1, %al andb $0x1, %al movzbl %al, %eax movb %al, -0x2035d(%rbp) cmpb $0x0, -0x2035d(%rbp) je 0x39756 movsbl -0x20349(%rbp), %eax cmpl $0x0, %eax je 0x39723 movsbl 0x3b1a9a(%rip), %eax # 0x3eb130 cmpl $0x0, %eax je 0x39723 cmpl $0x2, 0x3b1a62(%rip) # 0x3eb108 je 0x39723 movq -0x20340(%rbp), %rax movq 0x18(%rax), %rdi leaq 0x91237(%rip), %rsi # 0xca8f1 callq 0x36830 cmpl $0x0, %eax je 0x39723 cmpb $0x0, -0x2034a(%rbp) je 0x39707 cmpb $0x0, -0x20330(%rbp) je 0x396eb leaq -0x20330(%rbp), %rsi leaq 0x3b1acc(%rip), %rdi # 0x3eb1b0 callq 0x6e620 jmp 0x39705 leaq -0x330(%rbp), %rsi movq -0x20348(%rbp), %rdx leaq 0x3b1a88(%rip), %rdi # 0x3eb188 callq 0x399d0 jmp 0x39721 movq -0x20358(%rbp), %rdi leaq -0x330(%rbp), %rsi movq -0x20348(%rbp), %rdx callq 0x399d0 jmp 0x39723 leaq 0x3b1a0e(%rip), %rax # 0x3eb138 movq %rax, -0x20358(%rbp) movb $0x0, -0x20349(%rbp) movb $0x0, -0x2034a(%rbp) movb $0x0, -0x20330(%rbp) cmpb $0x0, 0x3b1a8d(%rip) # 0x3eb1da je 0x39754 jmp 0x3960f jmp 0x39756 movsbl -0x2035d(%rbp), %eax cmpl $0x0, %eax je 0x39793 cmpl $0x0, -0x2035c(%rbp) je 0x39793 movq -0x20340(%rbp), %rax movq (%rax), %rsi movq -0x20340(%rbp), %rax movq 0x18(%rax), %rdx leaq 0x9144e(%rip), %rdi # 0xcabd5 movb $0x0, %al callq 0x36070 jmp 0x398f5 cmpb $0x0, -0x2035d(%rbp) jne 0x398cf cmpl $0x0, -0x2035c(%rbp) je 0x398cf movq -0x20340(%rbp), %rax movq 0x10(%rax), %rdi leaq 0x919c5(%rip), %rsi # 0xcb184 callq 0x36830 cmpl $0x0, %eax jne 0x3983e movq -0x20340(%rbp), %rax movq 0x18(%rax), %rdi leaq 0x91403(%rip), %rsi # 0xcabde callq 0x36450 cmpq $0x0, %rax je 0x3983e movq -0x20340(%rbp), %rax movq (%rax), %rsi leaq 0x913de(%rip), %rdi # 0xcabd5 leaq 0x913e8(%rip), %rdx # 0xcabe6 movb $0x0, %al callq 0x36070 movq -0x20340(%rbp), %rax movq 0x18(%rax), %rdi leaq 0x91138(%rip), %rsi # 0xca94f callq 0x36450 movq %rax, %rdx leaq 0x3b1912(%rip), %rax # 0x3eb138 leaq 0x3b1933(%rip), %rcx # 0x3eb160 cmpq $0x0, %rdx cmovneq %rcx, %rax movq %rax, -0x20358(%rbp) jmp 0x3986c movq -0x20340(%rbp), %rax movq (%rax), %rsi movq -0x20340(%rbp), %rax movq 0x10(%rax), %rdx movq -0x20340(%rbp), %rax movq 0x18(%rax), %rcx leaq 0x9138f(%rip), %rdi # 0xcabf4 movb $0x0, %al callq 0x36070 movsbl 0x3b18bd(%rip), %eax # 0x3eb130 cmpl $0x0, %eax je 0x398cd movq -0x20340(%rbp), %rax movq 0x10(%rax), %rdi leaq 0x91376(%rip), %rsi # 0xcac00 callq 0x36830 cmpl $0x0, %eax je 0x398cd movb $0x1, -0x20349(%rbp) movsbl 0x3b188e(%rip), %eax # 0x3eb130 cmpl $0x0, %eax je 0x398cb movq -0x20340(%rbp), %rax movq 0x18(%rax), %rdi leaq 0x9134c(%rip), %rsi # 0xcac05 callq 0x36450 cmpq $0x0, %rax je 0x398cb movb $0x1, -0x2034a(%rbp) jmp 0x398cd jmp 0x398f3 movq -0x20340(%rbp), %rax movq 0x10(%rax), %rsi movq -0x20340(%rbp), %rax movq 0x18(%rax), %rdx leaq 0x9130b(%rip), %rdi # 0xcabf7 movb $0x0, %al callq 0x36070 jmp 0x398f5 leaq -0x330(%rbp), %rdi movq -0x20340(%rbp), %rax movq (%rax), %rsi callq 0x36970 movl $0xa, %edi callq 0x36b20 jmp 0x3960f movsbl -0x20349(%rbp), %eax cmpl $0x0, %eax je 0x3999a movsbl 0x3b1803(%rip), %eax # 0x3eb130 cmpl $0x0, %eax je 0x3999a cmpl $0x2, 0x3b17cf(%rip) # 0x3eb108 je 0x3999a cmpb $0x0, -0x2034a(%rbp) je 0x3997e cmpb $0x0, -0x20330(%rbp) je 0x39962 leaq -0x20330(%rbp), %rsi leaq 0x3b1855(%rip), %rdi # 0x3eb1b0 callq 0x6e620 jmp 0x3997c leaq -0x330(%rbp), %rsi movq -0x20348(%rbp), %rdx leaq 0x3b1811(%rip), %rdi # 0x3eb188 callq 0x399d0 jmp 0x39998 movq -0x20358(%rbp), %rdi leaq -0x330(%rbp), %rsi movq -0x20348(%rbp), %rdx callq 0x399d0 jmp 0x3999a movq -0x20338(%rbp), %rdi callq 0x3afe0 jmp 0x399a8 movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x399c3 addq $0x20360, %rsp # imm = 0x20360 popq %rbp retq callq 0x362a0 nopl (%rax,%rax)
print_result: push rbp mov rbp, rsp sub rsp, 20360h mov rax, fs:28h mov [rbp+var_8], rax mov rax, cs:sock mov rdi, [rax+2E8h] call _strlen mov [rbp+var_20348], rax mov [rbp+var_20349], 0 mov [rbp+var_2034A], 0 lea rax, tables4repair mov [rbp+var_20358], rax mov rdi, cs:sock call mysql_use_result mov [rbp+var_20338], rax mov [rbp+var_330], 0 mov [rbp+var_20330], 0 loc_3960F: mov rdi, [rbp+var_20338] call mysql_fetch_row mov [rbp+var_20340], rax cmp rax, 0 jz loc_3991A lea rdi, [rbp+var_330] mov rax, [rbp+var_20340] mov rsi, [rax] call _strcmp mov [rbp+var_2035C], eax mov rax, [rbp+var_20340] mov rdi, [rax+10h] lea rsi, aStatus; "status" call _strcmp cmp eax, 0 setnz al xor al, 0FFh and al, 1 movzx eax, al mov [rbp+var_2035D], al cmp [rbp+var_2035D], 0 jz loc_39756 movsx eax, [rbp+var_20349] cmp eax, 0 jz loc_39723 movsx eax, cs:opt_auto_repair cmp eax, 0 jz loc_39723 cmp cs:what_to_do, 2 jz short loc_39723 mov rax, [rbp+var_20340] mov rdi, [rax+18h] lea rsi, aOk; "OK" call _strcmp cmp eax, 0 jz short loc_39723 cmp [rbp+var_2034A], 0 jz short loc_39707 cmp [rbp+var_20330], 0 jz short loc_396EB lea rsi, [rbp+var_20330] lea rdi, alter_table_cmds call insert_dynamic jmp short loc_39705 loc_396EB: lea rsi, [rbp+var_330] mov rdx, [rbp+var_20348] lea rdi, tables4rebuild call insert_table_name loc_39705: jmp short loc_39721 loc_39707: mov rdi, [rbp+var_20358] lea rsi, [rbp+var_330] mov rdx, [rbp+var_20348] call insert_table_name loc_39721: jmp short $+2 loc_39723: lea rax, tables4repair mov [rbp+var_20358], rax mov [rbp+var_20349], 0 mov [rbp+var_2034A], 0 mov [rbp+var_20330], 0 cmp cs:opt_silent, 0 jz short loc_39754 jmp loc_3960F loc_39754: jmp short $+2 loc_39756: movsx eax, [rbp+var_2035D] cmp eax, 0 jz short loc_39793 cmp [rbp+var_2035C], 0 jz short loc_39793 mov rax, [rbp+var_20340] mov rsi, [rax] mov rax, [rbp+var_20340] mov rdx, [rax+18h] lea rdi, a50sS_0; "%-50s %s" mov al, 0 call _printf jmp loc_398F5 loc_39793: cmp [rbp+var_2035D], 0 jnz loc_398CF cmp [rbp+var_2035C], 0 jz loc_398CF mov rax, [rbp+var_20340] mov rdi, [rax+10h] lea rsi, aUnknownError+8; "error" call _strcmp cmp eax, 0 jnz short loc_3983E mov rax, [rbp+var_20340] mov rdi, [rax+18h] lea rsi, aRepair_1; "REPAIR " call _strstr cmp rax, 0 jz short loc_3983E mov rax, [rbp+var_20340] mov rsi, [rax] lea rdi, a50sS_0; "%-50s %s" lea rdx, aNeedsUpgrade; "Needs upgrade" mov al, 0 call _printf mov rax, [rbp+var_20340] mov rdi, [rax+18h] lea rsi, aView_0; "VIEW" call _strstr mov rdx, rax lea rax, tables4repair lea rcx, views4repair cmp rdx, 0 cmovnz rax, rcx mov [rbp+var_20358], rax jmp short loc_3986C loc_3983E: mov rax, [rbp+var_20340] mov rsi, [rax] mov rax, [rbp+var_20340] mov rdx, [rax+10h] mov rax, [rbp+var_20340] mov rcx, [rax+18h] lea rdi, aS9sS; "%s\n%-9s: %s" mov al, 0 call _printf loc_3986C: movsx eax, cs:opt_auto_repair cmp eax, 0 jz short loc_398CD mov rax, [rbp+var_20340] mov rdi, [rax+10h] lea rsi, aNote; "note" call _strcmp cmp eax, 0 jz short loc_398CD mov [rbp+var_20349], 1 movsx eax, cs:opt_auto_repair cmp eax, 0 jz short loc_398CB mov rax, [rbp+var_20340] mov rdi, [rax+18h] lea rsi, aAlterTable_0; "ALTER TABLE" call _strstr cmp rax, 0 jz short loc_398CB mov [rbp+var_2034A], 1 loc_398CB: jmp short $+2 loc_398CD: jmp short loc_398F3 loc_398CF: mov rax, [rbp+var_20340] mov rsi, [rax+10h] mov rax, [rbp+var_20340] mov rdx, [rax+18h] lea rdi, aS9sS+3; "%-9s: %s" mov al, 0 call _printf loc_398F3: jmp short $+2 loc_398F5: lea rdi, [rbp+var_330] mov rax, [rbp+var_20340] mov rsi, [rax] call _stpcpy mov edi, 0Ah call _putchar jmp loc_3960F loc_3991A: movsx eax, [rbp+var_20349] cmp eax, 0 jz short loc_3999A movsx eax, cs:opt_auto_repair cmp eax, 0 jz short loc_3999A cmp cs:what_to_do, 2 jz short loc_3999A cmp [rbp+var_2034A], 0 jz short loc_3997E cmp [rbp+var_20330], 0 jz short loc_39962 lea rsi, [rbp+var_20330] lea rdi, alter_table_cmds call insert_dynamic jmp short loc_3997C loc_39962: lea rsi, [rbp+var_330] mov rdx, [rbp+var_20348] lea rdi, tables4rebuild call insert_table_name loc_3997C: jmp short loc_39998 loc_3997E: mov rdi, [rbp+var_20358] lea rsi, [rbp+var_330] mov rdx, [rbp+var_20348] call insert_table_name loc_39998: jmp short $+2 loc_3999A: mov rdi, [rbp+var_20338] call mysql_free_result jmp short $+2 loc_399A8: mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_399C3 add rsp, 20360h pop rbp retn loc_399C3: call ___stack_chk_fail
unsigned long long print_result() { int v0; // eax long long v1; // rdx long long *v2; // rax bool v4; // [rsp+3h] [rbp-2035Dh] int v5; // [rsp+4h] [rbp-2035Ch] long long *v6; // [rsp+8h] [rbp-20358h] char v7; // [rsp+16h] [rbp-2034Ah] char v8; // [rsp+17h] [rbp-20349h] long long v9; // [rsp+18h] [rbp-20348h] const char **row; // [rsp+20h] [rbp-20340h] long long v11; // [rsp+28h] [rbp-20338h] _BYTE v12[131072]; // [rsp+30h] [rbp-20330h] BYREF _BYTE v13[808]; // [rsp+20030h] [rbp-330h] BYREF unsigned long long v14; // [rsp+20358h] [rbp-8h] v14 = __readfsqword(0x28u); v9 = strlen(*(_QWORD *)(sock + 744)); v8 = 0; v7 = 0; v6 = &tables4repair; v11 = mysql_use_result(sock); v13[0] = 0; v12[0] = 0; while ( 1 ) { row = (const char **)mysql_fetch_row(v11); if ( !row ) break; v5 = strcmp(v13, *row); v0 = strcmp(row[2], "status"); v4 = v0 == 0; if ( !v0 ) { if ( v8 && opt_auto_repair && what_to_do != 2 && (unsigned int)strcmp(row[3], "OK") ) { if ( v7 ) { if ( v12[0] ) insert_dynamic(&alter_table_cmds, v12); else insert_table_name(&tables4rebuild, v13, v9); } else { insert_table_name(v6, v13, v9); } } v6 = &tables4repair; v8 = 0; v7 = 0; v12[0] = 0; if ( opt_silent ) continue; } if ( v4 && v5 ) { printf("%-50s %s", *row, row[3]); } else if ( v4 || !v5 ) { printf("%-9s: %s", row[2], row[3]); } else { if ( !(unsigned int)strcmp(row[2], "error") && strstr(row[3], "REPAIR ") ) { printf("%-50s %s", *row, "Needs upgrade"); v1 = strstr(row[3], "VIEW"); v2 = &tables4repair; if ( v1 ) v2 = &views4repair; v6 = v2; } else { printf("%s\n%-9s: %s", *row, row[2], row[3]); } if ( opt_auto_repair ) { if ( (unsigned int)strcmp(row[2], "note") ) { v8 = 1; if ( opt_auto_repair ) { if ( strstr(row[3], "ALTER TABLE") ) v7 = 1; } } } } stpcpy(v13, *row); putchar(10LL); } if ( v8 && opt_auto_repair && what_to_do != 2 ) { if ( v7 ) { if ( v12[0] ) insert_dynamic(&alter_table_cmds, v12); else insert_table_name(&tables4rebuild, v13, v9); } else { insert_table_name(v6, v13, v9); } } mysql_free_result(v11); return __readfsqword(0x28u); }
print_result: PUSH RBP MOV RBP,RSP SUB RSP,0x20360 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV RAX,qword ptr [0x004eb780] MOV RDI,qword ptr [RAX + 0x2e8] CALL 0x001363e0 MOV qword ptr [RBP + -0x20348],RAX MOV byte ptr [RBP + -0x20349],0x0 MOV byte ptr [RBP + -0x2034a],0x0 LEA RAX,[0x4eb138] MOV qword ptr [RBP + -0x20358],RAX MOV RDI,qword ptr [0x004eb780] CALL 0x00140fc0 MOV qword ptr [RBP + -0x20338],RAX MOV byte ptr [RBP + -0x330],0x0 MOV byte ptr [RBP + -0x20330],0x0 LAB_0013960f: MOV RDI,qword ptr [RBP + -0x20338] CALL 0x00143ae0 MOV qword ptr [RBP + -0x20340],RAX CMP RAX,0x0 JZ 0x0013991a LEA RDI,[RBP + -0x330] MOV RAX,qword ptr [RBP + -0x20340] MOV RSI,qword ptr [RAX] CALL 0x00136830 MOV dword ptr [RBP + -0x2035c],EAX MOV RAX,qword ptr [RBP + -0x20340] MOV RDI,qword ptr [RAX + 0x10] LEA RSI,[0x1cabce] CALL 0x00136830 CMP EAX,0x0 SETNZ AL XOR AL,0xff AND AL,0x1 MOVZX EAX,AL MOV byte ptr [RBP + -0x2035d],AL CMP byte ptr [RBP + -0x2035d],0x0 JZ 0x00139756 MOVSX EAX,byte ptr [RBP + -0x20349] CMP EAX,0x0 JZ 0x00139723 MOVSX EAX,byte ptr [0x004eb130] CMP EAX,0x0 JZ 0x00139723 CMP dword ptr [0x004eb108],0x2 JZ 0x00139723 MOV RAX,qword ptr [RBP + -0x20340] MOV RDI,qword ptr [RAX + 0x18] LEA RSI,[0x1ca8f1] CALL 0x00136830 CMP EAX,0x0 JZ 0x00139723 CMP byte ptr [RBP + -0x2034a],0x0 JZ 0x00139707 CMP byte ptr [RBP + -0x20330],0x0 JZ 0x001396eb LEA RSI,[RBP + -0x20330] LEA RDI,[0x4eb1b0] CALL 0x0016e620 JMP 0x00139705 LAB_001396eb: LEA RSI,[RBP + -0x330] MOV RDX,qword ptr [RBP + -0x20348] LEA RDI,[0x4eb188] CALL 0x001399d0 LAB_00139705: JMP 0x00139721 LAB_00139707: MOV RDI,qword ptr [RBP + -0x20358] LEA RSI,[RBP + -0x330] MOV RDX,qword ptr [RBP + -0x20348] CALL 0x001399d0 LAB_00139721: JMP 0x00139723 LAB_00139723: LEA RAX,[0x4eb138] MOV qword ptr [RBP + -0x20358],RAX MOV byte ptr [RBP + -0x20349],0x0 MOV byte ptr [RBP + -0x2034a],0x0 MOV byte ptr [RBP + -0x20330],0x0 CMP byte ptr [0x004eb1da],0x0 JZ 0x00139754 JMP 0x0013960f LAB_00139754: JMP 0x00139756 LAB_00139756: MOVSX EAX,byte ptr [RBP + -0x2035d] CMP EAX,0x0 JZ 0x00139793 CMP dword ptr [RBP + -0x2035c],0x0 JZ 0x00139793 MOV RAX,qword ptr [RBP + -0x20340] MOV RSI,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x20340] MOV RDX,qword ptr [RAX + 0x18] LEA RDI,[0x1cabd5] MOV AL,0x0 CALL 0x00136070 JMP 0x001398f5 LAB_00139793: CMP byte ptr [RBP + -0x2035d],0x0 JNZ 0x001398cf CMP dword ptr [RBP + -0x2035c],0x0 JZ 0x001398cf MOV RAX,qword ptr [RBP + -0x20340] MOV RDI,qword ptr [RAX + 0x10] LEA RSI,[0x1cb184] CALL 0x00136830 CMP EAX,0x0 JNZ 0x0013983e MOV RAX,qword ptr [RBP + -0x20340] MOV RDI,qword ptr [RAX + 0x18] LEA RSI,[0x1cabde] CALL 0x00136450 CMP RAX,0x0 JZ 0x0013983e MOV RAX,qword ptr [RBP + -0x20340] MOV RSI,qword ptr [RAX] LEA RDI,[0x1cabd5] LEA RDX,[0x1cabe6] MOV AL,0x0 CALL 0x00136070 MOV RAX,qword ptr [RBP + -0x20340] MOV RDI,qword ptr [RAX + 0x18] LEA RSI,[0x1ca94f] CALL 0x00136450 MOV RDX,RAX LEA RAX,[0x4eb138] LEA RCX,[0x4eb160] CMP RDX,0x0 CMOVNZ RAX,RCX MOV qword ptr [RBP + -0x20358],RAX JMP 0x0013986c LAB_0013983e: MOV RAX,qword ptr [RBP + -0x20340] MOV RSI,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x20340] MOV RDX,qword ptr [RAX + 0x10] MOV RAX,qword ptr [RBP + -0x20340] MOV RCX,qword ptr [RAX + 0x18] LEA RDI,[0x1cabf4] MOV AL,0x0 CALL 0x00136070 LAB_0013986c: MOVSX EAX,byte ptr [0x004eb130] CMP EAX,0x0 JZ 0x001398cd MOV RAX,qword ptr [RBP + -0x20340] MOV RDI,qword ptr [RAX + 0x10] LEA RSI,[0x1cac00] CALL 0x00136830 CMP EAX,0x0 JZ 0x001398cd MOV byte ptr [RBP + -0x20349],0x1 MOVSX EAX,byte ptr [0x004eb130] CMP EAX,0x0 JZ 0x001398cb MOV RAX,qword ptr [RBP + -0x20340] MOV RDI,qword ptr [RAX + 0x18] LEA RSI,[0x1cac05] CALL 0x00136450 CMP RAX,0x0 JZ 0x001398cb MOV byte ptr [RBP + -0x2034a],0x1 LAB_001398cb: JMP 0x001398cd LAB_001398cd: JMP 0x001398f3 LAB_001398cf: MOV RAX,qword ptr [RBP + -0x20340] MOV RSI,qword ptr [RAX + 0x10] MOV RAX,qword ptr [RBP + -0x20340] MOV RDX,qword ptr [RAX + 0x18] LEA RDI,[0x1cabf7] MOV AL,0x0 CALL 0x00136070 LAB_001398f3: JMP 0x001398f5 LAB_001398f5: LEA RDI,[RBP + -0x330] MOV RAX,qword ptr [RBP + -0x20340] MOV RSI,qword ptr [RAX] CALL 0x00136970 MOV EDI,0xa CALL 0x00136b20 JMP 0x0013960f LAB_0013991a: MOVSX EAX,byte ptr [RBP + -0x20349] CMP EAX,0x0 JZ 0x0013999a MOVSX EAX,byte ptr [0x004eb130] CMP EAX,0x0 JZ 0x0013999a CMP dword ptr [0x004eb108],0x2 JZ 0x0013999a CMP byte ptr [RBP + -0x2034a],0x0 JZ 0x0013997e CMP byte ptr [RBP + -0x20330],0x0 JZ 0x00139962 LEA RSI,[RBP + -0x20330] LEA RDI,[0x4eb1b0] CALL 0x0016e620 JMP 0x0013997c LAB_00139962: LEA RSI,[RBP + -0x330] MOV RDX,qword ptr [RBP + -0x20348] LEA RDI,[0x4eb188] CALL 0x001399d0 LAB_0013997c: JMP 0x00139998 LAB_0013997e: MOV RDI,qword ptr [RBP + -0x20358] LEA RSI,[RBP + -0x330] MOV RDX,qword ptr [RBP + -0x20348] CALL 0x001399d0 LAB_00139998: JMP 0x0013999a LAB_0013999a: MOV RDI,qword ptr [RBP + -0x20338] CALL 0x0013afe0 JMP 0x001399a8 LAB_001399a8: MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x001399c3 ADD RSP,0x20360 POP RBP RET LAB_001399c3: CALL 0x001362a0
/* WARNING: Removing unreachable block (ram,0x001396d6) */ /* WARNING: Removing unreachable block (ram,0x0013994d) */ void print_result(void) { bool bVar1; bool bVar2; int iVar3; int iVar4; size_t sVar5; int8 uVar6; int8 *puVar7; char *pcVar8; long in_FS_OFFSET; bool bVar9; int8 *puStack_20360; char local_338 [808]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); sVar5 = strlen(*(char **)(sock + 0x2e8)); bVar1 = false; bVar2 = false; puStack_20360 = &tables4repair; uVar6 = mysql_use_result(sock); local_338[0] = '\0'; LAB_0013960f: puVar7 = (int8 *)mysql_fetch_row(uVar6); if (puVar7 == (int8 *)0x0) { if (((bVar1) && (opt_auto_repair != '\0')) && (what_to_do != 2)) { if (bVar2) { insert_table_name(&tables4rebuild,local_338,sVar5); } else { insert_table_name(puStack_20360,local_338,sVar5); } } mysql_free_result(uVar6); if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); } iVar3 = strcmp(local_338,(char *)*puVar7); iVar4 = strcmp((char *)puVar7[2],"status"); bVar9 = iVar4 == 0; if (bVar9) goto code_r0x0013967f; goto LAB_00139756; code_r0x0013967f: if (((bVar1) && (opt_auto_repair != '\0')) && ((what_to_do != 2 && (iVar4 = strcmp((char *)puVar7[3],"OK"), iVar4 != 0)))) { if (bVar2) { insert_table_name(&tables4rebuild,local_338,sVar5); } else { insert_table_name(puStack_20360,local_338,sVar5); } } puStack_20360 = &tables4repair; bVar1 = false; bVar2 = false; if (opt_silent == '\0') { LAB_00139756: if ((bVar9) && (iVar3 != 0)) { printf("%-50s %s",*puVar7,puVar7[3]); } else if ((bVar9) || (iVar3 == 0)) { printf("%-9s: %s",puVar7[2],puVar7[3]); } else { iVar3 = strcmp((char *)puVar7[2],"error"); if ((iVar3 == 0) && (pcVar8 = strstr((char *)puVar7[3],"REPAIR "), pcVar8 != (char *)0x0)) { printf("%-50s %s",*puVar7,"Needs upgrade"); pcVar8 = strstr((char *)puVar7[3],"VIEW"); puStack_20360 = &tables4repair; if (pcVar8 != (char *)0x0) { puStack_20360 = &views4repair; } } else { printf("%s\n%-9s: %s",*puVar7,puVar7[2],puVar7[3]); } if ((((opt_auto_repair != '\0') && (iVar3 = strcmp((char *)puVar7[2],"note"), iVar3 != 0)) && (bVar1 = true, opt_auto_repair != '\0')) && (pcVar8 = strstr((char *)puVar7[3],"ALTER TABLE"), pcVar8 != (char *)0x0)) { bVar2 = true; } } stpcpy(local_338,(char *)*puVar7); putchar(10); } goto LAB_0013960f; }
3,558
nglog::SetEmailLogging(nglog::LogSeverity, char const*)
ng-log[P]ng-log/src/logging.cc
void SetEmailLogging(LogSeverity min_severity, const char* addresses) { LogDestination::SetEmailLogging(min_severity, addresses); }
O1
cpp
nglog::SetEmailLogging(nglog::LogSeverity, char const*): pushq %rbp pushq %r15 pushq %r14 pushq %rbx pushq %rax movq %rsi, %rbx movl %edi, %ebp leaq 0x34269(%rip), %rdi # 0x40d48 callq 0x7840 testl %eax, %eax jne 0xcb2d movl %ebp, 0x24a92(%rip) # 0x31580 movq 0x25113(%rip), %r14 # 0x31c08 leaq 0x25104(%rip), %r15 # 0x31c00 movq %rbx, %rdi callq 0x71f0 movq %r15, %rdi xorl %esi, %esi movq %r14, %rdx movq %rbx, %rcx movq %rax, %r8 callq 0x78b0 leaq 0x3422a(%rip), %rdi # 0x40d48 addq $0x8, %rsp popq %rbx popq %r14 popq %r15 popq %rbp jmp 0x73e0 movl %eax, %edi callq 0x7350 movq %rax, %rbx leaq 0x3420a(%rip), %rdi # 0x40d48 callq 0x73e0 movq %rbx, %rdi callq 0x79b0
_ZN5nglog15SetEmailLoggingENS_11LogSeverityEPKc: push rbp push r15 push r14 push rbx push rax mov rbx, rsi mov ebp, edi lea rdi, _ZN5nglogL9log_mutexE; nglog::log_mutex call _pthread_mutex_lock test eax, eax jnz short loc_CB2D mov cs:_ZN5nglog14LogDestination23email_logging_severity_E, ebp; nglog::LogDestination::email_logging_severity_ mov r14, cs:qword_31C08 lea r15, _ZN5nglog14LogDestination10addresses_B5cxx11E; nglog::LogDestination::addresses_ mov rdi, rbx call _strlen mov rdi, r15 xor esi, esi mov rdx, r14 mov rcx, rbx mov r8, rax call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE10_M_replaceEmmPKcm; std::string::_M_replace(ulong,ulong,char const*,ulong) lea rdi, _ZN5nglogL9log_mutexE; nglog::log_mutex add rsp, 8 pop rbx pop r14 pop r15 pop rbp jmp _pthread_mutex_unlock loc_CB2D: mov edi, eax; int call __ZSt20__throw_system_errori; std::__throw_system_error(int) mov rbx, rax lea rdi, _ZN5nglogL9log_mutexE; nglog::log_mutex call _pthread_mutex_unlock mov rdi, rbx call __Unwind_Resume
long long nglog::SetEmailLogging(int a1, long long a2) { int v2; // eax long long v3; // r14 long long v4; // rax v2 = pthread_mutex_lock(&nglog::log_mutex); if ( v2 ) std::__throw_system_error(v2); nglog::LogDestination::email_logging_severity_ = a1; v3 = qword_31C08; v4 = strlen(a2); std::string::_M_replace(&nglog::LogDestination::addresses_[abi:cxx11], 0LL, v3, a2, v4); return pthread_mutex_unlock(&nglog::log_mutex); }
SetEmailLogging: PUSH RBP PUSH R15 PUSH R14 PUSH RBX PUSH RAX MOV RBX,RSI MOV EBP,EDI LEA RDI,[0x140d48] CALL 0x00107840 TEST EAX,EAX JNZ 0x0010cb2d MOV dword ptr [0x00131580],EBP MOV R14,qword ptr [0x00131c08] LEA R15,[0x131c00] MOV RDI,RBX CALL 0x001071f0 LAB_0010cb04: MOV RDI,R15 XOR ESI,ESI MOV RDX,R14 MOV RCX,RBX MOV R8,RAX CALL 0x001078b0 LAB_0010cb17: LEA RDI,[0x140d48] ADD RSP,0x8 POP RBX POP R14 POP R15 POP RBP JMP 0x001073e0 LAB_0010cb2d: MOV EDI,EAX CALL 0x00107350
/* nglog::SetEmailLogging(nglog::LogSeverity, char const*) */ void nglog::SetEmailLogging(int4 param_1,char *param_2) { char *pcVar1; int iVar2; iVar2 = pthread_mutex_lock((pthread_mutex_t *)log_mutex); pcVar1 = DAT_00131c08; if (iVar2 == 0) { LogDestination::email_logging_severity_ = param_1; strlen(param_2); /* try { // try from 0010cb04 to 0010cb16 has its CatchHandler @ 0010cb34 */ std::__cxx11::string::_M_replace(0x131c00,0,pcVar1,(ulong)param_2); pthread_mutex_unlock((pthread_mutex_t *)log_mutex); return; } /* WARNING: Subroutine does not return */ std::__throw_system_error(iVar2); }
3,559
to_digit
bluesky950520[P]quickjs/quickjs.c
static inline int to_digit(int c) { if (c >= '0' && c <= '9') return c - '0'; else if (c >= 'A' && c <= 'Z') return c - 'A' + 10; else if (c >= 'a' && c <= 'z') return c - 'a' + 10; else return 36; }
O0
c
to_digit: movl %edi, -0x8(%rsp) cmpl $0x30, -0x8(%rsp) jl 0x6399f cmpl $0x39, -0x8(%rsp) jg 0x6399f movl -0x8(%rsp), %eax subl $0x30, %eax movl %eax, -0x4(%rsp) jmp 0x639e3 cmpl $0x41, -0x8(%rsp) jl 0x639bd cmpl $0x5a, -0x8(%rsp) jg 0x639bd movl -0x8(%rsp), %eax subl $0x41, %eax addl $0xa, %eax movl %eax, -0x4(%rsp) jmp 0x639e3 cmpl $0x61, -0x8(%rsp) jl 0x639db cmpl $0x7a, -0x8(%rsp) jg 0x639db movl -0x8(%rsp), %eax subl $0x61, %eax addl $0xa, %eax movl %eax, -0x4(%rsp) jmp 0x639e3 movl $0x24, -0x4(%rsp) movl -0x4(%rsp), %eax retq nopl (%rax,%rax)
to_digit: mov [rsp+var_8], edi cmp [rsp+var_8], 30h ; '0' jl short loc_6399F cmp [rsp+var_8], 39h ; '9' jg short loc_6399F mov eax, [rsp+var_8] sub eax, 30h ; '0' mov [rsp+var_4], eax jmp short loc_639E3 loc_6399F: cmp [rsp+var_8], 41h ; 'A' jl short loc_639BD cmp [rsp+var_8], 5Ah ; 'Z' jg short loc_639BD mov eax, [rsp+var_8] sub eax, 41h ; 'A' add eax, 0Ah mov [rsp+var_4], eax jmp short loc_639E3 loc_639BD: cmp [rsp+var_8], 61h ; 'a' jl short loc_639DB cmp [rsp+var_8], 7Ah ; 'z' jg short loc_639DB mov eax, [rsp+var_8] sub eax, 61h ; 'a' add eax, 0Ah mov [rsp+var_4], eax jmp short loc_639E3 loc_639DB: mov [rsp+var_4], 24h ; '$' loc_639E3: mov eax, [rsp+var_4] retn
long long to_digit(int a1) { if ( a1 < 48 || a1 > 57 ) { if ( a1 < 65 || a1 > 90 ) { if ( a1 < 97 || a1 > 122 ) return 36; else return (unsigned int)(a1 - 97 + 10); } else { return (unsigned int)(a1 - 65 + 10); } } else { return (unsigned int)(a1 - 48); } }
to_digit: MOV dword ptr [RSP + -0x8],EDI CMP dword ptr [RSP + -0x8],0x30 JL 0x0016399f CMP dword ptr [RSP + -0x8],0x39 JG 0x0016399f MOV EAX,dword ptr [RSP + -0x8] SUB EAX,0x30 MOV dword ptr [RSP + -0x4],EAX JMP 0x001639e3 LAB_0016399f: CMP dword ptr [RSP + -0x8],0x41 JL 0x001639bd CMP dword ptr [RSP + -0x8],0x5a JG 0x001639bd MOV EAX,dword ptr [RSP + -0x8] SUB EAX,0x41 ADD EAX,0xa MOV dword ptr [RSP + -0x4],EAX JMP 0x001639e3 LAB_001639bd: CMP dword ptr [RSP + -0x8],0x61 JL 0x001639db CMP dword ptr [RSP + -0x8],0x7a JG 0x001639db MOV EAX,dword ptr [RSP + -0x8] SUB EAX,0x61 ADD EAX,0xa MOV dword ptr [RSP + -0x4],EAX JMP 0x001639e3 LAB_001639db: MOV dword ptr [RSP + -0x4],0x24 LAB_001639e3: MOV EAX,dword ptr [RSP + -0x4] RET
int to_digit(int param_1) { int4 local_4; if ((param_1 < 0x30) || (0x39 < param_1)) { if ((param_1 < 0x41) || (0x5a < param_1)) { if ((param_1 < 0x61) || (0x7a < param_1)) { local_4 = 0x24; } else { local_4 = param_1 + -0x57; } } else { local_4 = param_1 + -0x37; } } else { local_4 = param_1 + -0x30; } return local_4; }
3,560
start_timer
eloqsql/unittest/mytap/tap.c
static ulong start_timer(void) { #if defined(_WIN32) return clock(); #else struct tms tms_tmp; return times(&tms_tmp); #endif }
O0
c
start_timer: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp leaq -0x20(%rbp), %rdi callq 0x244d0 addq $0x20, %rsp popq %rbp retq nopw (%rax,%rax)
start_timer: push rbp mov rbp, rsp sub rsp, 20h lea rdi, [rbp+var_20] call _times add rsp, 20h pop rbp retn
long long start_timer() { _BYTE v1[32]; // [rsp+0h] [rbp-20h] BYREF return times(v1); }
start_timer: PUSH RBP MOV RBP,RSP SUB RSP,0x20 LEA RDI,[RBP + -0x20] CALL 0x001244d0 ADD RSP,0x20 POP RBP RET
void start_timer(void) { tms local_28; times(&local_28); return; }
3,561
my_interval_timer
eloqsql/mysys/my_getsystime.c
ulonglong my_interval_timer() { #ifdef HAVE_CLOCK_GETTIME struct timespec tp; clock_gettime(CLOCK_MONOTONIC, &tp); return tp.tv_sec*1000000000ULL+tp.tv_nsec; #elif defined(HAVE_GETHRTIME) return gethrtime(); #elif defined(_WIN32) DBUG_ASSERT(query_performance_frequency); LARGE_INTEGER t_cnt; QueryPerformanceCounter(&t_cnt); return (t_cnt.QuadPart / query_performance_frequency * 1000000000ULL) + ((t_cnt.QuadPart % query_performance_frequency) * 1000000000ULL / query_performance_frequency); #else /* TODO: check for other possibilities for hi-res timestamping */ struct timeval tv; gettimeofday(&tv,NULL); return tv.tv_sec*1000000000ULL+tv.tv_usec*1000ULL; #endif }
O0
c
my_interval_timer: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movl $0x1, %edi leaq -0x10(%rbp), %rsi callq 0x38370 imulq $0x3b9aca00, -0x10(%rbp), %rax # imm = 0x3B9ACA00 addq -0x8(%rbp), %rax addq $0x10, %rsp popq %rbp retq nopl (%rax,%rax)
my_interval_timer: push rbp mov rbp, rsp sub rsp, 10h mov edi, 1 lea rsi, [rbp+var_10] call _clock_gettime imul rax, [rbp+var_10], 3B9ACA00h add rax, [rbp+var_8] add rsp, 10h pop rbp retn
long long my_interval_timer() { _QWORD v1[2]; // [rsp+0h] [rbp-10h] BYREF clock_gettime(1LL, v1); return v1[1] + 1000000000LL * v1[0]; }
my_interval_timer: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV EDI,0x1 LEA RSI,[RBP + -0x10] CALL 0x00138370 IMUL RAX,qword ptr [RBP + -0x10],0x3b9aca00 ADD RAX,qword ptr [RBP + -0x8] ADD RSP,0x10 POP RBP RET
long my_interval_timer(void) { timespec local_18; clock_gettime(1,&local_18); return local_18.tv_sec * 1000000000 + local_18.tv_nsec; }
3,562
google::protobuf::MessageLite::SerializePartialToZeroCopyStream(google::protobuf::io::ZeroCopyOutputStream*) const
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc
bool MessageLite::SerializePartialToZeroCopyStream( io::ZeroCopyOutputStream* output) const { const size_t size = ByteSizeLong(); // Force size to be cached. if (size > INT_MAX) { GOOGLE_LOG(ERROR) << GetTypeName() << " exceeded maximum protobuf size of 2GB: " << size; return false; } uint8_t* target; io::EpsCopyOutputStream stream( output, io::CodedOutputStream::IsDefaultSerializationDeterministic(), &target); target = _InternalSerialize(target, &stream); stream.Trim(target); if (stream.HadError()) return false; return true; }
O3
cpp
google::protobuf::MessageLite::SerializePartialToZeroCopyStream(google::protobuf::io::ZeroCopyOutputStream*) const: pushq %r15 pushq %r14 pushq %rbx subq $0x70, %rsp movq %rsi, %r15 movq %rdi, %r14 movq (%rdi), %rax callq *0x40(%rax) testq $-0x80000000, %rax # imm = 0x80000000 je 0x9e38e movq %rax, %rbx leaq 0x1fc40(%rip), %rdx # 0xbdf55 leaq 0x30(%rsp), %rdi movl $0x2, %esi movl $0x192, %ecx # imm = 0x192 callq 0x169ca movq (%r14), %rax leaq 0x10(%rsp), %rdi movq %r14, %rsi callq *0x10(%rax) leaq 0x30(%rsp), %rdi leaq 0x10(%rsp), %rsi callq 0x164da leaq 0x1fc77(%rip), %rsi # 0xbdfc4 movq %rax, %rdi callq 0x164c8 movq %rax, %rdi movq %rbx, %rsi callq 0x168b8 leaq 0xf(%rsp), %rdi movq %rax, %rsi callq 0x165a2 leaq 0x20(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x9e380 callq 0xf330 leaq 0x30(%rsp), %rdi callq 0x169e8 xorl %eax, %eax jmp 0x9e3d8 leaq 0x64ad4(%rip), %rax # 0x102e69 movb (%rax), %al andb $0x1, %al leaq 0x40(%rsp), %rsi movq %rsi, -0x10(%rsi) movq %rsi, -0x8(%rsi) movq %r15, 0x20(%rsi) movw $0x0, 0x28(%rsi) movb %al, 0x2a(%rsi) movb $0x0, 0x2b(%rsi) movq (%r14), %rax leaq 0x30(%rsp), %rbx movq %r14, %rdi movq %rbx, %rdx callq *0x60(%rax) movq %rbx, %rdi movq %rax, %rsi callq 0x15b74 movb 0x38(%rbx), %al xorb $0x1, %al addq $0x70, %rsp popq %rbx popq %r14 popq %r15 retq jmp 0x9e3e9 movq %rax, %rbx jmp 0x9e3ff movq %rax, %rbx leaq 0x20(%rsp), %rax movq -0x10(%rax), %rdi cmpq %rax, %rdi je 0x9e3ff callq 0xf330 leaq 0x30(%rsp), %rdi callq 0x169e8 movq %rbx, %rdi callq 0xf570 nop
_ZNK6google8protobuf11MessageLite32SerializePartialToZeroCopyStreamEPNS0_2io20ZeroCopyOutputStreamE: push r15 push r14 push rbx sub rsp, 70h mov r15, rsi mov r14, rdi mov rax, [rdi] call qword ptr [rax+40h] test rax, 0FFFFFFFF80000000h jz loc_9E38E mov rbx, rax lea rdx, aWorkspaceLlm4b_25; "/workspace/llm4binary/github2025/aimrt_"... lea rdi, [rsp+88h+var_58] mov esi, 2 mov ecx, 192h call _ZN6google8protobuf8internal10LogMessageC2ENS0_8LogLevelEPKci; google::protobuf::internal::LogMessage::LogMessage(google::protobuf::LogLevel,char const*,int) mov rax, [r14] lea rdi, [rsp+88h+var_78] mov rsi, r14 call qword ptr [rax+10h] lea rdi, [rsp+88h+var_58] lea rsi, [rsp+88h+var_78] call _ZN6google8protobuf8internal10LogMessagelsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; google::protobuf::internal::LogMessage::operator<<(std::string const&) lea rsi, aExceededMaximu; " exceeded maximum protobuf size of 2GB:"... mov rdi, rax call _ZN6google8protobuf8internal10LogMessagelsEPKc; google::protobuf::internal::LogMessage::operator<<(char const*) mov rdi, rax mov rsi, rbx call _ZN6google8protobuf8internal10LogMessagelsEm; google::protobuf::internal::LogMessage::operator<<(ulong) lea rdi, [rsp+88h+var_79] mov rsi, rax call _ZN6google8protobuf8internal11LogFinisheraSERNS1_10LogMessageE; google::protobuf::internal::LogFinisher::operator=(google::protobuf::internal::LogMessage &) lea rax, [rsp+88h+var_68] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_9E380 call __ZdlPv; operator delete(void *) loc_9E380: lea rdi, [rsp+88h+var_58]; this call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage() xor eax, eax jmp short loc_9E3D8 loc_9E38E: lea rax, _ZN6google8protobuf2io17CodedOutputStream36default_serialization_deterministic_E; google::protobuf::io::CodedOutputStream::default_serialization_deterministic_ mov al, [rax] and al, 1 lea rsi, [rsp+88h+var_48] mov [rsi-10h], rsi mov [rsi-8], rsi mov [rsi+20h], r15 mov word ptr [rsi+28h], 0 mov [rsi+2Ah], al mov byte ptr [rsi+2Bh], 0 mov rax, [r14] lea rbx, [rsp+88h+var_58] mov rdi, r14 mov rdx, rbx call qword ptr [rax+60h] mov rdi, rbx; this mov rsi, rax; unsigned __int8 * call _ZN6google8protobuf2io19EpsCopyOutputStream4TrimEPh; google::protobuf::io::EpsCopyOutputStream::Trim(uchar *) mov al, [rbx+38h] xor al, 1 loc_9E3D8: add rsp, 70h pop rbx pop r14 pop r15 retn jmp short loc_9E3E9 mov rbx, rax jmp short loc_9E3FF loc_9E3E9: mov rbx, rax lea rax, [rsp+arg_18] mov rdi, [rax-10h]; void * cmp rdi, rax jz short loc_9E3FF call __ZdlPv; operator delete(void *) loc_9E3FF: lea rdi, [rsp+arg_28]; this call _ZN6google8protobuf8internal10LogMessageD2Ev; google::protobuf::internal::LogMessage::~LogMessage() mov rdi, rbx call __Unwind_Resume
char google::protobuf::MessageLite::SerializePartialToZeroCopyStream( google::protobuf::MessageLite *this, google::protobuf::io::ZeroCopyOutputStream *a2) { long long v2; // rax google::protobuf *v3; // rbx long long v4; // rax long long v5; // rax char *v6; // rdx google::protobuf::internal::LogMessage *v7; // rax unsigned __int8 *v9; // rax char v10; // [rsp+Fh] [rbp-79h] BYREF void *v11[2]; // [rsp+10h] [rbp-78h] BYREF char v12; // [rsp+20h] [rbp-68h] BYREF _QWORD v13[2]; // [rsp+30h] [rbp-58h] BYREF _BYTE v14[32]; // [rsp+40h] [rbp-48h] BYREF google::protobuf::io::ZeroCopyOutputStream *v15; // [rsp+60h] [rbp-28h] __int16 v16; // [rsp+68h] [rbp-20h] char v17; // [rsp+6Ah] [rbp-1Eh] char v18; // [rsp+6Bh] [rbp-1Dh] v2 = (*(long long ( **)(google::protobuf::MessageLite *))(*(_QWORD *)this + 64LL))(this); if ( (v2 & 0xFFFFFFFF80000000LL) != 0 ) { v3 = (google::protobuf *)v2; google::protobuf::internal::LogMessage::LogMessage( (long long)v13, 2, (long long)"/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc", 402); (*(void ( **)(void **, google::protobuf::MessageLite *))(*(_QWORD *)this + 16LL))(v11, this); v4 = google::protobuf::internal::LogMessage::operator<<((long long)v13, (long long)v11); v5 = google::protobuf::internal::LogMessage::operator<<(v4, (long long)" exceeded maximum protobuf size of 2GB: "); v7 = (google::protobuf::internal::LogMessage *)google::protobuf::internal::LogMessage::operator<<(v5, v3, v6); google::protobuf::internal::LogFinisher::operator=((long long)&v10, v7); if ( v11[0] != &v12 ) operator delete(v11[0]); google::protobuf::internal::LogMessage::~LogMessage((google::protobuf::internal::LogMessage *)v13); return 0; } else { v13[0] = v14; v13[1] = v14; v15 = a2; v16 = 0; v17 = google::protobuf::io::CodedOutputStream::default_serialization_deterministic_[0] & 1; v18 = 0; v9 = (unsigned __int8 *)(*(long long ( **)(google::protobuf::MessageLite *, _BYTE *, _QWORD *))(*(_QWORD *)this + 96LL))( this, v14, v13); google::protobuf::io::EpsCopyOutputStream::Trim((google::protobuf::io::EpsCopyOutputStream *)v13, v9); return v16 ^ 1; } }
SerializePartialToZeroCopyStream: PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x70 MOV R15,RSI MOV R14,RDI MOV RAX,qword ptr [RDI] CALL qword ptr [RAX + 0x40] TEST RAX,-0x80000000 JZ 0x0019e38e MOV RBX,RAX LEA RDX,[0x1bdf55] LEA RDI,[RSP + 0x30] MOV ESI,0x2 MOV ECX,0x192 CALL 0x001169ca MOV RAX,qword ptr [R14] LAB_0019e32c: LEA RDI,[RSP + 0x10] MOV RSI,R14 CALL qword ptr [RAX + 0x10] LAB_0019e337: LEA RDI,[RSP + 0x30] LEA RSI,[RSP + 0x10] CALL 0x001164da LEA RSI,[0x1bdfc4] MOV RDI,RAX CALL 0x001164c8 MOV RDI,RAX MOV RSI,RBX CALL 0x001168b8 LAB_0019e360: LEA RDI,[RSP + 0xf] MOV RSI,RAX CALL 0x001165a2 LAB_0019e36d: LEA RAX,[RSP + 0x20] MOV RDI,qword ptr [RAX + -0x10] CMP RDI,RAX JZ 0x0019e380 CALL 0x0010f330 LAB_0019e380: LEA RDI,[RSP + 0x30] CALL 0x001169e8 XOR EAX,EAX JMP 0x0019e3d8 LAB_0019e38e: LEA RAX,[0x202e69] MOV AL,byte ptr [RAX] AND AL,0x1 LEA RSI,[RSP + 0x40] MOV qword ptr [RSI + -0x10],RSI MOV qword ptr [RSI + -0x8],RSI MOV qword ptr [RSI + 0x20],R15 MOV word ptr [RSI + 0x28],0x0 MOV byte ptr [RSI + 0x2a],AL MOV byte ptr [RSI + 0x2b],0x0 MOV RAX,qword ptr [R14] LEA RBX,[RSP + 0x30] MOV RDI,R14 MOV RDX,RBX CALL qword ptr [RAX + 0x60] MOV RDI,RBX MOV RSI,RAX CALL 0x00115b74 MOV AL,byte ptr [RBX + 0x38] XOR AL,0x1 LAB_0019e3d8: ADD RSP,0x70 POP RBX POP R14 POP R15 RET
/* google::protobuf::MessageLite::SerializePartialToZeroCopyStream(google::protobuf::io::ZeroCopyOutputStream*) const */ ulong __thiscall google::protobuf::MessageLite::SerializePartialToZeroCopyStream (MessageLite *this,ZeroCopyOutputStream *param_1) { ulong uVar1; LogMessage *pLVar2; uchar *puVar3; int8 uVar4; LogFinisher local_79; int1 *local_78 [2]; int1 local_68 [16]; int1 *local_58; int1 *local_50; int1 local_48 [32]; ZeroCopyOutputStream *local_28; int2 local_20; byte local_1e; int1 local_1d; uVar1 = (**(code **)(*(long *)this + 0x40))(); if ((uVar1 & 0xffffffff80000000) == 0) { local_1e = io::CodedOutputStream::default_serialization_deterministic_ & 1; local_58 = local_48; local_20 = 0; local_1d = 0; local_50 = local_58; local_28 = param_1; puVar3 = (uchar *)(**(code **)(*(long *)this + 0x60)) (this,local_58,(EpsCopyOutputStream *)&local_58); uVar4 = io::EpsCopyOutputStream::Trim((EpsCopyOutputStream *)&local_58,puVar3); uVar1 = CONCAT71((int7)((ulong)uVar4 >> 8),(int1)local_20) ^ 1; } else { internal::LogMessage::LogMessage ((LogMessage *)&local_58,2, "/workspace/llm4binary/github2025/aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/message_lite.cc" ,0x192); /* try { // try from 0019e32c to 0019e336 has its CatchHandler @ 0019e3e4 */ (**(code **)(*(long *)this + 0x10))(local_78,this); /* try { // try from 0019e337 to 0019e35f has its CatchHandler @ 0019e3e9 */ pLVar2 = (LogMessage *) internal::LogMessage::operator<<((LogMessage *)&local_58,(string *)local_78); pLVar2 = (LogMessage *) internal::LogMessage::operator<<(pLVar2," exceeded maximum protobuf size of 2GB: "); pLVar2 = (LogMessage *)internal::LogMessage::operator<<(pLVar2,uVar1); /* try { // try from 0019e360 to 0019e36c has its CatchHandler @ 0019e3e2 */ internal::LogFinisher::operator=(&local_79,pLVar2); if (local_78[0] != local_68) { operator_delete(local_78[0]); } internal::LogMessage::~LogMessage((LogMessage *)&local_58); uVar1 = 0; } return uVar1; }
3,563
stbi__get8
dmazzella[P]pylunasvg/lunasvg/plutovg/source/plutovg-stb-image.h
stbi_inline static stbi_uc stbi__get8(stbi__context *s) { if (s->img_buffer < s->img_buffer_end) return *s->img_buffer++; if (s->read_from_callbacks) { stbi__refill_buffer(s); return *s->img_buffer++; } return 0; }
O0
c
stbi__get8: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x10(%rbp) movq -0x10(%rbp), %rax movq 0xc0(%rax), %rax movq -0x10(%rbp), %rcx cmpq 0xc8(%rcx), %rax jae 0x6a1f4 movq -0x10(%rbp), %rcx movq 0xc0(%rcx), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, 0xc0(%rcx) movb (%rax), %al movb %al, -0x1(%rbp) jmp 0x6a22b movq -0x10(%rbp), %rax cmpl $0x0, 0x30(%rax) je 0x6a227 movq -0x10(%rbp), %rdi callq 0x66350 movq -0x10(%rbp), %rcx movq 0xc0(%rcx), %rax movq %rax, %rdx addq $0x1, %rdx movq %rdx, 0xc0(%rcx) movb (%rax), %al movb %al, -0x1(%rbp) jmp 0x6a22b movb $0x0, -0x1(%rbp) movb -0x1(%rbp), %al addq $0x10, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
stbi__get8: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_10], rdi mov rax, [rbp+var_10] mov rax, [rax+0C0h] mov rcx, [rbp+var_10] cmp rax, [rcx+0C8h] jnb short loc_6A1F4 mov rcx, [rbp+var_10] mov rax, [rcx+0C0h] mov rdx, rax add rdx, 1 mov [rcx+0C0h], rdx mov al, [rax] mov [rbp+var_1], al jmp short loc_6A22B loc_6A1F4: mov rax, [rbp+var_10] cmp dword ptr [rax+30h], 0 jz short loc_6A227 mov rdi, [rbp+var_10] call stbi__refill_buffer mov rcx, [rbp+var_10] mov rax, [rcx+0C0h] mov rdx, rax add rdx, 1 mov [rcx+0C0h], rdx mov al, [rax] mov [rbp+var_1], al jmp short loc_6A22B loc_6A227: mov [rbp+var_1], 0 loc_6A22B: mov al, [rbp+var_1] add rsp, 10h pop rbp retn
char stbi__get8(long long a1) { long long v1; // rax long long v2; // rax if ( *(_QWORD *)(a1 + 192) >= *(_QWORD *)(a1 + 200) ) { if ( *(_DWORD *)(a1 + 48) ) { stbi__refill_buffer(a1); v2 = *(_QWORD *)(a1 + 192); *(_QWORD *)(a1 + 192) = v2 + 1; return *(_BYTE *)v2; } else { return 0; } } else { v1 = *(_QWORD *)(a1 + 192); *(_QWORD *)(a1 + 192) = v1 + 1; return *(_BYTE *)v1; } }
stbi__get8: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x10],RDI MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0xc0] MOV RCX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RCX + 0xc8] JNC 0x0016a1f4 MOV RCX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RCX + 0xc0] MOV RDX,RAX ADD RDX,0x1 MOV qword ptr [RCX + 0xc0],RDX MOV AL,byte ptr [RAX] MOV byte ptr [RBP + -0x1],AL JMP 0x0016a22b LAB_0016a1f4: MOV RAX,qword ptr [RBP + -0x10] CMP dword ptr [RAX + 0x30],0x0 JZ 0x0016a227 MOV RDI,qword ptr [RBP + -0x10] CALL 0x00166350 MOV RCX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RCX + 0xc0] MOV RDX,RAX ADD RDX,0x1 MOV qword ptr [RCX + 0xc0],RDX MOV AL,byte ptr [RAX] MOV byte ptr [RBP + -0x1],AL JMP 0x0016a22b LAB_0016a227: MOV byte ptr [RBP + -0x1],0x0 LAB_0016a22b: MOV AL,byte ptr [RBP + -0x1] ADD RSP,0x10 POP RBP RET
int1 stbi__get8(long param_1) { int1 *puVar1; int1 local_9; if (*(ulong *)(param_1 + 0xc0) < *(ulong *)(param_1 + 200)) { puVar1 = *(int1 **)(param_1 + 0xc0); *(int1 **)(param_1 + 0xc0) = puVar1 + 1; local_9 = *puVar1; } else if (*(int *)(param_1 + 0x30) == 0) { local_9 = 0; } else { stbi__refill_buffer(param_1); puVar1 = *(int1 **)(param_1 + 0xc0); *(int1 **)(param_1 + 0xc0) = puVar1 + 1; local_9 = *puVar1; } return local_9; }
3,564
stbi__get8
dmazzella[P]pylunasvg/lunasvg/plutovg/source/plutovg-stb-image.h
stbi_inline static stbi_uc stbi__get8(stbi__context *s) { if (s->img_buffer < s->img_buffer_end) return *s->img_buffer++; if (s->read_from_callbacks) { stbi__refill_buffer(s); return *s->img_buffer++; } return 0; }
O1
c
stbi__get8: pushq %rbx movq %rdi, %rbx movq 0xc0(%rdi), %rax cmpq 0xc8(%rdi), %rax jb 0x3568b cmpl $0x0, 0x30(%rbx) je 0x3569a movq %rbx, %rdi callq 0x2e10b movq 0xc0(%rbx), %rax leaq 0x1(%rax), %rcx movq %rcx, 0xc0(%rbx) movb (%rax), %al popq %rbx retq xorl %eax, %eax jmp 0x35698
stbi__get8: push rbx mov rbx, rdi mov rax, [rdi+0C0h] cmp rax, [rdi+0C8h] jb short loc_3568B cmp dword ptr [rbx+30h], 0 jz short loc_3569A mov rdi, rbx call stbi__refill_buffer mov rax, [rbx+0C0h] loc_3568B: lea rcx, [rax+1] mov [rbx+0C0h], rcx mov al, [rax] loc_35698: pop rbx retn loc_3569A: xor eax, eax jmp short loc_35698
char stbi__get8(long long a1) { unsigned long long v1; // rax v1 = *(_QWORD *)(a1 + 192); if ( v1 < *(_QWORD *)(a1 + 200) ) goto LABEL_4; if ( *(_DWORD *)(a1 + 48) ) { stbi__refill_buffer(a1); v1 = *(_QWORD *)(a1 + 192); LABEL_4: *(_QWORD *)(a1 + 192) = v1 + 1; return *(_BYTE *)v1; } return 0; }
stbi__get8: PUSH RBX MOV RBX,RDI MOV RAX,qword ptr [RDI + 0xc0] CMP RAX,qword ptr [RDI + 0xc8] JC 0x0013568b CMP dword ptr [RBX + 0x30],0x0 JZ 0x0013569a MOV RDI,RBX CALL 0x0012e10b MOV RAX,qword ptr [RBX + 0xc0] LAB_0013568b: LEA RCX,[RAX + 0x1] MOV qword ptr [RBX + 0xc0],RCX MOV AL,byte ptr [RAX] LAB_00135698: POP RBX RET LAB_0013569a: XOR EAX,EAX JMP 0x00135698
int8 stbi__get8(long param_1) { int1 *puVar1; puVar1 = *(int1 **)(param_1 + 0xc0); if (*(int1 **)(param_1 + 200) <= puVar1) { if (*(int *)(param_1 + 0x30) == 0) { return 0; } stbi__refill_buffer(param_1); puVar1 = *(int1 **)(param_1 + 0xc0); } *(int1 **)(param_1 + 0xc0) = puVar1 + 1; return CONCAT71((int7)((ulong)puVar1 >> 8),*puVar1); }
3,565
translog_read_record_header
eloqsql/storage/maria/ma_loghandler.c
int translog_read_record_header(LSN lsn, TRANSLOG_HEADER_BUFFER *buff) { TRANSLOG_PAGE_SIZE_BUFF psize_buff; uchar *page; translog_size_t res, page_offset= LSN_OFFSET(lsn) % TRANSLOG_PAGE_SIZE; PAGECACHE_BLOCK_LINK *direct_link; TRANSLOG_ADDRESS addr; TRANSLOG_VALIDATOR_DATA data; DBUG_ENTER("translog_read_record_header"); DBUG_PRINT("enter", ("LSN: " LSN_FMT, LSN_IN_PARTS(lsn))); DBUG_ASSERT(LSN_OFFSET(lsn) % TRANSLOG_PAGE_SIZE != 0); DBUG_ASSERT(translog_status == TRANSLOG_OK || translog_status == TRANSLOG_READONLY); buff->lsn= lsn; buff->groups_no= 0; data.addr= &addr; data.was_recovered= 0; addr= lsn; addr-= page_offset; /* offset decreasing */ res= (!(page= translog_get_page(&data, psize_buff.buffer, &direct_link))) ? RECHEADER_READ_ERROR : translog_read_record_header_from_buffer(page, page_offset, buff, 0); translog_free_link(direct_link); DBUG_RETURN(res); }
O0
c
translog_read_record_header: pushq %rbp movq %rsp, %rbp subq $0x2050, %rsp # imm = 0x2050 movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x2010(%rbp) movq %rsi, -0x2018(%rbp) movabsq $0xffffffff, %rax # imm = 0xFFFFFFFF andq -0x2010(%rbp), %rax andq $0x1fff, %rax # imm = 0x1FFF movl %eax, -0x2028(%rbp) jmp 0x48c05 jmp 0x48c07 jmp 0x48c09 jmp 0x48c0b jmp 0x48c0d movq -0x2010(%rbp), %rcx movq -0x2018(%rbp), %rax movq %rcx, (%rax) movq -0x2018(%rbp), %rax movl $0x0, 0x418(%rax) leaq -0x2038(%rbp), %rax movq %rax, -0x2048(%rbp) movb $0x0, -0x2040(%rbp) movq -0x2010(%rbp), %rax movq %rax, -0x2038(%rbp) movl -0x2028(%rbp), %eax movl %eax, %ecx movq -0x2038(%rbp), %rax subq %rcx, %rax movq %rax, -0x2038(%rbp) leaq -0x2008(%rbp), %rsi leaq -0x2048(%rbp), %rdi leaq -0x2030(%rbp), %rdx callq 0x47ce0 movq %rax, -0x2020(%rbp) cmpq $0x0, %rax jne 0x48c9f movl $0xffffffff, %eax # imm = 0xFFFFFFFF movl %eax, -0x204c(%rbp) jmp 0x48cc3 movq -0x2020(%rbp), %rdi movl -0x2028(%rbp), %eax movq -0x2018(%rbp), %rdx xorl %ecx, %ecx movzwl %ax, %esi callq 0x4a920 movl %eax, -0x204c(%rbp) movl -0x204c(%rbp), %eax movl %eax, -0x2024(%rbp) movq -0x2030(%rbp), %rdi callq 0x4a8c0 movl -0x2024(%rbp), %eax movl %eax, -0x2050(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x48d08 movl -0x2050(%rbp), %eax addq $0x2050, %rsp # imm = 0x2050 popq %rbp retq callq 0x2a290 nopl (%rax)
translog_read_record_header: push rbp mov rbp, rsp sub rsp, 2050h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_2010], rdi mov [rbp+var_2018], rsi mov rax, 0FFFFFFFFh and rax, [rbp+var_2010] and rax, 1FFFh mov [rbp+var_2028], eax jmp short $+2 loc_48C05: jmp short $+2 loc_48C07: jmp short $+2 loc_48C09: jmp short $+2 loc_48C0B: jmp short $+2 loc_48C0D: mov rcx, [rbp+var_2010] mov rax, [rbp+var_2018] mov [rax], rcx mov rax, [rbp+var_2018] mov dword ptr [rax+418h], 0 lea rax, [rbp+var_2038] mov [rbp+var_2048], rax mov [rbp+var_2040], 0 mov rax, [rbp+var_2010] mov [rbp+var_2038], rax mov eax, [rbp+var_2028] mov ecx, eax mov rax, [rbp+var_2038] sub rax, rcx mov [rbp+var_2038], rax lea rsi, [rbp+var_2008] lea rdi, [rbp+var_2048] lea rdx, [rbp+var_2030] call translog_get_page mov [rbp+var_2020], rax cmp rax, 0 jnz short loc_48C9F mov eax, 0FFFFFFFFh mov [rbp+var_204C], eax jmp short loc_48CC3 loc_48C9F: mov rdi, [rbp+var_2020] mov eax, [rbp+var_2028] mov rdx, [rbp+var_2018] xor ecx, ecx movzx esi, ax call translog_read_record_header_from_buffer mov [rbp+var_204C], eax loc_48CC3: mov eax, [rbp+var_204C] mov [rbp+var_2024], eax mov rdi, [rbp+var_2030] call translog_free_link mov eax, [rbp+var_2024] mov [rbp+var_2050], eax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_48D08 mov eax, [rbp+var_2050] add rsp, 2050h pop rbp retn loc_48D08: call ___stack_chk_fail
long long translog_read_record_header(long long a1, _QWORD *a2) { int record_header_from_buffer; // [rsp+4h] [rbp-204Ch] long long *v4; // [rsp+8h] [rbp-2048h] BYREF char v5; // [rsp+10h] [rbp-2040h] long long v6; // [rsp+18h] [rbp-2038h] BYREF long long v7; // [rsp+20h] [rbp-2030h] BYREF unsigned int v8; // [rsp+28h] [rbp-2028h] unsigned int v9; // [rsp+2Ch] [rbp-2024h] long long page; // [rsp+30h] [rbp-2020h] _QWORD *v11; // [rsp+38h] [rbp-2018h] long long v12; // [rsp+40h] [rbp-2010h] _BYTE v13[8192]; // [rsp+48h] [rbp-2008h] BYREF unsigned long long v14; // [rsp+2048h] [rbp-8h] v14 = __readfsqword(0x28u); v12 = a1; v11 = a2; v8 = a1 & 0x1FFF; *a2 = a1; *((_DWORD *)v11 + 262) = 0; v4 = &v6; v5 = 0; v6 = v12 - v8; page = translog_get_page(&v4, (long long)v13, &v7); if ( page ) record_header_from_buffer = translog_read_record_header_from_buffer(page, (unsigned __int16)v8, v11, 0LL); else record_header_from_buffer = -1; v9 = record_header_from_buffer; translog_free_link(v7); return v9; }
translog_read_record_header: PUSH RBP MOV RBP,RSP SUB RSP,0x2050 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x2010],RDI MOV qword ptr [RBP + -0x2018],RSI MOV RAX,0xffffffff AND RAX,qword ptr [RBP + -0x2010] AND RAX,0x1fff MOV dword ptr [RBP + -0x2028],EAX JMP 0x00148c05 LAB_00148c05: JMP 0x00148c07 LAB_00148c07: JMP 0x00148c09 LAB_00148c09: JMP 0x00148c0b LAB_00148c0b: JMP 0x00148c0d LAB_00148c0d: MOV RCX,qword ptr [RBP + -0x2010] MOV RAX,qword ptr [RBP + -0x2018] MOV qword ptr [RAX],RCX MOV RAX,qword ptr [RBP + -0x2018] MOV dword ptr [RAX + 0x418],0x0 LEA RAX,[RBP + -0x2038] MOV qword ptr [RBP + -0x2048],RAX MOV byte ptr [RBP + -0x2040],0x0 MOV RAX,qword ptr [RBP + -0x2010] MOV qword ptr [RBP + -0x2038],RAX MOV EAX,dword ptr [RBP + -0x2028] MOV ECX,EAX MOV RAX,qword ptr [RBP + -0x2038] SUB RAX,RCX MOV qword ptr [RBP + -0x2038],RAX LEA RSI,[RBP + -0x2008] LEA RDI,[RBP + -0x2048] LEA RDX,[RBP + -0x2030] CALL 0x00147ce0 MOV qword ptr [RBP + -0x2020],RAX CMP RAX,0x0 JNZ 0x00148c9f MOV EAX,0xffffffff MOV dword ptr [RBP + -0x204c],EAX JMP 0x00148cc3 LAB_00148c9f: MOV RDI,qword ptr [RBP + -0x2020] MOV EAX,dword ptr [RBP + -0x2028] MOV RDX,qword ptr [RBP + -0x2018] XOR ECX,ECX MOVZX ESI,AX CALL 0x0014a920 MOV dword ptr [RBP + -0x204c],EAX LAB_00148cc3: MOV EAX,dword ptr [RBP + -0x204c] MOV dword ptr [RBP + -0x2024],EAX MOV RDI,qword ptr [RBP + -0x2030] CALL 0x0014a8c0 MOV EAX,dword ptr [RBP + -0x2024] MOV dword ptr [RBP + -0x2050],EAX MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x00148d08 MOV EAX,dword ptr [RBP + -0x2050] ADD RSP,0x2050 POP RBP RET LAB_00148d08: CALL 0x0012a290
int4 translog_read_record_header(long param_1,long *param_2) { long in_FS_OFFSET; int4 local_2054; long *local_2050; int1 local_2048; long local_2040; int8 local_2038; uint local_2030; int4 local_202c; long local_2028; long *local_2020; long local_2018; int1 local_2010 [8192]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); local_2030 = (uint)param_1 & 0x1fff; *param_2 = param_1; *(int4 *)(param_2 + 0x83) = 0; local_2050 = &local_2040; local_2048 = 0; local_2040 = param_1 - (ulong)local_2030; local_2020 = param_2; local_2018 = param_1; local_2028 = translog_get_page(&local_2050,local_2010,&local_2038); if (local_2028 == 0) { local_2054 = 0xffffffff; } else { local_2054 = translog_read_record_header_from_buffer (local_2028,local_2030 & 0xffff,local_2020,0); } local_202c = local_2054; translog_free_link(local_2038); if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return local_202c; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
3,566
translog_read_record_header
eloqsql/storage/maria/ma_loghandler.c
int translog_read_record_header(LSN lsn, TRANSLOG_HEADER_BUFFER *buff) { TRANSLOG_PAGE_SIZE_BUFF psize_buff; uchar *page; translog_size_t res, page_offset= LSN_OFFSET(lsn) % TRANSLOG_PAGE_SIZE; PAGECACHE_BLOCK_LINK *direct_link; TRANSLOG_ADDRESS addr; TRANSLOG_VALIDATOR_DATA data; DBUG_ENTER("translog_read_record_header"); DBUG_PRINT("enter", ("LSN: " LSN_FMT, LSN_IN_PARTS(lsn))); DBUG_ASSERT(LSN_OFFSET(lsn) % TRANSLOG_PAGE_SIZE != 0); DBUG_ASSERT(translog_status == TRANSLOG_OK || translog_status == TRANSLOG_READONLY); buff->lsn= lsn; buff->groups_no= 0; data.addr= &addr; data.was_recovered= 0; addr= lsn; addr-= page_offset; /* offset decreasing */ res= (!(page= translog_get_page(&data, psize_buff.buffer, &direct_link))) ? RECHEADER_READ_ERROR : translog_read_record_header_from_buffer(page, page_offset, buff, 0); translog_free_link(direct_link); DBUG_RETURN(res); }
O3
c
translog_read_record_header: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx subq $0x2030, %rsp # imm = 0x2030 movq %rsi, %rbx movq %rdi, %r14 movq %fs:0x28, %rax movq %rax, -0x18(%rbp) movq %rdi, (%rsi) movl $0x0, 0x418(%rsi) leaq -0x2028(%rbp), %rax leaq -0x2038(%rbp), %rdi movq %rax, (%rdi) movb $0x0, 0x8(%rdi) movq %r14, %rcx andq $-0x2000, %rcx # imm = 0xE000 movq %rcx, (%rax) leaq -0x2018(%rbp), %rsi leaq -0x2020(%rbp), %rdx callq 0x44bdc testq %rax, %rax je 0x4558d andl $0x1fff, %r14d # imm = 0x1FFF movq %rax, %rdi movl %r14d, %esi movq %rbx, %rdx xorl %ecx, %ecx callq 0x466d0 movl %eax, %ebx jmp 0x45592 movl $0xffffffff, %ebx # imm = 0xFFFFFFFF movq -0x2020(%rbp), %rdi callq 0x4669e movq %fs:0x28, %rax cmpq -0x18(%rbp), %rax jne 0x455bb movl %ebx, %eax addq $0x2030, %rsp # imm = 0x2030 popq %rbx popq %r14 popq %rbp retq callq 0x2a280
translog_read_record_header: push rbp mov rbp, rsp push r14 push rbx sub rsp, 2030h mov rbx, rsi mov r14, rdi mov rax, fs:28h mov [rbp+var_18], rax mov [rsi], rdi mov dword ptr [rsi+418h], 0 lea rax, [rbp+var_2028] lea rdi, [rbp+var_2038] mov [rdi], rax mov byte ptr [rdi+8], 0 mov rcx, r14 and rcx, 0FFFFFFFFFFFFE000h mov [rax], rcx lea rsi, [rbp+var_2018] lea rdx, [rbp+var_2020] call translog_get_page test rax, rax jz short loc_4558D and r14d, 1FFFh mov rdi, rax mov esi, r14d mov rdx, rbx xor ecx, ecx call translog_read_record_header_from_buffer mov ebx, eax jmp short loc_45592 loc_4558D: mov ebx, 0FFFFFFFFh loc_45592: mov rdi, [rbp+var_2020] call translog_free_link mov rax, fs:28h cmp rax, [rbp+var_18] jnz short loc_455BB mov eax, ebx add rsp, 2030h pop rbx pop r14 pop rbp retn loc_455BB: call ___stack_chk_fail
long long translog_read_record_header(long long a1, long long a2) { long long page; // rax unsigned int record_header_from_buffer; // ebx unsigned long long *v5; // [rsp+8h] [rbp-2038h] BYREF char v6; // [rsp+10h] [rbp-2030h] unsigned long long v7; // [rsp+18h] [rbp-2028h] BYREF long long v8; // [rsp+20h] [rbp-2020h] BYREF _BYTE v9[8192]; // [rsp+28h] [rbp-2018h] BYREF unsigned long long v10; // [rsp+2028h] [rbp-18h] v10 = __readfsqword(0x28u); *(_QWORD *)a2 = a1; *(_DWORD *)(a2 + 1048) = 0; v5 = &v7; v6 = 0; v7 = a1 & 0xFFFFFFFFFFFFE000LL; page = translog_get_page((long long **)&v5, (long long)v9, &v8); if ( page ) record_header_from_buffer = translog_read_record_header_from_buffer(page, a1 & 0x1FFF, a2, 0LL); else record_header_from_buffer = -1; translog_free_link(v8); return record_header_from_buffer; }
translog_read_record_header: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX SUB RSP,0x2030 MOV RBX,RSI MOV R14,RDI MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x18],RAX MOV qword ptr [RSI],RDI MOV dword ptr [RSI + 0x418],0x0 LEA RAX,[RBP + -0x2028] LEA RDI,[RBP + -0x2038] MOV qword ptr [RDI],RAX MOV byte ptr [RDI + 0x8],0x0 MOV RCX,R14 AND RCX,-0x2000 MOV qword ptr [RAX],RCX LEA RSI,[RBP + -0x2018] LEA RDX,[RBP + -0x2020] CALL 0x00144bdc TEST RAX,RAX JZ 0x0014558d AND R14D,0x1fff MOV RDI,RAX MOV ESI,R14D MOV RDX,RBX XOR ECX,ECX CALL 0x001466d0 MOV EBX,EAX JMP 0x00145592 LAB_0014558d: MOV EBX,0xffffffff LAB_00145592: MOV RDI,qword ptr [RBP + -0x2020] CALL 0x0014669e MOV RAX,qword ptr FS:[0x28] CMP RAX,qword ptr [RBP + -0x18] JNZ 0x001455bb MOV EAX,EBX ADD RSP,0x2030 POP RBX POP R14 POP RBP RET LAB_001455bb: CALL 0x0012a280
int4 translog_read_record_header(ulong param_1,ulong *param_2) { int4 uVar1; long lVar2; long in_FS_OFFSET; ulong *local_2040; int1 local_2038; ulong local_2030; int8 local_2028; int1 local_2020 [8192]; long local_20; local_20 = *(long *)(in_FS_OFFSET + 0x28); *param_2 = param_1; *(int4 *)(param_2 + 0x83) = 0; local_2040 = &local_2030; local_2038 = 0; local_2030 = param_1 & 0xffffffffffffe000; lVar2 = translog_get_page(&local_2040,local_2020,&local_2028); if (lVar2 == 0) { uVar1 = 0xffffffff; } else { uVar1 = translog_read_record_header_from_buffer(lVar2,(uint)param_1 & 0x1fff,param_2,0); } translog_free_link(local_2028); if (*(long *)(in_FS_OFFSET + 0x28) == local_20) { return uVar1; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
3,567
my_hash_insert
eloqsql/mysys/hash.c
my_bool my_hash_insert(HASH *info, const uchar *record) { int flag; size_t idx, halfbuff, first_index; size_t length; my_hash_value_type current_hash_nr, UNINIT_VAR(rec_hash_nr), UNINIT_VAR(rec2_hash_nr); uchar *UNINIT_VAR(rec_data),*UNINIT_VAR(rec2_data), *key; HASH_LINK *data,*empty,*UNINIT_VAR(gpos),*UNINIT_VAR(gpos2),*pos; key= (uchar*) my_hash_key(info, record, &length, 1); current_hash_nr= info->hash_function(info->charset, key, length); if (info->flags & HASH_UNIQUE) { if (my_hash_search_using_hash_value(info, current_hash_nr, key, length)) return(TRUE); /* Duplicate entry */ } flag=0; if (!(empty=(HASH_LINK*) alloc_dynamic(&info->array))) return(TRUE); /* No more memory */ data=dynamic_element(&info->array,0,HASH_LINK*); halfbuff= info->blength >> 1; idx=first_index=info->records-halfbuff; if (idx != info->records) /* If some records */ { do { my_hash_value_type hash_nr; pos=data+idx; hash_nr= pos->hash_nr; if (flag == 0) /* First loop; Check if ok */ if (my_hash_mask(hash_nr, info->blength, info->records) != first_index) break; if (!(hash_nr & halfbuff)) { /* Key will not move */ if (!(flag & LOWFIND)) { if (flag & HIGHFIND) { flag= LOWFIND | HIGHFIND; /* key shall be moved to the current empty position */ gpos= empty; rec_data= pos->data; rec_hash_nr= pos->hash_nr; empty=pos; /* This place is now free */ } else { flag= LOWFIND | LOWUSED; /* key isn't changed */ gpos= pos; rec_data= pos->data; rec_hash_nr= pos->hash_nr; } } else { if (!(flag & LOWUSED)) { /* Change link of previous LOW-key */ gpos->data= rec_data; gpos->hash_nr= rec_hash_nr; gpos->next= (uint) (pos-data); flag= (flag & HIGHFIND) | (LOWFIND | LOWUSED); } gpos= pos; rec_data= pos->data; rec_hash_nr= pos->hash_nr; } } else { /* key will be moved */ if (!(flag & HIGHFIND)) { flag= (flag & LOWFIND) | HIGHFIND; /* key shall be moved to the last (empty) position */ gpos2= empty; empty= pos; rec2_data= pos->data; rec2_hash_nr= pos->hash_nr; } else { if (!(flag & HIGHUSED)) { /* Change link of previous hash-key and save */ gpos2->data= rec2_data; gpos2->hash_nr= rec2_hash_nr; gpos2->next= (uint) (pos-data); flag= (flag & LOWFIND) | (HIGHFIND | HIGHUSED); } gpos2= pos; rec2_data= pos->data; rec2_hash_nr= pos->hash_nr; } } } while ((idx=pos->next) != NO_RECORD); if ((flag & (LOWFIND | LOWUSED)) == LOWFIND) { gpos->data= rec_data; gpos->hash_nr= rec_hash_nr; gpos->next= NO_RECORD; } if ((flag & (HIGHFIND | HIGHUSED)) == HIGHFIND) { gpos2->data= rec2_data; gpos2->hash_nr= rec2_hash_nr; gpos2->next= NO_RECORD; } } idx= my_hash_mask(current_hash_nr, info->blength, info->records + 1); pos= data+idx; /* Check if we are at the empty position */ if (pos == empty) { pos->next=NO_RECORD; } else { /* Move conflicting record to empty position (last) */ empty[0]= pos[0]; /* Check if the moved record was in same hash-nr family */ gpos= data + my_hash_rec_mask(pos, info->blength, info->records + 1); if (pos == gpos) { /* Point to moved record */ pos->next= (uint32) (empty - data); } else { pos->next= NO_RECORD; movelink(data,(uint) (pos-data),(uint) (gpos-data),(uint) (empty-data)); } } pos->data= (uchar*) record; pos->hash_nr= current_hash_nr; if (++info->records == info->blength) info->blength+= info->blength; return(0); }
O3
c
my_hash_insert: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x38, %rsp movq %rsi, %r14 movq %rdi, %rbx movq 0x50(%rdi), %rax testq %rax, %rax je 0x24f81 leaq -0x50(%rbp), %r15 movq %r14, %rdi movq %r15, %rsi movl $0x1, %edx callq *%rax movq %rax, %r12 movq (%r15), %rdx jmp 0x24f8f movq 0x8(%rbx), %rdx movq %rdx, -0x50(%rbp) movq (%rbx), %r12 addq %r14, %r12 movq 0x68(%rbx), %rdi movq %r12, %rsi callq *0x58(%rbx) movl %eax, %r15d testb $0x1, 0x20(%rbx) je 0x24fc6 movq -0x50(%rbp), %rcx leaq -0x5c(%rbp), %r8 movq %rbx, %rdi movl %r15d, %esi movq %r12, %rdx callq 0x24d61 movq %rax, %rcx movb $0x1, %al testq %rcx, %rcx jne 0x2523d leaq 0x28(%rbx), %rdi callq 0x25c8c testq %rax, %rax je 0x25174 movq %rax, %rdi movl $0xffffffff, %edx # imm = 0xFFFFFFFF movq 0x28(%rbx), %rcx movq 0x10(%rbx), %rsi cmpq $0x2, %rsi jb 0x25186 movl %r15d, -0x2c(%rbp) movq %r14, -0x48(%rbp) movq 0x18(%rbx), %r12 shrq %rsi subq %rsi, %r12 xorl %r8d, %r8d movq %r12, -0x58(%rbp) movq %rdi, %r14 movq %r12, %rax shlq $0x4, %rax movl 0x4(%rcx,%rax), %r10d testl %r8d, %r8d jne 0x2505e movq 0x10(%rbx), %rdi leal (%rdi,%rdx), %r9d movq %rsi, %rdx movq %r15, %rsi movl %r11d, %r15d movl %r10d, %r11d andl %r9d, %r11d shrq %rdi decl %edi andl %r10d, %edi cmpq 0x18(%rbx), %r11 cmovbl %r11d, %edi movl %r15d, %r11d movq %rsi, %r15 movq %rdx, %rsi movl $0xffffffff, %edx # imm = 0xFFFFFFFF cmpq %rdi, -0x58(%rbp) jne 0x2517b addq %rcx, %rax testl %r10d, %esi je 0x25086 testb $0x4, %r8b jne 0x250bd andl $0x1, %r8d orl $0x4, %r8d movq 0x8(%rax), %r15 movl %r10d, %r11d movq %rax, %rdi movq %r14, %r13 jmp 0x25125 testb $0x1, %r8b jne 0x250ea andl $0x4, %r8d movl %r8d, %r9d shrl %r9d addl $0x3, %r9d testl %r8d, %r8d movq %rax, %rdi cmoveq %r14, %rdi cmoveq %rax, %r14 movq 0x8(%rax), %r8 movq %r8, -0x40(%rbp) movl %r10d, -0x30(%rbp) movl %r9d, %r8d movq %r14, -0x38(%rbp) jmp 0x25125 testb $0x8, %r8b jne 0x250db movq %r15, 0x8(%r13) movl %r11d, 0x4(%r13) movl %r12d, (%r13) andl $0x1, %r8d orl $0xc, %r8d movl 0x4(%rax), %r10d movq 0x8(%rax), %r15 movl %r10d, %r11d movq %r14, %rdi movq %rax, %r13 jmp 0x25125 testb $0x2, %r8b jne 0x25112 movq -0x40(%rbp), %rdi movq -0x38(%rbp), %r9 movq %rdi, 0x8(%r9) movl -0x30(%rbp), %edi movl %edi, 0x4(%r9) movl %r12d, (%r9) andl $0x4, %r8d orl $0x3, %r8d movl 0x4(%rax), %r10d movq 0x8(%rax), %rdi movq %rdi, -0x40(%rbp) movl %r10d, -0x30(%rbp) movq %r14, %rdi movq %rax, -0x38(%rbp) movl (%rax), %r12d cmpq %rdx, %r12 jne 0x2500b movl %r8d, %eax andl $0x3, %eax cmpl $0x1, %eax jne 0x25154 movq -0x40(%rbp), %rax movq -0x38(%rbp), %rsi movq %rax, 0x8(%rsi) movl -0x30(%rbp), %eax movl %eax, 0x4(%rsi) movl $0xffffffff, (%rsi) # imm = 0xFFFFFFFF andl $0xc, %r8d cmpl $0x4, %r8d movq -0x48(%rbp), %r14 jne 0x25182 movq %r15, 0x8(%r13) movl %r11d, 0x4(%r13) movl $0xffffffff, (%r13) # imm = 0xFFFFFFFF jmp 0x25182 movb $0x1, %al jmp 0x2523d movq %r14, %rdi movq -0x48(%rbp), %r14 movl -0x2c(%rbp), %r15d movq 0x10(%rbx), %rax movq 0x18(%rbx), %rsi incq %rsi leal (%rax,%rdx), %r8d andl %r15d, %r8d shrq %rax decl %eax andl %r15d, %eax cmpq %rsi, %r8 cmovbl %r8d, %eax movq %rax, %rsi shlq $0x4, %rsi addq %rcx, %rsi cmpq %rdi, %rsi je 0x251f1 movups (%rsi), %xmm0 movups %xmm0, (%rdi) movq 0x10(%rbx), %r8 movq 0x18(%rbx), %r9 incq %r9 movl 0x4(%rsi), %r10d addl %r8d, %edx andl %r10d, %edx shrq %r8 decl %r8d andl %r10d, %r8d cmpq %r9, %rdx cmovbl %edx, %r8d cmpl %r8d, %eax jne 0x251f9 subq %rcx, %rdi shrq $0x4, %rdi movl %edi, (%rsi) jmp 0x2521b movl $0xffffffff, (%rsi) # imm = 0xFFFFFFFF jmp 0x2521b movl $0xffffffff, (%rsi) # imm = 0xFFFFFFFF subq %rcx, %rdi shrq $0x4, %rdi movl %r8d, %edx shlq $0x4, %rdx movl (%rcx,%rdx), %r8d cmpl %eax, %r8d jne 0x25206 addq %rdx, %rcx movl %edi, (%rcx) movq %r14, 0x8(%rsi) movl %r15d, 0x4(%rsi) movq 0x18(%rbx), %rax incq %rax movq %rax, 0x18(%rbx) cmpq 0x10(%rbx), %rax jne 0x2523b addq %rax, %rax movq %rax, 0x10(%rbx) xorl %eax, %eax addq $0x38, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_hash_insert: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 38h mov r14, rsi mov rbx, rdi mov rax, [rdi+50h] test rax, rax jz short loc_24F81 lea r15, [rbp+var_50] mov rdi, r14 mov rsi, r15 mov edx, 1 call rax mov r12, rax mov rdx, [r15] jmp short loc_24F8F loc_24F81: mov rdx, [rbx+8] mov [rbp+var_50], rdx mov r12, [rbx] add r12, r14 loc_24F8F: mov rdi, [rbx+68h] mov rsi, r12 call qword ptr [rbx+58h] mov r15d, eax test byte ptr [rbx+20h], 1 jz short loc_24FC6 mov rcx, [rbp+var_50] lea r8, [rbp+var_5C] mov rdi, rbx mov esi, r15d mov rdx, r12 call my_hash_first_from_hash_value mov rcx, rax mov al, 1 test rcx, rcx jnz loc_2523D loc_24FC6: lea rdi, [rbx+28h] call alloc_dynamic test rax, rax jz loc_25174 mov rdi, rax mov edx, 0FFFFFFFFh mov rcx, [rbx+28h] mov rsi, [rbx+10h] cmp rsi, 2 jb loc_25186 mov [rbp+var_2C], r15d mov [rbp+var_48], r14 mov r12, [rbx+18h] shr rsi, 1 sub r12, rsi xor r8d, r8d mov [rbp+var_58], r12 loc_2500B: mov r14, rdi mov rax, r12 shl rax, 4 mov r10d, [rcx+rax+4] test r8d, r8d jnz short loc_2505E mov rdi, [rbx+10h] lea r9d, [rdi+rdx] mov rdx, rsi mov rsi, r15 mov r15d, r11d mov r11d, r10d and r11d, r9d shr rdi, 1 dec edi and edi, r10d cmp r11, [rbx+18h] cmovb edi, r11d mov r11d, r15d mov r15, rsi mov rsi, rdx mov edx, 0FFFFFFFFh cmp [rbp+var_58], rdi jnz loc_2517B loc_2505E: add rax, rcx test esi, r10d jz short loc_25086 test r8b, 4 jnz short loc_250BD and r8d, 1 or r8d, 4 mov r15, [rax+8] mov r11d, r10d mov rdi, rax mov r13, r14 jmp loc_25125 loc_25086: test r8b, 1 jnz short loc_250EA and r8d, 4 mov r9d, r8d shr r9d, 1 add r9d, 3 test r8d, r8d mov rdi, rax cmovz rdi, r14 cmovz r14, rax mov r8, [rax+8] mov [rbp+var_40], r8 mov [rbp+var_30], r10d mov r8d, r9d mov [rbp+var_38], r14 jmp short loc_25125 loc_250BD: test r8b, 8 jnz short loc_250DB mov [r13+8], r15 mov [r13+4], r11d mov [r13+0], r12d and r8d, 1 or r8d, 0Ch mov r10d, [rax+4] loc_250DB: mov r15, [rax+8] mov r11d, r10d mov rdi, r14 mov r13, rax jmp short loc_25125 loc_250EA: test r8b, 2 jnz short loc_25112 mov rdi, [rbp+var_40] mov r9, [rbp+var_38] mov [r9+8], rdi mov edi, [rbp+var_30] mov [r9+4], edi mov [r9], r12d and r8d, 4 or r8d, 3 mov r10d, [rax+4] loc_25112: mov rdi, [rax+8] mov [rbp+var_40], rdi mov [rbp+var_30], r10d mov rdi, r14 mov [rbp+var_38], rax loc_25125: mov r12d, [rax] cmp r12, rdx jnz loc_2500B mov eax, r8d and eax, 3 cmp eax, 1 jnz short loc_25154 mov rax, [rbp+var_40] mov rsi, [rbp+var_38] mov [rsi+8], rax mov eax, [rbp+var_30] mov [rsi+4], eax mov dword ptr [rsi], 0FFFFFFFFh loc_25154: and r8d, 0Ch cmp r8d, 4 mov r14, [rbp+var_48] jnz short loc_25182 mov [r13+8], r15 mov [r13+4], r11d mov dword ptr [r13+0], 0FFFFFFFFh jmp short loc_25182 loc_25174: mov al, 1 jmp loc_2523D loc_2517B: mov rdi, r14 mov r14, [rbp+var_48] loc_25182: mov r15d, [rbp+var_2C] loc_25186: mov rax, [rbx+10h] mov rsi, [rbx+18h] inc rsi lea r8d, [rax+rdx] and r8d, r15d shr rax, 1 dec eax and eax, r15d cmp r8, rsi cmovb eax, r8d mov rsi, rax shl rsi, 4 add rsi, rcx cmp rsi, rdi jz short loc_251F1 movups xmm0, xmmword ptr [rsi] movups xmmword ptr [rdi], xmm0 mov r8, [rbx+10h] mov r9, [rbx+18h] inc r9 mov r10d, [rsi+4] add edx, r8d and edx, r10d shr r8, 1 dec r8d and r8d, r10d cmp rdx, r9 cmovb r8d, edx cmp eax, r8d jnz short loc_251F9 sub rdi, rcx shr rdi, 4 mov [rsi], edi jmp short loc_2521B loc_251F1: mov dword ptr [rsi], 0FFFFFFFFh jmp short loc_2521B loc_251F9: mov dword ptr [rsi], 0FFFFFFFFh sub rdi, rcx shr rdi, 4 loc_25206: mov edx, r8d shl rdx, 4 mov r8d, [rcx+rdx] cmp r8d, eax jnz short loc_25206 add rcx, rdx mov [rcx], edi loc_2521B: mov [rsi+8], r14 mov [rsi+4], r15d mov rax, [rbx+18h] inc rax mov [rbx+18h], rax cmp rax, [rbx+10h] jnz short loc_2523B add rax, rax mov [rbx+10h], rax loc_2523B: xor eax, eax loc_2523D: add rsp, 38h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
char my_hash_insert(long long a1, long long a2) { _OWORD *v2; // r13 long long v3; // r14 long long ( *v5)(long long, long long *, long long); // rax long long v6; // r12 long long v7; // rdx unsigned int v8; // eax long long v9; // r15 long long v10; // rcx char result; // al long long v12; // rax unsigned int v13; // r11d _OWORD *v14; // rdi long long v15; // rcx unsigned long long v16; // rsi unsigned long long v17; // rsi unsigned long long v18; // r12 int v19; // r8d _OWORD *v20; // r14 unsigned int v21; // r10d unsigned long long v22; // rdi unsigned long long v23; // rdx long long v24; // rsi unsigned int v25; // r15d unsigned long long v26; // r11 long long v27; // rdi unsigned int *v28; // rax unsigned int v29; // r8d _DWORD *v30; // r9 _DWORD *v31; // rsi unsigned long long v32; // rax unsigned long long v33; // r8 long long v34; // rax long long v35; // rsi unsigned long long v36; // r8 int v37; // r10d unsigned long long v38; // rdx unsigned int v39; // r8d unsigned long long v40; // rdi long long v41; // rdx long long v42; // rax unsigned int v43; // [rsp+4h] [rbp-5Ch] BYREF unsigned long long v44; // [rsp+8h] [rbp-58h] long long v45; // [rsp+10h] [rbp-50h] BYREF long long v46; // [rsp+18h] [rbp-48h] long long v47; // [rsp+20h] [rbp-40h] _OWORD *v48; // [rsp+28h] [rbp-38h] unsigned int v49; // [rsp+30h] [rbp-30h] int v50; // [rsp+34h] [rbp-2Ch] v3 = a2; v5 = *(long long ( **)(long long, long long *, long long))(a1 + 80); if ( v5 ) { v6 = v5(a2, &v45, 1LL); v7 = v45; } else { v7 = *(_QWORD *)(a1 + 8); v45 = v7; v6 = a2 + *(_QWORD *)a1; } v8 = (*(long long ( **)(_QWORD, long long, long long))(a1 + 88))(*(_QWORD *)(a1 + 104), v6, v7); v9 = v8; if ( (*(_BYTE *)(a1 + 32) & 1) == 0 || (v10 = my_hash_first_from_hash_value((_QWORD *)a1, v8, v6, v45, &v43), result = 1, !v10) ) { v12 = alloc_dynamic(a1 + 40); if ( v12 ) { v14 = (_OWORD *)v12; v15 = *(_QWORD *)(a1 + 40); v16 = *(_QWORD *)(a1 + 16); if ( v16 >= 2 ) { v50 = v9; v46 = v3; v17 = v16 >> 1; v18 = *(_QWORD *)(a1 + 24) - v17; v19 = 0; v44 = v18; do { v20 = v14; v21 = *(_DWORD *)(v15 + 16 * v18 + 4); if ( !v19 ) { v22 = *(_QWORD *)(a1 + 16); v23 = v17; v24 = v9; v25 = v13; v26 = ((_DWORD)v22 - 1) & v21; v27 = v21 & ((unsigned int)(v22 >> 1) - 1); if ( v26 < *(_QWORD *)(a1 + 24) ) v27 = (unsigned int)v26; v13 = v25; v9 = v24; v17 = v23; if ( v44 != v27 ) { v14 = v20; v3 = v46; goto LABEL_33; } } v28 = (unsigned int *)(v15 + 16 * v18); if ( (v21 & (unsigned int)v17) != 0 ) { if ( (v19 & 4) != 0 ) { if ( (v19 & 8) == 0 ) { *((_QWORD *)v2 + 1) = v9; *((_DWORD *)v2 + 1) = v13; *(_DWORD *)v2 = v18; v19 = v19 & 1 | 0xC; v21 = v28[1]; } v9 = *((_QWORD *)v28 + 1); v13 = v21; v14 = v20; v2 = (_OWORD *)(v15 + 16 * v18); } else { v19 = v19 & 1 | 4; v9 = *((_QWORD *)v28 + 1); v13 = *(_DWORD *)(v15 + 16 * v18 + 4); v14 = (_OWORD *)(v15 + 16 * v18); v2 = v20; } } else if ( (v19 & 1) != 0 ) { if ( (v19 & 2) == 0 ) { v30 = v48; *((_QWORD *)v48 + 1) = v47; v30[1] = v49; *v30 = v18; v19 = v19 & 4 | 3; v21 = v28[1]; } v47 = *((_QWORD *)v28 + 1); v49 = v21; v14 = v20; v48 = (_OWORD *)(v15 + 16 * v18); } else { v29 = v19 & 4; v14 = (_OWORD *)(v15 + 16 * v18); if ( !v29 ) { v14 = v20; v20 = (_OWORD *)(v15 + 16 * v18); } v47 = *((_QWORD *)v28 + 1); v49 = v21; v19 = (v29 >> 1) + 3; v48 = v20; } v18 = *v28; } while ( v18 != 0xFFFFFFFF ); if ( (v19 & 3) == 1 ) { v31 = v48; *((_QWORD *)v48 + 1) = v47; v31[1] = v49; *v31 = -1; } v3 = v46; if ( (v19 & 0xC) == 4 ) { *((_QWORD *)v2 + 1) = v9; *((_DWORD *)v2 + 1) = v13; *(_DWORD *)v2 = -1; } LABEL_33: LODWORD(v9) = v50; } v32 = *(_QWORD *)(a1 + 16); v33 = (unsigned int)v9 & ((_DWORD)v32 - 1); v34 = (unsigned int)v9 & ((unsigned int)(v32 >> 1) - 1); if ( v33 < *(_QWORD *)(a1 + 24) + 1LL ) v34 = (unsigned int)v33; v35 = v15 + 16 * v34; if ( (_OWORD *)v35 == v14 ) { *(_DWORD *)v35 = -1; } else { *v14 = *(_OWORD *)v35; v36 = *(_QWORD *)(a1 + 16); v37 = *(_DWORD *)(v35 + 4); v38 = v37 & (unsigned int)(v36 - 1); v39 = v37 & ((v36 >> 1) - 1); if ( v38 < *(_QWORD *)(a1 + 24) + 1LL ) v39 = v38; if ( (_DWORD)v34 == v39 ) { *(_DWORD *)v35 = ((unsigned long long)v14 - v15) >> 4; } else { *(_DWORD *)v35 = -1; v40 = ((unsigned long long)v14 - v15) >> 4; do { v41 = 16LL * v39; v39 = *(_DWORD *)(v15 + v41); } while ( v39 != (_DWORD)v34 ); *(_DWORD *)(v41 + v15) = v40; } } *(_QWORD *)(v35 + 8) = v3; *(_DWORD *)(v35 + 4) = v9; v42 = *(_QWORD *)(a1 + 24) + 1LL; *(_QWORD *)(a1 + 24) = v42; if ( v42 == *(_QWORD *)(a1 + 16) ) *(_QWORD *)(a1 + 16) = 2 * v42; return 0; } else { return 1; } } return result; }
my_hash_insert: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x38 MOV R14,RSI MOV RBX,RDI MOV RAX,qword ptr [RDI + 0x50] TEST RAX,RAX JZ 0x00124f81 LEA R15,[RBP + -0x50] MOV RDI,R14 MOV RSI,R15 MOV EDX,0x1 CALL RAX MOV R12,RAX MOV RDX,qword ptr [R15] JMP 0x00124f8f LAB_00124f81: MOV RDX,qword ptr [RBX + 0x8] MOV qword ptr [RBP + -0x50],RDX MOV R12,qword ptr [RBX] ADD R12,R14 LAB_00124f8f: MOV RDI,qword ptr [RBX + 0x68] MOV RSI,R12 CALL qword ptr [RBX + 0x58] MOV R15D,EAX TEST byte ptr [RBX + 0x20],0x1 JZ 0x00124fc6 MOV RCX,qword ptr [RBP + -0x50] LEA R8,[RBP + -0x5c] MOV RDI,RBX MOV ESI,R15D MOV RDX,R12 CALL 0x00124d61 MOV RCX,RAX MOV AL,0x1 TEST RCX,RCX JNZ 0x0012523d LAB_00124fc6: LEA RDI,[RBX + 0x28] CALL 0x00125c8c TEST RAX,RAX JZ 0x00125174 MOV RDI,RAX MOV EDX,0xffffffff MOV RCX,qword ptr [RBX + 0x28] MOV RSI,qword ptr [RBX + 0x10] CMP RSI,0x2 JC 0x00125186 MOV dword ptr [RBP + -0x2c],R15D MOV qword ptr [RBP + -0x48],R14 MOV R12,qword ptr [RBX + 0x18] SHR RSI,0x1 SUB R12,RSI XOR R8D,R8D MOV qword ptr [RBP + -0x58],R12 LAB_0012500b: MOV R14,RDI MOV RAX,R12 SHL RAX,0x4 MOV R10D,dword ptr [RCX + RAX*0x1 + 0x4] TEST R8D,R8D JNZ 0x0012505e MOV RDI,qword ptr [RBX + 0x10] LEA R9D,[RDI + RDX*0x1] MOV RDX,RSI MOV RSI,R15 MOV R15D,R11D MOV R11D,R10D AND R11D,R9D SHR RDI,0x1 DEC EDI AND EDI,R10D CMP R11,qword ptr [RBX + 0x18] CMOVC EDI,R11D MOV R11D,R15D MOV R15,RSI MOV RSI,RDX MOV EDX,0xffffffff CMP qword ptr [RBP + -0x58],RDI JNZ 0x0012517b LAB_0012505e: ADD RAX,RCX TEST ESI,R10D JZ 0x00125086 TEST R8B,0x4 JNZ 0x001250bd AND R8D,0x1 OR R8D,0x4 MOV R15,qword ptr [RAX + 0x8] MOV R11D,R10D MOV RDI,RAX MOV R13,R14 JMP 0x00125125 LAB_00125086: TEST R8B,0x1 JNZ 0x001250ea AND R8D,0x4 MOV R9D,R8D SHR R9D,0x1 ADD R9D,0x3 TEST R8D,R8D MOV RDI,RAX CMOVZ RDI,R14 CMOVZ R14,RAX MOV R8,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x40],R8 MOV dword ptr [RBP + -0x30],R10D MOV R8D,R9D MOV qword ptr [RBP + -0x38],R14 JMP 0x00125125 LAB_001250bd: TEST R8B,0x8 JNZ 0x001250db MOV qword ptr [R13 + 0x8],R15 MOV dword ptr [R13 + 0x4],R11D MOV dword ptr [R13],R12D AND R8D,0x1 OR R8D,0xc MOV R10D,dword ptr [RAX + 0x4] LAB_001250db: MOV R15,qword ptr [RAX + 0x8] MOV R11D,R10D MOV RDI,R14 MOV R13,RAX JMP 0x00125125 LAB_001250ea: TEST R8B,0x2 JNZ 0x00125112 MOV RDI,qword ptr [RBP + -0x40] MOV R9,qword ptr [RBP + -0x38] MOV qword ptr [R9 + 0x8],RDI MOV EDI,dword ptr [RBP + -0x30] MOV dword ptr [R9 + 0x4],EDI MOV dword ptr [R9],R12D AND R8D,0x4 OR R8D,0x3 MOV R10D,dword ptr [RAX + 0x4] LAB_00125112: MOV RDI,qword ptr [RAX + 0x8] MOV qword ptr [RBP + -0x40],RDI MOV dword ptr [RBP + -0x30],R10D MOV RDI,R14 MOV qword ptr [RBP + -0x38],RAX LAB_00125125: MOV R12D,dword ptr [RAX] CMP R12,RDX JNZ 0x0012500b MOV EAX,R8D AND EAX,0x3 CMP EAX,0x1 JNZ 0x00125154 MOV RAX,qword ptr [RBP + -0x40] MOV RSI,qword ptr [RBP + -0x38] MOV qword ptr [RSI + 0x8],RAX MOV EAX,dword ptr [RBP + -0x30] MOV dword ptr [RSI + 0x4],EAX MOV dword ptr [RSI],0xffffffff LAB_00125154: AND R8D,0xc CMP R8D,0x4 MOV R14,qword ptr [RBP + -0x48] JNZ 0x00125182 MOV qword ptr [R13 + 0x8],R15 MOV dword ptr [R13 + 0x4],R11D MOV dword ptr [R13],0xffffffff JMP 0x00125182 LAB_00125174: MOV AL,0x1 JMP 0x0012523d LAB_0012517b: MOV RDI,R14 MOV R14,qword ptr [RBP + -0x48] LAB_00125182: MOV R15D,dword ptr [RBP + -0x2c] LAB_00125186: MOV RAX,qword ptr [RBX + 0x10] MOV RSI,qword ptr [RBX + 0x18] INC RSI LEA R8D,[RAX + RDX*0x1] AND R8D,R15D SHR RAX,0x1 DEC EAX AND EAX,R15D CMP R8,RSI CMOVC EAX,R8D MOV RSI,RAX SHL RSI,0x4 ADD RSI,RCX CMP RSI,RDI JZ 0x001251f1 MOVUPS XMM0,xmmword ptr [RSI] MOVUPS xmmword ptr [RDI],XMM0 MOV R8,qword ptr [RBX + 0x10] MOV R9,qword ptr [RBX + 0x18] INC R9 MOV R10D,dword ptr [RSI + 0x4] ADD EDX,R8D AND EDX,R10D SHR R8,0x1 DEC R8D AND R8D,R10D CMP RDX,R9 CMOVC R8D,EDX CMP EAX,R8D JNZ 0x001251f9 SUB RDI,RCX SHR RDI,0x4 MOV dword ptr [RSI],EDI JMP 0x0012521b LAB_001251f1: MOV dword ptr [RSI],0xffffffff JMP 0x0012521b LAB_001251f9: MOV dword ptr [RSI],0xffffffff SUB RDI,RCX SHR RDI,0x4 LAB_00125206: MOV EDX,R8D SHL RDX,0x4 MOV R8D,dword ptr [RCX + RDX*0x1] CMP R8D,EAX JNZ 0x00125206 ADD RCX,RDX MOV dword ptr [RCX],EDI LAB_0012521b: MOV qword ptr [RSI + 0x8],R14 MOV dword ptr [RSI + 0x4],R15D MOV RAX,qword ptr [RBX + 0x18] INC RAX MOV qword ptr [RBX + 0x18],RAX CMP RAX,qword ptr [RBX + 0x10] JNZ 0x0012523b ADD RAX,RAX MOV qword ptr [RBX + 0x10],RAX LAB_0012523b: XOR EAX,EAX LAB_0012523d: ADD RSP,0x38 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 my_hash_insert(long *param_1,long param_2) { uint uVar1; long lVar2; uint *puVar3; uint *puVar4; int8 uVar5; ulong uVar6; uint uVar7; ulong uVar8; uint *puVar9; ulong uVar10; uint uVar11; uint uVar12; ulong uVar13; ulong in_R11; ulong uVar14; ulong uVar15; uint *unaff_R13; long local_58 [2]; int8 local_48; uint *local_40; uint local_38; if ((code *)param_1[10] == (code *)0x0) { local_58[0] = param_1[1]; lVar2 = *param_1 + param_2; } else { lVar2 = (*(code *)param_1[10])(param_2,local_58,1); } uVar1 = (*(code *)param_1[0xb])(param_1[0xd],lVar2,local_58[0]); uVar6 = (ulong)uVar1; if (((*(byte *)(param_1 + 4) & 1) != 0) && (lVar2 = my_hash_first_from_hash_value(param_1,uVar6,lVar2,local_58[0]), lVar2 != 0)) { return 1; } puVar3 = (uint *)alloc_dynamic(param_1 + 5); if (puVar3 == (uint *)0x0) { uVar5 = 1; } else { lVar2 = param_1[5]; if (1 < (ulong)param_1[2]) { uVar8 = (ulong)param_1[2] >> 1; uVar15 = param_1[3] - uVar8; uVar11 = 0; uVar13 = uVar15; do { uVar7 = *(uint *)(lVar2 + 4 + uVar13 * 0x10); if (uVar11 == 0) { in_R11 = in_R11 & 0xffffffff; uVar14 = (ulong)(uVar7 & (int)param_1[2] - 1U); uVar10 = (ulong)((int)((ulong)param_1[2] >> 1) - 1U & uVar7); if (uVar14 < (ulong)param_1[3]) { uVar10 = uVar14; } if (uVar15 != uVar10) goto LAB_00125186; } puVar4 = (uint *)(uVar13 * 0x10 + lVar2); puVar9 = puVar4; if (((uint)uVar8 & uVar7) == 0) { if ((uVar11 & 1) == 0) { uVar12 = uVar11 & 4; uVar11 = (uVar12 >> 1) + 3; local_40 = puVar3; if (uVar12 == 0) { local_40 = puVar4; puVar9 = puVar3; } local_48 = *(int8 *)(puVar4 + 2); local_38 = uVar7; } else { if ((uVar11 & 2) == 0) { *(int8 *)(local_40 + 2) = local_48; local_40[1] = local_38; *local_40 = (uint)uVar13; uVar11 = uVar11 & 4 | 3; uVar7 = puVar4[1]; } local_48 = *(int8 *)(puVar4 + 2); puVar9 = puVar3; local_40 = puVar4; local_38 = uVar7; } } else if ((uVar11 & 4) == 0) { uVar11 = uVar11 & 1 | 4; uVar6 = *(ulong *)(puVar4 + 2); in_R11 = (ulong)uVar7; unaff_R13 = puVar3; } else { if ((uVar11 & 8) == 0) { *(ulong *)(unaff_R13 + 2) = uVar6; unaff_R13[1] = (uint)in_R11; *unaff_R13 = (uint)uVar13; uVar11 = uVar11 & 1 | 0xc; uVar7 = puVar4[1]; } uVar6 = *(ulong *)(puVar4 + 2); in_R11 = (ulong)uVar7; puVar9 = puVar3; unaff_R13 = puVar4; } uVar13 = (ulong)*puVar4; puVar3 = puVar9; } while (uVar13 != 0xffffffff); if ((uVar11 & 3) == 1) { *(int8 *)(local_40 + 2) = local_48; local_40[1] = local_38; *local_40 = 0xffffffff; } if ((uVar11 & 0xc) == 4) { *(ulong *)(unaff_R13 + 2) = uVar6; unaff_R13[1] = (uint)in_R11; *unaff_R13 = 0xffffffff; } } LAB_00125186: uVar13 = (ulong)((int)param_1[2] - 1U & uVar1); uVar6 = (ulong)((int)((ulong)param_1[2] >> 1) - 1U & uVar1); if (uVar13 < param_1[3] + 1U) { uVar6 = uVar13; } puVar9 = (uint *)(uVar6 * 0x10 + lVar2); if (puVar9 == puVar3) { *puVar9 = 0xffffffff; } else { uVar5 = *(int8 *)(puVar9 + 2); *(int8 *)puVar3 = *(int8 *)puVar9; *(int8 *)(puVar3 + 2) = uVar5; uVar7 = (int)param_1[2] - 1U & puVar9[1]; uVar11 = (int)((ulong)param_1[2] >> 1) - 1U & puVar9[1]; if ((ulong)uVar7 < param_1[3] + 1U) { uVar11 = uVar7; } if ((uint)uVar6 == uVar11) { *puVar9 = (uint)((ulong)((long)puVar3 - lVar2) >> 4); } else { *puVar9 = 0xffffffff; do { uVar13 = (ulong)uVar11; uVar11 = *(uint *)(lVar2 + uVar13 * 0x10); } while (uVar11 != (uint)uVar6); *(int *)(lVar2 + uVar13 * 0x10) = (int)((ulong)((long)puVar3 - lVar2) >> 4); } } *(long *)(puVar9 + 2) = param_2; puVar9[1] = uVar1; lVar2 = param_1[3] + 1; param_1[3] = lVar2; if (lVar2 == param_1[2]) { param_1[2] = lVar2 * 2; } uVar5 = 0; } return uVar5; }
3,568
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>::set_parents()
monkey531[P]llama/common/json.hpp
void set_parents() { #if JSON_DIAGNOSTICS switch (m_data.m_type) { case value_t::array: { for (auto& element : *m_data.m_value.array) { element.m_parent = this; } break; } case value_t::object: { for (auto& element : *m_data.m_value.object) { element.second.m_parent = this; } break; } 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: break; } #endif }
O0
cpp
nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>::set_parents(): movq %rdi, -0x8(%rsp) retq nopw %cs:(%rax,%rax)
_ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE11set_parentsEv: mov [rsp+var_8], rdi retn
void 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>::set_parents() { ; }
set_parents: MOV qword ptr [RSP + -0x8],RDI RET
/* nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>::set_parents() */ void nlohmann::json_abi_v3_11_3:: basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::set_parents(void) { return; }
3,569
serial_cpp::Serial::readline(unsigned long, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
ami-iit[P]serial_cpp/src/serial.cc
string Serial::readline (size_t size, string eol) { std::string buffer; this->readline (buffer, size, eol); return buffer; }
O1
cpp
serial_cpp::Serial::readline(unsigned long, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>): pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x20, %rsp movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx leaq 0x10(%rdi), %r12 movq %r12, (%rdi) movq $0x0, 0x8(%rdi) movb $0x0, 0x10(%rdi) leaq 0x10(%rsp), %r13 movq %r13, -0x10(%r13) movq (%rcx), %rsi movq 0x8(%rcx), %rdx addq %rsi, %rdx movq %rsp, %rdi callq 0x41da movq %rsp, %rcx movq %r15, %rdi movq %rbx, %rsi movq %r14, %rdx callq 0x46c6 movq (%rsp), %rdi cmpq %r13, %rdi je 0x486b movq 0x10(%rsp), %rsi incq %rsi callq 0x32c0 movq %rbx, %rax addq $0x20, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq movq %rax, %r14 movq (%rsp), %rdi cmpq %r13, %rdi je 0x489a movq 0x10(%rsp), %rsi incq %rsi callq 0x32c0 jmp 0x489a movq %rax, %r14 movq (%rbx), %rdi cmpq %r12, %rdi je 0x48ae movq (%r12), %rsi incq %rsi callq 0x32c0 movq %r14, %rdi callq 0x34f0
_ZN10serial_cpp6Serial8readlineEmNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: push r15 push r14 push r13 push r12 push rbx sub rsp, 20h mov r14, rdx mov r15, rsi mov rbx, rdi lea r12, [rdi+10h] mov [rdi], r12 mov qword ptr [rdi+8], 0 mov byte ptr [rdi+10h], 0 lea r13, [rsp+48h+var_38] mov [r13-10h], r13 mov rsi, [rcx] mov rdx, [rcx+8] add rdx, rsi mov rdi, rsp call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag) mov rcx, rsp mov rdi, r15 mov rsi, rbx mov rdx, r14 call _ZN10serial_cpp6Serial8readlineERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEmS6_; serial_cpp::Serial::readline(std::string &,ulong,std::string) mov rdi, [rsp+48h+var_48]; void * cmp rdi, r13 jz short loc_486B mov rsi, [rsp+48h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_486B: mov rax, rbx add rsp, 20h pop rbx pop r12 pop r13 pop r14 pop r15 retn mov r14, rax mov rdi, [rsp+0]; void * cmp rdi, r13 jz short loc_489A mov rsi, [rsp+arg_8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_489A mov r14, rax loc_489A: mov rdi, [rbx]; void * cmp rdi, r12 jz short loc_48AE mov rsi, [r12] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_48AE: mov rdi, r14 call __Unwind_Resume
long long serial_cpp::Serial::readline(long long a1, long long a2, long long a3, long long a4) { void *v6[2]; // [rsp+0h] [rbp-48h] BYREF _QWORD v7[7]; // [rsp+10h] [rbp-38h] BYREF *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; v6[0] = v7; std::string::_M_construct<char *>(v6, *(_BYTE **)a4, *(_QWORD *)a4 + *(_QWORD *)(a4 + 8)); serial_cpp::Serial::readline(a2, a1, a3, v6); if ( v6[0] != v7 ) operator delete(v6[0], v7[0] + 1LL); return a1; }
readline: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x20 MOV R14,RDX MOV R15,RSI MOV RBX,RDI LEA R12,[RDI + 0x10] MOV qword ptr [RDI],R12 MOV qword ptr [RDI + 0x8],0x0 MOV byte ptr [RDI + 0x10],0x0 LEA R13,[RSP + 0x10] MOV qword ptr [R13 + -0x10],R13 MOV RSI,qword ptr [RCX] MOV RDX,qword ptr [RCX + 0x8] ADD RDX,RSI LAB_0010483c: MOV RDI,RSP CALL 0x001041da LAB_00104844: MOV RCX,RSP MOV RDI,R15 MOV RSI,RBX MOV RDX,R14 CALL 0x001046c6 LAB_00104855: MOV RDI,qword ptr [RSP] CMP RDI,R13 JZ 0x0010486b MOV RSI,qword ptr [RSP + 0x10] INC RSI CALL 0x001032c0 LAB_0010486b: MOV RAX,RBX ADD RSP,0x20 POP RBX POP R12 POP R13 POP R14 POP R15 RET
/* serial_cpp::Serial::readline(unsigned long, std::__cxx11::string) */ long * serial_cpp::Serial::readline(long *param_1,Serial *param_2,int8 param_3,long *param_4) { long *local_48 [2]; long local_38 [2]; *param_1 = (long)(param_1 + 2); param_1[1] = 0; *(int1 *)(param_1 + 2) = 0; local_48[0] = local_38; /* try { // try from 0010483c to 00104843 has its CatchHandler @ 00104897 */ std::__cxx11::string::_M_construct<char*>(local_48,*param_4,param_4[1] + *param_4); /* try { // try from 00104844 to 00104854 has its CatchHandler @ 0010487c */ readline(param_2,param_1,param_3,local_48); if (local_48[0] != local_38) { operator_delete(local_48[0],local_38[0] + 1); } return param_1; }
3,570
serial_cpp::Serial::readline(unsigned long, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
ami-iit[P]serial_cpp/src/serial.cc
string Serial::readline (size_t size, string eol) { std::string buffer; this->readline (buffer, size, eol); return buffer; }
O2
cpp
serial_cpp::Serial::readline(unsigned long, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>): pushq %r15 pushq %r14 pushq %rbx subq $0x20, %rsp movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx leaq 0x10(%rdi), %rax movq %rax, (%rdi) andq $0x0, 0x8(%rdi) movb $0x0, 0x10(%rdi) movq %rsp, %rdi movq %rcx, %rsi callq 0x33b0 movq %rsp, %rcx movq %r15, %rdi movq %rbx, %rsi movq %r14, %rdx callq 0x429e movq %rsp, %rdi callq 0x3140 movq %rbx, %rax addq $0x20, %rsp popq %rbx popq %r14 popq %r15 retq movq %rax, %r14 movq %rsp, %rdi callq 0x3140 jmp 0x43f7 movq %rax, %r14 movq %rbx, %rdi callq 0x3140 movq %r14, %rdi callq 0x34d0 nop
_ZN10serial_cpp6Serial8readlineEmNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: push r15 push r14 push rbx sub rsp, 20h mov r14, rdx mov r15, rsi mov rbx, rdi lea rax, [rdi+10h] mov [rdi], rax and qword ptr [rdi+8], 0 mov byte ptr [rdi+10h], 0 mov rdi, rsp mov rsi, rcx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2ERKS4_; std::string::basic_string(std::string const&) mov rcx, rsp mov rdi, r15; this mov rsi, rbx mov rdx, r14 call _ZN10serial_cpp6Serial8readlineERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEmS6_; serial_cpp::Serial::readline(std::string &,ulong,std::string) mov rdi, rsp call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rax, rbx add rsp, 20h pop rbx pop r14 pop r15 retn mov r14, rax mov rdi, rsp call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() jmp short loc_43F7 mov r14, rax loc_43F7: mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdi, r14 call __Unwind_Resume
long long serial_cpp::Serial::readline(long long a1, serial_cpp::Serial *a2, long long a3, long long a4) { _BYTE v6[56]; // [rsp+0h] [rbp-38h] BYREF *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; std::string::basic_string(v6, a4); serial_cpp::Serial::readline(a2, a1, a3, (long long)v6); std::string::~string(v6); return a1; }
readline: PUSH R15 PUSH R14 PUSH RBX SUB RSP,0x20 MOV R14,RDX MOV R15,RSI MOV RBX,RDI LEA RAX,[RDI + 0x10] MOV qword ptr [RDI],RAX AND qword ptr [RDI + 0x8],0x0 MOV byte ptr [RDI + 0x10],0x0 LAB_001043b6: MOV RDI,RSP MOV RSI,RCX CALL 0x001033b0 LAB_001043c1: MOV RCX,RSP MOV RDI,R15 MOV RSI,RBX MOV RDX,R14 CALL 0x0010429e LAB_001043d2: MOV RDI,RSP CALL 0x00103140 MOV RAX,RBX ADD RSP,0x20 POP RBX POP R14 POP R15 RET
/* serial_cpp::Serial::readline(unsigned long, std::__cxx11::string) */ long * serial_cpp::Serial::readline (long *param_1,Serial *param_2,int8 param_3,string *param_4) { string asStack_38 [32]; *param_1 = (long)(param_1 + 2); param_1[1] = 0; *(int1 *)(param_1 + 2) = 0; /* try { // try from 001043b6 to 001043c0 has its CatchHandler @ 001043f4 */ std::__cxx11::string::string(asStack_38,param_4); /* try { // try from 001043c1 to 001043d1 has its CatchHandler @ 001043e7 */ readline(param_2,param_1,param_3,asStack_38); std::__cxx11::string::~string(asStack_38); return param_1; }
3,571
serial_cpp::Serial::readline(unsigned long, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
ami-iit[P]serial_cpp/src/serial.cc
string Serial::readline (size_t size, string eol) { std::string buffer; this->readline (buffer, size, eol); return buffer; }
O3
cpp
serial_cpp::Serial::readline(unsigned long, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>): pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x20, %rsp movq %rdx, %r14 movq %rsi, %r15 movq %rdi, %rbx leaq 0x10(%rdi), %r12 movq %r12, (%rdi) movq $0x0, 0x8(%rdi) movb $0x0, 0x10(%rdi) leaq 0x10(%rsp), %r13 movq %r13, -0x10(%r13) movq (%rcx), %rsi movq 0x8(%rcx), %rdx addq %rsi, %rdx movq %rsp, %rdi callq 0x41da movq %rsp, %rcx movq %r15, %rdi movq %rbx, %rsi movq %r14, %rdx callq 0x46d2 movq (%rsp), %rdi cmpq %r13, %rdi je 0x488f movq 0x10(%rsp), %rsi incq %rsi callq 0x32c0 movq %rbx, %rax addq $0x20, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 retq movq %rax, %r14 movq (%rsp), %rdi cmpq %r13, %rdi je 0x48be movq 0x10(%rsp), %rsi incq %rsi callq 0x32c0 jmp 0x48be movq %rax, %r14 movq (%rbx), %rdi cmpq %r12, %rdi je 0x48d2 movq (%r12), %rsi incq %rsi callq 0x32c0 movq %r14, %rdi callq 0x34f0
_ZN10serial_cpp6Serial8readlineEmNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE: push r15 push r14 push r13 push r12 push rbx sub rsp, 20h mov r14, rdx mov r15, rsi mov rbx, rdi lea r12, [rdi+10h] mov [rdi], r12 mov qword ptr [rdi+8], 0 mov byte ptr [rdi+10h], 0 lea r13, [rsp+48h+var_38] mov [r13-10h], r13 mov rsi, [rcx] mov rdx, [rcx+8] add rdx, rsi mov rdi, rsp call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructIPcEEvT_S7_St20forward_iterator_tag; std::string::_M_construct<char *>(char *,char *,std::forward_iterator_tag) mov rcx, rsp mov rdi, r15 mov rsi, rbx mov rdx, r14 call _ZN10serial_cpp6Serial8readlineERNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEmS6_; serial_cpp::Serial::readline(std::string &,ulong,std::string) mov rdi, [rsp+48h+var_48]; void * cmp rdi, r13 jz short loc_488F mov rsi, [rsp+48h+var_38] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_488F: mov rax, rbx add rsp, 20h pop rbx pop r12 pop r13 pop r14 pop r15 retn mov r14, rax mov rdi, [rsp+0]; void * cmp rdi, r13 jz short loc_48BE mov rsi, [rsp+arg_8] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) jmp short loc_48BE mov r14, rax loc_48BE: mov rdi, [rbx]; void * cmp rdi, r12 jz short loc_48D2 mov rsi, [r12] inc rsi; unsigned __int64 call __ZdlPvm; operator delete(void *,ulong) loc_48D2: mov rdi, r14 call __Unwind_Resume
long long serial_cpp::Serial::readline(long long a1, long long a2, long long a3, long long a4) { void *v6[2]; // [rsp+0h] [rbp-48h] BYREF _QWORD v7[7]; // [rsp+10h] [rbp-38h] BYREF *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; v6[0] = v7; std::string::_M_construct<char *>((long long)v6, *(_BYTE **)a4, *(_QWORD *)a4 + *(_QWORD *)(a4 + 8)); serial_cpp::Serial::readline(a2, a1, a3, v6); if ( v6[0] != v7 ) operator delete(v6[0], v7[0] + 1LL); return a1; }
readline: PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x20 MOV R14,RDX MOV R15,RSI MOV RBX,RDI LEA R12,[RDI + 0x10] MOV qword ptr [RDI],R12 MOV qword ptr [RDI + 0x8],0x0 MOV byte ptr [RDI + 0x10],0x0 LEA R13,[RSP + 0x10] MOV qword ptr [R13 + -0x10],R13 MOV RSI,qword ptr [RCX] MOV RDX,qword ptr [RCX + 0x8] ADD RDX,RSI LAB_00104860: MOV RDI,RSP CALL 0x001041da LAB_00104868: MOV RCX,RSP MOV RDI,R15 MOV RSI,RBX MOV RDX,R14 CALL 0x001046d2 LAB_00104879: MOV RDI,qword ptr [RSP] CMP RDI,R13 JZ 0x0010488f MOV RSI,qword ptr [RSP + 0x10] INC RSI CALL 0x001032c0 LAB_0010488f: MOV RAX,RBX ADD RSP,0x20 POP RBX POP R12 POP R13 POP R14 POP R15 RET
/* serial_cpp::Serial::readline(unsigned long, std::__cxx11::string) */ long * serial_cpp::Serial::readline(long *param_1,Serial *param_2,int8 param_3,long *param_4) { long *local_48 [2]; long local_38 [2]; *param_1 = (long)(param_1 + 2); param_1[1] = 0; *(int1 *)(param_1 + 2) = 0; local_48[0] = local_38; /* try { // try from 00104860 to 00104867 has its CatchHandler @ 001048bb */ std::__cxx11::string::_M_construct<char*>(local_48,*param_4,param_4[1] + *param_4); /* try { // try from 00104868 to 00104878 has its CatchHandler @ 001048a0 */ readline(param_2,param_1,param_3,local_48); if (local_48[0] != local_38) { operator_delete(local_48[0],local_38[0] + 1); } return param_1; }
3,572
line_dbl
corpus-core[P]colibri-stateless/build_O0/_deps/blst-src/src/pairing.c
static void line_dbl(vec384fp6 line, POINTonE2 *T, const POINTonE2 *Q) { vec384x ZZ, A, B, C, D, E, F; /* * https://www.hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-0.html#doubling-dbl-2009-alnr */ sqr_fp2(A, Q->X); /* A = X1^2 */ sqr_fp2(B, Q->Y); /* B = Y1^2 */ sqr_fp2(ZZ, Q->Z); /* ZZ = Z1^2 */ sqr_fp2(C, B); /* C = B^2 */ add_fp2(D, Q->X, B); /* X1+B */ sqr_fp2(D, D); /* (X1+B)^2 */ sub_fp2(D, D, A); /* (X1+B)^2-A */ sub_fp2(D, D, C); /* (X1+B)^2-A-C */ add_fp2(D, D, D); /* D = 2*((X1+B)^2-A-C) */ mul_by_3_fp2(E, A); /* E = 3*A */ sqr_fp2(F, E); /* F = E^2 */ add_fp2(line[0], E, Q->X); /* 3*A+X1 for line evaluation */ sub_fp2(T->X, F, D); sub_fp2(T->X, T->X, D); /* X3 = F-2*D */ add_fp2(T->Z, Q->Y, Q->Z); sqr_fp2(T->Z, T->Z); sub_fp2(T->Z, T->Z, B); sub_fp2(T->Z, T->Z, ZZ); /* Z3 = (Y1+Z1)^2-B-ZZ */ mul_by_8_fp2(C, C); /* 8*C */ sub_fp2(T->Y, D, T->X); /* D-X3 */ mul_fp2(T->Y, T->Y, E); /* E*(D-X3) */ sub_fp2(T->Y, T->Y, C); /* Y3 = E*(D-X3)-8*C */ /* * line evaluation */ sqr_fp2(line[0], line[0]); sub_fp2(line[0], line[0], A); sub_fp2(line[0], line[0], F); /* (3*A+X1)^2 - X1^2 - 9*A^2 */ lshift_fp2(B, B, 2); sub_fp2(line[0], line[0], B); /* 6*X1^3 - 4*Y1^2 */ mul_fp2(line[1], E, ZZ); /* 3*X1^2 * Z1^2 */ mul_fp2(line[2], T->Z, ZZ); /* Z3 * Z1^2 */ }
O0
c
line_dbl: pushq %rbp movq %rsp, %rbp subq $0x2c0, %rsp # imm = 0x2C0 movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) leaq -0xe0(%rbp), %rdi movq -0x18(%rbp), %rsi callq 0xb6750 leaq -0x140(%rbp), %rdi movq -0x18(%rbp), %rsi addq $0x60, %rsi callq 0xb6750 leaq -0x80(%rbp), %rdi movq -0x18(%rbp), %rsi addq $0xc0, %rsi callq 0xb6750 leaq -0x1a0(%rbp), %rdi leaq -0x140(%rbp), %rsi callq 0xb6750 leaq -0x200(%rbp), %rdi movq -0x18(%rbp), %rsi leaq -0x140(%rbp), %rdx callq 0xb64b0 leaq -0x200(%rbp), %rdi leaq -0x200(%rbp), %rsi callq 0xb6750 leaq -0x200(%rbp), %rdi leaq -0x200(%rbp), %rsi leaq -0xe0(%rbp), %rdx callq 0xb6520 leaq -0x200(%rbp), %rdi leaq -0x200(%rbp), %rsi leaq -0x1a0(%rbp), %rdx callq 0xb6520 leaq -0x200(%rbp), %rdi leaq -0x200(%rbp), %rsi leaq -0x200(%rbp), %rdx callq 0xb64b0 leaq -0x260(%rbp), %rdi leaq -0xe0(%rbp), %rsi callq 0xb6590 leaq -0x2c0(%rbp), %rdi leaq -0x260(%rbp), %rsi callq 0xb6750 movq -0x8(%rbp), %rdi leaq -0x260(%rbp), %rsi movq -0x18(%rbp), %rdx callq 0xb64b0 movq -0x10(%rbp), %rdi leaq -0x2c0(%rbp), %rsi leaq -0x200(%rbp), %rdx callq 0xb6520 movq -0x10(%rbp), %rdi movq -0x10(%rbp), %rsi leaq -0x200(%rbp), %rdx callq 0xb6520 movq -0x10(%rbp), %rdi addq $0xc0, %rdi movq -0x18(%rbp), %rsi addq $0x60, %rsi movq -0x18(%rbp), %rdx addq $0xc0, %rdx callq 0xb64b0 movq -0x10(%rbp), %rdi addq $0xc0, %rdi movq -0x10(%rbp), %rsi addq $0xc0, %rsi callq 0xb6750 movq -0x10(%rbp), %rdi addq $0xc0, %rdi movq -0x10(%rbp), %rsi addq $0xc0, %rsi leaq -0x140(%rbp), %rdx callq 0xb6520 movq -0x10(%rbp), %rdi addq $0xc0, %rdi movq -0x10(%rbp), %rsi addq $0xc0, %rsi leaq -0x80(%rbp), %rdx callq 0xb6520 leaq -0x1a0(%rbp), %rdi leaq -0x1a0(%rbp), %rsi callq 0xb65f0 movq -0x10(%rbp), %rdi addq $0x60, %rdi leaq -0x200(%rbp), %rsi movq -0x10(%rbp), %rdx callq 0xb6520 movq -0x10(%rbp), %rdi addq $0x60, %rdi movq -0x10(%rbp), %rsi addq $0x60, %rsi leaq -0x260(%rbp), %rdx callq 0xb66e0 movq -0x10(%rbp), %rdi addq $0x60, %rdi movq -0x10(%rbp), %rsi addq $0x60, %rsi leaq -0x1a0(%rbp), %rdx callq 0xb6520 movq -0x8(%rbp), %rdi movq -0x8(%rbp), %rsi callq 0xb6750 movq -0x8(%rbp), %rdi movq -0x8(%rbp), %rsi leaq -0xe0(%rbp), %rdx callq 0xb6520 movq -0x8(%rbp), %rdi movq -0x8(%rbp), %rsi leaq -0x2c0(%rbp), %rdx callq 0xb6520 leaq -0x140(%rbp), %rdi leaq -0x140(%rbp), %rsi movl $0x2, %edx callq 0xb6650 movq -0x8(%rbp), %rdi movq -0x8(%rbp), %rsi leaq -0x140(%rbp), %rdx callq 0xb6520 movq -0x8(%rbp), %rdi addq $0x60, %rdi leaq -0x260(%rbp), %rsi leaq -0x80(%rbp), %rdx callq 0xb66e0 movq -0x8(%rbp), %rdi addq $0xc0, %rdi movq -0x10(%rbp), %rsi addq $0xc0, %rsi leaq -0x80(%rbp), %rdx callq 0xb66e0 addq $0x2c0, %rsp # imm = 0x2C0 popq %rbp retq nopw %cs:(%rax,%rax) nopl (%rax)
line_dbl: push rbp mov rbp, rsp sub rsp, 2C0h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx lea rdi, [rbp+var_E0] mov rsi, [rbp+var_18] call sqr_fp2 lea rdi, [rbp+var_140] mov rsi, [rbp+var_18] add rsi, 60h ; '`' call sqr_fp2 lea rdi, [rbp+var_80] mov rsi, [rbp+var_18] add rsi, 0C0h call sqr_fp2 lea rdi, [rbp+var_1A0] lea rsi, [rbp+var_140] call sqr_fp2 lea rdi, [rbp+var_200] mov rsi, [rbp+var_18] lea rdx, [rbp+var_140] call add_fp2 lea rdi, [rbp+var_200] lea rsi, [rbp+var_200] call sqr_fp2 lea rdi, [rbp+var_200] lea rsi, [rbp+var_200] lea rdx, [rbp+var_E0] call _sub_fp2 lea rdi, [rbp+var_200] lea rsi, [rbp+var_200] lea rdx, [rbp+var_1A0] call _sub_fp2 lea rdi, [rbp+var_200] lea rsi, [rbp+var_200] lea rdx, [rbp+var_200] call add_fp2 lea rdi, [rbp+var_260] lea rsi, [rbp+var_E0] call mul_by_3_fp2 lea rdi, [rbp+var_2C0] lea rsi, [rbp+var_260] call sqr_fp2 mov rdi, [rbp+var_8] lea rsi, [rbp+var_260] mov rdx, [rbp+var_18] call add_fp2 mov rdi, [rbp+var_10] lea rsi, [rbp+var_2C0] lea rdx, [rbp+var_200] call _sub_fp2 mov rdi, [rbp+var_10] mov rsi, [rbp+var_10] lea rdx, [rbp+var_200] call _sub_fp2 mov rdi, [rbp+var_10] add rdi, 0C0h mov rsi, [rbp+var_18] add rsi, 60h ; '`' mov rdx, [rbp+var_18] add rdx, 0C0h call add_fp2 mov rdi, [rbp+var_10] add rdi, 0C0h mov rsi, [rbp+var_10] add rsi, 0C0h call sqr_fp2 mov rdi, [rbp+var_10] add rdi, 0C0h mov rsi, [rbp+var_10] add rsi, 0C0h lea rdx, [rbp+var_140] call _sub_fp2 mov rdi, [rbp+var_10] add rdi, 0C0h mov rsi, [rbp+var_10] add rsi, 0C0h lea rdx, [rbp+var_80] call _sub_fp2 lea rdi, [rbp+var_1A0] lea rsi, [rbp+var_1A0] call mul_by_8_fp2 mov rdi, [rbp+var_10] add rdi, 60h ; '`' lea rsi, [rbp+var_200] mov rdx, [rbp+var_10] call _sub_fp2 mov rdi, [rbp+var_10] add rdi, 60h ; '`' mov rsi, [rbp+var_10] add rsi, 60h ; '`' lea rdx, [rbp+var_260] call mul_fp2 mov rdi, [rbp+var_10] add rdi, 60h ; '`' mov rsi, [rbp+var_10] add rsi, 60h ; '`' lea rdx, [rbp+var_1A0] call _sub_fp2 mov rdi, [rbp+var_8] mov rsi, [rbp+var_8] call sqr_fp2 mov rdi, [rbp+var_8] mov rsi, [rbp+var_8] lea rdx, [rbp+var_E0] call _sub_fp2 mov rdi, [rbp+var_8] mov rsi, [rbp+var_8] lea rdx, [rbp+var_2C0] call _sub_fp2 lea rdi, [rbp+var_140] lea rsi, [rbp+var_140] mov edx, 2 call lshift_fp2 mov rdi, [rbp+var_8] mov rsi, [rbp+var_8] lea rdx, [rbp+var_140] call _sub_fp2 mov rdi, [rbp+var_8] add rdi, 60h ; '`' lea rsi, [rbp+var_260] lea rdx, [rbp+var_80] call mul_fp2 mov rdi, [rbp+var_8] add rdi, 0C0h mov rsi, [rbp+var_10] add rsi, 0C0h lea rdx, [rbp+var_80] call mul_fp2 add rsp, 2C0h pop rbp retn
long long line_dbl(long long a1, long long a2, long long a3) { _BYTE v4[96]; // [rsp+0h] [rbp-2C0h] BYREF _BYTE v5[96]; // [rsp+60h] [rbp-260h] BYREF _BYTE v6[96]; // [rsp+C0h] [rbp-200h] BYREF _BYTE v7[96]; // [rsp+120h] [rbp-1A0h] BYREF _BYTE v8[96]; // [rsp+180h] [rbp-140h] BYREF _BYTE v9[96]; // [rsp+1E0h] [rbp-E0h] BYREF _BYTE v10[104]; // [rsp+240h] [rbp-80h] BYREF long long v11; // [rsp+2A8h] [rbp-18h] long long v12; // [rsp+2B0h] [rbp-10h] long long v13; // [rsp+2B8h] [rbp-8h] v13 = a1; v12 = a2; v11 = a3; sqr_fp2((long long)v9, a3); sqr_fp2((long long)v8, v11 + 96); sqr_fp2((long long)v10, v11 + 192); sqr_fp2((long long)v7, (long long)v8); add_fp2((long long)v6, v11, (long long)v8); sqr_fp2((long long)v6, (long long)v6); sub_fp2((long long)v6, (long long)v6, (long long)v9); sub_fp2((long long)v6, (long long)v6, (long long)v7); add_fp2((long long)v6, (long long)v6, (long long)v6); mul_by_3_fp2((long long)v5, (long long)v9); sqr_fp2((long long)v4, (long long)v5); add_fp2(v13, (long long)v5, v11); sub_fp2(v12, (long long)v4, (long long)v6); sub_fp2(v12, v12, (long long)v6); add_fp2(v12 + 192, v11 + 96, v11 + 192); sqr_fp2(v12 + 192, v12 + 192); sub_fp2(v12 + 192, v12 + 192, (long long)v8); sub_fp2(v12 + 192, v12 + 192, (long long)v10); mul_by_8_fp2((long long)v7, (long long)v7); sub_fp2(v12 + 96, (long long)v6, v12); mul_fp2(v12 + 96, v12 + 96, (long long)v5); sub_fp2(v12 + 96, v12 + 96, (long long)v7); sqr_fp2(v13, v13); sub_fp2(v13, v13, (long long)v9); sub_fp2(v13, v13, (long long)v4); lshift_fp2((long long)v8, (long long)v8, 2LL); sub_fp2(v13, v13, (long long)v8); mul_fp2(v13 + 96, (long long)v5, (long long)v10); return mul_fp2(v13 + 192, v12 + 192, (long long)v10); }
line_dbl: PUSH RBP MOV RBP,RSP SUB RSP,0x2c0 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX LEA RDI,[RBP + -0xe0] MOV RSI,qword ptr [RBP + -0x18] CALL 0x001b6750 LEA RDI,[RBP + -0x140] MOV RSI,qword ptr [RBP + -0x18] ADD RSI,0x60 CALL 0x001b6750 LEA RDI,[RBP + -0x80] MOV RSI,qword ptr [RBP + -0x18] ADD RSI,0xc0 CALL 0x001b6750 LEA RDI,[RBP + -0x1a0] LEA RSI,[RBP + -0x140] CALL 0x001b6750 LEA RDI,[RBP + -0x200] MOV RSI,qword ptr [RBP + -0x18] LEA RDX,[RBP + -0x140] CALL 0x001b64b0 LEA RDI,[RBP + -0x200] LEA RSI,[RBP + -0x200] CALL 0x001b6750 LEA RDI,[RBP + -0x200] LEA RSI,[RBP + -0x200] LEA RDX,[RBP + -0xe0] CALL 0x001b6520 LEA RDI,[RBP + -0x200] LEA RSI,[RBP + -0x200] LEA RDX,[RBP + -0x1a0] CALL 0x001b6520 LEA RDI,[RBP + -0x200] LEA RSI,[RBP + -0x200] LEA RDX,[RBP + -0x200] CALL 0x001b64b0 LEA RDI,[RBP + -0x260] LEA RSI,[RBP + -0xe0] CALL 0x001b6590 LEA RDI,[RBP + -0x2c0] LEA RSI,[RBP + -0x260] CALL 0x001b6750 MOV RDI,qword ptr [RBP + -0x8] LEA RSI,[RBP + -0x260] MOV RDX,qword ptr [RBP + -0x18] CALL 0x001b64b0 MOV RDI,qword ptr [RBP + -0x10] LEA RSI,[RBP + -0x2c0] LEA RDX,[RBP + -0x200] CALL 0x001b6520 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x10] LEA RDX,[RBP + -0x200] CALL 0x001b6520 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0xc0 MOV RSI,qword ptr [RBP + -0x18] ADD RSI,0x60 MOV RDX,qword ptr [RBP + -0x18] ADD RDX,0xc0 CALL 0x001b64b0 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0xc0 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0xc0 CALL 0x001b6750 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0xc0 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0xc0 LEA RDX,[RBP + -0x140] CALL 0x001b6520 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0xc0 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0xc0 LEA RDX,[RBP + -0x80] CALL 0x001b6520 LEA RDI,[RBP + -0x1a0] LEA RSI,[RBP + -0x1a0] CALL 0x001b65f0 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x60 LEA RSI,[RBP + -0x200] MOV RDX,qword ptr [RBP + -0x10] CALL 0x001b6520 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x60 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x60 LEA RDX,[RBP + -0x260] CALL 0x001b66e0 MOV RDI,qword ptr [RBP + -0x10] ADD RDI,0x60 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0x60 LEA RDX,[RBP + -0x1a0] CALL 0x001b6520 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x8] CALL 0x001b6750 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x8] LEA RDX,[RBP + -0xe0] CALL 0x001b6520 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x8] LEA RDX,[RBP + -0x2c0] CALL 0x001b6520 LEA RDI,[RBP + -0x140] LEA RSI,[RBP + -0x140] MOV EDX,0x2 CALL 0x001b6650 MOV RDI,qword ptr [RBP + -0x8] MOV RSI,qword ptr [RBP + -0x8] LEA RDX,[RBP + -0x140] CALL 0x001b6520 MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0x60 LEA RSI,[RBP + -0x260] LEA RDX,[RBP + -0x80] CALL 0x001b66e0 MOV RDI,qword ptr [RBP + -0x8] ADD RDI,0xc0 MOV RSI,qword ptr [RBP + -0x10] ADD RSI,0xc0 LEA RDX,[RBP + -0x80] CALL 0x001b66e0 ADD RSP,0x2c0 POP RBP RET
void line_dbl(long param_1,long param_2,long param_3) { int1 local_2c8 [96]; int1 local_268 [96]; int1 local_208 [96]; int1 local_1a8 [96]; int1 local_148 [96]; int1 local_e8 [96]; int1 local_88 [104]; long local_20; long local_18; long local_10; local_20 = param_3; local_18 = param_2; local_10 = param_1; sqr_fp2(local_e8,param_3); sqr_fp2(local_148,local_20 + 0x60); sqr_fp2(local_88,local_20 + 0xc0); sqr_fp2(local_1a8,local_148); add_fp2(local_208,local_20,local_148); sqr_fp2(local_208,local_208); sub_fp2(local_208,local_208,local_e8); sub_fp2(local_208,local_208,local_1a8); add_fp2(local_208,local_208,local_208); mul_by_3_fp2(local_268,local_e8); sqr_fp2(local_2c8,local_268); add_fp2(local_10,local_268,local_20); sub_fp2(local_18,local_2c8,local_208); sub_fp2(local_18,local_18,local_208); add_fp2(local_18 + 0xc0,local_20 + 0x60,local_20 + 0xc0); sqr_fp2(local_18 + 0xc0,local_18 + 0xc0); sub_fp2(local_18 + 0xc0,local_18 + 0xc0,local_148); sub_fp2(local_18 + 0xc0,local_18 + 0xc0,local_88); mul_by_8_fp2(local_1a8,local_1a8); sub_fp2(local_18 + 0x60,local_208,local_18); mul_fp2(local_18 + 0x60,local_18 + 0x60,local_268); sub_fp2(local_18 + 0x60,local_18 + 0x60,local_1a8); sqr_fp2(local_10,local_10); sub_fp2(local_10,local_10,local_e8); sub_fp2(local_10,local_10,local_2c8); lshift_fp2(local_148,local_148,2); sub_fp2(local_10,local_10,local_148); mul_fp2(local_10 + 0x60,local_268,local_88); mul_fp2(local_10 + 0xc0,local_18 + 0xc0,local_88); return; }
3,573
nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&)
monkey531[P]llama/common/json.hpp
constexpr value_t type() const noexcept { return m_data.m_type; }
O1
cpp
nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&): pushq %r15 pushq %r14 pushq %r12 pushq %rbx subq $0x38, %rsp movzbl (%rdi), %eax movb (%rsi), %cl cmpb %cl, %al jne 0x9b599 cmpl $0x8, %eax ja 0x9b7a7 movb $0x1, %bl movl %eax, %eax leaq 0x634d1(%rip), %rcx # 0xfea54 movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax movq 0x8(%rdi), %rax cmpq 0x8(%rsi), %rax jmp 0x9b711 movl %eax, %edx xorb $0x5, %dl movl %ecx, %r8d xorb $0x7, %r8b orb %r8b, %dl jne 0x9b5bb cvtsi2sdq 0x8(%rdi), %xmm0 cmpeqsd 0x8(%rsi), %xmm0 jmp 0x9b661 movl %eax, %r9d xorb $0x7, %r9b movl %ecx, %edx xorb $0x5, %dl orb %dl, %r9b jne 0x9b5d7 cvtsi2sdq 0x8(%rsi), %xmm0 jmp 0x9b65b movl %eax, %r9d xorb $0x6, %r9b orb %r8b, %r9b jne 0x9b60b movsd 0x8(%rdi), %xmm0 unpcklps 0x59aa1(%rip), %xmm0 # xmm0 = xmm0[0],mem[0],xmm0[1],mem[1] subpd 0x59aa9(%rip), %xmm0 # 0xf50a0 movapd %xmm0, %xmm1 unpckhpd %xmm0, %xmm1 # xmm1 = xmm1[1],xmm0[1] addsd %xmm0, %xmm1 cmpeqsd 0x8(%rsi), %xmm1 jmp 0x9b644 movl %eax, %r8d xorb $0x7, %r8b xorb $0x6, %cl orb %cl, %r8b jne 0x9b7fb movsd 0x8(%rsi), %xmm0 unpcklps 0x59a66(%rip), %xmm0 # xmm0 = xmm0[0],mem[0],xmm0[1],mem[1] subpd 0x59a6e(%rip), %xmm0 # 0xf50a0 movapd %xmm0, %xmm1 unpckhpd %xmm0, %xmm1 # xmm1 = xmm1[1],xmm0[1] addsd %xmm0, %xmm1 cmpeqsd 0x8(%rdi), %xmm1 movq %xmm1, %rbx jmp 0x9b666 movb 0x8(%rdi), %al cmpb 0x8(%rsi), %al jmp 0x9b711 movsd 0x8(%rsi), %xmm0 cmpeqsd 0x8(%rdi), %xmm0 movq %xmm0, %rbx andl $0x1, %ebx jmp 0x9b7ea movq 0x8(%rdi), %rax movq 0x8(%rsi), %rcx movq (%rax), %r14 movq 0x8(%rax), %r12 movq %r12, %rax subq %r14, %rax movq (%rcx), %r15 movq 0x8(%rcx), %rcx subq %r15, %rcx cmpq %rcx, %rax jne 0x9b7a7 cmpq %r12, %r14 sete %bl je 0x9b7ea movq %r14, %rdi movq %r15, %rsi callq 0x9b55b testb %al, %al je 0x9b7ea addq $0x10, %r14 addq $0x10, %r15 cmpq %r12, %r14 sete %bl je 0x9b7ea movq %r14, %rdi movq %r15, %rsi callq 0x9b55b addq $0x10, %r14 addq $0x10, %r15 testb %al, %al jne 0x9b6bd jmp 0x9b7ea movq 0x8(%rdi), %rax movq 0x8(%rsi), %rcx movq 0x8(%rax), %rdx cmpq 0x8(%rcx), %rdx jne 0x9b7a7 testq %rdx, %rdx je 0x9b7ea movq (%rcx), %rsi movq (%rax), %rdi callq 0x1b930 testl %eax, %eax sete %bl jmp 0x9b7ea movq 0x8(%rdi), %rax movq 0x8(%rsi), %rcx movq (%rax), %r14 movq 0x8(%rax), %r12 movq %r12, %rax subq %r14, %rax movq (%rcx), %r15 movq 0x8(%rcx), %rcx subq %r15, %rcx cmpq %rcx, %rax jne 0x9b7a7 cmpq %r12, %r14 sete %bl je 0x9b7ea movq 0x8(%r14), %rdx cmpq 0x8(%r15), %rdx jne 0x9b7ea addq $0x20, %r14 addq $0x20, %r15 testq %rdx, %rdx je 0x9b775 movq -0x20(%r15), %rsi movq -0x20(%r14), %rdi callq 0x1b930 testl %eax, %eax jne 0x9b7ea movq %r14, %rdi movq %r15, %rsi callq 0x9b55b testb %al, %al je 0x9b7ea leaq 0x10(%r14), %rax cmpq %r12, %rax sete %bl je 0x9b7ea movq 0x18(%r14), %rdx addq $0x30, %r14 leaq 0x30(%r15), %rax cmpq 0x18(%r15), %rdx movq %rax, %r15 je 0x9b75f jmp 0x9b7ea xorl %ebx, %ebx jmp 0x9b7ea movq 0x8(%rdi), %rax movq 0x8(%rsi), %rcx leaq 0x18(%rax), %rdx leaq 0x20(%rax), %rsi leaq 0x20(%rsp), %rdi movq %rsi, (%rdi) movq %rdx, 0x8(%rdi) movq %rax, 0x10(%rdi) leaq 0x18(%rcx), %rax leaq 0x20(%rcx), %rdx leaq 0x8(%rsp), %rsi movq %rdx, (%rsi) movq %rax, 0x8(%rsi) movq %rcx, 0x10(%rsi) callq 0x9b87c movl %eax, %ebx andb $0x1, %bl movl %ebx, %eax addq $0x38, %rsp popq %rbx popq %r12 popq %r14 popq %r15 retq movl %eax, %r8d xorb $0x6, %r8b orb %dl, %r8b je 0x9b58c xorb $0x5, %al orb %cl, %al je 0x9b58c xorl %ebx, %ebx xorl %edx, %edx callq 0x9b828 jmp 0x9b7ea movq %rax, %rdi callq 0x2d543
_ZN8nlohmann16json_abi_v3_11_3eqERKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEESF_: push r15 push r14 push r12 push rbx sub rsp, 38h movzx eax, byte ptr [rdi] mov cl, [rsi] cmp al, cl jnz short loc_9B599 cmp eax, 8; switch 9 cases ja def_9B58A; jumptable 000000000009B58A default case mov bl, 1 mov eax, eax lea rcx, jpt_9B58A movsxd rax, ds:(jpt_9B58A - 0FEA54h)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_9B58C: mov rax, [rdi+8]; jumptable 000000000009B58A cases 5,6 cmp rax, [rsi+8] jmp loc_9B711 loc_9B599: mov edx, eax xor dl, 5 mov r8d, ecx xor r8b, 7 or dl, r8b jnz short loc_9B5BB cvtsi2sd xmm0, qword ptr [rdi+8] cmpeqsd xmm0, qword ptr [rsi+8] jmp loc_9B661 loc_9B5BB: mov r9d, eax xor r9b, 7 mov edx, ecx xor dl, 5 or r9b, dl jnz short loc_9B5D7 cvtsi2sd xmm0, qword ptr [rsi+8] jmp loc_9B65B loc_9B5D7: mov r9d, eax xor r9b, 6 or r9b, r8b jnz short loc_9B60B movsd xmm0, qword ptr [rdi+8] unpcklps xmm0, cs:xmmword_F5090 subpd xmm0, cs:xmmword_F50A0 movapd xmm1, xmm0 unpckhpd xmm1, xmm0 addsd xmm1, xmm0 cmpeqsd xmm1, qword ptr [rsi+8] jmp short loc_9B644 loc_9B60B: mov r8d, eax xor r8b, 7 xor cl, 6 or r8b, cl jnz loc_9B7FB movsd xmm0, qword ptr [rsi+8] unpcklps xmm0, cs:xmmword_F5090 subpd xmm0, cs:xmmword_F50A0 movapd xmm1, xmm0 unpckhpd xmm1, xmm0 addsd xmm1, xmm0 cmpeqsd xmm1, qword ptr [rdi+8] loc_9B644: movq rbx, xmm1 jmp short loc_9B666 loc_9B64B: mov al, [rdi+8]; jumptable 000000000009B58A case 4 cmp al, [rsi+8] jmp loc_9B711 loc_9B656: movsd xmm0, qword ptr [rsi+8]; jumptable 000000000009B58A case 7 loc_9B65B: cmpeqsd xmm0, qword ptr [rdi+8] loc_9B661: movq rbx, xmm0 loc_9B666: and ebx, 1 jmp loc_9B7EA; jumptable 000000000009B58A case 0 loc_9B66E: mov rax, [rdi+8]; jumptable 000000000009B58A case 2 mov rcx, [rsi+8] mov r14, [rax] mov r12, [rax+8] mov rax, r12 sub rax, r14 mov r15, [rcx] mov rcx, [rcx+8] sub rcx, r15 cmp rax, rcx jnz def_9B58A; jumptable 000000000009B58A default case cmp r14, r12 setz bl jz loc_9B7EA; jumptable 000000000009B58A case 0 mov rdi, r14 mov rsi, r15 call _ZN8nlohmann16json_abi_v3_11_3eqERKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEESF_; nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&) test al, al jz loc_9B7EA; jumptable 000000000009B58A case 0 add r14, 10h add r15, 10h loc_9B6BD: cmp r14, r12 setz bl jz loc_9B7EA; jumptable 000000000009B58A case 0 mov rdi, r14 mov rsi, r15 call _ZN8nlohmann16json_abi_v3_11_3eqERKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEESF_; nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&) add r14, 10h add r15, 10h test al, al jnz short loc_9B6BD jmp loc_9B7EA; jumptable 000000000009B58A case 0 loc_9B6E5: mov rax, [rdi+8]; jumptable 000000000009B58A case 3 mov rcx, [rsi+8] mov rdx, [rax+8] cmp rdx, [rcx+8] jnz def_9B58A; jumptable 000000000009B58A default case test rdx, rdx jz loc_9B7EA; jumptable 000000000009B58A case 0 mov rsi, [rcx] mov rdi, [rax] call _bcmp test eax, eax loc_9B711: setz bl jmp loc_9B7EA; jumptable 000000000009B58A case 0 loc_9B719: mov rax, [rdi+8]; jumptable 000000000009B58A case 1 mov rcx, [rsi+8] mov r14, [rax] mov r12, [rax+8] mov rax, r12 sub rax, r14 mov r15, [rcx] mov rcx, [rcx+8] sub rcx, r15 cmp rax, rcx jnz short def_9B58A; jumptable 000000000009B58A default case cmp r14, r12 setz bl jz loc_9B7EA; jumptable 000000000009B58A case 0 mov rdx, [r14+8] cmp rdx, [r15+8] jnz loc_9B7EA; jumptable 000000000009B58A case 0 add r14, 20h ; ' ' add r15, 20h ; ' ' loc_9B75F: test rdx, rdx jz short loc_9B775 mov rsi, [r15-20h] mov rdi, [r14-20h] call _bcmp test eax, eax jnz short loc_9B7EA; jumptable 000000000009B58A case 0 loc_9B775: mov rdi, r14 mov rsi, r15 call _ZN8nlohmann16json_abi_v3_11_3eqERKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvEESF_; nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&) test al, al jz short loc_9B7EA; jumptable 000000000009B58A case 0 lea rax, [r14+10h] cmp rax, r12 setz bl jz short loc_9B7EA; jumptable 000000000009B58A case 0 mov rdx, [r14+18h] add r14, 30h ; '0' lea rax, [r15+30h] cmp rdx, [r15+18h] mov r15, rax jz short loc_9B75F jmp short loc_9B7EA; jumptable 000000000009B58A case 0 def_9B58A: xor ebx, ebx; jumptable 000000000009B58A default case jmp short loc_9B7EA; jumptable 000000000009B58A case 0 loc_9B7AB: mov rax, [rdi+8]; jumptable 000000000009B58A case 8 mov rcx, [rsi+8] lea rdx, [rax+18h] lea rsi, [rax+20h] lea rdi, [rsp+58h+var_38] mov [rdi], rsi mov [rdi+8], rdx mov [rdi+10h], rax lea rax, [rcx+18h] lea rdx, [rcx+20h] lea rsi, [rsp+58h+var_50] mov [rsi], rdx mov [rsi+8], rax mov [rsi+10h], rcx call _ZNSt15__tuple_compareISt5tupleIJRKSt6vectorIhSaIhEERKmRKbEESA_Lm0ELm3EE4__eqERKSA_SD_; std::__tuple_compare<std::tuple<std::vector<uchar> const&,ulong const&,bool const&>,std::tuple<std::vector<uchar> const&,ulong const&,bool const&>,0ul,3ul>::__eq(std::tuple<std::vector<uchar> const&,ulong const&,bool const&> const&,std::tuple<std::vector<uchar> const&,ulong const&,bool const&> const&) mov ebx, eax loc_9B7EA: and bl, 1; jumptable 000000000009B58A case 0 mov eax, ebx add rsp, 38h pop rbx pop r12 pop r14 pop r15 retn loc_9B7FB: mov r8d, eax xor r8b, 6 or r8b, dl jz loc_9B58C; jumptable 000000000009B58A cases 5,6 xor al, 5 or al, cl jz loc_9B58C; jumptable 000000000009B58A cases 5,6 xor ebx, ebx xor edx, edx call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE18compares_unorderedERKSD_SF_b; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::compares_unordered(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,bool) jmp short loc_9B7EA; jumptable 000000000009B58A case 0 mov rdi, rax call __clang_call_terminate
long long nlohmann::json_abi_v3_11_3::operator==(unsigned __int8 *a1, unsigned __int8 *a2, __m128d a3) { unsigned int v3; // ebx unsigned __int8 v4; // al unsigned __int8 v5; // cl bool v6; // zf __m128d v7; // rt1 unsigned __int8 v8; // dl __m128d v9; // xmm0 __m128d v10; // xmm1 __m128d v11; // rt1 __int8 v12; // xmm1_1 unsigned __int8 v13; // cl __m128d v14; // xmm0 __m128d v15; // xmm1 __m128d v16; // rt1 __int8 v17; // bl __m128d v18; // rt1 long long *v19; // rax long long *v20; // rcx long long v21; // r14 long long v22; // r12 long long v23; // r15 long long v24; // r14 long long v25; // r15 char v26; // al _QWORD *v27; // rax _QWORD *v28; // rcx long long v29; // rdx long long *v30; // rax long long *v31; // rcx long long v32; // r14 long long v33; // r12 long long v34; // r15 long long v35; // rdx long long v36; // r14 long long v37; // r15 v4 = *a1; v5 = *a2; if ( *a1 == *a2 ) { LOBYTE(v3) = 1; switch ( *a1 ) { case 0u: goto LABEL_41; case 1u: v30 = (long long *)*((_QWORD *)a1 + 1); v31 = (long long *)*((_QWORD *)a2 + 1); v32 = *v30; v33 = v30[1]; v34 = *v31; if ( v33 - *v30 != v31[1] - *v31 ) goto LABEL_39; LOBYTE(v3) = v32 == v33; if ( v32 != v33 ) { v35 = *(_QWORD *)(v32 + 8); if ( v35 == *(_QWORD *)(v34 + 8) ) { v36 = v32 + 32; v37 = v34 + 32; do { if ( v35 && (unsigned int)bcmp(*(_QWORD *)(v36 - 32), *(_QWORD *)(v37 - 32)) ) break; if ( !(unsigned __int8)nlohmann::json_abi_v3_11_3::operator==(v36, v37) ) break; LOBYTE(v3) = v36 + 16 == v33; if ( v36 + 16 == v33 ) break; v35 = *(_QWORD *)(v36 + 24); v36 += 48LL; v6 = v35 == *(_QWORD *)(v37 + 24); v37 += 48LL; } while ( v6 ); } } goto LABEL_41; case 2u: v19 = (long long *)*((_QWORD *)a1 + 1); v20 = (long long *)*((_QWORD *)a2 + 1); v21 = *v19; v22 = v19[1]; v23 = *v20; if ( v22 - *v19 != v20[1] - *v20 ) goto LABEL_39; LOBYTE(v3) = v21 == v22; if ( v21 != v22 && (unsigned __int8)nlohmann::json_abi_v3_11_3::operator==(v21, v23) ) { v24 = v21 + 16; v25 = v23 + 16; do { LOBYTE(v3) = v24 == v22; if ( v24 == v22 ) break; v26 = nlohmann::json_abi_v3_11_3::operator==(v24, v25); v24 += 16LL; v25 += 16LL; } while ( v26 ); } goto LABEL_41; case 3u: v27 = (_QWORD *)*((_QWORD *)a1 + 1); v28 = (_QWORD *)*((_QWORD *)a2 + 1); v29 = v27[1]; if ( v29 != v28[1] ) goto LABEL_39; if ( !v29 ) goto LABEL_41; v6 = (unsigned int)bcmp(*v27, *v28) == 0; break; case 4u: v6 = a1[8] == a2[8]; break; case 5u: case 6u: goto LABEL_3; case 7u: a3 = (__m128d)*((unsigned long long *)a2 + 1); goto LABEL_15; case 8u: v3 = std::__tuple_compare<std::tuple<std::vector<unsigned char> const&,unsigned long const&,bool const&>,std::tuple<std::vector<unsigned char> const&,unsigned long const&,bool const&>,0ul,3ul>::__eq(); goto LABEL_41; default: LABEL_39: v3 = 0; goto LABEL_41; } LABEL_28: LOBYTE(v3) = v6; goto LABEL_41; } if ( !(v5 ^ 7 | v4 ^ 5) ) { a3.m128d_f64[0] = (double)(int)*((_QWORD *)a1 + 1); v7.m128d_f64[0] = *((double *)a2 + 1); LOBYTE(a3.m128d_f64[0]) = *(_OWORD *)&_mm_cmpeq_sd(a3, v7); LABEL_16: v17 = LOBYTE(a3.m128d_f64[0]); goto LABEL_17; } v8 = v5 ^ 5; if ( !(v5 ^ 5 | v4 ^ 7) ) { a3.m128d_f64[0] = (double)(int)*((_QWORD *)a2 + 1); LABEL_15: v18.m128d_f64[0] = *((double *)a1 + 1); LOBYTE(a3.m128d_f64[0]) = *(_OWORD *)&_mm_cmpeq_sd(a3, v18); goto LABEL_16; } if ( v5 ^ 7 | v4 ^ 6 ) { v13 = v5 ^ 6; if ( v13 | v4 ^ 7 ) { if ( v8 | v4 ^ 6 && v13 | v4 ^ 5 ) { v3 = 0; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::compares_unordered( a1, a2, 0LL); goto LABEL_41; } LABEL_3: v6 = *((_QWORD *)a1 + 1) == *((_QWORD *)a2 + 1); goto LABEL_28; } v14 = _mm_sub_pd( (__m128d)_mm_unpacklo_ps((__m128)*((unsigned long long *)a2 + 1), (__m128)xmmword_F5090), (__m128d)xmmword_F50A0); v15 = _mm_unpackhi_pd(v14, v14); v15.m128d_f64[0] = v15.m128d_f64[0] + v14.m128d_f64[0]; v16.m128d_f64[0] = *((double *)a1 + 1); v12 = *(_OWORD *)&_mm_cmpeq_sd(v15, v16); } else { v9 = _mm_sub_pd( (__m128d)_mm_unpacklo_ps((__m128)*((unsigned long long *)a1 + 1), (__m128)xmmword_F5090), (__m128d)xmmword_F50A0); v10 = _mm_unpackhi_pd(v9, v9); v10.m128d_f64[0] = v10.m128d_f64[0] + v9.m128d_f64[0]; v11.m128d_f64[0] = *((double *)a2 + 1); v12 = *(_OWORD *)&_mm_cmpeq_sd(v10, v11); } v17 = v12; LABEL_17: v3 = v17 & 1; LABEL_41: LOBYTE(v3) = v3 & 1; return v3; }
operator==: PUSH R15 PUSH R14 PUSH R12 PUSH RBX SUB RSP,0x38 MOVZX EAX,byte ptr [RDI] MOV CL,byte ptr [RSI] CMP AL,CL JNZ 0x0019b599 CMP EAX,0x8 JA 0x0019b7a7 MOV BL,0x1 MOV EAX,EAX LEA RCX,[0x1fea54] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_5: MOV RAX,qword ptr [RDI + 0x8] CMP RAX,qword ptr [RSI + 0x8] JMP 0x0019b711 LAB_0019b599: MOV EDX,EAX XOR DL,0x5 MOV R8D,ECX XOR R8B,0x7 OR DL,R8B JNZ 0x0019b5bb CVTSI2SD XMM0,qword ptr [RDI + 0x8] CMPEQSD XMM0,qword ptr [RSI + 0x8] JMP 0x0019b661 LAB_0019b5bb: MOV R9D,EAX XOR R9B,0x7 MOV EDX,ECX XOR DL,0x5 OR R9B,DL JNZ 0x0019b5d7 CVTSI2SD XMM0,qword ptr [RSI + 0x8] JMP 0x0019b65b LAB_0019b5d7: MOV R9D,EAX XOR R9B,0x6 OR R9B,R8B JNZ 0x0019b60b MOVSD XMM0,qword ptr [RDI + 0x8] UNPCKLPS XMM0,xmmword ptr [0x001f5090] SUBPD XMM0,xmmword ptr [0x001f50a0] MOVAPD XMM1,XMM0 UNPCKHPD XMM1,XMM0 ADDSD XMM1,XMM0 CMPEQSD XMM1,qword ptr [RSI + 0x8] JMP 0x0019b644 LAB_0019b60b: MOV R8D,EAX XOR R8B,0x7 XOR CL,0x6 OR R8B,CL JNZ 0x0019b7fb MOVSD XMM0,qword ptr [RSI + 0x8] UNPCKLPS XMM0,xmmword ptr [0x001f5090] SUBPD XMM0,xmmword ptr [0x001f50a0] MOVAPD XMM1,XMM0 UNPCKHPD XMM1,XMM0 ADDSD XMM1,XMM0 CMPEQSD XMM1,qword ptr [RDI + 0x8] LAB_0019b644: MOVQ RBX,XMM1 JMP 0x0019b666 caseD_4: MOV AL,byte ptr [RDI + 0x8] CMP AL,byte ptr [RSI + 0x8] JMP 0x0019b711 caseD_7: MOVSD XMM0,qword ptr [RSI + 0x8] LAB_0019b65b: CMPEQSD XMM0,qword ptr [RDI + 0x8] LAB_0019b661: MOVQ RBX,XMM0 LAB_0019b666: AND EBX,0x1 JMP 0x0019b7ea caseD_2: MOV RAX,qword ptr [RDI + 0x8] MOV RCX,qword ptr [RSI + 0x8] MOV R14,qword ptr [RAX] MOV R12,qword ptr [RAX + 0x8] MOV RAX,R12 SUB RAX,R14 MOV R15,qword ptr [RCX] MOV RCX,qword ptr [RCX + 0x8] SUB RCX,R15 CMP RAX,RCX JNZ 0x0019b7a7 CMP R14,R12 SETZ BL JZ 0x0019b7ea MOV RDI,R14 MOV RSI,R15 CALL 0x0019b55b TEST AL,AL JZ 0x0019b7ea ADD R14,0x10 ADD R15,0x10 LAB_0019b6bd: CMP R14,R12 SETZ BL JZ 0x0019b7ea MOV RDI,R14 MOV RSI,R15 CALL 0x0019b55b ADD R14,0x10 ADD R15,0x10 TEST AL,AL JNZ 0x0019b6bd JMP 0x0019b7ea caseD_3: MOV RAX,qword ptr [RDI + 0x8] MOV RCX,qword ptr [RSI + 0x8] MOV RDX,qword ptr [RAX + 0x8] CMP RDX,qword ptr [RCX + 0x8] JNZ 0x0019b7a7 TEST RDX,RDX JZ 0x0019b7ea MOV RSI,qword ptr [RCX] MOV RDI,qword ptr [RAX] CALL 0x0011b930 TEST EAX,EAX LAB_0019b711: SETZ BL JMP 0x0019b7ea caseD_1: MOV RAX,qword ptr [RDI + 0x8] MOV RCX,qword ptr [RSI + 0x8] MOV R14,qword ptr [RAX] MOV R12,qword ptr [RAX + 0x8] MOV RAX,R12 SUB RAX,R14 MOV R15,qword ptr [RCX] MOV RCX,qword ptr [RCX + 0x8] SUB RCX,R15 CMP RAX,RCX JNZ 0x0019b7a7 CMP R14,R12 SETZ BL JZ 0x0019b7ea MOV RDX,qword ptr [R14 + 0x8] CMP RDX,qword ptr [R15 + 0x8] JNZ 0x0019b7ea ADD R14,0x20 ADD R15,0x20 LAB_0019b75f: TEST RDX,RDX JZ 0x0019b775 MOV RSI,qword ptr [R15 + -0x20] MOV RDI,qword ptr [R14 + -0x20] CALL 0x0011b930 TEST EAX,EAX JNZ 0x0019b7ea LAB_0019b775: MOV RDI,R14 MOV RSI,R15 CALL 0x0019b55b TEST AL,AL JZ 0x0019b7ea LEA RAX,[R14 + 0x10] CMP RAX,R12 SETZ BL JZ 0x0019b7ea MOV RDX,qword ptr [R14 + 0x18] ADD R14,0x30 LEA RAX,[R15 + 0x30] CMP RDX,qword ptr [R15 + 0x18] MOV R15,RAX JZ 0x0019b75f JMP 0x0019b7ea LAB_0019b7a7: XOR EBX,EBX JMP 0x0019b7ea caseD_8: MOV RAX,qword ptr [RDI + 0x8] MOV RCX,qword ptr [RSI + 0x8] LEA RDX,[RAX + 0x18] LEA RSI,[RAX + 0x20] LEA RDI,[RSP + 0x20] MOV qword ptr [RDI],RSI MOV qword ptr [RDI + 0x8],RDX MOV qword ptr [RDI + 0x10],RAX LEA RAX,[RCX + 0x18] LEA RDX,[RCX + 0x20] LEA RSI,[RSP + 0x8] MOV qword ptr [RSI],RDX MOV qword ptr [RSI + 0x8],RAX MOV qword ptr [RSI + 0x10],RCX LAB_0019b7e3: CALL 0x0019b87c MOV EBX,EAX caseD_0: AND BL,0x1 MOV EAX,EBX ADD RSP,0x38 POP RBX POP R12 POP R14 POP R15 RET LAB_0019b7fb: MOV R8D,EAX XOR R8B,0x6 OR R8B,DL JZ 0x0019b58c XOR AL,0x5 OR AL,CL JZ 0x0019b58c XOR EBX,EBX XOR EDX,EDX CALL 0x0019b828 JMP 0x0019b7ea
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ /* nlohmann::json_abi_v3_11_3::TEMPNAMEPLACEHOLDERVALUE(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> const&) */ ulong nlohmann::json_abi_v3_11_3::operator==(basic_json *param_1,basic_json *param_2) { basic_json *pbVar1; basic_json bVar2; basic_json bVar3; basic_json *pbVar4; long lVar5; double dVar6; char cVar7; int iVar8; uint uVar9; size_t sVar10; ulong unaff_RBX; int7 uVar11; basic_json *pbVar12; basic_json *pbVar13; bool bVar14; long local_50; long local_48; long local_40; long local_38; long local_30; long local_28; bVar3 = *param_1; bVar2 = *param_2; if (bVar3 != bVar2) { if (bVar3 == (basic_json)0x5 && ((byte)bVar2 ^ 7) == 0) { bVar14 = (double)*(long *)(param_1 + 8) == *(double *)(param_2 + 8); } else { if (bVar3 == (basic_json)0x7 && ((byte)bVar2 ^ 5) == 0) { dVar6 = (double)*(long *)(param_2 + 8); goto LAB_0019b65b; } if (bVar3 == (basic_json)0x6 && ((byte)bVar2 ^ 7) == 0) { bVar14 = ((double)CONCAT44(DAT_001f5090._4_4_, (int)((ulong)*(int8 *)(param_1 + 8) >> 0x20)) - _UNK_001f50a8) + ((double)CONCAT44((int4)DAT_001f5090,(int)*(int8 *)(param_1 + 8)) - _DAT_001f50a0) == *(double *)(param_2 + 8); } else { if (bVar3 != (basic_json)0x7 || ((byte)bVar2 ^ 6) != 0) { if ((bVar3 != (basic_json)0x6 || ((byte)bVar2 ^ 5) != 0) && (bVar3 != (basic_json)0x5 || ((byte)bVar2 ^ 6) != 0)) { unaff_RBX = 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> ::compares_unordered(param_1,param_2,false); goto switchD_0019b58a_caseD_0; } goto switchD_0019b58a_caseD_5; } bVar14 = ((double)CONCAT44(DAT_001f5090._4_4_, (int)((ulong)*(int8 *)(param_2 + 8) >> 0x20)) - _UNK_001f50a8) + ((double)CONCAT44((int4)DAT_001f5090,(int)*(int8 *)(param_2 + 8)) - _DAT_001f50a0) == *(double *)(param_1 + 8); } } LAB_0019b666: unaff_RBX = (ulong)(-(uint)bVar14 & 1); goto switchD_0019b58a_caseD_0; } if (8 < (byte)bVar3) goto LAB_0019b7a7; uVar11 = (int7)(unaff_RBX >> 8); unaff_RBX = CONCAT71(uVar11,1); switch(bVar3) { case (basic_json)0x0: goto switchD_0019b58a_caseD_0; case (basic_json)0x1: pbVar12 = (basic_json *)**(long **)(param_1 + 8); pbVar4 = (basic_json *)(*(long **)(param_1 + 8))[1]; lVar5 = **(long **)(param_2 + 8); if ((long)pbVar4 - (long)pbVar12 == (*(long **)(param_2 + 8))[1] - lVar5) { unaff_RBX = CONCAT71(uVar11,pbVar12 == pbVar4); if ((pbVar12 != pbVar4) && (sVar10 = *(size_t *)(pbVar12 + 8), sVar10 == *(size_t *)(lVar5 + 8))) { pbVar12 = pbVar12 + 0x20; pbVar13 = (basic_json *)(lVar5 + 0x20); do { if ((((sVar10 != 0) && (iVar8 = bcmp(*(void **)(pbVar12 + -0x20),*(void **)(pbVar13 + -0x20),sVar10), iVar8 != 0)) || (cVar7 = operator==(pbVar12,pbVar13), cVar7 == '\0')) || (unaff_RBX = CONCAT71((int7)(unaff_RBX >> 8),pbVar12 + 0x10 == pbVar4), pbVar12 + 0x10 == pbVar4)) break; sVar10 = *(size_t *)(pbVar12 + 0x18); pbVar12 = pbVar12 + 0x30; pbVar1 = pbVar13 + 0x18; pbVar13 = pbVar13 + 0x30; } while (sVar10 == *(size_t *)pbVar1); } goto switchD_0019b58a_caseD_0; } break; case (basic_json)0x2: pbVar12 = (basic_json *)**(int8 **)(param_1 + 8); pbVar4 = (basic_json *)(*(int8 **)(param_1 + 8))[1]; pbVar13 = (basic_json *)**(int8 **)(param_2 + 8); if ((long)pbVar4 - (long)pbVar12 == (*(int8 **)(param_2 + 8))[1] - (long)pbVar13) { unaff_RBX = CONCAT71(uVar11,pbVar12 == pbVar4); if (pbVar12 != pbVar4) { cVar7 = operator==(pbVar12,pbVar13); while (cVar7 != '\0') { pbVar13 = pbVar13 + 0x10; pbVar12 = pbVar12 + 0x10; unaff_RBX = CONCAT71((int7)(unaff_RBX >> 8),pbVar12 == pbVar4); if (pbVar12 == pbVar4) break; cVar7 = operator==(pbVar12,pbVar13); } } goto switchD_0019b58a_caseD_0; } break; case (basic_json)0x3: sVar10 = (*(int8 **)(param_1 + 8))[1]; if (sVar10 == (*(int8 **)(param_2 + 8))[1]) { if (sVar10 == 0) goto switchD_0019b58a_caseD_0; iVar8 = bcmp((void *)**(int8 **)(param_1 + 8),(void *)**(int8 **)(param_2 + 8), sVar10); bVar14 = iVar8 == 0; goto LAB_0019b711; } break; case (basic_json)0x4: bVar14 = param_1[8] == param_2[8]; goto LAB_0019b711; default: switchD_0019b58a_caseD_5: bVar14 = *(long *)(param_1 + 8) == *(long *)(param_2 + 8); LAB_0019b711: unaff_RBX = CONCAT71((int7)(unaff_RBX >> 8),bVar14); goto switchD_0019b58a_caseD_0; case (basic_json)0x7: dVar6 = *(double *)(param_2 + 8); LAB_0019b65b: bVar14 = dVar6 == *(double *)(param_1 + 8); goto LAB_0019b666; case (basic_json)0x8: local_28 = *(long *)(param_1 + 8); local_40 = *(long *)(param_2 + 8); local_30 = local_28 + 0x18; local_38 = local_28 + 0x20; local_48 = local_40 + 0x18; local_50 = local_40 + 0x20; /* try { // try from 0019b7e3 to 0019b7e7 has its CatchHandler @ 0019b820 */ uVar9 = std:: __tuple_compare<std::tuple<std::vector<unsigned_char,std::allocator<unsigned_char>>const&,unsigned_long_const&,bool_const&>,std::tuple<std::vector<unsigned_char,std::allocator<unsigned_char>>const&,unsigned_long_const&,bool_const&>,0ul,3ul> ::__eq((tuple *)&local_38,(tuple *)&local_50); unaff_RBX = (ulong)uVar9; goto switchD_0019b58a_caseD_0; } LAB_0019b7a7: unaff_RBX = 0; switchD_0019b58a_caseD_0: return unaff_RBX & 0xffffff01; }
3,574
nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&)
monkey531[P]llama/common/json.hpp
constexpr value_t type() const noexcept { return m_data.m_type; }
O3
cpp
nlohmann::json_abi_v3_11_3::operator==(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&, nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void> const&): pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x108, %rsp # imm = 0x108 movzbl (%rdi), %r12d cmpq $0x9, %r12 ja 0xbfb01 movq %rdi, %r14 leaq 0x3d41c(%rip), %rax # 0xfcb5c movslq (%rax,%r12,4), %rcx addq %rax, %rcx jmpq *%rcx movl %r12d, %eax shll $0x6, %eax movl %r12d, %ecx shrl $0x2, %ecx orl %eax, %ecx jmp 0xbfa3b movq %r14, %rdi callq 0xbfc2c leaq 0x8(%rsp), %rdi movq %rax, %rsi callq 0x6336a jmp 0xbf9fb movl $0x9e3779b9, %r15d # imm = 0x9E3779B9 movq %r14, %rdi callq 0xbfb78 movl %r12d, %ecx shll $0x6, %ecx movl %r12d, %ebx shrl $0x2, %ebx orl %ecx, %ebx addq 0x8(%rax), %rbx addq %r15, %rbx subq (%rax), %rbx xorq %r12, %rbx movq %r14, %rdi callq 0xbfb78 movzbl 0x20(%rax), %eax movq %rbx, %rcx shlq $0x6, %rcx orq %rax, %rcx movq %rbx, %r12 shrq $0x2, %r12 addq %r15, %r12 addq %rcx, %r12 xorq %rbx, %r12 movq %r14, %rdi callq 0xbfb78 movq 0x18(%rax), %rcx addq %r15, %rcx leaq -0x1(%r15), %rdx cmpb $0x0, 0x20(%rax) cmovneq %rcx, %rdx movq %r12, %rax shlq $0x6, %rax addq %rdx, %rax movq %r12, %rbx shrq $0x2, %rbx addq %rax, %rbx xorq %r12, %rbx movq %r14, %rdi callq 0xbfb78 movq (%rax), %rcx movq 0x8(%rax), %rax cmpq %rax, %rcx je 0xbfa86 movzbl (%rcx), %edx movq %rbx, %rsi shlq $0x6, %rsi movq %rbx, %rdi shrq $0x2, %rdi addq %r15, %rsi addq %rdi, %rsi addq %rdx, %rsi xorq %rsi, %rbx incq %rcx jmp 0xbf806 movl $0x9e3779b9, %r15d # imm = 0x9E3779B9 movq %r14, %rdi callq 0x6b590 movq %rax, %rbx movl %r12d, %eax shll $0x6, %eax movl %r12d, %ecx shrl $0x2, %ecx orl %eax, %ecx addq %r15, %rbx addq %rcx, %rbx xorq %r12, %rbx leaq 0x78(%rsp), %r13 movq %r14, (%r13) xorps %xmm0, %xmm0 movups %xmm0, 0x8(%r13) movabsq $-0x8000000000000000, %rbp # imm = 0x8000000000000000 movq %rbp, 0x18(%r13) movq %r13, %rdi callq 0x9aa2a leaq 0x8(%rsp), %r12 movq %r12, %rdi movq %r13, %rsi xorl %edx, %edx callq 0xc353e leaq 0xe8(%rsp), %r13 movq %r14, (%r13) xorps %xmm0, %xmm0 movups %xmm0, 0x8(%r13) movq %rbp, 0x18(%r13) movq %r13, %rdi callq 0x9ad74 leaq 0x78(%rsp), %rdi movq %r13, %rsi xorl %edx, %edx callq 0xc353e movq %r12, %rdi leaq 0x78(%rsp), %rsi callq 0x9aa9c testb %al, %al jne 0xbfa9b movq %r12, %rdi callq 0xb842c movq %r13, %rdi movq %rax, %rsi callq 0x6336a movq %rax, %r14 movq %r12, %rdi callq 0x9a730 movq %rax, %rdi callq 0xbf717 movq %rax, %rbp movq %r12, %rdi callq 0x9a6e2 movq %rbx, %rax shlq $0x6, %rax movq %rbx, %rcx shrq $0x2, %rcx addq %r15, %rax addq %rcx, %rax addq %r14, %rax xorq %rbx, %rax movq %rax, %rcx shlq $0x6, %rcx movq %rax, %rbx shrq $0x2, %rbx addq %r15, %rcx addq %rbp, %rbx addq %rcx, %rbx xorq %rax, %rbx incq 0x28(%rsp) jmp 0xbf8c1 movl $0x9e3779b9, %r13d # imm = 0x9E3779B9 movq %r14, %rdi callq 0x6b590 movq %rax, %r15 movl %r12d, %eax shll $0x6, %eax movl %r12d, %ecx shrl $0x2, %ecx orl %eax, %ecx addq %r13, %r15 addq %rcx, %r15 xorq %r12, %r15 leaq 0x8(%rsp), %rbx movq %r14, (%rbx) xorps %xmm0, %xmm0 movups %xmm0, 0x8(%rbx) movabsq $-0x8000000000000000, %rbp # imm = 0x8000000000000000 movq %rbp, 0x18(%rbx) movq %rbx, %rdi callq 0x9aa2a leaq 0x78(%rsp), %r12 movq %r14, (%r12) xorps %xmm0, %xmm0 movups %xmm0, 0x8(%r12) movq %rbp, 0x18(%r12) movq %r12, %rdi callq 0x9ad74 movq %rbx, %rdi movq %r12, %rsi callq 0x9aa9c testb %al, %al je 0xbfab1 movq %r15, %rbx jmp 0xbfa86 leaq 0x8(%rsp), %rbx movq $0x0, (%rbx) movq %r14, %rdi movq %rbx, %rsi callq 0xbfd6c jmp 0xbfa2a leaq 0x8(%rsp), %rbx movb $0x0, (%rbx) movq %r14, %rdi movq %rbx, %rsi callq 0x951eb movzbl (%rbx), %eax movl %r12d, %ecx shll $0x6, %ecx movl %r12d, %edx shrl $0x2, %edx orl %ecx, %edx movl $0x9e3779b9, %ebx # imm = 0x9E3779B9 addq %rax, %rbx jmp 0xbfa80 leaq 0x8(%rsp), %rbx movq $0x0, (%rbx) movq %r14, %rdi movq %rbx, %rsi callq 0x94293 movl %r12d, %eax shll $0x6, %eax movl %r12d, %ecx shrl $0x2, %ecx orl %eax, %ecx addq (%rbx), %rcx movl $0x9e3779b9, %ebx # imm = 0x9E3779B9 addq %rcx, %rbx jmp 0xbfa83 leaq 0x8(%rsp), %rbx movq $0x0, (%rbx) movq %r14, %rdi movq %rbx, %rsi callq 0x94e45 movsd (%rbx), %xmm0 leaq 0x8(%rsp), %rdi callq 0xbfb46 movl %r12d, %ecx shll $0x6, %ecx movl %r12d, %edx shrl $0x2, %edx orl %ecx, %edx addq %rax, %rdx movl $0x9e3779b9, %ebx # imm = 0x9E3779B9 addq %rdx, %rbx xorq %r12, %rbx movq %rbx, %rax addq $0x108, %rsp # imm = 0x108 popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq leaq 0x78(%rsp), %rdi callq 0xb849a leaq 0x8(%rsp), %rdi callq 0xb849a jmp 0xbfa86 leaq 0x8(%rsp), %r14 leaq 0x78(%rsp), %r12 movq %r15, %rbx movq %r14, %rdi callq 0x9a730 movq %rax, %rdi callq 0xbf717 shlq $0x6, %rbx movq %r15, %rcx shrq $0x2, %rcx addq %r13, %rbx addq %rcx, %rbx addq %rax, %rbx xorq %r15, %rbx movq %r14, %rdi callq 0x9a6e2 movq %r14, %rdi movq %r12, %rsi callq 0x9aa9c movq %rbx, %r15 testb %al, %al je 0xbfabe jmp 0xbfa86 leaq 0x3a49c(%rip), %rdi # 0xf9fa4 leaq 0x34031(%rip), %rdx # 0xf3b40 leaq 0x37f8d(%rip), %rcx # 0xf7aa3 movl $0x17d9, %esi # imm = 0x17D9 xorl %eax, %eax callq 0x1bf10 jmp 0xbfb26 jmp 0xbfb26 movq %rax, %rbx leaq 0x78(%rsp), %rdi callq 0xb849a leaq 0x8(%rsp), %rdi callq 0xb849a movq %rbx, %rdi callq 0x1c020 nop
_ZN8nlohmann16json_abi_v3_11_36detail4hashINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEEmRKT_: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 108h movzx r12d, byte ptr [rdi] cmp r12, 9; switch 10 cases ja def_BF747; jumptable 00000000000BF747 default case mov r14, rdi lea rax, jpt_BF747 movsxd rcx, ds:(jpt_BF747 - 0FCB5Ch)[rax+r12*4] add rcx, rax jmp rcx; switch jump loc_BF749: mov eax, r12d; jumptable 00000000000BF747 cases 0,9 shl eax, 6 mov ecx, r12d shr ecx, 2 or ecx, eax jmp loc_BFA3B loc_BF75C: mov rdi, r14; jumptable 00000000000BF747 case 3 call _ZN8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE12get_ref_implIRKS9_KSD_EET_RT0_; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::get_ref_impl<std::string const&,nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const &) lea rdi, [rsp+138h+var_130] mov rsi, rax call _ZNKSt4hashINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEclERKS5_; std::hash<std::string>::operator()(std::string const&) jmp loc_BF9FB loc_BF776: mov r15d, 9E3779B9h; jumptable 00000000000BF747 case 8 mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE10get_binaryEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::get_binary(void) mov ecx, r12d shl ecx, 6 mov ebx, r12d shr ebx, 2 or ebx, ecx add rbx, [rax+8] add rbx, r15 sub rbx, [rax] xor rbx, r12 mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE10get_binaryEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::get_binary(void) movzx eax, byte ptr [rax+20h] mov rcx, rbx shl rcx, 6 or rcx, rax mov r12, rbx shr r12, 2 add r12, r15 add r12, rcx xor r12, rbx mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE10get_binaryEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::get_binary(void) mov rcx, [rax+18h] add rcx, r15 lea rdx, [r15-1] cmp byte ptr [rax+20h], 0 cmovnz rdx, rcx mov rax, r12 shl rax, 6 add rax, rdx mov rbx, r12 shr rbx, 2 add rbx, rax xor rbx, r12 mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE10get_binaryEv; nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>::get_binary(void) mov rcx, [rax] mov rax, [rax+8] loc_BF806: cmp rcx, rax jz loc_BFA86 movzx edx, byte ptr [rcx] mov rsi, rbx shl rsi, 6 mov rdi, rbx shr rdi, 2 add rsi, r15 add rsi, rdi add rsi, rdx xor rbx, rsi inc rcx jmp short loc_BF806 loc_BF831: mov r15d, 9E3779B9h; jumptable 00000000000BF747 case 1 mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4sizeEv; 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>::size(void) mov rbx, rax mov eax, r12d shl eax, 6 mov ecx, r12d shr ecx, 2 or ecx, eax add rbx, r15 add rbx, rcx xor rbx, r12 lea r13, [rsp+138h+var_C0] mov [r13+0], r14 xorps xmm0, xmm0 movups xmmword ptr [r13+8], xmm0 mov rbp, 8000000000000000h mov [r13+18h], rbp mov rdi, r13 call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE9set_beginEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::set_begin(void) lea r12, [rsp+138h+var_130] mov rdi, r12 mov rsi, r13 xor edx, edx call _ZN8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEEC2ESI_m; 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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> 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::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>,ulong) lea r13, [rsp+138h+var_50] mov [r13+0], r14 xorps xmm0, xmm0 movups xmmword ptr [r13+8], xmm0 mov [r13+18h], rbp mov rdi, r13 call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE7set_endEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::set_end(void) lea rdi, [rsp+138h+var_C0] mov rsi, r13 xor edx, edx call _ZN8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEEC2ESI_m; 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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> 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::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>,ulong) loc_BF8C1: mov rdi, r12 lea rsi, [rsp+138h+var_C0] call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ test al, al jnz loc_BFA9B mov rdi, r12 call _ZNK8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEE3keyEv; 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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>>::key(void) mov rdi, r13 mov rsi, rax call _ZNKSt4hashINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEclERKS5_; std::hash<std::string>::operator()(std::string const&) mov r14, rax mov rdi, r12 call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEdeEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::operator*(void) mov rdi, rax call _ZN8nlohmann16json_abi_v3_11_36detail4hashINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEEmRKT_; nlohmann::json_abi_v3_11_3::detail::hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&) mov rbp, rax mov rdi, r12 call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEppEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::operator++(void) mov rax, rbx shl rax, 6 mov rcx, rbx shr rcx, 2 add rax, r15 add rax, rcx add rax, r14 xor rax, rbx mov rcx, rax shl rcx, 6 mov rbx, rax shr rbx, 2 add rcx, r15 add rbx, rbp add rbx, rcx xor rbx, rax inc [rsp+138h+var_110] jmp loc_BF8C1 loc_BF945: mov r13d, 9E3779B9h; jumptable 00000000000BF747 case 2 mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_310basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES3_IhSaIhEEvE4sizeEv; 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>::size(void) mov r15, rax mov eax, r12d shl eax, 6 mov ecx, r12d shr ecx, 2 or ecx, eax add r15, r13 add r15, rcx xor r15, r12 lea rbx, [rsp+138h+var_130] mov [rbx], r14 xorps xmm0, xmm0 movups xmmword ptr [rbx+8], xmm0 mov rbp, 8000000000000000h mov [rbx+18h], rbp mov rdi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE9set_beginEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::set_begin(void) lea r12, [rsp+138h+var_C0] mov [r12], r14 xorps xmm0, xmm0 movups xmmword ptr [r12+8], xmm0 mov [r12+18h], rbp mov rdi, r12 call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEE7set_endEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::set_end(void) mov rdi, rbx mov rsi, r12 call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ test al, al jz loc_BFAB1 mov rbx, r15 jmp loc_BFA86 loc_BF9CC: lea rbx, [rsp+138h+var_130]; jumptable 00000000000BF747 case 6 mov qword ptr [rbx], 0 mov rdi, r14 mov rsi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEmTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_ jmp short loc_BFA2A loc_BF9E5: lea rbx, [rsp+138h+var_130]; jumptable 00000000000BF747 case 4 mov byte ptr [rbx], 0 mov rdi, r14 mov rsi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail9from_jsonINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEEvRKT_RNSG_9boolean_tE; nlohmann::json_abi_v3_11_3::detail::from_json<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&,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>::boolean_t &) movzx eax, byte ptr [rbx] loc_BF9FB: mov ecx, r12d shl ecx, 6 mov edx, r12d shr edx, 2 or edx, ecx mov ebx, 9E3779B9h add rbx, rax jmp short loc_BFA80 loc_BFA13: lea rbx, [rsp+138h+var_130]; jumptable 00000000000BF747 case 5 mov qword ptr [rbx], 0 mov rdi, r14 mov rsi, rbx call _ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEElTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_ loc_BFA2A: mov eax, r12d shl eax, 6 mov ecx, r12d shr ecx, 2 or ecx, eax add rcx, [rbx] loc_BFA3B: mov ebx, 9E3779B9h add rbx, rcx jmp short loc_BFA83 loc_BFA45: lea rbx, [rsp+138h+var_130]; jumptable 00000000000BF747 case 7 mov qword ptr [rbx], 0 mov rdi, r14 mov rsi, rbx call _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_ movsd xmm0, qword ptr [rbx] lea rdi, [rsp+138h+var_130] call _ZNKSt4hashIdEclEd; std::hash<double>::operator()(double) mov ecx, r12d shl ecx, 6 mov edx, r12d shr edx, 2 or edx, ecx add rdx, rax mov ebx, 9E3779B9h loc_BFA80: add rbx, rdx loc_BFA83: xor rbx, r12 loc_BFA86: mov rax, rbx add rsp, 108h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_BFA9B: lea rdi, [rsp+138h+var_C0] call _ZN8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEED2Ev; 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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>>::~iteration_proxy_value() lea rdi, [rsp+138h+var_130] call _ZN8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEED2Ev; 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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>>::~iteration_proxy_value() jmp short loc_BFA86 loc_BFAB1: lea r14, [rsp+138h+var_130] lea r12, [rsp+138h+var_C0] mov rbx, r15 loc_BFABE: mov rdi, r14 call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEdeEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::operator*(void) mov rdi, rax call _ZN8nlohmann16json_abi_v3_11_36detail4hashINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEEmRKT_; nlohmann::json_abi_v3_11_3::detail::hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void>>(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const&) shl rbx, 6 mov rcx, r15 shr rcx, 2 add rbx, r13 add rbx, rcx add rbx, rax xor rbx, r15 mov rdi, r14 call _ZN8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEppEv; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>::operator++(void) mov rdi, r14 mov rsi, r12 call _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ mov r15, rbx test al, al jz short loc_BFABE jmp short loc_BFA86 def_BF747: lea rdi, aWorkspaceLlm4b_0; jumptable 00000000000BF747 default case lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aAdvancedOption+0ABh; "false" mov esi, 17D9h xor eax, eax call _ggml_abort jmp short loc_BFB26 jmp short $+2 loc_BFB26: mov rbx, rax lea rdi, [rsp+138h+var_C0] call _ZN8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEED2Ev; 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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>>::~iteration_proxy_value() lea rdi, [rsp+138h+var_130] call _ZN8nlohmann16json_abi_v3_11_36detail21iteration_proxy_valueINS1_9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES6_IhSaIhEEvEEEEED2Ev; 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,ulong,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<uchar>,void> const>>::~iteration_proxy_value() mov rdi, rbx call __Unwind_Resume
unsigned long long nlohmann::json_abi_v3_11_3::detail::hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>( unsigned __int8 *a1) { long long v1; // r12 unsigned __int8 *v2; // rcx long long v3; // rax long long v4; // rax _QWORD *binary; // rax unsigned long long v6; // rbx unsigned long long v7; // r12 long long v8; // rax long long v9; // rdx unsigned long long v10; // rbx unsigned __int8 **v11; // rax unsigned __int8 *v12; // rcx unsigned __int8 *v13; // rax long long v14; // rax long long v15; // r14 long long v16; // rax long long v17; // rbp unsigned long long v18; // r15 long long v19; // rdx long long v20; // rbx long long v21; // rbx long long v23; // rax long long v24; // rbx unsigned __int8 *v25; // [rsp+8h] [rbp-130h] BYREF __int128 v26; // [rsp+10h] [rbp-128h] unsigned long long v27; // [rsp+20h] [rbp-118h] long long v28; // [rsp+28h] [rbp-110h] unsigned __int8 *v29; // [rsp+78h] [rbp-C0h] BYREF __int128 v30; // [rsp+80h] [rbp-B8h] unsigned long long v31; // [rsp+90h] [rbp-A8h] unsigned __int8 *v32; // [rsp+E8h] [rbp-50h] BYREF __int128 v33; // [rsp+F0h] [rbp-48h] unsigned long long v34; // [rsp+100h] [rbp-38h] v1 = *a1; switch ( *a1 ) { case 0u: case 9u: v2 = (unsigned __int8 *)(((_DWORD)v1 << 6) | ((unsigned int)v1 >> 2)); goto LABEL_19; case 1u: v10 = v1 ^ ((((_DWORD)v1 << 6) | ((unsigned int)v1 >> 2)) + 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>::size(a1) + 2654435769LL); v29 = a1; v30 = 0LL; v31 = 0x8000000000000000LL; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::set_begin(&v29); 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>>::iteration_proxy_value( &v25, &v29, 0LL); v32 = a1; v33 = 0LL; v34 = 0x8000000000000000LL; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::set_end(&v32); 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>>::iteration_proxy_value( &v29, &v32, 0LL); while ( !(unsigned __int8)ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_( &v25, &v29) ) { v14 = 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(&v25); v15 = std::hash<std::string>::operator()((long long)&v32, v14); v16 = nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::operator*(&v25); v17 = nlohmann::json_abi_v3_11_3::detail::hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>(v16); nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::operator++(&v25); v10 ^= (v15 + (v10 >> 2) + (v10 << 6) + 2654435769u) ^ (((v10 ^ (v15 + (v10 >> 2) + (v10 << 6) + 2654435769u)) << 6) + 2654435769u + v17 + ((v10 ^ (v15 + (v10 >> 2) + (v10 << 6) + 2654435769u)) >> 2)); ++v28; } 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>>::~iteration_proxy_value(&v29); 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>>::~iteration_proxy_value(&v25); return v10; case 2u: v18 = v1 ^ ((((_DWORD)v1 << 6) | ((unsigned int)v1 >> 2)) + 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>::size(a1) + 2654435769LL); v25 = a1; v26 = 0LL; v27 = 0x8000000000000000LL; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::set_begin(&v25); v29 = a1; v30 = 0LL; v31 = 0x8000000000000000LL; nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::set_end(&v29); if ( (unsigned __int8)ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_( &v25, &v29) ) return v18; v10 = v18; do { v23 = nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::operator*(&v25); v10 = v18 ^ (nlohmann::json_abi_v3_11_3::detail::hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>(v23) + (v18 >> 2) + (v10 << 6) + 2654435769u); nlohmann::json_abi_v3_11_3::detail::iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void> const>::operator++(&v25); v18 = v10; } while ( !(unsigned __int8)ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_( &v25, &v29) ); return v10; case 3u: v3 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::get_ref_impl<std::string 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> const>(a1); v4 = std::hash<std::string>::operator()((long long)&v25, v3); goto LABEL_16; case 4u: LOBYTE(v25) = 0; nlohmann::json_abi_v3_11_3::detail::from_json<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>>( a1, (unsigned __int8 *)&v25); v4 = (unsigned __int8)v25; LABEL_16: v19 = ((_DWORD)v1 << 6) | ((unsigned int)v1 >> 2); v20 = v4 + 2654435769LL; goto LABEL_21; case 5u: v25 = 0LL; ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEElTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_( a1, &v25); goto LABEL_18; case 6u: v25 = 0LL; ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEmTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_( a1, &v25); LABEL_18: v2 = &v25[((_DWORD)v1 << 6) | ((unsigned int)v1 >> 2)]; LABEL_19: v21 = (long long)(v2 + 2654435769LL); goto LABEL_22; case 7u: v25 = 0LL; 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_( a1, (double *)&v25); v19 = std::hash<double>::operator()(&v25, *(double *)&v25) + (((_DWORD)v1 << 6) | ((unsigned int)v1 >> 2)); v20 = 2654435769LL; LABEL_21: v21 = v19 + v20; LABEL_22: v10 = v1 ^ v21; break; case 8u: binary = (_QWORD *)nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::get_binary(a1); v6 = v1 ^ (binary[1] + (((_DWORD)v1 << 6) | ((unsigned int)v1 >> 2)) + 2654435769LL - *binary); v7 = v6 ^ ((*(unsigned __int8 *)(nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::get_binary(a1) + 32) | (v6 << 6)) + (v6 >> 2) + 2654435769u); v8 = nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::get_binary(a1); v9 = 2654435768LL; if ( *(_BYTE *)(v8 + 32) ) v9 = *(_QWORD *)(v8 + 24) + 2654435769LL; v10 = v7 ^ (v9 + (v7 << 6) + (v7 >> 2)); v11 = (unsigned __int8 **)nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>::get_binary(a1); v12 = *v11; v13 = v11[1]; while ( v12 != v13 ) v10 ^= *v12++ + (v10 >> 2) + (v10 << 6) + 2654435769u; break; default: v24 = ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 6105LL, "GGML_ASSERT(%s) failed", "false"); 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>>::~iteration_proxy_value(&v29); 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>>::~iteration_proxy_value(&v25); _Unwind_Resume(v24); } return v10; }
hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>>: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x108 MOVZX R12D,byte ptr [RDI] CMP R12,0x9 JA 0x001bfb01 MOV R14,RDI LEA RAX,[0x1fcb5c] MOVSXD RCX,dword ptr [RAX + R12*0x4] ADD RCX,RAX switchD: JMP RCX caseD_0: MOV EAX,R12D SHL EAX,0x6 MOV ECX,R12D SHR ECX,0x2 OR ECX,EAX JMP 0x001bfa3b caseD_3: MOV RDI,R14 CALL 0x001bfc2c LEA RDI,[RSP + 0x8] MOV RSI,RAX CALL 0x0016336a JMP 0x001bf9fb caseD_8: MOV R15D,0x9e3779b9 MOV RDI,R14 CALL 0x001bfb78 MOV ECX,R12D SHL ECX,0x6 MOV EBX,R12D SHR EBX,0x2 OR EBX,ECX ADD RBX,qword ptr [RAX + 0x8] ADD RBX,R15 SUB RBX,qword ptr [RAX] XOR RBX,R12 MOV RDI,R14 CALL 0x001bfb78 MOVZX EAX,byte ptr [RAX + 0x20] MOV RCX,RBX SHL RCX,0x6 OR RCX,RAX MOV R12,RBX SHR R12,0x2 ADD R12,R15 ADD R12,RCX XOR R12,RBX MOV RDI,R14 CALL 0x001bfb78 MOV RCX,qword ptr [RAX + 0x18] ADD RCX,R15 LEA RDX,[R15 + -0x1] CMP byte ptr [RAX + 0x20],0x0 CMOVNZ RDX,RCX MOV RAX,R12 SHL RAX,0x6 ADD RAX,RDX MOV RBX,R12 SHR RBX,0x2 ADD RBX,RAX XOR RBX,R12 MOV RDI,R14 CALL 0x001bfb78 MOV RCX,qword ptr [RAX] MOV RAX,qword ptr [RAX + 0x8] LAB_001bf806: CMP RCX,RAX JZ 0x001bfa86 MOVZX EDX,byte ptr [RCX] MOV RSI,RBX SHL RSI,0x6 MOV RDI,RBX SHR RDI,0x2 ADD RSI,R15 ADD RSI,RDI ADD RSI,RDX XOR RBX,RSI INC RCX JMP 0x001bf806 caseD_1: MOV R15D,0x9e3779b9 MOV RDI,R14 CALL 0x0016b590 MOV RBX,RAX MOV EAX,R12D SHL EAX,0x6 MOV ECX,R12D SHR ECX,0x2 OR ECX,EAX ADD RBX,R15 ADD RBX,RCX XOR RBX,R12 LEA R13,[RSP + 0x78] MOV qword ptr [R13],R14 XORPS XMM0,XMM0 MOVUPS xmmword ptr [R13 + 0x8],XMM0 MOV RBP,-0x8000000000000000 MOV qword ptr [R13 + 0x18],RBP MOV RDI,R13 CALL 0x0019aa2a LEA R12,[RSP + 0x8] MOV RDI,R12 MOV RSI,R13 XOR EDX,EDX CALL 0x001c353e LEA R13,[RSP + 0xe8] MOV qword ptr [R13],R14 XORPS XMM0,XMM0 MOVUPS xmmword ptr [R13 + 0x8],XMM0 MOV qword ptr [R13 + 0x18],RBP MOV RDI,R13 CALL 0x0019ad74 LEA RDI,[RSP + 0x78] MOV RSI,R13 XOR EDX,EDX CALL 0x001c353e LAB_001bf8c1: MOV RDI,R12 LEA RSI,[RSP + 0x78] CALL 0x0019aa9c TEST AL,AL JNZ 0x001bfa9b LAB_001bf8d6: MOV RDI,R12 CALL 0x001b842c MOV RDI,R13 MOV RSI,RAX CALL 0x0016336a MOV R14,RAX LAB_001bf8ec: MOV RDI,R12 CALL 0x0019a730 MOV RDI,RAX CALL 0x001bf717 LAB_001bf8fc: MOV RBP,RAX MOV RDI,R12 CALL 0x0019a6e2 LAB_001bf907: MOV RAX,RBX SHL RAX,0x6 MOV RCX,RBX SHR RCX,0x2 ADD RAX,R15 ADD RAX,RCX ADD RAX,R14 XOR RAX,RBX MOV RCX,RAX SHL RCX,0x6 MOV RBX,RAX SHR RBX,0x2 ADD RCX,R15 ADD RBX,RBP ADD RBX,RCX XOR RBX,RAX INC qword ptr [RSP + 0x28] JMP 0x001bf8c1 caseD_2: MOV R13D,0x9e3779b9 MOV RDI,R14 CALL 0x0016b590 MOV R15,RAX MOV EAX,R12D SHL EAX,0x6 MOV ECX,R12D SHR ECX,0x2 OR ECX,EAX ADD R15,R13 ADD R15,RCX XOR R15,R12 LEA RBX,[RSP + 0x8] MOV qword ptr [RBX],R14 XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX + 0x8],XMM0 MOV RBP,-0x8000000000000000 MOV qword ptr [RBX + 0x18],RBP MOV RDI,RBX CALL 0x0019aa2a LEA R12,[RSP + 0x78] MOV qword ptr [R12],R14 XORPS XMM0,XMM0 MOVUPS xmmword ptr [R12 + 0x8],XMM0 MOV qword ptr [R12 + 0x18],RBP MOV RDI,R12 CALL 0x0019ad74 MOV RDI,RBX MOV RSI,R12 CALL 0x0019aa9c TEST AL,AL JZ 0x001bfab1 MOV RBX,R15 JMP 0x001bfa86 caseD_6: LEA RBX,[RSP + 0x8] MOV qword ptr [RBX],0x0 MOV RDI,R14 MOV RSI,RBX CALL 0x001bfd6c JMP 0x001bfa2a caseD_4: LEA RBX,[RSP + 0x8] MOV byte ptr [RBX],0x0 MOV RDI,R14 MOV RSI,RBX CALL 0x001951eb MOVZX EAX,byte ptr [RBX] LAB_001bf9fb: MOV ECX,R12D SHL ECX,0x6 MOV EDX,R12D SHR EDX,0x2 OR EDX,ECX MOV EBX,0x9e3779b9 ADD RBX,RAX JMP 0x001bfa80 caseD_5: LEA RBX,[RSP + 0x8] MOV qword ptr [RBX],0x0 MOV RDI,R14 MOV RSI,RBX CALL 0x00194293 LAB_001bfa2a: MOV EAX,R12D SHL EAX,0x6 MOV ECX,R12D SHR ECX,0x2 OR ECX,EAX ADD RCX,qword ptr [RBX] LAB_001bfa3b: MOV EBX,0x9e3779b9 ADD RBX,RCX JMP 0x001bfa83 caseD_7: LEA RBX,[RSP + 0x8] MOV qword ptr [RBX],0x0 MOV RDI,R14 MOV RSI,RBX CALL 0x00194e45 MOVSD XMM0,qword ptr [RBX] LEA RDI,[RSP + 0x8] CALL 0x001bfb46 MOV ECX,R12D SHL ECX,0x6 MOV EDX,R12D SHR EDX,0x2 OR EDX,ECX ADD RDX,RAX MOV EBX,0x9e3779b9 LAB_001bfa80: ADD RBX,RDX LAB_001bfa83: XOR RBX,R12 LAB_001bfa86: MOV RAX,RBX ADD RSP,0x108 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_001bfa9b: LEA RDI,[RSP + 0x78] CALL 0x001b849a LEA RDI,[RSP + 0x8] CALL 0x001b849a JMP 0x001bfa86 LAB_001bfab1: LEA R14,[RSP + 0x8] LEA R12,[RSP + 0x78] MOV RBX,R15 LAB_001bfabe: MOV RDI,R14 CALL 0x0019a730 MOV RDI,RAX CALL 0x001bf717 SHL RBX,0x6 MOV RCX,R15 SHR RCX,0x2 ADD RBX,R13 ADD RBX,RCX ADD RBX,RAX XOR RBX,R15 MOV RDI,R14 CALL 0x0019a6e2 MOV RDI,R14 MOV RSI,R12 CALL 0x0019aa9c MOV R15,RBX TEST AL,AL JZ 0x001bfabe JMP 0x001bfa86 default: LEA RDI,[0x1f9fa4] LEA RDX,[0x1f3b40] LEA RCX,[0x1f7aa3] MOV ESI,0x17d9 XOR EAX,EAX CALL 0x0011bf10
/* unsigned long nlohmann::json_abi_v3_11_3::detail::hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void> >(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&) */ ulong nlohmann::json_abi_v3_11_3::detail:: hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> (basic_json *param_1) { basic_json bVar1; char cVar2; string *psVar3; ulong uVar4; long *plVar5; long lVar6; long lVar7; int8 *puVar8; byte *pbVar9; ulong uVar10; basic_json *pbVar11; ulong uVar12; basic_json *local_130; int8 local_128; int8 uStack_120; int8 local_118; long local_110; basic_json *local_c0; int8 local_b8; int8 uStack_b0; int8 local_a8; basic_json *local_50; int8 local_48; int8 uStack_40; int8 local_38; bVar1 = *param_1; uVar12 = (ulong)(byte)bVar1; local_c0 = param_1; switch(uVar12) { case 0: case 9: pbVar11 = (basic_json *)(ulong)((uint)((byte)bVar1 >> 2) | (uint)(byte)bVar1 << 6); goto LAB_001bfa3b; case 1: lVar6 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::size((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *)param_1); uVar12 = lVar6 + 0x9e3779b9 + (ulong)((uint)((byte)bVar1 >> 2) | (uint)(byte)bVar1 << 6) ^ uVar12; local_b8 = 0; uStack_b0 = 0; local_a8 = 0x8000000000000000; iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> ::set_begin((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_c0); 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>> ::iteration_proxy_value ((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>> *)&local_130, (iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_c0,0); local_48 = 0; uStack_40 = 0; local_38 = 0x8000000000000000; local_50 = param_1; iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> ::set_end((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_50); 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>> ::iteration_proxy_value ((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>> *)&local_c0, (iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_50,0); /* try { // try from 001bf8c1 to 001bf8cd has its CatchHandler @ 001bfb26 */ while (cVar2 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ ((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>> *)&local_130,&local_c0), cVar2 == '\0') { /* try { // try from 001bf8d6 to 001bf8dd has its CatchHandler @ 001bfb22 */ psVar3 = (string *) 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>> *)&local_130); lVar6 = std::hash<std::__cxx11::string>::operator() ((hash<std::__cxx11::string> *)&local_50,psVar3); /* try { // try from 001bf8ec to 001bf8fb has its CatchHandler @ 001bfb24 */ pbVar11 = (basic_json *) iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> ::operator*((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_130); uVar10 = hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> (pbVar11); /* try { // try from 001bf8fc to 001bf906 has its CatchHandler @ 001bfb26 */ iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> ::operator++((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_130); uVar12 = uVar12 * 0x40 + 0x9e3779b9 + (uVar12 >> 2) + lVar6 ^ uVar12; uVar12 = (uVar12 >> 2) + uVar10 + uVar12 * 0x40 + 0x9e3779b9 ^ uVar12; local_110 = local_110 + 1; } 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>> ::~iteration_proxy_value ((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>> *)&local_c0); 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>> ::~iteration_proxy_value ((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>> *)&local_130); break; case 2: lVar6 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::size((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> *)param_1); uVar12 = lVar6 + 0x9e3779b9 + (ulong)((uint)((byte)bVar1 >> 2) | (uint)(byte)bVar1 << 6) ^ uVar12; local_128 = 0; uStack_120 = 0; local_118 = 0x8000000000000000; local_130 = param_1; iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> ::set_begin((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_130); local_b8 = 0; uStack_b0 = 0; local_a8 = 0x8000000000000000; iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> ::set_end((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_c0); cVar2 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ ((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_130, (iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_c0); if (cVar2 == '\0') { do { pbVar11 = (basic_json *) iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> ::operator*((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_130); uVar10 = hash<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>> (pbVar11); uVar12 = uVar12 * 0x40 + 0x9e3779b9 + (uVar12 >> 2) + uVar10 ^ uVar12; iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> ::operator++((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_130); cVar2 = _ZNK8nlohmann16json_abi_v3_11_36detail9iter_implIKNS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEEeqISH_TnNSt9enable_ifIXoosr3std7is_sameIT_SH_EE5valuesr3std7is_sameISK_NS2_ISF_EEEE5valueEDnE4typeELDn0EEEbRKSK_ ((iter_impl<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>const> *)&local_130,&local_c0); } while (cVar2 == '\0'); } break; case 3: psVar3 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> :: get_ref_impl<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>const> (param_1); uVar4 = std::hash<std::__cxx11::string>::operator() ((hash<std::__cxx11::string> *)&local_130,psVar3); goto LAB_001bf9fb; case 4: local_130 = (basic_json *)((ulong)local_130 & 0xffffffffffffff00); from_json<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,(boolean_t *)&local_130); uVar4 = (ulong)local_130 & 0xff; LAB_001bf9fb: uVar10 = (ulong)((uint)((byte)bVar1 >> 2) | (uint)(byte)bVar1 << 6); lVar6 = uVar4 + 0x9e3779b9; LAB_001bfa80: pbVar11 = (basic_json *)(lVar6 + uVar10); LAB_001bfa83: uVar12 = (ulong)pbVar11 ^ uVar12; break; case 5: local_130 = (basic_json *)0x0; _ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEElTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_ (param_1,&local_130); goto LAB_001bfa2a; case 6: local_130 = (basic_json *)0x0; _ZN8nlohmann16json_abi_v3_11_36detail20get_arithmetic_valueINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEEmTnNSt9enable_ifIXaasr3std13is_arithmeticIT0_EE5valuentsr3std7is_sameISH_NT_9boolean_tEEE5valueEiE4typeELi0EEEvRKSI_RSH_ (param_1,&local_130); LAB_001bfa2a: pbVar11 = local_130 + ((uint)((byte)bVar1 >> 2) | (uint)(byte)bVar1 << 6); LAB_001bfa3b: pbVar11 = pbVar11 + 0x9e3779b9; goto LAB_001bfa83; case 7: local_130 = (basic_json *)0x0; _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_ (param_1,&local_130); lVar6 = std::hash<double>::operator()((hash<double> *)&local_130,(double)local_130); uVar10 = (ulong)((uint)((byte)bVar1 >> 2) | (uint)(byte)bVar1 << 6) + lVar6; lVar6 = 0x9e3779b9; goto LAB_001bfa80; case 8: plVar5 = (long *)basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::get_binary((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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); uVar12 = ((ulong)((uint)((byte)bVar1 >> 2) | (uint)(byte)bVar1 << 6) + plVar5[1] + 0x9e3779b9) - *plVar5 ^ uVar12; lVar6 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::get_binary((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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); uVar12 = (uVar12 >> 2) + 0x9e3779b9 + (uVar12 << 6 | (ulong)*(byte *)(lVar6 + 0x20)) ^ uVar12; lVar7 = basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::get_binary((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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); lVar6 = 0x9e3779b8; if (*(char *)(lVar7 + 0x20) != '\0') { lVar6 = *(long *)(lVar7 + 0x18) + 0x9e3779b9; } uVar12 = (uVar12 >> 2) + uVar12 * 0x40 + lVar6 ^ uVar12; puVar8 = (int8 *) basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void> ::get_binary((basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,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); for (pbVar9 = (byte *)*puVar8; pbVar9 != (byte *)puVar8[1]; pbVar9 = pbVar9 + 1) { uVar12 = uVar12 ^ uVar12 * 0x40 + 0x9e3779b9 + (uVar12 >> 2) + (ulong)*pbVar9; } break; default: /* WARNING: Subroutine does not return */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",0x17d9, "GGML_ASSERT(%s) failed","false"); } return uVar12; }
3,575
dequantize_row_q3_K
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-quants.c
void dequantize_row_q3_K(const block_q3_K * restrict x, float * restrict y, int64_t k) { assert(k % QK_K == 0); const int nb = k / QK_K; const uint32_t kmask1 = 0x03030303; const uint32_t kmask2 = 0x0f0f0f0f; uint32_t aux[4]; const int8_t * scales = (const int8_t*)aux; for (int i = 0; i < nb; i++) { const float d_all = GGML_FP16_TO_FP32(x[i].d); const uint8_t * restrict q = x[i].qs; const uint8_t * restrict hm = x[i].hmask; uint8_t m = 1; memcpy(aux, x[i].scales, 12); uint32_t tmp = aux[2]; aux[2] = ((aux[0] >> 4) & kmask2) | (((tmp >> 4) & kmask1) << 4); aux[3] = ((aux[1] >> 4) & kmask2) | (((tmp >> 6) & kmask1) << 4); aux[0] = (aux[0] & kmask2) | (((tmp >> 0) & kmask1) << 4); aux[1] = (aux[1] & kmask2) | (((tmp >> 2) & kmask1) << 4); int is = 0; float dl; for (int n = 0; n < QK_K; n += 128) { int shift = 0; for (int j = 0; j < 4; ++j) { dl = d_all * (scales[is++] - 32); for (int l = 0; l < 16; ++l) { *y++ = dl * ((int8_t)((q[l+ 0] >> shift) & 3) - ((hm[l+ 0] & m) ? 0 : 4)); } dl = d_all * (scales[is++] - 32); for (int l = 0; l < 16; ++l) { *y++ = dl * ((int8_t)((q[l+16] >> shift) & 3) - ((hm[l+16] & m) ? 0 : 4)); } shift += 2; m <<= 1; } q += 32; } } }
O0
c
dequantize_row_q3_K: pushq %rbp movq %rsp, %rbp subq $0x90, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x18(%rbp), %rax movl $0x100, %ecx # imm = 0x100 cqto idivq %rcx cmpq $0x0, %rdx jne 0x715bd jmp 0x715dc leaq 0x4fb80(%rip), %rdi # 0xc1144 leaq 0x4f791(%rip), %rsi # 0xc0d5c movl $0x421, %edx # imm = 0x421 leaq 0x4fc6c(%rip), %rcx # 0xc1243 callq 0x44810 movq -0x18(%rbp), %rax movl $0x100, %ecx # imm = 0x100 cqto idivq %rcx movl %eax, -0x1c(%rbp) movl $0x3030303, -0x20(%rbp) # imm = 0x3030303 movl $0xf0f0f0f, -0x24(%rbp) # imm = 0xF0F0F0F leaq -0x40(%rbp), %rax movq %rax, -0x48(%rbp) movl $0x0, -0x4c(%rbp) movl -0x4c(%rbp), %eax cmpl -0x1c(%rbp), %eax jge 0x718d8 movq -0x8(%rbp), %rax movslq -0x4c(%rbp), %rcx imulq $0x6e, %rcx, %rcx addq %rcx, %rax movzwl 0x6c(%rax), %edi callq 0x6e6e0 movss %xmm0, -0x50(%rbp) movq -0x8(%rbp), %rax movslq -0x4c(%rbp), %rcx imulq $0x6e, %rcx, %rcx addq %rcx, %rax addq $0x20, %rax movq %rax, -0x58(%rbp) movq -0x8(%rbp), %rax movslq -0x4c(%rbp), %rcx imulq $0x6e, %rcx, %rcx addq %rcx, %rax movq %rax, -0x60(%rbp) movb $0x1, -0x61(%rbp) movq -0x8(%rbp), %rax movslq -0x4c(%rbp), %rcx imulq $0x6e, %rcx, %rcx addq %rcx, %rax movq 0x60(%rax), %rcx movq %rcx, -0x40(%rbp) movl 0x68(%rax), %eax movl %eax, -0x38(%rbp) movl -0x38(%rbp), %eax movl %eax, -0x68(%rbp) movl -0x40(%rbp), %eax shrl $0x4, %eax andl $0xf0f0f0f, %eax # imm = 0xF0F0F0F movl -0x68(%rbp), %ecx shrl $0x4, %ecx andl $0x3030303, %ecx # imm = 0x3030303 shll $0x4, %ecx orl %ecx, %eax movl %eax, -0x38(%rbp) movl -0x3c(%rbp), %eax shrl $0x4, %eax andl $0xf0f0f0f, %eax # imm = 0xF0F0F0F movl -0x68(%rbp), %ecx shrl $0x6, %ecx andl $0x3030303, %ecx # imm = 0x3030303 shll $0x4, %ecx orl %ecx, %eax movl %eax, -0x34(%rbp) movl -0x40(%rbp), %eax andl $0xf0f0f0f, %eax # imm = 0xF0F0F0F movl -0x68(%rbp), %ecx shrl $0x0, %ecx andl $0x3030303, %ecx # imm = 0x3030303 shll $0x4, %ecx orl %ecx, %eax movl %eax, -0x40(%rbp) movl -0x3c(%rbp), %eax andl $0xf0f0f0f, %eax # imm = 0xF0F0F0F movl -0x68(%rbp), %ecx shrl $0x2, %ecx andl $0x3030303, %ecx # imm = 0x3030303 shll $0x4, %ecx orl %ecx, %eax movl %eax, -0x3c(%rbp) movl $0x0, -0x6c(%rbp) movl $0x0, -0x74(%rbp) cmpl $0x100, -0x74(%rbp) # imm = 0x100 jge 0x718c8 movl $0x0, -0x78(%rbp) movl $0x0, -0x7c(%rbp) cmpl $0x4, -0x7c(%rbp) jge 0x718ac movss -0x50(%rbp), %xmm0 movq -0x48(%rbp), %rax movl -0x6c(%rbp), %ecx movl %ecx, %edx addl $0x1, %edx movl %edx, -0x6c(%rbp) movslq %ecx, %rcx movsbl (%rax,%rcx), %eax subl $0x20, %eax cvtsi2ss %eax, %xmm1 mulss %xmm1, %xmm0 movss %xmm0, -0x70(%rbp) movl $0x0, -0x80(%rbp) cmpl $0x10, -0x80(%rbp) jge 0x717d2 movss -0x70(%rbp), %xmm0 movq -0x58(%rbp), %rax movl -0x80(%rbp), %ecx addl $0x0, %ecx movslq %ecx, %rcx movzbl (%rax,%rcx), %eax movl -0x78(%rbp), %ecx sarl %cl, %eax andl $0x3, %eax movsbl %al, %eax movq -0x60(%rbp), %rcx movl -0x80(%rbp), %edx addl $0x0, %edx movslq %edx, %rdx movzbl (%rcx,%rdx), %esi movzbl -0x61(%rbp), %ecx andl %ecx, %esi movl $0x4, %ecx xorl %edx, %edx cmpl $0x0, %esi cmovnel %edx, %ecx subl %ecx, %eax cvtsi2ss %eax, %xmm1 mulss %xmm1, %xmm0 movq -0x10(%rbp), %rax movq %rax, %rcx addq $0x4, %rcx movq %rcx, -0x10(%rbp) movss %xmm0, (%rax) movl -0x80(%rbp), %eax addl $0x1, %eax movl %eax, -0x80(%rbp) jmp 0x7175f movss -0x50(%rbp), %xmm0 movq -0x48(%rbp), %rax movl -0x6c(%rbp), %ecx movl %ecx, %edx addl $0x1, %edx movl %edx, -0x6c(%rbp) movslq %ecx, %rcx movsbl (%rax,%rcx), %eax subl $0x20, %eax cvtsi2ss %eax, %xmm1 mulss %xmm1, %xmm0 movss %xmm0, -0x70(%rbp) movl $0x0, -0x84(%rbp) cmpl $0x10, -0x84(%rbp) jge 0x7188c movss -0x70(%rbp), %xmm0 movq -0x58(%rbp), %rax movl -0x84(%rbp), %ecx addl $0x10, %ecx movslq %ecx, %rcx movzbl (%rax,%rcx), %eax movl -0x78(%rbp), %ecx sarl %cl, %eax andl $0x3, %eax movsbl %al, %eax movq -0x60(%rbp), %rcx movl -0x84(%rbp), %edx addl $0x10, %edx movslq %edx, %rdx movzbl (%rcx,%rdx), %esi movzbl -0x61(%rbp), %ecx andl %ecx, %esi movl $0x4, %ecx xorl %edx, %edx cmpl $0x0, %esi cmovnel %edx, %ecx subl %ecx, %eax cvtsi2ss %eax, %xmm1 mulss %xmm1, %xmm0 movq -0x10(%rbp), %rax movq %rax, %rcx addq $0x4, %rcx movq %rcx, -0x10(%rbp) movss %xmm0, (%rax) movl -0x84(%rbp), %eax addl $0x1, %eax movl %eax, -0x84(%rbp) jmp 0x71807 movl -0x78(%rbp), %eax addl $0x2, %eax movl %eax, -0x78(%rbp) movzbl -0x61(%rbp), %eax shll %eax movb %al, -0x61(%rbp) movl -0x7c(%rbp), %eax addl $0x1, %eax movl %eax, -0x7c(%rbp) jmp 0x71723 movq -0x58(%rbp), %rax addq $0x20, %rax movq %rax, -0x58(%rbp) movl -0x74(%rbp), %eax addl $0x80, %eax movl %eax, -0x74(%rbp) jmp 0x71708 jmp 0x718ca movl -0x4c(%rbp), %eax addl $0x1, %eax movl %eax, -0x4c(%rbp) jmp 0x7160a addq $0x90, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
dequantize_row_q3_K: push rbp mov rbp, rsp sub rsp, 90h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_18] mov ecx, 100h cqo idiv rcx cmp rdx, 0 jnz short loc_715BD jmp short loc_715DC loc_715BD: lea rdi, aKQkK0; "k % QK_K == 0" lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"... mov edx, 421h lea rcx, aVoidDequantize_5; "void dequantize_row_q3_K(const block_q3"... call ___assert_fail loc_715DC: mov rax, [rbp+var_18] mov ecx, 100h cqo idiv rcx mov [rbp+var_1C], eax mov [rbp+var_20], 3030303h mov [rbp+var_24], 0F0F0F0Fh lea rax, [rbp+var_40] mov [rbp+var_48], rax mov [rbp+var_4C], 0 loc_7160A: mov eax, [rbp+var_4C] cmp eax, [rbp+var_1C] jge loc_718D8 mov rax, [rbp+var_8] movsxd rcx, [rbp+var_4C] imul rcx, 6Eh ; 'n' add rax, rcx movzx edi, word ptr [rax+6Ch] call ggml_lookup_fp16_to_fp32_0 movss [rbp+var_50], xmm0 mov rax, [rbp+var_8] movsxd rcx, [rbp+var_4C] imul rcx, 6Eh ; 'n' add rax, rcx add rax, 20h ; ' ' mov [rbp+var_58], rax mov rax, [rbp+var_8] movsxd rcx, [rbp+var_4C] imul rcx, 6Eh ; 'n' add rax, rcx mov [rbp+var_60], rax mov [rbp+var_61], 1 mov rax, [rbp+var_8] movsxd rcx, [rbp+var_4C] imul rcx, 6Eh ; 'n' add rax, rcx mov rcx, [rax+60h] mov [rbp+var_40], rcx mov eax, [rax+68h] mov [rbp+var_38], eax mov eax, [rbp+var_38] mov [rbp+var_68], eax mov eax, dword ptr [rbp+var_40] shr eax, 4 and eax, 0F0F0F0Fh mov ecx, [rbp+var_68] shr ecx, 4 and ecx, 3030303h shl ecx, 4 or eax, ecx mov [rbp+var_38], eax mov eax, dword ptr [rbp+var_40+4] shr eax, 4 and eax, 0F0F0F0Fh mov ecx, [rbp+var_68] shr ecx, 6 and ecx, 3030303h shl ecx, 4 or eax, ecx mov [rbp+var_34], eax mov eax, dword ptr [rbp+var_40] and eax, 0F0F0F0Fh mov ecx, [rbp+var_68] shr ecx, 0 and ecx, 3030303h shl ecx, 4 or eax, ecx mov dword ptr [rbp+var_40], eax mov eax, dword ptr [rbp+var_40+4] and eax, 0F0F0F0Fh mov ecx, [rbp+var_68] shr ecx, 2 and ecx, 3030303h shl ecx, 4 or eax, ecx mov dword ptr [rbp+var_40+4], eax mov [rbp+var_6C], 0 mov [rbp+var_74], 0 loc_71708: cmp [rbp+var_74], 100h jge loc_718C8 mov [rbp+var_78], 0 mov [rbp+var_7C], 0 loc_71723: cmp [rbp+var_7C], 4 jge loc_718AC movss xmm0, [rbp+var_50] mov rax, [rbp+var_48] mov ecx, [rbp+var_6C] mov edx, ecx add edx, 1 mov [rbp+var_6C], edx movsxd rcx, ecx movsx eax, byte ptr [rax+rcx] sub eax, 20h ; ' ' cvtsi2ss xmm1, eax mulss xmm0, xmm1 movss [rbp+var_70], xmm0 mov [rbp+var_80], 0 loc_7175F: cmp [rbp+var_80], 10h jge short loc_717D2 movss xmm0, [rbp+var_70] mov rax, [rbp+var_58] mov ecx, [rbp+var_80] add ecx, 0 movsxd rcx, ecx movzx eax, byte ptr [rax+rcx] mov ecx, [rbp+var_78] sar eax, cl and eax, 3 movsx eax, al mov rcx, [rbp+var_60] mov edx, [rbp+var_80] add edx, 0 movsxd rdx, edx movzx esi, byte ptr [rcx+rdx] movzx ecx, [rbp+var_61] and esi, ecx mov ecx, 4 xor edx, edx cmp esi, 0 cmovnz ecx, edx sub eax, ecx cvtsi2ss xmm1, eax mulss xmm0, xmm1 mov rax, [rbp+var_10] mov rcx, rax add rcx, 4 mov [rbp+var_10], rcx movss dword ptr [rax], xmm0 mov eax, [rbp+var_80] add eax, 1 mov [rbp+var_80], eax jmp short loc_7175F loc_717D2: movss xmm0, [rbp+var_50] mov rax, [rbp+var_48] mov ecx, [rbp+var_6C] mov edx, ecx add edx, 1 mov [rbp+var_6C], edx movsxd rcx, ecx movsx eax, byte ptr [rax+rcx] sub eax, 20h ; ' ' cvtsi2ss xmm1, eax mulss xmm0, xmm1 movss [rbp+var_70], xmm0 mov [rbp+var_84], 0 loc_71807: cmp [rbp+var_84], 10h jge short loc_7188C movss xmm0, [rbp+var_70] mov rax, [rbp+var_58] mov ecx, [rbp+var_84] add ecx, 10h movsxd rcx, ecx movzx eax, byte ptr [rax+rcx] mov ecx, [rbp+var_78] sar eax, cl and eax, 3 movsx eax, al mov rcx, [rbp+var_60] mov edx, [rbp+var_84] add edx, 10h movsxd rdx, edx movzx esi, byte ptr [rcx+rdx] movzx ecx, [rbp+var_61] and esi, ecx mov ecx, 4 xor edx, edx cmp esi, 0 cmovnz ecx, edx sub eax, ecx cvtsi2ss xmm1, eax mulss xmm0, xmm1 mov rax, [rbp+var_10] mov rcx, rax add rcx, 4 mov [rbp+var_10], rcx movss dword ptr [rax], xmm0 mov eax, [rbp+var_84] add eax, 1 mov [rbp+var_84], eax jmp loc_71807 loc_7188C: mov eax, [rbp+var_78] add eax, 2 mov [rbp+var_78], eax movzx eax, [rbp+var_61] shl eax, 1 mov [rbp+var_61], al mov eax, [rbp+var_7C] add eax, 1 mov [rbp+var_7C], eax jmp loc_71723 loc_718AC: mov rax, [rbp+var_58] add rax, 20h ; ' ' mov [rbp+var_58], rax mov eax, [rbp+var_74] add eax, 80h mov [rbp+var_74], eax jmp loc_71708 loc_718C8: jmp short $+2 loc_718CA: mov eax, [rbp+var_4C] add eax, 1 mov [rbp+var_4C], eax jmp loc_7160A loc_718D8: add rsp, 90h pop rbp retn
long long dequantize_row_q3_K(long long a1, float *a2, long long a3) { long long result; // rax int v4; // ecx int v5; // ecx float v6; // xmm0_4 float *v7; // rax int v8; // ecx int v9; // ecx float v10; // xmm0_4 float *v11; // rax int n; // [rsp+Ch] [rbp-84h] int m; // [rsp+10h] [rbp-80h] int k; // [rsp+14h] [rbp-7Ch] char v15; // [rsp+18h] [rbp-78h] int j; // [rsp+1Ch] [rbp-74h] float v17; // [rsp+20h] [rbp-70h] float v18; // [rsp+20h] [rbp-70h] int v19; // [rsp+24h] [rbp-6Ch] int v20; // [rsp+24h] [rbp-6Ch] unsigned int v21; // [rsp+28h] [rbp-68h] char v22; // [rsp+2Fh] [rbp-61h] long long v23; // [rsp+30h] [rbp-60h] long long v24; // [rsp+38h] [rbp-58h] float v25; // [rsp+40h] [rbp-50h] unsigned int i; // [rsp+44h] [rbp-4Ch] long long v27; // [rsp+50h] [rbp-40h] unsigned int v28; // [rsp+58h] [rbp-38h] int v29; // [rsp+5Ch] [rbp-34h] int v30; // [rsp+6Ch] [rbp-24h] int v31; // [rsp+70h] [rbp-20h] int v32; // [rsp+74h] [rbp-1Ch] long long v33; // [rsp+78h] [rbp-18h] float *v34; // [rsp+80h] [rbp-10h] long long v35; // [rsp+88h] [rbp-8h] v35 = a1; v34 = a2; v33 = a3; if ( a3 % 256 ) __assert_fail( "k % QK_K == 0", "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-quants.c", 1057LL, "void dequantize_row_q3_K(const block_q3_K *restrict, float *restrict, int64_t)"); v32 = v33 / 256; v31 = 50529027; v30 = 252645135; for ( i = 0; ; ++i ) { result = i; if ( (int)i >= v32 ) break; v25 = ggml_lookup_fp16_to_fp32_0(*(_WORD *)(110LL * (int)i + v35 + 108)); v24 = 110LL * (int)i + v35 + 32; v23 = 110LL * (int)i + v35; v22 = 1; v27 = *(_QWORD *)(v23 + 96); v28 = *(_DWORD *)(v23 + 104); v21 = v28; v28 = (16 * ((v28 >> 4) & 0x3030303)) | ((unsigned int)v27 >> 4) & 0xF0F0F0F; v29 = (16 * ((v21 >> 6) & 0x3030303)) | (HIDWORD(v27) >> 4) & 0xF0F0F0F; LODWORD(v27) = (16 * (v21 & 0x3030303)) | v27 & 0xF0F0F0F; HIDWORD(v27) = (16 * ((v21 >> 2) & 0x3030303)) | HIDWORD(v27) & 0xF0F0F0F; v19 = 0; for ( j = 0; j < 256; j += 128 ) { v15 = 0; for ( k = 0; k < 4; ++k ) { v4 = v19; v20 = v19 + 1; v17 = v25 * (float)(*((char *)&v27 + v4) - 32); for ( m = 0; m < 16; ++m ) { v5 = 4; if ( ((unsigned __int8)v22 & *(_BYTE *)(v23 + m)) != 0 ) v5 = 0; v6 = v17 * (float)((((int)*(unsigned __int8 *)(v24 + m) >> v15) & 3) - v5); v7 = v34++; *v7 = v6; } v8 = v20; v19 = v20 + 1; v18 = v25 * (float)(*((char *)&v27 + v8) - 32); for ( n = 0; n < 16; ++n ) { v9 = 4; if ( ((unsigned __int8)v22 & *(_BYTE *)(v23 + n + 16)) != 0 ) v9 = 0; v10 = v18 * (float)((((int)*(unsigned __int8 *)(v24 + n + 16) >> v15) & 3) - v9); v11 = v34++; *v11 = v10; } v15 += 2; v22 *= 2; } v24 += 32LL; } } return result; }
dequantize_row_q3_K: PUSH RBP MOV RBP,RSP SUB RSP,0x90 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI MOV qword ptr [RBP + -0x18],RDX MOV RAX,qword ptr [RBP + -0x18] MOV ECX,0x100 CQO IDIV RCX CMP RDX,0x0 JNZ 0x001715bd JMP 0x001715dc LAB_001715bd: LEA RDI,[0x1c1144] LEA RSI,[0x1c0d5c] MOV EDX,0x421 LEA RCX,[0x1c1243] CALL 0x00144810 LAB_001715dc: MOV RAX,qword ptr [RBP + -0x18] MOV ECX,0x100 CQO IDIV RCX MOV dword ptr [RBP + -0x1c],EAX MOV dword ptr [RBP + -0x20],0x3030303 MOV dword ptr [RBP + -0x24],0xf0f0f0f LEA RAX,[RBP + -0x40] MOV qword ptr [RBP + -0x48],RAX MOV dword ptr [RBP + -0x4c],0x0 LAB_0017160a: MOV EAX,dword ptr [RBP + -0x4c] CMP EAX,dword ptr [RBP + -0x1c] JGE 0x001718d8 MOV RAX,qword ptr [RBP + -0x8] MOVSXD RCX,dword ptr [RBP + -0x4c] IMUL RCX,RCX,0x6e ADD RAX,RCX MOVZX EDI,word ptr [RAX + 0x6c] CALL 0x0016e6e0 MOVSS dword ptr [RBP + -0x50],XMM0 MOV RAX,qword ptr [RBP + -0x8] MOVSXD RCX,dword ptr [RBP + -0x4c] IMUL RCX,RCX,0x6e ADD RAX,RCX ADD RAX,0x20 MOV qword ptr [RBP + -0x58],RAX MOV RAX,qword ptr [RBP + -0x8] MOVSXD RCX,dword ptr [RBP + -0x4c] IMUL RCX,RCX,0x6e ADD RAX,RCX MOV qword ptr [RBP + -0x60],RAX MOV byte ptr [RBP + -0x61],0x1 MOV RAX,qword ptr [RBP + -0x8] MOVSXD RCX,dword ptr [RBP + -0x4c] IMUL RCX,RCX,0x6e ADD RAX,RCX MOV RCX,qword ptr [RAX + 0x60] MOV qword ptr [RBP + -0x40],RCX MOV EAX,dword ptr [RAX + 0x68] MOV dword ptr [RBP + -0x38],EAX MOV EAX,dword ptr [RBP + -0x38] MOV dword ptr [RBP + -0x68],EAX MOV EAX,dword ptr [RBP + -0x40] SHR EAX,0x4 AND EAX,0xf0f0f0f MOV ECX,dword ptr [RBP + -0x68] SHR ECX,0x4 AND ECX,0x3030303 SHL ECX,0x4 OR EAX,ECX MOV dword ptr [RBP + -0x38],EAX MOV EAX,dword ptr [RBP + -0x3c] SHR EAX,0x4 AND EAX,0xf0f0f0f MOV ECX,dword ptr [RBP + -0x68] SHR ECX,0x6 AND ECX,0x3030303 SHL ECX,0x4 OR EAX,ECX MOV dword ptr [RBP + -0x34],EAX MOV EAX,dword ptr [RBP + -0x40] AND EAX,0xf0f0f0f MOV ECX,dword ptr [RBP + -0x68] SHR ECX,0x0 AND ECX,0x3030303 SHL ECX,0x4 OR EAX,ECX MOV dword ptr [RBP + -0x40],EAX MOV EAX,dword ptr [RBP + -0x3c] AND EAX,0xf0f0f0f MOV ECX,dword ptr [RBP + -0x68] SHR ECX,0x2 AND ECX,0x3030303 SHL ECX,0x4 OR EAX,ECX MOV dword ptr [RBP + -0x3c],EAX MOV dword ptr [RBP + -0x6c],0x0 MOV dword ptr [RBP + -0x74],0x0 LAB_00171708: CMP dword ptr [RBP + -0x74],0x100 JGE 0x001718c8 MOV dword ptr [RBP + -0x78],0x0 MOV dword ptr [RBP + -0x7c],0x0 LAB_00171723: CMP dword ptr [RBP + -0x7c],0x4 JGE 0x001718ac MOVSS XMM0,dword ptr [RBP + -0x50] MOV RAX,qword ptr [RBP + -0x48] MOV ECX,dword ptr [RBP + -0x6c] MOV EDX,ECX ADD EDX,0x1 MOV dword ptr [RBP + -0x6c],EDX MOVSXD RCX,ECX MOVSX EAX,byte ptr [RAX + RCX*0x1] SUB EAX,0x20 CVTSI2SS XMM1,EAX MULSS XMM0,XMM1 MOVSS dword ptr [RBP + -0x70],XMM0 MOV dword ptr [RBP + -0x80],0x0 LAB_0017175f: CMP dword ptr [RBP + -0x80],0x10 JGE 0x001717d2 MOVSS XMM0,dword ptr [RBP + -0x70] MOV RAX,qword ptr [RBP + -0x58] MOV ECX,dword ptr [RBP + -0x80] ADD ECX,0x0 MOVSXD RCX,ECX MOVZX EAX,byte ptr [RAX + RCX*0x1] MOV ECX,dword ptr [RBP + -0x78] SAR EAX,CL AND EAX,0x3 MOVSX EAX,AL MOV RCX,qword ptr [RBP + -0x60] MOV EDX,dword ptr [RBP + -0x80] ADD EDX,0x0 MOVSXD RDX,EDX MOVZX ESI,byte ptr [RCX + RDX*0x1] MOVZX ECX,byte ptr [RBP + -0x61] AND ESI,ECX MOV ECX,0x4 XOR EDX,EDX CMP ESI,0x0 CMOVNZ ECX,EDX SUB EAX,ECX CVTSI2SS XMM1,EAX MULSS XMM0,XMM1 MOV RAX,qword ptr [RBP + -0x10] MOV RCX,RAX ADD RCX,0x4 MOV qword ptr [RBP + -0x10],RCX MOVSS dword ptr [RAX],XMM0 MOV EAX,dword ptr [RBP + -0x80] ADD EAX,0x1 MOV dword ptr [RBP + -0x80],EAX JMP 0x0017175f LAB_001717d2: MOVSS XMM0,dword ptr [RBP + -0x50] MOV RAX,qword ptr [RBP + -0x48] MOV ECX,dword ptr [RBP + -0x6c] MOV EDX,ECX ADD EDX,0x1 MOV dword ptr [RBP + -0x6c],EDX MOVSXD RCX,ECX MOVSX EAX,byte ptr [RAX + RCX*0x1] SUB EAX,0x20 CVTSI2SS XMM1,EAX MULSS XMM0,XMM1 MOVSS dword ptr [RBP + -0x70],XMM0 MOV dword ptr [RBP + -0x84],0x0 LAB_00171807: CMP dword ptr [RBP + -0x84],0x10 JGE 0x0017188c MOVSS XMM0,dword ptr [RBP + -0x70] MOV RAX,qword ptr [RBP + -0x58] MOV ECX,dword ptr [RBP + -0x84] ADD ECX,0x10 MOVSXD RCX,ECX MOVZX EAX,byte ptr [RAX + RCX*0x1] MOV ECX,dword ptr [RBP + -0x78] SAR EAX,CL AND EAX,0x3 MOVSX EAX,AL MOV RCX,qword ptr [RBP + -0x60] MOV EDX,dword ptr [RBP + -0x84] ADD EDX,0x10 MOVSXD RDX,EDX MOVZX ESI,byte ptr [RCX + RDX*0x1] MOVZX ECX,byte ptr [RBP + -0x61] AND ESI,ECX MOV ECX,0x4 XOR EDX,EDX CMP ESI,0x0 CMOVNZ ECX,EDX SUB EAX,ECX CVTSI2SS XMM1,EAX MULSS XMM0,XMM1 MOV RAX,qword ptr [RBP + -0x10] MOV RCX,RAX ADD RCX,0x4 MOV qword ptr [RBP + -0x10],RCX MOVSS dword ptr [RAX],XMM0 MOV EAX,dword ptr [RBP + -0x84] ADD EAX,0x1 MOV dword ptr [RBP + -0x84],EAX JMP 0x00171807 LAB_0017188c: MOV EAX,dword ptr [RBP + -0x78] ADD EAX,0x2 MOV dword ptr [RBP + -0x78],EAX MOVZX EAX,byte ptr [RBP + -0x61] SHL EAX,0x1 MOV byte ptr [RBP + -0x61],AL MOV EAX,dword ptr [RBP + -0x7c] ADD EAX,0x1 MOV dword ptr [RBP + -0x7c],EAX JMP 0x00171723 LAB_001718ac: MOV RAX,qword ptr [RBP + -0x58] ADD RAX,0x20 MOV qword ptr [RBP + -0x58],RAX MOV EAX,dword ptr [RBP + -0x74] ADD EAX,0x80 MOV dword ptr [RBP + -0x74],EAX JMP 0x00171708 LAB_001718c8: JMP 0x001718ca LAB_001718ca: MOV EAX,dword ptr [RBP + -0x4c] ADD EAX,0x1 MOV dword ptr [RBP + -0x4c],EAX JMP 0x0017160a LAB_001718d8: ADD RSP,0x90 POP RBP RET
void dequantize_row_q3_K(long param_1,float *param_2,long param_3) { char cVar1; uint uVar2; int8 uVar3; byte bVar4; long lVar5; long lVar6; int iVar7; int iVar8; float fVar9; int local_8c; int local_88; int local_84; int local_7c; int local_74; byte local_69; long local_60; int local_54; uint local_48; uint uStack_44; uint local_40; uint local_3c; int4 local_2c; int4 local_28; int local_24; long local_20; float *local_18; long local_10; local_20 = param_3; local_18 = param_2; local_10 = param_1; if (param_3 % 0x100 == 0) { local_24 = (int)(param_3 / 0x100); local_28 = 0x3030303; local_2c = 0xf0f0f0f; for (local_54 = 0; local_54 < local_24; local_54 = local_54 + 1) { fVar9 = (float)ggml_lookup_fp16_to_fp32 (*(int2 *)(local_10 + (long)local_54 * 0x6e + 0x6c)); local_60 = local_10 + (long)local_54 * 0x6e; lVar5 = local_10 + (long)local_54 * 0x6e; local_69 = 1; lVar6 = local_10 + (long)local_54 * 0x6e; uVar3 = *(int8 *)(lVar6 + 0x60); uVar2 = *(uint *)(lVar6 + 0x68); local_48 = (uint)uVar3; local_40 = local_48 >> 4 & 0xf0f0f0f | (uVar2 >> 4 & 0x3030303) << 4; uStack_44 = (uint)((ulong)uVar3 >> 0x20); local_3c = uStack_44 >> 4 & 0xf0f0f0f | (uVar2 >> 6 & 0x3030303) << 4; _local_48 = CONCAT44(uStack_44 & 0xf0f0f0f | (uVar2 >> 2 & 0x3030303) << 4, local_48 & 0xf0f0f0f | (uVar2 & 0x3030303) << 4); local_74 = 0; for (local_7c = 0; local_60 = local_60 + 0x20, local_7c < 0x100; local_7c = local_7c + 0x80) { bVar4 = 0; for (local_84 = 0; local_84 < 4; local_84 = local_84 + 1) { iVar8 = local_74 + 1; cVar1 = *(char *)((long)&local_48 + (long)local_74); for (local_88 = 0; local_88 < 0x10; local_88 = local_88 + 1) { iVar7 = 4; if ((*(byte *)(lVar5 + local_88) & local_69) != 0) { iVar7 = 0; } *local_18 = fVar9 * (float)(cVar1 + -0x20) * (float)((char)((byte)((int)(uint)*(byte *)(local_60 + local_88) >> (bVar4 & 0x1f)) & 3) - iVar7); local_18 = local_18 + 1; } local_74 = local_74 + 2; cVar1 = *(char *)((long)&local_48 + (long)iVar8); for (local_8c = 0; local_8c < 0x10; local_8c = local_8c + 1) { iVar8 = 4; if ((*(byte *)(lVar5 + (local_8c + 0x10)) & local_69) != 0) { iVar8 = 0; } *local_18 = fVar9 * (float)(cVar1 + -0x20) * (float)((char)((byte)((int)(uint)*(byte *)(local_60 + (local_8c + 0x10)) >> (bVar4 & 0x1f)) & 3) - iVar8); local_18 = local_18 + 1; } bVar4 = bVar4 + 2; local_69 = local_69 << 1; } } } return; } /* WARNING: Subroutine does not return */ __assert_fail("k % QK_K == 0", "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-quants.c" ,0x421, "void dequantize_row_q3_K(const block_q3_K *restrict, float *restrict, int64_t)"); }
3,576
dequantize_row_q3_K
Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-quants.c
void dequantize_row_q3_K(const block_q3_K * restrict x, float * restrict y, int64_t k) { assert(k % QK_K == 0); const int nb = k / QK_K; const uint32_t kmask1 = 0x03030303; const uint32_t kmask2 = 0x0f0f0f0f; uint32_t aux[4]; const int8_t * scales = (const int8_t*)aux; for (int i = 0; i < nb; i++) { const float d_all = GGML_FP16_TO_FP32(x[i].d); const uint8_t * restrict q = x[i].qs; const uint8_t * restrict hm = x[i].hmask; uint8_t m = 1; memcpy(aux, x[i].scales, 12); uint32_t tmp = aux[2]; aux[2] = ((aux[0] >> 4) & kmask2) | (((tmp >> 4) & kmask1) << 4); aux[3] = ((aux[1] >> 4) & kmask2) | (((tmp >> 6) & kmask1) << 4); aux[0] = (aux[0] & kmask2) | (((tmp >> 0) & kmask1) << 4); aux[1] = (aux[1] & kmask2) | (((tmp >> 2) & kmask1) << 4); int is = 0; float dl; for (int n = 0; n < QK_K; n += 128) { int shift = 0; for (int j = 0; j < 4; ++j) { dl = d_all * (scales[is++] - 32); for (int l = 0; l < 16; ++l) { *y++ = dl * ((int8_t)((q[l+ 0] >> shift) & 3) - ((hm[l+ 0] & m) ? 0 : 4)); } dl = d_all * (scales[is++] - 32); for (int l = 0; l < 16; ++l) { *y++ = dl * ((int8_t)((q[l+16] >> shift) & 3) - ((hm[l+16] & m) ? 0 : 4)); } shift += 2; m <<= 1; } q += 32; } } }
O2
c
dequantize_row_q3_K: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp testb %dl, %dl jne 0x33f6c shrq $0x8, %rdx xorl %eax, %eax testl %edx, %edx cmovlel %eax, %edx pushq $0x10 popq %r10 movq %rdi, %rbx movq %rdx, 0x10(%rsp) cmpq %rdx, %rax je 0x33f5d imulq $0x6e, %rax, %r8 leaq (%rdi,%r8), %r14 movzwl 0x6c(%rdi,%r8), %ecx movq 0x3f1ba(%rip), %rdx # 0x72fa8 movss (%rdx,%rcx,4), %xmm0 movl 0x68(%rdi,%r8), %ecx movl %ecx, 0x8(%rsp) movq 0x60(%rdi,%r8), %r8 movq %r8, (%rsp) movl %r8d, %r11d shrl $0x4, %r11d movl $0xf0f0f0f, %edx # imm = 0xF0F0F0F andl %edx, %r11d movl %ecx, %ebp movl $0x30303030, %r9d # imm = 0x30303030 andl %r9d, %ebp orl %r11d, %ebp movl %ebp, 0x8(%rsp) movl 0x4(%rsp), %r11d movl %r11d, %ebp shrl $0x4, %ebp andl %edx, %ebp movl %ecx, %r15d shrl $0x2, %r15d andl %r9d, %r15d orl %ebp, %r15d movl %r15d, 0xc(%rsp) andl %edx, %r8d movl %ecx, %ebp shll $0x4, %ebp andl %r9d, %ebp orl %r8d, %ebp movl %ebp, (%rsp) andl %edx, %r11d andl $0xc0c0c0c, %ecx # imm = 0xC0C0C0C leal (%r11,%rcx,4), %ecx movl %ecx, 0x4(%rsp) xorl %r15d, %r15d movb $0x1, %bpl xorl %r12d, %r12d cmpl $0xff, %r12d ja 0x33f4c leaq 0x20(%r14), %r13 movslq %r15d, %r15 xorl %ecx, %ecx xorl %r8d, %r8d cmpl $0x4, %r8d je 0x33f40 movsbl (%rsp,%r15), %r11d addl $-0x20, %r11d cvtsi2ss %r11d, %xmm1 mulss %xmm0, %xmm1 xorl %r11d, %r11d cmpq $0x10, %r11 je 0x33ee0 movzbl 0x20(%r14,%r11), %edx shrl %cl, %edx andl $0x3, %edx xorl %r9d, %r9d testb %bpl, (%rbx,%r11) setne %r9b leal (%rdx,%r9,4), %edx addl $-0x4, %edx cvtsi2ss %edx, %xmm2 mulss %xmm1, %xmm2 movss %xmm2, (%rsi) addq $0x4, %rsi incq %r11 jmp 0x33ea8 movsbl 0x1(%rsp,%r15), %r11d addl $-0x20, %r11d cvtsi2ss %r11d, %xmm1 mulss %xmm0, %xmm1 movq %r10, %r11 cmpq $0x20, %r11 je 0x33f2e movzbl 0x20(%r14,%r11), %edx shrl %cl, %edx andl $0x3, %edx xorl %r9d, %r9d testb %bpl, (%rbx,%r11) setne %r9b leal (%rdx,%r9,4), %edx addl $-0x4, %edx cvtsi2ss %edx, %xmm2 mulss %xmm1, %xmm2 movss %xmm2, (%rsi) addq $0x4, %rsi incq %r11 jmp 0x33ef6 addq $0x2, %r15 addl $0x2, %ecx addb %bpl, %bpl incl %r8d jmp 0x33e89 subl $-0x80, %r12d movq %r13, %r14 jmp 0x33e70 incq %rax addq $0x6e, %rbx movq 0x10(%rsp), %rdx jmp 0x33dd0 addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq leaq 0x29ed9(%rip), %rdi # 0x5de4c leaq 0x29aea(%rip), %rsi # 0x5da64 leaq 0x29fca(%rip), %rcx # 0x5df4b movl $0x421, %edx # imm = 0x421 callq 0x1dfb0
dequantize_row_q3_K: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h test dl, dl jnz loc_33F6C shr rdx, 8 xor eax, eax test edx, edx cmovle edx, eax push 10h pop r10 mov rbx, rdi mov [rsp+48h+var_38], rdx loc_33DD0: cmp rax, rdx jz loc_33F5D imul r8, rax, 6Eh ; 'n' lea r14, [rdi+r8] movzx ecx, word ptr [rdi+r8+6Ch] mov rdx, cs:ggml_table_f32_f16_ptr movss xmm0, dword ptr [rdx+rcx*4] mov ecx, [rdi+r8+68h] mov [rsp+48h+var_40], ecx mov r8, [rdi+r8+60h] mov [rsp+48h+var_48], r8 mov r11d, r8d shr r11d, 4 mov edx, 0F0F0F0Fh and r11d, edx mov ebp, ecx mov r9d, 30303030h and ebp, r9d or ebp, r11d mov [rsp+48h+var_40], ebp mov r11d, dword ptr [rsp+48h+var_48+4] mov ebp, r11d shr ebp, 4 and ebp, edx mov r15d, ecx shr r15d, 2 and r15d, r9d or r15d, ebp mov [rsp+48h+var_3C], r15d and r8d, edx mov ebp, ecx shl ebp, 4 and ebp, r9d or ebp, r8d mov dword ptr [rsp+48h+var_48], ebp and r11d, edx and ecx, 0C0C0C0Ch lea ecx, [r11+rcx*4] mov dword ptr [rsp+48h+var_48+4], ecx xor r15d, r15d mov bpl, 1 xor r12d, r12d loc_33E70: cmp r12d, 0FFh ja loc_33F4C lea r13, [r14+20h] movsxd r15, r15d xor ecx, ecx xor r8d, r8d loc_33E89: cmp r8d, 4 jz loc_33F40 movsx r11d, byte ptr [rsp+r15+48h+var_48] add r11d, 0FFFFFFE0h cvtsi2ss xmm1, r11d mulss xmm1, xmm0 xor r11d, r11d loc_33EA8: cmp r11, 10h jz short loc_33EE0 movzx edx, byte ptr [r14+r11+20h] shr edx, cl and edx, 3 xor r9d, r9d test [rbx+r11], bpl setnz r9b lea edx, [rdx+r9*4] add edx, 0FFFFFFFCh cvtsi2ss xmm2, edx mulss xmm2, xmm1 movss dword ptr [rsi], xmm2 add rsi, 4 inc r11 jmp short loc_33EA8 loc_33EE0: movsx r11d, byte ptr [rsp+r15+48h+var_48+1] add r11d, 0FFFFFFE0h cvtsi2ss xmm1, r11d mulss xmm1, xmm0 mov r11, r10 loc_33EF6: cmp r11, 20h ; ' ' jz short loc_33F2E movzx edx, byte ptr [r14+r11+20h] shr edx, cl and edx, 3 xor r9d, r9d test [rbx+r11], bpl setnz r9b lea edx, [rdx+r9*4] add edx, 0FFFFFFFCh cvtsi2ss xmm2, edx mulss xmm2, xmm1 movss dword ptr [rsi], xmm2 add rsi, 4 inc r11 jmp short loc_33EF6 loc_33F2E: add r15, 2 add ecx, 2 add bpl, bpl inc r8d jmp loc_33E89 loc_33F40: sub r12d, 0FFFFFF80h mov r14, r13 jmp loc_33E70 loc_33F4C: inc rax add rbx, 6Eh ; 'n' mov rdx, [rsp+48h+var_38] jmp loc_33DD0 loc_33F5D: add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_33F6C: lea rdi, aKQkK0; "k % QK_K == 0" lea rsi, aWorkspaceLlm4b_4; "/workspace/llm4binary/github/2025_star3"... lea rcx, aVoidDequantize_5; "void dequantize_row_q3_K(const block_q3"... mov edx, 421h call ___assert_fail
long long dequantize_row_q3_K(long long a1, float *a2, unsigned long long a3) { unsigned long long v3; // rdx long long result; // rax long long v5; // rbx long long v6; // r14 float v7; // xmm0_4 unsigned int v8; // ecx long long v9; // r8 long long v10; // r15 char v11; // bp unsigned int i; // r12d char v13; // cl int j; // r8d float v15; // xmm1_4 long long k; // r11 float v17; // xmm1_4 long long m; // r11 _DWORD v19[2]; // [rsp+0h] [rbp-48h] unsigned int v20; // [rsp+8h] [rbp-40h] int v21; // [rsp+Ch] [rbp-3Ch] unsigned long long v22; // [rsp+10h] [rbp-38h] if ( (_BYTE)a3 ) __assert_fail( "k % QK_K == 0", "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-quants.c", 1057LL, "void dequantize_row_q3_K(const block_q3_K *restrict, float *restrict, int64_t)"); v3 = a3 >> 8; result = 0LL; if ( (int)v3 <= 0 ) v3 = 0LL; v5 = a1; v22 = v3; while ( result != v3 ) { v6 = a1 + 110 * result; v7 = ggml_table_f32_f16[*(unsigned __int16 *)(v6 + 108)]; v8 = *(_DWORD *)(v6 + 104); v20 = v8; v9 = *(_QWORD *)(v6 + 96); v20 = ((unsigned int)v9 >> 4) & 0xF0F0F0F | v8 & 0x30303030; v21 = (HIDWORD(v9) >> 4) & 0xF0F0F0F | (v8 >> 2) & 0x30303030; v19[0] = v9 & 0xF0F0F0F | (16 * v8) & 0x30303030; v19[1] = (HIDWORD(v9) & 0xF0F0F0F) + 4 * (v8 & 0xC0C0C0C); LODWORD(v10) = 0; v11 = 1; for ( i = 0; i <= 0xFF; i += 128 ) { v10 = (int)v10; v13 = 0; for ( j = 0; j != 4; ++j ) { v15 = (float)(*((char *)v19 + v10) - 32) * v7; for ( k = 0LL; k != 16; ++k ) *a2++ = (float)(((*(unsigned __int8 *)(v6 + k + 32) >> v13) & 3) + 4 * (((unsigned __int8)v11 & *(_BYTE *)(v5 + k)) != 0) - 4) * v15; v17 = (float)(*((char *)v19 + v10 + 1) - 32) * v7; for ( m = 16LL; m != 32; ++m ) *a2++ = (float)(((*(unsigned __int8 *)(v6 + m + 32) >> v13) & 3) + 4 * (((unsigned __int8)v11 & *(_BYTE *)(v5 + m)) != 0) - 4) * v17; v10 += 2LL; v13 += 2; v11 *= 2; } v6 += 32LL; } ++result; v5 += 110LL; v3 = v22; } return result; }
dequantize_row_q3_K: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 TEST DL,DL JNZ 0x00133f6c SHR RDX,0x8 XOR EAX,EAX TEST EDX,EDX CMOVLE EDX,EAX PUSH 0x10 POP R10 MOV RBX,RDI MOV qword ptr [RSP + 0x10],RDX LAB_00133dd0: CMP RAX,RDX JZ 0x00133f5d IMUL R8,RAX,0x6e LEA R14,[RDI + R8*0x1] MOVZX ECX,word ptr [RDI + R8*0x1 + 0x6c] MOV RDX,qword ptr [0x00172fa8] MOVSS XMM0,dword ptr [RDX + RCX*0x4] MOV ECX,dword ptr [RDI + R8*0x1 + 0x68] MOV dword ptr [RSP + 0x8],ECX MOV R8,qword ptr [RDI + R8*0x1 + 0x60] MOV qword ptr [RSP],R8 MOV R11D,R8D SHR R11D,0x4 MOV EDX,0xf0f0f0f AND R11D,EDX MOV EBP,ECX MOV R9D,0x30303030 AND EBP,R9D OR EBP,R11D MOV dword ptr [RSP + 0x8],EBP MOV R11D,dword ptr [RSP + 0x4] MOV EBP,R11D SHR EBP,0x4 AND EBP,EDX MOV R15D,ECX SHR R15D,0x2 AND R15D,R9D OR R15D,EBP MOV dword ptr [RSP + 0xc],R15D AND R8D,EDX MOV EBP,ECX SHL EBP,0x4 AND EBP,R9D OR EBP,R8D MOV dword ptr [RSP],EBP AND R11D,EDX AND ECX,0xc0c0c0c LEA ECX,[R11 + RCX*0x4] MOV dword ptr [RSP + 0x4],ECX XOR R15D,R15D MOV BPL,0x1 XOR R12D,R12D LAB_00133e70: CMP R12D,0xff JA 0x00133f4c LEA R13,[R14 + 0x20] MOVSXD R15,R15D XOR ECX,ECX XOR R8D,R8D LAB_00133e89: CMP R8D,0x4 JZ 0x00133f40 MOVSX R11D,byte ptr [RSP + R15*0x1] ADD R11D,-0x20 CVTSI2SS XMM1,R11D MULSS XMM1,XMM0 XOR R11D,R11D LAB_00133ea8: CMP R11,0x10 JZ 0x00133ee0 MOVZX EDX,byte ptr [R14 + R11*0x1 + 0x20] SHR EDX,CL AND EDX,0x3 XOR R9D,R9D TEST byte ptr [RBX + R11*0x1],BPL SETNZ R9B LEA EDX,[RDX + R9*0x4] ADD EDX,-0x4 CVTSI2SS XMM2,EDX MULSS XMM2,XMM1 MOVSS dword ptr [RSI],XMM2 ADD RSI,0x4 INC R11 JMP 0x00133ea8 LAB_00133ee0: MOVSX R11D,byte ptr [RSP + R15*0x1 + 0x1] ADD R11D,-0x20 CVTSI2SS XMM1,R11D MULSS XMM1,XMM0 MOV R11,R10 LAB_00133ef6: CMP R11,0x20 JZ 0x00133f2e MOVZX EDX,byte ptr [R14 + R11*0x1 + 0x20] SHR EDX,CL AND EDX,0x3 XOR R9D,R9D TEST byte ptr [RBX + R11*0x1],BPL SETNZ R9B LEA EDX,[RDX + R9*0x4] ADD EDX,-0x4 CVTSI2SS XMM2,EDX MULSS XMM2,XMM1 MOVSS dword ptr [RSI],XMM2 ADD RSI,0x4 INC R11 JMP 0x00133ef6 LAB_00133f2e: ADD R15,0x2 ADD ECX,0x2 ADD BPL,BPL INC R8D JMP 0x00133e89 LAB_00133f40: SUB R12D,-0x80 MOV R14,R13 JMP 0x00133e70 LAB_00133f4c: INC RAX ADD RBX,0x6e MOV RDX,qword ptr [RSP + 0x10] JMP 0x00133dd0 LAB_00133f5d: ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00133f6c: LEA RDI,[0x15de4c] LEA RSI,[0x15da64] LEA RCX,[0x15df4b] MOV EDX,0x421 CALL 0x0011dfb0
void dequantize_row_q3_K(long param_1,float *param_2,ulong param_3) { float fVar1; char cVar2; ulong uVar3; byte bVar4; ulong uVar5; long lVar6; byte bVar7; int iVar8; long lVar9; long lVar10; uint uVar11; long lVar12; int4 local_48; uint uStack_44; uint local_40; uint local_3c; ulong local_38; if ((char)param_3 == '\0') { uVar3 = 0; local_38 = param_3 >> 8 & 0xffffffff; if ((int)(param_3 >> 8) < 1) { local_38 = uVar3; } uVar5 = local_38; lVar6 = param_1; for (; uVar3 != uVar5; uVar3 = uVar3 + 1) { lVar9 = uVar3 * 0x6e; fVar1 = *(float *)(PTR_ggml_table_f32_f16_00172fa8 + (ulong)*(ushort *)(param_1 + 0x6c + lVar9) * 4); uVar11 = *(uint *)(param_1 + 0x68 + lVar9); uVar5 = *(ulong *)(param_1 + 0x60 + lVar9); local_40 = uVar11 & 0x30303030 | (uint)(uVar5 >> 4) & 0xf0f0f0f; uStack_44 = (uint)(uVar5 >> 0x20); local_3c = uVar11 >> 2 & 0x30303030 | uStack_44 >> 4 & 0xf0f0f0f; _local_48 = CONCAT44((uStack_44 & 0xf0f0f0f) + (uVar11 & 0xc0c0c0c) * 4, (uVar11 & 0x3030303) << 4 | (uint)uVar5 & 0xf0f0f0f); lVar12 = 0; bVar7 = 1; lVar9 = param_1 + lVar9; for (uVar11 = 0; uVar11 < 0x100; uVar11 = uVar11 + 0x80) { lVar12 = (long)(int)lVar12; bVar4 = 0; for (iVar8 = 0; iVar8 != 4; iVar8 = iVar8 + 1) { cVar2 = *(char *)((long)&local_48 + lVar12); for (lVar10 = 0; lVar10 != 0x10; lVar10 = lVar10 + 1) { *param_2 = (float)(int)((*(byte *)(lVar9 + 0x20 + lVar10) >> (bVar4 & 0x1f) & 3) + (uint)((*(byte *)(lVar6 + lVar10) & bVar7) != 0) * 4 + -4) * (float)(cVar2 + -0x20) * fVar1; param_2 = param_2 + 1; } cVar2 = *(char *)((long)&local_48 + lVar12 + 1); for (lVar10 = 0x10; lVar10 != 0x20; lVar10 = lVar10 + 1) { *param_2 = (float)(int)((*(byte *)(lVar9 + 0x20 + lVar10) >> (bVar4 & 0x1f) & 3) + (uint)((*(byte *)(lVar6 + lVar10) & bVar7) != 0) * 4 + -4) * (float)(cVar2 + -0x20) * fVar1; param_2 = param_2 + 1; } lVar12 = lVar12 + 2; bVar4 = bVar4 + 2; bVar7 = bVar7 * '\x02'; } lVar9 = lVar9 + 0x20; } lVar6 = lVar6 + 0x6e; uVar5 = local_38; } return; } /* WARNING: Subroutine does not return */ __assert_fail("k % QK_K == 0", "/workspace/llm4binary/github/2025_star3/Yangxiaoz[P]GGML-Tutorial/ggml/src/ggml-quants.c" ,0x421, "void dequantize_row_q3_K(const block_q3_K *restrict, float *restrict, int64_t)"); }
3,577
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; }
O3
c
psi_mutex_trylock: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %rbx subq $0x38, %rsp movl %edx, %r8d movq %rsi, %rcx movq %rdi, %r14 leaq 0x35ebd8(%rip), %r15 # 0x38f258 movq (%r15), %rax movq 0x40(%rdi), %rsi leaq -0x48(%rbp), %rdi pushq $0x1 popq %rdx callq *0x190(%rax) movq %rax, %rbx movq %r14, %rdi callq 0x2a3f0 movl %eax, %r14d testq %rbx, %rbx je 0x306b6 movq (%r15), %rax movq %rbx, %rdi movl %r14d, %esi callq *0x198(%rax) movl %r14d, %eax addq $0x38, %rsp popq %rbx popq %r14 popq %r15 popq %rbp retq
psi_mutex_trylock: 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+40h] lea rdi, [rbp+var_48] push 1 pop rdx call qword ptr [rax+190h] mov rbx, rax mov rdi, r14 call _pthread_mutex_trylock mov r14d, eax test rbx, rbx jz short loc_306B6 mov rax, [r15] mov rdi, rbx mov esi, r14d call qword ptr [rax+198h] loc_306B6: mov eax, r14d add rsp, 38h pop rbx pop r14 pop r15 pop rbp retn
long long psi_mutex_trylock(long long a1, long long a2, unsigned int a3) { long long v3; // rbx unsigned int v4; // r14d _BYTE v6[72]; // [rsp+8h] [rbp-48h] BYREF v3 = ((long long ( *)(_BYTE *, _QWORD, long long, long long, _QWORD))PSI_server[50])( v6, *(_QWORD *)(a1 + 64), 1LL, a2, a3); v4 = pthread_mutex_trylock(a1); if ( v3 ) ((void ( *)(long long, _QWORD))PSI_server[51])(v3, v4); return v4; }
psi_mutex_trylock: 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,[0x48f258] MOV RAX,qword ptr [R15] MOV RSI,qword ptr [RDI + 0x40] LEA RDI,[RBP + -0x48] PUSH 0x1 POP RDX CALL qword ptr [RAX + 0x190] MOV RBX,RAX MOV RDI,R14 CALL 0x0012a3f0 MOV R14D,EAX TEST RBX,RBX JZ 0x001306b6 MOV RAX,qword ptr [R15] MOV RDI,RBX MOV ESI,R14D CALL qword ptr [RAX + 0x198] LAB_001306b6: MOV EAX,R14D ADD RSP,0x38 POP RBX POP R14 POP R15 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 [48]; lVar2 = (**(code **)(PSI_server + 400)) (local_50,*(int8 *)((long)param_1 + 0x40),1,param_2,param_3); iVar1 = pthread_mutex_trylock(param_1); if (lVar2 != 0) { (**(code **)(PSI_server + 0x198))(lVar2,iVar1); } return iVar1; }
3,578
bug_8378
eloqsql/libmariadb/unittest/libmariadb/charset.c
int bug_8378(MYSQL *mysql) { int rc, len; char out[9], buf[256]; MYSQL_RES *res; MYSQL_ROW row; len= mysql_real_escape_string(mysql, out, TEST_BUG8378_IN, 4); FAIL_IF(memcmp(out, TEST_BUG8378_OUT, len), "wrong result"); sprintf(buf, "SELECT '%s' FROM DUAL", TEST_BUG8378_OUT); rc= mysql_query(mysql, buf); check_mysql_rc(rc, mysql); if ((res= mysql_store_result(mysql))) { row= mysql_fetch_row(res); if (memcmp(row[0], TEST_BUG8378_IN, 4)) { mysql_free_result(res); return FAIL; } mysql_free_result(res); } else return FAIL; return OK; }
O0
c
bug_8378: pushq %rbp movq %rsp, %rbp subq $0x160, %rsp # imm = 0x160 movq %fs:0x28, %rax movq %rax, -0x8(%rbp) movq %rdi, -0x130(%rbp) movq -0x130(%rbp), %rdi leaq -0x11(%rbp), %rsi leaq 0x396ed(%rip), %rdx # 0x4e66e movl $0x4, %ecx callq 0x269c0 movl %eax, -0x138(%rbp) leaq -0x11(%rbp), %rdi movslq -0x138(%rbp), %rdx leaq 0x396d2(%rip), %rsi # 0x4e675 callq 0x131b0 cmpl $0x0, %eax je 0x14fdd leaq 0x39132(%rip), %rdi # 0x4e0e6 leaq 0x396c4(%rip), %rsi # 0x4e67f leaq 0x396ca(%rip), %rdx # 0x4e68c movl $0x33, %ecx movb $0x0, %al callq 0x187a0 movl $0x1, -0x124(%rbp) jmp 0x15107 jmp 0x14fdf leaq -0x120(%rbp), %rdi leaq 0x396f1(%rip), %rsi # 0x4e6de leaq 0x39681(%rip), %rdx # 0x4e675 movb $0x0, %al callq 0x130f0 movq -0x130(%rbp), %rdi leaq -0x120(%rbp), %rsi callq 0x22f20 movl %eax, -0x134(%rbp) cmpl $0x0, -0x134(%rbp) je 0x15081 movl -0x134(%rbp), %eax movl %eax, -0x154(%rbp) movq -0x130(%rbp), %rdi callq 0x268a0 movq %rax, -0x150(%rbp) movq -0x130(%rbp), %rdi callq 0x26870 movl -0x154(%rbp), %esi movq -0x150(%rbp), %rdx movl %eax, %ecx leaq 0x391cd(%rip), %rdi # 0x4e22b leaq 0x39627(%rip), %r8 # 0x4e68c movl $0x38, %r9d movb $0x0, %al callq 0x187a0 movl $0x1, -0x124(%rbp) jmp 0x15107 jmp 0x15083 movq -0x130(%rbp), %rdi callq 0x24570 movq %rax, -0x140(%rbp) cmpq $0x0, %rax je 0x150f1 movq -0x140(%rbp), %rdi callq 0x248b0 movq %rax, -0x148(%rbp) movq -0x148(%rbp), %rax movq (%rax), %rax movl (%rax), %eax subl $0x27bfbbef, %eax # imm = 0x27BFBBEF setne %al movzbl %al, %eax cmpl $0x0, %eax je 0x150e3 movq -0x140(%rbp), %rdi callq 0x1bdb0 movl $0x1, -0x124(%rbp) jmp 0x15107 movq -0x140(%rbp), %rdi callq 0x1bdb0 jmp 0x150fd movl $0x1, -0x124(%rbp) jmp 0x15107 movl $0x0, -0x124(%rbp) movl -0x124(%rbp), %eax movl %eax, -0x158(%rbp) movq %fs:0x28, %rax movq -0x8(%rbp), %rcx cmpq %rcx, %rax jne 0x15134 movl -0x158(%rbp), %eax addq $0x160, %rsp # imm = 0x160 popq %rbp retq callq 0x134b0 nopl (%rax)
bug_8378: push rbp mov rbp, rsp sub rsp, 160h mov rax, fs:28h mov [rbp+var_8], rax mov [rbp+var_130], rdi mov rdi, [rbp+var_130] lea rsi, [rbp+var_11] lea rdx, unk_4E66E mov ecx, 4 call mysql_real_escape_string mov [rbp+var_138], eax lea rdi, [rbp+var_11] movsxd rdx, [rbp+var_138] lea rsi, unk_4E675 call _memcmp cmp eax, 0 jz short loc_14FDD lea rdi, aErrorSSD; "Error: %s (%s: %d)" lea rsi, aWrongResult; "wrong result" lea rdx, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"... mov ecx, 33h ; '3' mov al, 0 call diag mov [rbp+var_124], 1 jmp loc_15107 loc_14FDD: jmp short $+2 loc_14FDF: lea rdi, [rbp+var_120] lea rsi, aSelectSFromDua; "SELECT '%s' FROM DUAL" lea rdx, unk_4E675 mov al, 0 call _sprintf mov rdi, [rbp+var_130] lea rsi, [rbp+var_120] call mysql_query mov [rbp+var_134], eax cmp [rbp+var_134], 0 jz short loc_15081 mov eax, [rbp+var_134] mov [rbp+var_154], eax mov rdi, [rbp+var_130] call mysql_error mov [rbp+var_150], rax mov rdi, [rbp+var_130] call mysql_errno mov esi, [rbp+var_154] mov rdx, [rbp+var_150] mov ecx, eax lea rdi, aErrorDSDInSLin; "Error (%d): %s (%d) in %s line %d" lea r8, aWorkspaceLlm4b_0; "/workspace/llm4binary/github2025/eloqsq"... mov r9d, 38h ; '8' mov al, 0 call diag mov [rbp+var_124], 1 jmp loc_15107 loc_15081: jmp short $+2 loc_15083: mov rdi, [rbp+var_130] call mysql_store_result mov [rbp+var_140], rax cmp rax, 0 jz short loc_150F1 mov rdi, [rbp+var_140] call mysql_fetch_row mov [rbp+var_148], rax mov rax, [rbp+var_148] mov rax, [rax] mov eax, [rax] sub eax, 27BFBBEFh setnz al movzx eax, al cmp eax, 0 jz short loc_150E3 mov rdi, [rbp+var_140] call mysql_free_result mov [rbp+var_124], 1 jmp short loc_15107 loc_150E3: mov rdi, [rbp+var_140] call mysql_free_result jmp short loc_150FD loc_150F1: mov [rbp+var_124], 1 jmp short loc_15107 loc_150FD: mov [rbp+var_124], 0 loc_15107: mov eax, [rbp+var_124] mov [rbp+var_158], eax mov rax, fs:28h mov rcx, [rbp+var_8] cmp rax, rcx jnz short loc_15134 mov eax, [rbp+var_158] add rsp, 160h pop rbp retn loc_15134: call ___stack_chk_fail
long long bug_8378(long long a1) { int v1; // r8d int v2; // r9d int v3; // eax int v5; // [rsp+10h] [rbp-150h] long long v6; // [rsp+20h] [rbp-140h] int v7; // [rsp+28h] [rbp-138h] int v8; // [rsp+2Ch] [rbp-134h] char v10[271]; // [rsp+40h] [rbp-120h] BYREF _BYTE v11[9]; // [rsp+14Fh] [rbp-11h] BYREF unsigned long long v12; // [rsp+158h] [rbp-8h] v12 = __readfsqword(0x28u); v7 = mysql_real_escape_string(a1, v11, &unk_4E66E, 4LL); if ( !(unsigned int)memcmp(v11, byte_4E675, v7) ) { sprintf(v10, "SELECT '%s' FROM DUAL", byte_4E675); v8 = mysql_query(a1, v10); if ( v8 ) { v5 = mysql_error(a1); v3 = mysql_errno(a1); diag( (unsigned int)"Error (%d): %s (%d) in %s line %d", v8, v5, v3, (unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/charset.c", 56); return 1; } else { v6 = mysql_store_result(a1); if ( v6 ) { if ( **(_DWORD **)mysql_fetch_row(v6) == 666876911 ) { mysql_free_result(v6); return 0; } else { mysql_free_result(v6); return 1; } } else { return 1; } } } else { diag( (unsigned int)"Error: %s (%s: %d)", (unsigned int)"wrong result", (unsigned int)"/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/charset.c", 51, v1, v2); return 1; } }
bug_8378: PUSH RBP MOV RBP,RSP SUB RSP,0x160 MOV RAX,qword ptr FS:[0x28] MOV qword ptr [RBP + -0x8],RAX MOV qword ptr [RBP + -0x130],RDI MOV RDI,qword ptr [RBP + -0x130] LEA RSI,[RBP + -0x11] LEA RDX,[0x14e66e] MOV ECX,0x4 CALL 0x001269c0 MOV dword ptr [RBP + -0x138],EAX LEA RDI,[RBP + -0x11] MOVSXD RDX,dword ptr [RBP + -0x138] LEA RSI,[0x14e675] CALL 0x001131b0 CMP EAX,0x0 JZ 0x00114fdd LEA RDI,[0x14e0e6] LEA RSI,[0x14e67f] LEA RDX,[0x14e68c] MOV ECX,0x33 MOV AL,0x0 CALL 0x001187a0 MOV dword ptr [RBP + -0x124],0x1 JMP 0x00115107 LAB_00114fdd: JMP 0x00114fdf LAB_00114fdf: LEA RDI,[RBP + -0x120] LEA RSI,[0x14e6de] LEA RDX,[0x14e675] MOV AL,0x0 CALL 0x001130f0 MOV RDI,qword ptr [RBP + -0x130] LEA RSI,[RBP + -0x120] CALL 0x00122f20 MOV dword ptr [RBP + -0x134],EAX CMP dword ptr [RBP + -0x134],0x0 JZ 0x00115081 MOV EAX,dword ptr [RBP + -0x134] MOV dword ptr [RBP + -0x154],EAX MOV RDI,qword ptr [RBP + -0x130] CALL 0x001268a0 MOV qword ptr [RBP + -0x150],RAX MOV RDI,qword ptr [RBP + -0x130] CALL 0x00126870 MOV ESI,dword ptr [RBP + -0x154] MOV RDX,qword ptr [RBP + -0x150] MOV ECX,EAX LEA RDI,[0x14e22b] LEA R8,[0x14e68c] MOV R9D,0x38 MOV AL,0x0 CALL 0x001187a0 MOV dword ptr [RBP + -0x124],0x1 JMP 0x00115107 LAB_00115081: JMP 0x00115083 LAB_00115083: MOV RDI,qword ptr [RBP + -0x130] CALL 0x00124570 MOV qword ptr [RBP + -0x140],RAX CMP RAX,0x0 JZ 0x001150f1 MOV RDI,qword ptr [RBP + -0x140] CALL 0x001248b0 MOV qword ptr [RBP + -0x148],RAX MOV RAX,qword ptr [RBP + -0x148] MOV RAX,qword ptr [RAX] MOV EAX,dword ptr [RAX] SUB EAX,0x27bfbbef SETNZ AL MOVZX EAX,AL CMP EAX,0x0 JZ 0x001150e3 MOV RDI,qword ptr [RBP + -0x140] CALL 0x0011bdb0 MOV dword ptr [RBP + -0x124],0x1 JMP 0x00115107 LAB_001150e3: MOV RDI,qword ptr [RBP + -0x140] CALL 0x0011bdb0 JMP 0x001150fd LAB_001150f1: MOV dword ptr [RBP + -0x124],0x1 JMP 0x00115107 LAB_001150fd: MOV dword ptr [RBP + -0x124],0x0 LAB_00115107: MOV EAX,dword ptr [RBP + -0x124] MOV dword ptr [RBP + -0x158],EAX MOV RAX,qword ptr FS:[0x28] MOV RCX,qword ptr [RBP + -0x8] CMP RAX,RCX JNZ 0x00115134 MOV EAX,dword ptr [RBP + -0x158] ADD RSP,0x160 POP RBP RET LAB_00115134: CALL 0x001134b0
int4 bug_8378(int8 param_1) { int iVar1; int4 uVar2; int8 uVar3; long lVar4; int8 *puVar5; long in_FS_OFFSET; int4 local_12c; char local_128 [271]; int1 local_19 [9]; long local_10; local_10 = *(long *)(in_FS_OFFSET + 0x28); iVar1 = mysql_real_escape_string(param_1,local_19,&DAT_0014e66e,4); iVar1 = memcmp(local_19,&DAT_0014e675,(long)iVar1); if (iVar1 == 0) { sprintf(local_128,"SELECT \'%s\' FROM DUAL",&DAT_0014e675); iVar1 = mysql_query(param_1,local_128); if (iVar1 == 0) { lVar4 = mysql_store_result(param_1); if (lVar4 == 0) { local_12c = 1; } else { puVar5 = (int8 *)mysql_fetch_row(lVar4); if (*(int *)*puVar5 == 0x27bfbbef) { mysql_free_result(lVar4); local_12c = 0; } else { mysql_free_result(lVar4); local_12c = 1; } } } else { uVar3 = mysql_error(param_1); uVar2 = mysql_errno(param_1); diag("Error (%d): %s (%d) in %s line %d",iVar1,uVar3,uVar2, "/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/charset.c",0x38) ; local_12c = 1; } } else { diag("Error: %s (%s: %d)","wrong result", "/workspace/llm4binary/github2025/eloqsql/libmariadb/unittest/libmariadb/charset.c",0x33); local_12c = 1; } if (*(long *)(in_FS_OFFSET + 0x28) == local_10) { return local_12c; } /* WARNING: Subroutine does not return */ __stack_chk_fail(); }
3,579
ma_net_write_buff
eloqsql/libmariadb/libmariadb/ma_net.c
static int ma_net_write_buff(NET *net,const char *packet, size_t len) { size_t left_length; if (!len) return 0; if (net->max_packet > MAX_PACKET_LENGTH && net->compress) left_length= (size_t)(MAX_PACKET_LENGTH - (net->write_pos - net->buff)); else left_length=(size_t) (net->buff_end - net->write_pos); if (len > left_length) { if (net->write_pos != net->buff) { memcpy((char*) net->write_pos,packet,left_length); if (ma_net_real_write(net,(char*) net->buff, (size_t)(net->write_pos - net->buff) + left_length)) return 1; packet+=left_length; len-=left_length; net->write_pos= net->buff; } if (net->compress) { /* uncompressed length is stored in 3 bytes,so packet can't be > 0xFFFFFF */ left_length= MAX_PACKET_LENGTH; while (len > left_length) { if (ma_net_real_write(net, packet, left_length)) return 1; packet+= left_length; len-= left_length; } } if (len > net->max_packet) return(test(ma_net_real_write(net, packet, len))); } memcpy((char*) net->write_pos,packet,len); net->write_pos+=len; return 0; }
O3
c
ma_net_write_buff: xorl %eax, %eax testq %rdx, %rdx je 0x31c62 pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r12 pushq %rbx movq %rsi, %r14 movq %rdi, %rbx cmpq $0x1000000, 0x50(%rdi) # imm = 0x1000000 jb 0x31bf4 cmpb $0x0, 0x84(%rbx) je 0x31bf4 movq 0x8(%rbx), %r12 movq 0x18(%rbx), %rdi subq %rdi, %r12 addq $0xffffff, %r12 # imm = 0xFFFFFF jmp 0x31bff movq 0x10(%rbx), %r12 movq 0x18(%rbx), %rdi subq %rdi, %r12 movq %rdx, %r15 subq %r12, %r15 jbe 0x31c46 cmpq 0x8(%rbx), %rdi je 0x31c63 movq %r14, %rsi movq %r12, %rdx callq 0x13390 movq 0x8(%rbx), %rsi movq %r12, %rdx subq %rsi, %rdx addq 0x18(%rbx), %rdx movq %rbx, %rdi callq 0x318bf movl %eax, %ecx movl $0x1, %eax testl %ecx, %ecx jne 0x31c5a addq %r12, %r14 movq 0x8(%rbx), %rax movq %rax, 0x18(%rbx) jmp 0x31c66 movq %rdx, %r15 movq %r14, %rsi movq %r15, %rdx callq 0x13390 addq %r15, 0x18(%rbx) xorl %eax, %eax popq %rbx popq %r12 popq %r14 popq %r15 popq %rbp retq movq %rdx, %r15 cmpb $0x0, 0x84(%rbx) je 0x31ca1 cmpq $0x1000000, %r15 # imm = 0x1000000 jb 0x31ca1 movl $0xffffff, %r12d # imm = 0xFFFFFF movl $0xffffff, %edx # imm = 0xFFFFFF movq %rbx, %rdi movq %r14, %rsi callq 0x318bf testl %eax, %eax jne 0x31cc6 addq %r12, %r14 addq $-0xffffff, %r15 # imm = 0xFF000001 cmpq %r12, %r15 ja 0x31c7e cmpq 0x50(%rbx), %r15 jbe 0x31cc0 movq %rbx, %rdi movq %r14, %rsi movq %r15, %rdx callq 0x318bf movl %eax, %ecx xorl %eax, %eax testl %ecx, %ecx setne %al jmp 0x31c5a movq 0x18(%rbx), %rdi jmp 0x31c49 movl $0x1, %eax jmp 0x31c5a
ma_net_write_buff: xor eax, eax test rdx, rdx jz locret_31C62 push rbp mov rbp, rsp push r15 push r14 push r12 push rbx mov r14, rsi mov rbx, rdi cmp qword ptr [rdi+50h], 1000000h jb short loc_31BF4 cmp byte ptr [rbx+84h], 0 jz short loc_31BF4 mov r12, [rbx+8] mov rdi, [rbx+18h] sub r12, rdi add r12, 0FFFFFFh jmp short loc_31BFF loc_31BF4: mov r12, [rbx+10h] mov rdi, [rbx+18h] sub r12, rdi loc_31BFF: mov r15, rdx sub r15, r12 jbe short loc_31C46 cmp rdi, [rbx+8] jz short loc_31C63 mov rsi, r14 mov rdx, r12 call _memcpy mov rsi, [rbx+8] mov rdx, r12 sub rdx, rsi add rdx, [rbx+18h] mov rdi, rbx call ma_net_real_write mov ecx, eax mov eax, 1 test ecx, ecx jnz short loc_31C5A add r14, r12 mov rax, [rbx+8] mov [rbx+18h], rax jmp short loc_31C66 loc_31C46: mov r15, rdx loc_31C49: mov rsi, r14 mov rdx, r15 call _memcpy add [rbx+18h], r15 xor eax, eax loc_31C5A: pop rbx pop r12 pop r14 pop r15 pop rbp locret_31C62: retn loc_31C63: mov r15, rdx loc_31C66: cmp byte ptr [rbx+84h], 0 jz short loc_31CA1 cmp r15, 1000000h jb short loc_31CA1 mov r12d, 0FFFFFFh loc_31C7E: mov edx, 0FFFFFFh mov rdi, rbx mov rsi, r14 call ma_net_real_write test eax, eax jnz short loc_31CC6 add r14, r12 add r15, 0FFFFFFFFFF000001h cmp r15, r12 ja short loc_31C7E loc_31CA1: cmp r15, [rbx+50h] jbe short loc_31CC0 mov rdi, rbx mov rsi, r14 mov rdx, r15 call ma_net_real_write mov ecx, eax xor eax, eax test ecx, ecx setnz al jmp short loc_31C5A loc_31CC0: mov rdi, [rbx+18h] jmp short loc_31C49 loc_31CC6: mov eax, 1 jmp short loc_31C5A
_BOOL8 ma_net_write_buff(long long a1, long long a2, unsigned long long a3) { _BOOL8 result; // rax long long v4; // r14 long long v6; // rdi unsigned long long v7; // r12 long long v8; // r12 unsigned long long v9; // r15 int v10; // ecx result = 0LL; if ( !a3 ) return result; v4 = a2; if ( *(_QWORD *)(a1 + 80) >= 0x1000000uLL && *(_BYTE *)(a1 + 132) ) { v6 = *(_QWORD *)(a1 + 24); v7 = *(_QWORD *)(a1 + 8) - v6 + 0xFFFFFF; } else { v8 = *(_QWORD *)(a1 + 16); v6 = *(_QWORD *)(a1 + 24); v7 = v8 - v6; } v9 = a3 - v7; if ( a3 <= v7 ) { v9 = a3; LABEL_11: memcpy(v6, v4, v9); *(_QWORD *)(a1 + 24) += v9; return 0LL; } if ( v6 == *(_QWORD *)(a1 + 8) ) { v9 = a3; } else { memcpy(v6, a2, v7); v10 = ma_net_real_write((_BYTE *)a1, *(_QWORD *)(a1 + 8), *(_QWORD *)(a1 + 24) + v7 - *(_QWORD *)(a1 + 8)); result = 1LL; if ( v10 ) return result; v4 = v7 + a2; *(_QWORD *)(a1 + 24) = *(_QWORD *)(a1 + 8); } if ( !*(_BYTE *)(a1 + 132) || v9 < 0x1000000 ) { LABEL_18: if ( v9 > *(_QWORD *)(a1 + 80) ) return (unsigned int)ma_net_real_write((_BYTE *)a1, v4, v9) != 0; v6 = *(_QWORD *)(a1 + 24); goto LABEL_11; } while ( !(unsigned int)ma_net_real_write((_BYTE *)a1, v4, 0xFFFFFFLL) ) { v4 += 0xFFFFFFLL; v9 -= 0xFFFFFFLL; if ( v9 <= 0xFFFFFF ) goto LABEL_18; } return 1LL; }
ma_net_write_buff: XOR EAX,EAX TEST RDX,RDX JZ 0x00131c62 PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R12 PUSH RBX MOV R14,RSI MOV RBX,RDI CMP qword ptr [RDI + 0x50],0x1000000 JC 0x00131bf4 CMP byte ptr [RBX + 0x84],0x0 JZ 0x00131bf4 MOV R12,qword ptr [RBX + 0x8] MOV RDI,qword ptr [RBX + 0x18] SUB R12,RDI ADD R12,0xffffff JMP 0x00131bff LAB_00131bf4: MOV R12,qword ptr [RBX + 0x10] MOV RDI,qword ptr [RBX + 0x18] SUB R12,RDI LAB_00131bff: MOV R15,RDX SUB R15,R12 JBE 0x00131c46 CMP RDI,qword ptr [RBX + 0x8] JZ 0x00131c63 MOV RSI,R14 MOV RDX,R12 CALL 0x00113390 MOV RSI,qword ptr [RBX + 0x8] MOV RDX,R12 SUB RDX,RSI ADD RDX,qword ptr [RBX + 0x18] MOV RDI,RBX CALL 0x001318bf MOV ECX,EAX MOV EAX,0x1 TEST ECX,ECX JNZ 0x00131c5a ADD R14,R12 MOV RAX,qword ptr [RBX + 0x8] MOV qword ptr [RBX + 0x18],RAX JMP 0x00131c66 LAB_00131c46: MOV R15,RDX LAB_00131c49: MOV RSI,R14 MOV RDX,R15 CALL 0x00113390 ADD qword ptr [RBX + 0x18],R15 XOR EAX,EAX LAB_00131c5a: POP RBX POP R12 POP R14 POP R15 POP RBP LAB_00131c62: RET LAB_00131c63: MOV R15,RDX LAB_00131c66: CMP byte ptr [RBX + 0x84],0x0 JZ 0x00131ca1 CMP R15,0x1000000 JC 0x00131ca1 MOV R12D,0xffffff LAB_00131c7e: MOV EDX,0xffffff MOV RDI,RBX MOV RSI,R14 CALL 0x001318bf TEST EAX,EAX JNZ 0x00131cc6 ADD R14,R12 ADD R15,-0xffffff CMP R15,R12 JA 0x00131c7e LAB_00131ca1: CMP R15,qword ptr [RBX + 0x50] JBE 0x00131cc0 MOV RDI,RBX MOV RSI,R14 MOV RDX,R15 CALL 0x001318bf MOV ECX,EAX XOR EAX,EAX TEST ECX,ECX SETNZ AL JMP 0x00131c5a LAB_00131cc0: MOV RDI,qword ptr [RBX + 0x18] JMP 0x00131c49 LAB_00131cc6: MOV EAX,0x1 JMP 0x00131c5a
bool ma_net_write_buff(long param_1,void *param_2,ulong param_3) { int iVar1; void *__dest; ulong __n; if (param_3 != 0) { if ((*(ulong *)(param_1 + 0x50) < 0x1000000) || (*(char *)(param_1 + 0x84) == '\0')) { __dest = *(void **)(param_1 + 0x18); __n = *(long *)(param_1 + 0x10) - (long)__dest; } else { __dest = *(void **)(param_1 + 0x18); __n = (*(long *)(param_1 + 8) - (long)__dest) + 0xffffff; } if (__n <= param_3 && param_3 - __n != 0) { if (__dest != *(void **)(param_1 + 8)) { memcpy(__dest,param_2,__n); iVar1 = ma_net_real_write(param_1,*(long *)(param_1 + 8), (__n - *(long *)(param_1 + 8)) + *(long *)(param_1 + 0x18)); if (iVar1 != 0) { return true; } param_2 = (void *)((long)param_2 + __n); *(int8 *)(param_1 + 0x18) = *(int8 *)(param_1 + 8); param_3 = param_3 - __n; } if (*(char *)(param_1 + 0x84) != '\0') { for (; 0xffffff < param_3; param_3 = param_3 - 0xffffff) { iVar1 = ma_net_real_write(param_1,param_2,0xffffff); if (iVar1 != 0) { return true; } param_2 = (void *)((long)param_2 + 0xffffff); } } if (*(ulong *)(param_1 + 0x50) < param_3) { iVar1 = ma_net_real_write(param_1,param_2,param_3); return iVar1 != 0; } __dest = *(void **)(param_1 + 0x18); } memcpy(__dest,param_2,param_3); *(long *)(param_1 + 0x18) = *(long *)(param_1 + 0x18) + param_3; } return false; }
3,580
my_error_unregister
eloqsql/mysys/my_error.c
my_bool my_error_unregister(uint first, uint last) { struct my_err_head *meh_p; struct my_err_head **search_meh_pp; /* Search for the registration in the list. */ for (search_meh_pp= &my_errmsgs_list; *search_meh_pp; search_meh_pp= &(*search_meh_pp)->meh_next) { if (((*search_meh_pp)->meh_first == first) && ((*search_meh_pp)->meh_last == last)) break; } if (! *search_meh_pp) return TRUE; /* Remove header from the chain. */ meh_p= *search_meh_pp; *search_meh_pp= meh_p->meh_next; my_free(meh_p); return FALSE; }
O3
c
my_error_unregister: movq 0x2ecc59(%rip), %r8 # 0x38d8f8 movb $0x1, %al testq %r8, %r8 je 0xa0cdd pushq %rbp movq %rsp, %rbp leaq 0x2ecc47(%rip), %rdx # 0x38d8f8 movq %r8, %rcx cmpl %edi, 0x10(%r8) jne 0xa0cbf cmpl %esi, 0x14(%rcx) je 0xa0ccc movq (%rcx), %r8 movq %rcx, %rdx testq %r8, %r8 jne 0xa0cb1 jmp 0xa0cdc movq (%rcx), %rax movq %rax, (%rdx) movq %rcx, %rdi callq 0xa4b96 xorl %eax, %eax popq %rbp retq
my_error_unregister: mov r8, cs:my_errmsgs_list mov al, 1 test r8, r8 jz short locret_A0CDD push rbp mov rbp, rsp lea rdx, my_errmsgs_list loc_A0CB1: mov rcx, r8 cmp [r8+10h], edi jnz short loc_A0CBF cmp [rcx+14h], esi jz short loc_A0CCC loc_A0CBF: mov r8, [rcx] mov rdx, rcx test r8, r8 jnz short loc_A0CB1 jmp short loc_A0CDC loc_A0CCC: mov rax, [rcx] mov [rdx], rax mov rdi, rcx call my_free xor eax, eax loc_A0CDC: pop rbp locret_A0CDD: retn
char my_error_unregister(int a1, int a2) { long long *v2; // r8 char result; // al long long **v4; // rdx long long *v5; // rcx v2 = my_errmsgs_list; result = 1; if ( my_errmsgs_list ) { v4 = &my_errmsgs_list; while ( 1 ) { v5 = v2; if ( *((_DWORD *)v2 + 4) == a1 && *((_DWORD *)v2 + 5) == a2 ) break; v2 = (long long *)*v2; v4 = (long long **)v5; if ( !*v5 ) return result; } *v4 = (long long *)*v2; my_free(v2); return 0; } return result; }
my_error_unregister: MOV R8,qword ptr [0x0048d8f8] MOV AL,0x1 TEST R8,R8 JZ 0x001a0cdd PUSH RBP MOV RBP,RSP LEA RDX,[0x48d8f8] LAB_001a0cb1: MOV RCX,R8 CMP dword ptr [R8 + 0x10],EDI JNZ 0x001a0cbf CMP dword ptr [RCX + 0x14],ESI JZ 0x001a0ccc LAB_001a0cbf: MOV R8,qword ptr [RCX] MOV RDX,RCX TEST R8,R8 JNZ 0x001a0cb1 JMP 0x001a0cdc LAB_001a0ccc: MOV RAX,qword ptr [RCX] MOV qword ptr [RDX],RAX MOV RDI,RCX CALL 0x001a4b96 XOR EAX,EAX LAB_001a0cdc: POP RBP LAB_001a0cdd: RET
int8 my_error_unregister(int param_1,int param_2) { int **ppuVar1; int **ppuVar2; int **ppuVar3; if (my_errmsgs_list != (int *)0x0) { ppuVar2 = &my_errmsgs_list; ppuVar3 = (int **)my_errmsgs_list; do { if ((*(int *)(ppuVar3 + 2) == param_1) && (*(int *)((long)ppuVar3 + 0x14) == param_2)) { *ppuVar2 = *ppuVar3; my_free(ppuVar3); return 0; } ppuVar1 = (int **)*ppuVar3; ppuVar2 = ppuVar3; ppuVar3 = ppuVar1; } while (ppuVar1 != (int **)0x0); } return 1; }
3,581
PAIRING_Aggregate_PK_in_G1
corpus-core[P]colibri-stateless/build_O3/_deps/blst-src/src/aggregate.c
static BLST_ERROR PAIRING_Aggregate_PK_in_G1(PAIRING *ctx, const POINTonE1_affine *PK, size_t pk_groupcheck, const POINTonE2_affine *sig, size_t sig_groupcheck, const byte *scalar, size_t nbits, const void *msg, size_t msg_len, const void *aug, size_t aug_len) { if (ctx->ctrl & AGGR_MIN_SIG) return BLST_AGGR_TYPE_MISMATCH; ctx->ctrl |= AGGR_MIN_PK; /* * Since we don't know if the signature is individual or aggregated, * the only sensible thing to do is to skip over infinite one and * count on the corresponding infinite public key to be rejected, * in case the signature is non-aggregated that is. */ if (sig != NULL && !vec_is_zero(sig, sizeof(*sig))) { POINTonE2 *S = &ctx->AggrSign.e2; POINTonE2 P[1]; FROM_AFFINE(P, sig); if (sig_groupcheck && !POINTonE2_in_G2(P)) return BLST_POINT_NOT_IN_GROUP; if (ctx->ctrl & AGGR_SIGN_SET) { if (nbits != 0 && scalar != NULL) { POINTonE2_mult_w5(P, P, scalar, nbits); POINTonE2_dadd(S, S, P, NULL); } else { POINTonE2_dadd_affine(S, S, sig); } } else { ctx->ctrl |= AGGR_SIGN_SET; if (nbits != 0 && scalar != NULL) POINTonE2_mult_w5(S, P, scalar, nbits); else vec_copy(S, P, sizeof(P)); } } if (PK != NULL) { unsigned int n; POINTonE2 H[1]; POINTonE1 pk[1]; const void *DST = pairing_get_dst(ctx); /* * Reject infinite public keys. */ if (vec_is_zero(PK, sizeof(*PK))) return BLST_PK_IS_INFINITY; if (pk_groupcheck) { POINTonE1 P[1]; FROM_AFFINE(P, PK); if (!POINTonE1_in_G1(P)) return BLST_POINT_NOT_IN_GROUP; } if (ctx->ctrl & AGGR_HASH_OR_ENCODE) Hash_to_G2(H, msg, msg_len, DST, ctx->DST_len, aug, aug_len); else Encode_to_G2(H, msg, msg_len, DST, ctx->DST_len, aug, aug_len); POINTonE2_from_Jacobian(H, H); if (nbits != 0 && scalar != NULL) { FROM_AFFINE(pk, PK); POINTonE1_mult_w5(pk, pk, scalar, nbits); POINTonE1_from_Jacobian(pk, pk); PK = (const POINTonE1_affine *)pk; } n = ctx->nelems; vec_copy(ctx->Q + n, H, sizeof(POINTonE2_affine)); vec_copy(ctx->P + n, PK, sizeof(POINTonE1_affine)); if (++n == N_MAX) { if (ctx->ctrl & AGGR_GT_SET) { vec384fp12 GT; miller_loop_n(GT, ctx->Q, ctx->P, n); mul_fp12(ctx->GT, ctx->GT, GT); } else { miller_loop_n(ctx->GT, ctx->Q, ctx->P, n); ctx->ctrl |= AGGR_GT_SET; } n = 0; } ctx->nelems = n; } return BLST_SUCCESS; }
O3
c
PAIRING_Aggregate_PK_in_G1: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x408, %rsp # imm = 0x408 movq %r9, -0x30(%rbp) movq %rdx, -0x38(%rbp) movl (%rdi), %eax movl $0x4, %r13d testb $0x1, %al jne 0x2110c movq %rcx, %r15 movq %rsi, %r14 movq %rdi, %rbx orl $0x2, %eax movl %eax, (%rdi) testq %rcx, %rcx je 0x20dc7 movq %r8, %r12 movl $0xc0, %esi movq %r15, %rdi callq 0x2ff40 testq %rax, %rax je 0x20e09 xorl %r13d, %r13d testq %r14, %r14 je 0x2110c movq 0x8(%rbx), %rax leaq 0xc78(%rbx), %r12 cmpq $0x2a, %rax cmovneq %rax, %r12 movl $0x60, %esi movq %r14, %rdi callq 0x2ff40 movl $0x6, %ecx testq %rax, %rax je 0x20ea8 movl %ecx, %r13d jmp 0x2110c leaq -0x280(%rbp), %rdi movl $0xc0, %edx movq %r15, %rsi callq 0x5060 leaq -0x1c0(%rbp), %r13 movl $0xc0, %esi movq %r15, %rdi callq 0x2ff40 leaq 0x1ed10(%rip), %rdx # 0x3fb48 movq %r13, %rdi movq %r15, %rsi movq %rax, %rcx callq 0x2f920 testq %r12, %r12 je 0x20e60 leaq -0x280(%rbp), %rdi callq 0x1e929 testq %rax, %rax je 0x210a6 leaq 0x258(%rbx), %r12 movl (%rbx), %eax testb $0x10, %al jne 0x20f3d orl $0x10, %eax movl %eax, (%rbx) movq 0x10(%rbp), %rcx testq %rcx, %rcx sete %al movq -0x30(%rbp), %rdx testq %rdx, %rdx sete %sil orb %al, %sil jne 0x210b8 leaq -0x280(%rbp), %rsi movq %r12, %rdi callq 0x1e11b jmp 0x20dc7 cmpq $0x0, -0x38(%rbp) je 0x20efb leaq -0x280(%rbp), %r15 movl $0xc, %ecx movq %r15, %rdi movq %r14, %rsi rep movsq (%rsi), %es:(%rdi) movl $0x60, %esi movq %r14, %rdi callq 0x2ff40 leaq 0x1ec70(%rip), %rdx # 0x3fb48 leaq -0x220(%rbp), %rdi movq %r14, %rsi movq %rax, %rcx callq 0x2f8a0 movq %r15, %rdi callq 0x1b662 testq %rax, %rax je 0x210ae movq 0x30(%rbp), %rcx movq 0x28(%rbp), %rdx movq 0x20(%rbp), %r9 movq 0x18(%rbp), %r8 testb $0x40, (%rbx) movq 0x10(%rbx), %rax leaq -0x280(%rbp), %r15 jne 0x20f82 movl $0x2, %esi movq %r15, %rdi pushq %rax pushq %r12 callq 0x2666a addq $0x10, %rsp leaq -0x430(%rbp), %rdi movq %r15, %rsi xorl %edx, %edx jmp 0x20fa7 movq 0x10(%rbp), %rcx testq %rcx, %rcx sete %al movq -0x30(%rbp), %rdx testq %rdx, %rdx sete %sil orb %al, %sil jne 0x210d1 leaq -0x280(%rbp), %r15 movq %r15, %rdi movq %r15, %rsi callq 0x1e11b movq %r12, %rdi movq %r12, %rsi movq %r15, %rdx xorl %ecx, %ecx callq 0x1c8af jmp 0x20dc7 movl $0x4, %esi movq %r15, %rdi pushq %rax pushq %r12 callq 0x2666a addq $0x10, %rsp leaq -0x220(%rbp), %rdx leaq -0x430(%rbp), %rdi movq %r15, %rsi callq 0x1e3a9 leaq -0x430(%rbp), %rdi movq %rdi, %rsi callq 0x1b7fc movq 0x10(%rbp), %rax testq %rax, %rax sete %al movq -0x30(%rbp), %r12 testq %r12, %r12 sete %cl orb %al, %cl jne 0x2102e leaq -0x310(%rbp), %r15 movl $0xc, %ecx movq %r15, %rdi movq %r14, %rsi rep movsq (%rsi), %es:(%rdi) movl $0x60, %esi movq %r14, %rdi callq 0x2ff40 leaq 0x1eb4c(%rip), %rdx # 0x3fb48 leaq -0x2b0(%rbp), %rdi movq %r14, %rsi movq %rax, %rcx callq 0x2f8a0 movq %r15, %rdi movq %r15, %rsi movq %r12, %rdx movq 0x10(%rbp), %rcx callq 0x1af02 movq %r15, %rdi movq %r15, %rsi callq 0x18a4a movq %r15, %r14 movl 0x4(%rbx), %r15d leaq (%r15,%r15,2), %r12 movq %r12, %rax shlq $0x6, %rax leaq (%rbx,%rax), %rdi addq $0x378, %rdi # imm = 0x378 leaq -0x430(%rbp), %rsi movl $0xc0, %edx callq 0x5060 shlq $0x5, %r12 leaq (%rbx,%r12), %rdi addq $0x978, %rdi # imm = 0x978 movl $0xc, %ecx movq %r14, %rsi rep movsq (%rsi), %es:(%rdi) leal 0x1(%r15), %eax cmpl $0x8, %eax jne 0x21109 leaq 0x378(%rbx), %rsi leaq 0x978(%rbx), %rdx testb $0x20, (%rbx) jne 0x210e4 leaq 0x18(%rbx), %rdi movl $0x8, %ecx callq 0x1fbe1 orb $0x20, (%rbx) jmp 0x21107 movl $0x3, %r13d jmp 0x2110c movl $0x3, %ecx jmp 0x20e01 leaq -0x280(%rbp), %rsi movl $0x120, %edx # imm = 0x120 movq %r12, %rdi callq 0x5060 jmp 0x20dc7 movq %r12, %rdi movq %r12, %rsi movq %r15, %rdx callq 0x1cfaf jmp 0x20dc7 leaq -0x280(%rbp), %r14 movl $0x8, %ecx movq %r14, %rdi callq 0x1fbe1 leaq 0x18(%rbx), %rdi movq %rdi, %rsi movq %r14, %rdx callq 0x1ee00 xorl %eax, %eax movl %eax, 0x4(%rbx) movl %r13d, %eax addq $0x408, %rsp # imm = 0x408 popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
PAIRING_Aggregate_PK_in_G1: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 408h mov [rbp+var_30], r9 mov [rbp+var_38], rdx mov eax, [rdi] mov r13d, 4 test al, 1 jnz loc_2110C mov r15, rcx mov r14, rsi mov rbx, rdi or eax, 2 mov [rdi], eax test rcx, rcx jz short loc_20DC7 mov r12, r8 mov esi, 0C0h mov rdi, r15 call vec_is_zero_16x test rax, rax jz short loc_20E09 loc_20DC7: xor r13d, r13d test r14, r14 jz loc_2110C mov rax, [rbx+8] lea r12, [rbx+0C78h] cmp rax, 2Ah ; '*' cmovnz r12, rax mov esi, 60h ; '`' mov rdi, r14 call vec_is_zero_16x mov ecx, 6 test rax, rax jz loc_20EA8 loc_20E01: mov r13d, ecx jmp loc_2110C loc_20E09: lea rdi, [rbp+var_280] mov edx, 0C0h mov rsi, r15 call _memcpy lea r13, [rbp+var_1C0] mov esi, 0C0h mov rdi, r15 call vec_is_zero_16x lea rdx, BLS12_381_Rx mov rdi, r13 mov rsi, r15 mov rcx, rax call vec_select_96 test r12, r12 jz short loc_20E60 lea rdi, [rbp+var_280] call POINTonE2_in_G2 test rax, rax jz loc_210A6 loc_20E60: lea r12, [rbx+258h] mov eax, [rbx] test al, 10h jnz loc_20F3D or eax, 10h mov [rbx], eax mov rcx, [rbp+arg_0] test rcx, rcx setz al mov rdx, [rbp+var_30] test rdx, rdx setz sil or sil, al jnz loc_210B8 lea rsi, [rbp+var_280] mov rdi, r12 call POINTonE2_mult_w5 jmp loc_20DC7 loc_20EA8: cmp [rbp+var_38], 0 jz short loc_20EFB lea r15, [rbp+var_280] mov ecx, 0Ch mov rdi, r15 mov rsi, r14 rep movsq mov esi, 60h ; '`' mov rdi, r14 call vec_is_zero_16x lea rdx, BLS12_381_Rx lea rdi, [rbp+var_220] mov rsi, r14 mov rcx, rax call vec_select_48 mov rdi, r15 call POINTonE1_in_G1 test rax, rax jz loc_210AE loc_20EFB: mov rcx, [rbp+arg_20] mov rdx, [rbp+arg_18] mov r9, [rbp+arg_10] mov r8, [rbp+arg_8] test byte ptr [rbx], 40h mov rax, [rbx+10h] lea r15, [rbp+var_280] jnz short loc_20F82 mov esi, 2 mov rdi, r15 push rax push r12 call hash_to_field add rsp, 10h lea rdi, [rbp+var_430] mov rsi, r15 xor edx, edx jmp short loc_20FA7 loc_20F3D: mov rcx, [rbp+arg_0] test rcx, rcx setz al mov rdx, [rbp+var_30] test rdx, rdx setz sil or sil, al jnz loc_210D1 lea r15, [rbp+var_280] mov rdi, r15 mov rsi, r15 call POINTonE2_mult_w5 mov rdi, r12 mov rsi, r12 mov rdx, r15 xor ecx, ecx call POINTonE2_dadd jmp loc_20DC7 loc_20F82: mov esi, 4 mov rdi, r15 push rax push r12 call hash_to_field add rsp, 10h lea rdx, [rbp+var_220] lea rdi, [rbp+var_430] mov rsi, r15 loc_20FA7: call map_to_g2 lea rdi, [rbp+var_430] mov rsi, rdi call POINTonE2_from_Jacobian mov rax, [rbp+arg_0] test rax, rax setz al mov r12, [rbp+var_30] test r12, r12 setz cl or cl, al jnz short loc_2102E lea r15, [rbp+var_310] mov ecx, 0Ch mov rdi, r15 mov rsi, r14 rep movsq mov esi, 60h ; '`' mov rdi, r14 call vec_is_zero_16x lea rdx, BLS12_381_Rx lea rdi, [rbp+var_2B0] mov rsi, r14 mov rcx, rax call vec_select_48 mov rdi, r15 mov rsi, r15 mov rdx, r12 mov rcx, [rbp+arg_0] call POINTonE1_mult_w5 mov rdi, r15 mov rsi, r15 call POINTonE1_from_Jacobian mov r14, r15 loc_2102E: mov r15d, [rbx+4] lea r12, [r15+r15*2] mov rax, r12 shl rax, 6 lea rdi, [rbx+rax] add rdi, 378h lea rsi, [rbp+var_430] mov edx, 0C0h call _memcpy shl r12, 5 lea rdi, [rbx+r12] add rdi, 978h mov ecx, 0Ch mov rsi, r14 rep movsq lea eax, [r15+1] cmp eax, 8 jnz loc_21109 lea rsi, [rbx+378h] lea rdx, [rbx+978h] test byte ptr [rbx], 20h jnz short loc_210E4 lea rdi, [rbx+18h] mov ecx, 8 call miller_loop_n or byte ptr [rbx], 20h jmp short loc_21107 loc_210A6: mov r13d, 3 jmp short loc_2110C loc_210AE: mov ecx, 3 jmp loc_20E01 loc_210B8: lea rsi, [rbp+var_280] mov edx, 120h mov rdi, r12 call _memcpy jmp loc_20DC7 loc_210D1: mov rdi, r12 mov rsi, r12 mov rdx, r15 call POINTonE2_dadd_affine jmp loc_20DC7 loc_210E4: lea r14, [rbp+var_280] mov ecx, 8 mov rdi, r14 call miller_loop_n lea rdi, [rbx+18h] mov rsi, rdi mov rdx, r14 call mul_fp12 loc_21107: xor eax, eax loc_21109: mov [rbx+4], eax loc_2110C: mov eax, r13d add rsp, 408h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long PAIRING_Aggregate_PK_in_G1( long long a1, _BYTE *a2, long long a3, long long a4, long long a5, unsigned __int8 *a6, unsigned long long a7, long long a8, long long a9, long long a10, long long a11) { unsigned int v11; // r13d _BYTE *v13; // r14 long long v15; // r12 long long v16; // rax unsigned int v17; // ecx long long is_zero_16x; // rax long long v19; // rax _BYTE *v20; // rdx unsigned __int8 *v21; // r12 long long v22; // rax long long v23; // r15 int v24; // eax long long v25; // rsi long long v26; // rdx _BYTE v28[288]; // [rsp+0h] [rbp-430h] BYREF _BYTE v29[96]; // [rsp+120h] [rbp-310h] BYREF _BYTE v30[48]; // [rsp+180h] [rbp-2B0h] BYREF char v31[96]; // [rsp+1B0h] [rbp-280h] BYREF _BYTE v32[96]; // [rsp+210h] [rbp-220h] BYREF _BYTE v33[392]; // [rsp+270h] [rbp-1C0h] BYREF long long v34; // [rsp+3F8h] [rbp-38h] unsigned __int8 *v35; // [rsp+400h] [rbp-30h] v35 = a6; v34 = a3; v11 = 4; if ( (*(_DWORD *)a1 & 1) == 0 ) { v13 = a2; *(_DWORD *)a1 |= 2u; if ( a4 && !vec_is_zero_16x(a4, 192LL) ) { memcpy(v31, a4, 192LL); is_zero_16x = vec_is_zero_16x(a4, 192LL); vec_select_96(v33, a4, &BLS12_381_Rx, is_zero_16x); if ( a5 && !POINTonE2_in_G2((long long)v31) ) return 3; if ( (*(_DWORD *)a1 & 0x10) != 0 ) { if ( a7 == 0 || v35 == 0LL ) { POINTonE2_dadd_affine(a1 + 600, a1 + 600, a4); } else { POINTonE2_mult_w5((long long)v31, (long long)v31, v35, a7); POINTonE2_dadd(a1 + 600, a1 + 600, (long long)v31, 0LL); } } else { *(_DWORD *)a1 |= 0x10u; if ( a7 == 0 || v35 == 0LL ) memcpy(a1 + 600, v31, 288LL); else POINTonE2_mult_w5(a1 + 600, (long long)v31, v35, a7); } } v11 = 0; if ( a2 ) { v15 = a1 + 3192; if ( *(_QWORD *)(a1 + 8) != 42LL ) v15 = *(_QWORD *)(a1 + 8); v16 = vec_is_zero_16x(a2, 96LL); v17 = 6; if ( v16 ) return v17; if ( v34 ) { qmemcpy(v31, a2, sizeof(v31)); v19 = vec_is_zero_16x(a2, 96LL); vec_select_48(v32, a2, &BLS12_381_Rx, v19); if ( !POINTonE1_in_G1(v31) ) return 3; } if ( (*(_BYTE *)a1 & 0x40) != 0 ) { hash_to_field((unsigned int)v31, 4, a10, a11, a8, a9, v15, *(_QWORD *)(a1 + 16)); v20 = v32; } else { hash_to_field((unsigned int)v31, 2, a10, a11, a8, a9, v15, *(_QWORD *)(a1 + 16)); v20 = 0LL; } map_to_g2((long long)v28, (long long)v31, (long long)v20); POINTonE2_from_Jacobian((long long)v28, (long long)v28); v21 = v35; if ( a7 != 0 && v35 != 0LL ) { qmemcpy(v29, a2, sizeof(v29)); v22 = vec_is_zero_16x(a2, 96LL); vec_select_48(v30, a2, &BLS12_381_Rx, v22); POINTonE1_mult_w5((long long)v29, (long long)v29, v21, a7); POINTonE1_from_Jacobian((long long)v29, (long long)v29); v13 = v29; } v23 = *(unsigned int *)(a1 + 4); memcpy(a1 + 192 * v23 + 888, v28, 192LL); qmemcpy((void *)(a1 + 96 * v23 + 2424), v13, 0x60uLL); v24 = v23 + 1; if ( (_DWORD)v23 == 7 ) { v25 = a1 + 888; v26 = a1 + 2424; if ( (*(_BYTE *)a1 & 0x20) != 0 ) { miller_loop_n((long long)v31, v25, v26, 8LL); mul_fp12(a1 + 24, a1 + 24, (long long)v31); } else { miller_loop_n(a1 + 24, v25, v26, 8LL); *(_BYTE *)a1 |= 0x20u; } v24 = 0; } *(_DWORD *)(a1 + 4) = v24; } } return v11; }
PAIRING_Aggregate_PK_in_G1: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x408 MOV qword ptr [RBP + -0x30],R9 MOV qword ptr [RBP + -0x38],RDX MOV EAX,dword ptr [RDI] MOV R13D,0x4 TEST AL,0x1 JNZ 0x0012110c MOV R15,RCX MOV R14,RSI MOV RBX,RDI OR EAX,0x2 MOV dword ptr [RDI],EAX TEST RCX,RCX JZ 0x00120dc7 MOV R12,R8 MOV ESI,0xc0 MOV RDI,R15 CALL 0x0012ff40 TEST RAX,RAX JZ 0x00120e09 LAB_00120dc7: XOR R13D,R13D TEST R14,R14 JZ 0x0012110c MOV RAX,qword ptr [RBX + 0x8] LEA R12,[RBX + 0xc78] CMP RAX,0x2a CMOVNZ R12,RAX MOV ESI,0x60 MOV RDI,R14 CALL 0x0012ff40 MOV ECX,0x6 TEST RAX,RAX JZ 0x00120ea8 LAB_00120e01: MOV R13D,ECX JMP 0x0012110c LAB_00120e09: LEA RDI,[RBP + -0x280] MOV EDX,0xc0 MOV RSI,R15 CALL 0x00105060 LEA R13,[RBP + -0x1c0] MOV ESI,0xc0 MOV RDI,R15 CALL 0x0012ff40 LEA RDX,[0x13fb48] MOV RDI,R13 MOV RSI,R15 MOV RCX,RAX CALL 0x0012f920 TEST R12,R12 JZ 0x00120e60 LEA RDI,[RBP + -0x280] CALL 0x0011e929 TEST RAX,RAX JZ 0x001210a6 LAB_00120e60: LEA R12,[RBX + 0x258] MOV EAX,dword ptr [RBX] TEST AL,0x10 JNZ 0x00120f3d OR EAX,0x10 MOV dword ptr [RBX],EAX MOV RCX,qword ptr [RBP + 0x10] TEST RCX,RCX SETZ AL MOV RDX,qword ptr [RBP + -0x30] TEST RDX,RDX SETZ SIL OR SIL,AL JNZ 0x001210b8 LEA RSI,[RBP + -0x280] MOV RDI,R12 CALL 0x0011e11b JMP 0x00120dc7 LAB_00120ea8: CMP qword ptr [RBP + -0x38],0x0 JZ 0x00120efb LEA R15,[RBP + -0x280] MOV ECX,0xc MOV RDI,R15 MOV RSI,R14 MOVSQ.REP RDI,RSI MOV ESI,0x60 MOV RDI,R14 CALL 0x0012ff40 LEA RDX,[0x13fb48] LEA RDI,[RBP + -0x220] MOV RSI,R14 MOV RCX,RAX CALL 0x0012f8a0 MOV RDI,R15 CALL 0x0011b662 TEST RAX,RAX JZ 0x001210ae LAB_00120efb: MOV RCX,qword ptr [RBP + 0x30] MOV RDX,qword ptr [RBP + 0x28] MOV R9,qword ptr [RBP + 0x20] MOV R8,qword ptr [RBP + 0x18] TEST byte ptr [RBX],0x40 MOV RAX,qword ptr [RBX + 0x10] LEA R15,[RBP + -0x280] JNZ 0x00120f82 MOV ESI,0x2 MOV RDI,R15 PUSH RAX PUSH R12 CALL 0x0012666a ADD RSP,0x10 LEA RDI,[RBP + -0x430] MOV RSI,R15 XOR EDX,EDX JMP 0x00120fa7 LAB_00120f3d: MOV RCX,qword ptr [RBP + 0x10] TEST RCX,RCX SETZ AL MOV RDX,qword ptr [RBP + -0x30] TEST RDX,RDX SETZ SIL OR SIL,AL JNZ 0x001210d1 LEA R15,[RBP + -0x280] MOV RDI,R15 MOV RSI,R15 CALL 0x0011e11b MOV RDI,R12 MOV RSI,R12 MOV RDX,R15 XOR ECX,ECX CALL 0x0011c8af JMP 0x00120dc7 LAB_00120f82: MOV ESI,0x4 MOV RDI,R15 PUSH RAX PUSH R12 CALL 0x0012666a ADD RSP,0x10 LEA RDX,[RBP + -0x220] LEA RDI,[RBP + -0x430] MOV RSI,R15 LAB_00120fa7: CALL 0x0011e3a9 LEA RDI,[RBP + -0x430] MOV RSI,RDI CALL 0x0011b7fc MOV RAX,qword ptr [RBP + 0x10] TEST RAX,RAX SETZ AL MOV R12,qword ptr [RBP + -0x30] TEST R12,R12 SETZ CL OR CL,AL JNZ 0x0012102e LEA R15,[RBP + -0x310] MOV ECX,0xc MOV RDI,R15 MOV RSI,R14 MOVSQ.REP RDI,RSI MOV ESI,0x60 MOV RDI,R14 CALL 0x0012ff40 LEA RDX,[0x13fb48] LEA RDI,[RBP + -0x2b0] MOV RSI,R14 MOV RCX,RAX CALL 0x0012f8a0 MOV RDI,R15 MOV RSI,R15 MOV RDX,R12 MOV RCX,qword ptr [RBP + 0x10] CALL 0x0011af02 MOV RDI,R15 MOV RSI,R15 CALL 0x00118a4a MOV R14,R15 LAB_0012102e: MOV R15D,dword ptr [RBX + 0x4] LEA R12,[R15 + R15*0x2] MOV RAX,R12 SHL RAX,0x6 LEA RDI,[RBX + RAX*0x1] ADD RDI,0x378 LEA RSI,[RBP + -0x430] MOV EDX,0xc0 CALL 0x00105060 SHL R12,0x5 LEA RDI,[RBX + R12*0x1] ADD RDI,0x978 MOV ECX,0xc MOV RSI,R14 MOVSQ.REP RDI,RSI LEA EAX,[R15 + 0x1] CMP EAX,0x8 JNZ 0x00121109 LEA RSI,[RBX + 0x378] LEA RDX,[RBX + 0x978] TEST byte ptr [RBX],0x20 JNZ 0x001210e4 LEA RDI,[RBX + 0x18] MOV ECX,0x8 CALL 0x0011fbe1 OR byte ptr [RBX],0x20 JMP 0x00121107 LAB_001210a6: MOV R13D,0x3 JMP 0x0012110c LAB_001210ae: MOV ECX,0x3 JMP 0x00120e01 LAB_001210b8: LEA RSI,[RBP + -0x280] MOV EDX,0x120 MOV RDI,R12 CALL 0x00105060 JMP 0x00120dc7 LAB_001210d1: MOV RDI,R12 MOV RSI,R12 MOV RDX,R15 CALL 0x0011cfaf JMP 0x00120dc7 LAB_001210e4: LEA R14,[RBP + -0x280] MOV ECX,0x8 MOV RDI,R14 CALL 0x0011fbe1 LEA RDI,[RBX + 0x18] MOV RSI,RDI MOV RDX,R14 CALL 0x0011ee00 LAB_00121107: XOR EAX,EAX LAB_00121109: MOV dword ptr [RBX + 0x4],EAX LAB_0012110c: MOV EAX,R13D ADD RSP,0x408 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int4 PAIRING_Aggregate_PK_in_G1 (uint *param_1,int8 *param_2,long param_3,void *param_4,long param_5,long param_6, long param_7,int8 param_8,int8 param_9,int8 param_10,int8 param_11 ) { uint uVar1; long lVar2; int8 uVar3; int4 uVar4; long lVar5; int1 *puVar6; int8 *puVar7; int8 *puVar8; int8 *puVar9; uint *puVar10; byte bVar11; int1 local_438 [288]; int8 local_318 [12]; int1 local_2b8 [48]; int8 local_288 [12]; int1 local_228 [96]; int1 local_1c8 [392]; long local_40; long local_38; bVar11 = 0; uVar4 = 4; if ((*param_1 & 1) == 0) { *param_1 = *param_1 | 2; local_40 = param_3; local_38 = param_6; if ((param_4 != (void *)0x0) && (lVar2 = vec_is_zero_16x(param_4,0xc0), lVar2 == 0)) { memcpy(local_288,param_4,0xc0); uVar3 = vec_is_zero_16x(param_4,0xc0); vec_select_96(local_1c8,param_4,&BLS12_381_Rx,uVar3); if ((param_5 != 0) && (lVar2 = POINTonE2_in_G2(local_288), lVar2 == 0)) { return 3; } puVar10 = param_1 + 0x96; if ((*param_1 & 0x10) == 0) { *param_1 = *param_1 | 0x10; if (local_38 == 0 || param_7 == 0) { memcpy(puVar10,local_288,0x120); } else { POINTonE2_mult_w5(puVar10,local_288); } } else if (local_38 == 0 || param_7 == 0) { POINTonE2_dadd_affine(puVar10,puVar10,param_4); } else { POINTonE2_mult_w5(local_288,local_288); POINTonE2_dadd(puVar10,puVar10,local_288,0); } } uVar4 = 0; if (param_2 != (int8 *)0x0) { puVar10 = param_1 + 0x31e; if (*(uint **)(param_1 + 2) != (uint *)0x2a) { puVar10 = *(uint **)(param_1 + 2); } lVar2 = vec_is_zero_16x(param_2,0x60); uVar4 = 6; if (lVar2 == 0) { if (local_40 != 0) { puVar8 = param_2; puVar7 = local_288; for (lVar2 = 0xc; lVar2 != 0; lVar2 = lVar2 + -1) { *puVar7 = *puVar8; puVar8 = puVar8 + (ulong)bVar11 * -2 + 1; puVar7 = puVar7 + (ulong)bVar11 * -2 + 1; } uVar3 = vec_is_zero_16x(param_2,0x60); vec_select_48(local_228,param_2,&BLS12_381_Rx,uVar3); lVar2 = POINTonE1_in_G1(local_288); if (lVar2 == 0) { return 3; } } if ((*param_1 & 0x40) == 0) { hash_to_field(local_288,2,param_10,param_11,param_8,param_9,puVar10, *(int8 *)(param_1 + 4)); puVar6 = (int1 *)0x0; } else { hash_to_field(local_288,4,param_10,param_11,param_8,param_9,puVar10, *(int8 *)(param_1 + 4)); puVar6 = local_228; } map_to_g2(local_438,local_288,puVar6); POINTonE2_from_Jacobian(local_438,local_438); lVar2 = local_38; puVar8 = param_2; if (local_38 != 0 && param_7 != 0) { puVar8 = local_318; puVar7 = param_2; puVar9 = puVar8; for (lVar5 = 0xc; lVar5 != 0; lVar5 = lVar5 + -1) { *puVar9 = *puVar7; puVar7 = puVar7 + (ulong)bVar11 * -2 + 1; puVar9 = puVar9 + (ulong)bVar11 * -2 + 1; } uVar3 = vec_is_zero_16x(param_2,0x60); vec_select_48(local_2b8,param_2,&BLS12_381_Rx,uVar3); POINTonE1_mult_w5(puVar8,puVar8,lVar2,param_7); POINTonE1_from_Jacobian(puVar8,puVar8); } uVar1 = param_1[1]; memcpy(param_1 + (ulong)uVar1 * 0x30 + 0xde,local_438,0xc0); puVar10 = param_1 + (ulong)uVar1 * 0x18 + 0x25e; for (lVar2 = 0xc; lVar2 != 0; lVar2 = lVar2 + -1) { *(int8 *)puVar10 = *puVar8; puVar8 = puVar8 + (ulong)bVar11 * -2 + 1; puVar10 = puVar10 + (ulong)bVar11 * -4 + 2; } uVar1 = uVar1 + 1; if (uVar1 == 8) { if ((*param_1 & 0x20) == 0) { miller_loop_n(param_1 + 6,param_1 + 0xde,param_1 + 0x25e,8); *(byte *)param_1 = (byte)*param_1 | 0x20; } else { miller_loop_n(local_288,param_1 + 0xde,param_1 + 0x25e,8); mul_fp12(param_1 + 6,param_1 + 6,local_288); } uVar1 = 0; } param_1[1] = uVar1; uVar4 = 0; } } } return uVar4; }
3,582
ac_expr_sequence_append_rule
alca/libalca/expr.c
void ac_expr_sequence_append_rule(ac_statement *seq, ac_statement *rule) { if (seq) { if (!seq->u.sequence.rules) seq->u.sequence.rules = ac_alloc(sizeof(ac_statement *)); else seq->u.sequence.rules = ac_realloc(seq->u.sequence.rules, sizeof(ac_statement *) * (seq->u.sequence.rule_count + 1)); seq->u.sequence.rules[seq->u.sequence.rule_count++] = rule; } }
O0
c
ac_expr_sequence_append_rule: pushq %rbp movq %rsp, %rbp subq $0x10, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) cmpq $0x0, -0x8(%rbp) je 0xb8f4 movq -0x8(%rbp), %rax cmpq $0x0, 0x18(%rax) jne 0xb8a9 movl $0x8, %edi callq 0x7890 movq %rax, %rcx movq -0x8(%rbp), %rax movq %rcx, 0x18(%rax) jmp 0xb8d3 movq -0x8(%rbp), %rax movq 0x18(%rax), %rdi movq -0x8(%rbp), %rax movl 0x14(%rax), %eax addl $0x1, %eax movl %eax, %eax shlq $0x3, %rax movl %eax, %esi callq 0x79b0 movq %rax, %rcx movq -0x8(%rbp), %rax movq %rcx, 0x18(%rax) movq -0x10(%rbp), %rdx movq -0x8(%rbp), %rax movq 0x18(%rax), %rax movq -0x8(%rbp), %rsi movl 0x14(%rsi), %ecx movl %ecx, %edi addl $0x1, %edi movl %edi, 0x14(%rsi) movl %ecx, %ecx movq %rdx, (%rax,%rcx,8) addq $0x10, %rsp popq %rbp retq nopw (%rax,%rax)
ac_expr_sequence_append_rule: push rbp mov rbp, rsp sub rsp, 10h mov [rbp+var_8], rdi mov [rbp+var_10], rsi cmp [rbp+var_8], 0 jz short loc_B8F4 mov rax, [rbp+var_8] cmp qword ptr [rax+18h], 0 jnz short loc_B8A9 mov edi, 8 call _ac_alloc mov rcx, rax mov rax, [rbp+var_8] mov [rax+18h], rcx jmp short loc_B8D3 loc_B8A9: mov rax, [rbp+var_8] mov rdi, [rax+18h] mov rax, [rbp+var_8] mov eax, [rax+14h] add eax, 1 mov eax, eax shl rax, 3 mov esi, eax call _ac_realloc mov rcx, rax mov rax, [rbp+var_8] mov [rax+18h], rcx loc_B8D3: mov rdx, [rbp+var_10] mov rax, [rbp+var_8] mov rax, [rax+18h] mov rsi, [rbp+var_8] mov ecx, [rsi+14h] mov edi, ecx add edi, 1 mov [rsi+14h], edi mov ecx, ecx mov [rax+rcx*8], rdx loc_B8F4: add rsp, 10h pop rbp retn
void ac_expr_sequence_append_rule(long long a1, long long a2) { long long v2; // rcx long long v3; // rax unsigned int v4; // ecx if ( a1 ) { if ( *(_QWORD *)(a1 + 24) ) v2 = ac_realloc(*(_QWORD *)(a1 + 24), (unsigned int)(8 * (*(_DWORD *)(a1 + 20) + 1))); else v2 = ac_alloc(8LL); *(_QWORD *)(a1 + 24) = v2; v3 = *(_QWORD *)(a1 + 24); v4 = *(_DWORD *)(a1 + 20); *(_DWORD *)(a1 + 20) = v4 + 1; *(_QWORD *)(v3 + 8LL * v4) = a2; } }
ac_expr_sequence_append_rule: PUSH RBP MOV RBP,RSP SUB RSP,0x10 MOV qword ptr [RBP + -0x8],RDI MOV qword ptr [RBP + -0x10],RSI CMP qword ptr [RBP + -0x8],0x0 JZ 0x0010b8f4 MOV RAX,qword ptr [RBP + -0x8] CMP qword ptr [RAX + 0x18],0x0 JNZ 0x0010b8a9 MOV EDI,0x8 CALL 0x00107890 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0x18],RCX JMP 0x0010b8d3 LAB_0010b8a9: MOV RAX,qword ptr [RBP + -0x8] MOV RDI,qword ptr [RAX + 0x18] MOV RAX,qword ptr [RBP + -0x8] MOV EAX,dword ptr [RAX + 0x14] ADD EAX,0x1 MOV EAX,EAX SHL RAX,0x3 MOV ESI,EAX CALL 0x001079b0 MOV RCX,RAX MOV RAX,qword ptr [RBP + -0x8] MOV qword ptr [RAX + 0x18],RCX LAB_0010b8d3: MOV RDX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RBP + -0x8] MOV RAX,qword ptr [RAX + 0x18] MOV RSI,qword ptr [RBP + -0x8] MOV ECX,dword ptr [RSI + 0x14] MOV EDI,ECX ADD EDI,0x1 MOV dword ptr [RSI + 0x14],EDI MOV ECX,ECX MOV qword ptr [RAX + RCX*0x8],RDX LAB_0010b8f4: ADD RSP,0x10 POP RBP RET
void ac_expr_sequence_append_rule(long param_1,int8 param_2) { uint uVar1; int8 uVar2; if (param_1 != 0) { if (*(long *)(param_1 + 0x18) == 0) { uVar2 = ac_alloc(8); *(int8 *)(param_1 + 0x18) = uVar2; } else { uVar2 = ac_realloc(*(int8 *)(param_1 + 0x18),(*(int *)(param_1 + 0x14) + 1) * 8); *(int8 *)(param_1 + 0x18) = uVar2; } uVar1 = *(uint *)(param_1 + 0x14); *(uint *)(param_1 + 0x14) = uVar1 + 1; *(int8 *)(*(long *)(param_1 + 0x18) + (ulong)uVar1 * 8) = param_2; } return; }
3,583
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>>>::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>>>::key() const: pushq %rbx movq (%rdi), %rax testq %rax, %rax je 0x8a37e movq %rdi, %rbx movzbl (%rax), %eax cmpl $0x1, %eax je 0x8a36c cmpl $0x2, %eax jne 0x8a375 movq 0x20(%rbx), %rsi cmpq 0x28(%rbx), %rsi je 0x8a366 leaq 0x30(%rbx), %rdi callq 0x48a2a movq 0x20(%rbx), %rax movq %rax, 0x28(%rbx) addq $0x30, %rbx jmp 0x8a379 movq %rbx, %rdi popq %rbx jmp 0x8a3a0 addq $0x50, %rbx movq %rbx, %rax popq %rbx retq leaq 0x2d415(%rip), %rdi # 0xb779a leaq 0x2adf6(%rip), %rdx # 0xb5182 leaq 0x2d61f(%rip), %rcx # 0xb79b2 movl $0x1491, %esi # imm = 0x1491 xorl %eax, %eax callq 0x19b30 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_8A37E mov rbx, rdi movzx eax, byte ptr [rax] cmp eax, 1 jz short loc_8A36C cmp eax, 2 jnz short loc_8A375 mov rsi, [rbx+20h] cmp rsi, [rbx+28h] jz short loc_8A366 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_8A366: add rbx, 30h ; '0' jmp short loc_8A379 loc_8A36C: 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_8A375: add rbx, 50h ; 'P' loc_8A379: mov rax, rbx pop rbx retn loc_8A37E: lea rdi, aWorkspaceLlm4b_2; "/workspace/llm4binary/github/2025_star3"... lea rdx, aGgmlAssertSFai; "GGML_ASSERT(%s) failed" lea rcx, aAnchorMObjectN; "anchor.m_object != nullptr" mov esi, 1491h xor eax, eax call _ggml_abort nop
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, double a2) { int v2; // eax unsigned long long v3; // rsi double v6; // xmm0_8 if ( *a1 ) { v2 = **a1; if ( v2 == 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(a2); } else { if ( v2 != 2 ) return (long long)(a1 + 10); v3 = (unsigned long long)a1[4]; if ( (unsigned __int8 *)v3 != a1[5] ) { nlohmann::json_abi_v3_11_3::detail::int_to_string<std::string>((long long)(a1 + 6), v3); a1[5] = a1[4]; } return (long long)(a1 + 6); } } else { v6 = ggml_abort( "/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp", 5265LL, "GGML_ASSERT(%s) failed", "anchor.m_object != nullptr"); 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(v6); } }
key: PUSH RBX MOV RAX,qword ptr [RDI] TEST RAX,RAX JZ 0x0018a37e MOV RBX,RDI MOVZX EAX,byte ptr [RAX] CMP EAX,0x1 JZ 0x0018a36c CMP EAX,0x2 JNZ 0x0018a375 MOV RSI,qword ptr [RBX + 0x20] CMP RSI,qword ptr [RBX + 0x28] JZ 0x0018a366 LEA RDI,[RBX + 0x30] CALL 0x00148a2a MOV RAX,qword ptr [RBX + 0x20] MOV qword ptr [RBX + 0x28],RAX LAB_0018a366: ADD RBX,0x30 JMP 0x0018a379 LAB_0018a36c: MOV RDI,RBX POP RBX JMP 0x0018a3a0 LAB_0018a375: ADD RBX,0x50 LAB_0018a379: MOV RAX,RBX POP RBX RET LAB_0018a37e: LEA RDI,[0x1b779a] LEA RDX,[0x1b5182] LEA RCX,[0x1b79b2] MOV ESI,0x1491 XOR EAX,EAX CALL 0x00119b30
/* 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 */ ggml_abort("/workspace/llm4binary/github/2025_star3/monkey531[P]llama/common/json.hpp",0x1491, "GGML_ASSERT(%s) failed","anchor.m_object != nullptr"); } 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; }
3,584
my_strtoll10_utf32
eloqsql/strings/ctype-ucs2.c
static longlong my_strtoll10_utf32(CHARSET_INFO *cs __attribute__((unused)), const char *nptr, char **endptr, int *error) { const char *s, *end, *start, *n_end, *true_end; uchar c; unsigned long i, j, k; ulonglong li; int negative; ulong cutoff, cutoff2, cutoff3; s= nptr; /* If fixed length string */ if (endptr) { /* Make sure string length is even */ end= s + ((*endptr - s) / 4) * 4; while (s < end && !s[0] && !s[1] && !s[2] && (s[3] == ' ' || s[3] == '\t')) s+= 4; if (s == end) goto no_conv; } else { /* We don't support null terminated strings in UCS2 */ goto no_conv; } /* Check for a sign. */ negative= 0; if (!s[0] && !s[1] && !s[2] && s[3] == '-') { *error= -1; /* Mark as negative number */ negative= 1; s+= 4; if (s == end) goto no_conv; cutoff= MAX_NEGATIVE_NUMBER / LFACTOR2; cutoff2= (MAX_NEGATIVE_NUMBER % LFACTOR2) / 100; cutoff3= MAX_NEGATIVE_NUMBER % 100; } else { *error= 0; if (!s[0] && !s[1] && !s[2] && s[3] == '+') { s+= 4; if (s == end) goto no_conv; } cutoff= ULONGLONG_MAX / LFACTOR2; cutoff2= ULONGLONG_MAX % LFACTOR2 / 100; cutoff3= ULONGLONG_MAX % 100; } /* Handle case where we have a lot of pre-zero */ if (!s[0] && !s[1] && !s[2] && s[3] == '0') { i= 0; do { s+= 4; if (s == end) goto end_i; /* Return 0 */ } while (!s[0] && !s[1] && !s[2] && s[3] == '0'); n_end= s + 4 * INIT_CNT; } else { /* Read first digit to check that it's a valid number */ if (s[0] || s[1] || s[2] || (c= (s[3]-'0')) > 9) goto no_conv; i= c; s+= 4; n_end= s + 4 * (INIT_CNT-1); } /* Handle first 9 digits and store them in i */ if (n_end > end) n_end= end; for (; s != n_end ; s+= 4) { if (s[0] || s[1] || s[2] || (c= (s[3] - '0')) > 9) goto end_i; i= i * 10 + c; } if (s == end) goto end_i; /* Handle next 9 digits and store them in j */ j= 0; start= s; /* Used to know how much to shift i */ n_end= true_end= s + 4 * INIT_CNT; if (n_end > end) n_end= end; do { if (s[0] || s[1] || s[2] || (c= (s[3] - '0')) > 9) goto end_i_and_j; j= j * 10 + c; s+= 4; } while (s != n_end); if (s == end) { if (s != true_end) goto end_i_and_j; goto end3; } if (s[0] || s[1] || s[2] || (c= (s[3] - '0')) > 9) goto end3; /* Handle the next 1 or 2 digits and store them in k */ k=c; s+= 4; if (s == end || s[0] || s[1] || s[2] || (c= (s[3]-'0')) > 9) goto end4; k= k * 10 + c; s+= 4; *endptr= (char*) s; /* number string should have ended here */ if (s != end && !s[0] && !s[1] && !s[2] && (c= (s[3] - '0')) <= 9) goto overflow; /* Check that we didn't get an overflow with the last digit */ if (i > cutoff || (i == cutoff && ((j > cutoff2 || j == cutoff2) && k > cutoff3))) goto overflow; li= i * LFACTOR2+ (ulonglong) j * 100 + k; return (longlong) li; overflow: /* *endptr is set here */ *error= MY_ERRNO_ERANGE; return negative ? LONGLONG_MIN : (longlong) ULONGLONG_MAX; end_i: *endptr= (char*) s; return (negative ? ((longlong) -(long) i) : (longlong) i); end_i_and_j: li= (ulonglong) i * lfactor[(size_t) (s-start) / 4] + j; *endptr= (char*) s; return (negative ? -((longlong) li) : (longlong) li); end3: li= (ulonglong) i*LFACTOR+ (ulonglong) j; *endptr= (char*) s; return (negative ? -((longlong) li) : (longlong) li); end4: li= (ulonglong) i*LFACTOR1+ (ulonglong) j * 10 + k; *endptr= (char*) s; if (negative) { if (li > MAX_NEGATIVE_NUMBER) goto overflow; return -((longlong) li); } return (longlong) li; no_conv: /* There was no number to convert. */ *error= MY_ERRNO_EDOM; *endptr= (char *) nptr; return 0; }
O3
c
my_strtoll10_utf32: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx testq %rdx, %rdx je 0x67c82 movq (%rdx), %rdi subq %rsi, %rdi leaq 0x3(%rdi), %rax testq %rdi, %rdi cmovnsq %rdi, %rax andq $-0x4, %rax addq %rsi, %rax movq %rsi, %r11 cmpq $0x4, %rdi jl 0x67b8c movq %rsi, %r11 cmpb $0x0, (%r11) jne 0x67b8c cmpb $0x0, 0x1(%r11) jne 0x67b8c cmpb $0x0, 0x2(%r11) jne 0x67b8c movzbl 0x3(%r11), %edi cmpl $0x20, %edi je 0x67b83 cmpl $0x9, %edi jne 0x67b8c addq $0x4, %r11 cmpq %rax, %r11 jb 0x67b60 cmpq %rax, %r11 je 0x67c82 cmpb $0x0, (%r11) jne 0x67bd9 cmpb $0x0, 0x1(%r11) jne 0x67bd9 cmpb $0x0, 0x2(%r11) jne 0x67bd9 cmpb $0x2d, 0x3(%r11) jne 0x67bd9 movl $0xffffffff, (%rcx) # imm = 0xFFFFFFFF addq $0x4, %r11 cmpq %rax, %r11 je 0x67c82 movl $0x8, %r8d movl $0x15f797ae, %r9d # imm = 0x15F797AE movl $0x57f5ff8, %r10d # imm = 0x57F5FF8 xorl %edi, %edi jmp 0x67c1c movl $0x0, (%rcx) cmpb $0x0, (%r11) jne 0x67c82 movl $0xf, %r8d movl $0x2bef2f5c, %r9d # imm = 0x2BEF2F5C movl $0xafebff0, %r10d # imm = 0xAFEBFF0 movb $0x1, %dil cmpb $0x0, 0x1(%r11) jne 0x67c1c cmpb $0x0, 0x2(%r11) jne 0x67c1c cmpb $0x2b, 0x3(%r11) jne 0x67c1c addq $0x4, %r11 cmpq %rax, %r11 je 0x67c82 cmpb $0x0, (%r11) jne 0x67c82 cmpb $0x0, 0x1(%r11) jne 0x67c82 cmpb $0x0, 0x2(%r11) jne 0x67c6f cmpb $0x30, 0x3(%r11) jne 0x67c6f addq $0x28, %r11 xorl %esi, %esi leaq -0x24(%r11), %rbx cmpq %rax, %rbx je 0x67e25 movq %r11, %r14 cmpb $0x0, (%rbx) jne 0x67c6b cmpb $0x0, -0x23(%r14) jne 0x67c6b cmpb $0x0, -0x22(%r14) jne 0x67c6b leaq 0x4(%r14), %r11 cmpb $0x30, -0x21(%r14) je 0x67c3d xorl %esi, %esi jmp 0x67ca6 cmpb $0x0, 0x2(%r11) jne 0x67c82 movb 0x3(%r11), %bl addb $-0x30, %bl cmpb $0x9, %bl jbe 0x67c98 movl $0x21, (%rcx) movq %rsi, (%rdx) xorl %eax, %eax popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq movzbl %bl, %esi leaq 0x4(%r11), %rbx addq $0x24, %r11 movq %r11, %r14 cmpq %rax, %r14 cmovaq %rax, %r14 cmpq %r14, %rbx je 0x67cf3 cmpb $0x0, (%rbx) jne 0x67e22 cmpb $0x0, 0x1(%rbx) jne 0x67e22 cmpb $0x0, 0x2(%rbx) jne 0x67e22 movb 0x3(%rbx), %r11b addb $-0x30, %r11b cmpb $0x9, %r11b ja 0x67e22 leaq (%rsi,%rsi,4), %rsi movzbl %r11b, %r11d leaq (%r11,%rsi,2), %rsi addq $0x4, %rbx jmp 0x67cad cmpq %rax, %rbx je 0x67e22 leaq 0x24(%rbx), %r12 cmpq %rax, %r12 cmovaq %rax, %r12 leaq 0x8(%rbx), %r14 movl $0x24, %r13d xorl %r11d, %r11d cmpb $0x0, -0x8(%r14) jne 0x67e2a cmpb $0x0, -0x7(%r14) jne 0x67e2a cmpb $0x0, -0x6(%r14) jne 0x67e2a movb -0x5(%r14), %r15b addb $-0x30, %r15b cmpb $0x9, %r15b ja 0x67e2a leaq (%r11,%r11,4), %r11 movzbl %r15b, %r15d leaq (%r15,%r11,2), %r11 leaq 0x4(%r14), %r15 addq $-0x4, %r14 addq $-0x4, %r13 cmpq %r12, %r14 movq %r15, %r14 jne 0x67d14 leaq -0x8(%r15), %r14 cmpq %rax, %r12 je 0x67e5c cmpb $0x0, (%r14) jne 0x67e61 cmpb $0x0, -0x7(%r15) jne 0x67e61 cmpb $0x0, -0x6(%r15) jne 0x67e61 movb -0x5(%r15), %bl addb $-0x30, %bl cmpb $0x9, %bl ja 0x67e61 movzbl %bl, %ebx leaq -0x4(%r15), %r12 cmpq %rax, %r12 je 0x67dd7 cmpb $0x0, -0x4(%r15) jne 0x67dd7 cmpb $0x0, -0x3(%r15) jne 0x67dd7 cmpb $0x0, -0x2(%r15) jne 0x67dd7 movb -0x1(%r15), %r14b addb $-0x30, %r14b cmpb $0x9, %r14b jbe 0x67e88 movabsq $0x2540be400, %rax # imm = 0x2540BE400 imulq %rax, %rsi leaq (%r11,%r11,4), %rax leaq (%rsi,%rax,2), %rax addq %rbx, %rax movq %r12, (%rdx) testb %dil, %dil jne 0x67c8d movabsq $-0x8000000000000000, %rdx # imm = 0x8000000000000000 cmpq %rdx, %rax jbe 0x67e80 movl $0x22, (%rcx) movzbl %dil, %eax negq %rax btsq $0x3f, %rax jmp 0x67c8d movq %rbx, %rax movq %rax, (%rdx) jmp 0x67e4a addq $-0x8, %r14 movq %r14, %rax subq %rbx, %rax andq $-0x4, %rax leaq 0x20c081(%rip), %rcx # 0x273ec0 imulq (%rcx,%rax,2), %rsi addq %r11, %rsi movq %r14, (%rdx) movq %rsi, %rax negq %rax testb %dil, %dil cmovneq %rsi, %rax jmp 0x67c8d testq %r13, %r13 jne 0x67e2e imulq $0x3b9aca00, %rsi, %rax # imm = 0x3B9ACA00 addq %rax, %r11 movq %r14, (%rdx) movq %r11, %rax negq %rax testb %dil, %dil cmovneq %r11, %rax jmp 0x67c8d negq %rax jmp 0x67c8d movq %r15, (%rdx) cmpq %rax, %r15 je 0x67eb2 cmpb $0x0, (%r15) jne 0x67eb2 cmpb $0x0, 0x1(%r15) jne 0x67eb2 cmpb $0x0, 0x2(%r15) jne 0x67eb2 movb 0x3(%r15), %al addb $-0x30, %al cmpb $0xa, %al jb 0x67e0b cmpq %r10, %rsi ja 0x67e0b leaq (%rbx,%rbx,4), %rax movzbl %r14b, %edx leaq (%rdx,%rax,2), %rax cmpq %r10, %rsi jne 0x67eda cmpq %r9, %r11 jb 0x67eda cmpl %r8d, %eax ja 0x67e0b movabsq $0x174876e800, %rcx # imm = 0x174876E800 imulq %rcx, %rsi imulq $0x64, %r11, %rcx addq %rax, %rsi addq %rcx, %rsi movq %rsi, %rax jmp 0x67c8d
my_strtoll10_utf32: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx test rdx, rdx jz loc_67C82 mov rdi, [rdx] sub rdi, rsi lea rax, [rdi+3] test rdi, rdi cmovns rax, rdi and rax, 0FFFFFFFFFFFFFFFCh add rax, rsi mov r11, rsi cmp rdi, 4 jl short loc_67B8C mov r11, rsi loc_67B60: cmp byte ptr [r11], 0 jnz short loc_67B8C cmp byte ptr [r11+1], 0 jnz short loc_67B8C cmp byte ptr [r11+2], 0 jnz short loc_67B8C movzx edi, byte ptr [r11+3] cmp edi, 20h ; ' ' jz short loc_67B83 cmp edi, 9 jnz short loc_67B8C loc_67B83: add r11, 4 cmp r11, rax jb short loc_67B60 loc_67B8C: cmp r11, rax jz loc_67C82 cmp byte ptr [r11], 0 jnz short loc_67BD9 cmp byte ptr [r11+1], 0 jnz short loc_67BD9 cmp byte ptr [r11+2], 0 jnz short loc_67BD9 cmp byte ptr [r11+3], 2Dh ; '-' jnz short loc_67BD9 mov dword ptr [rcx], 0FFFFFFFFh add r11, 4 cmp r11, rax jz loc_67C82 mov r8d, 8 mov r9d, 15F797AEh mov r10d, 57F5FF8h xor edi, edi jmp short loc_67C1C loc_67BD9: mov dword ptr [rcx], 0 cmp byte ptr [r11], 0 jnz loc_67C82 mov r8d, 0Fh mov r9d, 2BEF2F5Ch mov r10d, 0AFEBFF0h mov dil, 1 cmp byte ptr [r11+1], 0 jnz short loc_67C1C cmp byte ptr [r11+2], 0 jnz short loc_67C1C cmp byte ptr [r11+3], 2Bh ; '+' jnz short loc_67C1C add r11, 4 cmp r11, rax jz short loc_67C82 loc_67C1C: cmp byte ptr [r11], 0 jnz short loc_67C82 cmp byte ptr [r11+1], 0 jnz short loc_67C82 cmp byte ptr [r11+2], 0 jnz short loc_67C6F cmp byte ptr [r11+3], 30h ; '0' jnz short loc_67C6F add r11, 28h ; '(' xor esi, esi loc_67C3D: lea rbx, [r11-24h] cmp rbx, rax jz loc_67E25 mov r14, r11 cmp byte ptr [rbx], 0 jnz short loc_67C6B cmp byte ptr [r14-23h], 0 jnz short loc_67C6B cmp byte ptr [r14-22h], 0 jnz short loc_67C6B lea r11, [r14+4] cmp byte ptr [r14-21h], 30h ; '0' jz short loc_67C3D loc_67C6B: xor esi, esi jmp short loc_67CA6 loc_67C6F: cmp byte ptr [r11+2], 0 jnz short loc_67C82 mov bl, [r11+3] add bl, 0D0h cmp bl, 9 jbe short loc_67C98 loc_67C82: mov dword ptr [rcx], 21h ; '!' mov [rdx], rsi xor eax, eax loc_67C8D: pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn loc_67C98: movzx esi, bl lea rbx, [r11+4] add r11, 24h ; '$' mov r14, r11 loc_67CA6: cmp r14, rax cmova r14, rax loc_67CAD: cmp rbx, r14 jz short loc_67CF3 cmp byte ptr [rbx], 0 jnz loc_67E22 cmp byte ptr [rbx+1], 0 jnz loc_67E22 cmp byte ptr [rbx+2], 0 jnz loc_67E22 mov r11b, [rbx+3] add r11b, 0D0h cmp r11b, 9 ja loc_67E22 lea rsi, [rsi+rsi*4] movzx r11d, r11b lea rsi, [r11+rsi*2] add rbx, 4 jmp short loc_67CAD loc_67CF3: cmp rbx, rax jz loc_67E22 lea r12, [rbx+24h] cmp r12, rax cmova r12, rax lea r14, [rbx+8] mov r13d, 24h ; '$' xor r11d, r11d loc_67D14: cmp byte ptr [r14-8], 0 jnz loc_67E2A cmp byte ptr [r14-7], 0 jnz loc_67E2A cmp byte ptr [r14-6], 0 jnz loc_67E2A mov r15b, [r14-5] add r15b, 0D0h cmp r15b, 9 ja loc_67E2A lea r11, [r11+r11*4] movzx r15d, r15b lea r11, [r15+r11*2] lea r15, [r14+4] add r14, 0FFFFFFFFFFFFFFFCh add r13, 0FFFFFFFFFFFFFFFCh cmp r14, r12 mov r14, r15 jnz short loc_67D14 lea r14, [r15-8] cmp r12, rax jz loc_67E5C cmp byte ptr [r14], 0 jnz loc_67E61 cmp byte ptr [r15-7], 0 jnz loc_67E61 cmp byte ptr [r15-6], 0 jnz loc_67E61 mov bl, [r15-5] add bl, 0D0h cmp bl, 9 ja loc_67E61 movzx ebx, bl lea r12, [r15-4] cmp r12, rax jz short loc_67DD7 cmp byte ptr [r15-4], 0 jnz short loc_67DD7 cmp byte ptr [r15-3], 0 jnz short loc_67DD7 cmp byte ptr [r15-2], 0 jnz short loc_67DD7 mov r14b, [r15-1] add r14b, 0D0h cmp r14b, 9 jbe loc_67E88 loc_67DD7: mov rax, 2540BE400h imul rsi, rax lea rax, [r11+r11*4] lea rax, [rsi+rax*2] add rax, rbx mov [rdx], r12 test dil, dil jnz loc_67C8D mov rdx, 8000000000000000h cmp rax, rdx jbe short loc_67E80 loc_67E0B: mov dword ptr [rcx], 22h ; '"' movzx eax, dil neg rax bts rax, 3Fh ; '?' jmp loc_67C8D loc_67E22: mov rax, rbx loc_67E25: mov [rdx], rax jmp short loc_67E4A loc_67E2A: add r14, 0FFFFFFFFFFFFFFF8h loc_67E2E: mov rax, r14 sub rax, rbx and rax, 0FFFFFFFFFFFFFFFCh lea rcx, lfactor imul rsi, [rcx+rax*2] add rsi, r11 mov [rdx], r14 loc_67E4A: mov rax, rsi neg rax test dil, dil cmovnz rax, rsi jmp loc_67C8D loc_67E5C: test r13, r13 jnz short loc_67E2E loc_67E61: imul rax, rsi, 3B9ACA00h add r11, rax mov [rdx], r14 mov rax, r11 neg rax test dil, dil cmovnz rax, r11 jmp loc_67C8D loc_67E80: neg rax jmp loc_67C8D loc_67E88: mov [rdx], r15 cmp r15, rax jz short loc_67EB2 cmp byte ptr [r15], 0 jnz short loc_67EB2 cmp byte ptr [r15+1], 0 jnz short loc_67EB2 cmp byte ptr [r15+2], 0 jnz short loc_67EB2 mov al, [r15+3] add al, 0D0h cmp al, 0Ah jb loc_67E0B loc_67EB2: cmp rsi, r10 ja loc_67E0B lea rax, [rbx+rbx*4] movzx edx, r14b lea rax, [rdx+rax*2] cmp rsi, r10 jnz short loc_67EDA cmp r11, r9 jb short loc_67EDA cmp eax, r8d ja loc_67E0B loc_67EDA: mov rcx, 174876E800h imul rsi, rcx imul rcx, r11, 64h ; 'd' add rsi, rax add rsi, rcx mov rax, rsi jmp loc_67C8D
unsigned long long my_strtoll10_utf32(long long a1, _BYTE *a2, unsigned long long *a3, _DWORD *a4) { long long v4; // rdi long long v5; // rax unsigned long long v6; // rax _BYTE *v7; // r11 int v8; // edi unsigned int v9; // r8d unsigned long long v10; // r9 unsigned long long v11; // r10 unsigned __int8 v12; // di _BYTE *v13; // r11 unsigned long long v14; // rsi _BYTE *v15; // rbx _BYTE *v16; // r14 unsigned __int8 v17; // bl unsigned long long result; // rax unsigned __int8 v19; // r11 _BYTE *v20; // r12 _BYTE *v21; // r14 long long v22; // r13 unsigned long long v23; // r11 unsigned __int8 v24; // r15 _BYTE *v25; // r15 bool v26; // zf _BYTE *v27; // r14 unsigned __int8 v28; // bl unsigned __int8 v29; // r14 unsigned long long v30; // r11 long long v31; // rax if ( !a3 ) goto LABEL_37; v4 = *a3 - (_QWORD)a2; v5 = v4 + 3; if ( v4 >= 0 ) v5 = *a3 - (_QWORD)a2; v6 = (unsigned long long)&a2[v5 & 0xFFFFFFFFFFFFFFFCLL]; v7 = a2; if ( v4 >= 4 ) { v7 = a2; do { if ( *v7 ) break; if ( v7[1] ) break; if ( v7[2] ) break; v8 = (unsigned __int8)v7[3]; if ( v8 != 32 && v8 != 9 ) break; v7 += 4; } while ( (unsigned long long)v7 < v6 ); } if ( v7 == (_BYTE *)v6 ) goto LABEL_37; if ( *v7 || v7[1] || v7[2] || v7[3] != 45 ) { *a4 = 0; if ( *v7 ) goto LABEL_37; v9 = 15; v10 = 737095516LL; v11 = 184467440LL; v12 = 1; if ( !v7[1] && !v7[2] && v7[3] == 43 ) { v7 += 4; if ( v7 == (_BYTE *)v6 ) goto LABEL_37; } } else { *a4 = -1; v7 += 4; if ( v7 == (_BYTE *)v6 ) goto LABEL_37; v9 = 8; v10 = 368547758LL; v11 = 92233720LL; v12 = 0; } if ( *v7 || v7[1] ) goto LABEL_37; if ( !v7[2] && v7[3] == 48 ) { v13 = v7 + 40; v14 = 0LL; while ( 1 ) { v15 = v13 - 36; if ( v13 - 36 == (_BYTE *)v6 ) goto LABEL_71; v16 = v13; if ( !*v15 && !*(v13 - 35) && !*(v13 - 34) ) { v13 += 4; if ( *(v16 - 33) == 48 ) continue; } v14 = 0LL; goto LABEL_40; } } if ( v7[2] || (v17 = v7[3] - 48, v17 > 9u) ) { LABEL_37: *a4 = 33; *a3 = (unsigned long long)a2; return 0LL; } v14 = v17; v15 = v7 + 4; v16 = v7 + 36; LABEL_40: if ( (unsigned long long)v16 > v6 ) v16 = (_BYTE *)v6; while ( v15 != v16 ) { if ( *v15 ) goto LABEL_70; if ( v15[1] ) goto LABEL_70; if ( v15[2] ) goto LABEL_70; v19 = v15[3] - 48; if ( v19 > 9u ) goto LABEL_70; v14 = v19 + 10 * v14; v15 += 4; } if ( v15 != (_BYTE *)v6 ) { v20 = v15 + 36; if ( (unsigned long long)(v15 + 36) > v6 ) v20 = (_BYTE *)v6; v21 = v15 + 8; v22 = 36LL; v23 = 0LL; while ( !*(v21 - 8) ) { if ( *(v21 - 7) ) break; if ( *(v21 - 6) ) break; v24 = *(v21 - 5) - 48; if ( v24 > 9u ) break; v23 = v24 + 10 * v23; v25 = v21 + 4; v22 -= 4LL; v26 = v21 - 4 == v20; v21 += 4; if ( v26 ) { v27 = v25 - 8; if ( v20 != (_BYTE *)v6 ) { if ( !*v27 && !*(v25 - 7) && !*(v25 - 6) ) { v28 = *(v25 - 5) - 48; if ( v28 <= 9u ) { if ( v25 - 4 == (_BYTE *)v6 || *(v25 - 4) || *(v25 - 3) || *(v25 - 2) || (v29 = *(v25 - 1) - 48, v29 > 9u) ) { result = v28 + 10000000000LL * v14 + 10 * v23; *a3 = (unsigned long long)(v25 - 4); if ( v12 ) return result; if ( result > 0x8000000000000000LL ) goto LABEL_69; return -(long long)result; } else { *a3 = (unsigned long long)v25; if ( v25 != (_BYTE *)v6 && !*v25 && !v25[1] && !v25[2] && (unsigned __int8)(v25[3] - 48) < 0xAu || v14 > v11 || (v31 = v29 + 10LL * v28, v14 == v11) && v23 >= v10 && (unsigned int)v31 > v9 ) { LABEL_69: *a4 = 34; return -(long long)v12 | 0x8000000000000000LL; } return 100 * v23 + v31 + 100000000000LL * v14; } } } LABEL_78: v30 = 1000000000 * v14 + v23; *a3 = (unsigned long long)v27; result = -(long long)v30; if ( v12 ) return v30; return result; } if ( !v22 ) goto LABEL_78; LABEL_73: v14 = v23 + *(_QWORD *)((char *)&lfactor + 2 * ((v27 - v15) & 0xFFFFFFFFFFFFFFFCLL)) * v14; *a3 = (unsigned long long)v27; goto LABEL_74; } } v27 = v21 - 8; goto LABEL_73; } LABEL_70: v6 = (unsigned long long)v15; LABEL_71: *a3 = v6; LABEL_74: result = -(long long)v14; if ( v12 ) return v14; return result; }
my_strtoll10_utf32: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX TEST RDX,RDX JZ 0x00167c82 MOV RDI,qword ptr [RDX] SUB RDI,RSI LEA RAX,[RDI + 0x3] TEST RDI,RDI CMOVNS RAX,RDI AND RAX,-0x4 ADD RAX,RSI MOV R11,RSI CMP RDI,0x4 JL 0x00167b8c MOV R11,RSI LAB_00167b60: CMP byte ptr [R11],0x0 JNZ 0x00167b8c CMP byte ptr [R11 + 0x1],0x0 JNZ 0x00167b8c CMP byte ptr [R11 + 0x2],0x0 JNZ 0x00167b8c MOVZX EDI,byte ptr [R11 + 0x3] CMP EDI,0x20 JZ 0x00167b83 CMP EDI,0x9 JNZ 0x00167b8c LAB_00167b83: ADD R11,0x4 CMP R11,RAX JC 0x00167b60 LAB_00167b8c: CMP R11,RAX JZ 0x00167c82 CMP byte ptr [R11],0x0 JNZ 0x00167bd9 CMP byte ptr [R11 + 0x1],0x0 JNZ 0x00167bd9 CMP byte ptr [R11 + 0x2],0x0 JNZ 0x00167bd9 CMP byte ptr [R11 + 0x3],0x2d JNZ 0x00167bd9 MOV dword ptr [RCX],0xffffffff ADD R11,0x4 CMP R11,RAX JZ 0x00167c82 MOV R8D,0x8 MOV R9D,0x15f797ae MOV R10D,0x57f5ff8 XOR EDI,EDI JMP 0x00167c1c LAB_00167bd9: MOV dword ptr [RCX],0x0 CMP byte ptr [R11],0x0 JNZ 0x00167c82 MOV R8D,0xf MOV R9D,0x2bef2f5c MOV R10D,0xafebff0 MOV DIL,0x1 CMP byte ptr [R11 + 0x1],0x0 JNZ 0x00167c1c CMP byte ptr [R11 + 0x2],0x0 JNZ 0x00167c1c CMP byte ptr [R11 + 0x3],0x2b JNZ 0x00167c1c ADD R11,0x4 CMP R11,RAX JZ 0x00167c82 LAB_00167c1c: CMP byte ptr [R11],0x0 JNZ 0x00167c82 CMP byte ptr [R11 + 0x1],0x0 JNZ 0x00167c82 CMP byte ptr [R11 + 0x2],0x0 JNZ 0x00167c6f CMP byte ptr [R11 + 0x3],0x30 JNZ 0x00167c6f ADD R11,0x28 XOR ESI,ESI LAB_00167c3d: LEA RBX,[R11 + -0x24] CMP RBX,RAX JZ 0x00167e25 MOV R14,R11 CMP byte ptr [RBX],0x0 JNZ 0x00167c6b CMP byte ptr [R14 + -0x23],0x0 JNZ 0x00167c6b CMP byte ptr [R14 + -0x22],0x0 JNZ 0x00167c6b LEA R11,[R14 + 0x4] CMP byte ptr [R14 + -0x21],0x30 JZ 0x00167c3d LAB_00167c6b: XOR ESI,ESI JMP 0x00167ca6 LAB_00167c6f: CMP byte ptr [R11 + 0x2],0x0 JNZ 0x00167c82 MOV BL,byte ptr [R11 + 0x3] ADD BL,0xd0 CMP BL,0x9 JBE 0x00167c98 LAB_00167c82: MOV dword ptr [RCX],0x21 MOV qword ptr [RDX],RSI XOR EAX,EAX LAB_00167c8d: POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET LAB_00167c98: MOVZX ESI,BL LEA RBX,[R11 + 0x4] ADD R11,0x24 MOV R14,R11 LAB_00167ca6: CMP R14,RAX CMOVA R14,RAX LAB_00167cad: CMP RBX,R14 JZ 0x00167cf3 CMP byte ptr [RBX],0x0 JNZ 0x00167e22 CMP byte ptr [RBX + 0x1],0x0 JNZ 0x00167e22 CMP byte ptr [RBX + 0x2],0x0 JNZ 0x00167e22 MOV R11B,byte ptr [RBX + 0x3] ADD R11B,0xd0 CMP R11B,0x9 JA 0x00167e22 LEA RSI,[RSI + RSI*0x4] MOVZX R11D,R11B LEA RSI,[R11 + RSI*0x2] ADD RBX,0x4 JMP 0x00167cad LAB_00167cf3: CMP RBX,RAX JZ 0x00167e22 LEA R12,[RBX + 0x24] CMP R12,RAX CMOVA R12,RAX LEA R14,[RBX + 0x8] MOV R13D,0x24 XOR R11D,R11D LAB_00167d14: CMP byte ptr [R14 + -0x8],0x0 JNZ 0x00167e2a CMP byte ptr [R14 + -0x7],0x0 JNZ 0x00167e2a CMP byte ptr [R14 + -0x6],0x0 JNZ 0x00167e2a MOV R15B,byte ptr [R14 + -0x5] ADD R15B,0xd0 CMP R15B,0x9 JA 0x00167e2a LEA R11,[R11 + R11*0x4] MOVZX R15D,R15B LEA R11,[R15 + R11*0x2] LEA R15,[R14 + 0x4] ADD R14,-0x4 ADD R13,-0x4 CMP R14,R12 MOV R14,R15 JNZ 0x00167d14 LEA R14,[R15 + -0x8] CMP R12,RAX JZ 0x00167e5c CMP byte ptr [R14],0x0 JNZ 0x00167e61 CMP byte ptr [R15 + -0x7],0x0 JNZ 0x00167e61 CMP byte ptr [R15 + -0x6],0x0 JNZ 0x00167e61 MOV BL,byte ptr [R15 + -0x5] ADD BL,0xd0 CMP BL,0x9 JA 0x00167e61 MOVZX EBX,BL LEA R12,[R15 + -0x4] CMP R12,RAX JZ 0x00167dd7 CMP byte ptr [R15 + -0x4],0x0 JNZ 0x00167dd7 CMP byte ptr [R15 + -0x3],0x0 JNZ 0x00167dd7 CMP byte ptr [R15 + -0x2],0x0 JNZ 0x00167dd7 MOV R14B,byte ptr [R15 + -0x1] ADD R14B,0xd0 CMP R14B,0x9 JBE 0x00167e88 LAB_00167dd7: MOV RAX,0x2540be400 IMUL RSI,RAX LEA RAX,[R11 + R11*0x4] LEA RAX,[RSI + RAX*0x2] ADD RAX,RBX MOV qword ptr [RDX],R12 TEST DIL,DIL JNZ 0x00167c8d MOV RDX,-0x8000000000000000 CMP RAX,RDX JBE 0x00167e80 LAB_00167e0b: MOV dword ptr [RCX],0x22 MOVZX EAX,DIL NEG RAX BTS RAX,0x3f JMP 0x00167c8d LAB_00167e22: MOV RAX,RBX LAB_00167e25: MOV qword ptr [RDX],RAX JMP 0x00167e4a LAB_00167e2a: ADD R14,-0x8 LAB_00167e2e: MOV RAX,R14 SUB RAX,RBX AND RAX,-0x4 LEA RCX,[0x373ec0] IMUL RSI,qword ptr [RCX + RAX*0x2] ADD RSI,R11 MOV qword ptr [RDX],R14 LAB_00167e4a: MOV RAX,RSI NEG RAX TEST DIL,DIL CMOVNZ RAX,RSI JMP 0x00167c8d LAB_00167e5c: TEST R13,R13 JNZ 0x00167e2e LAB_00167e61: IMUL RAX,RSI,0x3b9aca00 ADD R11,RAX MOV qword ptr [RDX],R14 MOV RAX,R11 NEG RAX TEST DIL,DIL CMOVNZ RAX,R11 JMP 0x00167c8d LAB_00167e80: NEG RAX JMP 0x00167c8d LAB_00167e88: MOV qword ptr [RDX],R15 CMP R15,RAX JZ 0x00167eb2 CMP byte ptr [R15],0x0 JNZ 0x00167eb2 CMP byte ptr [R15 + 0x1],0x0 JNZ 0x00167eb2 CMP byte ptr [R15 + 0x2],0x0 JNZ 0x00167eb2 MOV AL,byte ptr [R15 + 0x3] ADD AL,0xd0 CMP AL,0xa JC 0x00167e0b LAB_00167eb2: CMP RSI,R10 JA 0x00167e0b LEA RAX,[RBX + RBX*0x4] MOVZX EDX,R14B LEA RAX,[RDX + RAX*0x2] CMP RSI,R10 JNZ 0x00167eda CMP R11,R9 JC 0x00167eda CMP EAX,R8D JA 0x00167e0b LAB_00167eda: MOV RCX,0x174876e800 IMUL RSI,RCX IMUL RCX,R11,0x64 ADD RSI,RAX ADD RSI,RCX MOV RAX,RSI JMP 0x00167c8d
ulong my_strtoll10_utf32(int8 param_1,char *param_2,long *param_3,int4 *param_4) { char *pcVar1; char cVar2; char *pcVar3; byte bVar4; char *pcVar5; ulong uVar6; byte bVar7; ulong uVar8; uint uVar9; ulong uVar10; char *pcVar11; ulong uVar12; long lVar13; char *pcVar14; char *pcVar15; if (param_3 != (long *)0x0) { uVar8 = *param_3 - (long)param_2; uVar10 = uVar8 + 3; if (-1 < (long)uVar8) { uVar10 = uVar8; } pcVar3 = param_2 + (uVar10 & 0xfffffffffffffffc); pcVar11 = param_2; if (3 < (long)uVar8) { do { if ((((*pcVar11 != '\0') || (pcVar11[1] != '\0')) || (pcVar11[2] != '\0')) || ((pcVar11[3] != ' ' && (pcVar11[3] != '\t')))) break; pcVar11 = pcVar11 + 4; } while (pcVar11 < pcVar3); } if (pcVar11 != pcVar3) { if (((*pcVar11 == '\0') && (pcVar11[1] == '\0')) && ((pcVar11[2] == '\0' && (pcVar11[3] == '-')))) { *param_4 = 0xffffffff; pcVar11 = pcVar11 + 4; if (pcVar11 == pcVar3) goto LAB_00167c82; uVar9 = 8; uVar10 = 0x15f797ae; uVar8 = 0x57f5ff8; bVar7 = 0; } else { *param_4 = 0; if (*pcVar11 != '\0') goto LAB_00167c82; uVar9 = 0xf; uVar10 = 0x2bef2f5c; uVar8 = 0xafebff0; bVar7 = 1; if ((((pcVar11[1] == '\0') && (pcVar11[2] == '\0')) && (pcVar11[3] == '+')) && (pcVar11 = pcVar11 + 4, pcVar11 == pcVar3)) goto LAB_00167c82; } if ((*pcVar11 == '\0') && (pcVar11[1] == '\0')) { if ((pcVar11[2] == '\0') && (pcVar11[3] == '0')) { uVar6 = 0; pcVar5 = pcVar11 + 0x28; do { pcVar11 = pcVar5; pcVar1 = pcVar11 + -0x24; pcVar5 = pcVar3; if (pcVar1 == pcVar3) goto LAB_00167e25; } while ((((*pcVar1 == '\0') && (pcVar11[-0x23] == '\0')) && (pcVar11[-0x22] == '\0')) && (pcVar5 = pcVar11 + 4, pcVar11[-0x21] == '0')); uVar6 = 0; pcVar5 = pcVar1; } else { if ((pcVar11[2] != '\0') || (9 < (byte)(pcVar11[3] - 0x30U))) goto LAB_00167c82; uVar6 = (ulong)(byte)(pcVar11[3] - 0x30U); pcVar5 = pcVar11 + 4; pcVar11 = pcVar11 + 0x24; } if (pcVar3 < pcVar11) { pcVar11 = pcVar3; } for (; pcVar5 != pcVar11; pcVar5 = pcVar5 + 4) { if (((*pcVar5 != '\0') || (pcVar5[1] != '\0')) || ((pcVar5[2] != '\0' || (9 < (byte)(pcVar5[3] - 0x30U))))) goto LAB_00167e25; uVar6 = (ulong)(byte)(pcVar5[3] - 0x30U) + uVar6 * 10; } if (pcVar5 != pcVar3) { pcVar11 = pcVar5 + 0x24; if (pcVar3 < pcVar5 + 0x24) { pcVar11 = pcVar3; } lVar13 = 0x24; uVar12 = 0; pcVar1 = pcVar5 + 8; do { pcVar14 = pcVar1; if (((pcVar14[-8] != '\0') || (pcVar14[-7] != '\0')) || ((pcVar14[-6] != '\0' || (9 < (byte)(pcVar14[-5] - 0x30U))))) { pcVar15 = pcVar14 + -8; goto LAB_00167e2e; } uVar12 = (ulong)(byte)(pcVar14[-5] - 0x30U) + uVar12 * 10; pcVar1 = pcVar14 + 4; lVar13 = lVar13 + -4; } while (pcVar14 + -4 != pcVar11); pcVar15 = pcVar14 + -4; if (pcVar11 == pcVar3) { if (lVar13 != 0) { LAB_00167e2e: uVar6 = uVar6 * *(long *)((long)&lfactor + ((long)pcVar15 - (long)pcVar5 & 0xfffffffffffffffcU) * 2) + uVar12; *param_3 = (long)pcVar15; goto LAB_00167e4a; } } else if ((((*pcVar15 == '\0') && (pcVar14[-3] == '\0')) && (pcVar14[-2] == '\0')) && (bVar4 = pcVar14[-1] - 0x30, bVar4 < 10)) { if (((pcVar14 == pcVar3) || (*pcVar14 != '\0')) || ((pcVar14[1] != '\0' || ((pcVar14[2] != '\0' || (cVar2 = pcVar14[3], 9 < (byte)(cVar2 - 0x30U))))))) { uVar10 = uVar6 * 10000000000 + uVar12 * 10 + (ulong)bVar4; *param_3 = (long)pcVar14; if (bVar7 != 0) { return uVar10; } if (uVar10 < 0x8000000000000001) { return -uVar10; } } else { *param_3 = (long)pcVar1; if ((((((pcVar1 == pcVar3) || (*pcVar1 != '\0')) || (pcVar14[5] != '\0')) || ((pcVar14[6] != '\0' || (9 < (byte)(pcVar14[7] - 0x30U))))) && (uVar6 <= uVar8)) && (((lVar13 = (ulong)(byte)(cVar2 - 0x30U) + (ulong)bVar4 * 10, uVar6 != uVar8 || (uVar12 < uVar10)) || ((uint)lVar13 <= uVar9)))) { return uVar6 * 100000000000 + lVar13 + uVar12 * 100; } } *param_4 = 0x22; return -(ulong)bVar7 | 0x8000000000000000; } uVar12 = uVar12 + uVar6 * 1000000000; *param_3 = (long)pcVar15; if (bVar7 == 0) { return -uVar12; } return uVar12; } LAB_00167e25: *param_3 = (long)pcVar5; LAB_00167e4a: if (bVar7 == 0) { return -uVar6; } return uVar6; } } } LAB_00167c82: *param_4 = 0x21; *param_3 = (long)param_2; return 0; }
3,585
virtual thunk to nglog::NullStream::~NullStream()
ng-log[P]ng-log/src/ng-log/logging.h
class NGLOG_EXPORT NullStream : public LogMessage::LogStream { public: // Initialize the LogStream so the messages can be written somewhere // (they'll never be actually displayed). This will be needed if a // NullStream& is implicitly converted to LogStream&, in which case // the overloaded NullStream::operator<< will not be invoked. NullStream(); NullStream(const char* /*file*/, int /*line*/, const internal::CheckOpString& /*result*/); NullStream& stream(); private: // A very short buffer for messages (which we discard anyway). This // will be needed if NullStream& converted to LogStream& (e.g. as a // result of a conditional expression). char message_buffer_[3]; }
O1
c
virtual thunk to nglog::NullStream::~NullStream(): pushq %r14 pushq %rbx pushq %rax movq (%rdi), %rax movq -0x18(%rax), %rax leaq (%rdi,%rax), %rbx leaq 0x1d320(%rip), %rcx # 0x2e540 leaq 0x18(%rcx), %rdx leaq (%rdi,%rax), %r14 addq $0x60, %r14 movq %rdx, -0x60(%r14) addq $0x40, %rcx movq %rcx, (%r14) movq 0x1dd02(%rip), %rcx # 0x2ef40 addq $0x10, %rcx movq %rcx, -0x58(%r14) addq %rax, %rdi addq $0x40, %rdi callq 0x77a0 movq %r14, %rdi callq 0x7170 movl $0x168, %esi # imm = 0x168 movq %rbx, %rdi addq $0x8, %rsp popq %rbx popq %r14 jmp 0x7530
_ZTv0_n24_N5nglog10NullStreamD0Ev: push r14 push rbx push rax mov rax, [rdi] mov rax, [rax-18h] lea rbx, [rdi+rax] lea rcx, _ZTCN5nglog10NullStreamE0_NS_10LogMessage9LogStreamE; `construction vtable for'nglog::LogMessage::LogStream-in-nglog::NullStream lea rdx, [rcx+18h] lea r14, [rdi+rax] add r14, 60h ; '`' mov [r14-60h], rdx add rcx, 40h ; '@' mov [r14], rcx mov rcx, cs:_ZTVSt15basic_streambufIcSt11char_traitsIcEE_ptr add rcx, 10h mov [r14-58h], rcx add rdi, rax add rdi, 40h ; '@'; this call __ZNSt6localeD1Ev; std::locale::~locale() mov rdi, r14; this call __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base() mov esi, 168h; unsigned __int64 mov rdi, rbx; void * add rsp, 8 pop rbx pop r14 jmp __ZdlPvm; operator delete(void *,ulong)
void `virtual thunk to'nglog::NullStream::~NullStream(nglog::NullStream *this) { _QWORD *v1; // rbx v1 = (_QWORD *)((char *)this + *(_QWORD *)(*(_QWORD *)this - 24LL)); *v1 = (char *)&`construction vtable for'nglog::LogMessage::LogStream-in-nglog::NullStream + 24; v1[12] = (char *)&`construction vtable for'nglog::LogMessage::LogStream-in-nglog::NullStream + 64; v1[1] = (char *)&`vtable for'std::streambuf + 16; std::locale::~locale((std::locale *)(v1 + 8)); std::ios_base::~ios_base((std::ios_base *)(v1 + 12)); operator delete(v1, 0x168uLL); }
~NullStream: PUSH R14 PUSH RBX PUSH RAX MOV RAX,qword ptr [RDI] MOV RAX,qword ptr [RAX + -0x18] LEA RBX,[RDI + RAX*0x1] LEA RCX,[0x12e540] LEA RDX,[RCX + 0x18] LEA R14,[RDI + RAX*0x1] ADD R14,0x60 MOV qword ptr [R14 + -0x60],RDX ADD RCX,0x40 MOV qword ptr [R14],RCX MOV RCX,qword ptr [0x0012ef40] ADD RCX,0x10 MOV qword ptr [R14 + -0x58],RCX ADD RDI,RAX ADD RDI,0x40 CALL 0x001077a0 MOV RDI,R14 CALL 0x00107170 MOV ESI,0x168 MOV RDI,RBX ADD RSP,0x8 POP RBX POP R14 JMP 0x00107530
/* virtual thunk to nglog::NullStream::~NullStream() */ void __thiscall nglog::NullStream::~NullStream(NullStream *this) { NullStream *pNVar1; long lVar2; lVar2 = *(long *)(*(long *)this + -0x18); pNVar1 = this + lVar2; *(int8 *)pNVar1 = 0x12e558; *(int8 *)(pNVar1 + 0x60) = 0x12e580; *(int **)(pNVar1 + 8) = PTR_vtable_0012ef40 + 0x10; std::locale::~locale((locale *)(this + lVar2 + 0x40)); std::ios_base::~ios_base((ios_base *)(pNVar1 + 0x60)); operator_delete(this + lVar2,0x168); return; }
3,586
virtual thunk to nglog::NullStream::~NullStream()
ng-log[P]ng-log/src/ng-log/logging.h
class NGLOG_EXPORT NullStream : public LogMessage::LogStream { public: // Initialize the LogStream so the messages can be written somewhere // (they'll never be actually displayed). This will be needed if a // NullStream& is implicitly converted to LogStream&, in which case // the overloaded NullStream::operator<< will not be invoked. NullStream(); NullStream(const char* /*file*/, int /*line*/, const internal::CheckOpString& /*result*/); NullStream& stream(); private: // A very short buffer for messages (which we discard anyway). This // will be needed if NullStream& converted to LogStream& (e.g. as a // result of a conditional expression). char message_buffer_[3]; }
O3
c
virtual thunk to nglog::NullStream::~NullStream(): pushq %rbx movq (%rdi), %rax movq -0x18(%rax), %rax leaq 0x1d633(%rip), %rcx # 0x2e580 leaq 0x18(%rcx), %rdx leaq (%rdi,%rax), %rbx addq $0x60, %rbx movq %rdx, -0x60(%rbx) addq $0x40, %rcx movq %rcx, (%rbx) movq 0x1dfd5(%rip), %rcx # 0x2ef40 addq $0x10, %rcx movq %rcx, -0x58(%rbx) addq %rax, %rdi addq $0x40, %rdi callq 0x77a0 movq %rbx, %rdi popq %rbx jmp 0x7170
_ZTv0_n24_N5nglog10NullStreamD1Ev: push rbx mov rax, [rdi] mov rax, [rax-18h] lea rcx, _ZTCN5nglog10NullStreamE0_NS_10LogMessage9LogStreamE; `construction vtable for'nglog::LogMessage::LogStream-in-nglog::NullStream lea rdx, [rcx+18h] lea rbx, [rdi+rax] add rbx, 60h ; '`' mov [rbx-60h], rdx add rcx, 40h ; '@' mov [rbx], rcx mov rcx, cs:_ZTVSt15basic_streambufIcSt11char_traitsIcEE_ptr add rcx, 10h mov [rbx-58h], rcx add rdi, rax add rdi, 40h ; '@'; this call __ZNSt6localeD1Ev; std::locale::~locale() mov rdi, rbx; this pop rbx jmp __ZNSt8ios_baseD2Ev; std::ios_base::~ios_base()
void `virtual thunk to'nglog::NullStream::~NullStream(nglog::NullStream *this) { long long v1; // rax std::ios_base *v2; // rbx v1 = *(_QWORD *)(*(_QWORD *)this - 24LL); v2 = (nglog::NullStream *)((char *)this + v1 + 96); *((_QWORD *)v2 - 12) = (char *)&`construction vtable for'nglog::LogMessage::LogStream-in-nglog::NullStream + 24; *(_QWORD *)v2 = (char *)&`construction vtable for'nglog::LogMessage::LogStream-in-nglog::NullStream + 64; *((_QWORD *)v2 - 11) = (char *)&`vtable for'std::streambuf + 16; std::locale::~locale((nglog::NullStream *)((char *)this + v1 + 64)); std::ios_base::~ios_base(v2); }
~NullStream: PUSH RBX MOV RAX,qword ptr [RDI] MOV RAX,qword ptr [RAX + -0x18] LEA RCX,[0x12e580] LEA RDX,[RCX + 0x18] LEA RBX,[RDI + RAX*0x1] ADD RBX,0x60 MOV qword ptr [RBX + -0x60],RDX ADD RCX,0x40 MOV qword ptr [RBX],RCX MOV RCX,qword ptr [0x0012ef40] ADD RCX,0x10 MOV qword ptr [RBX + -0x58],RCX ADD RDI,RAX ADD RDI,0x40 CALL 0x001077a0 MOV RDI,RBX POP RBX JMP 0x00107170
/* virtual thunk to nglog::NullStream::~NullStream() */ void __thiscall nglog::NullStream::~NullStream(NullStream *this) { NullStream *pNVar1; long lVar2; lVar2 = *(long *)(*(long *)this + -0x18); pNVar1 = this + lVar2; *(int8 *)pNVar1 = 0x12e598; *(int8 *)(pNVar1 + 0x60) = 0x12e5c0; *(int **)(pNVar1 + 8) = PTR_vtable_0012ef40 + 0x10; std::locale::~locale((locale *)(this + lVar2 + 0x40)); std::ios_base::~ios_base((ios_base *)(pNVar1 + 0x60)); return; }
3,587
coro::mutex::lock_operation::await_suspend(std::__n4861::coroutine_handle<void>)
AlayaLite/build_O3/_deps/libcoro-src/src/mutex.cpp
auto mutex::lock_operation::await_suspend(std::coroutine_handle<> awaiting_coroutine) noexcept -> bool { m_awaiting_coroutine = awaiting_coroutine; void* current = m_mutex.m_state.load(std::memory_order::acquire); void* new_value; const void* unlocked_value = m_mutex.unlocked_value(); do { if (current == unlocked_value) { // If the current value is 'unlocked' then attempt to lock it. new_value = nullptr; } else { // If the current value is a waiting lock operation, or nullptr, set our next to that // lock op and attempt to set ourself as the head of the waiter list. m_next = static_cast<lock_operation*>(current); new_value = static_cast<void*>(this); } } while (!m_mutex.m_state.compare_exchange_weak(current, new_value, std::memory_order::acq_rel)); // Don't suspend if the state went from unlocked -> locked with zero waiters. if (current == unlocked_value) { std::atomic_thread_fence(std::memory_order::acquire); m_awaiting_coroutine = nullptr; // nothing to await later since this doesn't suspend return false; } return true; }
O3
cpp
coro::mutex::lock_operation::await_suspend(std::__n4861::coroutine_handle<void>): movq %rsi, 0x8(%rdi) movq (%rdi), %rax movq (%rax), %rcx movq (%rdi), %rdx cmpq %rcx, %rdx je 0xc87b9 movq %rcx, 0x10(%rdi) movq %rdi, %rsi jmp 0xc87bb xorl %esi, %esi movq (%rdi), %r8 movq %rcx, %rax lock cmpxchgq %rsi, (%r8) je 0xc87cd movq %rax, %rcx jmp 0xc87ab cmpq %rcx, %rdx jne 0xc87da movq $0x0, 0x8(%rdi) cmpq %rcx, %rdx setne %al retq nopl (%rax)
_ZN4coro5mutex14lock_operation13await_suspendENSt7__n486116coroutine_handleIvEE: mov [rdi+8], rsi mov rax, [rdi] mov rcx, [rax] mov rdx, [rdi] loc_C87AB: cmp rdx, rcx jz short loc_C87B9 mov [rdi+10h], rcx mov rsi, rdi jmp short loc_C87BB loc_C87B9: xor esi, esi loc_C87BB: mov r8, [rdi] mov rax, rcx lock cmpxchg [r8], rsi jz short loc_C87CD mov rcx, rax jmp short loc_C87AB loc_C87CD: cmp rdx, rcx jnz short loc_C87DA mov qword ptr [rdi+8], 0 loc_C87DA: cmp rdx, rcx setnz al retn
bool coro::mutex::lock_operation::await_suspend(signed long long a1, long long a2) { signed long long v2; // rcx signed long long *v3; // rdx signed long long v4; // rsi signed long long v5; // rax *(_QWORD *)(a1 + 8) = a2; v2 = **(_QWORD **)a1; v3 = *(signed long long **)a1; while ( 1 ) { if ( v3 == (signed long long *)v2 ) { v4 = 0LL; } else { *(_QWORD *)(a1 + 16) = v2; v4 = a1; } v5 = _InterlockedCompareExchange64(*(volatile signed long long **)a1, v4, v2); if ( v2 == v5 ) break; v2 = v5; } if ( v3 == (signed long long *)v2 ) *(_QWORD *)(a1 + 8) = 0LL; return v3 != (signed long long *)v2; }
await_suspend: MOV qword ptr [RDI + 0x8],RSI MOV RAX,qword ptr [RDI] MOV RCX,qword ptr [RAX] MOV RDX,qword ptr [RDI] LAB_001c87ab: CMP RDX,RCX JZ 0x001c87b9 MOV qword ptr [RDI + 0x10],RCX MOV RSI,RDI JMP 0x001c87bb LAB_001c87b9: XOR ESI,ESI LAB_001c87bb: MOV R8,qword ptr [RDI] MOV RAX,RCX CMPXCHG.LOCK qword ptr [R8],RSI JZ 0x001c87cd MOV RCX,RAX JMP 0x001c87ab LAB_001c87cd: CMP RDX,RCX JNZ 0x001c87da MOV qword ptr [RDI + 0x8],0x0 LAB_001c87da: CMP RDX,RCX SETNZ AL RET
/* coro::mutex::lock_operation::await_suspend(std::__n4861::coroutine_handle<void>) */ int8 __thiscall coro::mutex::lock_operation::await_suspend(lock_operation *this,int8 param_2) { long lVar1; long lVar2; long lVar3; lock_operation *plVar4; bool bVar5; *(int8 *)(this + 8) = param_2; lVar1 = *(long *)this; lVar2 = **(long **)this; do { lVar3 = lVar2; if (lVar1 == lVar3) { plVar4 = (lock_operation *)0x0; } else { *(long *)(this + 0x10) = lVar3; plVar4 = this; } LOCK(); lVar2 = **(long **)this; bVar5 = lVar3 == lVar2; if (bVar5) { **(long **)this = (long)plVar4; lVar2 = lVar3; } UNLOCK(); } while (!bVar5); if (lVar1 == lVar3) { *(int8 *)(this + 8) = 0; } return CONCAT71((int7)((ulong)lVar2 >> 8),lVar1 != lVar3); }
3,588
getopt_double_limit_value
eloqsql/mysys/my_getopt.c
double getopt_double_limit_value(double num, const struct my_option *optp, my_bool *fix) { my_bool adjusted= FALSE; double old= num; double min, max; DBUG_ENTER("getopt_double_limit_value"); max= getopt_ulonglong2double(optp->max_value); min= getopt_ulonglong2double(optp->min_value); if (max && num > max) { num= max; adjusted= TRUE; } if (num < min) { num= min; adjusted= TRUE; } if (fix) *fix= adjusted; else if (adjusted) my_getopt_error_reporter(WARNING_LEVEL, "option '%s': value %g adjusted to %g", optp->name, old, num); DBUG_RETURN(num); }
O0
c
getopt_double_limit_value: pushq %rbp movq %rsp, %rbp subq $0x40, %rsp movsd %xmm0, -0x8(%rbp) movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movb $0x0, -0x19(%rbp) movsd -0x8(%rbp), %xmm0 movsd %xmm0, -0x28(%rbp) movq -0x10(%rbp), %rax movq 0x50(%rax), %rdi callq 0xf14b0 movsd %xmm0, -0x38(%rbp) movq -0x10(%rbp), %rax movq 0x48(%rax), %rdi callq 0xf14b0 movsd %xmm0, -0x30(%rbp) movsd -0x38(%rbp), %xmm0 xorps %xmm1, %xmm1 ucomisd %xmm1, %xmm0 jne 0xf37b9 jp 0xf37b9 jmp 0xf37d3 movsd -0x8(%rbp), %xmm0 ucomisd -0x38(%rbp), %xmm0 jbe 0xf37d3 movsd -0x38(%rbp), %xmm0 movsd %xmm0, -0x8(%rbp) movb $0x1, -0x19(%rbp) movsd -0x8(%rbp), %xmm1 movsd -0x30(%rbp), %xmm0 ucomisd %xmm1, %xmm0 jbe 0xf37f1 movsd -0x30(%rbp), %xmm0 movsd %xmm0, -0x8(%rbp) movb $0x1, -0x19(%rbp) cmpq $0x0, -0x18(%rbp) je 0xf3803 movb -0x19(%rbp), %cl movq -0x18(%rbp), %rax movb %cl, (%rax) jmp 0xf3836 cmpb $0x0, -0x19(%rbp) je 0xf3834 leaq 0x1d7190(%rip), %rax # 0x2ca9a0 movq (%rax), %rcx movq -0x10(%rbp), %rax movq (%rax), %rdx movsd -0x28(%rbp), %xmm0 movsd -0x8(%rbp), %xmm1 movl $0x1, %edi leaq 0x695e7(%rip), %rsi # 0x15ce17 movb $0x2, %al callq *%rcx jmp 0xf3836 jmp 0xf3838 movsd -0x8(%rbp), %xmm0 movsd %xmm0, -0x40(%rbp) movsd -0x40(%rbp), %xmm0 addq $0x40, %rsp popq %rbp retq nopl (%rax)
getopt_double_limit_value: push rbp mov rbp, rsp sub rsp, 40h movsd [rbp+var_8], xmm0 mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_19], 0 movsd xmm0, [rbp+var_8] movsd [rbp+var_28], xmm0 mov rax, [rbp+var_10] mov rdi, [rax+50h] call getopt_ulonglong2double movsd [rbp+var_38], xmm0 mov rax, [rbp+var_10] mov rdi, [rax+48h] call getopt_ulonglong2double movsd [rbp+var_30], xmm0 movsd xmm0, [rbp+var_38] xorps xmm1, xmm1 ucomisd xmm0, xmm1 jnz short loc_F37B9 jp short loc_F37B9 jmp short loc_F37D3 loc_F37B9: movsd xmm0, [rbp+var_8] ucomisd xmm0, [rbp+var_38] jbe short loc_F37D3 movsd xmm0, [rbp+var_38] movsd [rbp+var_8], xmm0 mov [rbp+var_19], 1 loc_F37D3: movsd xmm1, [rbp+var_8] movsd xmm0, [rbp+var_30] ucomisd xmm0, xmm1 jbe short loc_F37F1 movsd xmm0, [rbp+var_30] movsd [rbp+var_8], xmm0 mov [rbp+var_19], 1 loc_F37F1: cmp [rbp+var_18], 0 jz short loc_F3803 mov cl, [rbp+var_19] mov rax, [rbp+var_18] mov [rax], cl jmp short loc_F3836 loc_F3803: cmp [rbp+var_19], 0 jz short loc_F3834 lea rax, my_getopt_error_reporter mov rcx, [rax] mov rax, [rbp+var_10] mov rdx, [rax] movsd xmm0, [rbp+var_28] movsd xmm1, [rbp+var_8] mov edi, 1 lea rsi, aOptionSValueGA; "option '%s': value %g adjusted to %g" mov al, 2 call rcx loc_F3834: jmp short $+2 loc_F3836: jmp short $+2 loc_F3838: movsd xmm0, [rbp+var_8] movsd [rbp+var_40], xmm0 movsd xmm0, [rbp+var_40] add rsp, 40h pop rbp retn
double getopt_double_limit_value(_QWORD *a1, char *a2, double a3) { double v4; // [rsp+8h] [rbp-38h] double v5; // [rsp+10h] [rbp-30h] char v7; // [rsp+27h] [rbp-19h] double v8; // [rsp+38h] [rbp-8h] v8 = a3; v7 = 0; v4 = getopt_ulonglong2double(a1[10]); v5 = getopt_ulonglong2double(a1[9]); if ( v4 != 0.0 && v8 > v4 ) { v8 = v4; v7 = 1; } if ( v5 > v8 ) { v8 = v5; v7 = 1; } if ( a2 ) { *a2 = v7; } else if ( v7 ) { my_getopt_error_reporter(1, (long long)"option '%s': value %g adjusted to %g", *a1, a3, v8); } return v8; }
getopt_double_limit_value: PUSH RBP MOV RBP,RSP SUB RSP,0x40 MOVSD qword ptr [RBP + -0x8],XMM0 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV byte ptr [RBP + -0x19],0x0 MOVSD XMM0,qword ptr [RBP + -0x8] MOVSD qword ptr [RBP + -0x28],XMM0 MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x50] CALL 0x001f14b0 MOVSD qword ptr [RBP + -0x38],XMM0 MOV RAX,qword ptr [RBP + -0x10] MOV RDI,qword ptr [RAX + 0x48] CALL 0x001f14b0 MOVSD qword ptr [RBP + -0x30],XMM0 MOVSD XMM0,qword ptr [RBP + -0x38] XORPS XMM1,XMM1 UCOMISD XMM0,XMM1 JNZ 0x001f37b9 JP 0x001f37b9 JMP 0x001f37d3 LAB_001f37b9: MOVSD XMM0,qword ptr [RBP + -0x8] UCOMISD XMM0,qword ptr [RBP + -0x38] JBE 0x001f37d3 MOVSD XMM0,qword ptr [RBP + -0x38] MOVSD qword ptr [RBP + -0x8],XMM0 MOV byte ptr [RBP + -0x19],0x1 LAB_001f37d3: MOVSD XMM1,qword ptr [RBP + -0x8] MOVSD XMM0,qword ptr [RBP + -0x30] UCOMISD XMM0,XMM1 JBE 0x001f37f1 MOVSD XMM0,qword ptr [RBP + -0x30] MOVSD qword ptr [RBP + -0x8],XMM0 MOV byte ptr [RBP + -0x19],0x1 LAB_001f37f1: CMP qword ptr [RBP + -0x18],0x0 JZ 0x001f3803 MOV CL,byte ptr [RBP + -0x19] MOV RAX,qword ptr [RBP + -0x18] MOV byte ptr [RAX],CL JMP 0x001f3836 LAB_001f3803: CMP byte ptr [RBP + -0x19],0x0 JZ 0x001f3834 LEA RAX,[0x3ca9a0] MOV RCX,qword ptr [RAX] MOV RAX,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RAX] MOVSD XMM0,qword ptr [RBP + -0x28] MOVSD XMM1,qword ptr [RBP + -0x8] MOV EDI,0x1 LEA RSI,[0x25ce17] MOV AL,0x2 CALL RCX LAB_001f3834: JMP 0x001f3836 LAB_001f3836: JMP 0x001f3838 LAB_001f3838: MOVSD XMM0,qword ptr [RBP + -0x8] MOVSD qword ptr [RBP + -0x40],XMM0 MOVSD XMM0,qword ptr [RBP + -0x40] ADD RSP,0x40 POP RBP RET
double getopt_double_limit_value(double param_1,int8 *param_2,char *param_3) { double dVar1; double dVar2; char local_21; double local_10; local_21 = '\0'; dVar1 = (double)getopt_ulonglong2double(param_2[10]); dVar2 = (double)getopt_ulonglong2double(param_2[9]); if (((dVar1 != 0.0) || (local_10 = param_1, NAN(dVar1))) && (local_10 = param_1, dVar1 < param_1)) { local_21 = '\x01'; local_10 = dVar1; } if (local_10 < dVar2) { local_21 = '\x01'; local_10 = dVar2; } if (param_3 == (char *)0x0) { if (local_21 != '\0') { (*(code *)my_getopt_error_reporter) (param_1,local_10,1,"option \'%s\': value %g adjusted to %g",*param_2); } } else { *param_3 = local_21; } return local_10; }
3,589
google::protobuf::io::CodedOutputStream::WriteStringWithSizeToArray(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned char*)
aimrt_mujoco_sim/_deps/protobuf-src/src/google/protobuf/io/coded_stream.cc
uint8_t* EpsCopyOutputStream::WriteStringOutline(uint32_t num, const std::string& s, uint8_t* ptr) { ptr = EnsureSpace(ptr); uint32_t size = s.size(); ptr = WriteLengthDelim(num, size, ptr); return WriteRaw(s.data(), size, ptr); }
O3
cpp
google::protobuf::io::CodedOutputStream::WriteStringWithSizeToArray(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, unsigned char*): pushq %r14 pushq %rbx pushq %rax movq 0x8(%rdi), %rcx movb %cl, (%rsi) cmpl $0x7f, %ecx ja 0xfb6b7 incq %rsi movq %rsi, %rbx jmp 0xfb6ef movl %ecx, %eax orb $-0x80, %al movb %al, (%rsi) movl %ecx, %eax shrl $0x7, %eax movb %al, 0x1(%rsi) leaq 0x2(%rsi), %rbx cmpl $0x4000, %ecx # imm = 0x4000 jb 0xfb6ef movb 0x1(%rsi), %dl movl %eax, %ecx orb $-0x80, %dl movb %dl, -0x1(%rbx) shrl $0x7, %ecx movb %cl, (%rbx) incq %rbx movl %ecx, %edx cmpl $0x3fff, %eax # imm = 0x3FFF movl %ecx, %eax ja 0xfb6d6 movq (%rdi), %rsi movslq 0x8(%rdi), %r14 movq %rbx, %rdi movq %r14, %rdx callq 0x1f400 addq %r14, %rbx movq %rbx, %rax addq $0x8, %rsp popq %rbx popq %r14 retq nop
_ZN6google8protobuf2io17CodedOutputStream26WriteStringWithSizeToArrayERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPh: push r14 push rbx push rax mov rcx, [rdi+8] mov [rsi], cl cmp ecx, 7Fh ja short loc_FB6B7 inc rsi mov rbx, rsi jmp short loc_FB6EF loc_FB6B7: mov eax, ecx or al, 80h mov [rsi], al mov eax, ecx shr eax, 7 mov [rsi+1], al lea rbx, [rsi+2] cmp ecx, 4000h jb short loc_FB6EF mov dl, [rsi+1] mov ecx, eax loc_FB6D6: or dl, 80h mov [rbx-1], dl shr ecx, 7 mov [rbx], cl inc rbx mov edx, ecx cmp eax, 3FFFh mov eax, ecx ja short loc_FB6D6 loc_FB6EF: mov rsi, [rdi] movsxd r14, dword ptr [rdi+8] mov rdi, rbx mov rdx, r14 call _memcpy add rbx, r14 mov rax, rbx add rsp, 8 pop rbx pop r14 retn
_BYTE * google::protobuf::io::CodedOutputStream::WriteStringWithSizeToArray(_QWORD *a1, _BYTE *a2) { long long v2; // rcx _BYTE *v3; // rbx unsigned int v4; // eax char v5; // dl unsigned int v6; // ecx bool v7; // cc long long v8; // r14 v2 = a1[1]; *a2 = v2; if ( (unsigned int)v2 > 0x7F ) { *a2 = v2 | 0x80; v4 = (unsigned int)v2 >> 7; a2[1] = (unsigned int)v2 >> 7; v3 = a2 + 2; if ( (unsigned int)v2 >= 0x4000 ) { v5 = a2[1]; v6 = (unsigned int)v2 >> 7; do { *(v3 - 1) = v5 | 0x80; v6 >>= 7; *v3++ = v6; v5 = v6; v7 = v4 <= 0x3FFF; v4 = v6; } while ( !v7 ); } } else { v3 = a2 + 1; } v8 = *((int *)a1 + 2); memcpy(v3, *a1, v8); return &v3[v8]; }
WriteStringWithSizeToArray: PUSH R14 PUSH RBX PUSH RAX MOV RCX,qword ptr [RDI + 0x8] MOV byte ptr [RSI],CL CMP ECX,0x7f JA 0x001fb6b7 INC RSI MOV RBX,RSI JMP 0x001fb6ef LAB_001fb6b7: MOV EAX,ECX OR AL,0x80 MOV byte ptr [RSI],AL MOV EAX,ECX SHR EAX,0x7 MOV byte ptr [RSI + 0x1],AL LEA RBX,[RSI + 0x2] CMP ECX,0x4000 JC 0x001fb6ef MOV DL,byte ptr [RSI + 0x1] MOV ECX,EAX LAB_001fb6d6: OR DL,0x80 MOV byte ptr [RBX + -0x1],DL SHR ECX,0x7 MOV byte ptr [RBX],CL INC RBX MOV EDX,ECX CMP EAX,0x3fff MOV EAX,ECX JA 0x001fb6d6 LAB_001fb6ef: MOV RSI,qword ptr [RDI] MOVSXD R14,dword ptr [RDI + 0x8] MOV RDI,RBX MOV RDX,R14 CALL 0x0011f400 ADD RBX,R14 MOV RAX,RBX ADD RSP,0x8 POP RBX POP R14 RET
/* google::protobuf::io::CodedOutputStream::WriteStringWithSizeToArray(std::__cxx11::string const&, unsigned char*) */ uchar * google::protobuf::io::CodedOutputStream::WriteStringWithSizeToArray (string *param_1,uchar *param_2) { int iVar1; uint uVar2; ulong uVar3; ulong uVar4; uchar *__dest; uVar4 = *(ulong *)(param_1 + 8); *param_2 = (byte)uVar4; if ((uint)uVar4 < 0x80) { __dest = param_2 + 1; } else { *param_2 = (byte)uVar4 | 0x80; uVar3 = uVar4 >> 7 & 0x1ffffff; param_2[1] = (uchar)uVar3; __dest = param_2 + 2; if (0x3fff < (uint)uVar4) { uVar4 = (ulong)param_2[1]; do { __dest[-1] = (byte)uVar4 | 0x80; uVar4 = uVar3 >> 7; *__dest = (uchar)uVar4; __dest = __dest + 1; uVar2 = (uint)uVar3; uVar3 = uVar4; } while (0x3fff < uVar2); } } iVar1 = *(int *)(param_1 + 8); memcpy(__dest,*(void **)param_1,(long)iVar1); return __dest + iVar1; }
3,590
CLI::App::_parse_single(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>&, bool&)
MikePodsytnik[P]TCRtrie/build_O0/_deps/cli11-src/include/CLI/impl/App_inl.hpp
CLI11_INLINE bool App::_parse_single(std::vector<std::string> &args, bool &positional_only) { bool retval = true; detail::Classifier classifier = positional_only ? detail::Classifier::NONE : _recognize(args.back()); switch(classifier) { case detail::Classifier::POSITIONAL_MARK: args.pop_back(); positional_only = true; if((!_has_remaining_positionals()) && (parent_ != nullptr)) { retval = false; } else { _move_to_missing(classifier, "--"); } break; case detail::Classifier::SUBCOMMAND_TERMINATOR: // treat this like a positional mark if in the parent app args.pop_back(); retval = false; break; case detail::Classifier::SUBCOMMAND: retval = _parse_subcommand(args); break; case detail::Classifier::LONG: case detail::Classifier::SHORT: case detail::Classifier::WINDOWS_STYLE: // If already parsed a subcommand, don't accept options_ _parse_arg(args, classifier); break; case detail::Classifier::NONE: // Probably a positional or something for a parent (sub)command retval = _parse_positional(args, false); if(retval && positionals_at_end_) { positional_only = true; } break; // LCOV_EXCL_START default: throw HorribleError("unrecognized classifier (you should not see this!)"); // LCOV_EXCL_STOP } return retval; }
O0
cpp
CLI::App::_parse_single(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>&, bool&): pushq %rbp movq %rsp, %rbp subq $0xc0, %rsp movq %rdi, -0x8(%rbp) movq %rsi, -0x10(%rbp) movq %rdx, -0x18(%rbp) movq -0x8(%rbp), %rax movq %rax, -0x88(%rbp) movb $0x1, -0x19(%rbp) movq -0x18(%rbp), %rax testb $0x1, (%rax) je 0x34679 xorl %eax, %eax movl %eax, -0x8c(%rbp) jmp 0x3469c movq -0x10(%rbp), %rdi callq 0x18780 movq -0x88(%rbp), %rdi movq %rax, %rsi movl $0x1, %edx callq 0x34f60 movl %eax, -0x8c(%rbp) movl -0x8c(%rbp), %eax movl %eax, -0x20(%rbp) movl -0x20(%rbp), %eax movq %rax, -0x98(%rbp) subq $0x6, %rax ja 0x3481b movq -0x98(%rbp), %rax leaq 0x3aaf9(%rip), %rcx # 0x6f1c0 movslq (%rcx,%rax,4), %rax addq %rcx, %rax jmpq *%rax movq -0x10(%rbp), %rdi callq 0x352d0 movq -0x88(%rbp), %rdi movq -0x18(%rbp), %rax movb $0x1, (%rax) callq 0x35300 testb $0x1, %al jne 0x3470a movq -0x88(%rbp), %rax cmpq $0x0, 0x2c8(%rax) je 0x3470a movb $0x0, -0x19(%rbp) jmp 0x34799 movl -0x20(%rbp), %eax movl %eax, -0xa4(%rbp) leaq -0x41(%rbp), %rdi movq %rdi, -0xa0(%rbp) callq 0x9a80 movq -0xa0(%rbp), %rdx leaq 0x3afaf(%rip), %rsi # 0x6f6e0 leaq -0x40(%rbp), %rdi callq 0xbb20 jmp 0x3473c movl -0xa4(%rbp), %esi movq -0x88(%rbp), %rdi leaq -0x40(%rbp), %rdx callq 0x353c0 jmp 0x34754 leaq -0x40(%rbp), %rdi callq 0x9b90 leaq -0x41(%rbp), %rdi callq 0x9690 jmp 0x34799 movq %rax, %rcx movl %edx, %eax movq %rcx, -0x50(%rbp) movl %eax, -0x54(%rbp) jmp 0x3478b movq %rax, %rcx movl %edx, %eax movq %rcx, -0x50(%rbp) movl %eax, -0x54(%rbp) leaq -0x40(%rbp), %rdi callq 0x9b90 leaq -0x41(%rbp), %rdi callq 0x9690 jmp 0x348db jmp 0x348cd movq -0x10(%rbp), %rdi callq 0x352d0 movb $0x0, -0x19(%rbp) jmp 0x348cd movq -0x88(%rbp), %rdi movq -0x10(%rbp), %rsi callq 0x354e0 andb $0x1, %al movb %al, -0x19(%rbp) jmp 0x348cd movq -0x88(%rbp), %rdi movq -0x10(%rbp), %rsi movl -0x20(%rbp), %edx callq 0x35700 jmp 0x348cd movq -0x88(%rbp), %rdi movq -0x10(%rbp), %rsi xorl %edx, %edx callq 0x36eb0 andb $0x1, %al movb %al, -0x19(%rbp) testb $0x1, -0x19(%rbp) je 0x34816 movq -0x88(%rbp), %rax testb $0x1, 0x29c(%rax) je 0x34816 movq -0x18(%rbp), %rax movb $0x1, (%rax) jmp 0x348cd movb $0x1, -0x7a(%rbp) movl $0x38, %edi callq 0x92d0 movq %rax, -0xb8(%rbp) leaq -0x79(%rbp), %rdi movq %rdi, -0xb0(%rbp) callq 0x9a80 movq -0xb0(%rbp), %rdx leaq 0x3b2b0(%rip), %rsi # 0x6fafe leaq -0x78(%rbp), %rdi callq 0xbb20 jmp 0x34859 movq -0xb8(%rbp), %rdi leaq -0x78(%rbp), %rsi callq 0x37b10 jmp 0x3486b movq -0xb8(%rbp), %rdi movb $0x0, -0x7a(%rbp) leaq 0x6cd13(%rip), %rsi # 0xa1590 leaq 0x336c(%rip), %rdx # 0x37bf0 callq 0x9a30 jmp 0x348e4 movq %rax, %rcx movl %edx, %eax movq %rcx, -0x50(%rbp) movl %eax, -0x54(%rbp) jmp 0x348ae movq %rax, %rcx movl %edx, %eax movq %rcx, -0x50(%rbp) movl %eax, -0x54(%rbp) leaq -0x78(%rbp), %rdi callq 0x9b90 leaq -0x79(%rbp), %rdi callq 0x9690 testb $0x1, -0x7a(%rbp) jne 0x348bf jmp 0x348cb movq -0xb8(%rbp), %rdi callq 0x9470 jmp 0x348db movb -0x19(%rbp), %al andb $0x1, %al addq $0xc0, %rsp popq %rbp retq movq -0x50(%rbp), %rdi callq 0x9a70 nopw %cs:(%rax,%rax) nop
_ZN3CLI3App13_parse_singleERSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EERb: push rbp mov rbp, rsp sub rsp, 0C0h mov [rbp+var_8], rdi mov [rbp+var_10], rsi mov [rbp+var_18], rdx mov rax, [rbp+var_8] mov [rbp+var_88], rax mov [rbp+var_19], 1 mov rax, [rbp+var_18] test byte ptr [rax], 1 jz short loc_34679 xor eax, eax mov [rbp+var_8C], eax jmp short loc_3469C loc_34679: mov rdi, [rbp+var_10] call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE4backEv; std::vector<std::string>::back(void) mov rdi, [rbp+var_88] mov rsi, rax mov edx, 1 call _ZNK3CLI3App10_recognizeERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEb; CLI::App::_recognize(std::string const&,bool) mov [rbp+var_8C], eax loc_3469C: mov eax, [rbp+var_8C] mov [rbp+var_20], eax mov eax, [rbp+var_20] mov [rbp+var_98], rax sub rax, 6; switch 7 cases ja def_346CE; jumptable 00000000000346CE default case mov rax, [rbp+var_98] lea rcx, jpt_346CE movsxd rax, ds:(jpt_346CE - 6F1C0h)[rcx+rax*4] add rax, rcx jmp rax; switch jump loc_346D0: mov rdi, [rbp+var_10]; jumptable 00000000000346CE case 1 call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE8pop_backEv; std::vector<std::string>::pop_back(void) mov rdi, [rbp+var_88]; this mov rax, [rbp+var_18] mov byte ptr [rax], 1 call _ZNK3CLI3App26_has_remaining_positionalsEv; CLI::App::_has_remaining_positionals(void) test al, 1 jnz short loc_3470A mov rax, [rbp+var_88] cmp qword ptr [rax+2C8h], 0 jz short loc_3470A mov [rbp+var_19], 0 jmp loc_34799 loc_3470A: mov eax, [rbp+var_20] mov [rbp+var_A4], eax lea rdi, [rbp+var_41] mov [rbp+var_A0], rdi call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void) mov rdx, [rbp+var_A0] lea rsi, asc_6F6E0; "--" lea rdi, [rbp+var_40] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) jmp short $+2 loc_3473C: mov esi, [rbp+var_A4] mov rdi, [rbp+var_88] lea rdx, [rbp+var_40] call _ZN3CLI3App16_move_to_missingENS_6detail10ClassifierERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; CLI::App::_move_to_missing(CLI::detail::Classifier,std::string const&) jmp short $+2 loc_34754: lea rdi, [rbp+var_40]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() lea rdi, [rbp+var_41] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() jmp short loc_34799 mov rcx, rax mov eax, edx mov [rbp+var_50], rcx mov [rbp+var_54], eax jmp short loc_3478B mov rcx, rax mov eax, edx mov [rbp+var_50], rcx mov [rbp+var_54], eax lea rdi, [rbp+var_40]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_3478B: lea rdi, [rbp+var_41] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() jmp loc_348DB loc_34799: jmp loc_348CD loc_3479E: mov rdi, [rbp+var_10]; jumptable 00000000000346CE case 6 call _ZNSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE8pop_backEv; std::vector<std::string>::pop_back(void) mov [rbp+var_19], 0 jmp loc_348CD loc_347B0: mov rdi, [rbp+var_88]; jumptable 00000000000346CE case 5 mov rsi, [rbp+var_10] call _ZN3CLI3App17_parse_subcommandERSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EE; CLI::App::_parse_subcommand(std::vector<std::string> &) and al, 1 mov [rbp+var_19], al jmp loc_348CD loc_347CA: mov rdi, [rbp+var_88]; jumptable 00000000000346CE cases 2-4 mov rsi, [rbp+var_10] mov edx, [rbp+var_20] call _ZN3CLI3App10_parse_argERSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EENS_6detail10ClassifierE; CLI::App::_parse_arg(std::vector<std::string> &,CLI::detail::Classifier) jmp loc_348CD loc_347E2: mov rdi, [rbp+var_88]; jumptable 00000000000346CE case 0 mov rsi, [rbp+var_10] xor edx, edx call _ZN3CLI3App17_parse_positionalERSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS7_EEb; CLI::App::_parse_positional(std::vector<std::string> &,bool) and al, 1 mov [rbp+var_19], al test [rbp+var_19], 1 jz short loc_34816 mov rax, [rbp+var_88] test byte ptr [rax+29Ch], 1 jz short loc_34816 mov rax, [rbp+var_18] mov byte ptr [rax], 1 loc_34816: jmp loc_348CD def_346CE: mov [rbp+var_7A], 1; jumptable 00000000000346CE default case mov edi, 38h ; '8'; thrown_size call ___cxa_allocate_exception mov [rbp+var_B8], rax lea rdi, [rbp+var_79] mov [rbp+var_B0], rdi call __ZNSaIcEC1Ev; std::allocator<char>::allocator(void) mov rdx, [rbp+var_B0] lea rsi, aUnrecognizedCl; "unrecognized classifier (you should not"... lea rdi, [rbp+var_78] call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_; std::string::basic_string<std::allocator<char>>(char const*,std::allocator<char> const&) jmp short $+2 loc_34859: mov rdi, [rbp+var_B8] lea rsi, [rbp+var_78] call _ZN3CLI13HorribleErrorC2ENSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE; CLI::HorribleError::HorribleError(std::string) jmp short $+2 loc_3486B: mov rdi, [rbp+var_B8]; void * mov [rbp+var_7A], 0 lea rsi, _ZTIN3CLI13HorribleErrorE; lptinfo lea rdx, _ZN3CLI13HorribleErrorD2Ev; void (*)(void *) call ___cxa_throw jmp short loc_348E4 mov rcx, rax mov eax, edx mov [rbp+var_50], rcx mov [rbp+var_54], eax jmp short loc_348AE mov rcx, rax mov eax, edx mov [rbp+var_50], rcx mov [rbp+var_54], eax lea rdi, [rbp+var_78]; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev; std::string::~string() loc_348AE: lea rdi, [rbp+var_79] call __ZNSaIcED1Ev; std::allocator<char>::~allocator() test [rbp+var_7A], 1 jnz short loc_348BF jmp short loc_348CB loc_348BF: mov rdi, [rbp+var_B8]; void * call ___cxa_free_exception loc_348CB: jmp short loc_348DB loc_348CD: mov al, [rbp+var_19] and al, 1 add rsp, 0C0h pop rbp retn loc_348DB: mov rdi, [rbp+var_50] call __Unwind_Resume loc_348E4: nop word ptr [rax+rax+00000000h] xchg ax, ax
char CLI::App::_parse_single(long long a1, long long a2, _BYTE *a3) { long long v3; // rdx long long v4; // rdx void *exception; // [rsp+8h] [rbp-B8h] unsigned int v7; // [rsp+1Ch] [rbp-A4h] unsigned int v8; // [rsp+34h] [rbp-8Ch] char v9; // [rsp+47h] [rbp-79h] BYREF _BYTE v10[36]; // [rsp+48h] [rbp-78h] BYREF char v11; // [rsp+7Fh] [rbp-41h] BYREF _BYTE v12[32]; // [rsp+80h] [rbp-40h] BYREF unsigned int v13; // [rsp+A0h] [rbp-20h] char v14; // [rsp+A7h] [rbp-19h] _BYTE *v15; // [rsp+A8h] [rbp-18h] long long v16; // [rsp+B0h] [rbp-10h] long long v17; // [rsp+B8h] [rbp-8h] v17 = a1; v16 = a2; v15 = a3; v14 = 1; if ( (*a3 & 1) != 0 ) { v8 = 0; } else { a2 = std::vector<std::string>::back(v16); v8 = CLI::App::_recognize(a1, a2, 1LL); } v13 = v8; switch ( v8 ) { case 0u: v14 = CLI::App::_parse_positional(a1, v16, 0LL) & 1; if ( v14 && (*(_BYTE *)(a1 + 668) & 1) != 0 ) *v15 = 1; break; case 1u: std::vector<std::string>::pop_back(v16); *v15 = 1; if ( (CLI::App::_has_remaining_positionals((CLI::App *)a1) & 1) != 0 || !*(_QWORD *)(a1 + 712) ) { v7 = v13; std::allocator<char>::allocator(&v11, a2, v3); std::string::basic_string<std::allocator<char>>((long long)v12, (long long)"--", (long long)&v11); CLI::App::_move_to_missing(a1, v7, v12); std::string::~string(v12); std::allocator<char>::~allocator(&v11); } else { v14 = 0; } break; case 2u: case 3u: case 4u: CLI::App::_parse_arg(a1, v16, v13); break; case 5u: v14 = CLI::App::_parse_subcommand(a1, v16) & 1; break; case 6u: std::vector<std::string>::pop_back(v16); v14 = 0; break; default: exception = __cxa_allocate_exception(0x38uLL); std::allocator<char>::allocator(&v9, a2, v4); std::string::basic_string<std::allocator<char>>( (long long)v10, (long long)"unrecognized classifier (you should not see this!)", (long long)&v9); CLI::HorribleError::HorribleError(exception, v10); __cxa_throw(exception, (struct type_info *)&`typeinfo for'CLI::HorribleError, CLI::HorribleError::~HorribleError); } return v14 & 1; }
_parse_single: PUSH RBP MOV RBP,RSP SUB RSP,0xc0 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 qword ptr [RBP + -0x88],RAX MOV byte ptr [RBP + -0x19],0x1 MOV RAX,qword ptr [RBP + -0x18] TEST byte ptr [RAX],0x1 JZ 0x00134679 XOR EAX,EAX MOV dword ptr [RBP + -0x8c],EAX JMP 0x0013469c LAB_00134679: MOV RDI,qword ptr [RBP + -0x10] CALL 0x00118780 MOV RDI,qword ptr [RBP + -0x88] MOV RSI,RAX MOV EDX,0x1 CALL 0x00134f60 MOV dword ptr [RBP + -0x8c],EAX LAB_0013469c: MOV EAX,dword ptr [RBP + -0x8c] MOV dword ptr [RBP + -0x20],EAX MOV EAX,dword ptr [RBP + -0x20] MOV qword ptr [RBP + -0x98],RAX SUB RAX,0x6 JA 0x0013481b MOV RAX,qword ptr [RBP + -0x98] LEA RCX,[0x16f1c0] MOVSXD RAX,dword ptr [RCX + RAX*0x4] ADD RAX,RCX switchD: JMP RAX caseD_1: MOV RDI,qword ptr [RBP + -0x10] CALL 0x001352d0 MOV RDI,qword ptr [RBP + -0x88] MOV RAX,qword ptr [RBP + -0x18] MOV byte ptr [RAX],0x1 CALL 0x00135300 TEST AL,0x1 JNZ 0x0013470a MOV RAX,qword ptr [RBP + -0x88] CMP qword ptr [RAX + 0x2c8],0x0 JZ 0x0013470a MOV byte ptr [RBP + -0x19],0x0 JMP 0x00134799 LAB_0013470a: MOV EAX,dword ptr [RBP + -0x20] MOV dword ptr [RBP + -0xa4],EAX LEA RDI,[RBP + -0x41] MOV qword ptr [RBP + -0xa0],RDI CALL 0x00109a80 MOV RDX,qword ptr [RBP + -0xa0] LAB_0013472a: LEA RSI,[0x16f6e0] LEA RDI,[RBP + -0x40] CALL 0x0010bb20 JMP 0x0013473c LAB_0013473c: MOV ESI,dword ptr [RBP + -0xa4] MOV RDI,qword ptr [RBP + -0x88] LEA RDX,[RBP + -0x40] CALL 0x001353c0 LAB_00134752: JMP 0x00134754 LAB_00134754: LEA RDI,[RBP + -0x40] CALL 0x00109b90 LEA RDI,[RBP + -0x41] CALL 0x00109690 JMP 0x00134799 LAB_00134799: JMP 0x001348cd caseD_6: MOV RDI,qword ptr [RBP + -0x10] CALL 0x001352d0 MOV byte ptr [RBP + -0x19],0x0 JMP 0x001348cd caseD_5: MOV RDI,qword ptr [RBP + -0x88] MOV RSI,qword ptr [RBP + -0x10] CALL 0x001354e0 AND AL,0x1 MOV byte ptr [RBP + -0x19],AL JMP 0x001348cd caseD_2: MOV RDI,qword ptr [RBP + -0x88] MOV RSI,qword ptr [RBP + -0x10] MOV EDX,dword ptr [RBP + -0x20] CALL 0x00135700 JMP 0x001348cd caseD_0: MOV RDI,qword ptr [RBP + -0x88] MOV RSI,qword ptr [RBP + -0x10] XOR EDX,EDX CALL 0x00136eb0 AND AL,0x1 MOV byte ptr [RBP + -0x19],AL TEST byte ptr [RBP + -0x19],0x1 JZ 0x00134816 MOV RAX,qword ptr [RBP + -0x88] TEST byte ptr [RAX + 0x29c],0x1 JZ 0x00134816 MOV RAX,qword ptr [RBP + -0x18] MOV byte ptr [RAX],0x1 LAB_00134816: JMP 0x001348cd default: MOV byte ptr [RBP + -0x7a],0x1 MOV EDI,0x38 CALL 0x001092d0 MOV qword ptr [RBP + -0xb8],RAX LEA RDI,[RBP + -0x79] MOV qword ptr [RBP + -0xb0],RDI CALL 0x00109a80 MOV RDX,qword ptr [RBP + -0xb0] LAB_00134847: LEA RSI,[0x16fafe] LEA RDI,[RBP + -0x78] CALL 0x0010bb20 JMP 0x00134859 LAB_00134859: MOV RDI,qword ptr [RBP + -0xb8] LEA RSI,[RBP + -0x78] CALL 0x00137b10 JMP 0x0013486b LAB_0013486b: MOV RDI,qword ptr [RBP + -0xb8] MOV byte ptr [RBP + -0x7a],0x0 LEA RSI,[0x1a1590] LEA RDX,[0x137bf0] CALL 0x00109a30 LAB_001348cd: MOV AL,byte ptr [RBP + -0x19] AND AL,0x1 ADD RSP,0xc0 POP RBP RET
/* CLI::App::_parse_single(std::vector<std::__cxx11::string, std::allocator<std::__cxx11::string > >&, bool&) */ ulong __thiscall CLI::App::_parse_single(App *this,vector *param_1,bool *param_2) { int4 uVar1; string *psVar2; App *pAVar3; ulong uVar4; HorribleError *pHVar5; int4 local_94; allocator local_81; string local_80 [55]; allocator local_49; string local_48 [32]; int4 local_28; char local_21; App *local_20; vector *local_18; App *local_10; local_21 = '\x01'; local_20 = (App *)param_2; local_18 = param_1; local_10 = this; if ((*param_2 & 1U) == 0) { psVar2 = (string *) std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::back ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)param_1 ); local_94 = _recognize(this,psVar2,true); } else { local_94 = 0; } local_28 = local_94; switch(local_94) { case 0: uVar4 = _parse_positional(this,local_18,false); local_21 = (char)(App *)(uVar4 & 0xffffffffffffff01); pAVar3 = (App *)(uVar4 & 0xffffffffffffff01); if ((local_21 != '\0') && (pAVar3 = this, ((byte)this[0x29c] & 1) != 0)) { *local_20 = (App)0x1; pAVar3 = local_20; } break; case 1: std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::pop_back ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *)local_18); *local_20 = (App)0x1; uVar4 = _has_remaining_positionals(this); uVar1 = local_28; if (((uVar4 & 1) == 0) && (*(long *)(this + 0x2c8) != 0)) { local_21 = '\0'; pAVar3 = this; } else { std::allocator<char>::allocator(); /* try { // try from 0013472a to 00134739 has its CatchHandler @ 00134768 */ std::__cxx11::string::string<std::allocator<char>>(local_48,"--",&local_49); /* try { // try from 0013473c to 00134751 has its CatchHandler @ 00134776 */ _move_to_missing(this,uVar1,local_48); std::__cxx11::string::~string(local_48); pAVar3 = (App *)std::allocator<char>::~allocator((allocator<char> *)&local_49); } break; case 2: case 3: case 4: pAVar3 = (App *)_parse_arg(this,local_18,local_94); break; case 5: uVar4 = _parse_subcommand(this,local_18); local_21 = (char)(App *)(uVar4 & 0xffffffffffffff01); pAVar3 = (App *)(uVar4 & 0xffffffffffffff01); break; case 6: pAVar3 = (App *)std::vector<std::__cxx11::string,std::allocator<std::__cxx11::string>>::pop_back ((vector<std::__cxx11::string,std::allocator<std::__cxx11::string>> *) local_18); local_21 = '\0'; break; default: pHVar5 = (HorribleError *)__cxa_allocate_exception(0x38); std::allocator<char>::allocator(); /* try { // try from 00134847 to 00134856 has its CatchHandler @ 0013488b */ std::__cxx11::string::string<std::allocator<char>> (local_80,"unrecognized classifier (you should not see this!)",&local_81); /* try { // try from 00134859 to 00134888 has its CatchHandler @ 00134899 */ HorribleError::HorribleError(pHVar5,local_80); /* WARNING: Subroutine does not return */ __cxa_throw(pHVar5,&HorribleError::typeinfo,HorribleError::~HorribleError); } return CONCAT71((int7)((ulong)pAVar3 >> 8),local_21) & 0xffffffffffffff01; }
3,591
mysql_close
eloqsql/libmariadb/libmariadb/mariadb_lib.c
void STDCALL mysql_close(MYSQL *mysql) { if (mysql) /* Some simple safety */ { if (mysql->extension && mysql->extension->conn_hdlr) { MA_CONNECTION_HANDLER *p= mysql->extension->conn_hdlr; if (p->plugin->close) p->plugin->close(mysql); free(p); /* Fix for CONC-294: Since we already called plugin->close function we need to prevent that mysql_close_slow_part (which sends COM_QUIT to the server) will be handled by plugin again. */ mysql->extension->conn_hdlr= NULL; } if (mysql->methods) mysql->methods->db_close(mysql); /* reset the connection in all active statements */ ma_invalidate_stmts(mysql, "mysql_close()"); mysql_close_memory(mysql); mysql_close_options(mysql); ma_clear_session_state(mysql); if (mysql->net.extension) { if (compression_plugin(&mysql->net)) compression_plugin(&mysql->net)->free_ctx(compression_ctx(&mysql->net)); free(mysql->net.extension); } mysql->host_info=mysql->user=mysql->passwd=mysql->db=0; /* Clear pointers for better safety */ memset((char*) &mysql->options, 0, sizeof(mysql->options)); if (mysql->extension) free(mysql->extension); /* Clear pointers for better safety */ mysql->net.extension = NULL; mysql->extension = NULL; mysql->net.pvio= 0; if (mysql->free_me) free(mysql); } return; }
O3
c
mysql_close: pushq %rbp movq %rsp, %rbp pushq %r14 pushq %rbx testq %rdi, %rdi je 0x1da69 movq %rdi, %rbx movq 0x4f0(%rdi), %rax testq %rax, %rax je 0x1d9a2 movq (%rax), %r14 testq %r14, %r14 je 0x1d9a2 movq (%r14), %rax movq 0x60(%rax), %rax testq %rax, %rax je 0x1d98c movq %rbx, %rdi callq *%rax movq %r14, %rdi callq 0x13570 movq 0x4f0(%rbx), %rax movq $0x0, (%rax) movq 0x4d0(%rbx), %rax testq %rax, %rax je 0x1d9b4 movq %rbx, %rdi callq *0x8(%rax) leaq 0x1c231(%rip), %rsi # 0x39bec movq %rbx, %rdi callq 0x1da6e movq %rbx, %rdi callq 0x1d50c movq %rbx, %rdi callq 0x1d598 movq %rbx, %rdi callq 0x1de7f movq 0x2a0(%rbx), %rdi testq %rdi, %rdi je 0x1da03 movq 0x10(%rdi), %rax testq %rax, %rax je 0x1d9fe movq 0x8(%rdi), %rdi callq *0x60(%rax) movq 0x2a0(%rbx), %rdi callq 0x13570 xorl %eax, %eax movq %rax, 0x2e8(%rbx) movq %rax, 0x2d8(%rbx) leaq 0x390(%rbx), %rdi xorps %xmm0, %xmm0 movups %xmm0, 0x2b8(%rbx) movl $0xf8, %edx xorl %esi, %esi callq 0x13260 movq 0x4f0(%rbx), %rdi testq %rdi, %rdi je 0x1da41 callq 0x13570 xorl %eax, %eax movq %rax, 0x2a0(%rbx) movq %rax, 0x4f0(%rbx) movq %rax, (%rbx) cmpb $0x0, 0x48c(%rbx) je 0x1da69 movq %rbx, %rdi popq %rbx popq %r14 popq %rbp jmp 0x13570 popq %rbx popq %r14 popq %rbp retq
mysql_close: push rbp mov rbp, rsp push r14 push rbx test rdi, rdi jz loc_1DA69 mov rbx, rdi mov rax, [rdi+4F0h] test rax, rax jz short loc_1D9A2 mov r14, [rax] test r14, r14 jz short loc_1D9A2 mov rax, [r14] mov rax, [rax+60h] test rax, rax jz short loc_1D98C mov rdi, rbx call rax loc_1D98C: mov rdi, r14 call _free mov rax, [rbx+4F0h] mov qword ptr [rax], 0 loc_1D9A2: mov rax, [rbx+4D0h] test rax, rax jz short loc_1D9B4 mov rdi, rbx call qword ptr [rax+8] loc_1D9B4: lea rsi, aMysqlClose; "mysql_close()" mov rdi, rbx call ma_invalidate_stmts mov rdi, rbx call mysql_close_memory mov rdi, rbx call mysql_close_options mov rdi, rbx call ma_clear_session_state mov rdi, [rbx+2A0h] test rdi, rdi jz short loc_1DA03 mov rax, [rdi+10h] test rax, rax jz short loc_1D9FE mov rdi, [rdi+8] call qword ptr [rax+60h] mov rdi, [rbx+2A0h] loc_1D9FE: call _free loc_1DA03: xor eax, eax mov [rbx+2E8h], rax mov [rbx+2D8h], rax lea rdi, [rbx+390h] xorps xmm0, xmm0 movups xmmword ptr [rbx+2B8h], xmm0 mov edx, 0F8h xor esi, esi call _memset mov rdi, [rbx+4F0h] test rdi, rdi jz short loc_1DA41 call _free loc_1DA41: xor eax, eax mov [rbx+2A0h], rax mov [rbx+4F0h], rax mov [rbx], rax cmp byte ptr [rbx+48Ch], 0 jz short loc_1DA69 mov rdi, rbx pop rbx pop r14 pop rbp jmp _free loc_1DA69: pop rbx pop r14 pop rbp retn
void mysql_close(long long a1) { long long *v2; // rax long long v3; // r14 void ( *v4)(long long); // rax long long v5; // rax long long v6; // rdi long long v7; // rax long long v8; // rdi if ( a1 ) { v2 = *(long long **)(a1 + 1264); if ( v2 ) { v3 = *v2; if ( *v2 ) { v4 = *(void ( **)(long long))(*(_QWORD *)v3 + 96LL); if ( v4 ) v4(a1); free(v3); **(_QWORD **)(a1 + 1264) = 0LL; } } v5 = *(_QWORD *)(a1 + 1232); if ( v5 ) (*(void ( **)(long long))(v5 + 8))(a1); ma_invalidate_stmts(a1, "mysql_close()"); mysql_close_memory((_QWORD *)a1); mysql_close_options((_QWORD *)a1); ma_clear_session_state(a1); v6 = *(_QWORD *)(a1 + 672); if ( v6 ) { v7 = *(_QWORD *)(v6 + 16); if ( v7 ) { (*(void ( **)(_QWORD))(v7 + 96))(*(_QWORD *)(v6 + 8)); v6 = *(_QWORD *)(a1 + 672); } free(v6); } *(_QWORD *)(a1 + 744) = 0LL; *(_QWORD *)(a1 + 728) = 0LL; *(_OWORD *)(a1 + 696) = 0LL; memset(a1 + 912, 0LL, 248LL); v8 = *(_QWORD *)(a1 + 1264); if ( v8 ) free(v8); *(_QWORD *)(a1 + 672) = 0LL; *(_QWORD *)(a1 + 1264) = 0LL; *(_QWORD *)a1 = 0LL; if ( *(_BYTE *)(a1 + 1164) ) free(a1); } }
mysql_close: PUSH RBP MOV RBP,RSP PUSH R14 PUSH RBX TEST RDI,RDI JZ 0x0011da69 MOV RBX,RDI MOV RAX,qword ptr [RDI + 0x4f0] TEST RAX,RAX JZ 0x0011d9a2 MOV R14,qword ptr [RAX] TEST R14,R14 JZ 0x0011d9a2 MOV RAX,qword ptr [R14] MOV RAX,qword ptr [RAX + 0x60] TEST RAX,RAX JZ 0x0011d98c MOV RDI,RBX CALL RAX LAB_0011d98c: MOV RDI,R14 CALL 0x00113570 MOV RAX,qword ptr [RBX + 0x4f0] MOV qword ptr [RAX],0x0 LAB_0011d9a2: MOV RAX,qword ptr [RBX + 0x4d0] TEST RAX,RAX JZ 0x0011d9b4 MOV RDI,RBX CALL qword ptr [RAX + 0x8] LAB_0011d9b4: LEA RSI,[0x139bec] MOV RDI,RBX CALL 0x0011da6e MOV RDI,RBX CALL 0x0011d50c MOV RDI,RBX CALL 0x0011d598 MOV RDI,RBX CALL 0x0011de7f MOV RDI,qword ptr [RBX + 0x2a0] TEST RDI,RDI JZ 0x0011da03 MOV RAX,qword ptr [RDI + 0x10] TEST RAX,RAX JZ 0x0011d9fe MOV RDI,qword ptr [RDI + 0x8] CALL qword ptr [RAX + 0x60] MOV RDI,qword ptr [RBX + 0x2a0] LAB_0011d9fe: CALL 0x00113570 LAB_0011da03: XOR EAX,EAX MOV qword ptr [RBX + 0x2e8],RAX MOV qword ptr [RBX + 0x2d8],RAX LEA RDI,[RBX + 0x390] XORPS XMM0,XMM0 MOVUPS xmmword ptr [RBX + 0x2b8],XMM0 MOV EDX,0xf8 XOR ESI,ESI CALL 0x00113260 MOV RDI,qword ptr [RBX + 0x4f0] TEST RDI,RDI JZ 0x0011da41 CALL 0x00113570 LAB_0011da41: XOR EAX,EAX MOV qword ptr [RBX + 0x2a0],RAX MOV qword ptr [RBX + 0x4f0],RAX MOV qword ptr [RBX],RAX CMP byte ptr [RBX + 0x48c],0x0 JZ 0x0011da69 MOV RDI,RBX POP RBX POP R14 POP RBP JMP 0x00113570 LAB_0011da69: POP RBX POP R14 POP RBP RET
void mysql_close(int8 *param_1) { long *__ptr; void *__ptr_00; if (param_1 != (int8 *)0x0) { if (((int8 *)param_1[0x9e] != (int8 *)0x0) && (__ptr = *(long **)param_1[0x9e], __ptr != (long *)0x0)) { if (*(code **)(*__ptr + 0x60) != (code *)0x0) { (**(code **)(*__ptr + 0x60))(param_1); } free(__ptr); *(int8 *)param_1[0x9e] = 0; } if (param_1[0x9a] != 0) { (**(code **)(param_1[0x9a] + 8))(param_1); } ma_invalidate_stmts(param_1); mysql_close_memory(param_1); mysql_close_options(param_1); ma_clear_session_state(param_1); __ptr_00 = (void *)param_1[0x54]; if (__ptr_00 != (void *)0x0) { if (*(long *)((long)__ptr_00 + 0x10) != 0) { (**(code **)(*(long *)((long)__ptr_00 + 0x10) + 0x60))(*(int8 *)((long)__ptr_00 + 8)); __ptr_00 = (void *)param_1[0x54]; } free(__ptr_00); } param_1[0x5d] = 0; param_1[0x5b] = 0; param_1[0x57] = 0; param_1[0x58] = 0; memset(param_1 + 0x72,0,0xf8); if ((void *)param_1[0x9e] != (void *)0x0) { free((void *)param_1[0x9e]); } param_1[0x54] = 0; param_1[0x9e] = 0; *param_1 = 0; if (*(char *)((long)param_1 + 0x48c) != '\0') { free(param_1); return; } } return; }
3,592
my_uca_charcmp
eloqsql/strings/ctype-uca.c
static int my_uca_charcmp(CHARSET_INFO *cs, my_wc_t wc1, my_wc_t wc2) { uint num_level= cs->levels_for_order; int ret; uint i; for (i= 0; i != num_level; i++) { ret= my_uca_charcmp_onelevel(cs, wc1, wc2, i); if (ret) { return ret; } } return 0; }
O0
c
my_uca_charcmp: pushq %rbp movq %rsp, %rbp subq $0x30, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq %rdx, -0x20(%rbp) movq -0x10(%rbp), %rax movzbl 0xb2(%rax), %eax movl %eax, -0x24(%rbp) movl $0x0, -0x2c(%rbp) movl -0x2c(%rbp), %eax cmpl -0x24(%rbp), %eax je 0x4dbe3 movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi movq -0x20(%rbp), %rdx movl -0x2c(%rbp), %ecx callq 0x4dc00 movl %eax, -0x28(%rbp) cmpl $0x0, -0x28(%rbp) je 0x4dbd6 movl -0x28(%rbp), %eax movl %eax, -0x4(%rbp) jmp 0x4dbea jmp 0x4dbd8 movl -0x2c(%rbp), %eax addl $0x1, %eax movl %eax, -0x2c(%rbp) jmp 0x4dba9 movl $0x0, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x30, %rsp popq %rbp retq nopw %cs:(%rax,%rax)
my_uca_charcmp: push rbp mov rbp, rsp sub rsp, 30h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_20], rdx mov rax, [rbp+var_10] movzx eax, byte ptr [rax+0B2h] mov [rbp+var_24], eax mov [rbp+var_2C], 0 loc_4DBA9: mov eax, [rbp+var_2C] cmp eax, [rbp+var_24] jz short loc_4DBE3 mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] mov rdx, [rbp+var_20] mov ecx, [rbp+var_2C] call my_uca_charcmp_onelevel mov [rbp+var_28], eax cmp [rbp+var_28], 0 jz short loc_4DBD6 mov eax, [rbp+var_28] mov [rbp+var_4], eax jmp short loc_4DBEA loc_4DBD6: jmp short $+2 loc_4DBD8: mov eax, [rbp+var_2C] add eax, 1 mov [rbp+var_2C], eax jmp short loc_4DBA9 loc_4DBE3: mov [rbp+var_4], 0 loc_4DBEA: mov eax, [rbp+var_4] add rsp, 30h pop rbp retn
long long my_uca_charcmp(long long a1, long long a2, long long a3) { unsigned int i; // [rsp+4h] [rbp-2Ch] unsigned int v5; // [rsp+8h] [rbp-28h] int v6; // [rsp+Ch] [rbp-24h] v6 = *(unsigned __int8 *)(a1 + 178); for ( i = 0; i != v6; ++i ) { v5 = my_uca_charcmp_onelevel(a1, a2, a3, i); if ( v5 ) return v5; } return 0; }
my_uca_charcmp: PUSH RBP MOV RBP,RSP SUB RSP,0x30 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV qword ptr [RBP + -0x20],RDX MOV RAX,qword ptr [RBP + -0x10] MOVZX EAX,byte ptr [RAX + 0xb2] MOV dword ptr [RBP + -0x24],EAX MOV dword ptr [RBP + -0x2c],0x0 LAB_0014dba9: MOV EAX,dword ptr [RBP + -0x2c] CMP EAX,dword ptr [RBP + -0x24] JZ 0x0014dbe3 MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] MOV RDX,qword ptr [RBP + -0x20] MOV ECX,dword ptr [RBP + -0x2c] CALL 0x0014dc00 MOV dword ptr [RBP + -0x28],EAX CMP dword ptr [RBP + -0x28],0x0 JZ 0x0014dbd6 MOV EAX,dword ptr [RBP + -0x28] MOV dword ptr [RBP + -0x4],EAX JMP 0x0014dbea LAB_0014dbd6: JMP 0x0014dbd8 LAB_0014dbd8: MOV EAX,dword ptr [RBP + -0x2c] ADD EAX,0x1 MOV dword ptr [RBP + -0x2c],EAX JMP 0x0014dba9 LAB_0014dbe3: MOV dword ptr [RBP + -0x4],0x0 LAB_0014dbea: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x30 POP RBP RET
int my_uca_charcmp(long param_1,int8 param_2,int8 param_3) { byte bVar1; int iVar2; uint local_34; bVar1 = *(byte *)(param_1 + 0xb2); local_34 = 0; while( true ) { if (local_34 == bVar1) { return 0; } iVar2 = my_uca_charcmp_onelevel(param_1,param_2,param_3,local_34); if (iVar2 != 0) break; local_34 = local_34 + 1; } return iVar2; }
3,593
my_uca_charcmp
eloqsql/strings/ctype-uca.c
static int my_uca_charcmp(CHARSET_INFO *cs, my_wc_t wc1, my_wc_t wc2) { uint num_level= cs->levels_for_order; int ret; uint i; for (i= 0; i != num_level; i++) { ret= my_uca_charcmp_onelevel(cs, wc1, wc2, i); if (ret) { return ret; } } return 0; }
O3
c
my_uca_charcmp: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x58, %rsp movzbl 0xb2(%rdi), %eax testq %rax, %rax je 0x3fdc4 movq 0x60(%rdi), %r12 movl %esi, %edi movq %rsi, %r8 shrq $0x8, %r8 movl $0xffffff, %r9d # imm = 0xFFFFFF movq %r8, -0x78(%rbp) andq %r9, %r8 movl $0xff, %ecx movq %rsi, %r10 andq %rcx, %r10 movl %edx, %r11d movq %rdx, %rbx shrq $0x8, %rbx movq %rbx, -0x70(%rbp) andq %rbx, %r9 andq %rdx, %rcx movq %rcx, -0x80(%rbp) cmpq %rdx, %rsi movl $0x0, %esi setne %sil imulq $0x38, %rax, %rdx xorl %r13d, %r13d movq %rdi, -0x68(%rbp) movq %r9, -0x60(%rbp) movq %r8, -0x58(%rbp) movq %r10, -0x50(%rbp) movq %r11, -0x48(%rbp) movl %esi, -0x2c(%rbp) movq %rdx, -0x38(%rbp) movq (%r12,%r13), %rax cmpq %rdi, %rax jb 0x3fca3 movq 0x10(%r12,%r13), %rcx movq (%rcx,%r8,8), %rcx testq %rcx, %rcx je 0x3fca3 movq 0x8(%r12,%r13), %rdx movzbl (%rdx,%r8), %edx imull %r10d, %edx leaq (%rcx,%rdx,2), %r14 movq -0x38(%rbp), %rdx jmp 0x3fca6 xorl %r14d, %r14d movl %esi, %ebx cmpq %r11, %rax jb 0x3fdb3 movq 0x10(%r12,%r13), %rax movq (%rax,%r9,8), %rax movl %esi, %ebx testq %rax, %rax je 0x3fdb3 movl %esi, %ebx testq %r14, %r14 je 0x3fdb3 movq 0x8(%r12,%r13), %rcx movzbl (%rcx,%r9), %edx imull -0x80(%rbp), %edx leaq (%rax,%rdx,2), %r15 movzwl (%r14), %eax movl $0x1, %ebx cmpw (%r15), %ax jne 0x3fdc6 movq -0x78(%rbp), %rax movzbl (%rcx,%rax), %esi movq -0x70(%rbp), %rax movzbl (%rcx,%rax), %eax cmpb %al, %sil jbe 0x3fd4a movq %rax, -0x40(%rbp) leal (%rax,%rax), %edx movq %r14, %rdi movq %r15, %rsi callq 0x242e0 movl -0x2c(%rbp), %esi movq -0x48(%rbp), %r11 movq -0x50(%rbp), %r10 movq -0x58(%rbp), %r8 movq -0x60(%rbp), %r9 movq -0x68(%rbp), %rdi testl %eax, %eax movq -0x38(%rbp), %rdx jne 0x3fdc6 movq -0x40(%rbp), %rax movzwl (%r14,%rax,2), %ebx jmp 0x3fdb3 leal (%rsi,%rsi), %edx cmpb %al, %sil jae 0x3fd8b movq %rsi, -0x40(%rbp) movq %r14, %rdi movq %r15, %rsi callq 0x242e0 testl %eax, %eax movq -0x68(%rbp), %rdi movq -0x60(%rbp), %r9 movq -0x58(%rbp), %r8 movq -0x50(%rbp), %r10 movq -0x48(%rbp), %r11 movl -0x2c(%rbp), %esi movq -0x38(%rbp), %rdx jne 0x3fdc6 movq -0x40(%rbp), %rax movzwl (%r15,%rax,2), %ebx jmp 0x3fdb3 movq %r14, %rdi movq %r15, %rsi callq 0x24140 movl %eax, %ebx movq -0x68(%rbp), %rdi movq -0x60(%rbp), %r9 movq -0x58(%rbp), %r8 movq -0x50(%rbp), %r10 movq -0x48(%rbp), %r11 movl -0x2c(%rbp), %esi movq -0x38(%rbp), %rdx testl %ebx, %ebx jne 0x3fdc6 addq $0x38, %r13 cmpq %r13, %rdx jne 0x3fc74 xorl %ebx, %ebx movl %ebx, %eax addq $0x58, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
my_uca_charcmp: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 58h movzx eax, byte ptr [rdi+0B2h] test rax, rax jz loc_3FDC4 mov r12, [rdi+60h] mov edi, esi mov r8, rsi shr r8, 8 mov r9d, 0FFFFFFh mov [rbp+var_78], r8 and r8, r9 mov ecx, 0FFh mov r10, rsi and r10, rcx mov r11d, edx mov rbx, rdx shr rbx, 8 mov [rbp+var_70], rbx and r9, rbx and rcx, rdx mov [rbp+var_80], rcx cmp rsi, rdx mov esi, 0 setnz sil imul rdx, rax, 38h ; '8' xor r13d, r13d mov [rbp+var_68], rdi mov [rbp+var_60], r9 mov [rbp+var_58], r8 mov [rbp+var_50], r10 mov [rbp+var_48], r11 mov [rbp+var_2C], esi mov [rbp+var_38], rdx loc_3FC74: mov rax, [r12+r13] cmp rax, rdi jb short loc_3FCA3 mov rcx, [r12+r13+10h] mov rcx, [rcx+r8*8] test rcx, rcx jz short loc_3FCA3 mov rdx, [r12+r13+8] movzx edx, byte ptr [rdx+r8] imul edx, r10d lea r14, [rcx+rdx*2] mov rdx, [rbp+var_38] jmp short loc_3FCA6 loc_3FCA3: xor r14d, r14d loc_3FCA6: mov ebx, esi cmp rax, r11 jb loc_3FDB3 mov rax, [r12+r13+10h] mov rax, [rax+r9*8] mov ebx, esi test rax, rax jz loc_3FDB3 mov ebx, esi test r14, r14 jz loc_3FDB3 mov rcx, [r12+r13+8] movzx edx, byte ptr [rcx+r9] imul edx, dword ptr [rbp+var_80] lea r15, [rax+rdx*2] movzx eax, word ptr [r14] mov ebx, 1 cmp ax, [r15] jnz loc_3FDC6 mov rax, [rbp+var_78] movzx esi, byte ptr [rcx+rax] mov rax, [rbp+var_70] movzx eax, byte ptr [rcx+rax] cmp sil, al jbe short loc_3FD4A mov [rbp+var_40], rax lea edx, [rax+rax] mov rdi, r14 mov rsi, r15 call _bcmp mov esi, [rbp+var_2C] mov r11, [rbp+var_48] mov r10, [rbp+var_50] mov r8, [rbp+var_58] mov r9, [rbp+var_60] mov rdi, [rbp+var_68] test eax, eax mov rdx, [rbp+var_38] jnz loc_3FDC6 mov rax, [rbp+var_40] movzx ebx, word ptr [r14+rax*2] jmp short loc_3FDB3 loc_3FD4A: lea edx, [rsi+rsi] cmp sil, al jnb short loc_3FD8B mov [rbp+var_40], rsi mov rdi, r14 mov rsi, r15 call _bcmp test eax, eax mov rdi, [rbp+var_68] mov r9, [rbp+var_60] mov r8, [rbp+var_58] mov r10, [rbp+var_50] mov r11, [rbp+var_48] mov esi, [rbp+var_2C] mov rdx, [rbp+var_38] jnz short loc_3FDC6 mov rax, [rbp+var_40] movzx ebx, word ptr [r15+rax*2] jmp short loc_3FDB3 loc_3FD8B: mov rdi, r14 mov rsi, r15 call _memcmp mov ebx, eax mov rdi, [rbp+var_68] mov r9, [rbp+var_60] mov r8, [rbp+var_58] mov r10, [rbp+var_50] mov r11, [rbp+var_48] mov esi, [rbp+var_2C] mov rdx, [rbp+var_38] loc_3FDB3: test ebx, ebx jnz short loc_3FDC6 add r13, 38h ; '8' cmp rdx, r13 jnz loc_3FC74 loc_3FDC4: xor ebx, ebx loc_3FDC6: mov eax, ebx add rsp, 58h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
long long my_uca_charcmp(long long a1, unsigned long long a2, unsigned long long a3) { long long v3; // rax long long v4; // r12 unsigned long long v5; // rdi long long v6; // r8 int v7; // r10d unsigned long long v8; // r11 long long v9; // r9 BOOL v10; // esi long long v11; // rdx long long v12; // r13 unsigned long long v13; // rax long long v14; // rcx _WORD *v15; // r14 unsigned int v16; // ebx long long v17; // rax long long v18; // rcx _WORD *v19; // r15 int v20; // esi int v21; // eax int v22; // eax long long v23; // rdx int v24; // eax int v26; // [rsp+0h] [rbp-80h] unsigned long long v27; // [rsp+8h] [rbp-78h] unsigned long long v28; // [rsp+10h] [rbp-70h] unsigned long long v29; // [rsp+18h] [rbp-68h] long long v30; // [rsp+20h] [rbp-60h] long long v31; // [rsp+28h] [rbp-58h] int v32; // [rsp+30h] [rbp-50h] unsigned long long v33; // [rsp+38h] [rbp-48h] long long v34; // [rsp+40h] [rbp-40h] long long v35; // [rsp+40h] [rbp-40h] long long v36; // [rsp+48h] [rbp-38h] BOOL v37; // [rsp+54h] [rbp-2Ch] v3 = *(unsigned __int8 *)(a1 + 178); if ( *(_BYTE *)(a1 + 178) ) { v4 = *(_QWORD *)(a1 + 96); v5 = (unsigned int)a2; v27 = a2 >> 8; v6 = (unsigned int)a2 >> 8; v7 = (unsigned __int8)a2; v8 = (unsigned int)a3; v28 = a3 >> 8; v9 = (unsigned int)a3 >> 8; v26 = (unsigned __int8)a3; v10 = a2 != a3; v11 = 56 * v3; v12 = 0LL; v29 = v5; v30 = v9; v31 = v6; v32 = v7; v33 = v8; v37 = v10; v36 = 56 * v3; while ( 1 ) { v13 = *(_QWORD *)(v4 + v12); if ( v13 >= v5 && (v14 = *(_QWORD *)(*(_QWORD *)(v4 + v12 + 16) + 8 * v6)) != 0 ) { v15 = (_WORD *)(v14 + 2LL * v7 * (unsigned int)*(unsigned __int8 *)(*(_QWORD *)(v4 + v12 + 8) + v6)); v11 = v36; } else { v15 = 0LL; } v16 = v10; if ( v13 >= v8 ) { v17 = *(_QWORD *)(*(_QWORD *)(v4 + v12 + 16) + 8 * v9); v16 = v10; if ( v17 ) { v16 = v10; if ( v15 ) { v18 = *(_QWORD *)(v4 + v12 + 8); v19 = (_WORD *)(v17 + 2LL * v26 * (unsigned int)*(unsigned __int8 *)(v18 + v9)); v16 = 1; if ( *v15 != *v19 ) return v16; v20 = *(unsigned __int8 *)(v18 + v27); v21 = *(unsigned __int8 *)(v18 + v28); if ( (unsigned __int8)v20 <= (unsigned __int8)v21 ) { v23 = (unsigned int)(2 * v20); if ( (unsigned __int8)v20 >= (unsigned __int8)v21 ) { v16 = memcmp(v15, v19, v23); v5 = v29; v9 = v30; v6 = v31; v7 = v32; v8 = v33; v10 = v37; v11 = v36; } else { v35 = *(unsigned __int8 *)(v18 + v27); v24 = bcmp(v15, v19, v23); v5 = v29; v9 = v30; v6 = v31; v7 = v32; v8 = v33; v10 = v37; v11 = v36; if ( v24 ) return v16; v16 = (unsigned __int16)v19[v35]; } } else { v34 = *(unsigned __int8 *)(v18 + v28); v22 = bcmp(v15, v19, (unsigned int)(2 * v21)); v10 = v37; v8 = v33; v7 = v32; v6 = v31; v9 = v30; v5 = v29; v11 = v36; if ( v22 ) return v16; v16 = (unsigned __int16)v15[v34]; } } } } if ( v16 ) break; v12 += 56LL; if ( v11 == v12 ) return 0; } } else { return 0; } return v16; }
my_uca_charcmp: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x58 MOVZX EAX,byte ptr [RDI + 0xb2] TEST RAX,RAX JZ 0x0013fdc4 MOV R12,qword ptr [RDI + 0x60] MOV EDI,ESI MOV R8,RSI SHR R8,0x8 MOV R9D,0xffffff MOV qword ptr [RBP + -0x78],R8 AND R8,R9 MOV ECX,0xff MOV R10,RSI AND R10,RCX MOV R11D,EDX MOV RBX,RDX SHR RBX,0x8 MOV qword ptr [RBP + -0x70],RBX AND R9,RBX AND RCX,RDX MOV qword ptr [RBP + -0x80],RCX CMP RSI,RDX MOV ESI,0x0 SETNZ SIL IMUL RDX,RAX,0x38 XOR R13D,R13D MOV qword ptr [RBP + -0x68],RDI MOV qword ptr [RBP + -0x60],R9 MOV qword ptr [RBP + -0x58],R8 MOV qword ptr [RBP + -0x50],R10 MOV qword ptr [RBP + -0x48],R11 MOV dword ptr [RBP + -0x2c],ESI MOV qword ptr [RBP + -0x38],RDX LAB_0013fc74: MOV RAX,qword ptr [R12 + R13*0x1] CMP RAX,RDI JC 0x0013fca3 MOV RCX,qword ptr [R12 + R13*0x1 + 0x10] MOV RCX,qword ptr [RCX + R8*0x8] TEST RCX,RCX JZ 0x0013fca3 MOV RDX,qword ptr [R12 + R13*0x1 + 0x8] MOVZX EDX,byte ptr [RDX + R8*0x1] IMUL EDX,R10D LEA R14,[RCX + RDX*0x2] MOV RDX,qword ptr [RBP + -0x38] JMP 0x0013fca6 LAB_0013fca3: XOR R14D,R14D LAB_0013fca6: MOV EBX,ESI CMP RAX,R11 JC 0x0013fdb3 MOV RAX,qword ptr [R12 + R13*0x1 + 0x10] MOV RAX,qword ptr [RAX + R9*0x8] MOV EBX,ESI TEST RAX,RAX JZ 0x0013fdb3 MOV EBX,ESI TEST R14,R14 JZ 0x0013fdb3 MOV RCX,qword ptr [R12 + R13*0x1 + 0x8] MOVZX EDX,byte ptr [RCX + R9*0x1] IMUL EDX,dword ptr [RBP + -0x80] LEA R15,[RAX + RDX*0x2] MOVZX EAX,word ptr [R14] MOV EBX,0x1 CMP AX,word ptr [R15] JNZ 0x0013fdc6 MOV RAX,qword ptr [RBP + -0x78] MOVZX ESI,byte ptr [RCX + RAX*0x1] MOV RAX,qword ptr [RBP + -0x70] MOVZX EAX,byte ptr [RCX + RAX*0x1] CMP SIL,AL JBE 0x0013fd4a MOV qword ptr [RBP + -0x40],RAX LEA EDX,[RAX + RAX*0x1] MOV RDI,R14 MOV RSI,R15 CALL 0x001242e0 MOV ESI,dword ptr [RBP + -0x2c] MOV R11,qword ptr [RBP + -0x48] MOV R10,qword ptr [RBP + -0x50] MOV R8,qword ptr [RBP + -0x58] MOV R9,qword ptr [RBP + -0x60] MOV RDI,qword ptr [RBP + -0x68] TEST EAX,EAX MOV RDX,qword ptr [RBP + -0x38] JNZ 0x0013fdc6 MOV RAX,qword ptr [RBP + -0x40] MOVZX EBX,word ptr [R14 + RAX*0x2] JMP 0x0013fdb3 LAB_0013fd4a: LEA EDX,[RSI + RSI*0x1] CMP SIL,AL JNC 0x0013fd8b MOV qword ptr [RBP + -0x40],RSI MOV RDI,R14 MOV RSI,R15 CALL 0x001242e0 TEST EAX,EAX MOV RDI,qword ptr [RBP + -0x68] MOV R9,qword ptr [RBP + -0x60] MOV R8,qword ptr [RBP + -0x58] MOV R10,qword ptr [RBP + -0x50] MOV R11,qword ptr [RBP + -0x48] MOV ESI,dword ptr [RBP + -0x2c] MOV RDX,qword ptr [RBP + -0x38] JNZ 0x0013fdc6 MOV RAX,qword ptr [RBP + -0x40] MOVZX EBX,word ptr [R15 + RAX*0x2] JMP 0x0013fdb3 LAB_0013fd8b: MOV RDI,R14 MOV RSI,R15 CALL 0x00124140 MOV EBX,EAX MOV RDI,qword ptr [RBP + -0x68] MOV R9,qword ptr [RBP + -0x60] MOV R8,qword ptr [RBP + -0x58] MOV R10,qword ptr [RBP + -0x50] MOV R11,qword ptr [RBP + -0x48] MOV ESI,dword ptr [RBP + -0x2c] MOV RDX,qword ptr [RBP + -0x38] LAB_0013fdb3: TEST EBX,EBX JNZ 0x0013fdc6 ADD R13,0x38 CMP RDX,R13 JNZ 0x0013fc74 LAB_0013fdc4: XOR EBX,EBX LAB_0013fdc6: MOV EAX,EBX ADD RSP,0x58 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
uint my_uca_charcmp(long param_1,ulong param_2,ulong param_3) { short *__s2; byte bVar1; byte bVar2; byte bVar3; long lVar4; long lVar5; long lVar6; int iVar7; uint uVar8; ulong uVar9; ulong uVar10; long lVar11; short *__s1; uint local_88; bVar1 = *(byte *)(param_1 + 0xb2); if ((ulong)bVar1 != 0) { lVar4 = *(long *)(param_1 + 0x60); uVar9 = param_2 >> 8 & 0xffffff; uVar10 = param_3 >> 8 & 0xffffff; local_88 = (uint)param_3 & 0xff; lVar11 = 0; do { uVar8 = (uint)(param_2 != param_3); if ((*(ulong *)(lVar4 + lVar11) < (param_2 & 0xffffffff)) || (lVar5 = *(long *)(*(long *)(lVar4 + 0x10 + lVar11) + uVar9 * 8), lVar5 == 0)) { __s1 = (short *)0x0; } else { __s1 = (short *)(lVar5 + (ulong)((uint)*(byte *)(*(long *)(lVar4 + 8 + lVar11) + uVar9) * ((uint)param_2 & 0xff)) * 2); } if ((((param_3 & 0xffffffff) <= *(ulong *)(lVar4 + lVar11)) && (lVar5 = *(long *)(*(long *)(lVar4 + 0x10 + lVar11) + uVar10 * 8), lVar5 != 0)) && (__s1 != (short *)0x0)) { lVar6 = *(long *)(lVar4 + 8 + lVar11); __s2 = (short *)(lVar5 + (ulong)(*(byte *)(lVar6 + uVar10) * local_88) * 2); if (*__s1 != *__s2) { return 1; } bVar2 = *(byte *)(lVar6 + (param_2 >> 8)); bVar3 = *(byte *)(lVar6 + (param_3 >> 8)); if (bVar3 < bVar2) { iVar7 = bcmp(__s1,__s2,(ulong)((uint)bVar3 + (uint)bVar3)); if (iVar7 != 0) { return 1; } uVar8 = (uint)(ushort)__s1[bVar3]; } else if (bVar2 < bVar3) { iVar7 = bcmp(__s1,__s2,(ulong)((uint)bVar2 + (uint)bVar2)); if (iVar7 != 0) { return 1; } uVar8 = (uint)(ushort)__s2[bVar2]; } else { uVar8 = memcmp(__s1,__s2,(ulong)((uint)bVar2 + (uint)bVar2)); } } if (uVar8 != 0) { return uVar8; } lVar11 = lVar11 + 0x38; } while ((ulong)bVar1 * 0x38 != lVar11); } return 0; }
3,594
ma_scramble_323
eloqsql/libmariadb/libmariadb/ma_password.c
char *ma_scramble_323(char *to, const char *message, const char *password) { struct rand_struct rand_st; ulong hash_pass[2], hash_message[2]; if (password && password[0]) { char extra, *to_start=to; const char *end_scramble323= message + SCRAMBLE_LENGTH_323; ma_hash_password(hash_pass,password, (uint) strlen(password)); /* Don't use strlen, could be > SCRAMBLE_LENGTH_323 ! */ ma_hash_password(hash_message, message, SCRAMBLE_LENGTH_323); ma_randominit(&rand_st, hash_pass[0] ^ hash_message[0], hash_pass[1] ^ hash_message[1]); for (; message < end_scramble323; message++) *to++= (char) (floor(rnd(&rand_st) * 31) + 64); extra=(char) (floor(rnd(&rand_st) * 31)); while (to_start != to) *(to_start++)^= extra; } *to= 0; return to; }
O3
c
ma_scramble_323: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x28, %rsp movq %rdi, %rbx testq %rdx, %rdx je 0x4406f movq %rdx, %r15 cmpb $0x0, (%rdx) je 0x4406f movq %rsi, %r14 movq %r15, %rdi callq 0x141c0 movl %eax, %edx leaq -0x50(%rbp), %r12 movq %r12, %rdi movq %r15, %rsi callq 0x43cc0 leaq -0x40(%rbp), %r15 movl $0x8, %edx movq %r15, %rdi movq %r14, %rsi callq 0x43cc0 movq (%r15), %rsi movq 0x8(%r15), %rcx xorq (%r12), %rsi xorq 0x8(%r12), %rcx movabsq $0x400000011, %r12 # imm = 0x400000011 movq %rsi, %rax mulq %r12 movq %rsi, %r13 subq %rdx, %r13 shrq %r13 addq %rdx, %r13 shrq $0x1d, %r13 movq %r13, %rax shlq $0x1e, %rax subq %rax, %r13 addq %rsi, %r13 movq %rcx, %rax mulq %r12 movq %rcx, %rsi subq %rdx, %rsi shrq %rsi addq %rdx, %rsi shrq $0x1d, %rsi movq %rsi, %rax shlq $0x1e, %rax subq %rax, %rsi addq %rcx, %rsi xorl %r15d, %r15d leaq (,%r13,2), %rcx addq %r13, %rcx addq %rsi, %rcx movq %rcx, %rax mulq %r12 movq %rcx, %r13 subq %rdx, %r13 shrq %r13 addq %rdx, %r13 shrq $0x1d, %r13 movq %r13, %rax shlq $0x1e, %rax subq %rax, %r13 addq %rcx, %r13 leaq (%rsi,%r13), %r14 addq $0x21, %r14 xorps %xmm0, %xmm0 cvtsi2sd %r13d, %xmm0 divsd 0x2205(%rip), %xmm0 # 0x461c8 mulsd 0x2205(%rip), %xmm0 # 0x461d0 callq 0x147b0 addsd 0x2200(%rip), %xmm0 # 0x461d8 cvttsd2si %xmm0, %eax movb %al, (%rbx,%r15) movq %r14, %rax mulq %r12 incq %r15 movq %r14, %rsi subq %rdx, %rsi shrq %rsi addq %rdx, %rsi shrq $0x1d, %rsi movq %rsi, %rax shlq $0x1e, %rax subq %rax, %rsi addq %r14, %rsi cmpq $0x8, %r15 jne 0x43f7a leal (%r13,%r13,2), %eax addl %eax, %esi leaq (%rsi,%rsi,4), %rax shrq $0x20, %rax movl %esi, %ecx subl %eax, %ecx shrl %ecx addl %eax, %ecx shrl $0x1d, %ecx movl %ecx, %eax shll $0x1e, %eax subl %eax, %ecx addl %esi, %ecx xorps %xmm0, %xmm0 cvtsi2sd %ecx, %xmm0 divsd 0x2186(%rip), %xmm0 # 0x461c8 mulsd 0x2186(%rip), %xmm0 # 0x461d0 callq 0x147b0 cvttsd2si %xmm0, %eax movd %eax, %xmm0 punpcklbw %xmm0, %xmm0 # xmm0 = xmm0[0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7] pshuflw $0x0, %xmm0, %xmm0 # xmm0 = xmm0[0,0,0,0,4,5,6,7] movq (%rbx), %xmm1 pxor %xmm0, %xmm1 movq %xmm1, (%rbx) addq %r15, %rbx movb $0x0, (%rbx) movq %rbx, %rax addq $0x28, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
ma_scramble_323: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 28h mov rbx, rdi test rdx, rdx jz loc_4406F mov r15, rdx cmp byte ptr [rdx], 0 jz loc_4406F mov r14, rsi mov rdi, r15 call _strlen mov edx, eax lea r12, [rbp+var_50] mov rdi, r12 mov rsi, r15 call ma_hash_password lea r15, [rbp+var_40] mov edx, 8 mov rdi, r15 mov rsi, r14 call ma_hash_password mov rsi, [r15] mov rcx, [r15+8] xor rsi, [r12] xor rcx, [r12+8] mov r12, 400000011h mov rax, rsi mul r12 mov r13, rsi sub r13, rdx shr r13, 1 add r13, rdx shr r13, 1Dh mov rax, r13 shl rax, 1Eh sub r13, rax add r13, rsi mov rax, rcx mul r12 mov rsi, rcx sub rsi, rdx shr rsi, 1 add rsi, rdx shr rsi, 1Dh mov rax, rsi shl rax, 1Eh sub rsi, rax add rsi, rcx xor r15d, r15d loc_43F7A: lea rcx, ds:0[r13*2] add rcx, r13 add rcx, rsi mov rax, rcx mul r12 mov r13, rcx sub r13, rdx shr r13, 1 add r13, rdx shr r13, 1Dh mov rax, r13 shl rax, 1Eh sub r13, rax add r13, rcx lea r14, [rsi+r13] add r14, 21h ; '!' xorps xmm0, xmm0 cvtsi2sd xmm0, r13d divsd xmm0, cs:qword_461C8 mulsd xmm0, cs:qword_461D0 call _floor addsd xmm0, cs:qword_461D8 cvttsd2si eax, xmm0 mov [rbx+r15], al mov rax, r14 mul r12 inc r15 mov rsi, r14 sub rsi, rdx shr rsi, 1 add rsi, rdx shr rsi, 1Dh mov rax, rsi shl rax, 1Eh sub rsi, rax add rsi, r14 cmp r15, 8 jnz loc_43F7A lea eax, [r13+r13*2+0] add esi, eax lea rax, [rsi+rsi*4] shr rax, 20h mov ecx, esi sub ecx, eax shr ecx, 1 add ecx, eax shr ecx, 1Dh mov eax, ecx shl eax, 1Eh sub ecx, eax add ecx, esi xorps xmm0, xmm0 cvtsi2sd xmm0, ecx divsd xmm0, cs:qword_461C8 mulsd xmm0, cs:qword_461D0 call _floor cvttsd2si eax, xmm0 movd xmm0, eax punpcklbw xmm0, xmm0 pshuflw xmm0, xmm0, 0 movq xmm1, qword ptr [rbx] pxor xmm1, xmm0 movq qword ptr [rbx], xmm1 add rbx, r15 loc_4406F: mov byte ptr [rbx], 0 mov rax, rbx add rsp, 28h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
__m128i * ma_scramble_323(__m128i *a1, unsigned __int8 *a2, unsigned __int8 *a3) { __m128i *v3; // rbx unsigned int v5; // eax unsigned long long v6; // r13 unsigned long long v7; // rsi long long i; // r15 __m128i v9; // xmm0 long long v11[2]; // [rsp+0h] [rbp-50h] BYREF long long v12[8]; // [rsp+10h] [rbp-40h] BYREF v3 = a1; if ( a3 && *a3 ) { v5 = strlen(a3); ma_hash_password(v11, a3, v5); ma_hash_password(v12, a2, 8LL); v6 = (v11[0] ^ v12[0]) % 0x3FFFFFFFuLL; v7 = (v11[1] ^ v12[1]) % 0x3FFFFFFFuLL; for ( i = 0LL; i != 8; ++i ) { v6 = (v7 + 3 * v6) % 0x3FFFFFFF; a1->m128i_i8[i] = (int)(floor((double)(int)v6 / 1073741823.0 * 31.0) + 64.0); v7 = (v7 + v6 + 33) % 0x3FFFFFFF; } v9 = _mm_cvtsi32_si128((int)floor((double)((3 * (int)v6 + (int)v7) % 0x3FFFFFFFu) / 1073741823.0 * 31.0)); a1->m128i_i64[0] = _mm_xor_si128(_mm_loadl_epi64(a1), _mm_shufflelo_epi16(_mm_unpacklo_epi8(v9, v9), 0)).m128i_u64[0]; v3 = (__m128i *)&a1->m128i_u64[1]; } v3->m128i_i8[0] = 0; return v3; }
ma_scramble_323: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x28 MOV RBX,RDI TEST RDX,RDX JZ 0x0014406f MOV R15,RDX CMP byte ptr [RDX],0x0 JZ 0x0014406f MOV R14,RSI MOV RDI,R15 CALL 0x001141c0 MOV EDX,EAX LEA R12,[RBP + -0x50] MOV RDI,R12 MOV RSI,R15 CALL 0x00143cc0 LEA R15,[RBP + -0x40] MOV EDX,0x8 MOV RDI,R15 MOV RSI,R14 CALL 0x00143cc0 MOV RSI,qword ptr [R15] MOV RCX,qword ptr [R15 + 0x8] XOR RSI,qword ptr [R12] XOR RCX,qword ptr [R12 + 0x8] MOV R12,0x400000011 MOV RAX,RSI MUL R12 MOV R13,RSI SUB R13,RDX SHR R13,0x1 ADD R13,RDX SHR R13,0x1d MOV RAX,R13 SHL RAX,0x1e SUB R13,RAX ADD R13,RSI MOV RAX,RCX MUL R12 MOV RSI,RCX SUB RSI,RDX SHR RSI,0x1 ADD RSI,RDX SHR RSI,0x1d MOV RAX,RSI SHL RAX,0x1e SUB RSI,RAX ADD RSI,RCX XOR R15D,R15D LAB_00143f7a: LEA RCX,[R13*0x2] ADD RCX,R13 ADD RCX,RSI MOV RAX,RCX MUL R12 MOV R13,RCX SUB R13,RDX SHR R13,0x1 ADD R13,RDX SHR R13,0x1d MOV RAX,R13 SHL RAX,0x1e SUB R13,RAX ADD R13,RCX LEA R14,[RSI + R13*0x1] ADD R14,0x21 XORPS XMM0,XMM0 CVTSI2SD XMM0,R13D DIVSD XMM0,qword ptr [0x001461c8] MULSD XMM0,qword ptr [0x001461d0] CALL 0x001147b0 ADDSD XMM0,qword ptr [0x001461d8] CVTTSD2SI EAX,XMM0 MOV byte ptr [RBX + R15*0x1],AL MOV RAX,R14 MUL R12 INC R15 MOV RSI,R14 SUB RSI,RDX SHR RSI,0x1 ADD RSI,RDX SHR RSI,0x1d MOV RAX,RSI SHL RAX,0x1e SUB RSI,RAX ADD RSI,R14 CMP R15,0x8 JNZ 0x00143f7a LEA EAX,[R13 + R13*0x2] ADD ESI,EAX LEA RAX,[RSI + RSI*0x4] SHR RAX,0x20 MOV ECX,ESI SUB ECX,EAX SHR ECX,0x1 ADD ECX,EAX SHR ECX,0x1d MOV EAX,ECX SHL EAX,0x1e SUB ECX,EAX ADD ECX,ESI XORPS XMM0,XMM0 CVTSI2SD XMM0,ECX DIVSD XMM0,qword ptr [0x001461c8] MULSD XMM0,qword ptr [0x001461d0] CALL 0x001147b0 CVTTSD2SI EAX,XMM0 MOVD XMM0,EAX PUNPCKLBW XMM0,XMM0 PSHUFLW XMM0,XMM0,0x0 MOVQ XMM1,qword ptr [RBX] PXOR XMM1,XMM0 MOVQ qword ptr [RBX],XMM1 ADD RBX,R15 LAB_0014406f: MOV byte ptr [RBX],0x0 MOV RAX,RBX ADD RSP,0x28 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */ ulong * ma_scramble_323(ulong *param_1,int8 param_2,char *param_3) { int iVar1; size_t sVar2; ulong uVar3; ulong uVar4; long lVar5; int1 uVar8; int1 uVar9; int1 uVar10; double dVar6; int1 auVar7 [16]; ulong local_58; ulong local_50; ulong local_48; ulong local_40; if ((param_3 != (char *)0x0) && (*param_3 != '\0')) { sVar2 = strlen(param_3); ma_hash_password(&local_58,param_3,sVar2 & 0xffffffff); ma_hash_password(&local_48,param_2,8); uVar4 = (local_48 ^ local_58) % 0x3fffffff; uVar3 = (local_40 ^ local_50) % 0x3fffffff; lVar5 = 0; do { uVar4 = (uVar4 * 3 + uVar3) % 0x3fffffff; dVar6 = floor(((double)(int)uVar4 / _DAT_001461c8) * _DAT_001461d0); *(char *)((long)param_1 + lVar5) = (char)(int)(dVar6 + _DAT_001461d8); lVar5 = lVar5 + 1; uVar3 = (uVar3 + uVar4 + 0x21) % 0x3fffffff; } while (lVar5 != 8); dVar6 = floor(((double)((uint)((int)uVar3 + (int)uVar4 * 3) % 0x3fffffff) / _DAT_001461c8) * _DAT_001461d0); iVar1 = (int)dVar6; uVar10 = (int1)((uint)iVar1 >> 0x18); uVar9 = (int1)((uint)iVar1 >> 0x10); uVar8 = (int1)((uint)iVar1 >> 8); auVar7._4_4_ = (int)(CONCAT35(CONCAT21(CONCAT11(uVar10,uVar10),uVar9),CONCAT14(uVar9,iVar1)) >> 0x20); auVar7[3] = uVar8; auVar7[2] = uVar8; auVar7[0] = (int1)iVar1; auVar7[1] = auVar7[0]; auVar7._8_8_ = 0; auVar7 = pshuflw(auVar7,auVar7,0); *param_1 = *param_1 ^ auVar7._0_8_; param_1 = param_1 + 1; } *(int1 *)param_1 = 0; return param_1; }
3,595
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>::get_token_string() const
monkey531[P]llama/common/json.hpp
std::string get_token_string() const { // escape control characters std::string result; for (const auto c : token_string) { if (static_cast<unsigned char>(c) <= '\x1F') { // escape control characters std::array<char, 9> cs{{}}; static_cast<void>((std::snprintf)(cs.data(), cs.size(), "<U+%.4X>", static_cast<unsigned char>(c))); // NOLINT(cppcoreguidelines-pro-type-vararg,hicpp-vararg) result += cs.data(); } else { // add character as is result.push_back(static_cast<std::string::value_type>(c)); } } return result; }
O2
cpp
nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char>>, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>>>::get_token_string() const: pushq %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x18, %rsp movq %rdi, %rbx leaq 0x10(%rdi), %rax movq %rax, (%rdi) andq $0x0, 0x8(%rdi) movb $0x0, 0x10(%rdi) movq 0x38(%rsi), %r13 movq 0x40(%rsi), %rbp leaq 0x718be(%rip), %r14 # 0xbd0c8 leaq 0x8(%rsp), %r15 pushq $0x9 popq %r12 cmpq %rbp, %r13 je 0x4b85a movzbl (%r13), %ecx cmpl $0x1f, %ecx ja 0x4b84a movb $0x0, 0x10(%rsp) andq $0x0, 0x8(%rsp) movq %r15, %rdi movq %r12, %rsi movq %r14, %rdx xorl %eax, %eax callq 0x24e50 movq %rbx, %rdi movq %r15, %rsi callq 0x251b0 jmp 0x4b855 movsbl %cl, %esi movq %rbx, %rdi callq 0x24790 incq %r13 jmp 0x4b813 movq %rbx, %rax addq $0x18, %rsp popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq jmp 0x4b86e movq %rax, %r14 movq %rbx, %rdi callq 0x25298 movq %r14, %rdi callq 0x25010 nop
_ZNK8nlohmann16json_abi_v3_11_36detail5lexerINS0_10basic_jsonINS0_11ordered_mapESt6vectorNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEblmdSaNS0_14adl_serializerES5_IhSaIhEEvEENS1_22iterator_input_adapterIN9__gnu_cxx17__normal_iteratorIPKcSB_EEEEE16get_token_stringEv: push rbp push r15 push r14 push r13 push r12 push rbx sub rsp, 18h mov rbx, rdi lea rax, [rdi+10h] mov [rdi], rax and qword ptr [rdi+8], 0 mov byte ptr [rdi+10h], 0 mov r13, [rsi+38h] mov rbp, [rsi+40h] lea r14, aU4x; "<U+%.4X>" lea r15, [rsp+48h+var_40] push 9 pop r12 loc_4B813: cmp r13, rbp jz short loc_4B85A movzx ecx, byte ptr [r13+0] cmp ecx, 1Fh ja short loc_4B84A mov [rsp+48h+var_38], 0 and [rsp+48h+var_40], 0 mov rdi, r15 mov rsi, r12 mov rdx, r14 xor eax, eax call _snprintf mov rdi, rbx mov rsi, r15 call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE6appendEPKc; std::string::append(char const*) jmp short loc_4B855 loc_4B84A: movsx esi, cl mov rdi, rbx call __ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE9push_backEc; std::string::push_back(char) loc_4B855: inc r13 jmp short loc_4B813 loc_4B85A: mov rax, rbx add rsp, 18h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn jmp short $+2 loc_4B86E: mov r14, rax mov rdi, rbx; void * call _ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev; std::string::~string() mov rdi, r14 call __Unwind_Resume
long long nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::string,bool,long,unsigned long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned char>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*,std::string>>>::get_token_string( long long a1, long long a2) { unsigned __int8 *v2; // r13 unsigned __int8 *v3; // rbp unsigned int v4; // ecx long long v6; // [rsp+8h] [rbp-40h] BYREF char v7; // [rsp+10h] [rbp-38h] *(_QWORD *)a1 = a1 + 16; *(_QWORD *)(a1 + 8) = 0LL; *(_BYTE *)(a1 + 16) = 0; v2 = *(unsigned __int8 **)(a2 + 56); v3 = *(unsigned __int8 **)(a2 + 64); while ( v2 != v3 ) { v4 = *v2; if ( v4 > 0x1F ) { std::string::push_back(a1, (unsigned int)(char)v4); } else { v7 = 0; v6 = 0LL; snprintf(&v6, 9LL, "<U+%.4X>", v4); std::string::append(a1, &v6); } ++v2; } return a1; }
get_token_string: PUSH RBP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x18 MOV RBX,RDI LEA RAX,[RDI + 0x10] MOV qword ptr [RDI],RAX AND qword ptr [RDI + 0x8],0x0 MOV byte ptr [RDI + 0x10],0x0 MOV R13,qword ptr [RSI + 0x38] MOV RBP,qword ptr [RSI + 0x40] LEA R14,[0x1bd0c8] LEA R15,[RSP + 0x8] PUSH 0x9 POP R12 LAB_0014b813: CMP R13,RBP JZ 0x0014b85a MOVZX ECX,byte ptr [R13] CMP ECX,0x1f JA 0x0014b84a MOV byte ptr [RSP + 0x10],0x0 AND qword ptr [RSP + 0x8],0x0 MOV RDI,R15 MOV RSI,R12 MOV RDX,R14 XOR EAX,EAX CALL 0x00124e50 LAB_0014b83d: MOV RDI,RBX MOV RSI,R15 CALL 0x001251b0 JMP 0x0014b855 LAB_0014b84a: MOVSX ESI,CL MOV RDI,RBX CALL 0x00124790 LAB_0014b855: INC R13 JMP 0x0014b813 LAB_0014b85a: MOV RAX,RBX ADD RSP,0x18 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
/* nlohmann::json_abi_v3_11_3::detail::lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map, std::vector, std::__cxx11::string, bool, long, unsigned long, double, std::allocator, nlohmann::json_abi_v3_11_3::adl_serializer, std::vector<unsigned char, std::allocator<unsigned char> >, void>, nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char const*, std::__cxx11::string > > >::get_token_string() const */ void nlohmann::json_abi_v3_11_3::detail:: lexer<nlohmann::json_abi_v3_11_3::basic_json<nlohmann::json_abi_v3_11_3::ordered_map,std::vector,std::__cxx11::string,bool,long,unsigned_long,double,std::allocator,nlohmann::json_abi_v3_11_3::adl_serializer,std::vector<unsigned_char,std::allocator<unsigned_char>>,void>,nlohmann::json_abi_v3_11_3::detail::iterator_input_adapter<__gnu_cxx::__normal_iterator<char_const*,std::__cxx11::string>>> ::get_token_string(void) { byte *pbVar1; long in_RSI; long *in_RDI; byte *pbVar2; char local_40 [16]; *in_RDI = (long)(in_RDI + 2); in_RDI[1] = 0; *(int1 *)(in_RDI + 2) = 0; pbVar1 = *(byte **)(in_RSI + 0x40); for (pbVar2 = *(byte **)(in_RSI + 0x38); pbVar2 != pbVar1; pbVar2 = pbVar2 + 1) { if (*pbVar2 < 0x20) { local_40[8] = 0; local_40[0] = '\0'; local_40[1] = '\0'; local_40[2] = '\0'; local_40[3] = '\0'; local_40[4] = '\0'; local_40[5] = '\0'; local_40[6] = '\0'; local_40[7] = '\0'; snprintf(local_40,9,"<U+%.4X>"); /* try { // try from 0014b83d to 0014b847 has its CatchHandler @ 0014b86e */ std::__cxx11::string::append((char *)in_RDI); } else { /* try { // try from 0014b84a to 0014b854 has its CatchHandler @ 0014b86c */ std::__cxx11::string::push_back((char)in_RDI); } } return; }
3,596
LefDefParser::lefiLayer::addAcCutarea()
Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefiLayer.cpp
void lefiLayer::addAcCutarea() { lefiLayerDensity *density; density = accurrents_[numAccurrents_ - 1]; density->addCutarea(numNums_, nums_); numNums_ = 0; numAllocated_ = 0; nums_ = 0; }
O3
cpp
LefDefParser::lefiLayer::addAcCutarea(): movq 0x380(%rdi), %rax movslq 0x378(%rdi), %rcx movq -0x8(%rax,%rcx,8), %rax movl 0x398(%rdi), %ecx movq 0x3a0(%rdi), %rdx movl %ecx, 0x40(%rax) movq %rdx, 0x48(%rax) xorps %xmm0, %xmm0 movups %xmm0, 0x398(%rdi) retq
_ZN12LefDefParser9lefiLayer12addAcCutareaEv: mov rax, [rdi+380h] movsxd rcx, dword ptr [rdi+378h] mov rax, [rax+rcx*8-8] mov ecx, [rdi+398h] mov rdx, [rdi+3A0h] mov [rax+40h], ecx mov [rax+48h], rdx xorps xmm0, xmm0 movups xmmword ptr [rdi+398h], xmm0 retn
long long LefDefParser::lefiLayer::addAcCutarea(LefDefParser::lefiLayer *this) { long long result; // rax long long v2; // rdx result = *(_QWORD *)(*((_QWORD *)this + 112) + 8LL * *((int *)this + 222) - 8); v2 = *((_QWORD *)this + 116); *(_DWORD *)(result + 64) = *((_DWORD *)this + 230); *(_QWORD *)(result + 72) = v2; *(_OWORD *)((char *)this + 920) = 0LL; return result; }
addAcCutarea: MOV RAX,qword ptr [RDI + 0x380] MOVSXD RCX,dword ptr [RDI + 0x378] MOV RAX,qword ptr [RAX + RCX*0x8 + -0x8] MOV ECX,dword ptr [RDI + 0x398] MOV RDX,qword ptr [RDI + 0x3a0] MOV dword ptr [RAX + 0x40],ECX MOV qword ptr [RAX + 0x48],RDX XORPS XMM0,XMM0 MOVUPS xmmword ptr [RDI + 0x398],XMM0 RET
/* LefDefParser::lefiLayer::addAcCutarea() */ void __thiscall LefDefParser::lefiLayer::addAcCutarea(lefiLayer *this) { long lVar1; int8 uVar2; lVar1 = *(long *)(*(long *)(this + 0x380) + -8 + (long)*(int *)(this + 0x378) * 8); uVar2 = *(int8 *)(this + 0x3a0); *(int4 *)(lVar1 + 0x40) = *(int4 *)(this + 0x398); *(int8 *)(lVar1 + 0x48) = uVar2; *(int8 *)(this + 0x398) = 0; *(int8 *)(this + 0x3a0) = 0; return; }
3,597
rtree_fill_reinsert_list
eloqsql/storage/myisam/rt_index.c
static int rtree_fill_reinsert_list(stPageList *ReinsertList, my_off_t page, int level) { DBUG_ENTER("rtree_fill_reinsert_list"); DBUG_PRINT("rtree", ("page: %lu level: %d", (ulong) page, level)); if (ReinsertList->n_pages == ReinsertList->m_pages) { ReinsertList->m_pages += REINSERT_BUFFER_INC; if (!(ReinsertList->pages = (stPageLevel*) my_realloc(mi_key_memory_stPageList_pages, (uchar*)ReinsertList->pages, ReinsertList->m_pages * sizeof(stPageLevel), MYF(MY_ALLOW_ZERO_PTR)))) goto err1; } /* save page to ReinsertList */ ReinsertList->pages[ReinsertList->n_pages].offs = page; ReinsertList->pages[ReinsertList->n_pages].level = level; ReinsertList->n_pages++; DBUG_RETURN(0); err1: DBUG_RETURN(-1); /* purecov: inspected */ }
O0
c
rtree_fill_reinsert_list: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movl %edx, -0x1c(%rbp) jmp 0xcac75 movq -0x10(%rbp), %rax movq (%rax), %rax movq -0x10(%rbp), %rcx cmpq 0x8(%rcx), %rax jne 0xcaccf movq -0x10(%rbp), %rax movq 0x8(%rax), %rcx addq $0xa, %rcx movq %rcx, 0x8(%rax) leaq 0xbafa37(%rip), %rax # 0xc7a6d4 movl (%rax), %edi movq -0x10(%rbp), %rax movq 0x10(%rax), %rsi movq -0x10(%rbp), %rax movq 0x8(%rax), %rdx shlq $0x4, %rdx movl $0x40, %ecx callq 0xf3bc0 movq -0x10(%rbp), %rcx movq %rax, 0x10(%rcx) cmpq $0x0, %rax jne 0xcaccd jmp 0xcad1f jmp 0xcaccf movq -0x18(%rbp), %rcx movq -0x10(%rbp), %rax movq 0x10(%rax), %rax movq -0x10(%rbp), %rdx movq (%rdx), %rdx shlq $0x4, %rdx addq %rdx, %rax movq %rcx, 0x8(%rax) movl -0x1c(%rbp), %ecx movq -0x10(%rbp), %rax movq 0x10(%rax), %rax movq -0x10(%rbp), %rdx movq (%rdx), %rdx shlq $0x4, %rdx addq %rdx, %rax movl %ecx, (%rax) movq -0x10(%rbp), %rax movq (%rax), %rcx addq $0x1, %rcx movq %rcx, (%rax) movl $0x0, -0x4(%rbp) jmp 0xcad28 jmp 0xcad21 movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF movl -0x4(%rbp), %eax addq $0x20, %rsp popq %rbp retq nopw %cs:(%rax,%rax) nopl (%rax,%rax)
rtree_fill_reinsert_list: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov [rbp+var_1C], edx jmp short $+2 loc_CAC75: mov rax, [rbp+var_10] mov rax, [rax] mov rcx, [rbp+var_10] cmp rax, [rcx+8] jnz short loc_CACCF mov rax, [rbp+var_10] mov rcx, [rax+8] add rcx, 0Ah mov [rax+8], rcx lea rax, mi_key_memory_stPageList_pages mov edi, [rax] mov rax, [rbp+var_10] mov rsi, [rax+10h] mov rax, [rbp+var_10] mov rdx, [rax+8] shl rdx, 4 mov ecx, 40h ; '@' call my_realloc mov rcx, [rbp+var_10] mov [rcx+10h], rax cmp rax, 0 jnz short loc_CACCD jmp short loc_CAD1F loc_CACCD: jmp short $+2 loc_CACCF: mov rcx, [rbp+var_18] mov rax, [rbp+var_10] mov rax, [rax+10h] mov rdx, [rbp+var_10] mov rdx, [rdx] shl rdx, 4 add rax, rdx mov [rax+8], rcx mov ecx, [rbp+var_1C] mov rax, [rbp+var_10] mov rax, [rax+10h] mov rdx, [rbp+var_10] mov rdx, [rdx] shl rdx, 4 add rax, rdx mov [rax], ecx mov rax, [rbp+var_10] mov rcx, [rax] add rcx, 1 mov [rax], rcx mov [rbp+var_4], 0 jmp short loc_CAD28 loc_CAD1F: jmp short $+2 loc_CAD21: mov [rbp+var_4], 0FFFFFFFFh loc_CAD28: mov eax, [rbp+var_4] add rsp, 20h pop rbp retn
long long rtree_fill_reinsert_list(_QWORD *a1, long long a2, int a3) { long long v3; // rax if ( *a1 == a1[1] && (a1[1] += 10LL, v3 = my_realloc(mi_key_memory_stPageList_pages, a1[2], 16LL * a1[1], 64LL), (a1[2] = v3) == 0LL) ) { return (unsigned int)-1; } else { *(_QWORD *)(16LL * *a1 + a1[2] + 8) = a2; *(_DWORD *)(16LL * (*a1)++ + a1[2]) = a3; return 0; } }
rtree_fill_reinsert_list: PUSH RBP MOV RBP,RSP SUB RSP,0x20 MOV qword ptr [RBP + -0x10],RDI MOV qword ptr [RBP + -0x18],RSI MOV dword ptr [RBP + -0x1c],EDX JMP 0x001cac75 LAB_001cac75: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX] MOV RCX,qword ptr [RBP + -0x10] CMP RAX,qword ptr [RCX + 0x8] JNZ 0x001caccf MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX + 0x8] ADD RCX,0xa MOV qword ptr [RAX + 0x8],RCX LEA RAX,[0xd7a6d4] MOV EDI,dword ptr [RAX] MOV RAX,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RAX + 0x10] MOV RAX,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RAX + 0x8] SHL RDX,0x4 MOV ECX,0x40 CALL 0x001f3bc0 MOV RCX,qword ptr [RBP + -0x10] MOV qword ptr [RCX + 0x10],RAX CMP RAX,0x0 JNZ 0x001caccd JMP 0x001cad1f LAB_001caccd: JMP 0x001caccf LAB_001caccf: MOV RCX,qword ptr [RBP + -0x18] MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x10] MOV RDX,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RDX] SHL RDX,0x4 ADD RAX,RDX MOV qword ptr [RAX + 0x8],RCX MOV ECX,dword ptr [RBP + -0x1c] MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x10] MOV RDX,qword ptr [RBP + -0x10] MOV RDX,qword ptr [RDX] SHL RDX,0x4 ADD RAX,RDX MOV dword ptr [RAX],ECX MOV RAX,qword ptr [RBP + -0x10] MOV RCX,qword ptr [RAX] ADD RCX,0x1 MOV qword ptr [RAX],RCX MOV dword ptr [RBP + -0x4],0x0 JMP 0x001cad28 LAB_001cad1f: JMP 0x001cad21 LAB_001cad21: MOV dword ptr [RBP + -0x4],0xffffffff LAB_001cad28: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x20 POP RBP RET
int4 rtree_fill_reinsert_list(long *param_1,int8 param_2,int4 param_3) { long lVar1; if (*param_1 == param_1[1]) { param_1[1] = param_1[1] + 10; lVar1 = my_realloc(mi_key_memory_stPageList_pages,param_1[2],param_1[1] << 4,0x40); param_1[2] = lVar1; if (lVar1 == 0) { return 0xffffffff; } } *(int8 *)(param_1[2] + *param_1 * 0x10 + 8) = param_2; *(int4 *)(param_1[2] + *param_1 * 0x10) = param_3; *param_1 = *param_1 + 1; return 0; }
3,598
mi_ft_parserecord
eloqsql/storage/myisam/ft_update.c
FT_WORD *_mi_ft_parserecord(MI_INFO *info, uint keynr, const uchar *record, MEM_ROOT *mem_root) { TREE ptree; MYSQL_FTPARSER_PARAM *param; DBUG_ENTER("_mi_ft_parserecord"); if (! (param= ftparser_call_initializer(info, keynr, 0))) DBUG_RETURN(NULL); bzero((char*) &ptree, sizeof(ptree)); param->flags= 0; if (_mi_ft_parse(&ptree, info, keynr, record, param, mem_root)) DBUG_RETURN(NULL); DBUG_RETURN(ft_linearize(&ptree, mem_root)); }
O3
c
mi_ft_parserecord: pushq %rbp movq %rsp, %rbp pushq %r15 pushq %r14 pushq %r13 pushq %r12 pushq %rbx subq $0x2a8, %rsp # imm = 0x2A8 movq %rcx, -0x30(%rbp) movq %rdx, %r15 movl %esi, %r12d movq %rdi, %r13 xorl %r14d, %r14d xorl %edx, %edx callq 0x432cd testq %rax, %rax je 0x439b4 movq %rax, %rbx leaq -0x2c8(%rbp), %rdi xorl %r14d, %r14d movl $0x298, %edx # imm = 0x298 xorl %esi, %esi callq 0x281d0 movl $0x0, 0x34(%rbx) leaq -0x2c8(%rbp), %rdi movq %r13, %rsi movl %r12d, %edx movq %r15, %rcx movq %rbx, %r8 movq -0x30(%rbp), %rbx movq %rbx, %r9 callq 0x43862 testl %eax, %eax jne 0x439b4 leaq -0x2c8(%rbp), %rdi movq %rbx, %rsi callq 0x42abc movq %rax, %r14 movq %r14, %rax addq $0x2a8, %rsp # imm = 0x2A8 popq %rbx popq %r12 popq %r13 popq %r14 popq %r15 popq %rbp retq
_mi_ft_parserecord: push rbp mov rbp, rsp push r15 push r14 push r13 push r12 push rbx sub rsp, 2A8h mov [rbp+var_30], rcx mov r15, rdx mov r12d, esi mov r13, rdi xor r14d, r14d xor edx, edx call ftparser_call_initializer test rax, rax jz short loc_439B4 mov rbx, rax lea rdi, [rbp+var_2C8] xor r14d, r14d mov edx, 298h xor esi, esi call _memset mov dword ptr [rbx+34h], 0 lea rdi, [rbp+var_2C8] mov rsi, r13 mov edx, r12d mov rcx, r15 mov r8, rbx mov rbx, [rbp+var_30] mov r9, rbx call _mi_ft_parse test eax, eax jnz short loc_439B4 lea rdi, [rbp+var_2C8] mov rsi, rbx call ft_linearize mov r14, rax loc_439B4: mov rax, r14 add rsp, 2A8h pop rbx pop r12 pop r13 pop r14 pop r15 pop rbp retn
_QWORD * mi_ft_parserecord(_QWORD *a1, unsigned int a2, long long a3, long long a4) { long long v5; // r14 long long v6; // rax long long v7; // rbx long long v8; // r8 long long v9; // rbx _QWORD v11[83]; // [rsp+8h] [rbp-2C8h] BYREF long long v12; // [rsp+2A0h] [rbp-30h] v12 = a4; v5 = 0LL; v6 = ftparser_call_initializer(a1, a2, 0); if ( v6 ) { v7 = v6; v5 = 0LL; memset(v11, 0LL, sizeof(v11)); *(_DWORD *)(v7 + 52) = 0; v8 = v7; v9 = v12; if ( !(unsigned int)mi_ft_parse(v11, (long long)a1, a2, a3, v8, v12) ) return ft_linearize((long long)v11, v9); } return (_QWORD *)v5; }
_mi_ft_parserecord: PUSH RBP MOV RBP,RSP PUSH R15 PUSH R14 PUSH R13 PUSH R12 PUSH RBX SUB RSP,0x2a8 MOV qword ptr [RBP + -0x30],RCX MOV R15,RDX MOV R12D,ESI MOV R13,RDI XOR R14D,R14D XOR EDX,EDX CALL 0x001432cd TEST RAX,RAX JZ 0x001439b4 MOV RBX,RAX LEA RDI,[RBP + -0x2c8] XOR R14D,R14D MOV EDX,0x298 XOR ESI,ESI CALL 0x001281d0 MOV dword ptr [RBX + 0x34],0x0 LEA RDI,[RBP + -0x2c8] MOV RSI,R13 MOV EDX,R12D MOV RCX,R15 MOV R8,RBX MOV RBX,qword ptr [RBP + -0x30] MOV R9,RBX CALL 0x00143862 TEST EAX,EAX JNZ 0x001439b4 LEA RDI,[RBP + -0x2c8] MOV RSI,RBX CALL 0x00142abc MOV R14,RAX LAB_001439b4: MOV RAX,R14 ADD RSP,0x2a8 POP RBX POP R12 POP R13 POP R14 POP R15 POP RBP RET
int8 _mi_ft_parserecord(int8 param_1,ulong param_2,int8 param_3,int8 param_4) { int8 uVar1; int iVar2; long lVar3; int8 uVar4; int1 local_2d0 [664]; int8 local_38; uVar4 = 0; local_38 = param_4; lVar3 = ftparser_call_initializer(param_1,param_2,0); if (lVar3 != 0) { uVar4 = 0; memset(local_2d0,0,0x298); uVar1 = local_38; *(int4 *)(lVar3 + 0x34) = 0; iVar2 = _mi_ft_parse(local_2d0,param_1,param_2 & 0xffffffff,param_3,lVar3,local_38); if (iVar2 == 0) { uVar4 = ft_linearize(local_2d0,uVar1); } } return uVar4; }
3,599
translog_read_next_record_header
eloqsql/storage/maria/ma_loghandler.c
int translog_read_next_record_header(TRANSLOG_SCANNER_DATA *scanner, TRANSLOG_HEADER_BUFFER *buff) { translog_size_t res; DBUG_ENTER("translog_read_next_record_header"); buff->groups_no= 0; /* to be sure that we will free it right */ DBUG_PRINT("enter", ("scanner: %p", scanner)); DBUG_PRINT("info", ("Scanner: Cur: " LSN_FMT " Hrz: " LSN_FMT " " "Lst: " LSN_FMT " Offset: %u(%x) fixed: %d", LSN_IN_PARTS(scanner->page_addr), LSN_IN_PARTS(scanner->horizon), LSN_IN_PARTS(scanner->last_file_page), (uint) scanner->page_offset, (uint) scanner->page_offset, scanner->fixed_horizon)); DBUG_ASSERT(translog_status == TRANSLOG_OK || translog_status == TRANSLOG_READONLY); do { if (translog_get_next_chunk(scanner)) DBUG_RETURN(RECHEADER_READ_ERROR); if (scanner->page == END_OF_LOG) { DBUG_PRINT("info", ("End of file from the scanner")); /* Last record was read */ buff->lsn= LSN_IMPOSSIBLE; DBUG_RETURN(RECHEADER_READ_EOF); } DBUG_PRINT("info", ("Page: " LSN_FMT " offset: %lu byte: %x", LSN_IN_PARTS(scanner->page_addr), (ulong) scanner->page_offset, (uint) scanner->page[scanner->page_offset])); } while (!translog_is_LSN_chunk(scanner->page[scanner->page_offset]) && scanner->page[scanner->page_offset] != TRANSLOG_FILLER); if (scanner->page[scanner->page_offset] == TRANSLOG_FILLER) { DBUG_PRINT("info", ("End of file")); /* Last record was read */ buff->lsn= LSN_IMPOSSIBLE; /* Return 'end of log' marker */ res= RECHEADER_READ_EOF; } else res= translog_read_record_header_scan(scanner, buff, 0); DBUG_RETURN(res); }
O0
c
translog_read_next_record_header: pushq %rbp movq %rsp, %rbp subq $0x20, %rsp movq %rdi, -0x10(%rbp) movq %rsi, -0x18(%rbp) movq -0x18(%rbp), %rax movl $0x0, 0x418(%rax) jmp 0x55960 jmp 0x55962 jmp 0x55964 jmp 0x55966 jmp 0x55968 jmp 0x5596a movq -0x10(%rbp), %rdi callq 0x52e30 cmpb $0x0, %al je 0x55985 jmp 0x55979 movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF jmp 0x55a65 movq -0x10(%rbp), %rax leaq 0xc24950(%rip), %rcx # 0xc7a2e0 cmpq %rcx, 0x2018(%rax) jne 0x559b4 jmp 0x5599b jmp 0x5599d movq -0x18(%rbp), %rax movq $0x0, (%rax) movl $0xfffffffe, -0x4(%rbp) # imm = 0xFFFFFFFE jmp 0x55a65 jmp 0x559b6 jmp 0x559b8 jmp 0x559ba movq -0x10(%rbp), %rax movq 0x2018(%rax), %rax movq -0x10(%rbp), %rcx movl 0x2028(%rcx), %ecx movzbl (%rax,%rcx), %edi callq 0x52dd0 movb %al, %cl xorl %eax, %eax cmpb $0x0, %cl movb %al, -0x1d(%rbp) jne 0x55a08 movq -0x10(%rbp), %rax movq 0x2018(%rax), %rax movq -0x10(%rbp), %rcx movl 0x2028(%rcx), %ecx movzbl (%rax,%rcx), %eax cmpl $0xff, %eax setne %al movb %al, -0x1d(%rbp) movb -0x1d(%rbp), %al testb $0x1, %al jne 0x5596a movq -0x10(%rbp), %rax movq 0x2018(%rax), %rax movq -0x10(%rbp), %rcx movl 0x2028(%rcx), %ecx movzbl (%rax,%rcx), %eax cmpl $0xff, %eax jne 0x55a4b jmp 0x55a35 jmp 0x55a37 movq -0x18(%rbp), %rax movq $0x0, (%rax) movl $0xfffffffe, -0x1c(%rbp) # imm = 0xFFFFFFFE jmp 0x55a5d movq -0x10(%rbp), %rdi movq -0x18(%rbp), %rsi xorl %edx, %edx callq 0x55880 movl %eax, -0x1c(%rbp) jmp 0x55a5f movl -0x1c(%rbp), %eax movl %eax, -0x4(%rbp) movl -0x4(%rbp), %eax addq $0x20, %rsp popq %rbp retq nop
translog_read_next_record_header: push rbp mov rbp, rsp sub rsp, 20h mov [rbp+var_10], rdi mov [rbp+var_18], rsi mov rax, [rbp+var_18] mov dword ptr [rax+418h], 0 jmp short $+2 loc_55960: jmp short $+2 loc_55962: jmp short $+2 loc_55964: jmp short $+2 loc_55966: jmp short $+2 loc_55968: jmp short $+2 loc_5596A: mov rdi, [rbp+var_10] call translog_get_next_chunk cmp al, 0 jz short loc_55985 jmp short $+2 loc_55979: mov [rbp+var_4], 0FFFFFFFFh jmp loc_55A65 loc_55985: mov rax, [rbp+var_10] lea rcx, end_of_log cmp [rax+2018h], rcx jnz short loc_559B4 jmp short $+2 loc_5599B: jmp short $+2 loc_5599D: mov rax, [rbp+var_18] mov qword ptr [rax], 0 mov [rbp+var_4], 0FFFFFFFEh jmp loc_55A65 loc_559B4: jmp short $+2 loc_559B6: jmp short $+2 loc_559B8: jmp short $+2 loc_559BA: mov rax, [rbp+var_10] mov rax, [rax+2018h] mov rcx, [rbp+var_10] mov ecx, [rcx+2028h] movzx edi, byte ptr [rax+rcx] call translog_is_LSN_chunk mov cl, al xor eax, eax cmp cl, 0 mov [rbp+var_1D], al jnz short loc_55A08 mov rax, [rbp+var_10] mov rax, [rax+2018h] mov rcx, [rbp+var_10] mov ecx, [rcx+2028h] movzx eax, byte ptr [rax+rcx] cmp eax, 0FFh setnz al mov [rbp+var_1D], al loc_55A08: mov al, [rbp+var_1D] test al, 1 jnz loc_5596A mov rax, [rbp+var_10] mov rax, [rax+2018h] mov rcx, [rbp+var_10] mov ecx, [rcx+2028h] movzx eax, byte ptr [rax+rcx] cmp eax, 0FFh jnz short loc_55A4B jmp short $+2 loc_55A35: jmp short $+2 loc_55A37: mov rax, [rbp+var_18] mov qword ptr [rax], 0 mov [rbp+var_1C], 0FFFFFFFEh jmp short loc_55A5D loc_55A4B: mov rdi, [rbp+var_10] mov rsi, [rbp+var_18] xor edx, edx call translog_read_record_header_scan mov [rbp+var_1C], eax loc_55A5D: jmp short $+2 loc_55A5F: mov eax, [rbp+var_1C] mov [rbp+var_4], eax loc_55A65: mov eax, [rbp+var_4] add rsp, 20h pop rbp retn
long long translog_read_next_record_header(long long a1, long long a2) { bool v3; // [rsp+3h] [rbp-1Dh] *(_DWORD *)(a2 + 1048) = 0; do { if ( translog_get_next_chunk(a1) ) return (unsigned int)-1; if ( *(_UNKNOWN **)(a1 + 8216) == &end_of_log ) { *(_QWORD *)a2 = 0LL; return (unsigned int)-2; } v3 = 0; if ( !(unsigned __int8)translog_is_LSN_chunk(*(_BYTE *)(*(_QWORD *)(a1 + 8216) + *(unsigned int *)(a1 + 8232))) ) v3 = *(unsigned __int8 *)(*(_QWORD *)(a1 + 8216) + *(unsigned int *)(a1 + 8232)) != 255; } while ( v3 ); if ( *(unsigned __int8 *)(*(_QWORD *)(a1 + 8216) + *(unsigned int *)(a1 + 8232)) == 255 ) { *(_QWORD *)a2 = 0LL; return (unsigned int)-2; } else { return (unsigned int)translog_read_record_header_scan(a1, a2, 0); } }
translog_read_next_record_header: 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 + -0x18] MOV dword ptr [RAX + 0x418],0x0 JMP 0x00155960 LAB_00155960: JMP 0x00155962 LAB_00155962: JMP 0x00155964 LAB_00155964: JMP 0x00155966 LAB_00155966: JMP 0x00155968 LAB_00155968: JMP 0x0015596a LAB_0015596a: MOV RDI,qword ptr [RBP + -0x10] CALL 0x00152e30 CMP AL,0x0 JZ 0x00155985 JMP 0x00155979 LAB_00155979: MOV dword ptr [RBP + -0x4],0xffffffff JMP 0x00155a65 LAB_00155985: MOV RAX,qword ptr [RBP + -0x10] LEA RCX,[0xd7a2e0] CMP qword ptr [RAX + 0x2018],RCX JNZ 0x001559b4 JMP 0x0015599b LAB_0015599b: JMP 0x0015599d LAB_0015599d: MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX],0x0 MOV dword ptr [RBP + -0x4],0xfffffffe JMP 0x00155a65 LAB_001559b4: JMP 0x001559b6 LAB_001559b6: JMP 0x001559b8 LAB_001559b8: JMP 0x001559ba LAB_001559ba: MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x2018] MOV RCX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RCX + 0x2028] MOVZX EDI,byte ptr [RAX + RCX*0x1] CALL 0x00152dd0 MOV CL,AL XOR EAX,EAX CMP CL,0x0 MOV byte ptr [RBP + -0x1d],AL JNZ 0x00155a08 MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x2018] MOV RCX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RCX + 0x2028] MOVZX EAX,byte ptr [RAX + RCX*0x1] CMP EAX,0xff SETNZ AL MOV byte ptr [RBP + -0x1d],AL LAB_00155a08: MOV AL,byte ptr [RBP + -0x1d] TEST AL,0x1 JNZ 0x0015596a MOV RAX,qword ptr [RBP + -0x10] MOV RAX,qword ptr [RAX + 0x2018] MOV RCX,qword ptr [RBP + -0x10] MOV ECX,dword ptr [RCX + 0x2028] MOVZX EAX,byte ptr [RAX + RCX*0x1] CMP EAX,0xff JNZ 0x00155a4b JMP 0x00155a35 LAB_00155a35: JMP 0x00155a37 LAB_00155a37: MOV RAX,qword ptr [RBP + -0x18] MOV qword ptr [RAX],0x0 MOV dword ptr [RBP + -0x1c],0xfffffffe JMP 0x00155a5d LAB_00155a4b: MOV RDI,qword ptr [RBP + -0x10] MOV RSI,qword ptr [RBP + -0x18] XOR EDX,EDX CALL 0x00155880 MOV dword ptr [RBP + -0x1c],EAX LAB_00155a5d: JMP 0x00155a5f LAB_00155a5f: MOV EAX,dword ptr [RBP + -0x1c] MOV dword ptr [RBP + -0x4],EAX LAB_00155a65: MOV EAX,dword ptr [RBP + -0x4] ADD RSP,0x20 POP RBP RET
int4 translog_read_next_record_header(long param_1,int8 *param_2) { char cVar1; bool bVar2; int4 local_24; *(int4 *)(param_2 + 0x83) = 0; while( true ) { cVar1 = translog_get_next_chunk(param_1); if (cVar1 != '\0') { return 0xffffffff; } if (*(int1 **)(param_1 + 0x2018) == &end_of_log) break; cVar1 = translog_is_LSN_chunk (*(int1 *) (*(long *)(param_1 + 0x2018) + (ulong)*(uint *)(param_1 + 0x2028))); bVar2 = false; if (cVar1 == '\0') { bVar2 = *(char *)(*(long *)(param_1 + 0x2018) + (ulong)*(uint *)(param_1 + 0x2028)) != -1; } if (!bVar2) { if (*(char *)(*(long *)(param_1 + 0x2018) + (ulong)*(uint *)(param_1 + 0x2028)) == -1) { *param_2 = 0; local_24 = 0xfffffffe; } else { local_24 = translog_read_record_header_scan(param_1,param_2,0); } return local_24; } } *param_2 = 0; return 0xfffffffe; }