Decompile-Bench
Collection
Train: 2 million binary-source function pairs (condensed from 100 million). Test: HumanEval, MBPP, 60K from GitHub repos released after 2025. • 3 items • Updated • 3
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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
0 | mi_cmp_dynamic_unique | eloqsql/storage/myisam/mi_dynrec.c | int _mi_cmp_dynamic_unique(MI_INFO *info, MI_UNIQUEDEF *def,
const uchar *record, my_off_t pos)
{
uchar *rec_buff,*old_record;
int error;
DBUG_ENTER("_mi_cmp_dynamic_unique");
if (!(old_record=my_alloca(info->s->base.reclength)))
DBUG_RETURN(1);
/* Don't let the compare destroy blobs that may be i... | O0 | c | mi_cmp_dynamic_unique:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq 0x140(%rax), %rsi
xorl %edi, %edi
xorl %eax, %eax
movl %eax, %edx
callq 0xf99f0
movq %rax, -0x38(%rbp)
cmpq $0x0, %... | _mi_cmp_dynamic_unique:
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov rax, [rbp+var_10]
mov rax, [rax]
mov rsi, [rax+140h]
xor edi, edi
xor eax, eax
mov edx, eax
call my_malloc
mov ... | long long mi_cmp_dynamic_unique(char *a1, long long a2, long long a3, const char *a4)
{
unsigned int dynamic_record; // [rsp+14h] [rbp-3Ch]
const char *v6; // [rsp+18h] [rbp-38h]
long long v7; // [rsp+20h] [rbp-30h]
v6 = (const char *)my_malloc(0LL, *(_QWORD *)(*(_QWORD *)a1 + 320LL), 0LL);
if ( v6 )
{
... | _mi_cmp_dynamic_unique:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX]
MOV RSI,qword ptr [RAX + 0x140]
XOR EDI,EDI
XOR EAX,EAX
MOV EDX,EAX
CALL 0x001... |
int _mi_cmp_dynamic_unique(long *param_1,long param_2,int8 param_3,int8 param_4)
{
long lVar1;
long lVar2;
long local_50;
int local_44;
int local_c;
lVar2 = my_malloc(0,*(int8 *)(*param_1 + 0x140),0);
if (lVar2 == 0) {
local_c = 1;
}
else {
lVar1 = param_1[0x24];
if (*(int *)(*param_1... | |
1 | pcmp | eloqsql/strings/ctype-simple.c | static int pcmp(const void * f, const void * s)
{
const uni_idx *F= (const uni_idx*) f;
const uni_idx *S= (const uni_idx*) s;
int res;
if (!(res=((S->nchars)-(F->nchars))))
res=((F->uidx.from)-(S->uidx.to));
return res;
} | O3 | c | pcmp:
pushq %rbp
movq %rsp, %rbp
movl (%rsi), %eax
subl (%rdi), %eax
jne 0xbd5bd
movzwl 0x8(%rdi), %eax
movzwl 0xa(%rsi), %ecx
subl %ecx, %eax
popq %rbp
retq
nop
| pcmp:
push rbp
mov rbp, rsp
mov eax, [rsi]
sub eax, [rdi]
jnz short loc_BD5BD
movzx eax, word ptr [rdi+8]
movzx ecx, word ptr [rsi+0Ah]
sub eax, ecx
loc_BD5BD:
pop rbp
retn
| long long pcmp(long long a1, long long a2)
{
long long result; // rax
result = (unsigned int)(*(_DWORD *)a2 - *(_DWORD *)a1);
if ( *(_DWORD *)a2 == *(_DWORD *)a1 )
return *(unsigned __int16 *)(a1 + 8) - (unsigned int)*(unsigned __int16 *)(a2 + 10);
return result;
}
| pcmp:
PUSH RBP
MOV RBP,RSP
MOV EAX,dword ptr [RSI]
SUB EAX,dword ptr [RDI]
JNZ 0x001bd5bd
MOVZX EAX,word ptr [RDI + 0x8]
MOVZX ECX,word ptr [RSI + 0xa]
SUB EAX,ECX
LAB_001bd5bd:
POP RBP
RET
|
int pcmp(int *param_1,int *param_2)
{
int iVar1;
iVar1 = *param_2 - *param_1;
if (iVar1 == 0) {
iVar1 = (uint)*(ushort *)(param_1 + 2) - (uint)*(ushort *)((long)param_2 + 10);
}
return iVar1;
}
| |
2 | JS_NewTypedArray | bluesky950520[P]quickjs/quickjs.c | JSValue JS_NewTypedArray(JSContext *ctx, int argc, JSValue *argv,
JSTypedArrayEnum type)
{
if (type < JS_TYPED_ARRAY_UINT8C || type > JS_TYPED_ARRAY_FLOAT64)
return JS_ThrowRangeError(ctx, "invalid typed array type");
return js_typed_array_constructor(ctx, JS_UNDEFINED, argc, a... | O1 | c | JS_NewTypedArray:
pushq %rbx
cmpl $0xc, %ecx
jb 0x38407
leaq 0x65342(%rip), %rsi # 0x9d739
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x1fec9
movl $0x6, %edx
jmp 0x3841f
movq %rdx, %r8
addl $0x15, %ecx
movl $0x3, %edx
xorl %esi, %esi
movl %ecx, %r9d
callq 0x38424
movq %rax, %rbx
movq %rbx, %rax
popq %rbx
retq
| JS_NewTypedArray:
push rbx
cmp ecx, 0Ch
jb short loc_38407
lea rsi, aInvalidTypedAr; "invalid typed array type"
xor ebx, ebx
xor eax, eax
call JS_ThrowRangeError
mov edx, 6
jmp short loc_3841F
loc_38407:
mov r8, rdx
add ecx, 15h
mov edx, 3
xor esi, esi
mov r9d, ecx... | long long JS_NewTypedArray(
long long a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
long long a10,
long long a11,
long long a12,
long long a13,
long long a14)
{
... | JS_NewTypedArray:
PUSH RBX
CMP ECX,0xc
JC 0x00138407
LEA RSI,[0x19d739]
XOR EBX,EBX
XOR EAX,EAX
CALL 0x0011fec9
MOV EDX,0x6
JMP 0x0013841f
LAB_00138407:
MOV R8,RDX
ADD ECX,0x15
MOV EDX,0x3
XOR ESI,ESI
MOV R9D,ECX
CALL 0x00138424
MOV RBX,RAX
LAB_0013841f:
MOV RAX,RBX
POP RBX
RET
|
int8 JS_NewTypedArray(int8 param_1,int8 param_2,int8 param_3,uint param_4)
{
int8 uVar1;
if (param_4 < 0xc) {
uVar1 = js_typed_array_constructor(param_1,0,3,param_4 + 0x15,param_3,param_4 + 0x15);
}
else {
uVar1 = 0;
JS_ThrowRangeError(param_1,"invalid typed array type");
}
return uVar1;
}
... | |
3 | JS_NewTypedArray | bluesky950520[P]quickjs/quickjs.c | JSValue JS_NewTypedArray(JSContext *ctx, int argc, JSValue *argv,
JSTypedArrayEnum type)
{
if (type < JS_TYPED_ARRAY_UINT8C || type > JS_TYPED_ARRAY_FLOAT64)
return JS_ThrowRangeError(ctx, "invalid typed array type");
return js_typed_array_constructor(ctx, JS_UNDEFINED, argc, a... | O2 | c | JS_NewTypedArray:
pushq %rbx
cmpl $0xc, %ecx
jb 0x315ce
leaq 0x530d9(%rip), %rsi # 0x84699
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x1a137
pushq $0x6
popq %rdx
jmp 0x315e4
movq %rdx, %r8
addl $0x15, %ecx
pushq $0x3
popq %rdx
xorl %esi, %esi
movl %ecx, %r9d
callq 0x315e9
movq %rax, %rbx
movq %rbx, %rax
popq %rbx
retq
| JS_NewTypedArray:
push rbx
cmp ecx, 0Ch
jb short loc_315CE
lea rsi, aInvalidTypedAr_0; "invalid typed array type"
xor ebx, ebx
xor eax, eax
call JS_ThrowRangeError
push 6
pop rdx
jmp short loc_315E4
loc_315CE:
mov r8, rdx
add ecx, 15h
push 3
pop rdx
xor esi, esi
... | long long JS_NewTypedArray(
long long a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
long long a10,
long long a11,
long long a12,
long long a13,
long long a14)
{
... | JS_NewTypedArray:
PUSH RBX
CMP ECX,0xc
JC 0x001315ce
LEA RSI,[0x184699]
XOR EBX,EBX
XOR EAX,EAX
CALL 0x0011a137
PUSH 0x6
POP RDX
JMP 0x001315e4
LAB_001315ce:
MOV R8,RDX
ADD ECX,0x15
PUSH 0x3
POP RDX
XOR ESI,ESI
MOV R9D,ECX
CALL 0x001315e9
MOV RBX,RAX
LAB_001315e4:
MOV RAX,RBX
POP RBX
RET
|
int8 JS_NewTypedArray(int8 param_1,int8 param_2,int8 param_3,uint param_4)
{
int8 uVar1;
if (param_4 < 0xc) {
uVar1 = js_typed_array_constructor(param_1,0,3,param_4 + 0x15,param_3,param_4 + 0x15);
}
else {
uVar1 = 0;
JS_ThrowRangeError(param_1,"invalid typed array type");
}
return uVar1;
}
... | |
4 | JS_NewTypedArray | bluesky950520[P]quickjs/quickjs.c | JSValue JS_NewTypedArray(JSContext *ctx, int argc, JSValue *argv,
JSTypedArrayEnum type)
{
if (type < JS_TYPED_ARRAY_UINT8C || type > JS_TYPED_ARRAY_FLOAT64)
return JS_ThrowRangeError(ctx, "invalid typed array type");
return js_typed_array_constructor(ctx, JS_UNDEFINED, argc, a... | O3 | c | JS_NewTypedArray:
pushq %rbx
cmpl $0xc, %ecx
jb 0x396bb
leaq 0x6705e(%rip), %rsi # 0xa0709
xorl %ebx, %ebx
xorl %eax, %eax
callq 0x205f0
movl $0x6, %edx
jmp 0x396d3
movq %rdx, %r8
addl $0x15, %ecx
movl $0x3, %edx
xorl %esi, %esi
movl %ecx, %r9d
callq 0x396d8
movq %rax, %rbx
movq %rbx, %rax
popq %rbx
retq
| JS_NewTypedArray:
push rbx
cmp ecx, 0Ch
jb short loc_396BB
lea rsi, aInvalidTypedAr; "invalid typed array type"
xor ebx, ebx
xor eax, eax
call JS_ThrowRangeError
mov edx, 6
jmp short loc_396D3
loc_396BB:
mov r8, rdx
add ecx, 15h
mov edx, 3
xor esi, esi
mov r9d, ecx... | long long JS_NewTypedArray(
long long a1,
__m128 a2,
__m128 a3,
__m128 a4,
__m128 a5,
__m128 a6,
__m128 a7,
__m128 a8,
__m128 a9,
long long a10,
long long a11,
long long a12,
long long a13,
long long a14)
{
... | JS_NewTypedArray:
PUSH RBX
CMP ECX,0xc
JC 0x001396bb
LEA RSI,[0x1a0709]
XOR EBX,EBX
XOR EAX,EAX
CALL 0x001205f0
MOV EDX,0x6
JMP 0x001396d3
LAB_001396bb:
MOV R8,RDX
ADD ECX,0x15
MOV EDX,0x3
XOR ESI,ESI
MOV R9D,ECX
CALL 0x001396d8
MOV RBX,RAX
LAB_001396d3:
MOV RAX,RBX
POP RBX
RET
|
int8 JS_NewTypedArray(int8 param_1,int8 param_2,int8 param_3,uint param_4)
{
int8 uVar1;
if (param_4 < 0xc) {
uVar1 = js_typed_array_constructor(param_1,0,3,param_4 + 0x15,param_3,param_4 + 0x15);
}
else {
uVar1 = 0;
JS_ThrowRangeError(param_1,"invalid typed array type");
}
return uVar1;
}
... | |
5 | my_parse_charset_xml | eloqsql/strings/ctype.c | my_bool
my_parse_charset_xml(MY_CHARSET_LOADER *loader, const char *buf, size_t len)
{
MY_XML_PARSER p;
struct my_cs_file_info info;
my_bool rc;
my_charset_file_init(&info);
my_xml_parser_create(&p);
my_xml_set_enter_handler(&p,cs_enter);
my_xml_set_value_handler(&p,cs_value);
my_xml_set_leave_handle... | O3 | c | my_parse_charset_xml:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x928, %rsp # imm = 0x928
movq %rdx, %r14
movq %rsi, %r12
movq %rdi, %rbx
movq %fs:0x28, %rax
movq %rax, -0x30(%rbp)
leaq -0x260(%rbp), %r15
movl $0xc8, %edx
movq %r15, %rdi
xorl %esi, %esi
callq 0x2... | my_parse_charset_xml:
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 928h
mov r14, rdx
mov r12, rsi
mov rbx, rdi
mov rax, fs:28h
mov [rbp+var_30], rax
lea r15, [rbp+var_260]
mov edx, 0C8h
mov rdi, r15
xor esi, esi
call _memset... | bool my_parse_charset_xml(long long a1, long long a2, long long a3)
{
int v4; // r14d
long long v5; // rax
int v6; // r15d
int v7; // r12d
const char *v8; // rax
_QWORD v10[220]; // [rsp+10h] [rbp-940h] BYREF
_BYTE v11[200]; // [rsp+6F0h] [rbp-260h] BYREF
long long v12; // [rsp+7B8h] [rbp-198h]
_BYTE... | my_parse_charset_xml:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x928
MOV R14,RDX
MOV R12,RSI
MOV RBX,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x30],RAX
LEA R15,[RBP + -0x260]
MOV EDX,0xc8
MOV RDI,R15
XOR ESI,ESI
CALL 0x001261c0
XORPS XMM0,XMM0
MOVUPS xmmword ptr [R15 + -0x5... |
bool my_parse_charset_xml(long param_1,int8 param_2,int8 param_3)
{
int iVar1;
int iVar2;
int4 uVar3;
char *__s;
size_t sVar4;
int8 uVar5;
long in_FS_OFFSET;
int1 local_948 [1672];
int8 local_2c0;
int1 uStack_2b8;
int7 uStack_2b7;
int1 uStack_2b0;
int8 uStack_2af;
int1 local_268 [200];
l... | |
6 | dump_header_page | eloqsql/storage/maria/ma_loghandler.c | static void dump_header_page(uchar *buff)
{
LOGHANDLER_FILE_INFO desc;
char strbuff[21];
struct tm tmp_tm;
time_t header_time;
translog_interpret_file_header(&desc, buff);
header_time= desc.timestamp/1000000ULL;
localtime_r(&header_time, &tmp_tm);
printf(" This can be header page:\n"
" Ti... | O0 | c | dump_header_page:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0xf8, %rsp
movq %fs:0x28, %rax
movq %rax, -0x20(%rbp)
movq %rdi, -0x48(%rbp)
movq -0x48(%rbp), %rsi
leaq -0x80(%rbp), %rdi
callq 0x2f760
movq -0x78(%rbp), %rax
movl $0xf4240, %ecx # imm = 0xF4240
xorl %edx, %edx
divq %rcx
movq ... | dump_header_page:
push rbp
mov rbp, rsp
push r15
push r14
push rbx
sub rsp, 0F8h
mov rax, fs:28h
mov [rbp+var_20], rax
mov [rbp+var_48], rdi
mov rsi, [rbp+var_48]
lea rdi, [rbp+var_80]
call translog_interpret_file_header
mov rax, [rbp+var_78]
mov ecx, 0F4240h
xor e... | unsigned long long dump_header_page(long long a1)
{
int v1; // r15d
const char *v2; // rax
int v4; // [rsp+3Ch] [rbp-D4h]
int v5; // [rsp+40h] [rbp-D0h]
int v6; // [rsp+44h] [rbp-CCh]
int v7; // [rsp+48h] [rbp-C8h]
int v8; // [rsp+4Ch] [rbp-C4h]
unsigned long long v9; // [rsp+50h] [rbp-C0h] BYREF
_DW... | dump_header_page:
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH RBX
SUB RSP,0xf8
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x20],RAX
MOV qword ptr [RBP + -0x48],RDI
MOV RSI,qword ptr [RBP + -0x48]
LEA RDI,[RBP + -0x80]
CALL 0x0012f760
MOV RAX,qword ptr [RBP + -0x78]
MOV ECX,0xf4240
XOR EDX,EDX
DIV RCX
MOV qword p... |
void dump_header_page(int8 param_1)
{
int8 uVar1;
long in_FS_OFFSET;
ulong local_c8;
tm local_c0;
ulong local_88;
ulong local_80;
int8 local_78;
int8 local_70;
int8 local_68;
long local_60;
int8 local_58;
int8 local_50;
int1 local_48 [32];
long local_28;
local_28 = *(long *)(in_FS_OFF... | |
7 | LefDefParser::lefwStartArrayFloorplan(char const*) | Efficient-TDP/thirdparty/Limbo/limbo/thirdparty/lefdef/5.8/lef/lef/lefwWriter.cpp | int
lefwStartArrayFloorplan(const char *name)
{
if (!lefwFile)
return LEFW_UNINITIALIZED;
if (lefwState != LEFW_ARRAY_START &&
lefwState != LEFW_ARRAY)
return LEFW_BAD_ORDER;
if (lefwIsArrayFloorp)
return LEFW_BAD_ORDER;
if (!name || name == 0 || *name == 0)
retur... | O0 | cpp | LefDefParser::lefwStartArrayFloorplan(char const*):
subq $0x18, %rsp
movq %rdi, 0x8(%rsp)
leaq 0x9c310(%rip), %rax # 0xc5250
cmpq $0x0, (%rax)
jne 0x28f53
movl $0x1, 0x14(%rsp)
jmp 0x29034
leaq 0x9c546(%rip), %rax # 0xc54a0
cmpl $0x2, (%rax)
je 0x28f78
leaq 0x9c53a(%rip), %rax # 0xc54a0
cmpl $0x13, (%rax)
j... | _ZN12LefDefParser23lefwStartArrayFloorplanEPKc:
sub rsp, 18h
mov [rsp+18h+var_10], rdi
lea rax, _ZN12LefDefParser8lefwFileE; LefDefParser::lefwFile
cmp qword ptr [rax], 0
jnz short loc_28F53
mov [rsp+18h+var_4], 1
jmp loc_29034
loc_28F53:
lea rax, _ZN12LefDefParser9lefwStateE; LefDefPars... | long long LefDefParser::lefwStartArrayFloorplan(
LefDefParser *this,
const char *a2,
long long a3,
int a4,
int a5,
int a6)
{
if ( *(_QWORD *)&LefDefParser::lefwFile )
{
if ( LefDefParser::lefwState == 2 || LefDefParser::lefwState == 19 )
{
if ( LefDefPa... | lefwStartArrayFloorplan:
SUB RSP,0x18
MOV qword ptr [RSP + 0x8],RDI
LEA RAX,[0x1c5250]
CMP qword ptr [RAX],0x0
JNZ 0x00128f53
MOV dword ptr [RSP + 0x14],0x1
JMP 0x00129034
LAB_00128f53:
LEA RAX,[0x1c54a0]
CMP dword ptr [RAX],0x2
JZ 0x00128f78
LEA RAX,[0x1c54a0]
CMP dword ptr [RAX],0x13
JZ 0x00128f78
MOV dword ptr [RSP ... |
/* LefDefParser::lefwStartArrayFloorplan(char const*) */
int4 LefDefParser::lefwStartArrayFloorplan(char *param_1)
{
int4 local_4;
if (lefwFile == (_IO_FILE *)0x0) {
local_4 = 1;
}
else if ((lefwState == 2) || (lefwState == 0x13)) {
if (lefwIsArrayFloorp == 0) {
if (((param_1 == (char *)0x0)... | |
8 | my_mb_wc_latin1 | eloqsql/strings/ctype-latin1.c | static
int my_mb_wc_latin1(CHARSET_INFO *cs __attribute__((unused)),
my_wc_t *wc,
const uchar *str,
const uchar *end __attribute__((unused)))
{
if (str >= end)
return MY_CS_TOOSMALL;
/*
There are no unassigned characters in latin1.
Every code point in latin1 is mapped to some Unicode ... | O0 | c | my_mb_wc_latin1:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
movq -0x20(%rbp), %rax
cmpq -0x28(%rbp), %rax
jb 0x53ec7
movl $0xffffff9b, -0x4(%rbp) # imm = 0xFFFFFF9B
jmp 0x53eed
movq -0x20(%rbp), %rax
movzbl (%rax), %eax
movl %eax, %ecx
leaq 0x1... | my_mb_wc_latin1:
push rbp
mov rbp, rsp
mov [rbp+var_10], rdi
mov [rbp+var_18], rsi
mov [rbp+var_20], rdx
mov [rbp+var_28], rcx
mov rax, [rbp+var_20]
cmp rax, [rbp+var_28]
jb short loc_53EC7
mov [rbp+var_4], 0FFFFFF9Bh
jmp short loc_53EED
loc_53EC7:
mov rax, [rbp+var_20]
m... | long long my_mb_wc_latin1(long long a1, _QWORD *a2, unsigned __int8 *a3, unsigned long long a4)
{
if ( (unsigned long long)a3 < a4 )
{
*a2 = cs_to_uni[*a3];
return 1;
}
else
{
return (unsigned int)-101;
}
}
| my_mb_wc_latin1:
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x10],RDI
MOV qword ptr [RBP + -0x18],RSI
MOV qword ptr [RBP + -0x20],RDX
MOV qword ptr [RBP + -0x28],RCX
MOV RAX,qword ptr [RBP + -0x20]
CMP RAX,qword ptr [RBP + -0x28]
JC 0x00153ec7
MOV dword ptr [RBP + -0x4],0xffffff9b
JMP 0x00153eed
LAB_00153ec7:
MOV RAX,q... |
int4 my_mb_wc_latin1(int8 param_1,ulong *param_2,byte *param_3,byte *param_4)
{
int4 local_c;
if (param_3 < param_4) {
*param_2 = (ulong)*(ushort *)(cs_to_uni + (ulong)*param_3 * 2);
local_c = 1;
}
else {
local_c = 0xffffff9b;
}
return local_c;
}
| |
9 | hexlo | eloqsql/strings/ctype-utf8.c | static int hexlo(int x)
{
static const char hex_lo_digit[256]=
{
-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, /* ................ */
-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, /* ................ */
-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1, /* !"#$%&'()*+,-./ */
0, 1, 2, 3, 4, 5, ... | O0 | c | hexlo:
pushq %rbp
movq %rsp, %rbp
movl %edi, -0x4(%rbp)
movl -0x4(%rbp), %eax
movl %eax, %ecx
leaq 0x14c0dd(%rip), %rax # 0x1bb380
movsbl (%rax,%rcx), %eax
popq %rbp
retq
nopl (%rax)
| hexlo:
push rbp
mov rbp, rsp
mov [rbp+var_4], edi
mov eax, [rbp+var_4]
mov ecx, eax
lea rax, hexlo_hex_lo_digit
movsx eax, byte ptr [rax+rcx]
pop rbp
retn
| long long hexlo(int a1)
{
return (unsigned int)hexlo_hex_lo_digit[a1];
}
| hexlo:
PUSH RBP
MOV RBP,RSP
MOV dword ptr [RBP + -0x4],EDI
MOV EAX,dword ptr [RBP + -0x4]
MOV ECX,EAX
LEA RAX,[0x2bb380]
MOVSX EAX,byte ptr [RAX + RCX*0x1]
POP RBP
RET
|
int hexlo(uint param_1)
{
return (int)(char)hexlo_hex_lo_digit[param_1];
}
| |
10 | ma_close | eloqsql/libmariadb/libmariadb/ma_io.c | int ma_close(MA_FILE *file)
{
int rc;
if (!file)
return -1;
switch (file->type) {
case MA_FILE_LOCAL:
rc= fclose((FILE *)file->ptr);
free(file);
break;
#ifdef HAVE_REMOTEIO
case MA_FILE_REMOTE:
rc= rio_plugin->methods->mclose(file);
break;
#endif
default:
return -1;
}
return... | O0 | c | ma_close:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0x3799c
movl $0xffffffff, -0x4(%rbp) # imm = 0xFFFFFFFF
jmp 0x379fd
movq -0x10(%rbp), %rax
movl (%rax), %eax
movl %eax, -0x18(%rbp)
subl $0x1, %eax
je 0x379b6
jmp 0x379ac
movl -0x18(%rbp), %eax
subl $0x2, %eax
je 0x3... | ma_close:
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_10], rdi
cmp [rbp+var_10], 0
jnz short loc_3799C
mov [rbp+var_4], 0FFFFFFFFh
jmp short loc_379FD
loc_3799C:
mov rax, [rbp+var_10]
mov eax, [rax]
mov [rbp+var_18], eax
sub eax, 1
jz short loc_379B6
jmp short... | long long ma_close(long long a1)
{
unsigned int v2; // [rsp+Ch] [rbp-14h]
if ( a1 )
{
if ( *(_DWORD *)a1 == 1 )
{
v2 = fclose(*(_QWORD *)(a1 + 8));
free(a1);
}
else
{
if ( *(_DWORD *)a1 != 2 )
return (unsigned int)-1;
return (unsigned int)(*(long long ( **)(lo... | ma_close:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x10],RDI
CMP qword ptr [RBP + -0x10],0x0
JNZ 0x0013799c
MOV dword ptr [RBP + -0x4],0xffffffff
JMP 0x001379fd
LAB_0013799c:
MOV RAX,qword ptr [RBP + -0x10]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RBP + -0x18],EAX
SUB EAX,0x1
JZ 0x001379b6
JMP 0x001379ac
L... |
int ma_close(int *param_1)
{
int local_1c;
int local_c;
if (param_1 == (int *)0x0) {
local_c = -1;
}
else {
if (*param_1 == 1) {
local_1c = fclose(*(FILE **)(param_1 + 2));
free(param_1);
}
else {
if (*param_1 != 2) {
return -1;
}
local_1c = (**(code ... | |
11 | ma_mark_file_changed | eloqsql/storage/maria/ma_locking.c | int _ma_mark_file_changed(register MARIA_SHARE *share)
{
if (!share->base.born_transactional)
{
if (!_MA_ALREADY_MARKED_FILE_CHANGED)
return _ma_mark_file_changed_now(share);
}
else
{
/*
For transactional tables, the table is marked changed when the first page
is written. Here we jus... | O3 | c | ma_mark_file_changed:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
cmpb $0x0, 0x44c(%rdi)
movl 0x170(%rdi), %eax
je 0x4424b
notl %eax
testb $0x19, %al
je 0x44258
leaq 0x8f0(%rbx), %r14
cmpq $0x0, 0x930(%rbx)
jne 0x4426b
movq %r14, %rdi
callq 0x2b230
orb $0x19, 0x170(%rbx)
movq 0x930(%rbx), %rdi
test... | _ma_mark_file_changed:
push rbp
mov rbp, rsp
push r14
push rbx
mov rbx, rdi
cmp byte ptr [rdi+44Ch], 0
mov eax, [rdi+170h]
jz short loc_4424B
not eax
test al, 19h
jz short loc_44258
lea r14, [rbx+8F0h]
cmp qword ptr [rbx+930h], 0
jnz short loc_4426B
mov rdi, r14... | long long ma_mark_file_changed(long long a1)
{
int v1; // eax
v1 = *(_DWORD *)(a1 + 368);
if ( *(_BYTE *)(a1 + 1100) )
{
if ( (~(_BYTE)v1 & 0x19) != 0 )
{
if ( *(_QWORD *)(a1 + 2352) )
psi_mutex_lock(
a1 + 2288,
(long long)"/workspace/llm4binary/github2025/eloqsql/sto... | _ma_mark_file_changed:
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH RBX
MOV RBX,RDI
CMP byte ptr [RDI + 0x44c],0x0
MOV EAX,dword ptr [RDI + 0x170]
JZ 0x0014424b
NOT EAX
TEST AL,0x19
JZ 0x00144258
LEA R14,[RBX + 0x8f0]
CMP qword ptr [RBX + 0x930],0x0
JNZ 0x0014426b
MOV RDI,R14
CALL 0x0012b230
LAB_0014422e:
OR byte ptr [RBX + 0x17... |
int8 _ma_mark_file_changed(long param_1)
{
pthread_mutex_t *__mutex;
int8 uVar1;
if (*(char *)(param_1 + 0x44c) == '\0') {
if (((*(uint *)(param_1 + 0x170) & 1) == 0) || (*(char *)(param_1 + 0x7df) == '\0')) {
uVar1 = _ma_mark_file_changed_now(param_1);
return uVar1;
}
}
else if ((~*(... | |
12 | minja::Expression::evaluate(std::shared_ptr<minja::Context> const&) const | monkey531[P]llama/common/minja.hpp | Value evaluate(const std::shared_ptr<Context> & context) const {
try {
return do_evaluate(context);
} catch (const std::exception & e) {
std::ostringstream out;
out << e.what();
if (location.source) out << error_location_suffix(*location.source, location.p... | O2 | cpp | minja::Expression::evaluate(std::shared_ptr<minja::Context> const&) const:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x1a0, %rsp # imm = 0x1A0
movq %rsi, %r14
movq %rdi, %rbx
movq (%rsi), %rax
callq *(%rax)
movq %rbx, %rax
addq $0x1a0, %rsp # imm = 0x1A0
popq %rbx
popq %r14
popq %rbp
retq
movq %rax, ... | _ZNK5minja10Expression8evaluateERKSt10shared_ptrINS_7ContextEE:
push rbp
push r14
push rbx
sub rsp, 1A0h
mov r14, rsi
mov rbx, rdi
mov rax, [rsi]
call qword ptr [rax]
mov rax, rbx
add rsp, 1A0h
pop rbx
pop r14
pop rbp
retn
mov rbx, rax
cmp edx, 1
jnz loc_626CB... | long long minja::Expression::evaluate(long long a1, void (***a2)(void))
{
(**a2)();
return a1;
}
| evaluate:
PUSH RBP
PUSH R14
PUSH RBX
SUB RSP,0x1a0
MOV R14,RSI
MOV RBX,RDI
MOV RAX,qword ptr [RSI]
LAB_001625c6:
CALL qword ptr [RAX]
LAB_001625c8:
MOV RAX,RBX
ADD RSP,0x1a0
POP RBX
POP R14
POP RBP
RET
|
/* minja::Expression::evaluate(std::shared_ptr<minja::Context> const&) const */
Expression * __thiscall minja::Expression::evaluate(Expression *this,shared_ptr *param_1)
{
/* try { // try from 001625c6 to 001625c7 has its CatchHandler @ 001625d7 */
(*(code *)**(int8 **)param_1)();
return this... | |
13 | string_process_escapes(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&) | llama.cpp/common/common.cpp | void string_process_escapes(std::string & input) {
std::size_t input_len = input.length();
std::size_t output_idx = 0;
for (std::size_t input_idx = 0; input_idx < input_len; ++input_idx) {
if (input[input_idx] == '\\' && input_idx + 1 < input_len) {
switch (input[++input_idx]) {
... | O3 | cpp | string_process_escapes(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>&):
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
movq 0x8(%rdi), %r13
testq %r13, %r13
je 0xf6d2b
leaq 0xf(%rsp), %r12
xorl %r14d, %r14d
leaq 0xd(%rsp), %rdi
leaq 0x... | _Z22string_process_escapesRNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 18h
mov rbx, rdi
mov r13, [rdi+8]
test r13, r13
jz loc_F6D2B
lea r12, [rsp+48h+var_39]
xor r14d, r14d
lea rdi, [rsp+48h+var_3B... | long long string_process_escapes(long long *a1)
{
unsigned long long v1; // r13
long long v2; // r14
long long v3; // rcx
long long v4; // rax
char v5; // dl
long long v6; // rbp
unsigned int v7; // edx
long long v8; // r15
char v9; // al
_BYTE v11[2]; // [rsp+Dh] [rbp-3Bh] BYREF
char v12; // [rs... | string_process_escapes:
PUSH RBP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x18
MOV RBX,RDI
MOV R13,qword ptr [RDI + 0x8]
TEST R13,R13
JZ 0x001f6d2b
LEA R12,[RSP + 0xf]
XOR R14D,R14D
LEA RDI,[RSP + 0xd]
LEA RSI,[RSP + 0x10]
XOR ECX,ECX
LAB_001f6c0c:
MOV RAX,qword ptr [RBX]
MOV DL,byte ptr [RAX + RCX*0x1]
CMP... |
/* string_process_escapes(std::__cxx11::string&) */
void string_process_escapes(string *param_1)
{
ulong uVar1;
byte bVar2;
ulong uVar3;
long lVar4;
ulong uVar5;
long lVar6;
char local_3b;
int1 local_3a;
char local_39;
char *local_38;
uVar3 = *(ulong *)(param_1 + 8);
if (uVar3 == 0) {
... | |
14 | ftxui::StackedContainer::Render() | Andrewchistyakov[P]flashcards_lyc/build_O0/_deps/ftxui-src/src/ftxui/component/container.cpp | Element Render() final {
Elements elements;
for (auto& child : children_) {
elements.push_back(child->Render());
}
// Reverse the order of the elements.
std::reverse(elements.begin(), elements.end());
return dbox(std::move(elements));
} | O0 | cpp | ftxui::StackedContainer::Render():
pushq %rbp
movq %rsp, %rbp
subq $0xc0, %rsp
movq %rdi, -0xa8(%rbp)
movq %rdi, %rax
movq %rax, -0xa0(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x98(%rbp)
leaq -0x28(%rbp), %rdi
callq 0x24340
movq -0x98(%rbp), %rax
addq $0x8, %rax
movq %rax, -... | _ZN5ftxui16StackedContainer6RenderEv:
push rbp
mov rbp, rsp
sub rsp, 0C0h
mov [rbp+var_A8], rdi
mov rax, rdi
mov [rbp+var_A0], rax
mov [rbp+var_8], rdi
mov [rbp+var_10], rsi
mov rax, [rbp+var_10]
mov [rbp+var_98], rax
lea rdi, [rbp+var_28]
call _ZNSt6vectorISt10shared_ptrIN... | ftxui::StackedContainer * ftxui::StackedContainer::Render(ftxui::StackedContainer *this, long long a2)
{
long long v2; // rsi
long long v4[3]; // [rsp+30h] [rbp-90h] BYREF
long long v5; // [rsp+48h] [rbp-78h]
long long v6; // [rsp+50h] [rbp-70h]
_BYTE v7[16]; // [rsp+68h] [rbp-58h] BYREF
long long v8; // [r... | Render:
PUSH RBP
MOV RBP,RSP
SUB RSP,0xc0
MOV qword ptr [RBP + -0xa8],RDI
MOV RAX,RDI
MOV qword ptr [RBP + -0xa0],RAX
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RAX,qword ptr [RBP + -0x10]
MOV qword ptr [RBP + -0x98],RAX
LEA RDI,[RBP + -0x28]
CALL 0x00124340
MOV RAX,qword ptr [RBP + -0x98]
ADD R... |
/* ftxui::StackedContainer::Render() */
ftxui * ftxui::StackedContainer::Render(void)
{
bool bVar1;
long *plVar2;
long in_RSI;
ftxui *in_RDI;
vector<std::shared_ptr<ftxui::Node>,std::allocator<std::shared_ptr<ftxui::Node>>> local_98 [24];
int8 local_80;
int8 local_78;
shared_ptr<ftxui::Node> local_60... | |
15 | translog_scanner_set_last_page | eloqsql/storage/maria/ma_loghandler.c | static my_bool translog_scanner_set_last_page(TRANSLOG_SCANNER_DATA *scanner)
{
my_bool page_ok;
if (LSN_FILE_NO(scanner->page_addr) == LSN_FILE_NO(scanner->horizon))
{
/* It is last file => we can easy find last page address by horizon */
uint pagegrest= LSN_OFFSET(scanner->horizon) % TRANSLOG_PAGE_SIZE;... | O0 | c | translog_scanner_set_last_page:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq 0x2000(%rax), %rax
sarq $0x20, %rax
movq -0x10(%rbp), %rcx
movq 0x2008(%rcx), %rcx
sarq $0x20, %rcx
cmpl %ecx, %eax
jne 0x32ae0
movq -0x10(%rbp), %rcx
movabsq $0xffffffff, %rax # imm = 0x... | translog_scanner_set_last_page:
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_10], rdi
mov rax, [rbp+var_10]
mov rax, [rax+2000h]
sar rax, 20h
mov rcx, [rbp+var_10]
mov rcx, [rcx+2008h]
sar rcx, 20h
cmp eax, ecx
jnz short loc_32AE0
mov rcx, [rbp+var_10]
mov rax, ... | char translog_scanner_set_last_page(_QWORD *a1)
{
unsigned int v2; // [rsp+Ch] [rbp-24h]
bool v3; // [rsp+1Fh] [rbp-11h] BYREF
_QWORD *v4; // [rsp+20h] [rbp-10h]
v4 = a1;
if ( HIDWORD(a1[1024]) == HIDWORD(a1[1025]) )
{
if ( (v4[1025] & 0x1FFF) != 0 )
v2 = v4[1025] & 0x1FFF;
else
v2 = 0... | translog_scanner_set_last_page:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x10],RDI
MOV RAX,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RAX + 0x2000]
SAR RAX,0x20
MOV RCX,qword ptr [RBP + -0x10]
MOV RCX,qword ptr [RCX + 0x2008]
SAR RCX,0x20
CMP EAX,ECX
JNZ 0x00132ae0
MOV RCX,qword ptr [RBP + -0x10]
MOV RAX... |
int1 translog_scanner_set_last_page(long param_1)
{
uint local_2c;
int1 local_19;
long local_18;
int1 local_9;
if ((int)((ulong)*(int8 *)(param_1 + 0x2000) >> 0x20) ==
(int)((ulong)*(int8 *)(param_1 + 0x2008) >> 0x20)) {
local_2c = (uint)*(ulong *)(param_1 + 0x2008) & 0x1fff;
if ((*(ulong *... | |
16 | usage | eloqsql/client/mysql_plugin.c | static void usage(void)
{
PRINT_VERSION;
puts("Copyright (c) 2011, 2015, Oracle and/or its affiliates. "
"All rights reserved.\n");
puts("Enable or disable plugins.");
printf("\nUsage: %s [options] <plugin> ENABLE|DISABLE\n\nOptions:\n",
my_progname);
my_print_help(my_long_options);
puts("\n");
... | O0 | c | usage:
pushq %rbp
movq %rsp, %rbp
jmp 0x26a56
leaq 0x36a723(%rip), %rax # 0x391180
movq (%rax), %rsi
leaq 0x5b981(%rip), %rdi # 0x823e8
leaq 0x5b991(%rip), %rdx # 0x823ff
leaq 0x5b990(%rip), %rcx # 0x82405
movb $0x0, %al
callq 0x25050
leaq 0x5ba45(%rip), %rdi # 0x824c8
callq 0x255a0
leaq 0x5ba87(%rip... | usage:
push rbp
mov rbp, rsp
jmp short $+2
loc_26A56:
lea rax, my_progname
mov rsi, [rax]
lea rdi, aSVerSDistribS; "%s Ver %s Distrib %s\n"
lea rdx, a100; "1.0.0"
lea rcx, a10610Mariadb; "10.6.10-MariaDB"
mov al, 0
call _printf
lea rdi, aCopyrightC2011; "Copyright (c) 2011, 20... | long long usage()
{
printf("%s Ver %s Distrib %s\n", my_progname, "1.0.0", "10.6.10-MariaDB");
puts("Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.\n");
puts("Enable or disable plugins.");
printf("\nUsage: %s [options] <plugin> ENABLE|DISABLE\n\nOptions:\n", my_progname);
my_pri... | usage:
PUSH RBP
MOV RBP,RSP
JMP 0x00126a56
LAB_00126a56:
LEA RAX,[0x491180]
MOV RSI,qword ptr [RAX]
LEA RDI,[0x1823e8]
LEA RDX,[0x1823ff]
LEA RCX,[0x182405]
MOV AL,0x0
CALL 0x00125050
LEA RDI,[0x1824c8]
CALL 0x001255a0
LEA RDI,[0x182516]
CALL 0x001255a0
LEA RAX,[0x491180]
MOV RSI,qword ptr [RAX]
LEA RDI,[0x182531]
MOV ... |
void usage(void)
{
printf("%s Ver %s Distrib %s\n",my_progname,&DAT_001823ff,"10.6.10-MariaDB");
puts("Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.\n");
puts("Enable or disable plugins.");
printf("\nUsage: %s [options] <plugin> ENABLE|DISABLE\n\nOptions:\n",my_progname);
my_... | |
17 | usage | eloqsql/client/mysql_plugin.c | static void usage(void)
{
PRINT_VERSION;
puts("Copyright (c) 2011, 2015, Oracle and/or its affiliates. "
"All rights reserved.\n");
puts("Enable or disable plugins.");
printf("\nUsage: %s [options] <plugin> ENABLE|DISABLE\n\nOptions:\n",
my_progname);
my_print_help(my_long_options);
puts("\n");
... | O3 | c | usage:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
leaq 0x346e81(%rip), %rbx # 0x36d590
movq (%rbx), %rdx
leaq 0x3ac63(%rip), %rsi # 0x6137c
leaq 0x3ac73(%rip), %rcx # 0x61393
leaq 0x3ac72(%rip), %r8 # 0x61399
movl $0x1, %edi
xorl %eax, %eax
callq 0x24030
leaq 0x3ad22(%rip), %rdi # 0x6145c
call... | usage:
push rbp
mov rbp, rsp
push rbx
push rax
lea rbx, my_progname
mov rdx, [rbx]
lea rsi, aSVerSDistribS; "%s Ver %s Distrib %s\n"
lea rcx, a100; "1.0.0"
lea r8, a10610Mariadb; "10.6.10-MariaDB"
mov edi, 1
xor eax, eax
call ___printf_chk
lea rdi, aCopyrightC2011; "Copy... | long long usage()
{
__printf_chk(1LL, "%s Ver %s Distrib %s\n", my_progname, "1.0.0", "10.6.10-MariaDB");
puts("Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.\n");
puts("Enable or disable plugins.");
__printf_chk(1LL, "\nUsage: %s [options] <plugin> ENABLE|DISABLE\n\nOptions:\n", ... | usage:
PUSH RBP
MOV RBP,RSP
PUSH RBX
PUSH RAX
LEA RBX,[0x46d590]
MOV RDX,qword ptr [RBX]
LEA RSI,[0x16137c]
LEA RCX,[0x161393]
LEA R8,[0x161399]
MOV EDI,0x1
XOR EAX,EAX
CALL 0x00124030
LEA RDI,[0x16145c]
CALL 0x001245f0
LEA RDI,[0x1614aa]
CALL 0x001245f0
MOV RDX,qword ptr [RBX]
LEA RSI,[0x1614c5]
MOV EDI,0x1
XOR EAX,EA... |
void usage(void)
{
__printf_chk(1,"%s Ver %s Distrib %s\n",my_progname,&DAT_00161393,"10.6.10-MariaDB");
puts("Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved.\n");
puts("Enable or disable plugins.");
__printf_chk(1,"\nUsage: %s [options] <plugin> ENABLE|DISABLE\n\nOptions:\n",my_... | |
18 | minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const | monkey531[P]llama/common/minja.hpp | Value do_evaluate(const std::shared_ptr<Context> & context) const override {
if (!left) throw std::runtime_error("BinaryOpExpr.left is null");
if (!right) throw std::runtime_error("BinaryOpExpr.right is null");
auto l = left->evaluate(context);
auto do_eval = [&](const Value & l) -> Val... | O2 | cpp | minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0xe8, %rsp
movq %rsi, %r15
movq 0x20(%rsi), %rsi
testq %rsi, %rsi
je 0x70b1d
cmpq $0x0, 0x30(%r15)
je 0x70b39
movq %rdx, %r14
movq %rdi, %rbx
leaq 0x38(%rsp), %r12
movq %r12, %rdi
callq 0x63... | _ZNK5minja12BinaryOpExpr11do_evaluateERKSt10shared_ptrINS_7ContextEE:
push r15
push r14
push r12
push rbx
sub rsp, 0E8h
mov r15, rsi
mov rsi, [rsi+20h]
test rsi, rsi
jz loc_70B1D
cmp qword ptr [r15+30h], 0
jz loc_70B39
mov r14, rdx
mov rbx, rdi
lea r12, [rsp+108h+var... | minja::Value * minja::BinaryOpExpr::do_evaluate(minja::Value *this, long long a2, long long a3)
{
void (***v4)(void); // rsi
int v6; // edx
int v7; // ecx
int v8; // r8d
int v9; // r9d
std::runtime_error *exception; // r14
__int128 v12; // [rsp+8h] [rbp-100h]
_BYTE v13[32]; // [rsp+18h] [rbp-F0h] BYREF
... | do_evaluate:
PUSH R15
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0xe8
MOV R15,RSI
MOV RSI,qword ptr [RSI + 0x20]
TEST RSI,RSI
JZ 0x00170b1d
CMP qword ptr [R15 + 0x30],0x0
JZ 0x00170b39
MOV R14,RDX
MOV RBX,RDI
LEA R12,[RSP + 0x38]
MOV RDI,R12
CALL 0x00163f0a
MOV qword ptr [RSP + 0x8],R15
MOV qword ptr [RSP + 0x10],R14
CMP qword... |
/* minja::BinaryOpExpr::do_evaluate(std::shared_ptr<minja::Context> const&) const */
shared_ptr * minja::BinaryOpExpr::do_evaluate(shared_ptr *param_1)
{
runtime_error *this;
int8 in_RDX;
long in_RSI;
long local_100;
int8 uStack_f8;
_lambda_std__shared_ptr<minja::Context>_const__minja__ArgumentsValue___1... | |
19 | int10_to_str | eloqsql/strings/int2str.c | char *int10_to_str(long int val,char *dst,int radix)
{
char buffer[65];
register char *p;
long int new_val;
unsigned long int uval = (unsigned long int) val;
if (radix < 0) /* -10 */
{
if (val < 0)
{
*dst++ = '-';
/* Avoid integer overflow in (-val) for LONGLONG_MIN (BUG#31799). */
... | O0 | c | int10_to_str:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %fs:0x28, %rax
movq %rax, -0x8(%rbp)
movq %rdi, -0x58(%rbp)
movq %rsi, -0x60(%rbp)
movl %edx, -0x64(%rbp)
movq -0x58(%rbp), %rax
movq %rax, -0x80(%rbp)
cmpl $0x0, -0x64(%rbp)
jge 0x798c6
cmpq $0x0, -0x58(%rbp)
jge 0x798c4
movq -0x60(%rbp), %rax
movq %rax, %... | int10_to_str:
push rbp
mov rbp, rsp
sub rsp, 90h
mov rax, fs:28h
mov [rbp+var_8], rax
mov [rbp+var_58], rdi
mov [rbp+var_60], rsi
mov [rbp+var_64], edx
mov rax, [rbp+var_58]
mov [rbp+var_80], rax
cmp [rbp+var_64], 0
jge short loc_798C6
cmp [rbp+var_58], 0
jge short... | _BYTE * int10_to_str(long long a1, _BYTE *a2, int a3)
{
_BYTE *v3; // rax
_BYTE *v4; // rax
_BYTE *v5; // rcx
unsigned long long v7; // [rsp+10h] [rbp-80h]
_BYTE *v8; // [rsp+20h] [rbp-70h]
_BYTE *v9; // [rsp+30h] [rbp-60h]
signed long long i; // [rsp+38h] [rbp-58h]
_BYTE v11[9]; // [rsp+7Fh] [rbp-11h] ... | int10_to_str:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x90
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
MOV qword ptr [RBP + -0x58],RDI
MOV qword ptr [RBP + -0x60],RSI
MOV dword ptr [RBP + -0x64],EDX
MOV RAX,qword ptr [RBP + -0x58]
MOV qword ptr [RBP + -0x80],RAX
CMP dword ptr [RBP + -0x64],0x0
JGE 0x001798c6
CMP qw... |
char * int10_to_str(ulong param_1,char *param_2,int param_3)
{
char cVar1;
char *pcVar2;
long in_FS_OFFSET;
ulong local_88;
char *local_78;
char *local_68;
ulong local_60;
char local_1a [10];
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
local_88 = param_1;
local_68 = param_2;
... | |
20 | ma_init_alloc_root | eloqsql/libmariadb/libmariadb/ma_alloc.c | void ma_init_alloc_root(MA_MEM_ROOT *mem_root, size_t block_size, size_t pre_alloc_size)
{
mem_root->free= mem_root->used= mem_root->pre_alloc= 0;
mem_root->min_malloc=32;
mem_root->block_size= (block_size-MALLOC_OVERHEAD-sizeof(MA_USED_MEM)+8);
mem_root->error_handler=0;
mem_root->block_num= 4;
mem_root->f... | O0 | c | ma_init_alloc_root:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq $0x0, 0x10(%rax)
movq -0x8(%rbp), %rax
movq $0x0, 0x8(%rax)
movq -0x8(%rbp), %rax
movq $0x0, (%rax)
movq -0x8(%rbp), %rax
movq $0x20, 0x18(%rax)
movq -0x10(%rbp)... | ma_init_alloc_root:
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 qword ptr [rax+10h], 0
mov rax, [rbp+var_8]
mov qword ptr [rax+8], 0
mov rax, [rbp+var_8]
mov qword ptr [rax], 0
mov rax, [r... | long long ma_init_alloc_root(long long *a1, long long a2, long long a3)
{
long long result; // rax
a1[2] = 0LL;
a1[1] = 0LL;
*a1 = 0LL;
a1[3] = 32LL;
a1[4] = a2 - 32 + 8;
a1[6] = 0LL;
*((_DWORD *)a1 + 10) = 4;
result = (long long)a1;
*((_DWORD *)a1 + 11) = 0;
if ( a3 )
{
result = malloc(a3... | ma_init_alloc_root:
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 qword ptr [RAX + 0x10],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RAX + 0x8],0x0
MOV RAX,qword ptr [RBP + -0x8]
MOV qword ptr [RA... |
void ma_init_alloc_root(long *param_1,long param_2,long param_3)
{
void *pvVar1;
param_1[2] = 0;
param_1[1] = 0;
*param_1 = 0;
param_1[3] = 0x20;
param_1[4] = param_2 + -0x18;
param_1[6] = 0;
*(int4 *)(param_1 + 5) = 4;
*(int4 *)((long)param_1 + 0x2c) = 0;
if (param_3 != 0) {
pvVar1 = mallo... | |
21 | my_coll_parser_scan_rule | eloqsql/strings/ctype-uca.c | static int
my_coll_parser_scan_rule(MY_COLL_RULE_PARSER *p)
{
if (!my_coll_parser_scan_term(p, MY_COLL_LEXEM_RESET) ||
!my_coll_parser_scan_reset_sequence(p))
return 0;
/* Scan the first required shift command */
if (!my_coll_parser_scan_shift(p))
return my_coll_parser_expected_error(p, MY_COLL_LEX... | O0 | c | my_coll_parser_scan_rule:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x10(%rbp)
movq -0x10(%rbp), %rdi
movl $0x4, %esi
callq 0x9eb80
cmpl $0x0, %eax
je 0x9eafd
movq -0x10(%rbp), %rdi
callq 0x9ede0
cmpl $0x0, %eax
jne 0x9eb06
movl $0x0, -0x4(%rbp)
jmp 0x9eb6e
movq -0x10(%rbp), %rdi
callq 0x9ee90
cmpl $0x0, ... | my_coll_parser_scan_rule:
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_10], rdi
mov rdi, [rbp+var_10]
mov esi, 4
call my_coll_parser_scan_term
cmp eax, 0
jz short loc_9EAFD
mov rdi, [rbp+var_10]
call my_coll_parser_scan_reset_sequence
cmp eax, 0
jnz short loc_9EB06
l... | long long my_coll_parser_scan_rule(long long a1)
{
if ( (unsigned int)my_coll_parser_scan_term(a1, 4LL) && (unsigned int)my_coll_parser_scan_reset_sequence(a1) )
{
if ( (unsigned int)my_coll_parser_scan_shift(a1) )
{
if ( (unsigned int)my_coll_parser_scan_shift_sequence(a1) )
{
while ( ... | my_coll_parser_scan_rule:
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x10],RDI
MOV RDI,qword ptr [RBP + -0x10]
MOV ESI,0x4
CALL 0x0019eb80
CMP EAX,0x0
JZ 0x0019eafd
MOV RDI,qword ptr [RBP + -0x10]
CALL 0x0019ede0
CMP EAX,0x0
JNZ 0x0019eb06
LAB_0019eafd:
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0019eb6e
LAB_001... |
int4 my_coll_parser_scan_rule(int8 param_1)
{
int iVar1;
int4 local_c;
iVar1 = my_coll_parser_scan_term(param_1,4);
if ((iVar1 == 0) || (iVar1 = my_coll_parser_scan_reset_sequence(param_1), iVar1 == 0)) {
local_c = 0;
}
else {
iVar1 = my_coll_parser_scan_shift(param_1);
if (iVar1 == 0) {
... | |
22 | ggml_compute_forward_diag_mask_f32 | monkey531[P]llama/ggml/src/ggml-cpu/ggml-cpu.c | static void ggml_compute_forward_diag_mask_f32(
const struct ggml_compute_params * params,
struct ggml_tensor * dst,
const float value) {
const struct ggml_tensor * src0 = dst->src[0];
const int ith = params->ith;
const int nth = params->nth;
const int n_past = ((int32_t *) ... | O0 | c | ggml_compute_forward_diag_mask_f32:
subq $0x68, %rsp
movq %rdi, 0x60(%rsp)
movq %rsi, 0x58(%rsp)
vmovss %xmm0, 0x54(%rsp)
movq 0x58(%rsp), %rax
movq 0x98(%rax), %rax
movq %rax, 0x48(%rsp)
movq 0x60(%rsp), %rax
movl (%rax), %eax
movl %eax, 0x44(%rsp)
movq 0x60(%rsp), %rax
movl 0x4(%rax), %eax
movl %eax, 0x40(%rsp)
movq ... | ggml_compute_forward_diag_mask_f32:
sub rsp, 68h
mov [rsp+68h+var_8], rdi
mov [rsp+68h+var_10], rsi
vmovss [rsp+68h+var_14], xmm0
mov rax, [rsp+68h+var_10]
mov rax, [rax+98h]
mov [rsp+68h+var_20], rax
mov rax, [rsp+68h+var_8]
mov eax, [rax]
mov [rsp+68h+var_24], eax
mov rax, [rs... | long long ggml_compute_forward_diag_mask_f32(int *a1, long long a2, __m128 _XMM0)
{
long long v3; // rax
long long result; // rax
long long v8; // [rsp+0h] [rbp-68h]
long long v9; // [rsp+8h] [rbp-60h]
long long v10; // [rsp+10h] [rbp-58h]
int k; // [rsp+1Ch] [rbp-4Ch]
int j; // [rsp+20h] [rbp-48h]
int... | ggml_compute_forward_diag_mask_f32:
SUB RSP,0x68
MOV qword ptr [RSP + 0x60],RDI
MOV qword ptr [RSP + 0x58],RSI
VMOVSS dword ptr [RSP + 0x54],XMM0
MOV RAX,qword ptr [RSP + 0x58]
MOV RAX,qword ptr [RAX + 0x98]
MOV qword ptr [RSP + 0x48],RAX
MOV RAX,qword ptr [RSP + 0x60]
MOV EAX,dword ptr [RAX]
MOV dword ptr [RSP + 0x44]... |
void ggml_compute_forward_diag_mask_f32(int4 param_1,int *param_2,long param_3)
{
int iVar1;
int iVar2;
int iVar3;
long lVar4;
void *__dest;
void *__src;
int8 uVar5;
int iVar6;
int iVar7;
long lVar8;
long lVar9;
ulong uVar10;
size_t __n;
int local_4c;
int local_48;
int local_44;
l... | |
23 | ggml_numa_init | 7CodeWizard[P]stablediffusion/ggml/src/ggml.c | void ggml_numa_init(void) {
if (g_state.numa.n_nodes > 0) {
fprintf(stderr, "ggml_numa_init: NUMA already initialized\n");
return;
}
#ifdef __linux__
struct stat st;
char path[256];
int rv;
// enumerate nodes
while (g_state.numa.n_nodes < GGML_NUMA_MAX_NODES) {
rv ... | O0 | c | ggml_numa_init:
subq $0x1e8, %rsp # imm = 0x1E8
cmpl $0x0, 0x1455a2(%rip) # 0x25ffa0
jbe 0x11aa1d
movq 0xbd5a1(%rip), %rax # 0x1d7fa8
movq (%rax), %rdi
leaq 0x6ecca(%rip), %rsi # 0x1896db
movb $0x0, %al
callq 0xbae0
jmp 0x11ad63
jmp 0x11aa1f
cmpl $0x8, 0x14557a(%rip) # 0x25ffa0
jae 0x11aad4
lea... | ggml_numa_init:
sub rsp, 1E8h
cmp cs:dword_25FFA0, 0
jbe short loc_11AA1D
mov rax, cs:stderr_ptr
mov rdi, [rax]
lea rsi, aGgmlNumaInitNu; "ggml_numa_init: NUMA already initialize"...
mov al, 0
call _fprintf
jmp loc_11AD63
loc_11AA1D:
jmp short $+2
loc_11AA1F:
cmp cs:dword_25FF... | void ggml_numa_init()
{
long long v0; // rdi
long long v1; // rdi
long long v2; // rdi
unsigned int v3; // edx
char *v4; // rax
int v5; // ecx
_BYTE v6[48]; // [rsp+0h] [rbp-1E8h] BYREF
long long v7; // [rsp+30h] [rbp-1B8h]
unsigned int j; // [rsp+3Ch] [rbp-1ACh]
char *v9; // [rsp+40h] [rbp-1A8h]
... | |||
24 | ggml_numa_init | 7CodeWizard[P]stablediffusion/ggml/src/ggml.c | void ggml_numa_init(void) {
if (g_state.numa.n_nodes > 0) {
fprintf(stderr, "ggml_numa_init: NUMA already initialized\n");
return;
}
#ifdef __linux__
struct stat st;
char path[256];
int rv;
// enumerate nodes
while (g_state.numa.n_nodes < GGML_NUMA_MAX_NODES) {
rv ... | O1 | c | ggml_numa_init:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1c8, %rsp # imm = 0x1C8
cmpl $0x0, 0xf04f7(%rip) # 0x17e270
jne 0x8df9c
movl 0xf04eb(%rip), %ecx # 0x17e270
cmpl $0x7, %ecx
ja 0x8dddf
leaq 0x37dac(%rip), %rbx # 0xc5b3d
leaq 0xc0(%rsp), %r14
leaq 0x30(%rsp)... | ggml_numa_init:
push rbp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 1C8h
cmp cs:dword_17E270, 0
jnz loc_8DF9C
mov ecx, cs:dword_17E270
cmp ecx, 7
ja short loc_8DDDF
lea rbx, aSysDevicesSyst_0; "/sys/devices/system/node/node%u"
lea r14, [rsp+1F8h+var_138]
lea... | long long ggml_numa_init()
{
unsigned int i; // ecx
long long result; // rax
unsigned int v2; // ecx
unsigned long long v3; // r12
unsigned int v4; // ebp
long long v5; // rax
long long v6; // rbx
unsigned __int16 v7; // [rsp+0h] [rbp-1F8h] BYREF
unsigned __int8 v8; // [rsp+2h] [rbp-1F6h]
_BYTE v9[1... |
This is the evaluation benchmark of LLM4Decompile project.
It contains three splits, huameval, mbpp, and github2025. We also provide a json verison for the data. They contains the following columns:
{
"index":"index of the function",
"func_name":"demangled name for he function",
"func_dep":"function dependecies (includes, help functions), or the path to the source code",
"func":"source code",
"test":"unit tests for the function, empty for github data",
"opt":"optimization, O0, O1, O2, O3",
"language":"language, c or cpp",
"asm":"assembly",
"ida_asm":"assembly from ida pro",
"ida_pseudo":"decompiled results (pseudo code) from ida pro",
"ghidra_asm":"assembly from ghidra",
"ghidra_pseudo":"decompiled results (pseudo code) from ghidra"
}
For more details, please check LLM4Decompile project.