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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
5,182 | func0 |
#include <stdio.h>
#include <assert.h>
#include <limits.h>
| int* func0(int list1[], int size, int *resultSize) {
int min_val = INT_MAX;
static int min_positions[100]; // static buffer to store positions
int count = 0;
// Find minimum value
for (int i = 0; i < size; i++) {
if (list1[i] < min_val) {
min_val = list1[i];
}
... | int main() {
int resultSize;
int* result;
int list1[] = {12,33,23,10,67,89,45,667,23,12,11,10,54};
int list2[] = {1,2,2,2,4,4,4,5,5,5,5};
int list3[] = {2,1,5,6,8,3,4,9,10,11,8,12};
result = func0(list1, sizeof(list1)/sizeof(list1[0]), &resultSize);
assert(resultSize == 2 && result[... | O2 | c | func0:
endbr64
test %esi,%esi
jle 1520 <func0+0x70>
lea -0x1(%rsi),%r9d
mov %rdi,%rax
mov $0x7fffffff,%ecx
lea 0x4(%rdi,%r9,4),%r8
nopl 0x0(%rax)
mov (%rax),%esi
cmp %esi,%ecx
cmovg %esi,%ecx
add $0x4,%rax
cmp %r8,%rax
jne 14d0 <func0+0x20>
xor %eax,%eax
xor %r8d,%r8d
lea 0x2... | func0:
endbr64
mov r8, rdi
test esi, esi
jle short loc_1410
lea ecx, [rsi-1]
mov rax, rdi
lea r9, [rdi+rcx*4+4]
mov ecx, 7FFFFFFFh
nop dword ptr [rax+rax+00h]
loc_13D0:
mov edi, [rax]
cmp ecx, edi
cmovg ecx, edi
add rax, 4
cmp rax, r9
jnz short loc_13D0
mov esi, ... | _DWORD * func0(int *a1, int a2, _DWORD *a3)
{
int *v4; // rax
int v5; // ecx
long long v6; // rax
int v7; // edi
long long v8; // r9
if ( a2 <= 0 )
{
*a3 = 0;
return min_positions_1;
}
else
{
v4 = a1;
v5 = 0x7FFFFFFF;
do
{
if ( v5 > *v4 )
v5 = *v4;
++v4;
... | func0:
ENDBR64
MOV R8,RDI
TEST ESI,ESI
JLE 0x00101410
LEA ECX,[RSI + -0x1]
MOV RAX,RDI
LEA R9,[RDI + RCX*0x4 + 0x4]
MOV ECX,0x7fffffff
NOP dword ptr [RAX + RAX*0x1]
LAB_001013d0:
MOV EDI,dword ptr [RAX]
CMP ECX,EDI
CMOVG ECX,EDI
ADD RAX,0x4
CMP RAX,R9
JNZ 0x001013d0
MOV ESI,ESI
XOR EAX,EAX
LEA R10,[0x104040]
XOR EDI,ED... | int4 * func0(int *param_1,uint param_2,int *param_3)
{
int *piVar1;
ulong uVar2;
int iVar3;
int iVar4;
long lVar5;
if (0 < (int)param_2) {
iVar3 = 0x7fffffff;
piVar1 = param_1;
do {
if (*piVar1 < iVar3) {
iVar3 = *piVar1;
}
piVar1 = piVar1 + 1;
} while (piVar1 !... |
5,183 | func0 |
#include <stdio.h>
#include <assert.h>
#include <limits.h>
| int* func0(int list1[], int size, int *resultSize) {
int min_val = INT_MAX;
static int min_positions[100]; // static buffer to store positions
int count = 0;
// Find minimum value
for (int i = 0; i < size; i++) {
if (list1[i] < min_val) {
min_val = list1[i];
}
... | int main() {
int resultSize;
int* result;
int list1[] = {12,33,23,10,67,89,45,667,23,12,11,10,54};
int list2[] = {1,2,2,2,4,4,4,5,5,5,5};
int list3[] = {2,1,5,6,8,3,4,9,10,11,8,12};
result = func0(list1, sizeof(list1)/sizeof(list1[0]), &resultSize);
assert(resultSize == 2 && result[... | O3 | c | func0:
endbr64
test %esi,%esi
jle 1730 <func0+0x120>
lea -0x1(%rsi),%r8d
cmp $0x2,%r8d
jbe 173e <func0+0x12e>
mov %esi,%ecx
movdqa 0xabc(%rip),%xmm0
mov %rdi,%rax
shr $0x2,%ecx
shl $0x4,%rcx
add %rdi,%rcx
nopl 0x0(%rax)
movdqu (%rax),%xmm1
movdqu (%rax),%xmm3
add $0x10,%rax
pcmpgtd %xm... | func0:
endbr64
movsxd rcx, esi
mov r10, rdx
test ecx, ecx
jle loc_1290
lea eax, [rcx-1]
cmp eax, 2
jbe loc_12A0
mov edx, ecx
movdqa xmm0, cs:xmmword_2020
mov rax, rdi
shr edx, 2
shl rdx, 4
add rdx, rdi
nop dword ptr [rax]
loc_11B8:
movdqu xmm1, xmmword ptr [rax]
movdqu ... | long long * func0(const __m128i *a1, int a2, _DWORD *a3)
{
long long v3; // rcx
__m128i si128; // xmm0
const __m128i *v6; // rax
__m128i v7; // xmm1
__m128i v8; // xmm3
__m128i v9; // xmm1
__m128i v10; // xmm2
signed int v11; // eax
__m128i v12; // xmm1
__m128i v13; // xmm0
__m128i v14; // xmm2
... | func0:
ENDBR64
MOVSXD RCX,ESI
MOV R10,RDX
TEST ECX,ECX
JLE 0x00101290
LEA EAX,[RCX + -0x1]
CMP EAX,0x2
JBE 0x001012a0
MOV EDX,ECX
MOVDQA XMM0,xmmword ptr [0x00102020]
MOV RAX,RDI
SHR EDX,0x2
SHL RDX,0x4
ADD RDX,RDI
NOP dword ptr [RAX]
LAB_001011b8:
MOVDQU XMM1,xmmword ptr [RAX]
MOVDQU XMM3,xmmword ptr [RAX]
ADD RAX,0x1... | /* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
int4 * func0(uint *param_1,uint param_2,int *param_3)
{
uint *puVar1;
uint *puVar2;
uint *puVar3;
uint uVar4;
uint *puVar5;
uint *puVar6;
uint *puVar7;
uint uVar8;
uint *puVar9;
ulong uVar10;
uint uVar11;
int ... |
5,184 | func0 |
#include <assert.h>
void right_rotate(int arr[], int n, int out_of_place, int cur) {
int temp = arr[cur];
for (int i = cur; i > out_of_place; --i) {
arr[i] = arr[i - 1];
}
arr[out_of_place] = temp;
}
| void func0(int arr[], int n) {
int out_of_place = -1;
for (int index = 0; index < n; ++index) {
if (out_of_place >= 0) {
if ((arr[index] >= 0 && arr[out_of_place] < 0) ||
(arr[index] < 0 && arr[out_of_place] >= 0)) {
right_rotate(arr, n, out_of_place, i... | int main() {
int arr1[] = {-5, -2, 5, 2, 4, 7, 1, 8, 0, -8};
int arr1_result[] = {-5, 5, -2, 2, -8, 4, 7, 1, 8, 0};
func0(arr1, 10);
for (int i = 0; i < 10; i++) {
assert(arr1[i] == arr1_result[i]);
}
int arr2[] = {1, 2, 3, -4, -1, 4};
int arr2_result[] = {-4, 1, -1, 2, 3, ... | O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
sub $0x20,%rsp
mov %rdi,-0x18(%rbp)
mov %esi,-0x1c(%rbp)
movl $0xffffffff,-0x8(%rbp)
movl $0x0,-0x4(%rbp)
jmpq 131a <func0+0x126>
cmpl $0x0,-0x8(%rbp)
js 12b9 <func0+0xc5>
mov -0x4(%rbp),%eax
cltq
lea 0x0(,%rax,4),%rdx
mov -0x18(%rbp),%rax
add ... | func0:
endbr64
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_18], rdi
mov [rbp+var_1C], esi
mov [rbp+var_8], 0FFFFFFFFh
mov [rbp+var_4], 0
jmp loc_1320
loc_121A:
cmp [rbp+var_8], 0
js loc_12B9
mov eax, [rbp+var_4]
cdqe
lea rdx, ds:0[rax*4]
mov rax, [rbp+var_18]
add ... | long long func0(long long a1, int a2)
{
long long result; // rax
int v3; // [rsp+18h] [rbp-8h]
int i; // [rsp+1Ch] [rbp-4h]
v3 = -1;
for ( i = 0; ; ++i )
{
result = (unsigned int)i;
if ( i >= a2 )
break;
if ( v3 >= 0
&& (*(int *)(4LL * i + a1) >= 0 && *(int *)(4LL * v3 + a1) < 0
... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x18],RDI
MOV dword ptr [RBP + -0x1c],ESI
MOV dword ptr [RBP + -0x8],0xffffffff
MOV dword ptr [RBP + -0x4],0x0
JMP 0x00101320
LAB_0010121a:
CMP dword ptr [RBP + -0x8],0x0
JS 0x001012b9
MOV EAX,dword ptr [RBP + -0x4]
CDQE
LEA RDX,[RAX*0x4]
MOV RAX,qw... | void func0(long param_1,int param_2)
{
int4 local_10;
int4 local_c;
local_10 = 0xffffffff;
for (local_c = 0; (int)local_c < param_2; local_c = local_c + 1) {
if ((-1 < (int)local_10) &&
(((-1 < *(int *)(param_1 + (long)(int)local_c * 4) &&
(*(int *)(param_1 + (long)(int)local_10 * 4) < 0... |
5,185 | func0 |
#include <assert.h>
void right_rotate(int arr[], int n, int out_of_place, int cur) {
int temp = arr[cur];
for (int i = cur; i > out_of_place; --i) {
arr[i] = arr[i - 1];
}
arr[out_of_place] = temp;
}
| void func0(int arr[], int n) {
int out_of_place = -1;
for (int index = 0; index < n; ++index) {
if (out_of_place >= 0) {
if ((arr[index] >= 0 && arr[out_of_place] < 0) ||
(arr[index] < 0 && arr[out_of_place] >= 0)) {
right_rotate(arr, n, out_of_place, i... | int main() {
int arr1[] = {-5, -2, 5, 2, 4, 7, 1, 8, 0, -8};
int arr1_result[] = {-5, 5, -2, 2, -8, 4, 7, 1, 8, 0};
func0(arr1, 10);
for (int i = 0; i < 10; i++) {
assert(arr1[i] == arr1_result[i]);
}
int arr2[] = {1, 2, 3, -4, -1, 4};
int arr2_result[] = {-4, 1, -1, 2, 3, ... | O1 | c | func0:
endbr64
test %esi,%esi
jle 1275 <func0+0xca>
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x8,%rsp
mov %rdi,%r12
mov %esi,%r15d
lea -0x1(%rsi),%r14d
mov $0x0,%ebx
mov $0xffffffff,%ebp
jmp 120d <func0+0x62>
movslq %ebp,%rax
cmpl $0x0,(%r12,%rax,4)
jns ... | func0:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 8
mov [rsp+38h+var_34], esi
test esi, esi
jle loc_1261
mov r12, rdi
mov r15d, esi
mov ebx, 0
mov ebp, 0FFFFFFFFh
jmp short loc_1208
loc_11DA:
movsxd rax, ebp
cmp dword ptr [r12+rax*4],... | long long func0(long long a1, int a2)
{
long long v2; // rbx
int v3; // ebp
long long result; // rax
if ( a2 > 0 )
{
v2 = 0LL;
v3 = -1;
do
{
if ( v3 < 0 )
{
if ( v3 == -1 )
goto LABEL_6;
}
else
{
if ( *(int *)(a1 + 4 * v2) < 0 )
... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x8
MOV dword ptr [RSP + 0x4],ESI
TEST ESI,ESI
JLE 0x00101261
MOV R12,RDI
MOV R15D,ESI
MOV EBX,0x0
MOV EBP,0xffffffff
JMP 0x00101208
LAB_001011da:
MOVSXD RAX,EBP
CMP dword ptr [R12 + RAX*0x4],0x0
JNS 0x00101223
JMP 0x001011ff
LAB_001011e6:
CMP... | void func0(long param_1,uint param_2)
{
ulong uVar1;
int iVar2;
ulong uVar3;
ulong uVar4;
if (0 < (int)param_2) {
uVar1 = 0;
uVar3 = 0xffffffff;
do {
uVar4 = uVar1 & 0xffffffff;
iVar2 = (int)uVar3;
if (iVar2 < 0) {
if (iVar2 != -1) goto LAB_001011ff;
LAB_001011eb:
... |
5,186 | func0 |
#include <assert.h>
void right_rotate(int arr[], int n, int out_of_place, int cur) {
int temp = arr[cur];
for (int i = cur; i > out_of_place; --i) {
arr[i] = arr[i - 1];
}
arr[out_of_place] = temp;
}
| void func0(int arr[], int n) {
int out_of_place = -1;
for (int index = 0; index < n; ++index) {
if (out_of_place >= 0) {
if ((arr[index] >= 0 && arr[out_of_place] < 0) ||
(arr[index] < 0 && arr[out_of_place] >= 0)) {
right_rotate(arr, n, out_of_place, i... | int main() {
int arr1[] = {-5, -2, 5, 2, 4, 7, 1, 8, 0, -8};
int arr1_result[] = {-5, 5, -2, 2, -8, 4, 7, 1, 8, 0};
func0(arr1, 10);
for (int i = 0; i < 10; i++) {
assert(arr1[i] == arr1_result[i]);
}
int arr2[] = {1, 2, 3, -4, -1, 4};
int arr2_result[] = {-4, 1, -1, 2, 3, ... | O2 | c | func0:
endbr64
test %esi,%esi
jle 1580 <func0+0x110>
push %r12
xor %r8d,%r8d
mov $0xffffffff,%r10d
lea -0x4(%rdi),%r12
push %rbp
push %rbx
jmp 14bc <func0+0x4c>
lea 0x0(,%r11,4),%rdx
movslq %r10d,%rcx
lea (%rdi,%rdx,1),%rax
lea (%rdi,%rcx,4),%rbp
mov (%rax),%ebx
mov 0x0(%rbp),%ecx
... | func0:
endbr64
test esi, esi
jle locret_15AA
push r15
mov r15d, esi
push r14
push r13
mov r13, rdi
push r12
mov r12d, 0FFFFFFFFh
push rbp
push rbx
xor ebx, ebx
sub rsp, 18h
jmp short loc_14E2
loc_14D0:
lea eax, [rbx+1]
test esi, esi
js short loc_150F
loc_14D7... | void func0(long long a1, int a2)
{
int v3; // r12d
int v4; // ebx
int v5; // eax
long long v6; // rbp
int v7; // r14d
int *v8; // rcx
int v9; // esi
if ( a2 > 0 )
{
v3 = -1;
v4 = 0;
while ( 1 )
{
v6 = v4;
v7 = *(_DWORD *)(a1 + 4LL * v4);
if ( v3 == -1 )
goto... | func0:
ENDBR64
TEST ESI,ESI
JLE 0x001015aa
PUSH R15
MOV R15D,ESI
PUSH R14
PUSH R13
MOV R13,RDI
PUSH R12
MOV R12D,0xffffffff
PUSH RBP
PUSH RBX
XOR EBX,EBX
SUB RSP,0x18
JMP 0x001014e2
LAB_001014d0:
LEA EAX,[RBX + 0x1]
TEST ESI,ESI
JS 0x0010150f
LAB_001014d7:
MOV EBX,EAX
CMP R15D,EAX
JLE 0x0010156d
LAB_001014e2:
MOVSXD RB... | void func0(long param_1,int param_2)
{
int *piVar1;
int iVar2;
int iVar3;
uint uVar4;
ulong uVar5;
uint uVar6;
ulong uVar7;
long lVar8;
uint uVar9;
if (param_2 < 1) {
return;
}
uVar9 = 0xffffffff;
uVar6 = 0;
do {
while( true ) {
uVar7 = (ulong)(int)uVar6;
iVar2 = *(in... |
5,187 | func0 |
#include <assert.h>
void right_rotate(int arr[], int n, int out_of_place, int cur) {
int temp = arr[cur];
for (int i = cur; i > out_of_place; --i) {
arr[i] = arr[i - 1];
}
arr[out_of_place] = temp;
}
| void func0(int arr[], int n) {
int out_of_place = -1;
for (int index = 0; index < n; ++index) {
if (out_of_place >= 0) {
if ((arr[index] >= 0 && arr[out_of_place] < 0) ||
(arr[index] < 0 && arr[out_of_place] >= 0)) {
right_rotate(arr, n, out_of_place, i... | int main() {
int arr1[] = {-5, -2, 5, 2, 4, 7, 1, 8, 0, -8};
int arr1_result[] = {-5, 5, -2, 2, -8, 4, 7, 1, 8, 0};
func0(arr1, 10);
for (int i = 0; i < 10; i++) {
assert(arr1[i] == arr1_result[i]);
}
int arr2[] = {1, 2, 3, -4, -1, 4};
int arr2_result[] = {-4, 1, -1, 2, 3, ... | O3 | c | func0:
endbr64
test %esi,%esi
jle 1610 <func0+0x130>
push %r15
mov %esi,%r15d
push %r14
mov %rdi,%r14
push %r13
push %r12
mov $0xffffffff,%r12d
push %rbp
push %rbx
xor %ebx,%ebx
sub $0x18,%rsp
nopl 0x0(%rax,%rax,1)
lea 0x1(%rbx),%ebp
movslq %ebx,%r13
cmp $0xffffffff,%r12d
je ... | func0:
endbr64
test esi, esi
jle locret_1510
push r15
push r14
push r13
mov r13d, esi
push r12
mov r12, rdi
push rbp
xor ebp, ebp
push rbx
xor ebx, ebx
sub rsp, 18h
loc_1414:
lea rax, [r12+rbp]
mov edx, ebx
mov eax, [rax]
and edx, 1
test eax, eax
js l... | void func0(long long a1, int a2)
{
long long v2; // rbp
int v3; // ebx
int v4; // ecx
int v5; // r15d
int *v6; // r14
int v7; // eax
int v8; // [rsp+0h] [rbp-40h]
int v9; // [rsp+4h] [rbp-3Ch]
if ( a2 > 0 )
{
v2 = 0LL;
v3 = 0;
while ( 1 )
{
LABEL_3:
while ( *(int *)(a1 + v2) ... | func0:
ENDBR64
TEST ESI,ESI
JLE 0x00101510
PUSH R15
PUSH R14
PUSH R13
MOV R13D,ESI
PUSH R12
MOV R12,RDI
PUSH RBP
XOR EBP,EBP
PUSH RBX
XOR EBX,EBX
SUB RSP,0x18
LAB_00101414:
LEA RAX,[R12 + RBP*0x1]
MOV EDX,EBX
MOV EAX,dword ptr [RAX]
AND EDX,0x1
TEST EAX,EAX
JS 0x001014e8
TEST EDX,EDX
JNZ 0x001014f0
LAB_0010142f:
LEA EA... | void func0(long param_1,uint param_2)
{
int *piVar1;
int iVar2;
uint uVar3;
ulong uVar4;
uint uVar5;
uint uVar6;
long lVar7;
long lVar8;
long lVar9;
if ((int)param_2 < 1) {
return;
}
lVar7 = 0;
uVar6 = 0;
LAB_00101414:
while ((uVar6 & 1) == 0) {
uVar6 = uVar6 + 1;
lVar7 = lVa... |
5,188 | func0 |
#include <stdio.h>
#include <assert.h>
| int* func0(int test_tuple[], int size) {
static int sums[2];
int sum1 = 0;
int sum2 = 0;
for (int idx = 0; idx < size; idx++) {
if (idx % 2) {
sum1 += test_tuple[idx];
} else {
sum2 += test_tuple[idx];
}
}
sums[0] = sum1;
sums[1] = ... | int main() {
int arr1[] = {5, 6, 3, 6, 10, 34};
int* result1 = func0(arr1, 6);
assert(result1[0] == 46 && result1[1] == 18);
int arr2[] = {1, 2, 3, 4, 5};
int* result2 = func0(arr2, 5);
assert(result2[0] == 6 && result2[1] == 9);
int arr3[] = {6, 7, 8, 9, 4, 5};
int* result3 ... | O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
mov %rdi,-0x18(%rbp)
mov %esi,-0x1c(%rbp)
movl $0x0,-0xc(%rbp)
movl $0x0,-0x8(%rbp)
movl $0x0,-0x4(%rbp)
jmp 11d1 <func0+0x68>
mov -0x4(%rbp),%eax
and $0x1,%eax
test %eax,%eax
je 11b4 <func0+0x4b>
mov -0x4(%rbp),%eax
cltq
lea 0x0(,%rax,4),%rdx... | func0:
endbr64
push rbp
mov rbp, rsp
mov [rbp+var_18], rdi
mov [rbp+var_1C], esi
mov [rbp+var_C], 0
mov [rbp+var_8], 0
mov [rbp+var_4], 0
jmp short loc_11D1
loc_118F:
mov eax, [rbp+var_4]
and eax, 1
test eax, eax
jz short loc_11B4
mov eax, [rbp+var_4]
cdqe
lea rdx,... | int * func0(long long a1, int a2)
{
int v3; // [rsp+10h] [rbp-Ch]
int v4; // [rsp+14h] [rbp-8h]
int i; // [rsp+18h] [rbp-4h]
v3 = 0;
v4 = 0;
for ( i = 0; i < a2; ++i )
{
if ( (i & 1) != 0 )
v3 += *(_DWORD *)(4LL * i + a1);
else
v4 += *(_DWORD *)(4LL * i + a1);
}
sums_1 = v3;
dwo... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x18],RDI
MOV dword ptr [RBP + -0x1c],ESI
MOV dword ptr [RBP + -0xc],0x0
MOV dword ptr [RBP + -0x8],0x0
MOV dword ptr [RBP + -0x4],0x0
JMP 0x001011d1
LAB_0010118f:
MOV EAX,dword ptr [RBP + -0x4]
AND EAX,0x1
TEST EAX,EAX
JZ 0x001011b4
MOV EAX,dword ptr [RBP + -0x... | int8 * func0(long param_1,int param_2)
{
int local_14;
int local_10;
uint local_c;
local_14 = 0;
local_10 = 0;
for (local_c = 0; (int)local_c < param_2; local_c = local_c + 1) {
if ((local_c & 1) == 0) {
local_10 = local_10 + *(int *)(param_1 + (long)(int)local_c * 4);
}
else {
l... |
5,189 | func0 |
#include <stdio.h>
#include <assert.h>
| int* func0(int test_tuple[], int size) {
static int sums[2];
int sum1 = 0;
int sum2 = 0;
for (int idx = 0; idx < size; idx++) {
if (idx % 2) {
sum1 += test_tuple[idx];
} else {
sum2 += test_tuple[idx];
}
}
sums[0] = sum1;
sums[1] = ... | int main() {
int arr1[] = {5, 6, 3, 6, 10, 34};
int* result1 = func0(arr1, 6);
assert(result1[0] == 46 && result1[1] == 18);
int arr2[] = {1, 2, 3, 4, 5};
int* result2 = func0(arr2, 5);
assert(result2[0] == 6 && result2[1] == 9);
int arr3[] = {6, 7, 8, 9, 4, 5};
int* result3 ... | O1 | c | func0:
endbr64
test %esi,%esi
jle 119e <func0+0x35>
lea -0x1(%rsi),%r8d
mov $0x0,%eax
mov $0x0,%ecx
mov $0x0,%esi
jmp 1195 <func0+0x2c>
add (%rdi,%rax,4),%ecx
lea 0x1(%rax),%rdx
cmp %r8,%rax
je 11a8 <func0+0x3f>
mov %rdx,%rax
test $0x1,%al
je 1186 <func0+0x1d>
add (%rdi,%rax... | func0:
endbr64
test esi, esi
jle short loc_1199
mov esi, esi
mov eax, 0
mov edx, 0
mov ecx, 0
jmp short loc_1190
loc_1184:
add edx, [rdi+rax*4]
loc_1187:
add rax, 1
cmp rax, rsi
jz short loc_11A3
loc_1190:
test al, 1
jz short loc_1184
add ecx, [rdi+rax*4]
jmp ... | int * func0(long long a1, int a2)
{
long long v2; // rax
int v3; // edx
int v4; // ecx
if ( a2 <= 0 )
{
v3 = 0;
v4 = 0;
}
else
{
v2 = 0LL;
v3 = 0;
v4 = 0;
do
{
if ( (v2 & 1) != 0 )
v4 += *(_DWORD *)(a1 + 4 * v2);
else
v3 += *(_DWORD *)(a1 + 4 * v2... | func0:
ENDBR64
TEST ESI,ESI
JLE 0x00101199
MOV ESI,ESI
MOV EAX,0x0
MOV EDX,0x0
MOV ECX,0x0
JMP 0x00101190
LAB_00101184:
ADD EDX,dword ptr [RDI + RAX*0x4]
LAB_00101187:
ADD RAX,0x1
CMP RAX,RSI
JZ 0x001011a3
LAB_00101190:
TEST AL,0x1
JZ 0x00101184
ADD ECX,dword ptr [RDI + RAX*0x4]
JMP 0x00101187
LAB_00101199:
MOV EDX,0x0... | int8 * func0(long param_1,uint param_2)
{
ulong uVar1;
if ((int)param_2 < 1) {
sums_1._4_4_ = 0;
sums_1._0_4_ = 0;
}
else {
uVar1 = 0;
sums_1._4_4_ = 0;
sums_1._0_4_ = 0;
do {
if ((uVar1 & 1) == 0) {
sums_1._4_4_ = sums_1._4_4_ + *(int *)(param_1 + uVar1 * 4);
}
... |
5,190 | func0 |
#include <stdio.h>
#include <assert.h>
| int* func0(int test_tuple[], int size) {
static int sums[2];
int sum1 = 0;
int sum2 = 0;
for (int idx = 0; idx < size; idx++) {
if (idx % 2) {
sum1 += test_tuple[idx];
} else {
sum2 += test_tuple[idx];
}
}
sums[0] = sum1;
sums[1] = ... | int main() {
int arr1[] = {5, 6, 3, 6, 10, 34};
int* result1 = func0(arr1, 6);
assert(result1[0] == 46 && result1[1] == 18);
int arr2[] = {1, 2, 3, 4, 5};
int* result2 = func0(arr2, 5);
assert(result2[0] == 6 && result2[1] == 9);
int arr3[] = {6, 7, 8, 9, 4, 5};
int* result3 ... | O2 | c | func0:
endbr64
test %esi,%esi
jle 11a0 <func0+0x50>
lea -0x1(%rsi),%r8d
xor %eax,%eax
xor %ecx,%ecx
xor %esi,%esi
jmp 1176 <func0+0x26>
nopl 0x0(%rax)
add %edx,%esi
lea 0x1(%rax),%rdx
cmp %r8,%rax
je 1188 <func0+0x38>
mov %rdx,%rax
mov (%rdi,%rax,4),%edx
test $0x1,%al
jne 1... | func0:
endbr64
test esi, esi
jle short loc_1330
movsxd rsi, esi
xor eax, eax
xor ecx, ecx
xor r8d, r8d
jmp short loc_1304
loc_12F8:
add rax, 1
add r8d, edx
cmp rsi, rax
jz short loc_1316
loc_1304:
mov edx, [rdi+rax*4]
test al, 1
jnz short loc_12F8
add rax, 1
add ... | int * func0(long long a1, int a2)
{
long long v2; // rax
int v3; // ecx
int v4; // r8d
int v5; // edx
int *result; // rax
if ( a2 <= 0 )
{
v3 = 0;
v4 = 0;
}
else
{
v2 = 0LL;
v3 = 0;
v4 = 0;
do
{
while ( 1 )
{
v5 = *(_DWORD *)(a1 + 4 * v2);
if ... | func0:
ENDBR64
TEST ESI,ESI
JLE 0x00101330
MOVSXD RSI,ESI
XOR EAX,EAX
XOR ECX,ECX
XOR R8D,R8D
JMP 0x00101304
LAB_001012f8:
ADD RAX,0x1
ADD R8D,EDX
CMP RSI,RAX
JZ 0x00101316
LAB_00101304:
MOV EDX,dword ptr [RDI + RAX*0x4]
TEST AL,0x1
JNZ 0x001012f8
ADD RAX,0x1
ADD ECX,EDX
CMP RSI,RAX
JNZ 0x00101304
LAB_00101316:
MOV dwo... | int8 * func0(long param_1,int param_2)
{
int iVar1;
ulong uVar2;
if (param_2 < 1) {
sums_1._4_4_ = 0;
sums_1._0_4_ = 0;
}
else {
uVar2 = 0;
sums_1._4_4_ = 0;
sums_1._0_4_ = 0;
do {
while (iVar1 = *(int *)(param_1 + uVar2 * 4), (uVar2 & 1) == 0) {
uVar2 = uVar2 + 1;
... |
5,191 | func0 |
#include <stdio.h>
#include <assert.h>
| int* func0(int test_tuple[], int size) {
static int sums[2];
int sum1 = 0;
int sum2 = 0;
for (int idx = 0; idx < size; idx++) {
if (idx % 2) {
sum1 += test_tuple[idx];
} else {
sum2 += test_tuple[idx];
}
}
sums[0] = sum1;
sums[1] = ... | int main() {
int arr1[] = {5, 6, 3, 6, 10, 34};
int* result1 = func0(arr1, 6);
assert(result1[0] == 46 && result1[1] == 18);
int arr2[] = {1, 2, 3, 4, 5};
int* result2 = func0(arr2, 5);
assert(result2[0] == 6 && result2[1] == 9);
int arr3[] = {6, 7, 8, 9, 4, 5};
int* result3 ... | O3 | c | func0:
endbr64
test %esi,%esi
jle 12a0 <func0+0x150>
lea -0x1(%rsi),%eax
cmp $0x4,%eax
jbe 12a6 <func0+0x156>
mov %esi,%edx
pxor %xmm2,%xmm2
movdqa 0xe9a(%rip),%xmm3
movdqa 0xea2(%rip),%xmm7
shr $0x2,%edx
movdqa %xmm2,%xmm1
movdqa %xmm2,%xmm5
mov %rdi,%rax
shl $0x4,%rdx
movdqa 0xe98(%rip),%x... | func0:
endbr64
mov rcx, rdi
test esi, esi
jle loc_1280
lea eax, [rsi-1]
cmp eax, 3
jbe loc_128A
mov edx, esi
pxor xmm1, xmm1
movdqa xmm3, cs:xmmword_2010
movdqa xmm7, cs:xmmword_2020
shr edx, 2
movdqa xmm2, xmm1
movdqa xmm4, xmm1
mov rax, rdi
shl rdx, 4
movdqa xmm6, cs:xmm... | long long * func0(unsigned int *a1, int a2)
{
__m128i v3; // xmm1
__m128i si128; // xmm3
__m128i v5; // xmm7
__m128i v6; // xmm2
const __m128i *v7; // rax
__m128i v8; // xmm6
__m128i v9; // xmm0
__m128i v10; // xmm5
__m128i v11; // xmm0
unsigned int v12; // eax
__m128i v13; // xmm1
__m128i v14; ... | func0:
ENDBR64
MOV RCX,RDI
TEST ESI,ESI
JLE 0x00101280
LEA EAX,[RSI + -0x1]
CMP EAX,0x3
JBE 0x0010128a
MOV EDX,ESI
PXOR XMM1,XMM1
MOVDQA XMM3,xmmword ptr [0x00102010]
MOVDQA XMM7,xmmword ptr [0x00102020]
SHR EDX,0x2
MOVDQA XMM2,XMM1
MOVDQA XMM4,XMM1
MOV RAX,RDI
SHL RDX,0x4
MOVDQA XMM6,xmmword ptr [0x00102030]
ADD RDX,R... | /* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
int8 * func0(uint *param_1,uint param_2)
{
uint uVar1;
uint *puVar2;
uint *puVar3;
ulong uVar4;
long lVar5;
uint uVar6;
uint uVar7;
uint uVar8;
uint uVar9;
int iVar10;
int iVar11;
int iVar12;
int iVar13;
i... |
5,192 | func0 |
#include <stdio.h>
#include <limits.h>
#include <assert.h>
| int func0(int n) {
if (n <= 3) {
return n;
}
int res = n;
for (int x = 1; x <= n; x++) {
int temp = x * x;
if (temp > n) {
break;
} else {
res = (res < (1 + func0(n - temp))) ? res : (1 + func0(n - temp));
}
}
return re... | int main() {
assert(func0(6) == 3);
assert(func0(2) == 2);
assert(func0(4) == 1);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
sub $0x20,%rsp
mov %edi,-0x14(%rbp)
cmpl $0x3,-0x14(%rbp)
jg 1163 <func0+0x1a>
mov -0x14(%rbp),%eax
jmp 11bf <func0+0x76>
mov -0x14(%rbp),%eax
mov %eax,-0xc(%rbp)
movl $0x1,-0x8(%rbp)
jmp 11b1 <func0+0x68>
mov -0x8(%rbp),%eax
imul %eax,%eax
m... | func0:
endbr64
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_14], edi
cmp [rbp+var_14], 3
jg short loc_1163
mov eax, [rbp+var_14]
jmp short locret_11BF
loc_1163:
mov eax, [rbp+var_14]
mov [rbp+var_C], eax
mov [rbp+var_8], 1
jmp short loc_11B1
loc_1172:
mov eax, [rbp... | long long func0(int a1)
{
int v2; // eax
int v3; // [rsp+14h] [rbp-Ch]
int i; // [rsp+18h] [rbp-8h]
int v5; // [rsp+1Ch] [rbp-4h]
if ( a1 <= 3 )
return (unsigned int)a1;
v3 = a1;
for ( i = 1; i <= a1; ++i )
{
v5 = i * i;
if ( i * i > a1 )
break;
if ( v3 <= (int)func0((unsigned in... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV dword ptr [RBP + -0x14],EDI
CMP dword ptr [RBP + -0x14],0x3
JG 0x00101163
MOV EAX,dword ptr [RBP + -0x14]
JMP 0x001011bf
LAB_00101163:
MOV EAX,dword ptr [RBP + -0x14]
MOV dword ptr [RBP + -0xc],EAX
MOV dword ptr [RBP + -0x8],0x1
JMP 0x001011b1
LAB_00101172:
MOV EAX,d... | int func0(int param_1)
{
int iVar1;
int iVar2;
int local_14;
int local_10;
local_14 = param_1;
if (3 < param_1) {
for (local_10 = 1; (local_10 <= param_1 && (iVar1 = local_10 * local_10, iVar1 <= param_1));
local_10 = local_10 + 1) {
iVar2 = func0(param_1 - iVar1);
if (iVar2 < lo... |
5,193 | func0 |
#include <stdio.h>
#include <limits.h>
#include <assert.h>
| int func0(int n) {
if (n <= 3) {
return n;
}
int res = n;
for (int x = 1; x <= n; x++) {
int temp = x * x;
if (temp > n) {
break;
} else {
res = (res < (1 + func0(n - temp))) ? res : (1 + func0(n - temp));
}
}
return re... | int main() {
assert(func0(6) == 3);
assert(func0(2) == 2);
assert(func0(4) == 1);
return 0;
}
| O1 | c | func0:
endbr64
push %r12
push %rbp
push %rbx
mov %edi,%r12d
cmp $0x3,%edi
jle 1188 <func0+0x3f>
mov %edi,%ebx
mov $0x1,%eax
mov $0x1,%ebp
mov %ebx,%edi
sub %eax,%edi
callq 1149 <func0>
lea 0x1(%rax),%edx
cmp %r12d,%eax
cmovl %edx,%r12d
add $0x1,%ebp
cmp %ebp,%ebx
jl 1188 ... | func0:
endbr64
push r12
push rbp
push rbx
mov r12d, edi
cmp edi, 3
jle short loc_118A
mov ebx, edi
mov eax, 1
mov ebp, 1
jmp short loc_1170
loc_1167:
mov eax, ebp
imul eax, ebp
cmp ebx, eax
jl short loc_118A
loc_1170:
mov edi, ebx
sub edi, eax
call func0
l... | long long func0(int a1)
{
int v1; // r12d
int v2; // eax
int v3; // ebp
int v4; // eax
v1 = a1;
if ( a1 > 3 )
{
v2 = 1;
v3 = 1;
do
{
v4 = func0((unsigned int)(a1 - v2));
if ( v4 < v1 )
v1 = v4 + 1;
if ( a1 < ++v3 )
break;
v2 = v3 * v3;
}
wh... | func0:
ENDBR64
PUSH R12
PUSH RBP
PUSH RBX
MOV R12D,EDI
CMP EDI,0x3
JLE 0x0010118a
MOV EBX,EDI
MOV EAX,0x1
MOV EBP,0x1
JMP 0x00101170
LAB_00101167:
MOV EAX,EBP
IMUL EAX,EBP
CMP EBX,EAX
JL 0x0010118a
LAB_00101170:
MOV EDI,EBX
SUB EDI,EAX
CALL 0x00101149
LEA EDX,[RAX + 0x1]
CMP EAX,R12D
CMOVL R12D,EDX
ADD EBP,0x1
CMP EBX,... | int func0(int param_1)
{
int iVar1;
int iVar2;
int iVar3;
iVar3 = param_1;
if (3 < param_1) {
iVar1 = 1;
iVar2 = 1;
do {
iVar1 = func0(param_1 - iVar1);
if (iVar1 < iVar3) {
iVar3 = iVar1 + 1;
}
iVar2 = iVar2 + 1;
} while ((iVar2 <= param_1) && (iVar1 = iVar... |
5,194 | func0 |
#include <stdio.h>
#include <limits.h>
#include <assert.h>
| int func0(int n) {
if (n <= 3) {
return n;
}
int res = n;
for (int x = 1; x <= n; x++) {
int temp = x * x;
if (temp > n) {
break;
} else {
res = (res < (1 + func0(n - temp))) ? res : (1 + func0(n - temp));
}
}
return re... | int main() {
assert(func0(6) == 3);
assert(func0(2) == 2);
assert(func0(4) == 1);
return 0;
}
| O2 | c | func0:
endbr64
cmp $0x3,%edi
jle 11d0 <func0+0x10>
jmp 11e0 <func0.part.0>
nopl 0x0(%rax,%rax,1)
mov %edi,%eax
retq
data16 nopw %cs:0x0(%rax,%rax,1)
xchg %ax,%ax
| func0_part_0:
push r14
mov eax, 1
push r13
mov r13d, edi
push r12
mov r12d, edi
push rbp
push rbx
mov ebx, 1
test edi, edi
jle short loc_1215
loc_11DC:
mov ebp, r12d
sub ebp, eax
cmp ebp, 3
jle short loc_1228
mov edi, ebp
call func0_part_0
mov r14d, eax
c... | long long func0_part_0(int a1)
{
int v1; // eax
int v2; // r13d
int v4; // ebx
unsigned int v5; // ebp
signed int v6; // eax
long long v7; // rdi
v1 = 1;
v2 = a1;
v4 = 1;
if ( a1 > 0 )
{
while ( 1 )
{
v5 = a1 - v1;
if ( a1 - v1 > 3 )
break;
if ( (int)v5 < v2 )
... | func0.part.0:
PUSH R14
MOV EAX,0x1
PUSH R13
MOV R13D,EDI
PUSH R12
MOV R12D,EDI
PUSH RBP
PUSH RBX
MOV EBX,0x1
TEST EDI,EDI
JLE 0x00101215
LAB_001011dc:
MOV EBP,R12D
SUB EBP,EAX
CMP EBP,0x3
JLE 0x00101228
MOV EDI,EBP
CALL 0x001011c0
MOV R14D,EAX
CMP EAX,R13D
JGE 0x00101203
MOV EDI,EBP
MOV EBP,R14D
CALL 0x001011c0
LAB_001... | int func0_part_0(int param_1)
{
int iVar1;
int iVar2;
int iVar3;
int iVar4;
iVar3 = 1;
iVar2 = 1;
iVar4 = param_1;
if (0 < param_1) {
do {
iVar3 = param_1 - iVar3;
if (iVar3 < 4) {
if (iVar3 < iVar4) goto LAB_001011ff;
}
else {
iVar1 = func0_part_0(iVar3);... |
5,195 | func0 |
#include <stdio.h>
#include <limits.h>
#include <assert.h>
| int func0(int n) {
if (n <= 3) {
return n;
}
int res = n;
for (int x = 1; x <= n; x++) {
int temp = x * x;
if (temp > n) {
break;
} else {
res = (res < (1 + func0(n - temp))) ? res : (1 + func0(n - temp));
}
}
return re... | int main() {
assert(func0(6) == 3);
assert(func0(2) == 2);
assert(func0(4) == 1);
return 0;
}
| O3 | c | func0:
endbr64
mov %edi,%r8d
cmp $0x3,%edi
jle 13e8 <func0+0x1a8>
mov %edi,%ecx
mov $0x1,%esi
mov $0x1,%eax
mov %ecx,%edx
sub %eax,%edx
cmp $0x3,%edx
jle 13c8 <func0+0x188>
push %r13
push %r12
push %rbp
push %rbx
sub $0x8,%rsp
mov %edx,%edi
callq 11c0 <func0.part.0>
cmp %... | func0_part_0:
push r15
push r14
push r13
push r12
push rbp
mov ebp, edi
push rbx
sub rsp, 38h
test edi, edi
jle loc_1371
mov eax, 1
mov r13d, 1
mov r12d, edi
loc_11E6:
mov esi, r12d
sub esi, eax
cmp esi, 3
jle loc_185B
mov r14d, 1
mov [rsp+68h+var_5C]... | long long func0_part_0(int a1, long long a2, long long a3, long long a4, long long a5, long long a6)
{
unsigned int v6; // ebp
int v7; // eax
int v8; // r13d
int v9; // r12d
long long v10; // rsi
int v11; // ebx
int v12; // eax
unsigned int v13; // r13d
unsigned int v14; // ebp
int v15; // r14d
i... | func0.part.0:
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
MOV EBP,EDI
PUSH RBX
SUB RSP,0x38
TEST EDI,EDI
JLE 0x00101371
MOV EAX,0x1
MOV R13D,0x1
MOV R12D,EDI
LAB_001011e6:
MOV ESI,R12D
SUB ESI,EAX
CMP ESI,0x3
JLE 0x0010185b
MOV R14D,0x1
MOV dword ptr [RSP + 0xc],R13D
MOV EBX,ESI
MOV EAX,0x1
MOV dword ptr [RSP + 0x10],... | int func0_part_0(int param_1)
{
int iVar1;
int iVar2;
int iVar3;
int iVar4;
int iVar5;
int iVar6;
int iVar7;
int iVar8;
int iVar9;
int iVar10;
int iVar11;
int iVar12;
int iVar13;
int iVar14;
int iVar15;
int iVar16;
int iVar17;
int iVar18;
int iVar19;
int iVar20;
iVar16 = pa... |
5,196 | func0 |
#include <assert.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
typedef struct {
char word[50];
int count;
} WordCount;
| const char* func0(int n, const char* test_list[]) {
static WordCount words[100];
int unique = 0;
for(int i=0;i<n;i++) {
const char* str = test_list[i];
char word[50];
int pos =0;
while(*str) {
if(!isspace(*str)) {
word[pos++] = *str;
... | int main(){
const char* test1[] = {"UTS is best for RTF", "RTF love UTS", "UTS is best"};
assert(strcmp(func0(3, test1), "UTS") == 0);
const char* test2[] = {"Its been a great year", "this year is so worse", "this year is okay"};
assert(strcmp(func0(3, test2), "year") == 0);
const c... | O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
add $0xffffffffffffff80,%rsp
mov %edi,-0x74(%rbp)
mov %rsi,-0x80(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x8(%rbp)
xor %eax,%eax
movl $0x0,-0x70(%rbp)
movl $0x0,-0x6c(%rbp)
jmpq 14ab <func0+0x2e2>
mov -0x6c(%rbp),%eax
cltq
lea 0x0(,%rax,8),%rdx
mov ... | func0:
endbr64
push rbp
mov rbp, rsp
add rsp, 0FFFFFFFFFFFFFF80h
mov [rbp+var_74], edi
mov [rbp+var_80], rsi
mov rax, fs:28h
mov [rbp+var_8], rax
xor eax, eax
mov [rbp+var_70], 0
mov [rbp+var_6C], 0
jmp loc_14AB
loc_11FE:
mov eax, [rbp+var_6C]
cdqe
lea rdx, ds:0[rax*8]... | char * func0(int a1, long long a2)
{
int v2; // eax
int v4; // [rsp+10h] [rbp-70h]
int i; // [rsp+14h] [rbp-6Ch]
int v6; // [rsp+18h] [rbp-68h]
int v7; // [rsp+1Ch] [rbp-64h]
int j; // [rsp+20h] [rbp-60h]
int v9; // [rsp+24h] [rbp-5Ch]
int k; // [rsp+28h] [rbp-58h]
int v11; // [rsp+2Ch] [rbp-54h]
in... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
ADD RSP,-0x80
MOV dword ptr [RBP + -0x74],EDI
MOV qword ptr [RBP + -0x80],RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
XOR EAX,EAX
MOV dword ptr [RBP + -0x70],0x0
MOV dword ptr [RBP + -0x6c],0x0
JMP 0x001014ab
LAB_001011fe:
MOV EAX,dword ptr [RBP + -0x6c]
CDQE
LEA R... | int1 * func0(int param_1,long param_2)
{
bool bVar1;
int iVar2;
ushort **ppuVar3;
long in_FS_OFFSET;
int local_78;
int local_74;
int local_70;
int local_68;
int local_60;
int local_5c;
int local_58;
int local_54;
char *local_50;
char local_48 [56];
long local_10;
local_10 = *(long *)... |
5,197 | func0 |
#include <assert.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
typedef struct {
char word[50];
int count;
} WordCount;
| const char* func0(int n, const char* test_list[]) {
static WordCount words[100];
int unique = 0;
for(int i=0;i<n;i++) {
const char* str = test_list[i];
char word[50];
int pos =0;
while(*str) {
if(!isspace(*str)) {
word[pos++] = *str;
... | int main(){
const char* test1[] = {"UTS is best for RTF", "RTF love UTS", "UTS is best"};
assert(strcmp(func0(3, test1), "UTS") == 0);
const char* test2[] = {"Its been a great year", "this year is so worse", "this year is okay"};
assert(strcmp(func0(3, test2), "year") == 0);
const c... | O1 | c | func0:
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x58,%rsp
mov %fs:0x28,%rax
mov %rax,0x48(%rsp)
xor %eax,%eax
test %edi,%edi
jle 13f2 <func0+0x229>
mov %rsi,(%rsp)
lea -0x1(%rdi),%eax
lea 0x8(%rsi,%rax,8),%rax
mov %rax,0x8(%rsp)
mov $0x0,%r13d
... | func0:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 58h
mov rax, fs:28h
mov [rsp+88h+var_40], rax
xor eax, eax
test edi, edi
jle loc_13F2
mov [rsp+88h+var_88], rsi
lea eax, [rdi-1]
lea rax, [rsi+rax*8+8]
mov [rsp+88h+var_80], rax
mov ... | char * func0(int a1, char **a2)
{
int v2; // r13d
char *v3; // r12
char v4; // bl
int v5; // eax
char *v6; // rbp
int v7; // ebx
_QWORD *v8; // r15
char *v9; // rbp
int v10; // ebx
int *v11; // rdx
int v12; // eax
int v13; // edi
int v14; // esi
char **v16; // [rsp+0h] [rbp-88h]
_BYTE v17[... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x58
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x48],RAX
XOR EAX,EAX
TEST EDI,EDI
JLE 0x001013f2
MOV qword ptr [RSP],RSI
LEA EAX,[RDI + -0x1]
LEA RAX,[RSI + RAX*0x8 + 0x8]
MOV qword ptr [RSP + 0x8],RAX
MOV R13D,0x0
JMP 0x001012fb
LAB_00... | int1 * func0(int param_1,int8 *param_2)
{
int iVar1;
int iVar2;
ushort **ppuVar3;
int *piVar4;
char cVar5;
int iVar6;
int1 *puVar7;
char *pcVar8;
int iVar9;
long in_FS_OFFSET;
int8 *local_88;
char local_78 [56];
long local_40;
local_40 = *(long *)(in_FS_OFFSET + 0x28);
if (param_1 < 1)... |
5,198 | func0 |
#include <assert.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
typedef struct {
char word[50];
int count;
} WordCount;
| const char* func0(int n, const char* test_list[]) {
static WordCount words[100];
int unique = 0;
for(int i=0;i<n;i++) {
const char* str = test_list[i];
char word[50];
int pos =0;
while(*str) {
if(!isspace(*str)) {
word[pos++] = *str;
... | int main(){
const char* test1[] = {"UTS is best for RTF", "RTF love UTS", "UTS is best"};
assert(strcmp(func0(3, test1), "UTS") == 0);
const char* test2[] = {"Its been a great year", "this year is so worse", "this year is okay"};
assert(strcmp(func0(3, test2), "year") == 0);
const c... | O2 | c | func0:
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x58,%rsp
mov %fs:0x28,%rax
mov %rax,0x48(%rsp)
xor %eax,%eax
test %edi,%edi
jle 15ec <func0+0x29c>
lea -0x1(%rdi),%eax
mov %rsi,(%rsp)
xor %ebp,%ebp
lea 0x8(%rsi,%rax,8),%rax
mov %rax,0x8(%rsp)
n... | func0:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 58h
mov rax, fs:28h
mov [rsp+88h+var_40], rax
xor eax, eax
test edi, edi
jle loc_15DC
lea eax, [rdi-1]
mov [rsp+88h+var_88], rsi
xor ebp, ebp
lea rax, [rsi+rax*8+8]
mov [rsp+88h+var... | char * func0(int a1, char **a2)
{
int v2; // ebp
char *v3; // rbx
char v4; // r15
_QWORD *v5; // r12
int v6; // eax
long long v7; // rdx
char *v8; // r13
int v9; // r14d
int *v10; // rdx
int v11; // eax
long long v12; // rdi
int v13; // esi
char *v15; // r12
int v16; // ebx
long long v17; ... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x58
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x48],RAX
XOR EAX,EAX
TEST EDI,EDI
JLE 0x001015dc
LEA EAX,[RDI + -0x1]
MOV qword ptr [RSP],RSI
XOR EBP,EBP
LEA RAX,[RSI + RAX*0x8 + 0x8]
MOV qword ptr [RSP + 0x8],RAX
NOP dword ptr [RAX]
LA... | int1 * func0(int param_1,int8 *param_2)
{
int iVar1;
ushort **ppuVar2;
int *piVar3;
int iVar4;
char *pcVar5;
int iVar6;
long lVar7;
int1 *puVar8;
char cVar9;
long in_FS_OFFSET;
int8 *local_88;
char local_78 [56];
long local_40;
local_40 = *(long *)(in_FS_OFFSET + 0x28);
if (0 < param_1... |
5,199 | func0 |
#include <assert.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
typedef struct {
char word[50];
int count;
} WordCount;
| const char* func0(int n, const char* test_list[]) {
static WordCount words[100];
int unique = 0;
for(int i=0;i<n;i++) {
const char* str = test_list[i];
char word[50];
int pos =0;
while(*str) {
if(!isspace(*str)) {
word[pos++] = *str;
... | int main(){
const char* test1[] = {"UTS is best for RTF", "RTF love UTS", "UTS is best"};
assert(strcmp(func0(3, test1), "UTS") == 0);
const char* test2[] = {"Its been a great year", "this year is so worse", "this year is okay"};
assert(strcmp(func0(3, test2), "year") == 0);
const c... | O3 | c | func0:
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x58,%rsp
mov %fs:0x28,%rax
mov %rax,0x48(%rsp)
xor %eax,%eax
test %edi,%edi
jle 160c <func0+0x29c>
lea -0x1(%rdi),%eax
mov %rsi,(%rsp)
xor %ebp,%ebp
lea 0x8(%rsi,%rax,8),%rax
mov %rax,0x8(%rsp)
n... | func0:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 68h
mov rax, fs:28h
mov [rsp+98h+var_40], rax
xor eax, eax
test edi, edi
jle loc_15EA
movsxd rdi, edi
mov [rsp+98h+var_88], rsi
xor ebp, ebp
lea rax, [rsi+rdi*8]
mov [rsp+98h+var_80], ... | char * func0(int a1, char **a2)
{
int v2; // ebp
char *v3; // rbx
char v4; // r14
const unsigned __int16 **v5; // r13
int v6; // eax
long long v7; // rdx
const char *v8; // r14
int v9; // r15d
int *v10; // rdx
int v11; // eax
long long v12; // rdi
int v13; // esi
const char *v15; // r12
int ... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x68
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x58],RAX
XOR EAX,EAX
TEST EDI,EDI
JLE 0x001015ea
MOVSXD RDI,EDI
MOV qword ptr [RSP + 0x10],RSI
XOR EBP,EBP
LEA RAX,[RSI + RDI*0x8]
MOV qword ptr [RSP + 0x18],RAX
NOP dword ptr [RAX]
LAB_00... | int1 * func0(int param_1,int8 *param_2)
{
int iVar1;
ushort **ppuVar2;
int *piVar3;
int iVar4;
char *pcVar5;
int iVar6;
long lVar7;
char cVar8;
int1 *puVar9;
long in_FS_OFFSET;
char *local_90;
int8 *local_88;
char local_78 [56];
long local_40;
local_40 = *(long *)(in_FS_OFFSET + 0x28);... |
5,200 | func0 |
#include <assert.h>
#include <stdbool.h>
| bool func0(int x, int y, int z) {
if (x == y || y == z || z == x) {
return true;
} else {
return false;
}
}
| int main() {
assert(func0(6, 8, 12) == false);
assert(func0(6, 6, 12) == true);
assert(func0(6, 16, 20) == false);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
mov %edi,-0x4(%rbp)
mov %esi,-0x8(%rbp)
mov %edx,-0xc(%rbp)
mov -0x4(%rbp),%eax
cmp -0x8(%rbp),%eax
je 1172 <func0+0x29>
mov -0x8(%rbp),%eax
cmp -0xc(%rbp),%eax
je 1172 <func0+0x29>
mov -0xc(%rbp),%eax
cmp -0x4(%rbp),%eax
jne 1179 <func0+... | func0:
endbr64
push rbp
mov rbp, rsp
mov [rbp+var_4], edi
mov [rbp+var_8], esi
mov [rbp+var_C], edx
mov eax, [rbp+var_4]
cmp eax, [rbp+var_8]
jz short loc_1172
mov eax, [rbp+var_8]
cmp eax, [rbp+var_C]
jz short loc_1172
mov eax, [rbp+var_C]
cmp eax, [rbp+var_4]
jnz ... | _BOOL8 func0(int a1, int a2, int a3)
{
return a1 == a2 || a2 == a3 || a3 == a1;
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
MOV dword ptr [RBP + -0x4],EDI
MOV dword ptr [RBP + -0x8],ESI
MOV dword ptr [RBP + -0xc],EDX
MOV EAX,dword ptr [RBP + -0x4]
CMP EAX,dword ptr [RBP + -0x8]
JZ 0x00101172
MOV EAX,dword ptr [RBP + -0x8]
CMP EAX,dword ptr [RBP + -0xc]
JZ 0x00101172
MOV EAX,dword ptr [RBP + -0xc]
CMP EAX,... | int8 func0(int param_1,int param_2,int param_3)
{
int8 uVar1;
if (((param_1 == param_2) || (param_2 == param_3)) || (param_3 == param_1)) {
uVar1 = 1;
}
else {
uVar1 = 0;
}
return uVar1;
} |
5,201 | func0 |
#include <assert.h>
#include <stdbool.h>
| bool func0(int x, int y, int z) {
if (x == y || y == z || z == x) {
return true;
} else {
return false;
}
}
| int main() {
assert(func0(6, 8, 12) == false);
assert(func0(6, 6, 12) == true);
assert(func0(6, 16, 20) == false);
return 0;
}
| O1 | c | func0:
endbr64
cmp %esi,%edi
sete %al
cmp %edx,%edi
sete %cl
or %ecx,%eax
cmp %edx,%esi
sete %dl
or %edx,%eax
retq
| func0:
endbr64
cmp edi, esi
setz al
cmp edi, edx
setz cl
or eax, ecx
cmp esi, edx
setz dl
or eax, edx
retn | long long func0(int a1, int a2, int a3, int a4)
{
unsigned int v4; // eax
LOBYTE(v4) = a1 == a2;
LOBYTE(a4) = a1 == a3;
LOBYTE(a3) = a2 == a3;
return a3 | a4 | v4;
} | func0:
ENDBR64
CMP EDI,ESI
SETZ AL
CMP EDI,EDX
SETZ CL
OR EAX,ECX
CMP ESI,EDX
SETZ DL
OR EAX,EDX
RET | uint func0(int param_1,int param_2,int param_3,int4 param_4)
{
int8 in_RAX;
return (uint)CONCAT71((int7)((ulong)in_RAX >> 8),param_1 == param_2) |
CONCAT31((int3)((uint)param_4 >> 8),param_1 == param_3) |
CONCAT31((int3)((uint)param_3 >> 8),param_2 == param_3);
} |
5,202 | func0 |
#include <assert.h>
#include <stdbool.h>
| bool func0(int x, int y, int z) {
if (x == y || y == z || z == x) {
return true;
} else {
return false;
}
}
| int main() {
assert(func0(6, 8, 12) == false);
assert(func0(6, 6, 12) == true);
assert(func0(6, 16, 20) == false);
return 0;
}
| O2 | c | func0:
endbr64
cmp %esi,%edi
sete %al
cmp %edx,%edi
sete %cl
or %ecx,%eax
cmp %edx,%esi
sete %dl
or %edx,%eax
retq
nopl 0x0(%rax,%rax,1)
| func0:
endbr64
cmp edi, esi
setz al
cmp edi, edx
setz cl
or eax, ecx
cmp esi, edx
setz dl
or eax, edx
retn | long long func0(int a1, int a2, int a3, int a4)
{
unsigned int v4; // eax
LOBYTE(v4) = a1 == a2;
LOBYTE(a4) = a1 == a3;
LOBYTE(a3) = a2 == a3;
return a3 | a4 | v4;
} | func0:
ENDBR64
CMP EDI,ESI
SETZ AL
CMP EDI,EDX
SETZ CL
OR EAX,ECX
CMP ESI,EDX
SETZ DL
OR EAX,EDX
RET | uint func0(int param_1,int param_2,int param_3,int4 param_4)
{
int8 in_RAX;
return (uint)CONCAT71((int7)((ulong)in_RAX >> 8),param_1 == param_2) |
CONCAT31((int3)((uint)param_4 >> 8),param_1 == param_3) |
CONCAT31((int3)((uint)param_3 >> 8),param_2 == param_3);
} |
5,203 | func0 |
#include <assert.h>
#include <stdbool.h>
| bool func0(int x, int y, int z) {
if (x == y || y == z || z == x) {
return true;
} else {
return false;
}
}
| int main() {
assert(func0(6, 8, 12) == false);
assert(func0(6, 6, 12) == true);
assert(func0(6, 16, 20) == false);
return 0;
}
| O3 | c | func0:
endbr64
cmp %esi,%edi
sete %al
cmp %edx,%edi
sete %cl
or %ecx,%eax
cmp %edx,%esi
sete %dl
or %edx,%eax
retq
nopl 0x0(%rax,%rax,1)
| func0:
endbr64
cmp edi, esi
setz al
cmp edi, edx
setz cl
or eax, ecx
cmp esi, edx
setz dl
or eax, edx
retn | long long func0(int a1, int a2, int a3, int a4)
{
unsigned int v4; // eax
LOBYTE(v4) = a1 == a2;
LOBYTE(a4) = a1 == a3;
LOBYTE(a3) = a2 == a3;
return a3 | a4 | v4;
} | func0:
ENDBR64
CMP EDI,ESI
SETZ AL
CMP EDI,EDX
SETZ CL
OR EAX,ECX
CMP ESI,EDX
SETZ DL
OR EAX,EDX
RET | uint func0(int param_1,int param_2,int param_3,int4 param_4)
{
int8 in_RAX;
return (uint)CONCAT71((int7)((ulong)in_RAX >> 8),param_1 == param_2) |
CONCAT31((int3)((uint)param_4 >> 8),param_1 == param_3) |
CONCAT31((int3)((uint)param_3 >> 8),param_2 == param_3);
} |
5,204 | func0 |
#include <stdio.h>
#include <assert.h>
| void func0(int list1[], int result[], int m, int n, int size) {
int index = 0;
for (int i = m; i < size; i++, index++) {
result[index] = list1[i];
}
for (int i = 0; i < n; i++, index++) {
result[index] = list1[i];
}
}
| int main() {
int arr1[10] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
int result1[10];
func0(arr1, result1, 3, 4, 10);
int expected1[10] = {4, 5, 6, 7, 8, 9, 10, 1, 2, 3};
for (int i = 0; i < 10; i++) {
assert(result1[i] == expected1[i]);
}
int result2[10];
func0(arr1, result2,... | O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
mov %rdi,-0x18(%rbp)
mov %rsi,-0x20(%rbp)
mov %edx,-0x24(%rbp)
mov %ecx,-0x28(%rbp)
mov %r8d,-0x2c(%rbp)
movl $0x0,-0xc(%rbp)
mov -0x24(%rbp),%eax
mov %eax,-0x8(%rbp)
jmp 11e7 <func0+0x5e>
mov -0x8(%rbp),%eax
cltq
lea 0x0(,%rax,4),%rdx
mov -... | func0:
endbr64
push rbp
mov rbp, rsp
mov [rbp+var_18], rdi
mov [rbp+var_20], rsi
mov [rbp+var_24], edx
mov [rbp+var_28], ecx
mov [rbp+var_2C], r8d
mov [rbp+var_C], 0
mov eax, [rbp+var_24]
mov [rbp+var_8], eax
jmp short loc_11E7
loc_11B2:
mov eax, [rbp+var_8]
cdqe
lea r... | long long func0(long long a1, long long a2, int a3, int a4, int a5)
{
long long result; // rax
int v6; // [rsp+20h] [rbp-Ch]
unsigned int i; // [rsp+28h] [rbp-4h]
v6 = 0;
while ( a3 < a5 )
*(_DWORD *)(4LL * v6++ + a2) = *(_DWORD *)(4LL * a3++ + a1);
for ( i = 0; ; ++i )
{
result = i;
if ( (i... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x18],RDI
MOV qword ptr [RBP + -0x20],RSI
MOV dword ptr [RBP + -0x24],EDX
MOV dword ptr [RBP + -0x28],ECX
MOV dword ptr [RBP + -0x2c],R8D
MOV dword ptr [RBP + -0xc],0x0
MOV EAX,dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0x8],EAX
JMP 0x001011e7
LAB_001011b2:
M... | void func0(long param_1,long param_2,int param_3,int param_4,int param_5)
{
int4 local_14;
int4 local_10;
int4 local_c;
local_14 = 0;
for (local_10 = param_3; local_10 < param_5; local_10 = local_10 + 1) {
*(int4 *)(param_2 + (long)local_14 * 4) = *(int4 *)(param_1 + (long)local_10 * 4);
local_14 ... |
5,205 | func0 |
#include <stdio.h>
#include <assert.h>
| void func0(int list1[], int result[], int m, int n, int size) {
int index = 0;
for (int i = m; i < size; i++, index++) {
result[index] = list1[i];
}
for (int i = 0; i < n; i++, index++) {
result[index] = list1[i];
}
}
| int main() {
int arr1[10] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
int result1[10];
func0(arr1, result1, 3, 4, 10);
int expected1[10] = {4, 5, 6, 7, 8, 9, 10, 1, 2, 3};
for (int i = 0; i < 10; i++) {
assert(result1[i] == expected1[i]);
}
int result2[10];
func0(arr1, result2,... | O1 | c | func0:
endbr64
cmp %r8d,%edx
jge 11da <func0+0x51>
movslq %edx,%rax
mov %rax,%r9
neg %r9
lea (%rsi,%r9,4),%r10
mov (%rdi,%rax,4),%r9d
mov %r9d,(%r10,%rax,4)
add $0x1,%rax
cmp %eax,%r8d
jg 119f <func0+0x16>
sub %edx,%r8d
test %ecx,%ecx
jle 11d9 <func0+0x50>
lea -0x1(%rcx),%r9d
m... | func0:
endbr64
mov r10, rsi
cmp edx, r8d
jge short loc_11D7
movsxd rax, edx
mov rsi, rax
neg rsi
lea r9, [r10+rsi*4]
loc_11A2:
mov esi, [rdi+rax*4]
mov [r9+rax*4], esi
add rax, 1
cmp r8d, eax
jg short loc_11A2
sub r8d, edx
loc_11B5:
test ecx, ecx
jle short locret... | void func0(long long a1, long long a2, int a3, int a4, int a5)
{
long long v5; // rax
int v6; // r8d
long long i; // rax
if ( a3 >= a5 )
{
v6 = 0;
}
else
{
v5 = a3;
do
{
*(_DWORD *)(a2 - 4LL * a3 + 4 * v5) = *(_DWORD *)(a1 + 4 * v5);
++v5;
}
while ( a5 > (int)v5 );
... | func0:
ENDBR64
MOV R10,RSI
CMP EDX,R8D
JGE 0x001011d7
MOVSXD RAX,EDX
MOV RSI,RAX
NEG RSI
LEA R9,[R10 + RSI*0x4]
LAB_001011a2:
MOV ESI,dword ptr [RDI + RAX*0x4]
MOV dword ptr [R9 + RAX*0x4],ESI
ADD RAX,0x1
CMP R8D,EAX
JG 0x001011a2
SUB R8D,EDX
LAB_001011b5:
TEST ECX,ECX
JLE 0x001011d6
MOV ECX,ECX
MOVSXD R8,R8D
LEA RSI,[... | void func0(long param_1,long param_2,int param_3,uint param_4,int param_5)
{
long lVar1;
long lVar2;
ulong uVar3;
if (param_3 < param_5) {
lVar2 = (long)param_3;
lVar1 = lVar2 * -4;
do {
*(int4 *)(param_2 + lVar1 + lVar2 * 4) = *(int4 *)(param_1 + lVar2 * 4);
lVar2 = lVar2 + 1;
}... |
5,206 | func0 |
#include <stdio.h>
#include <assert.h>
| void func0(int list1[], int result[], int m, int n, int size) {
int index = 0;
for (int i = m; i < size; i++, index++) {
result[index] = list1[i];
}
for (int i = 0; i < n; i++, index++) {
result[index] = list1[i];
}
}
| int main() {
int arr1[10] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
int result1[10];
func0(arr1, result1, 3, 4, 10);
int expected1[10] = {4, 5, 6, 7, 8, 9, 10, 1, 2, 3};
for (int i = 0; i < 10; i++) {
assert(result1[i] == expected1[i]);
}
int result2[10];
func0(arr1, result2,... | O2 | c | func0:
endbr64
cmp %r8d,%edx
jge 14b0 <func0+0x60>
movslq %edx,%rax
mov %rax,%r9
neg %r9
lea (%rsi,%r9,4),%r10
nopw %cs:0x0(%rax,%rax,1)
mov (%rdi,%rax,4),%r9d
mov %r9d,(%r10,%rax,4)
add $0x1,%rax
cmp %eax,%r8d
jg 1470 <func0+0x20>
sub %edx,%r8d
test %ecx,%ecx
jle 14aa <func0+0x... | func0:
endbr64
mov r10, rsi
cmp edx, r8d
jge short loc_1480
movsxd rax, edx
mov rsi, rax
neg rsi
lea r9, [r10+rsi*4]
nop dword ptr [rax+00000000h]
loc_1440:
mov esi, [rdi+rax*4]
mov [r9+rax*4], esi
add rax, 1
cmp r8d, eax
jg short loc_1440
sub r8d, edx
loc_1453:
tes... | void func0(long long a1, long long a2, int a3, int a4, int a5)
{
long long v5; // rax
int v6; // r8d
long long i; // rax
if ( a3 >= a5 )
{
v6 = 0;
}
else
{
v5 = a3;
do
{
*(_DWORD *)(a2 - 4LL * a3 + 4 * v5) = *(_DWORD *)(a1 + 4 * v5);
++v5;
}
while ( a5 > (int)v5 );
... | func0:
ENDBR64
MOV R10,RSI
CMP EDX,R8D
JGE 0x00101480
MOVSXD RAX,EDX
MOV RSI,RAX
NEG RSI
LEA R9,[R10 + RSI*0x4]
NOP dword ptr [RAX]
LAB_00101440:
MOV ESI,dword ptr [RDI + RAX*0x4]
MOV dword ptr [R9 + RAX*0x4],ESI
ADD RAX,0x1
CMP R8D,EAX
JG 0x00101440
SUB R8D,EDX
LAB_00101453:
TEST ECX,ECX
JLE 0x00101477
MOVSXD R8,R8D
M... | void func0(long param_1,long param_2,int param_3,int param_4,int param_5)
{
long lVar1;
long lVar2;
if (param_3 < param_5) {
lVar1 = (long)param_3;
lVar2 = lVar1 * -4;
do {
*(int4 *)(param_2 + lVar2 + lVar1 * 4) = *(int4 *)(param_1 + lVar1 * 4);
lVar1 = lVar1 + 1;
} while ((int)lVa... |
5,207 | func0 |
#include <stdio.h>
#include <assert.h>
| void func0(int list1[], int result[], int m, int n, int size) {
int index = 0;
for (int i = m; i < size; i++, index++) {
result[index] = list1[i];
}
for (int i = 0; i < n; i++, index++) {
result[index] = list1[i];
}
}
| int main() {
int arr1[10] = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
int result1[10];
func0(arr1, result1, 3, 4, 10);
int expected1[10] = {4, 5, 6, 7, 8, 9, 10, 1, 2, 3};
for (int i = 0; i < 10; i++) {
assert(result1[i] == expected1[i]);
}
int result2[10];
func0(arr1, result2,... | O3 | c | func0:
endbr64
cmp %r8d,%edx
jge 1610 <func0+0x1c0>
movslq %edx,%rax
lea 0x10(%rdi,%rax,4),%r9
lea (%rdi,%rax,4),%r10
cmp %r9,%rsi
lea 0x10(%rsi),%r9
setae %r11b
cmp %r9,%r10
setae %r9b
or %r9b,%r11b
je 15e0 <func0+0x190>
lea -0x1(%r8),%r9d
sub %edx,%r9d
cmp $0x3,%r9d
jbe 15e0... | func0:
endbr64
mov r9d, edx
push rbx
movsxd rdx, ecx
cmp r9d, r8d
jge loc_1338
mov ecx, r8d
sub ecx, r9d
lea eax, [rcx-1]
cmp eax, 2
movsxd rax, r9d
jbe short loc_11AD
lea r10, ds:4[rax*4]
mov r11, rsi
lea rbx, [rdi+r10]
sub r11, rbx
cmp r11, 8
ja short loc_... | void func0(long long a1, long long a2, int a3, int a4, int a5)
{
long long v6; // rdx
unsigned int v7; // ecx
long long v8; // rax
long long v9; // rsi
long long v10; // rdx
long long v11; // rax
long long v12; // rax
int v13; // r9d
long long v14; // r10
long long v15; // r11
long long v16; // r... | func0:
ENDBR64
MOV R9D,EDX
PUSH RBX
MOVSXD RDX,ECX
CMP R9D,R8D
JGE 0x00101338
MOV ECX,R8D
SUB ECX,R9D
LEA EAX,[RCX + -0x1]
CMP EAX,0x2
MOVSXD RAX,R9D
JBE 0x001011ad
LEA R10,[0x4 + RAX*0x4]
MOV R11,RSI
LEA RBX,[RDI + R10*0x1]
SUB R11,RBX
CMP R11,0x8
JA 0x00101220
LAB_001011ad:
MOV R9D,ECX
LEA R10,[RDI + RAX*0x4]
XOR EAX... | void func0(long param_1,long param_2,int param_3,uint param_4,int param_5)
{
int iVar1;
int8 *puVar2;
int8 uVar3;
uint uVar4;
long lVar5;
long lVar6;
uint uVar7;
if (param_3 < param_5) {
uVar7 = param_5 - param_3;
if ((uVar7 - 1 < 3) || (lVar5 = (long)param_3 * 4 + 4, (ulong)(param_2 - (para... |
5,208 | func0 |
#include <assert.h>
| int func0(int list[], int list_size) {
int neg_count = 0;
for (int i = 0; i < list_size; i++) {
if (list[i] <= 0) {
neg_count += 1;
}
}
return neg_count;
}
| int main() {
int list1[] = {-1, -2, 3, -4, -5};
int list2[] = {1, 2, 3};
int list3[] = {1, 2, -3, -10, 20};
assert(func0(list1, 5) == 4);
assert(func0(list2, 3) == 0);
assert(func0(list3, 5) == 2);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
mov %rdi,-0x18(%rbp)
mov %esi,-0x1c(%rbp)
movl $0x0,-0x8(%rbp)
movl $0x0,-0x4(%rbp)
jmp 11aa <func0+0x41>
mov -0x4(%rbp),%eax
cltq
lea 0x0(,%rax,4),%rdx
mov -0x18(%rbp),%rax
add %rdx,%rax
mov (%rax),%eax
test %eax,%eax
jg 11a6 <func0+0x3d>
ad... | func0:
endbr64
push rbp
mov rbp, rsp
mov [rbp+var_18], rdi
mov [rbp+var_1C], esi
mov [rbp+var_8], 0
mov [rbp+var_4], 0
jmp short loc_11AA
loc_1188:
mov eax, [rbp+var_4]
cdqe
lea rdx, ds:0[rax*4]
mov rax, [rbp+var_18]
add rax, rdx
mov eax, [rax]
test eax, eax
jg sho... | long long func0(long long a1, int a2)
{
unsigned int v3; // [rsp+14h] [rbp-8h]
int i; // [rsp+18h] [rbp-4h]
v3 = 0;
for ( i = 0; i < a2; ++i )
{
if ( *(int *)(4LL * i + a1) <= 0 )
++v3;
}
return v3;
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x18],RDI
MOV dword ptr [RBP + -0x1c],ESI
MOV dword ptr [RBP + -0x8],0x0
MOV dword ptr [RBP + -0x4],0x0
JMP 0x001011aa
LAB_00101188:
MOV EAX,dword ptr [RBP + -0x4]
CDQE
LEA RDX,[RAX*0x4]
MOV RAX,qword ptr [RBP + -0x18]
ADD RAX,RDX
MOV EAX,dword ptr [RAX]
TEST EA... | int func0(long param_1,int param_2)
{
int4 local_10;
int4 local_c;
local_10 = 0;
for (local_c = 0; local_c < param_2; local_c = local_c + 1) {
if (*(int *)(param_1 + (long)local_c * 4) < 1) {
local_10 = local_10 + 1;
}
}
return local_10;
} |
5,209 | func0 |
#include <assert.h>
| int func0(int list[], int list_size) {
int neg_count = 0;
for (int i = 0; i < list_size; i++) {
if (list[i] <= 0) {
neg_count += 1;
}
}
return neg_count;
}
| int main() {
int list1[] = {-1, -2, 3, -4, -5};
int list2[] = {1, 2, 3};
int list3[] = {1, 2, -3, -10, 20};
assert(func0(list1, 5) == 4);
assert(func0(list2, 3) == 0);
assert(func0(list3, 5) == 2);
return 0;
}
| O1 | c | func0:
endbr64
test %esi,%esi
jle 1198 <func0+0x2f>
mov %rdi,%rax
lea -0x1(%rsi),%edx
lea 0x4(%rdi,%rdx,4),%rsi
mov $0x0,%edx
cmpl $0x0,(%rax)
setle %cl
movzbl %cl,%ecx
add %ecx,%edx
add $0x4,%rax
cmp %rsi,%rax
jne 1181 <func0+0x18>
mov %edx,%eax
retq
mov $0x0,%edx
jmp 1195 <fun... | func0:
endbr64
test esi, esi
jle short loc_1198
mov rax, rdi
lea edx, [rsi-1]
lea rsi, [rdi+rdx*4+4]
mov edx, 0
loc_1181:
cmp dword ptr [rax], 0
setle cl
movzx ecx, cl
add edx, ecx
add rax, 4
cmp rax, rsi
jnz short loc_1181
loc_1195:
mov eax, edx
retn
loc_1198:
mov ... | long long func0(_DWORD *a1, int a2)
{
_DWORD *v2; // rax
long long v3; // rsi
unsigned int v4; // edx
if ( a2 <= 0 )
{
return 0;
}
else
{
v2 = a1;
v3 = (long long)&a1[a2 - 1 + 1];
v4 = 0;
do
v4 += *v2++ <= 0;
while ( v2 != (_DWORD *)v3 );
}
return v4;
} | func0:
ENDBR64
TEST ESI,ESI
JLE 0x00101198
MOV RAX,RDI
LEA EDX,[RSI + -0x1]
LEA RSI,[RDI + RDX*0x4 + 0x4]
MOV EDX,0x0
LAB_00101181:
CMP dword ptr [RAX],0x0
SETLE CL
MOVZX ECX,CL
ADD EDX,ECX
ADD RAX,0x4
CMP RAX,RSI
JNZ 0x00101181
LAB_00101195:
MOV EAX,EDX
RET
LAB_00101198:
MOV EDX,0x0
JMP 0x00101195 | int func0(int *param_1,int param_2)
{
int *piVar1;
int iVar2;
if (param_2 < 1) {
iVar2 = 0;
}
else {
piVar1 = param_1 + (ulong)(param_2 - 1) + 1;
iVar2 = 0;
do {
iVar2 = iVar2 + (uint)(*param_1 < 1);
param_1 = param_1 + 1;
} while (param_1 != piVar1);
}
return iVar2;
} |
5,210 | func0 |
#include <assert.h>
| int func0(int list[], int list_size) {
int neg_count = 0;
for (int i = 0; i < list_size; i++) {
if (list[i] <= 0) {
neg_count += 1;
}
}
return neg_count;
}
| int main() {
int list1[] = {-1, -2, 3, -4, -5};
int list2[] = {1, 2, 3};
int list3[] = {1, 2, -3, -10, 20};
assert(func0(list1, 5) == 4);
assert(func0(list2, 3) == 0);
assert(func0(list3, 5) == 2);
return 0;
}
| O2 | c | func0:
endbr64
test %esi,%esi
jle 1270 <func0+0x30>
lea -0x1(%rsi),%eax
lea 0x4(%rdi,%rax,4),%rcx
xor %eax,%eax
nopw 0x0(%rax,%rax,1)
mov (%rdi),%esi
xor %edx,%edx
test %esi,%esi
setle %dl
add $0x4,%rdi
add %edx,%eax
cmp %rcx,%rdi
jne 1258 <func0+0x18>
retq
nopl (%rax)
xor %eax... | func0:
endbr64
test esi, esi
jle short loc_12C0
lea eax, [rsi-1]
lea rcx, [rdi+rax*4+4]
xor eax, eax
nop word ptr [rax+rax+00h]
loc_12A8:
mov esi, [rdi]
xor edx, edx
test esi, esi
setle dl
add rdi, 4
add eax, edx
cmp rdi, rcx
jnz short loc_12A8
retn
loc_12C0:
xor ... | long long func0(_DWORD *a1, int a2)
{
long long v2; // rcx
long long result; // rax
BOOL v4; // edx
if ( a2 <= 0 )
return 0LL;
v2 = (long long)&a1[a2 - 1 + 1];
LODWORD(result) = 0;
do
{
v4 = *a1++ <= 0;
result = (unsigned int)(v4 + result);
}
while ( a1 != (_DWORD *)v2 );
return resu... | func0:
ENDBR64
TEST ESI,ESI
JLE 0x001012c0
LEA EAX,[RSI + -0x1]
LEA RCX,[RDI + RAX*0x4 + 0x4]
XOR EAX,EAX
NOP word ptr [RAX + RAX*0x1]
LAB_001012a8:
MOV ESI,dword ptr [RDI]
XOR EDX,EDX
TEST ESI,ESI
SETLE DL
ADD RDI,0x4
ADD EAX,EDX
CMP RDI,RCX
JNZ 0x001012a8
RET
LAB_001012c0:
XOR EAX,EAX
RET | int func0(int *param_1,int param_2)
{
int *piVar1;
int iVar2;
int iVar3;
if (0 < param_2) {
piVar1 = param_1 + (ulong)(param_2 - 1) + 1;
iVar3 = 0;
do {
iVar2 = *param_1;
param_1 = param_1 + 1;
iVar3 = iVar3 + (uint)(iVar2 < 1);
} while (param_1 != piVar1);
return iVar3... |
5,211 | func0 |
#include <assert.h>
| int func0(int list[], int list_size) {
int neg_count = 0;
for (int i = 0; i < list_size; i++) {
if (list[i] <= 0) {
neg_count += 1;
}
}
return neg_count;
}
| int main() {
int list1[] = {-1, -2, 3, -4, -5};
int list2[] = {1, 2, 3};
int list3[] = {1, 2, -3, -10, 20};
assert(func0(list1, 5) == 4);
assert(func0(list2, 3) == 0);
assert(func0(list3, 5) == 2);
return 0;
}
| O3 | c | func0:
endbr64
test %esi,%esi
jle 1310 <func0+0xf0>
lea -0x1(%rsi),%eax
cmp $0x3,%eax
jbe 1313 <func0+0xf3>
mov %esi,%edx
pxor %xmm1,%xmm1
pcmpeqd %xmm2,%xmm2
mov %rdi,%rax
shr $0x2,%edx
movdqa %xmm1,%xmm3
shl $0x4,%rdx
add %rdi,%rdx
nopl 0x0(%rax,%rax,1)
movdqu (%rax),%xmm0
add $0x1... | func0:
endbr64
mov rcx, rdi
test esi, esi
jle loc_1220
lea eax, [rsi-1]
cmp eax, 2
jbe loc_1223
mov edx, esi
movdqa xmm2, cs:xmmword_2010
mov rax, rdi
pxor xmm0, xmm0
shr edx, 2
shl rdx, 4
add rdx, rdi
nop word ptr [rax+rax+00000000h]
loc_1180:
movdqu xmm3, xmmword pt... | long long func0(const __m128i *a1, int a2)
{
__m128i si128; // xmm2
const __m128i *v3; // rax
__m128i v4; // xmm0
__m128i v5; // xmm3
int v6; // edx
__m128i v7; // xmm0
long long result; // rax
long long v9; // r8
if ( a2 <= 0 )
return 0LL;
if ( (unsigned int)(a2 - 1) <= 2 )
{
v6 = 0;
... | func0:
ENDBR64
MOV RCX,RDI
TEST ESI,ESI
JLE 0x00101220
LEA EAX,[RSI + -0x1]
CMP EAX,0x2
JBE 0x00101223
MOV EDX,ESI
MOVDQA XMM2,xmmword ptr [0x00102010]
MOV RAX,RDI
PXOR XMM0,XMM0
SHR EDX,0x2
SHL RDX,0x4
ADD RDX,RDI
NOP word ptr CS:[RAX + RAX*0x1]
LAB_00101180:
MOVDQU XMM3,xmmword ptr [RAX]
MOVDQA XMM1,XMM2
ADD RAX,0x10... | /* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
int func0(int *param_1,uint param_2)
{
int iVar1;
int *piVar2;
int *piVar3;
int *piVar4;
int *piVar5;
uint uVar6;
int iVar7;
int iVar8;
int iVar9;
int iVar10;
if ((int)param_2 < 1) {
return 0;
}
if (p... |
5,212 | func0 |
#include <stdio.h>
#include <string.h>
#include <regex.h>
#include <assert.h>
| void func0(const char* text, char output[][6], int* count) {
regex_t regex;
regmatch_t pmatch[1];
const char* pattern = "\\b\\w{3,5}\\b";
regcomp(®ex, pattern, REG_EXTENDED);
const char* current = text;
*count = 0;
while (regexec(®ex, current, 1, pmatch, 0) == 0) {
... | int main() {
char words1[5][6];
int count1 = 0;
func0("For the four consumer complaints contact manager AKR reddy", words1, &count1);
assert(count1 == 5 && strcmp(words1[0], "For") == 0 && strcmp(words1[1], "the") == 0 && strcmp(words1[2], "four") == 0 && strcmp(words1[3], "AKR") == 0 && strcmp(word... | O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
sub $0x90,%rsp
mov %rdi,-0x78(%rbp)
mov %rsi,-0x80(%rbp)
mov %rdx,-0x88(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x8(%rbp)
xor %eax,%eax
lea 0xdcb(%rip),%rax
mov %rax,-0x58(%rbp)
mov -0x58(%rbp),%rcx
lea -0x50(%rbp),%rax
mov $0x1,%edx
mov %rcx,... | func0:
endbr64
push rbp
mov rbp, rsp
sub rsp, 90h
mov [rbp+var_78], rdi
mov [rbp+var_80], rsi
mov [rbp+var_88], rdx
mov rax, fs:28h
mov [rbp+var_8], rax
xor eax, eax
lea rax, aBW35B; "\\b\\w{3,5}\\b"
mov [rbp+pattern], rax
mov rcx, [rbp+pattern]
lea rax, [rbp+preg]
mov... | unsigned long long func0(const char *a1, long long a2, int *a3)
{
int i; // eax
regoff_t rm_eo; // [rsp+28h] [rbp-68h]
int v7; // [rsp+2Ch] [rbp-64h]
char *string; // [rsp+30h] [rbp-60h]
regex_t preg; // [rsp+40h] [rbp-50h] BYREF
regmatch_t pmatch; // [rsp+80h] [rbp-10h] BYREF
unsigned long long v11; // ... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x90
MOV qword ptr [RBP + -0x78],RDI
MOV qword ptr [RBP + -0x80],RSI
MOV qword ptr [RBP + -0x88],RDX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
XOR EAX,EAX
LEA RAX,[0x102008]
MOV qword ptr [RBP + -0x58],RAX
MOV RCX,qword ptr [RBP + -0x58]
LEA RAX,[RBP + -0x50]... | void func0(char *param_1,long param_2,int *param_3)
{
regoff_t rVar1;
int iVar2;
long in_FS_OFFSET;
char *local_68;
regex_t local_58;
regmatch_t local_18;
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
regcomp(&local_58,"\\b\\w{3,5}\\b",1);
*param_3 = 0;
local_68 = param_1;
while(... |
5,213 | func0 |
#include <stdio.h>
#include <string.h>
#include <regex.h>
#include <assert.h>
| void func0(const char* text, char output[][6], int* count) {
regex_t regex;
regmatch_t pmatch[1];
const char* pattern = "\\b\\w{3,5}\\b";
regcomp(®ex, pattern, REG_EXTENDED);
const char* current = text;
*count = 0;
while (regexec(®ex, current, 1, pmatch, 0) == 0) {
... | int main() {
char words1[5][6];
int count1 = 0;
func0("For the four consumer complaints contact manager AKR reddy", words1, &count1);
assert(count1 == 5 && strcmp(words1[0], "For") == 0 && strcmp(words1[1], "the") == 0 && strcmp(words1[2], "four") == 0 && strcmp(words1[3], "AKR") == 0 && strcmp(word... | O1 | c | func0:
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x58,%rsp
mov %rdi,%r13
mov %rsi,%r14
mov %rdx,%r12
mov %fs:0x28,%rax
mov %rax,0x48(%rsp)
xor %eax,%eax
mov %rsp,%rdi
mov $0x1,%edx
lea 0xde1(%rip),%rsi
callq 10e0 <regcomp@plt>
movl $0x0,(%r12)
... | func0:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 58h
mov r13, rdi
mov r14, rsi
mov r12, rdx
mov rax, fs:28h
mov [rsp+88h+var_40], rax
xor eax, eax
mov rdi, rsp
mov edx, 1
lea rsi, aBW35B; "\\b\\w{3,5}\\b"
call _regcomp
mov eax... | unsigned long long func0(long long a1, long long a2, int *a3)
{
int v5; // eax
int v6; // ebx
long long v7; // rbp
_BYTE v9[64]; // [rsp+0h] [rbp-88h] BYREF
int v10; // [rsp+40h] [rbp-48h] BYREF
int v11; // [rsp+44h] [rbp-44h]
unsigned long long v12; // [rsp+48h] [rbp-40h]
v12 = __readfsqword(0x28u);
... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x58
MOV R13,RDI
MOV R14,RSI
MOV R12,RDX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x48],RAX
XOR EAX,EAX
MOV RDI,RSP
MOV EDX,0x1
LEA RSI,[0x102004]
CALL 0x001010f0
MOV EAX,0x0
LEA R15,[RSP + 0x40]
JMP 0x0010129a
LAB_00101254:
MOV ESI,dw... | void func0(char *param_1,long param_2,int *param_3)
{
regoff_t rVar1;
int iVar2;
long in_FS_OFFSET;
regex_t rStack_88;
regmatch_t local_48;
long local_40;
local_40 = *(long *)(in_FS_OFFSET + 0x28);
regcomp(&rStack_88,"\\b\\w{3,5}\\b",1);
iVar2 = 0;
while( true ) {
*param_3 = iVar2;
iVar2... |
5,214 | func0 |
#include <stdio.h>
#include <string.h>
#include <regex.h>
#include <assert.h>
| void func0(const char* text, char output[][6], int* count) {
regex_t regex;
regmatch_t pmatch[1];
const char* pattern = "\\b\\w{3,5}\\b";
regcomp(®ex, pattern, REG_EXTENDED);
const char* current = text;
*count = 0;
while (regexec(®ex, current, 1, pmatch, 0) == 0) {
... | int main() {
char words1[5][6];
int count1 = 0;
func0("For the four consumer complaints contact manager AKR reddy", words1, &count1);
assert(count1 == 5 && strcmp(words1[0], "For") == 0 && strcmp(words1[1], "the") == 0 && strcmp(words1[2], "four") == 0 && strcmp(words1[3], "AKR") == 0 && strcmp(word... | O2 | c | func0:
endbr64
push %r15
mov %rdi,%r15
push %r14
push %r13
push %r12
push %rbp
mov %rsi,%rbp
lea 0xc4a(%rip),%rsi
push %rbx
mov %rdx,%rbx
mov $0x1,%edx
sub $0x68,%rsp
mov %fs:0x28,%rax
mov %rax,0x58(%rsp)
xor %eax,%eax
lea 0x10(%rsp),%r12
lea 0x50(%rsp),%r13
mov %r12,%rdi... | func0:
endbr64
push r15
mov r15, rdi
push r14
mov r14, rdx
mov edx, 1
push r13
push r12
push rbp
push rbx
mov rbx, rsi
lea rsi, aBW35B; "\\b\\w{3,5}\\b"
sub rsp, 68h
mov rax, fs:28h
mov [rsp+98h+var_40], rax
xor eax, eax
lea rbp, [rsp+98h+var_88]
lea r12, [r... | unsigned long long func0(long long a1, long long a2, int *a3)
{
int i; // eax
long long v7; // rsi
long long v9; // [rsp+8h] [rbp-90h]
_BYTE v10[64]; // [rsp+10h] [rbp-88h] BYREF
int v11; // [rsp+50h] [rbp-48h] BYREF
int v12; // [rsp+54h] [rbp-44h]
unsigned long long v13; // [rsp+58h] [rbp-40h]
v13 = ... | func0:
ENDBR64
PUSH R15
MOV R15,RDI
PUSH R14
MOV R14,RDX
MOV EDX,0x1
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
MOV RBX,RSI
LEA RSI,[0x102004]
SUB RSP,0x68
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x58],RAX
XOR EAX,EAX
LEA RBP,[RSP + 0x10]
LEA R12,[RSP + 0x50]
MOV RDI,RBP
CALL 0x001010f0
XOR EAX,EAX
JMP 0x00101447
LAB... | void func0(char *param_1,long param_2,int *param_3)
{
int iVar1;
char *__src;
long in_FS_OFFSET;
regex_t local_88;
regmatch_t local_48;
long local_40;
local_40 = *(long *)(in_FS_OFFSET + 0x28);
regcomp(&local_88,"\\b\\w{3,5}\\b",1);
iVar1 = 0;
while( true ) {
*param_3 = iVar1;
iVar1 = re... |
5,215 | func0 |
#include <stdio.h>
#include <string.h>
#include <regex.h>
#include <assert.h>
| void func0(const char* text, char output[][6], int* count) {
regex_t regex;
regmatch_t pmatch[1];
const char* pattern = "\\b\\w{3,5}\\b";
regcomp(®ex, pattern, REG_EXTENDED);
const char* current = text;
*count = 0;
while (regexec(®ex, current, 1, pmatch, 0) == 0) {
... | int main() {
char words1[5][6];
int count1 = 0;
func0("For the four consumer complaints contact manager AKR reddy", words1, &count1);
assert(count1 == 5 && strcmp(words1[0], "For") == 0 && strcmp(words1[1], "the") == 0 && strcmp(words1[2], "four") == 0 && strcmp(words1[3], "AKR") == 0 && strcmp(word... | O3 | c | func0:
endbr64
push %r15
mov %rdi,%r15
push %r14
push %r13
push %r12
push %rbp
mov %rsi,%rbp
lea 0xc4a(%rip),%rsi
push %rbx
mov %rdx,%rbx
mov $0x1,%edx
sub $0x68,%rsp
mov %fs:0x28,%rax
mov %rax,0x58(%rsp)
xor %eax,%eax
lea 0x10(%rsp),%r12
lea 0x50(%rsp),%r13
mov %r12,%rdi... | func0:
endbr64
push r15
mov r15, rdx
mov edx, 1; cflags
push r14
push r13
push r12
push rbp
mov rbp, rsi
lea rsi, pattern; "\\b\\w{3,5}\\b"
push rbx
mov rbx, rdi
sub rsp, 68h
mov rax, fs:28h
mov [rsp+98h+var_40], rax
xor eax, eax
lea r12, [rsp+98h+preg]
mov ... | unsigned long long func0(char *string, long long a2, int *a3)
{
int i; // eax
const char *v7; // rsi
size_t v8; // r13
regex_t preg; // [rsp+10h] [rbp-88h] BYREF
regmatch_t v11; // [rsp+50h] [rbp-48h] BYREF
unsigned long long v12; // [rsp+58h] [rbp-40h]
v12 = __readfsqword(0x28u);
regcomp(&preg, "\\b\... | func0:
ENDBR64
PUSH R15
MOV R15,RDX
MOV EDX,0x1
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
MOV RBP,RSI
LEA RSI,[0x102004]
PUSH RBX
MOV RBX,RDI
SUB RSP,0x68
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x58],RAX
XOR EAX,EAX
LEA R12,[RSP + 0x10]
MOV RDI,R12
CALL 0x001010f0
LEA RCX,[RSP + 0x50]
XOR EAX,EAX
MOV qword ptr [RSP... | void func0(char *param_1,long param_2,int *param_3)
{
int iVar1;
char *__src;
long in_FS_OFFSET;
regex_t local_88;
regmatch_t local_48;
long local_40;
local_40 = *(long *)(in_FS_OFFSET + 0x28);
regcomp(&local_88,"\\b\\w{3,5}\\b",1);
iVar1 = 0;
while( true ) {
*param_3 = iVar1;
iVar1 = re... |
5,216 | func0 |
#include <assert.h>
| int func0(int n) {
int count = 0;
int x = 1;
while (x < n + 1) {
if ((x & n) == 0) {
count += 1;
}
x = x << 1;
}
return count;
}
| int main() {
assert(func0(2) == 1);
assert(func0(4) == 2);
assert(func0(6) == 1);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
mov %edi,-0x14(%rbp)
movl $0x0,-0x8(%rbp)
movl $0x1,-0x4(%rbp)
jmp 1175 <func0+0x2c>
mov -0x4(%rbp),%eax
and -0x14(%rbp),%eax
test %eax,%eax
jne 1172 <func0+0x29>
addl $0x1,-0x8(%rbp)
shll -0x4(%rbp)
mov -0x14(%rbp),%eax
cmp -0x4(%rbp),%eax
jge ... | func0:
endbr64
push rbp
mov rbp, rsp
mov [rbp+var_14], edi
mov [rbp+var_8], 0
mov [rbp+var_4], 1
jmp short loc_1175
loc_1164:
mov eax, [rbp+var_4]
and eax, [rbp+var_14]
test eax, eax
jnz short loc_1172
add [rbp+var_8], 1
loc_1172:
shl [rbp+var_4], 1
loc_1175:
mov eax, [... | long long func0(int a1)
{
unsigned int v2; // [rsp+Ch] [rbp-8h]
int i; // [rsp+10h] [rbp-4h]
v2 = 0;
for ( i = 1; a1 >= i; i *= 2 )
{
if ( (a1 & i) == 0 )
++v2;
}
return v2;
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
MOV dword ptr [RBP + -0x14],EDI
MOV dword ptr [RBP + -0x8],0x0
MOV dword ptr [RBP + -0x4],0x1
JMP 0x00101175
LAB_00101164:
MOV EAX,dword ptr [RBP + -0x4]
AND EAX,dword ptr [RBP + -0x14]
TEST EAX,EAX
JNZ 0x00101172
ADD dword ptr [RBP + -0x8],0x1
LAB_00101172:
SHL dword ptr [RBP + -0x4... | int func0(uint param_1)
{
int4 local_10;
int4 local_c;
local_10 = 0;
for (local_c = 1; (int)local_c <= (int)param_1; local_c = local_c << 1) {
if ((local_c & param_1) == 0) {
local_10 = local_10 + 1;
}
}
return local_10;
} |
5,217 | func0 |
#include <assert.h>
| int func0(int n) {
int count = 0;
int x = 1;
while (x < n + 1) {
if ((x & n) == 0) {
count += 1;
}
x = x << 1;
}
return count;
}
| int main() {
assert(func0(2) == 1);
assert(func0(4) == 2);
assert(func0(6) == 1);
return 0;
}
| O1 | c | func0:
endbr64
test %edi,%edi
jle 116e <func0+0x25>
mov $0x1,%eax
mov $0x0,%edx
mov %edi,%ecx
and %eax,%ecx
cmp $0x1,%ecx
adc $0x0,%edx
add %eax,%eax
cmp %eax,%edi
jge 115b <func0+0x12>
mov %edx,%eax
retq
mov $0x0,%edx
jmp 116b <func0+0x22>
| func0:
endbr64
test edi, edi
jle short loc_116E
mov eax, 1
mov edx, 0
loc_115B:
mov ecx, edi
and ecx, eax
cmp ecx, 1
adc edx, 0
add eax, eax
cmp edi, eax
jge short loc_115B
loc_116B:
mov eax, edx
retn
loc_116E:
mov edx, 0
jmp short loc_116B | long long func0(int a1)
{
int v1; // eax
unsigned int v2; // edx
if ( a1 <= 0 )
{
return 0;
}
else
{
v1 = 1;
v2 = 0;
do
{
v2 += (v1 & a1) == 0;
v1 *= 2;
}
while ( a1 >= v1 );
}
return v2;
} | func0:
ENDBR64
TEST EDI,EDI
JLE 0x0010116e
MOV EAX,0x1
MOV EDX,0x0
LAB_0010115b:
MOV ECX,EDI
AND ECX,EAX
CMP ECX,0x1
ADC EDX,0x0
ADD EAX,EAX
CMP EDI,EAX
JGE 0x0010115b
LAB_0010116b:
MOV EAX,EDX
RET
LAB_0010116e:
MOV EDX,0x0
JMP 0x0010116b | int func0(uint param_1)
{
uint uVar1;
int iVar2;
if ((int)param_1 < 1) {
iVar2 = 0;
}
else {
uVar1 = 1;
iVar2 = 0;
do {
iVar2 = iVar2 + (uint)((param_1 & uVar1) == 0);
uVar1 = uVar1 * 2;
} while ((int)uVar1 <= (int)param_1);
}
return iVar2;
} |
5,218 | func0 |
#include <assert.h>
| int func0(int n) {
int count = 0;
int x = 1;
while (x < n + 1) {
if ((x & n) == 0) {
count += 1;
}
x = x << 1;
}
return count;
}
| int main() {
assert(func0(2) == 1);
assert(func0(4) == 2);
assert(func0(6) == 1);
return 0;
}
| O2 | c | func0:
endbr64
test %edi,%edi
jle 1218 <func0+0x28>
mov $0x1,%eax
xor %r8d,%r8d
mov %edi,%edx
and %eax,%edx
cmp $0x1,%edx
adc $0x0,%r8d
add %eax,%eax
cmp %eax,%edi
jge 1200 <func0+0x10>
mov %r8d,%eax
retq
nopl (%rax)
xor %r8d,%r8d
mov %r8d,%eax
retq
| func0:
endbr64
test edi, edi
jle short loc_1218
mov eax, 1
xor r8d, r8d
loc_1200:
mov edx, edi
and edx, eax
cmp edx, 1
adc r8d, 0
add eax, eax
cmp edi, eax
jge short loc_1200
mov eax, r8d
retn
loc_1218:
xor r8d, r8d
mov eax, r8d
retn | long long func0(int a1)
{
int v1; // eax
unsigned int v2; // r8d
if ( a1 <= 0 )
return 0LL;
v1 = 1;
v2 = 0;
do
{
v2 += (v1 & a1) == 0;
v1 *= 2;
}
while ( a1 >= v1 );
return v2;
} | func0:
ENDBR64
TEST EDI,EDI
JLE 0x00101218
MOV EAX,0x1
XOR R8D,R8D
LAB_00101200:
MOV EDX,EDI
AND EDX,EAX
CMP EDX,0x1
ADC R8D,0x0
ADD EAX,EAX
CMP EDI,EAX
JGE 0x00101200
MOV EAX,R8D
RET
LAB_00101218:
XOR R8D,R8D
MOV EAX,R8D
RET | int func0(uint param_1)
{
uint uVar1;
int iVar2;
if (0 < (int)param_1) {
uVar1 = 1;
iVar2 = 0;
do {
iVar2 = iVar2 + (uint)((param_1 & uVar1) == 0);
uVar1 = uVar1 * 2;
} while ((int)uVar1 <= (int)param_1);
return iVar2;
}
return 0;
} |
5,219 | func0 |
#include <assert.h>
| int func0(int n) {
int count = 0;
int x = 1;
while (x < n + 1) {
if ((x & n) == 0) {
count += 1;
}
x = x << 1;
}
return count;
}
| int main() {
assert(func0(2) == 1);
assert(func0(4) == 2);
assert(func0(6) == 1);
return 0;
}
| O3 | c | func0:
endbr64
test %edi,%edi
jle 1168 <func0+0x28>
mov $0x1,%eax
xor %r8d,%r8d
mov %edi,%edx
and %eax,%edx
cmp $0x1,%edx
adc $0x0,%r8d
add %eax,%eax
cmp %eax,%edi
jge 1150 <func0+0x10>
mov %r8d,%eax
retq
nopl (%rax)
xor %r8d,%r8d
mov %r8d,%eax
retq
| func0:
endbr64
test edi, edi
jle short loc_1168
mov eax, 1
xor edx, edx
nop
loc_1150:
mov ecx, edi
and ecx, eax
cmp ecx, 1
adc edx, 0
add eax, eax
cmp edi, eax
jge short loc_1150
mov eax, edx
retn
loc_1168:
xor edx, edx
mov eax, edx
retn | long long func0(int a1)
{
int v1; // eax
unsigned int v2; // edx
if ( a1 <= 0 )
return 0LL;
v1 = 1;
v2 = 0;
do
{
v2 += (v1 & a1) == 0;
v1 *= 2;
}
while ( a1 >= v1 );
return v2;
} | func0:
ENDBR64
TEST EDI,EDI
JLE 0x00101168
MOV EAX,0x1
XOR EDX,EDX
NOP
LAB_00101150:
MOV ECX,EDI
AND ECX,EAX
CMP ECX,0x1
ADC EDX,0x0
ADD EAX,EAX
CMP EDI,EAX
JGE 0x00101150
MOV EAX,EDX
RET
LAB_00101168:
XOR EDX,EDX
MOV EAX,EDX
RET | int func0(uint param_1)
{
uint uVar1;
int iVar2;
if (0 < (int)param_1) {
uVar1 = 1;
iVar2 = 0;
do {
iVar2 = iVar2 + (uint)((param_1 & uVar1) == 0);
uVar1 = uVar1 * 2;
} while ((int)uVar1 <= (int)param_1);
return iVar2;
}
return 0;
} |
5,220 | func0 |
#include <stdio.h>
#include <assert.h>
#include <string.h>
#include <stdlib.h>
#define NUM_CHARS 256
| int* func0(const char* str) {
int* freq = calloc(NUM_CHARS, sizeof(int));
if (freq == NULL) {
perror("Failed to allocate memory");
exit(EXIT_FAILURE);
}
for(int i = 0; str[i] != '\0'; i++) {
unsigned char c = str[i];
freq[c]++;
}
return freq;
}
| int main() {
// Test case 1: "python"
int* freq1 = func0("python");
assert(freq1['p'] == 1);
assert(freq1['y'] == 1);
assert(freq1['t'] == 1);
assert(freq1['h'] == 1);
assert(freq1['o'] == 1);
assert(freq1['n'] == 1);
free(freq1);
// Test case 2: "program"
int* f... | O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
sub $0x20,%rsp
mov %rdi,-0x18(%rbp)
mov $0x4,%esi
mov $0x100,%edi
callq 10b0 <calloc@plt>
mov %rax,-0x8(%rbp)
cmpq $0x0,-0x8(%rbp)
jne 1209 <func0+0x40>
lea 0xe0e(%rip),%rdi
callq 10c0 <perror@plt>
mov $0x1,%edi
callq 10d0 <exit@plt>
movl $0x0,-... | func0:
endbr64
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+var_18], rdi
mov esi, 4; size
mov edi, 100h; nmemb
call _calloc
mov [rbp+var_8], rax
cmp [rbp+var_8], 0
jnz short loc_120C
lea rax, s; "Failed to allocate memory"
mov rdi, rax; s
call _perror
mov edi, 1; stat... | char * func0(long long a1)
{
char *v1; // rax
int i; // [rsp+14h] [rbp-Ch]
char *v4; // [rsp+18h] [rbp-8h]
v4 = (char *)calloc(0x100uLL, 4uLL);
if ( !v4 )
{
perror("Failed to allocate memory");
exit(1);
}
for ( i = 0; *(_BYTE *)(i + a1); ++i )
{
v1 = &v4[4 * *(unsigned __int8 *)(i + a1)];... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x18],RDI
MOV ESI,0x4
MOV EDI,0x100
CALL 0x001010b0
MOV qword ptr [RBP + -0x8],RAX
CMP qword ptr [RBP + -0x8],0x0
JNZ 0x0010120c
LEA RAX,[0x102004]
MOV RDI,RAX
CALL 0x001010c0
MOV EDI,0x1
CALL 0x001010d0
LAB_0010120c:
MOV dword ptr [RBP + -0xc],0x0
... | void * func0(long param_1)
{
void *pvVar1;
int *piVar2;
int local_14;
pvVar1 = calloc(0x100,4);
if (pvVar1 == (void *)0x0) {
perror("Failed to allocate memory");
/* WARNING: Subroutine does not return */
exit(1);
}
for (local_14 = 0; *(char *)(param_1 + local_14) != '\0'; l... |
5,221 | func0 |
#include <stdio.h>
#include <assert.h>
#include <string.h>
#include <stdlib.h>
#define NUM_CHARS 256
| int* func0(const char* str) {
int* freq = calloc(NUM_CHARS, sizeof(int));
if (freq == NULL) {
perror("Failed to allocate memory");
exit(EXIT_FAILURE);
}
for(int i = 0; str[i] != '\0'; i++) {
unsigned char c = str[i];
freq[c]++;
}
return freq;
}
| int main() {
// Test case 1: "python"
int* freq1 = func0("python");
assert(freq1['p'] == 1);
assert(freq1['y'] == 1);
assert(freq1['t'] == 1);
assert(freq1['h'] == 1);
assert(freq1['o'] == 1);
assert(freq1['n'] == 1);
free(freq1);
// Test case 2: "program"
int* f... | O1 | c | func0:
endbr64
push %rbx
mov %rdi,%rbx
mov $0x4,%esi
mov $0x100,%edi
callq 10b0 <calloc@plt>
test %rax,%rax
je 1205 <func0+0x3c>
movzbl (%rbx),%edx
lea 0x1(%rbx),%rdi
test %dl,%dl
je 1203 <func0+0x3a>
movzbl %dl,%edx
addl $0x1,(%rax,%rdx,4)
add $0x1,%rdi
movzbl -0x1(%rdi),%edx
test %dl... | func0:
endbr64
push rbx
mov rbx, rdi
mov esi, 4
mov edi, 100h
call _calloc
test rax, rax
jz short loc_1205
movzx edx, byte ptr [rbx]
lea rdi, [rbx+1]
test dl, dl
jz short loc_1203
loc_11F0:
movzx edx, dl
add dword ptr [rax+rdx*4], 1
add rdi, 1
movzx edx, byte ptr [rdi... | long long func0(unsigned __int8 *a1)
{
long long result; // rax
unsigned __int8 v3; // dl
_BYTE *i; // rdi
result = calloc(256LL, 4LL);
if ( !result )
{
perror("Failed to allocate memory");
exit(1LL);
}
v3 = *a1;
for ( i = a1 + 1; v3; v3 = *(i - 1) )
{
++*(_DWORD *)(result + 4LL * v3);... | func0:
ENDBR64
PUSH RBX
MOV RBX,RDI
MOV ESI,0x4
MOV EDI,0x100
CALL 0x001010b0
TEST RAX,RAX
JZ 0x00101205
MOVZX EDX,byte ptr [RBX]
LEA RDI,[RBX + 0x1]
TEST DL,DL
JZ 0x00101203
LAB_001011f0:
MOVZX EDX,DL
ADD dword ptr [RAX + RDX*0x4],0x1
ADD RDI,0x1
MOVZX EDX,byte ptr [RDI + -0x1]
TEST DL,DL
JNZ 0x001011f0
LAB_00101203:
... | void func0(byte *param_1)
{
int *piVar1;
byte bVar2;
byte *pbVar3;
void *pvVar4;
pvVar4 = calloc(0x100,4);
if (pvVar4 == (void *)0x0) {
perror("Failed to allocate memory");
/* WARNING: Subroutine does not return */
exit(1);
}
bVar2 = *param_1;
pbVar3 = param_1 + 1;
wh... |
5,222 | func0 |
#include <stdio.h>
#include <assert.h>
#include <string.h>
#include <stdlib.h>
#define NUM_CHARS 256
| int* func0(const char* str) {
int* freq = calloc(NUM_CHARS, sizeof(int));
if (freq == NULL) {
perror("Failed to allocate memory");
exit(EXIT_FAILURE);
}
for(int i = 0; str[i] != '\0'; i++) {
unsigned char c = str[i];
freq[c]++;
}
return freq;
}
| int main() {
// Test case 1: "python"
int* freq1 = func0("python");
assert(freq1['p'] == 1);
assert(freq1['y'] == 1);
assert(freq1['t'] == 1);
assert(freq1['h'] == 1);
assert(freq1['o'] == 1);
assert(freq1['n'] == 1);
free(freq1);
// Test case 2: "program"
int* f... | O2 | c | func0:
endbr64
push %rbx
mov $0x4,%esi
mov %rdi,%rbx
mov $0x100,%edi
callq 10b0 <calloc@plt>
test %rax,%rax
je 1575 <func0+0x45>
movzbl (%rbx),%edx
lea 0x1(%rbx),%rdi
test %dl,%dl
je 1573 <func0+0x43>
nopw 0x0(%rax,%rax,1)
movzbl %dl,%edx
add $0x1,%rdi
addl $0x1,(%rax,%rdx,4)
movzbl -0... | func0:
endbr64
push rbx
mov esi, 4
mov rbx, rdi
mov edi, 100h
call _calloc
test rax, rax
jz short loc_1572
movzx edx, byte ptr [rbx]
lea rdi, [rbx+1]
test dl, dl
jz short loc_1570
nop word ptr [rax+rax+00000000h]
loc_1560:
add rdi, 1
add dword ptr [rax+rdx*4], 1
movzx... | long long func0(unsigned __int8 *a1)
{
long long result; // rax
long long v2; // rdx
unsigned __int8 *i; // rdi
result = calloc(256LL, 4LL);
if ( !result )
{
perror("Failed to allocate memory");
exit(1LL);
}
v2 = *a1;
for ( i = a1 + 1; (_BYTE)v2; v2 = *(i - 1) )
{
++i;
++*(_DWORD *... | func0:
ENDBR64
PUSH RBX
MOV ESI,0x4
MOV RBX,RDI
MOV EDI,0x100
CALL 0x001010b0
TEST RAX,RAX
JZ 0x00101572
MOVZX EDX,byte ptr [RBX]
LEA RDI,[RBX + 0x1]
TEST DL,DL
JZ 0x00101570
NOP word ptr [RAX + RAX*0x1]
LAB_00101560:
ADD RDI,0x1
ADD dword ptr [RAX + RDX*0x4],0x1
MOVZX EDX,byte ptr [RDI + -0x1]
TEST DL,DL
JNZ 0x0010156... | void func0(byte *param_1)
{
int *piVar1;
byte bVar2;
byte *pbVar3;
void *pvVar4;
pvVar4 = calloc(0x100,4);
if (pvVar4 != (void *)0x0) {
bVar2 = *param_1;
pbVar3 = param_1 + 1;
while (bVar2 != 0) {
piVar1 = (int *)((long)pvVar4 + (ulong)bVar2 * 4);
*piVar1 = *piVar1 + 1;
bVa... |
5,223 | func0 |
#include <stdio.h>
#include <assert.h>
#include <string.h>
#include <stdlib.h>
#define NUM_CHARS 256
| int* func0(const char* str) {
int* freq = calloc(NUM_CHARS, sizeof(int));
if (freq == NULL) {
perror("Failed to allocate memory");
exit(EXIT_FAILURE);
}
for(int i = 0; str[i] != '\0'; i++) {
unsigned char c = str[i];
freq[c]++;
}
return freq;
}
| int main() {
// Test case 1: "python"
int* freq1 = func0("python");
assert(freq1['p'] == 1);
assert(freq1['y'] == 1);
assert(freq1['t'] == 1);
assert(freq1['h'] == 1);
assert(freq1['o'] == 1);
assert(freq1['n'] == 1);
free(freq1);
// Test case 2: "program"
int* f... | O3 | c | func0:
endbr64
push %rbx
mov $0x4,%esi
mov %rdi,%rbx
mov $0x100,%edi
callq 10b0 <calloc@plt>
test %rax,%rax
je 1575 <func0+0x45>
movzbl (%rbx),%edx
lea 0x1(%rbx),%rdi
test %dl,%dl
je 1573 <func0+0x43>
nopw 0x0(%rax,%rax,1)
movzbl %dl,%edx
add $0x1,%rdi
addl $0x1,(%rax,%rdx,4)
movzbl -0... | func0:
endbr64
push rbx
mov esi, 4; size
mov rbx, rdi
mov edi, 100h; nmemb
call _calloc
test rax, rax
jz func0_cold
movzx edx, byte ptr [rbx]
lea rdi, [rbx+1]
test dl, dl
jz short loc_1590
nop dword ptr [rax+rax+00h]
loc_1580:
add rdi, 1
add dword ptr [rax+rdx*4], 1
m... | _DWORD * func0(unsigned __int8 *a1)
{
_DWORD *result; // rax
long long v2; // rdx
unsigned __int8 *i; // rdi
result = calloc(0x100uLL, 4uLL);
if ( !result )
func0_cold();
v2 = *a1;
for ( i = a1 + 1; (_BYTE)v2; v2 = *(i - 1) )
{
++i;
++result[v2];
}
return result;
} | func0:
ENDBR64
PUSH RBX
MOV ESI,0x4
MOV RBX,RDI
MOV EDI,0x100
CALL 0x001010b0
TEST RAX,RAX
JZ 0x001010e0
MOVZX EDX,byte ptr [RBX]
LEA RDI,[RBX + 0x1]
TEST DL,DL
JZ 0x00101590
NOP dword ptr [RAX + RAX*0x1]
LAB_00101580:
ADD RDI,0x1
ADD dword ptr [RAX + RDX*0x4],0x1
MOVZX EDX,byte ptr [RDI + -0x1]
TEST DL,DL
JNZ 0x001015... | void func0(byte *param_1)
{
int *piVar1;
byte bVar2;
byte *pbVar3;
void *pvVar4;
pvVar4 = calloc(0x100,4);
if (pvVar4 != (void *)0x0) {
bVar2 = *param_1;
pbVar3 = param_1 + 1;
while (bVar2 != 0) {
piVar1 = (int *)((long)pvVar4 + (ulong)bVar2 * 4);
*piVar1 = *piVar1 + 1;
bVa... |
5,224 | func0 | #include <stdio.h>
#include <stdlib.h>
#include <assert.h>
typedef struct {
char* str;
int num;
} pair;
int compare_pairs(const void* a, const void* b) {
const pair* pa = (const pair*)a;
const pair* pb = (const pair*)b;
return (pa->num - pb->num);
}
| void func0(pair* sub_li, size_t n) {
qsort(sub_li, n, sizeof(pair), compare_pairs);
}
| int main() {
pair array1[] = {{"a", 10}, {"b", 5}, {"c", 20}, {"d", 15}};
pair expected1[] = {{"b", 5}, {"a", 10}, {"d", 15}, {"c", 20}};
size_t size1 = sizeof(array1) / sizeof(array1[0]);
pair array2[] = {{"452", 10}, {"256", 5}, {"100", 20}, {"135", 15}};
pair expected2[] = {{"256", 5}, {"4... | O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
sub $0x10,%rsp
mov %rdi,-0x8(%rbp)
mov %rsi,-0x10(%rbp)
mov -0x10(%rbp),%rsi
mov -0x8(%rbp),%rax
lea -0x57(%rip),%rcx
mov $0x10,%edx
mov %rax,%rdi
callq 1070 <qsort@plt>
leaveq
retq
| func0:
endbr64
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+base], rdi
mov [rbp+nmemb], rsi
mov rsi, [rbp+nmemb]; nmemb
mov rax, [rbp+base]
lea rdx, compare_pairs
mov rcx, rdx; compar
mov edx, 10h; size
mov rdi, rax; base
call _qsort
nop
leave
retn | void func0(void *a1, size_t a2)
{
qsort(a1, a2, 0x10uLL, compare_pairs);
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV qword ptr [RBP + -0x10],RSI
MOV RSI,qword ptr [RBP + -0x10]
MOV RAX,qword ptr [RBP + -0x8]
LEA RDX,[0x101189]
MOV RCX,RDX
MOV EDX,0x10
MOV RDI,RAX
CALL 0x00101070
NOP
LEAVE
RET | void func0(void *param_1,size_t param_2)
{
qsort(param_1,param_2,0x10,compare_pairs);
return;
} |
5,225 | func0 | #include <stdio.h>
#include <stdlib.h>
#include <assert.h>
typedef struct {
char* str;
int num;
} pair;
int compare_pairs(const void* a, const void* b) {
const pair* pa = (const pair*)a;
const pair* pb = (const pair*)b;
return (pa->num - pb->num);
}
| void func0(pair* sub_li, size_t n) {
qsort(sub_li, n, sizeof(pair), compare_pairs);
}
| int main() {
pair array1[] = {{"a", 10}, {"b", 5}, {"c", 20}, {"d", 15}};
pair expected1[] = {{"b", 5}, {"a", 10}, {"d", 15}, {"c", 20}};
size_t size1 = sizeof(array1) / sizeof(array1[0]);
pair array2[] = {{"452", 10}, {"256", 5}, {"100", 20}, {"135", 15}};
pair expected2[] = {{"256", 5}, {"4... | O1 | c | func0:
endbr64
sub $0x8,%rsp
lea -0x1a(%rip),%rcx
mov $0x10,%edx
callq 1070 <qsort@plt>
add $0x8,%rsp
retq
| func0:
endbr64
sub rsp, 8
lea rcx, compare_pairs
mov edx, 10h
call _qsort
add rsp, 8
retn | long long func0(long long a1, long long a2)
{
return qsort(a1, a2, 16LL, compare_pairs);
} | func0:
ENDBR64
SUB RSP,0x8
LEA RCX,[0x101189]
MOV EDX,0x10
CALL 0x00101070
ADD RSP,0x8
RET | void func0(void *param_1,size_t param_2)
{
qsort(param_1,param_2,0x10,compare_pairs);
return;
} |
5,226 | func0 | #include <stdio.h>
#include <stdlib.h>
#include <assert.h>
typedef struct {
char* str;
int num;
} pair;
int compare_pairs(const void* a, const void* b) {
const pair* pa = (const pair*)a;
const pair* pb = (const pair*)b;
return (pa->num - pb->num);
}
| void func0(pair* sub_li, size_t n) {
qsort(sub_li, n, sizeof(pair), compare_pairs);
}
| int main() {
pair array1[] = {{"a", 10}, {"b", 5}, {"c", 20}, {"d", 15}};
pair expected1[] = {{"b", 5}, {"a", 10}, {"d", 15}, {"c", 20}};
size_t size1 = sizeof(array1) / sizeof(array1[0]);
pair array2[] = {{"452", 10}, {"256", 5}, {"100", 20}, {"135", 15}};
pair expected2[] = {{"256", 5}, {"4... | O2 | c | func0:
endbr64
lea -0x1b(%rip),%rcx
mov $0x10,%edx
jmpq 1070 <qsort@plt>
nopw %cs:0x0(%rax,%rax,1)
| func0:
endbr64
lea rcx, compare_pairs
mov edx, 10h
jmp _qsort | long long func0(long long a1, long long a2)
{
return qsort(a1, a2, 16LL, compare_pairs);
} | func0:
ENDBR64
LEA RCX,[0x101490]
MOV EDX,0x10
JMP 0x00101070 | void func0(void *param_1,size_t param_2)
{
qsort(param_1,param_2,0x10,compare_pairs);
return;
} |
5,227 | func0 | #include <stdio.h>
#include <stdlib.h>
#include <assert.h>
typedef struct {
char* str;
int num;
} pair;
int compare_pairs(const void* a, const void* b) {
const pair* pa = (const pair*)a;
const pair* pb = (const pair*)b;
return (pa->num - pb->num);
}
| void func0(pair* sub_li, size_t n) {
qsort(sub_li, n, sizeof(pair), compare_pairs);
}
| int main() {
pair array1[] = {{"a", 10}, {"b", 5}, {"c", 20}, {"d", 15}};
pair expected1[] = {{"b", 5}, {"a", 10}, {"d", 15}, {"c", 20}};
size_t size1 = sizeof(array1) / sizeof(array1[0]);
pair array2[] = {{"452", 10}, {"256", 5}, {"100", 20}, {"135", 15}};
pair expected2[] = {{"256", 5}, {"4... | O3 | c | func0:
endbr64
lea -0x1b(%rip),%rcx
mov $0x10,%edx
jmpq 1070 <qsort@plt>
nopw %cs:0x0(%rax,%rax,1)
| func0:
endbr64
lea rcx, compare_pairs; compar
mov edx, 10h; size
jmp _qsort | void func0(void *a1, size_t a2)
{
qsort(a1, a2, 0x10uLL, compare_pairs);
} | func0:
ENDBR64
LEA RCX,[0x101400]
MOV EDX,0x10
JMP 0x00101070 | void func0(void *param_1,size_t param_2)
{
qsort(param_1,param_2,0x10,compare_pairs);
return;
} |
5,228 | func0 |
#include <assert.h>
#include <stdbool.h>
| bool func0(int a, int b, int c) {
if ((a + b <= c) || (a + c <= b) || (b + c <= a)) {
return false;
} else {
return true;
}
}
| int main() {
assert(func0(1, 2, 3) == false);
assert(func0(2, 3, 5) == false);
assert(func0(7, 10, 5) == true);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
mov %edi,-0x4(%rbp)
mov %esi,-0x8(%rbp)
mov %edx,-0xc(%rbp)
mov -0x4(%rbp),%edx
mov -0x8(%rbp),%eax
add %edx,%eax
cmp %eax,-0xc(%rbp)
jge 1181 <func0+0x38>
mov -0x4(%rbp),%edx
mov -0xc(%rbp),%eax
add %edx,%eax
cmp %eax,-0x8(%rbp)
jge 118... | func0:
endbr64
push rbp
mov rbp, rsp
mov [rbp+var_4], edi
mov [rbp+var_8], esi
mov [rbp+var_C], edx
mov edx, [rbp+var_4]
mov eax, [rbp+var_8]
add eax, edx
cmp [rbp+var_C], eax
jge short loc_1181
mov edx, [rbp+var_4]
mov eax, [rbp+var_C]
add eax, edx
cmp [rbp+var_8]... | _BOOL8 func0(int a1, int a2, int a3)
{
return a3 < a1 + a2 && a2 < a1 + a3 && a1 < a2 + a3;
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
MOV dword ptr [RBP + -0x4],EDI
MOV dword ptr [RBP + -0x8],ESI
MOV dword ptr [RBP + -0xc],EDX
MOV EDX,dword ptr [RBP + -0x4]
MOV EAX,dword ptr [RBP + -0x8]
ADD EAX,EDX
CMP dword ptr [RBP + -0xc],EAX
JGE 0x00101181
MOV EDX,dword ptr [RBP + -0x4]
MOV EAX,dword ptr [RBP + -0xc]
ADD EAX,E... | int8 func0(int param_1,int param_2,int param_3)
{
int8 uVar1;
if (((param_3 < param_2 + param_1) && (param_2 < param_3 + param_1)) &&
(param_1 < param_3 + param_2)) {
uVar1 = 1;
}
else {
uVar1 = 0;
}
return uVar1;
} |
5,229 | func0 |
#include <assert.h>
#include <stdbool.h>
| bool func0(int a, int b, int c) {
if ((a + b <= c) || (a + c <= b) || (b + c <= a)) {
return false;
} else {
return true;
}
}
| int main() {
assert(func0(1, 2, 3) == false);
assert(func0(2, 3, 5) == false);
assert(func0(7, 10, 5) == true);
return 0;
}
| O1 | c | func0:
endbr64
lea (%rdi,%rsi,1),%ecx
mov $0x0,%eax
cmp %edx,%ecx
jle 1147 <func0+0x1e>
lea (%rdi,%rdx,1),%ecx
cmp %esi,%ecx
jle 1147 <func0+0x1e>
add %edx,%esi
cmp %edi,%esi
setg %al
retq
| func0:
endbr64
lea ecx, [rdi+rsi]
mov eax, 0
cmp ecx, edx
jle short locret_1147
lea ecx, [rdi+rdx]
cmp ecx, esi
jle short locret_1147
add esi, edx
cmp esi, edi
setnle al
locret_1147:
retn | bool func0(int a1, int a2, int a3)
{
bool result; // al
result = 0;
if ( a1 + a2 > a3 && a1 + a3 > a2 )
return a3 + a2 > a1;
return result;
} | func0:
ENDBR64
LEA ECX,[RDI + RSI*0x1]
MOV EAX,0x0
CMP ECX,EDX
JLE 0x00101147
LEA ECX,[RDI + RDX*0x1]
CMP ECX,ESI
JLE 0x00101147
ADD ESI,EDX
CMP ESI,EDI
SETG AL
LAB_00101147:
RET | bool func0(int param_1,int param_2,int param_3)
{
bool bVar1;
bVar1 = false;
if ((param_3 < param_1 + param_2) && (param_2 < param_1 + param_3)) {
bVar1 = param_1 < param_2 + param_3;
}
return bVar1;
} |
5,230 | func0 |
#include <assert.h>
#include <stdbool.h>
| bool func0(int a, int b, int c) {
if ((a + b <= c) || (a + c <= b) || (b + c <= a)) {
return false;
} else {
return true;
}
}
| int main() {
assert(func0(1, 2, 3) == false);
assert(func0(2, 3, 5) == false);
assert(func0(7, 10, 5) == true);
return 0;
}
| O2 | c | func0:
endbr64
lea (%rdi,%rsi,1),%ecx
xor %eax,%eax
cmp %edx,%ecx
jle 115b <func0+0x1b>
lea (%rdi,%rdx,1),%ecx
cmp %esi,%ecx
jle 115b <func0+0x1b>
add %edx,%esi
cmp %edi,%esi
setg %al
retq
nopl 0x0(%rax)
| func0:
endbr64
lea ecx, [rdi+rsi]
xor eax, eax
cmp ecx, edx
jle short locret_115B
lea ecx, [rdi+rdx]
cmp ecx, esi
jle short locret_115B
add esi, edx
cmp esi, edi
setnle al
locret_115B:
retn | bool func0(int a1, int a2, int a3)
{
bool result; // al
result = 0;
if ( a1 + a2 > a3 && a1 + a3 > a2 )
return a3 + a2 > a1;
return result;
} | func0:
ENDBR64
LEA ECX,[RDI + RSI*0x1]
XOR EAX,EAX
CMP ECX,EDX
JLE 0x0010115b
LEA ECX,[RDI + RDX*0x1]
CMP ECX,ESI
JLE 0x0010115b
ADD ESI,EDX
CMP ESI,EDI
SETG AL
LAB_0010115b:
RET | bool func0(int param_1,int param_2,int param_3)
{
bool bVar1;
bVar1 = false;
if ((param_3 < param_1 + param_2) && (param_2 < param_1 + param_3)) {
bVar1 = param_1 < param_2 + param_3;
}
return bVar1;
} |
5,231 | func0 |
#include <assert.h>
#include <stdbool.h>
| bool func0(int a, int b, int c) {
if ((a + b <= c) || (a + c <= b) || (b + c <= a)) {
return false;
} else {
return true;
}
}
| int main() {
assert(func0(1, 2, 3) == false);
assert(func0(2, 3, 5) == false);
assert(func0(7, 10, 5) == true);
return 0;
}
| O3 | c | func0:
endbr64
lea (%rdi,%rsi,1),%ecx
xor %eax,%eax
cmp %edx,%ecx
jle 115b <func0+0x1b>
lea (%rdi,%rdx,1),%ecx
cmp %esi,%ecx
jle 115b <func0+0x1b>
add %edx,%esi
cmp %edi,%esi
setg %al
retq
nopl 0x0(%rax)
| func0:
endbr64
lea ecx, [rdi+rsi]
xor eax, eax
cmp ecx, edx
jle short locret_115B
lea ecx, [rdi+rdx]
cmp ecx, esi
jle short locret_115B
add esi, edx
cmp esi, edi
setnle al
locret_115B:
retn | bool func0(int a1, int a2, int a3)
{
bool result; // al
result = 0;
if ( a1 + a2 > a3 && a1 + a3 > a2 )
return a3 + a2 > a1;
return result;
} | func0:
ENDBR64
LEA ECX,[RDI + RSI*0x1]
XOR EAX,EAX
CMP ECX,EDX
JLE 0x0010115b
LEA ECX,[RDI + RDX*0x1]
CMP ECX,ESI
JLE 0x0010115b
ADD ESI,EDX
CMP ESI,EDI
SETG AL
LAB_0010115b:
RET | bool func0(int param_1,int param_2,int param_3)
{
bool bVar1;
bVar1 = false;
if ((param_3 < param_1 + param_2) && (param_2 < param_1 + param_3)) {
bVar1 = param_1 < param_2 + param_3;
}
return bVar1;
} |
5,232 | func0 |
#include <assert.h>
| double func0(int a, int n, int d) {
return (n * (2 * a + (n - 1) * d)) / 2.0;
}
| int main() {
assert(func0(1, 5, 2) == 25);
assert(func0(2, 6, 4) == 72);
assert(func0(1, 4, 5) == 34);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
mov %edi,-0x4(%rbp)
mov %esi,-0x8(%rbp)
mov %edx,-0xc(%rbp)
mov -0x4(%rbp),%eax
lea (%rax,%rax,1),%edx
mov -0x8(%rbp),%eax
sub $0x1,%eax
imul -0xc(%rbp),%eax
add %edx,%eax
imul -0x8(%rbp),%eax
cvtsi2sd %eax,%xmm0
movsd 0xf0c(%rip),%xmm1
divsd %xm... | func0:
endbr64
push rbp
mov rbp, rsp
mov [rbp+var_4], edi
mov [rbp+var_8], esi
mov [rbp+var_C], edx
mov eax, [rbp+var_4]
lea edx, [rax+rax]
mov eax, [rbp+var_8]
sub eax, 1
imul eax, [rbp+var_C]
add eax, edx
imul eax, [rbp+var_8]
pxor xmm0, xmm0
cvtsi2sd xmm0, eax
movsd ... | double func0(int a1, int a2, int a3)
{
return (double)(a2 * (2 * a1 + a3 * (a2 - 1))) / 2.0;
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
MOV dword ptr [RBP + -0x4],EDI
MOV dword ptr [RBP + -0x8],ESI
MOV dword ptr [RBP + -0xc],EDX
MOV EAX,dword ptr [RBP + -0x4]
LEA EDX,[RAX + RAX*0x1]
MOV EAX,dword ptr [RBP + -0x8]
SUB EAX,0x1
IMUL EAX,dword ptr [RBP + -0xc]
ADD EAX,EDX
IMUL EAX,dword ptr [RBP + -0x8]
PXOR XMM0,XMM0
CV... | double func0(int param_1,int param_2,int param_3)
{
return (double)(((param_2 + -1) * param_3 + param_1 * 2) * param_2) / DAT_00102070;
} |
5,233 | func0 |
#include <assert.h>
| double func0(int a, int n, int d) {
return (n * (2 * a + (n - 1) * d)) / 2.0;
}
| int main() {
assert(func0(1, 5, 2) == 25);
assert(func0(2, 6, 4) == 72);
assert(func0(1, 4, 5) == 34);
return 0;
}
| O1 | c | func0:
endbr64
mov %esi,%eax
mov %edx,%ecx
lea -0x1(%rsi),%edx
imul %ecx,%edx
lea (%rdx,%rdi,2),%esi
imul %eax,%esi
pxor %xmm0,%xmm0
cvtsi2sd %esi,%xmm0
mulsd 0xebb(%rip),%xmm0
retq
| func0:
endbr64
lea eax, [rsi-1]
imul eax, edx
lea eax, [rax+rdi*2]
imul eax, esi
pxor xmm0, xmm0
cvtsi2sd xmm0, eax
mulsd xmm0, cs:qword_2008
retn | double func0(int a1, int a2, int a3)
{
return (double)(a2 * (a3 * (a2 - 1) + 2 * a1)) * 0.5;
} | func0:
ENDBR64
LEA EAX,[RSI + -0x1]
IMUL EAX,EDX
LEA EAX,[RAX + RDI*0x2]
IMUL EAX,ESI
PXOR XMM0,XMM0
CVTSI2SD XMM0,EAX
MULSD XMM0,qword ptr [0x00102008]
RET | /* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
double func0(int param_1,int param_2,int param_3)
{
return (double)(((param_2 + -1) * param_3 + param_1 * 2) * param_2) * _DAT_00102008;
} |
5,234 | func0 |
#include <assert.h>
| double func0(int a, int n, int d) {
return (n * (2 * a + (n - 1) * d)) / 2.0;
}
| int main() {
assert(func0(1, 5, 2) == 25);
assert(func0(2, 6, 4) == 72);
assert(func0(1, 4, 5) == 34);
return 0;
}
| O2 | c | func0:
endbr64
mov %edx,%r8d
lea -0x1(%rsi),%edx
pxor %xmm0,%xmm0
mov %esi,%eax
imul %r8d,%edx
lea (%rdx,%rdi,2),%esi
imul %eax,%esi
cvtsi2sd %esi,%xmm0
mulsd 0xea2(%rip),%xmm0
retq
nopw 0x0(%rax,%rax,1)
| func0:
endbr64
lea eax, [rsi-1]
pxor xmm0, xmm0
imul eax, edx
lea eax, [rax+rdi*2]
imul eax, esi
cvtsi2sd xmm0, eax
mulsd xmm0, cs:qword_2008
retn | double func0(int a1, int a2, int a3)
{
return (double)(a2 * (a3 * (a2 - 1) + 2 * a1)) * 0.5;
} | func0:
ENDBR64
LEA EAX,[RSI + -0x1]
PXOR XMM0,XMM0
IMUL EAX,EDX
LEA EAX,[RAX + RDI*0x2]
IMUL EAX,ESI
CVTSI2SD XMM0,EAX
MULSD XMM0,qword ptr [0x00102008]
RET | /* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
double func0(int param_1,int param_2,int param_3)
{
return (double)(((param_2 + -1) * param_3 + param_1 * 2) * param_2) * _DAT_00102008;
} |
5,235 | func0 |
#include <assert.h>
| double func0(int a, int n, int d) {
return (n * (2 * a + (n - 1) * d)) / 2.0;
}
| int main() {
assert(func0(1, 5, 2) == 25);
assert(func0(2, 6, 4) == 72);
assert(func0(1, 4, 5) == 34);
return 0;
}
| O3 | c | func0:
endbr64
mov %edx,%r8d
lea -0x1(%rsi),%edx
pxor %xmm0,%xmm0
mov %esi,%eax
imul %r8d,%edx
lea (%rdx,%rdi,2),%esi
imul %eax,%esi
cvtsi2sd %esi,%xmm0
mulsd 0xea2(%rip),%xmm0
retq
nopw 0x0(%rax,%rax,1)
| func0:
endbr64
lea eax, [rsi-1]
pxor xmm0, xmm0
imul eax, edx
lea eax, [rax+rdi*2]
imul eax, esi
cvtsi2sd xmm0, eax
mulsd xmm0, cs:qword_2008
retn | double func0(int a1, int a2, int a3)
{
return (double)(a2 * (a3 * (a2 - 1) + 2 * a1)) * 0.5;
} | func0:
ENDBR64
LEA EAX,[RSI + -0x1]
PXOR XMM0,XMM0
IMUL EAX,EDX
LEA EAX,[RAX + RDI*0x2]
IMUL EAX,ESI
CVTSI2SD XMM0,EAX
MULSD XMM0,qword ptr [0x00102008]
RET | /* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
double func0(int param_1,int param_2,int param_3)
{
return (double)(((param_2 + -1) * param_3 + param_1 * 2) * param_2) * _DAT_00102008;
} |
5,236 | func0 | #include <assert.h>
#include <stdbool.h>
| bool func0(char *monthname1) {
if (monthname1[0] == 'F' && monthname1[1] == 'e' && monthname1[2] == 'b' && monthname1[3] == 'r' && monthname1[4] == 'u' && monthname1[5] == 'a' && monthname1[6] == 'r' && monthname1[7] == 'y' && monthname1[8] == '\0') {
return true;
} else {
return false;
... | int main() {
assert(func0("February") == true);
assert(func0("January") == false);
assert(func0("March") == false);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
mov %rdi,-0x8(%rbp)
mov -0x8(%rbp),%rax
movzbl (%rax),%eax
cmp $0x46,%al
jne 11df <func0+0x96>
mov -0x8(%rbp),%rax
add $0x1,%rax
movzbl (%rax),%eax
cmp $0x65,%al
jne 11df <func0+0x96>
mov -0x8(%rbp),%rax
add $0x2,%rax
movzbl (%rax),%eax
cmp $0... | func0:
endbr64
push rbp
mov rbp, rsp
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
movzx eax, byte ptr [rax]
cmp al, 46h ; 'F'
jnz short loc_11DF
mov rax, [rbp+var_8]
add rax, 1
movzx eax, byte ptr [rax]
cmp al, 65h ; 'e'
jnz short loc_11DF
mov rax, [rbp+var_8]
add rax, 2
... | _BOOL8 func0(_BYTE *a1)
{
return *a1 == 70
&& a1[1] == 101
&& a1[2] == 98
&& a1[3] == 114
&& a1[4] == 117
&& a1[5] == 97
&& a1[6] == 114
&& a1[7] == 121
&& !a1[8];
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
MOVZX EAX,byte ptr [RAX]
CMP AL,0x46
JNZ 0x001011df
MOV RAX,qword ptr [RBP + -0x8]
ADD RAX,0x1
MOVZX EAX,byte ptr [RAX]
CMP AL,0x65
JNZ 0x001011df
MOV RAX,qword ptr [RBP + -0x8]
ADD RAX,0x2
MOVZX EAX,byte ptr [RAX]
CMP AL,... | int8 func0(char *param_1)
{
int8 uVar1;
if ((((((*param_1 == 'F') && (param_1[1] == 'e')) && (param_1[2] == 'b')) &&
((param_1[3] == 'r' && (param_1[4] == 'u')))) &&
((param_1[5] == 'a' && ((param_1[6] == 'r' && (param_1[7] == 'y')))))) && (param_1[8] == '\0')
) {
uVar1 = 1;
}
else {
... |
5,237 | func0 | #include <assert.h>
#include <stdbool.h>
| bool func0(char *monthname1) {
if (monthname1[0] == 'F' && monthname1[1] == 'e' && monthname1[2] == 'b' && monthname1[3] == 'r' && monthname1[4] == 'u' && monthname1[5] == 'a' && monthname1[6] == 'r' && monthname1[7] == 'y' && monthname1[8] == '\0') {
return true;
} else {
return false;
... | int main() {
assert(func0("February") == true);
assert(func0("January") == false);
assert(func0("March") == false);
return 0;
}
| O1 | c | func0:
endbr64
mov $0x0,%eax
cmpb $0x46,(%rdi)
jne 1188 <func0+0x3f>
cmpb $0x65,0x1(%rdi)
jne 1188 <func0+0x3f>
cmpb $0x62,0x2(%rdi)
jne 1188 <func0+0x3f>
cmpb $0x72,0x3(%rdi)
jne 1188 <func0+0x3f>
cmpb $0x75,0x4(%rdi)
jne 1188 <func0+0x3f>
cmpb $0x61,0x5(%rdi)
jne 1188 <func0+0x3f>
cmp... | func0:
endbr64
mov eax, 0
cmp byte ptr [rdi], 46h ; 'F'
jnz short locret_1188
cmp byte ptr [rdi+1], 65h ; 'e'
jnz short locret_1188
cmp byte ptr [rdi+2], 62h ; 'b'
jnz short locret_1188
cmp byte ptr [rdi+3], 72h ; 'r'
jnz short locret_1188
cmp byte ptr [rdi+4], 75h ; 'u'
jnz ... | bool func0(_BYTE *a1)
{
bool result; // al
result = 0;
if ( *a1 == 70
&& a1[1] == 101
&& a1[2] == 98
&& a1[3] == 114
&& a1[4] == 117
&& a1[5] == 97
&& a1[6] == 114
&& a1[7] == 121 )
{
return a1[8] == 0;
}
return result;
} | func0:
ENDBR64
MOV EAX,0x0
CMP byte ptr [RDI],0x46
JNZ 0x00101188
CMP byte ptr [RDI + 0x1],0x65
JNZ 0x00101188
CMP byte ptr [RDI + 0x2],0x62
JNZ 0x00101188
CMP byte ptr [RDI + 0x3],0x72
JNZ 0x00101188
CMP byte ptr [RDI + 0x4],0x75
JNZ 0x00101188
CMP byte ptr [RDI + 0x5],0x61
JNZ 0x00101188
CMP byte ptr [RDI + 0x6],0x72... | bool func0(char *param_1)
{
bool bVar1;
bVar1 = false;
if (((((*param_1 == 'F') && (param_1[1] == 'e')) && (param_1[2] == 'b')) &&
((param_1[3] == 'r' && (param_1[4] == 'u')))) &&
((param_1[5] == 'a' && ((param_1[6] == 'r' && (param_1[7] == 'y')))))) {
bVar1 = param_1[8] == '\0';
}
return b... |
5,238 | func0 | #include <assert.h>
#include <stdbool.h>
| bool func0(char *monthname1) {
if (monthname1[0] == 'F' && monthname1[1] == 'e' && monthname1[2] == 'b' && monthname1[3] == 'r' && monthname1[4] == 'u' && monthname1[5] == 'a' && monthname1[6] == 'r' && monthname1[7] == 'y' && monthname1[8] == '\0') {
return true;
} else {
return false;
... | int main() {
assert(func0("February") == true);
assert(func0("January") == false);
assert(func0("March") == false);
return 0;
}
| O2 | c | func0:
endbr64
xor %eax,%eax
cmpb $0x46,(%rdi)
jne 122c <func0+0x3c>
cmpb $0x65,0x1(%rdi)
jne 122c <func0+0x3c>
cmpb $0x62,0x2(%rdi)
jne 122c <func0+0x3c>
cmpb $0x72,0x3(%rdi)
jne 122c <func0+0x3c>
cmpb $0x75,0x4(%rdi)
jne 122c <func0+0x3c>
cmpb $0x61,0x5(%rdi)
jne 122c <func0+0x3c>
cmp... | func0:
endbr64
xor eax, eax
cmp byte ptr [rdi], 46h ; 'F'
jnz short locret_122C
cmp byte ptr [rdi+1], 65h ; 'e'
jnz short locret_122C
cmp byte ptr [rdi+2], 62h ; 'b'
jnz short locret_122C
cmp byte ptr [rdi+3], 72h ; 'r'
jnz short locret_122C
cmp byte ptr [rdi+4], 75h ; 'u'
jnz ... | bool func0(_BYTE *a1)
{
bool result; // al
result = 0;
if ( *a1 == 70
&& a1[1] == 101
&& a1[2] == 98
&& a1[3] == 114
&& a1[4] == 117
&& a1[5] == 97
&& a1[6] == 114
&& a1[7] == 121 )
{
return a1[8] == 0;
}
return result;
} | func0:
ENDBR64
XOR EAX,EAX
CMP byte ptr [RDI],0x46
JNZ 0x0010122c
CMP byte ptr [RDI + 0x1],0x65
JNZ 0x0010122c
CMP byte ptr [RDI + 0x2],0x62
JNZ 0x0010122c
CMP byte ptr [RDI + 0x3],0x72
JNZ 0x0010122c
CMP byte ptr [RDI + 0x4],0x75
JNZ 0x0010122c
CMP byte ptr [RDI + 0x5],0x61
JNZ 0x0010122c
CMP byte ptr [RDI + 0x6],0x72... | bool func0(char *param_1)
{
bool bVar1;
bool bVar2;
bVar2 = false;
bVar1 = false;
if (((((*param_1 == 'F') && (param_1[1] == 'e')) && (param_1[2] == 'b')) &&
((bVar2 = bVar1, param_1[3] == 'r' && (param_1[4] == 'u')))) &&
((param_1[5] == 'a' && ((param_1[6] == 'r' && (param_1[7] == 'y')))))) {
... |
5,239 | func0 | #include <assert.h>
#include <stdbool.h>
| bool func0(char *monthname1) {
if (monthname1[0] == 'F' && monthname1[1] == 'e' && monthname1[2] == 'b' && monthname1[3] == 'r' && monthname1[4] == 'u' && monthname1[5] == 'a' && monthname1[6] == 'r' && monthname1[7] == 'y' && monthname1[8] == '\0') {
return true;
} else {
return false;
... | int main() {
assert(func0("February") == true);
assert(func0("January") == false);
assert(func0("March") == false);
return 0;
}
| O3 | c | func0:
endbr64
xor %eax,%eax
cmpb $0x46,(%rdi)
jne 122c <func0+0x3c>
cmpb $0x65,0x1(%rdi)
jne 122c <func0+0x3c>
cmpb $0x62,0x2(%rdi)
jne 122c <func0+0x3c>
cmpb $0x72,0x3(%rdi)
jne 122c <func0+0x3c>
cmpb $0x75,0x4(%rdi)
jne 122c <func0+0x3c>
cmpb $0x61,0x5(%rdi)
jne 122c <func0+0x3c>
cmp... | func0:
endbr64
xor eax, eax
cmp byte ptr [rdi], 46h ; 'F'
jnz short locret_122C
cmp byte ptr [rdi+1], 65h ; 'e'
jnz short locret_122C
cmp byte ptr [rdi+2], 62h ; 'b'
jnz short locret_122C
cmp byte ptr [rdi+3], 72h ; 'r'
jnz short locret_122C
cmp byte ptr [rdi+4], 75h ; 'u'
jnz ... | bool func0(_BYTE *a1)
{
bool result; // al
result = 0;
if ( *a1 == 70
&& a1[1] == 101
&& a1[2] == 98
&& a1[3] == 114
&& a1[4] == 117
&& a1[5] == 97
&& a1[6] == 114
&& a1[7] == 121 )
{
return a1[8] == 0;
}
return result;
} | func0:
ENDBR64
XOR EAX,EAX
CMP byte ptr [RDI],0x46
JNZ 0x0010122c
CMP byte ptr [RDI + 0x1],0x65
JNZ 0x0010122c
CMP byte ptr [RDI + 0x2],0x62
JNZ 0x0010122c
CMP byte ptr [RDI + 0x3],0x72
JNZ 0x0010122c
CMP byte ptr [RDI + 0x4],0x75
JNZ 0x0010122c
CMP byte ptr [RDI + 0x5],0x61
JNZ 0x0010122c
CMP byte ptr [RDI + 0x6],0x72... | bool func0(char *param_1)
{
bool bVar1;
bool bVar2;
bVar2 = false;
bVar1 = false;
if (((((*param_1 == 'F') && (param_1[1] == 'e')) && (param_1[2] == 'b')) &&
((bVar2 = bVar1, param_1[3] == 'r' && (param_1[4] == 'u')))) &&
((param_1[5] == 'a' && ((param_1[6] == 'r' && (param_1[7] == 'y')))))) {
... |
5,240 | func0 | #include <stdio.h>
#include <assert.h>
#include <string.h>
#include <regex.h>
| char* func0(const char* text) {
regex_t regex;
char *patterns = "\\w+\\S*$";
if (regcomp(®ex, patterns, REG_EXTENDED) == 0) {
regmatch_t matches[1];
if (regexec(®ex, text, 1, matches, 0) == 0) {
regfree(®ex);
return "Found a match!";
} else {
... | int main() {
assert(strcmp(func0("python."), "Found a match!") == 0);
assert(strcmp(func0("python."), "Found a match!") == 0);
assert(strcmp(func0(" lang ."), "Not matched!") == 0);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
sub $0x70,%rsp
mov %rdi,-0x68(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x8(%rbp)
xor %eax,%eax
lea 0xdf9(%rip),%rax
mov %rax,-0x58(%rbp)
mov -0x58(%rbp),%rcx
lea -0x50(%rbp),%rax
mov $0x1,%edx
mov %rcx,%rsi
mov %rax,%rdi
callq 10d0 <regcomp@plt>
... | func0:
endbr64
push rbp
mov rbp, rsp
sub rsp, 70h
mov [rbp+string], rdi
mov rax, fs:28h
mov [rbp+var_8], rax
xor eax, eax
lea rax, aWS; "\\w+\\S*$"
mov [rbp+pattern], rax
mov rcx, [rbp+pattern]
lea rax, [rbp+preg]
mov edx, 1; cflags
mov rsi, rcx; pattern
mov rdi, r... | const char * func0(const char *a1)
{
regex_t preg; // [rsp+20h] [rbp-50h] BYREF
regmatch_t pmatch; // [rsp+60h] [rbp-10h] BYREF
unsigned long long v4; // [rsp+68h] [rbp-8h]
v4 = __readfsqword(0x28u);
if ( regcomp(&preg, "\\w+\\S*$", 1) )
return "Regex compilation failed";
if ( regexec(&preg, a1, 1uLL, ... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x70
MOV qword ptr [RBP + -0x68],RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
XOR EAX,EAX
LEA RAX,[0x102008]
MOV qword ptr [RBP + -0x58],RAX
MOV RCX,qword ptr [RBP + -0x58]
LEA RAX,[RBP + -0x50]
MOV EDX,0x1
MOV RSI,RCX
MOV RDI,RAX
CALL 0x001010d0
TEST EAX,EA... | char * func0(char *param_1)
{
int iVar1;
char *pcVar2;
long in_FS_OFFSET;
regex_t local_58;
regmatch_t local_18;
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
iVar1 = regcomp(&local_58,"\\w+\\S*$",1);
if (iVar1 == 0) {
iVar1 = regexec(&local_58,param_1,1,&local_18,0);
if (iVar1... |
5,241 | func0 | #include <stdio.h>
#include <assert.h>
#include <string.h>
#include <regex.h>
| char* func0(const char* text) {
regex_t regex;
char *patterns = "\\w+\\S*$";
if (regcomp(®ex, patterns, REG_EXTENDED) == 0) {
regmatch_t matches[1];
if (regexec(®ex, text, 1, matches, 0) == 0) {
regfree(®ex);
return "Found a match!";
} else {
... | int main() {
assert(strcmp(func0("python."), "Found a match!") == 0);
assert(strcmp(func0("python."), "Found a match!") == 0);
assert(strcmp(func0(" lang ."), "Not matched!") == 0);
return 0;
}
| O1 | c | func0:
endbr64
push %rbx
sub $0x50,%rsp
mov %rdi,%rbx
mov %fs:0x28,%rax
mov %rax,0x48(%rsp)
xor %eax,%eax
mov %rsp,%rdi
mov $0x1,%edx
lea 0xe45(%rip),%rsi
callq 10c0 <regcomp@plt>
mov %eax,%edx
lea 0xe1e(%rip),%rax
test %edx,%edx
je 121c <func0+0x53>
mov 0x48(%rsp),%rcx
xor ... | func0:
endbr64
push rbx
sub rsp, 50h
mov rbx, rdi
mov rax, fs:28h
mov [rsp+58h+var_10], rax
xor eax, eax
mov rdi, rsp
mov edx, 1
lea rsi, aWS; "\\w+\\S*$"
call _regcomp
mov edx, eax
lea rax, aRegexCompilati; "Regex compilation failed"
test edx, edx
jz short loc_123C... | const char * func0(long long a1)
{
int v1; // edx
const char *result; // rax
_BYTE v3[64]; // [rsp+0h] [rbp-58h] BYREF
_BYTE v4[8]; // [rsp+40h] [rbp-18h] BYREF
unsigned long long v5; // [rsp+48h] [rbp-10h]
v5 = __readfsqword(0x28u);
v1 = regcomp(v3, "\\w+\\S*$", 1LL);
result = "Regex compilation faile... | func0:
ENDBR64
PUSH RBX
SUB RSP,0x50
MOV RBX,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x48],RAX
XOR EAX,EAX
MOV RDI,RSP
MOV EDX,0x1
LEA RSI,[0x102039]
CALL 0x001010d0
MOV EDX,EAX
LEA RAX,[0x102020]
TEST EDX,EDX
JZ 0x0010123c
LAB_00101226:
MOV RDX,qword ptr [RSP + 0x48]
SUB RDX,qword ptr FS:[0x28]
JNZ 0x0010... | char * func0(char *param_1)
{
int iVar1;
char *pcVar2;
long in_FS_OFFSET;
regex_t rStack_58;
regmatch_t local_18;
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
iVar1 = regcomp(&rStack_58,"\\w+\\S*$",1);
pcVar2 = "Regex compilation failed";
if (iVar1 == 0) {
iVar1 = regexec(&rStac... |
5,242 | func0 | #include <stdio.h>
#include <assert.h>
#include <string.h>
#include <regex.h>
| char* func0(const char* text) {
regex_t regex;
char *patterns = "\\w+\\S*$";
if (regcomp(®ex, patterns, REG_EXTENDED) == 0) {
regmatch_t matches[1];
if (regexec(®ex, text, 1, matches, 0) == 0) {
regfree(®ex);
return "Found a match!";
} else {
... | int main() {
assert(strcmp(func0("python."), "Found a match!") == 0);
assert(strcmp(func0("python."), "Found a match!") == 0);
assert(strcmp(func0(" lang ."), "Not matched!") == 0);
return 0;
}
| O2 | c | func0:
endbr64
push %r12
mov $0x1,%edx
lea 0xd77(%rip),%rsi
push %rbp
mov %rdi,%rbp
sub $0x58,%rsp
mov %fs:0x28,%rax
mov %rax,0x48(%rsp)
xor %eax,%eax
mov %rsp,%r12
mov %r12,%rdi
callq 10c0 <regcomp@plt>
mov %eax,%r8d
lea 0xd31(%rip),%rax
test %r8d,%r8d
je 1310 <func0+0x60>
m... | func0:
endbr64
push r12
mov edx, 1
mov r12, rdi
lea rsi, aWS; "\\w+\\S*$"
push rbp
sub rsp, 58h
mov rax, fs:28h
mov [rsp+var_s48], rax
xor eax, eax
mov rbp, rsp
mov rdi, rbp
call _regcomp
mov r8d, eax
lea rax, aRegexCompilati; "Regex compilation failed"
test r8d, ... | const char * func0(long long a1)
{
int v1; // r8d
const char *result; // rax
_BYTE _0[64]; // [rsp+0h] [rbp+0h] BYREF
char vars40; // [rsp+40h] [rbp+40h] BYREF
unsigned long long vars48; // [rsp+48h] [rbp+48h]
vars48 = __readfsqword(0x28u);
v1 = regcomp(_0, "\\w+\\S*$", 1LL);
result = "Regex compilatio... | func0:
ENDBR64
PUSH R12
MOV EDX,0x1
MOV R12,RDI
LEA RSI,[0x102039]
PUSH RBP
SUB RSP,0x58
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x48],RAX
XOR EAX,EAX
MOV RBP,RSP
MOV RDI,RBP
CALL 0x001010d0
MOV R8D,EAX
LEA RAX,[0x102020]
TEST R8D,R8D
JZ 0x00101320
LAB_00101304:
MOV RDX,qword ptr [RSP + 0x48]
SUB RDX,qword ptr... | char * func0(char *param_1)
{
int iVar1;
char *pcVar2;
long in_FS_OFFSET;
regex_t rStack_68;
regmatch_t local_28;
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
iVar1 = regcomp(&rStack_68,"\\w+\\S*$",1);
pcVar2 = "Regex compilation failed";
if (iVar1 == 0) {
iVar1 = regexec(&rStac... |
5,243 | func0 | #include <stdio.h>
#include <assert.h>
#include <string.h>
#include <regex.h>
| char* func0(const char* text) {
regex_t regex;
char *patterns = "\\w+\\S*$";
if (regcomp(®ex, patterns, REG_EXTENDED) == 0) {
regmatch_t matches[1];
if (regexec(®ex, text, 1, matches, 0) == 0) {
regfree(®ex);
return "Found a match!";
} else {
... | int main() {
assert(strcmp(func0("python."), "Found a match!") == 0);
assert(strcmp(func0("python."), "Found a match!") == 0);
assert(strcmp(func0(" lang ."), "Not matched!") == 0);
return 0;
}
| O3 | c | func0:
endbr64
push %r12
mov $0x1,%edx
lea 0xd77(%rip),%rsi
push %rbp
mov %rdi,%rbp
sub $0x58,%rsp
mov %fs:0x28,%rax
mov %rax,0x48(%rsp)
xor %eax,%eax
mov %rsp,%r12
mov %r12,%rdi
callq 10c0 <regcomp@plt>
mov %eax,%r8d
lea 0xd31(%rip),%rax
test %r8d,%r8d
je 1310 <func0+0x60>
m... | func0:
endbr64
push rbp
mov edx, 1; cflags
mov rbp, rdi
lea rsi, pattern; "\\w+\\S*$"
push rbx
sub rsp, 58h
mov rax, fs:28h
mov [rsp+68h+var_20], rax
xor eax, eax
mov rbx, rsp
mov rdi, rbx; preg
call _regcomp
mov edx, eax
lea rax, aRegexCompilati; "Regex compilation ... | const char * func0(char *string)
{
int v1; // edx
const char *result; // rax
regex_t v3; // [rsp+0h] [rbp-68h] BYREF
regmatch_t pmatch; // [rsp+40h] [rbp-28h] BYREF
unsigned long long v5; // [rsp+48h] [rbp-20h]
v5 = __readfsqword(0x28u);
v1 = regcomp(&v3, "\\w+\\S*$", 1);
result = "Regex compilation fa... | func0:
ENDBR64
PUSH RBP
MOV EDX,0x1
MOV RBP,RDI
LEA RSI,[0x102039]
PUSH RBX
SUB RSP,0x58
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x48],RAX
XOR EAX,EAX
MOV RBX,RSP
MOV RDI,RBX
CALL 0x001010d0
MOV EDX,EAX
LEA RAX,[0x102020]
TEST EDX,EDX
JZ 0x00101320
LAB_00101301:
MOV RDX,qword ptr [RSP + 0x48]
SUB RDX,qword ptr... | char * func0(char *param_1)
{
int iVar1;
char *pcVar2;
long in_FS_OFFSET;
regex_t rStack_68;
regmatch_t local_28;
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
iVar1 = regcomp(&rStack_68,"\\w+\\S*$",1);
pcVar2 = "Regex compilation failed";
if (iVar1 == 0) {
iVar1 = regexec(&rStac... |
5,244 | func0 |
#include <stdio.h>
#include <assert.h>
#include <string.h>
int check_Equality(char* s, int start, int end) {
return (s[start] == s[end]);
}
| int func0(char* s) {
int result = 0;
int n = strlen(s);
for (int i = 0; i < n; i++) {
for (int j = 1; j <= n - i; j++) {
if (check_Equality(s, i, i + j - 1)) {
result++;
}
}
}
return result;
}
| int main() {
assert(func0("aba") == 4);
assert(func0("abcab") == 7);
assert(func0("abc") == 3);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
sub $0x20,%rsp
mov %rdi,-0x18(%rbp)
movl $0x0,-0x10(%rbp)
mov -0x18(%rbp),%rax
mov %rax,%rdi
callq 1060 <strlen@plt>
mov %eax,-0x4(%rbp)
movl $0x0,-0xc(%rbp)
jmp 1214 <func0+0x6f>
movl $0x1,-0x8(%rbp)
jmp 1205 <func0+0x60>
mov -0xc(%rbp),%edx
mo... | func0:
endbr64
push rbp
mov rbp, rsp
sub rsp, 20h
mov [rbp+s], rdi
mov [rbp+var_10], 0
mov rax, [rbp+s]
mov rdi, rax; s
call _strlen
mov [rbp+var_4], eax
mov [rbp+var_C], 0
jmp short loc_1214
loc_11D4:
mov [rbp+var_8], 1
jmp short loc_1205
loc_11DD:
mov edx, [rbp+va... | long long func0(const char *a1)
{
unsigned int v2; // [rsp+10h] [rbp-10h]
unsigned int i; // [rsp+14h] [rbp-Ch]
int j; // [rsp+18h] [rbp-8h]
int v5; // [rsp+1Ch] [rbp-4h]
v2 = 0;
v5 = strlen(a1);
for ( i = 0; (int)i < v5; ++i )
{
for ( j = 1; j <= (int)(v5 - i); ++j )
{
if ( (unsigned in... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x20
MOV qword ptr [RBP + -0x18],RDI
MOV dword ptr [RBP + -0x10],0x0
MOV RAX,qword ptr [RBP + -0x18]
MOV RDI,RAX
CALL 0x00101060
MOV dword ptr [RBP + -0x4],EAX
MOV dword ptr [RBP + -0xc],0x0
JMP 0x00101214
LAB_001011d4:
MOV dword ptr [RBP + -0x8],0x1
JMP 0x00101205
LAB_001011... | int func0(char *param_1)
{
int iVar1;
size_t sVar2;
int4 local_18;
int4 local_14;
int4 local_10;
local_18 = 0;
sVar2 = strlen(param_1);
for (local_14 = 0; local_14 < (int)sVar2; local_14 = local_14 + 1) {
for (local_10 = 1; local_10 <= (int)sVar2 - local_14; local_10 = local_10 + 1) {
iVar... |
5,245 | func0 |
#include <stdio.h>
#include <assert.h>
#include <string.h>
int check_Equality(char* s, int start, int end) {
return (s[start] == s[end]);
}
| int func0(char* s) {
int result = 0;
int n = strlen(s);
for (int i = 0; i < n; i++) {
for (int j = 1; j <= n - i; j++) {
if (check_Equality(s, i, i + j - 1)) {
result++;
}
}
}
return result;
}
| int main() {
assert(func0("aba") == 4);
assert(func0("abcab") == 7);
assert(func0("abc") == 3);
return 0;
}
| O1 | c | func0:
endbr64
mov %rdi,%rdx
mov $0xffffffffffffffff,%rcx
mov $0x0,%eax
repnz scas %es:(%rdi),%al
mov %rcx,%rax
not %rax
lea -0x1(%rax),%r10
test %r10d,%r10d
jle 11db <func0+0x7a>
push %rbx
mov %r10d,%r11d
mov %rdx,%rdi
mov $0x0,%r9d
mov $0x0,%edx
lea -0x1(%r10),%ebx
jmp 11cf ... | func0:
endbr64
push rbx
mov rbx, rdi
call _strlen
test eax, eax
jle short loc_11EA
mov r10, rax
mov r11d, eax
mov rdi, rbx
mov r9d, 0
mov eax, 0
lea ebx, [r10-1]
jmp short loc_11DE
loc_11AC:
movzx r8d, byte ptr [rdi]
mov edx, ebx
sub edx, r9d
lea rsi, [rdi+rdx+... | long long func0(_BYTE *a1)
{
int v1; // eax
int v2; // r10d
int v3; // r11d
int v4; // r9d
long long result; // rax
_BYTE *v6; // rdx
v1 = strlen();
if ( v1 <= 0 )
return 0LL;
v2 = v1;
v3 = v1;
v4 = 0;
result = 0LL;
do
{
if ( v2 - v4 > 0 )
{
v6 = a1;
do
resu... | func0:
ENDBR64
PUSH RBX
MOV RBX,RDI
CALL 0x00101060
TEST EAX,EAX
JLE 0x001011ea
MOV R10,RAX
MOV R11D,EAX
MOV RDI,RBX
MOV R9D,0x0
MOV EAX,0x0
LEA EBX,[R10 + -0x1]
JMP 0x001011de
LAB_001011ac:
MOVZX R8D,byte ptr [RDI]
MOV EDX,EBX
SUB EDX,R9D
LEA RSI,[RDI + RDX*0x1 + 0x1]
MOV RDX,RDI
LAB_001011bd:
CMP R8B,byte ptr [RDX]
S... | int func0(char *param_1)
{
int iVar1;
int iVar2;
size_t sVar3;
char *pcVar4;
int iVar5;
sVar3 = strlen(param_1);
iVar1 = (int)sVar3;
if (iVar1 < 1) {
iVar2 = 0;
}
else {
iVar5 = 0;
iVar2 = 0;
do {
if (0 < iVar1 - iVar5) {
pcVar4 = param_1;
do {
iVa... |
5,246 | func0 |
#include <stdio.h>
#include <assert.h>
#include <string.h>
int check_Equality(char* s, int start, int end) {
return (s[start] == s[end]);
}
| int func0(char* s) {
int result = 0;
int n = strlen(s);
for (int i = 0; i < n; i++) {
for (int j = 1; j <= n - i; j++) {
if (check_Equality(s, i, i + j - 1)) {
result++;
}
}
}
return result;
}
| int main() {
assert(func0("aba") == 4);
assert(func0("abcab") == 7);
assert(func0("abc") == 3);
return 0;
}
| O2 | c | func0:
endbr64
push %rbx
mov %rdi,%rbx
callq 1060 <strlen@plt>
test %eax,%eax
jle 1292 <func0+0x62>
mov %eax,%r10d
mov %rbx,%rdi
xor %r9d,%r9d
xor %r8d,%r8d
lea -0x1(%rax),%r11d
nopl 0x0(%rax)
mov %r11d,%ecx
movzbl (%rdi),%esi
mov %rdi,%rax
add $0x1,%rdi
sub %r9d,%ecx
add %rdi... | func0:
endbr64
push rbx
mov rbx, rdi
call _strlen
test eax, eax
jle short loc_1292
mov r10d, eax
mov rdi, rbx
xor r9d, r9d
xor r8d, r8d
lea r11d, [rax-1]
nop dword ptr [rax+00000000h]
loc_1258:
mov ecx, r11d
movzx esi, byte ptr [rdi]
mov rax, rdi
add rdi, 1
sub ... | long long func0(char *a1)
{
int v1; // eax
int v2; // r10d
int v3; // r9d
unsigned int v4; // r8d
int v5; // r11d
char v6; // si
char *v7; // rax
int v8; // edx
v1 = strlen();
if ( v1 <= 0 )
return 0LL;
v2 = v1;
v3 = 0;
v4 = 0;
v5 = v1 - 1;
do
{
v6 = *a1;
v7 = a1++;
do
... | func0:
ENDBR64
PUSH RBX
MOV RBX,RDI
CALL 0x00101060
TEST EAX,EAX
JLE 0x00101292
MOV R10D,EAX
MOV RDI,RBX
XOR R9D,R9D
XOR R8D,R8D
LEA R11D,[RAX + -0x1]
NOP dword ptr [RAX]
LAB_00101258:
MOV ECX,R11D
MOVZX ESI,byte ptr [RDI]
MOV RAX,RDI
ADD RDI,0x1
SUB ECX,R9D
ADD RCX,RDI
NOP dword ptr [RAX + RAX*0x1]
LAB_00101270:
XOR E... | int func0(char *param_1)
{
char cVar1;
char cVar2;
int iVar3;
size_t sVar4;
char *pcVar5;
int iVar6;
int iVar7;
sVar4 = strlen(param_1);
iVar3 = (int)sVar4;
if (0 < iVar3) {
iVar7 = 0;
iVar6 = 0;
do {
cVar2 = *param_1;
pcVar5 = param_1 + 1;
do {
cVar1 = *par... |
5,247 | func0 |
#include <stdio.h>
#include <assert.h>
#include <string.h>
int check_Equality(char* s, int start, int end) {
return (s[start] == s[end]);
}
| int func0(char* s) {
int result = 0;
int n = strlen(s);
for (int i = 0; i < n; i++) {
for (int j = 1; j <= n - i; j++) {
if (check_Equality(s, i, i + j - 1)) {
result++;
}
}
}
return result;
}
| int main() {
assert(func0("aba") == 4);
assert(func0("abcab") == 7);
assert(func0("abc") == 3);
return 0;
}
| O3 | c | func0:
endbr64
push %rbp
push %rbx
mov %rdi,%rbx
sub $0x8,%rsp
callq 1060 <strlen@plt>
test %eax,%eax
jle 152a <func0+0x2fa>
movdqa 0xe4e(%rip),%xmm5
mov %rax,%rdx
mov %eax,%r11d
mov %eax,%ebp
mov %rbx,%rdi
xor %esi,%esi
pxor %xmm4,%xmm4
xor %r8d,%r8d
pxor %xmm3,%xmm3
nopw 0x0(%r... | func0:
endbr64
push r14
push r13
push r12
push rbp
push rbx
mov rbx, rdi
call _strlen
test eax, eax
jle loc_151D
mov rcx, rax
mov r10, rbx
xor r11d, r11d
xor edi, edi
pxor xmm6, xmm6
pxor xmm5, xmm5
pxor xmm4, xmm4
pxor xmm3, xmm3
nop word ptr [rax+rax+000000... | long long func0(const char *a1)
{
int v2; // eax
int v3; // ecx
const __m128i *v4; // r10
long long v5; // r11
unsigned int v6; // edi
unsigned int v7; // edx
__m128i v8; // xmm8
__m128i v9; // xmm1
const __m128i *v10; // rax
__m128i v11; // xmm8
__m128i v12; // xmm8
__m128i v13; // xmm0
__m1... | func0:
ENDBR64
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
MOV RBX,RDI
CALL 0x00101060
TEST EAX,EAX
JLE 0x0010151d
MOV RCX,RAX
MOV R10,RBX
XOR R11D,R11D
XOR EDI,EDI
PXOR XMM6,XMM6
PXOR XMM5,XMM5
PXOR XMM4,XMM4
PXOR XMM3,XMM3
NOP word ptr [RAX + RAX*0x1]
LAB_00101270:
LEA R8D,[RCX + -0x1]
MOVZX EDX,byte ptr [R10]
MOV E... | int func0(char *param_1)
{
char cVar1;
bool bVar2;
bool bVar3;
bool bVar4;
bool bVar5;
bool bVar6;
bool bVar7;
bool bVar8;
bool bVar9;
uint uVar10;
char *pcVar11;
char *pcVar12;
char *pcVar13;
char *pcVar14;
char *pcVar15;
char *pcVar16;
char *pcVar17;
char *pcVar18;
char *pcVar19... |
5,248 | func0 |
#include <assert.h>
| int func0(int x, int y) {
if (x == y) {
return y;
}
return 2;
}
| int main() {
assert(func0(2,2) == 2);
assert(func0(2,5) == 2);
assert(func0(5,10) == 2);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
mov %edi,-0x4(%rbp)
mov %esi,-0x8(%rbp)
mov -0x4(%rbp),%eax
cmp -0x8(%rbp),%eax
jne 1164 <func0+0x1b>
mov -0x8(%rbp),%eax
jmp 1169 <func0+0x20>
mov $0x2,%eax
pop %rbp
retq
| func0:
endbr64
push rbp
mov rbp, rsp
mov [rbp+var_4], edi
mov [rbp+var_8], esi
mov eax, [rbp+var_4]
cmp eax, [rbp+var_8]
jnz short loc_1164
mov eax, [rbp+var_8]
jmp short loc_1169
loc_1164:
mov eax, 2
loc_1169:
pop rbp
retn | long long func0(int a1, unsigned int a2)
{
if ( a1 == a2 )
return a2;
else
return 2LL;
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
MOV dword ptr [RBP + -0x4],EDI
MOV dword ptr [RBP + -0x8],ESI
MOV EAX,dword ptr [RBP + -0x4]
CMP EAX,dword ptr [RBP + -0x8]
JNZ 0x00101164
MOV EAX,dword ptr [RBP + -0x8]
JMP 0x00101169
LAB_00101164:
MOV EAX,0x2
LAB_00101169:
POP RBP
RET | int func0(int param_1,int param_2)
{
if (param_1 != param_2) {
param_2 = 2;
}
return param_2;
} |
5,249 | func0 |
#include <assert.h>
| int func0(int x, int y) {
if (x == y) {
return y;
}
return 2;
}
| int main() {
assert(func0(2,2) == 2);
assert(func0(2,5) == 2);
assert(func0(5,10) == 2);
return 0;
}
| O1 | c | func0:
endbr64
cmp %esi,%edi
mov $0x2,%eax
cmove %esi,%eax
retq
| func0:
endbr64
cmp edi, esi
mov eax, 2
cmovz eax, esi
retn | long long func0(int a1, unsigned int a2)
{
long long result; // rax
result = 2LL;
if ( a1 == a2 )
return a2;
return result;
} | func0:
ENDBR64
CMP EDI,ESI
MOV EAX,0x2
CMOVZ EAX,ESI
RET | int func0(int param_1,int param_2)
{
int iVar1;
iVar1 = 2;
if (param_1 == param_2) {
iVar1 = param_2;
}
return iVar1;
} |
5,250 | func0 |
#include <assert.h>
| int func0(int x, int y) {
if (x == y) {
return y;
}
return 2;
}
| int main() {
assert(func0(2,2) == 2);
assert(func0(2,5) == 2);
assert(func0(5,10) == 2);
return 0;
}
| O2 | c | func0:
endbr64
cmp %esi,%edi
mov $0x2,%eax
cmove %edi,%eax
retq
| func0:
endbr64
cmp edi, esi
mov eax, 2
cmovz eax, edi
retn | long long func0(unsigned int a1, int a2)
{
long long result; // rax
result = 2LL;
if ( a1 == a2 )
return a1;
return result;
} | func0:
ENDBR64
CMP EDI,ESI
MOV EAX,0x2
CMOVZ EAX,EDI
RET | int func0(int param_1,int param_2)
{
int iVar1;
iVar1 = 2;
if (param_1 == param_2) {
iVar1 = param_1;
}
return iVar1;
} |
5,251 | func0 |
#include <assert.h>
| int func0(int x, int y) {
if (x == y) {
return y;
}
return 2;
}
| int main() {
assert(func0(2,2) == 2);
assert(func0(2,5) == 2);
assert(func0(5,10) == 2);
return 0;
}
| O3 | c | func0:
endbr64
cmp %esi,%edi
mov $0x2,%eax
cmove %edi,%eax
retq
| func0:
endbr64
cmp edi, esi
mov eax, 2
cmovz eax, edi
retn | long long func0(unsigned int a1, int a2)
{
long long result; // rax
result = 2LL;
if ( a1 == a2 )
return a1;
return result;
} | func0:
ENDBR64
CMP EDI,ESI
MOV EAX,0x2
CMOVZ EAX,EDI
RET | int func0(int param_1,int param_2)
{
int iVar1;
iVar1 = 2;
if (param_1 == param_2) {
iVar1 = param_1;
}
return iVar1;
} |
5,252 | func0 |
#include <stdio.h>
#include <assert.h>
#include <stdlib.h>
int compare(const void * a, const void * b) {
return (*(int*)a - *(int*)b);
}
| int func0(int lst[], int size) {
int positive_numbers[size];
int count = 0;
for (int i = 0; i < size; i++) {
if (lst[i] > 0) {
positive_numbers[count++] = lst[i];
}
}
qsort(positive_numbers, count, sizeof(int), compare);
int sum = 0;
for (int i = 0; i < ... | int main() {
int arr1[] = {10, 20, 30, 40, 50, 60, 7};
int arr2[] = {1, 2, 3, 4, 5};
int arr3[] = {0, 1, 2, 3, 4, 5};
assert(func0(arr1, 7) == 37);
assert(func0(arr2, 5) == 6);
assert(func0(arr3, 6) == 6);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x48,%rsp
mov %rdi,-0x48(%rbp)
mov %esi,-0x4c(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
mov %rsp,%rax
mov %rax,%rbx
mov -0x4c(%rbp),%eax
movslq %eax,%rdx
sub $0x1,%rdx
mov %rdx,-0x28(%rbp)
movslq %eax,%rdx
mov... | func0:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 48h
mov [rbp+var_48], rdi
mov [rbp+var_4C], esi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
mov rax, rsp
mov rbx, rax
mov eax, [rbp+var_4C]
movsxd rdx, eax
sub rdx, 1
mov [rbp+var_28], rdx
cdqe
lea r... | long long func0(long long a1, int a2)
{
unsigned long long v2; // rax
void *v3; // rsp
int v4; // eax
_BYTE v6[4]; // [rsp+8h] [rbp-50h] BYREF
int v7; // [rsp+Ch] [rbp-4Ch]
long long v8; // [rsp+10h] [rbp-48h]
int v9; // [rsp+20h] [rbp-38h]
int i; // [rsp+24h] [rbp-34h]
unsigned int v11; // [rsp+28h]... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x48
MOV qword ptr [RBP + -0x48],RDI
MOV dword ptr [RBP + -0x4c],ESI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
MOV RAX,RSP
MOV RBX,RAX
MOV EAX,dword ptr [RBP + -0x4c]
MOVSXD RDX,EAX
SUB RDX,0x1
MOV qword ptr [RBP + -0x28],RDX
CDQE
LEA RD... | int func0(long param_1,int param_2)
{
long lVar1;
ulong uVar2;
int *puVar3;
size_t __nmemb;
long in_FS_OFFSET;
int auStack_58 [4];
int local_54;
long local_50;
int local_40;
int local_3c;
int local_38;
int local_34;
long local_30;
int *local_28;
long local_20;
local_50 = param_1;
l... |
5,253 | func0 |
#include <stdio.h>
#include <assert.h>
#include <stdlib.h>
int compare(const void * a, const void * b) {
return (*(int*)a - *(int*)b);
}
| int func0(int lst[], int size) {
int positive_numbers[size];
int count = 0;
for (int i = 0; i < size; i++) {
if (lst[i] > 0) {
positive_numbers[count++] = lst[i];
}
}
qsort(positive_numbers, count, sizeof(int), compare);
int sum = 0;
for (int i = 0; i < ... | int main() {
int arr1[] = {10, 20, 30, 40, 50, 60, 7};
int arr2[] = {1, 2, 3, 4, 5};
int arr3[] = {0, 1, 2, 3, 4, 5};
assert(func0(arr1, 7) == 37);
assert(func0(arr2, 5) == 6);
assert(func0(arr3, 6) == 6);
return 0;
}
| O1 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
push %r12
push %rbx
sub $0x10,%rsp
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
movslq %esi,%rax
lea 0xf(,%rax,4),%rax
mov %rax,%rdx
and $0xfffffffffffffff0,%rdx
and $0xfffffffffffff000,%rax
mov %rsp,%rbx
sub %rax,%rbx
mov %rbx,%ra... | func0:
endbr64
push rbp
mov rbp, rsp
push r12
push rbx
sub rsp, 10h
mov rdx, rdi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
movsxd rax, esi
lea rax, ds:0Fh[rax*4]
mov rdi, rax
and rdi, 0FFFFFFFFFFFFFFF0h
and rax, 0FFFFFFFFFFFFF000h
mov rcx, rsp
sub rcx, ... | long long func0(_DWORD *a1, int a2)
{
signed long long v2; // rax
void *v3; // rsp
_DWORD *v4; // rax
long long v5; // rsi
int v6; // ebx
long long v7; // rax
unsigned int v8; // ecx
int v9; // edx
_DWORD v12[2]; // [rsp+8h] [rbp-20h] BYREF
unsigned long long v13; // [rsp+10h] [rbp-18h]
v13 = __... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH R12
PUSH RBX
SUB RSP,0x10
MOV RDX,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
MOVSXD RAX,ESI
LEA RAX,[0xf + RAX*0x4]
MOV RDI,RAX
AND RDI,-0x10
AND RAX,-0x1000
MOV RCX,RSP
SUB RCX,RAX
LAB_001011d1:
CMP RSP,RCX
JZ 0x001011e8
SUB RSP,0x1000
OR qword ... | int func0(int *param_1,int param_2)
{
int *piVar1;
long lVar2;
ulong uVar3;
long lVar4;
int iVar5;
int iVar6;
int iVar7;
int1 *puVar8;
long in_FS_OFFSET;
int1 auStack_28 [8];
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
uVar3 = (long)param_2 * 4 + 0xf;
for (puVar8 = auStack_... |
5,254 | func0 |
#include <stdio.h>
#include <assert.h>
#include <stdlib.h>
int compare(const void * a, const void * b) {
return (*(int*)a - *(int*)b);
}
| int func0(int lst[], int size) {
int positive_numbers[size];
int count = 0;
for (int i = 0; i < size; i++) {
if (lst[i] > 0) {
positive_numbers[count++] = lst[i];
}
}
qsort(positive_numbers, count, sizeof(int), compare);
int sum = 0;
for (int i = 0; i < ... | int main() {
int arr1[] = {10, 20, 30, 40, 50, 60, 7};
int arr2[] = {1, 2, 3, 4, 5};
int arr3[] = {0, 1, 2, 3, 4, 5};
assert(func0(arr1, 7) == 37);
assert(func0(arr2, 5) == 6);
assert(func0(arr3, 6) == 6);
return 0;
}
| O2 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
push %r12
push %rbx
sub $0x10,%rsp
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
movslq %esi,%rax
mov %rsp,%rcx
lea 0xf(,%rax,4),%rax
mov %rax,%rdx
and $0xfffffffffffff000,%rax
sub %rax,%rcx
and $0xfffffffffffffff0,%rdx
mov %rcx,%ra... | func0:
endbr64
push rbp
mov rbp, rsp
push r12
push rbx
sub rsp, 10h
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
movsxd rax, esi
mov rcx, rsp
lea rax, ds:0Fh[rax*4]
mov rdx, rax
and rax, 0FFFFFFFFFFFFF000h
sub rcx, rax
and rdx, 0FFFFFFFFFFFFFFF0h
cmp rsp, ... | long long func0(_DWORD *a1, int a2)
{
long long v2; // rdx
_DWORD *v3; // rcx
__int16 v4; // dx
signed long long v5; // rdx
void *v6; // rsp
int v7; // ebx
long long v8; // rcx
long long v9; // rdx
long long v10; // rax
unsigned int v11; // r8d
int v12; // edx
_DWORD v15[1022]; // [rsp+8h] [rbp... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH R12
PUSH RBX
SUB RSP,0x10
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
MOVSXD RAX,ESI
MOV RCX,RSP
LEA RAX,[0xf + RAX*0x4]
MOV RDX,RAX
AND RAX,-0x1000
SUB RCX,RAX
AND RDX,-0x10
CMP RSP,RCX
JZ 0x00101346
LAB_00101331:
SUB RSP,0x1000
OR qword ptr [RSP + 0... | int func0(int *param_1,int param_2)
{
int *piVar1;
long lVar2;
int1 *puVar3;
int iVar4;
ulong uVar5;
long lVar6;
int iVar7;
int1 *puVar8;
int iVar10;
long in_FS_OFFSET;
int1 auStack_28 [8];
long local_20;
int1 *puVar9;
puVar8 = auStack_28;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
u... |
5,255 | func0 |
#include <stdio.h>
#include <assert.h>
#include <stdlib.h>
int compare(const void * a, const void * b) {
return (*(int*)a - *(int*)b);
}
| int func0(int lst[], int size) {
int positive_numbers[size];
int count = 0;
for (int i = 0; i < size; i++) {
if (lst[i] > 0) {
positive_numbers[count++] = lst[i];
}
}
qsort(positive_numbers, count, sizeof(int), compare);
int sum = 0;
for (int i = 0; i < ... | int main() {
int arr1[] = {10, 20, 30, 40, 50, 60, 7};
int arr2[] = {1, 2, 3, 4, 5};
int arr3[] = {0, 1, 2, 3, 4, 5};
assert(func0(arr1, 7) == 37);
assert(func0(arr2, 5) == 6);
assert(func0(arr3, 6) == 6);
return 0;
}
| O3 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
push %r12
push %rbx
sub $0x10,%rsp
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
movslq %esi,%rax
mov %rsp,%rcx
lea 0xf(,%rax,4),%rax
mov %rax,%rdx
and $0xfffffffffffff000,%rax
sub %rax,%rcx
and $0xfffffffffffffff0,%rdx
mov %rcx,%ra... | func0:
endbr64
push rbp
movsxd rcx, esi
mov rax, rdi
shl rcx, 2
mov rbp, rsp
push r12
push rbx
sub rsp, 10h
mov rdx, fs:28h
mov [rbp+var_18], rdx
xor edx, edx
lea rdx, [rcx+0Fh]
mov r8, rsp
mov rdi, rdx
and rdx, 0FFFFFFFFFFFFF000h
sub r8, rdx
and rdi, 0FFFFF... | long long func0(_DWORD *a1, int a2)
{
long long v3; // rcx
_DWORD *v4; // r8
signed long long v5; // rdi
void *v6; // rsp
_DWORD *v7; // rcx
int v8; // r12d
long long v9; // rsi
long long result; // rax
_DWORD v12[1022]; // [rsp+8h] [rbp-1020h] BYREF
_QWORD v13[4]; // [rsp+1008h] [rbp-20h] BYREF
... | func0:
ENDBR64
PUSH RBP
MOVSXD RCX,ESI
MOV RAX,RDI
SHL RCX,0x2
MOV RBP,RSP
PUSH R12
PUSH RBX
SUB RSP,0x10
MOV RDX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RDX
XOR EDX,EDX
LEA RDX,[RCX + 0xf]
MOV R8,RSP
MOV RDI,RDX
AND RDX,-0x1000
SUB R8,RDX
AND RDI,-0x10
CMP RSP,R8
JZ 0x0010131a
LAB_00101305:
SUB RSP,0x1000
OR q... | int func0(int *param_1,int param_2)
{
long lVar1;
int *puVar2;
int iVar3;
int *piVar4;
ulong uVar5;
int *puVar6;
long lVar8;
int iVar9;
long in_FS_OFFSET;
int auStack_28 [8];
long local_20;
int *puVar7;
puVar6 = auStack_28;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
uVar5 = (long)param... |
5,256 | func0 | #include <stdio.h>
#include <assert.h>
#include <stdlib.h>
int cmpfunc (const void * a, const void * b) {
return ( *(int*)a - *(int*)b );
}
| void func0(int arr[], int n, int result[]) {
qsort(arr, n, sizeof(int), cmpfunc);
for (int i = 0; i < n; i++) {
result[i] = arr[i];
}
}
| int main() {
int result[5];
int set1[] = {1, 2, 3, 4, 5};
func0(set1, 5, result);
assert(result[0] == 1 && result[1] == 2 && result[2] == 3 && result[3] == 4 && result[4] == 5);
int set2[] = {6, 7, 8, 9, 10, 11};
func0(set2, 6, result);
assert(result[0] == 6 && result[1] == 7 && r... | O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
sub $0x30,%rsp
mov %rdi,-0x18(%rbp)
mov %esi,-0x1c(%rbp)
mov %rdx,-0x28(%rbp)
mov -0x1c(%rbp),%eax
movslq %eax,%rsi
mov -0x18(%rbp),%rax
lea -0x4a(%rip),%rcx
mov $0x4,%edx
mov %rax,%rdi
callq 1070 <qsort@plt>
movl $0x0,-0x4(%rbp)
jmp 121a <fun... | func0:
endbr64
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+base], rdi
mov [rbp+var_1C], esi
mov [rbp+var_28], rdx
mov eax, [rbp+var_1C]
movsxd rsi, eax; nmemb
mov rax, [rbp+base]
lea rdx, cmpfunc
mov rcx, rdx; compar
mov edx, 4; size
mov rdi, rax; base
call _qsort
mov ... | long long func0(void *a1, int a2, long long a3)
{
long long result; // rax
unsigned int i; // [rsp+2Ch] [rbp-4h]
qsort(a1, a2, 4uLL, cmpfunc);
for ( i = 0; ; ++i )
{
result = i;
if ( (int)i >= a2 )
break;
*(_DWORD *)(4LL * (int)i + a3) = *((_DWORD *)a1 + (int)i);
}
return result;
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x18],RDI
MOV dword ptr [RBP + -0x1c],ESI
MOV qword ptr [RBP + -0x28],RDX
MOV EAX,dword ptr [RBP + -0x1c]
MOVSXD RSI,EAX
MOV RAX,qword ptr [RBP + -0x18]
LEA RDX,[0x101189]
MOV RCX,RDX
MOV EDX,0x4
MOV RDI,RAX
CALL 0x00101070
MOV dword ptr [RBP + -0x4... | void func0(void *param_1,int param_2,long param_3)
{
int local_c;
qsort(param_1,(long)param_2,4,cmpfunc);
for (local_c = 0; local_c < param_2; local_c = local_c + 1) {
*(int4 *)(param_3 + (long)local_c * 4) =
*(int4 *)((long)param_1 + (long)local_c * 4);
}
return;
} |
5,257 | func0 | #include <stdio.h>
#include <assert.h>
#include <stdlib.h>
int cmpfunc (const void * a, const void * b) {
return ( *(int*)a - *(int*)b );
}
| void func0(int arr[], int n, int result[]) {
qsort(arr, n, sizeof(int), cmpfunc);
for (int i = 0; i < n; i++) {
result[i] = arr[i];
}
}
| int main() {
int result[5];
int set1[] = {1, 2, 3, 4, 5};
func0(set1, 5, result);
assert(result[0] == 1 && result[1] == 2 && result[2] == 3 && result[3] == 4 && result[4] == 5);
int set2[] = {6, 7, 8, 9, 10, 11};
func0(set2, 6, result);
assert(result[0] == 6 && result[1] == 7 && r... | O1 | c | func0:
endbr64
push %r12
push %rbp
push %rbx
mov %rdi,%rbx
mov %esi,%r12d
mov %rdx,%rbp
movslq %esi,%rsi
lea -0x24(%rip),%rcx
mov $0x4,%edx
callq 1070 <qsort@plt>
test %r12d,%r12d
jle 11d9 <func0+0x47>
lea -0x1(%r12),%ecx
mov $0x0,%eax
mov (%rbx,%rax,4),%edx
mov %edx,0x0(%rbp,%rax... | func0:
endbr64
push r12
push rbp
push rbx
mov rbp, rdi
mov ebx, esi
mov r12, rdx
movsxd rsi, esi
lea rcx, cmpfunc
mov edx, 4
call _qsort
test ebx, ebx
jle short loc_11D2
mov esi, ebx
mov eax, 0
loc_11C1:
mov edx, [rbp+rax*4+0]
mov [r12+rax*4], edx
add rax, 1
c... | long long func0(long long a1, int a2, long long a3)
{
long long result; // rax
result = qsort(a1, a2, 4LL, cmpfunc);
if ( a2 > 0 )
{
for ( result = 0LL; result != a2; ++result )
*(_DWORD *)(a3 + 4 * result) = *(_DWORD *)(a1 + 4 * result);
}
return result;
} | func0:
ENDBR64
PUSH R12
PUSH RBP
PUSH RBX
MOV RBP,RDI
MOV EBX,ESI
MOV R12,RDX
MOVSXD RSI,ESI
LEA RCX,[0x101189]
MOV EDX,0x4
CALL 0x00101070
TEST EBX,EBX
JLE 0x001011d2
MOV ESI,EBX
MOV EAX,0x0
LAB_001011c1:
MOV EDX,dword ptr [RBP + RAX*0x4]
MOV dword ptr [R12 + RAX*0x4],EDX
ADD RAX,0x1
CMP RAX,RSI
JNZ 0x001011c1
LAB_001... | void func0(void *param_1,uint param_2,long param_3)
{
ulong uVar1;
qsort(param_1,(long)(int)param_2,4,cmpfunc);
if (0 < (int)param_2) {
uVar1 = 0;
do {
*(int4 *)(param_3 + uVar1 * 4) = *(int4 *)((long)param_1 + uVar1 * 4);
uVar1 = uVar1 + 1;
} while (uVar1 != param_2);
}
return;
} |
5,258 | func0 | #include <stdio.h>
#include <assert.h>
#include <stdlib.h>
int cmpfunc (const void * a, const void * b) {
return ( *(int*)a - *(int*)b );
}
| void func0(int arr[], int n, int result[]) {
qsort(arr, n, sizeof(int), cmpfunc);
for (int i = 0; i < n; i++) {
result[i] = arr[i];
}
}
| int main() {
int result[5];
int set1[] = {1, 2, 3, 4, 5};
func0(set1, 5, result);
assert(result[0] == 1 && result[1] == 2 && result[2] == 3 && result[3] == 4 && result[4] == 5);
int set2[] = {6, 7, 8, 9, 10, 11};
func0(set2, 6, result);
assert(result[0] == 6 && result[1] == 7 && r... | O2 | c | func0:
endbr64
push %r12
movslq %esi,%rsi
lea -0x20(%rip),%rcx
push %rbp
mov %rsi,%r12
mov %rdx,%rbp
mov $0x4,%edx
push %rbx
mov %rdi,%rbx
callq 1070 <qsort@plt>
test %r12d,%r12d
jle 13cb <func0+0x4b>
lea -0x1(%r12),%ecx
xor %eax,%eax
nopl 0x0(%rax)
mov (%rbx,%rax,4),%edx
mov %e... | func0:
endbr64
push r13
lea rcx, cmpfunc
push r12
movsxd r12, esi
push rbp
mov rsi, r12
mov rbp, rdx
mov edx, 4
push rbx
mov rbx, rdi
sub rsp, 8
call _qsort
test r12d, r12d
jle short loc_13C8
xor eax, eax
nop word ptr [rax+rax+00h]
loc_13B8:
mov edx, [rbx+rax*4... | long long func0(long long a1, int a2, long long a3)
{
long long result; // rax
result = qsort(a1, a2, 4LL, cmpfunc);
if ( a2 > 0 )
{
for ( result = 0LL; result != a2; ++result )
*(_DWORD *)(a3 + 4 * result) = *(_DWORD *)(a1 + 4 * result);
}
return result;
} | func0:
ENDBR64
PUSH R13
LEA RCX,[0x101370]
PUSH R12
MOVSXD R12,ESI
PUSH RBP
MOV RSI,R12
MOV RBP,RDX
MOV EDX,0x4
PUSH RBX
MOV RBX,RDI
SUB RSP,0x8
CALL 0x00101070
TEST R12D,R12D
JLE 0x001013c8
XOR EAX,EAX
NOP word ptr [RAX + RAX*0x1]
LAB_001013b8:
MOV EDX,dword ptr [RBX + RAX*0x4]
MOV dword ptr [RBP + RAX*0x4],EDX
ADD RA... | void func0(void *param_1,int param_2,long param_3)
{
size_t sVar1;
qsort(param_1,(long)param_2,4,cmpfunc);
if (0 < param_2) {
sVar1 = 0;
do {
*(int4 *)(param_3 + sVar1 * 4) = *(int4 *)((long)param_1 + sVar1 * 4);
sVar1 = sVar1 + 1;
} while (sVar1 != (long)param_2);
}
return;
} |
5,259 | func0 | #include <stdio.h>
#include <assert.h>
#include <stdlib.h>
int cmpfunc (const void * a, const void * b) {
return ( *(int*)a - *(int*)b );
}
| void func0(int arr[], int n, int result[]) {
qsort(arr, n, sizeof(int), cmpfunc);
for (int i = 0; i < n; i++) {
result[i] = arr[i];
}
}
| int main() {
int result[5];
int set1[] = {1, 2, 3, 4, 5};
func0(set1, 5, result);
assert(result[0] == 1 && result[1] == 2 && result[2] == 3 && result[3] == 4 && result[4] == 5);
int set2[] = {6, 7, 8, 9, 10, 11};
func0(set2, 6, result);
assert(result[0] == 6 && result[1] == 7 && r... | O3 | c | func0:
endbr64
push %r12
movslq %esi,%rsi
lea -0x20(%rip),%rcx
push %rbp
mov %rsi,%r12
mov %rdx,%rbp
mov $0x4,%edx
push %rbx
mov %rdi,%rbx
callq 1070 <qsort@plt>
test %r12d,%r12d
jle 13db <func0+0x9b>
lea 0xf(%rbx),%rdx
lea -0x1(%r12),%eax
sub %rbp,%rdx
cmp $0x1e,%rdx
jbe 13e0 ... | func0:
endbr64
push r13
movsxd r13, esi
lea rcx, cmpfunc; compar
push r12
mov rsi, r13; nmemb
push rbp
mov rbp, rdx
mov edx, 4; size
push rbx
mov rbx, rdi
sub rsp, 8
call _qsort
test r13d, r13d
jle short loc_13B0
lea eax, [r13-1]
mov r12, r13
cmp eax, 2
jbe ... | void func0(char *a1, int a2, long long a3)
{
long long v4; // rax
long long v5; // rax
unsigned int v6; // eax
long long v7; // rdx
qsort(a1, a2, 4uLL, cmpfunc);
if ( a2 > 0 )
{
if ( (unsigned int)(a2 - 1) > 2 && (unsigned long long)(a3 - (_QWORD)(a1 + 4)) > 8 )
{
v5 = 0LL;
do
... | func0:
ENDBR64
PUSH R13
MOVSXD R13,ESI
LEA RCX,[0x101330]
PUSH R12
MOV RSI,R13
PUSH RBP
MOV RBP,RDX
MOV EDX,0x4
PUSH RBX
MOV RBX,RDI
SUB RSP,0x8
CALL 0x00101070
TEST R13D,R13D
JLE 0x001013b0
LEA EAX,[R13 + -0x1]
MOV R12,R13
CMP EAX,0x2
JBE 0x0010138c
LEA RDX,[RBX + 0x4]
MOV RAX,RBP
SUB RAX,RDX
CMP RAX,0x8
JA 0x001013c0... | void func0(void *param_1,uint param_2,long param_3)
{
int8 uVar1;
uint uVar2;
long lVar3;
ulong uVar4;
size_t __nmemb;
__nmemb = (size_t)(int)param_2;
qsort(param_1,__nmemb,4,cmpfunc);
if (0 < (int)param_2) {
if ((param_2 - 1 < 3) || ((ulong)(param_3 - ((long)param_1 + 4)) < 9)) {
lVar3 = ... |
5,260 | func0 |
#include <stdio.h>
#include <stdlib.h>
#include <limits.h>
#include <assert.h>
typedef struct Node {
int value;
int list_num;
int index;
} Node;
Node* create_node(int value, int list_num, int index) {
Node* node = (Node*)malloc(sizeof(Node));
node->value = value;
node->list_num... | int* func0(int** list, int* list_sizes, int numLists) {
static int range[2];
int high = INT_MIN;
int i, j;
Node** pq = malloc(numLists * sizeof(Node*));
int pq_size = 0;
for (i = 0; i < numLists; i++) {
pq[pq_size++] = create_node(list[i][0], i, 0);
if (list[i][0] > hig... | int main() {
int list1[] = {3, 6, 8, 10, 15};
int list2[] = {1, 5, 12};
int list3[] = {4, 8, 15, 16};
int list4[] = {2, 6};
int* lists[] = {list1, list2, list3, list4};
int sizes[] = {5, 3, 4, 2};
int* result;
result = func0(lists, sizes, 4);
assert(result[0] == 4 && resul... | O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x58,%rsp
mov %rdi,-0x48(%rbp)
mov %rsi,-0x50(%rbp)
mov %edx,-0x54(%rbp)
movl $0x80000000,-0x34(%rbp)
mov -0x54(%rbp),%eax
cltq
shl $0x3,%rax
mov %rax,%rdi
callq 10d0 <malloc@plt>
mov %rax,-0x20(%rbp)
movl $0x0,-0x2c(%rbp)
movl ... | func0:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 58h
mov [rbp+var_48], rdi
mov [rbp+var_50], rsi
mov [rbp+var_54], edx
mov [rbp+var_34], 80000000h
mov eax, [rbp+var_54]
cdqe
shl rax, 3
mov rdi, rax; size
call _malloc
mov [rbp+base], rax
mov [rbp+var_2C], 0
mov ... | int * func0(long long a1, long long a2, int a3)
{
int v3; // eax
signed int v6; // [rsp+2Ch] [rbp-34h]
unsigned int i; // [rsp+30h] [rbp-30h]
int v8; // [rsp+30h] [rbp-30h]
int v9; // [rsp+34h] [rbp-2Ch]
int v10; // [rsp+3Ch] [rbp-24h]
int **base; // [rsp+40h] [rbp-20h]
v6 = 0x80000000;
base = (int *... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x58
MOV qword ptr [RBP + -0x48],RDI
MOV qword ptr [RBP + -0x50],RSI
MOV dword ptr [RBP + -0x54],EDX
MOV dword ptr [RBP + -0x34],0x80000000
MOV EAX,dword ptr [RBP + -0x54]
CDQE
SHL RAX,0x3
MOV RDI,RAX
CALL 0x001010d0
MOV qword ptr [RBP + -0x20],RAX
MOV dword ptr [RBP... | int4 * func0(long param_1,long param_2,int param_3)
{
int iVar1;
int iVar2;
int *piVar3;
int8 *__base;
int8 uVar4;
int local_3c;
int local_38;
int local_34;
local_3c = -0x80000000;
__base = (int8 *)malloc((long)param_3 << 3);
local_34 = 0;
for (local_38 = 0; local_38 < param_3; local_38 = lo... |
5,261 | func0 |
#include <stdio.h>
#include <stdlib.h>
#include <limits.h>
#include <assert.h>
typedef struct Node {
int value;
int list_num;
int index;
} Node;
Node* create_node(int value, int list_num, int index) {
Node* node = (Node*)malloc(sizeof(Node));
node->value = value;
node->list_num... | int* func0(int** list, int* list_sizes, int numLists) {
static int range[2];
int high = INT_MIN;
int i, j;
Node** pq = malloc(numLists * sizeof(Node*));
int pq_size = 0;
for (i = 0; i < numLists; i++) {
pq[pq_size++] = create_node(list[i][0], i, 0);
if (list[i][0] > hig... | int main() {
int list1[] = {3, 6, 8, 10, 15};
int list2[] = {1, 5, 12};
int list3[] = {4, 8, 15, 16};
int list4[] = {2, 6};
int* lists[] = {list1, list2, list3, list4};
int sizes[] = {5, 3, 4, 2};
int* result;
result = func0(lists, sizes, 4);
assert(result[0] == 4 && resul... | O1 | c | func0:
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x18,%rsp
mov %rdi,%r13
mov %rsi,%r15
mov %edx,%ebx
mov %edx,0x8(%rsp)
movslq %edx,%rdi
shl $0x3,%rdi
callq 10d0 <malloc@plt>
mov %rax,%r12
test %ebx,%ebx
jle 12b4 <func0+0xa5>
lea -0x1(%rbx),%r14d
... | func0:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 18h
mov r13, rdi
mov r15, rsi
mov ebx, edx
mov dword ptr [rsp+48h+var_40], edx
movsxd rdi, edx
shl rdi, 3
call _malloc
mov r12, rax
test ebx, ebx
jle short loc_12AE
mov r14d, ebx
mo... | int * func0(long long a1, long long a2, int a3)
{
int **v5; // r12
long long v6; // r14
long long v7; // rbp
signed int v8; // ebx
_QWORD *v9; // r14
long long v10; // rbp
long long v11; // rsi
int v12; // edx
int v14; // [rsp+8h] [rbp-40h]
v14 = a3;
v5 = (int **)malloc(8LL * a3);
if ( a3 <= 0 ... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x18
MOV R13,RDI
MOV R15,RSI
MOV EBX,EDX
MOV dword ptr [RSP + 0x8],EDX
MOVSXD RDI,EDX
SHL RDI,0x3
CALL 0x001010d0
MOV R12,RAX
TEST EBX,EBX
JLE 0x001012ae
MOV R14D,EBX
MOV EBP,0x0
MOV EBX,0x80000000
LAB_0010124b:
MOV RAX,qword ptr [R13 + RBP*0x... | int8 * func0(long param_1,long param_2,uint param_3)
{
long *plVar1;
int iVar2;
int iVar3;
int *piVar4;
int8 *__base;
int8 uVar5;
int iVar6;
ulong uVar7;
__base = (int8 *)malloc((long)(int)param_3 << 3);
if ((int)param_3 < 1) {
param_3 = 0;
iVar6 = -0x80000000;
}
else {
uVar7 = 0... |
5,262 | func0 |
#include <stdio.h>
#include <stdlib.h>
#include <limits.h>
#include <assert.h>
typedef struct Node {
int value;
int list_num;
int index;
} Node;
Node* create_node(int value, int list_num, int index) {
Node* node = (Node*)malloc(sizeof(Node));
node->value = value;
node->list_num... | int* func0(int** list, int* list_sizes, int numLists) {
static int range[2];
int high = INT_MIN;
int i, j;
Node** pq = malloc(numLists * sizeof(Node*));
int pq_size = 0;
for (i = 0; i < numLists; i++) {
pq[pq_size++] = create_node(list[i][0], i, 0);
if (list[i][0] > hig... | int main() {
int list1[] = {3, 6, 8, 10, 15};
int list2[] = {1, 5, 12};
int list3[] = {4, 8, 15, 16};
int list4[] = {2, 6};
int* lists[] = {list1, list2, list3, list4};
int sizes[] = {5, 3, 4, 2};
int* result;
result = func0(lists, sizes, 4);
assert(result[0] == 4 && resul... | O2 | c | func0:
endbr64
push %r15
push %r14
push %r13
movslq %edx,%r13
push %r12
mov %rsi,%r12
push %rbp
mov %rdi,%rbp
lea 0x0(,%r13,8),%rdi
push %rbx
sub $0x28,%rsp
callq 10d0 <malloc@plt>
mov %rax,%r15
test %r13d,%r13d
jle 15f0 <func0+0x190>
lea -0x1(%r13),%eax
xor %r14d,%r14d
mov $0x... | func0:
endbr64
push r15
push r14
mov r14, rsi
push r13
push r12
push rbp
movsxd rbp, edx
push rbx
sub rsp, 18h
mov [rsp+48h+var_48], rdi
lea rdi, ds:0[rbp*8]
call _malloc
mov r12, rax
test ebp, ebp
jle loc_15E0
xor r13d, r13d
mov ebx, 80000000h
nop dword ptr ... | long long * func0(long long a1, long long a2, int a3)
{
long long v4; // rbp
signed int **v5; // r12
long long v6; // r13
signed int v7; // ebx
signed int *v8; // r15
signed int *v9; // rax
int v10; // edi
int v11; // eax
signed int *v12; // r13
signed int *v13; // rax
int v14; // esi
signed int... | func0:
ENDBR64
PUSH R15
PUSH R14
MOV R14,RSI
PUSH R13
PUSH R12
PUSH RBP
MOVSXD RBP,EDX
PUSH RBX
SUB RSP,0x18
MOV qword ptr [RSP],RDI
LEA RDI,[RBP*0x8]
CALL 0x001010d0
MOV R12,RAX
TEST EBP,EBP
JLE 0x001015e0
XOR R13D,R13D
MOV EBX,0x80000000
NOP dword ptr [RAX]
LAB_001014a0:
MOV RAX,qword ptr [RSP]
MOV EDI,0xc
MOV R15,qw... | /* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
int4 * func0(long param_1,long param_2,int param_3)
{
int iVar1;
int iVar2;
int iVar3;
int *piVar4;
int8 *__base;
int *piVar5;
int iVar6;
size_t __nmemb;
size_t sVar7;
__nmemb = (size_t)param_3;
__base = (int... |
5,263 | func0 |
#include <stdio.h>
#include <stdlib.h>
#include <limits.h>
#include <assert.h>
typedef struct Node {
int value;
int list_num;
int index;
} Node;
Node* create_node(int value, int list_num, int index) {
Node* node = (Node*)malloc(sizeof(Node));
node->value = value;
node->list_num... | int* func0(int** list, int* list_sizes, int numLists) {
static int range[2];
int high = INT_MIN;
int i, j;
Node** pq = malloc(numLists * sizeof(Node*));
int pq_size = 0;
for (i = 0; i < numLists; i++) {
pq[pq_size++] = create_node(list[i][0], i, 0);
if (list[i][0] > hig... | int main() {
int list1[] = {3, 6, 8, 10, 15};
int list2[] = {1, 5, 12};
int list3[] = {4, 8, 15, 16};
int list4[] = {2, 6};
int* lists[] = {list1, list2, list3, list4};
int sizes[] = {5, 3, 4, 2};
int* result;
result = func0(lists, sizes, 4);
assert(result[0] == 4 && resul... | O3 | c | func0:
endbr64
push %r15
push %r14
movslq %edx,%r14
push %r13
mov %rsi,%r13
push %r12
push %rbp
mov %rdi,%rbp
lea 0x0(,%r14,8),%rdi
push %rbx
sub $0x28,%rsp
callq 10d0 <malloc@plt>
mov %rax,%r15
test %r14d,%r14d
jle 15d0 <func0+0x1b0>
lea -0x1(%r14),%eax
xor %r12d,%r12d
mov $0x... | func0:
endbr64
push r15
push r14
mov r14, rsi
push r13
movsxd r13, edx
push r12
mov r12d, 80000000h
push rbp
push rbx
xor ebx, ebx
sub rsp, 18h
mov [rsp+48h+var_48], rdi
lea rdi, ds:0[r13*8]; size
call _malloc
mov rbp, rax
test r13d, r13d
jle short loc_14BE
nop ... | long long * func0(long long a1, long long a2, int a3)
{
long long v4; // r13
signed int v5; // r12d
size_t v6; // rbx
unsigned int **v7; // rbp
unsigned int *v8; // r15
unsigned int *v9; // rax
unsigned long long v10; // xmm0_8
int v11; // edi
int v12; // ecx
long long v13; // rcx
unsigned int *v1... | func0:
ENDBR64
PUSH R15
PUSH R14
MOV R14,RSI
PUSH R13
MOVSXD R13,EDX
PUSH R12
MOV R12D,0x80000000
PUSH RBP
PUSH RBX
XOR EBX,EBX
SUB RSP,0x18
MOV qword ptr [RSP],RDI
LEA RDI,[R13*0x8]
CALL 0x001010d0
MOV RBP,RAX
TEST R13D,R13D
JLE 0x001014be
NOP dword ptr [RAX]
LAB_00101470:
MOV RAX,qword ptr [RSP]
MOVD XMM1,EBX
MOV EDI... | int8 * func0(long param_1,long param_2,int param_3)
{
int4 uVar1;
int iVar2;
int iVar3;
int *piVar4;
long lVar5;
int8 *__base;
int8 *puVar6;
int iVar7;
size_t __nmemb;
int iVar8;
int iVar9;
iVar9 = -0x80000000;
__nmemb = 0;
__base = (int8 *)malloc((long)param_3 * 8);
if (0 < param_3) {... |
5,264 | func0 |
#include <ctype.h>
#include <assert.h>
| void func0(const char *s, int *letters, int *digits) {
int l = 0, d = 0;
while (*s) {
if (isdigit((unsigned char)*s))
d++;
else if (isalpha((unsigned char)*s))
l++;
s++;
}
*letters = l;
*digits = d;
}
| int main() {
int letters, digits;
func0("python", &letters, &digits);
assert(letters == 6 && digits == 0);
func0("program", &letters, &digits);
assert(letters == 7 && digits == 0);
func0("python3.0", &letters, &digits);
assert(letters == 6 && digits == 2);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
sub $0x30,%rsp
mov %rdi,-0x18(%rbp)
mov %rsi,-0x20(%rbp)
mov %rdx,-0x28(%rbp)
movl $0x0,-0x8(%rbp)
movl $0x0,-0x4(%rbp)
jmp 120e <func0+0x85>
callq 1090 <__ctype_b_loc@plt>
mov (%rax),%rdx
mov -0x18(%rbp),%rax
movzbl (%rax),%eax
movzbl %al,%eax
add ... | func0:
endbr64
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_18], rdi
mov [rbp+var_20], rsi
mov [rbp+var_28], rdx
mov [rbp+var_8], 0
mov [rbp+var_4], 0
jmp short loc_120E
loc_11B1:
call ___ctype_b_loc
mov rdx, [rax]
mov rax, [rbp+var_18]
movzx eax, byte ptr [rax]
movzx ... | _DWORD * func0(_BYTE *a1, _DWORD *a2, _DWORD *a3)
{
_DWORD *result; // rax
int v6; // [rsp+28h] [rbp-8h]
int v7; // [rsp+2Ch] [rbp-4h]
v6 = 0;
v7 = 0;
while ( *a1 )
{
if ( ((*__ctype_b_loc())[(unsigned __int8)*a1] & 0x800) != 0 )
{
++v7;
}
else if ( ((*__ctype_b_loc())[(unsigned __i... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x18],RDI
MOV qword ptr [RBP + -0x20],RSI
MOV qword ptr [RBP + -0x28],RDX
MOV dword ptr [RBP + -0x8],0x0
MOV dword ptr [RBP + -0x4],0x0
JMP 0x0010120e
LAB_001011b1:
CALL 0x00101090
MOV RDX,qword ptr [RAX]
MOV RAX,qword ptr [RBP + -0x18]
MOVZX EAX,by... | void func0(byte *param_1,int *param_2,int *param_3)
{
ushort **ppuVar1;
byte *local_20;
int local_10;
int local_c;
local_10 = 0;
local_c = 0;
for (local_20 = param_1; *local_20 != 0; local_20 = local_20 + 1) {
ppuVar1 = __ctype_b_loc();
if (((*ppuVar1)[*local_20] & 0x800) == 0) {
ppuVar1... |
5,265 | func0 |
#include <ctype.h>
#include <assert.h>
| void func0(const char *s, int *letters, int *digits) {
int l = 0, d = 0;
while (*s) {
if (isdigit((unsigned char)*s))
d++;
else if (isalpha((unsigned char)*s))
l++;
s++;
}
*letters = l;
*digits = d;
}
| int main() {
int letters, digits;
func0("python", &letters, &digits);
assert(letters == 6 && digits == 0);
func0("program", &letters, &digits);
assert(letters == 7 && digits == 0);
func0("python3.0", &letters, &digits);
assert(letters == 6 && digits == 2);
return 0;
}
| O1 | c | func0:
endbr64
push %r13
push %r12
push %rbp
push %rbx
sub $0x8,%rsp
mov %rsi,%r13
mov %rdx,%r12
movzbl (%rdi),%ebx
test %bl,%bl
je 11e3 <func0+0x5a>
mov %rdi,%rbp
callq 1090 <__ctype_b_loc@plt>
mov (%rax),%rsi
mov $0x0,%edx
mov $0x0,%ecx
jmp 11d2 <func0+0x49>
and $0x400,%ax
cm... | func0:
endbr64
push r13
push r12
push rbp
push rbx
sub rsp, 8
mov r13, rsi
mov r12, rdx
movzx ebx, byte ptr [rdi]
test bl, bl
jz short loc_11E3
mov rbp, rdi
call ___ctype_b_loc
mov rsi, [rax]
mov edx, 0
mov ecx, 0
jmp short loc_11D2
loc_11BB:
and ax, 400h
cmp... | void func0(unsigned __int8 *a1, _DWORD *a2, _DWORD *a3)
{
unsigned __int8 v5; // bl
unsigned __int8 *v6; // rbp
long long v7; // rsi
int v8; // edx
int v9; // ecx
__int16 v10; // ax
v5 = *a1;
if ( *a1 )
{
v6 = a1;
v7 = *(_QWORD *)__ctype_b_loc();
v8 = 0;
v9 = 0;
do
{
v1... | func0:
ENDBR64
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x8
MOV R13,RSI
MOV R12,RDX
MOVZX EBX,byte ptr [RDI]
TEST BL,BL
JZ 0x001011e3
MOV RBP,RDI
CALL 0x00101090
MOV RSI,qword ptr [RAX]
MOV EDX,0x0
MOV ECX,0x0
JMP 0x001011d2
LAB_001011bb:
AND AX,0x400
CMP AX,0x1
SBB ECX,-0x1
LAB_001011c6:
ADD RBP,0x1
MOVZX EBX,byte ... | void func0(byte *param_1,int *param_2,int *param_3)
{
ushort **ppuVar1;
int iVar2;
int iVar3;
byte bVar4;
bVar4 = *param_1;
if (bVar4 == 0) {
iVar3 = 0;
iVar2 = 0;
}
else {
ppuVar1 = __ctype_b_loc();
iVar3 = 0;
iVar2 = 0;
do {
if (((*ppuVar1)[bVar4] & 0x800) == 0) {
... |
5,266 | func0 |
#include <ctype.h>
#include <assert.h>
| void func0(const char *s, int *letters, int *digits) {
int l = 0, d = 0;
while (*s) {
if (isdigit((unsigned char)*s))
d++;
else if (isalpha((unsigned char)*s))
l++;
s++;
}
*letters = l;
*digits = d;
}
| int main() {
int letters, digits;
func0("python", &letters, &digits);
assert(letters == 6 && digits == 0);
func0("program", &letters, &digits);
assert(letters == 7 && digits == 0);
func0("python3.0", &letters, &digits);
assert(letters == 6 && digits == 2);
return 0;
}
| O2 | c | func0:
endbr64
push %r13
mov %rsi,%r13
push %r12
mov %rdx,%r12
push %rbp
push %rbx
sub $0x8,%rsp
movzbl (%rdi),%ebx
test %bl,%bl
je 1308 <func0+0x78>
mov %rdi,%rbp
callq 1090 <__ctype_b_loc@plt>
xor %ecx,%ecx
xor %edi,%edi
mov (%rax),%r8
jmp 12cf <func0+0x3f>
nopl 0x0(%rax)
movz... | func0:
endbr64
push r13
mov r13, rsi
push r12
mov r12, rdx
push rbp
push rbx
sub rsp, 8
movzx ebx, byte ptr [rdi]
test bl, bl
jz short loc_1308
mov rbp, rdi
call ___ctype_b_loc
xor ecx, ecx
xor edi, edi
mov r8, [rax]
jmp short loc_12CF
loc_12C0:
movzx ebx, byte... | void func0(unsigned __int8 *a1, _DWORD *a2, _DWORD *a3)
{
long long v4; // rbx
unsigned __int8 *v5; // rbp
long long *v6; // rax
int v7; // ecx
int v8; // edi
long long v9; // r8
__int16 v10; // ax
v4 = *a1;
if ( (_BYTE)v4 )
{
v5 = a1;
v6 = (long long *)__ctype_b_loc();
v7 = 0;
v8 ... | func0:
ENDBR64
PUSH R13
MOV R13,RSI
PUSH R12
MOV R12,RDX
PUSH RBP
PUSH RBX
SUB RSP,0x8
MOVZX EBX,byte ptr [RDI]
TEST BL,BL
JZ 0x00101308
MOV RBP,RDI
CALL 0x00101090
XOR ECX,ECX
XOR EDI,EDI
MOV R8,qword ptr [RAX]
JMP 0x001012cf
LAB_001012c0:
MOVZX EBX,byte ptr [RBP + 0x1]
ADD RBP,0x1
ADD ECX,0x1
TEST BL,BL
JZ 0x001012f0... | void func0(byte *param_1,int *param_2,int *param_3)
{
byte *pbVar1;
ushort **ppuVar2;
int iVar3;
ulong uVar4;
int iVar5;
uVar4 = (ulong)*param_1;
if (*param_1 == 0) {
iVar3 = 0;
iVar5 = 0;
}
else {
ppuVar2 = __ctype_b_loc();
iVar3 = 0;
iVar5 = 0;
do {
while (((*ppuVar... |
5,267 | func0 |
#include <ctype.h>
#include <assert.h>
| void func0(const char *s, int *letters, int *digits) {
int l = 0, d = 0;
while (*s) {
if (isdigit((unsigned char)*s))
d++;
else if (isalpha((unsigned char)*s))
l++;
s++;
}
*letters = l;
*digits = d;
}
| int main() {
int letters, digits;
func0("python", &letters, &digits);
assert(letters == 6 && digits == 0);
func0("program", &letters, &digits);
assert(letters == 7 && digits == 0);
func0("python3.0", &letters, &digits);
assert(letters == 6 && digits == 2);
return 0;
}
| O3 | c | func0:
endbr64
push %r13
mov %rsi,%r13
push %r12
mov %rdx,%r12
push %rbp
push %rbx
sub $0x8,%rsp
movzbl (%rdi),%ebx
test %bl,%bl
je 1308 <func0+0x78>
mov %rdi,%rbp
callq 1090 <__ctype_b_loc@plt>
xor %ecx,%ecx
xor %edi,%edi
mov (%rax),%r8
jmp 12cf <func0+0x3f>
nopl 0x0(%rax)
movz... | func0:
endbr64
push r13
mov r13, rsi
push r12
mov r12, rdx
push rbp
push rbx
sub rsp, 8
movzx ebx, byte ptr [rdi]
test bl, bl
jz short loc_1308
mov rbp, rdi
call ___ctype_b_loc
xor ecx, ecx
xor edi, edi
mov r8, [rax]
jmp short loc_12CF
loc_12C0:
movzx ebx, byte... | void func0(unsigned __int8 *a1, _DWORD *a2, _DWORD *a3)
{
long long v4; // rbx
unsigned __int8 *v5; // rbp
const unsigned __int16 **v6; // rax
int v7; // ecx
int v8; // edi
const unsigned __int16 *v9; // r8
unsigned __int16 v10; // ax
v4 = *a1;
if ( (_BYTE)v4 )
{
v5 = a1;
v6 = __ctype_b_lo... | func0:
ENDBR64
PUSH R13
MOV R13,RSI
PUSH R12
MOV R12,RDX
PUSH RBP
PUSH RBX
SUB RSP,0x8
MOVZX EBX,byte ptr [RDI]
TEST BL,BL
JZ 0x00101308
MOV RBP,RDI
CALL 0x00101090
XOR ECX,ECX
XOR EDI,EDI
MOV R8,qword ptr [RAX]
JMP 0x001012cf
LAB_001012c0:
MOVZX EBX,byte ptr [RBP + 0x1]
ADD RBP,0x1
ADD ECX,0x1
TEST BL,BL
JZ 0x001012f0... | void func0(byte *param_1,int *param_2,int *param_3)
{
byte *pbVar1;
ushort **ppuVar2;
int iVar3;
ulong uVar4;
int iVar5;
uVar4 = (ulong)*param_1;
if (*param_1 == 0) {
iVar3 = 0;
iVar5 = 0;
}
else {
ppuVar2 = __ctype_b_loc();
iVar3 = 0;
iVar5 = 0;
do {
while (((*ppuVar... |
5,268 | func0 |
#include <math.h>
#include <assert.h>
| int func0(int n, int m) {
return (int)sqrt(m) - (int)sqrt(n - 1);
}
| int main() {
assert(func0(5, 100) == 8);
assert(func0(8, 65) == 6);
assert(func0(2, 5) == 1);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x18,%rsp
mov %edi,-0x14(%rbp)
mov %esi,-0x18(%rbp)
cvtsi2sdl -0x18(%rbp),%xmm0
callq 1070 <sqrt@plt>
cvttsd2si %xmm0,%ebx
mov -0x14(%rbp),%eax
sub $0x1,%eax
cvtsi2sd %eax,%xmm0
callq 1070 <sqrt@plt>
cvttsd2si %xmm0,%eax
sub %eax,%ebx
mov ... | func0:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 18h
mov [rbp+var_14], edi
mov [rbp+var_18], esi
pxor xmm1, xmm1
cvtsi2sd xmm1, [rbp+var_18]
movq rax, xmm1
movq xmm0, rax; x
call _sqrt
cvttsd2si ebx, xmm0
mov eax, [rbp+var_14]
sub eax, 1
pxor xmm2, xmm2
cvtsi2sd xmm2, ... | long long func0(int a1, int a2)
{
int v2; // ebx
v2 = (int)sqrt((double)a2);
return (unsigned int)(v2 - (int)sqrt((double)(a1 - 1)));
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x18
MOV dword ptr [RBP + -0x14],EDI
MOV dword ptr [RBP + -0x18],ESI
PXOR XMM1,XMM1
CVTSI2SD XMM1,dword ptr [RBP + -0x18]
MOVQ RAX,XMM1
MOVQ XMM0,RAX
CALL 0x00101070
CVTTSD2SI EBX,XMM0
MOV EAX,dword ptr [RBP + -0x14]
SUB EAX,0x1
PXOR XMM2,XMM2
CVTSI2SD XMM2,EAX
MOVQ ... | int func0(int param_1,int param_2)
{
double dVar1;
double dVar2;
dVar1 = sqrt((double)param_2);
dVar2 = sqrt((double)(param_1 + -1));
return (int)dVar1 - (int)dVar2;
} |
5,269 | func0 |
#include <math.h>
#include <assert.h>
| int func0(int n, int m) {
return (int)sqrt(m) - (int)sqrt(n - 1);
}
| int main() {
assert(func0(5, 100) == 8);
assert(func0(8, 65) == 6);
assert(func0(2, 5) == 1);
return 0;
}
| O1 | c | func0:
endbr64
push %rbp
push %rbx
sub $0x18,%rsp
mov %edi,%ebx
pxor %xmm0,%xmm0
cvtsi2sd %esi,%xmm0
movapd %xmm0,%xmm2
sqrtsd %xmm2,%xmm2
movsd %xmm2,0x8(%rsp)
pxor %xmm1,%xmm1
ucomisd %xmm0,%xmm1
ja 11cf <func0+0x66>
cvttsd2si 0x8(%rsp),%ebp
sub $0x1,%ebx
pxor %xmm0,%xmm0
cvtsi2sd %ebx,%xmm0
m... | func0:
endbr64
push rbp
push rbx
sub rsp, 8
mov ebx, edi
pxor xmm0, xmm0
cvtsi2sd xmm0, esi
pxor xmm1, xmm1
ucomisd xmm1, xmm0
ja short loc_11B7
sqrtsd xmm0, xmm0
loc_118B:
cvttsd2si ebp, xmm0
sub ebx, 1
pxor xmm0, xmm0
cvtsi2sd xmm0, ebx
pxor xmm1, xmm1
ucomisd xmm1, xmm0
ja sh... | long long func0(int a1, int a2)
{
double v2; // xmm0_8
double v3; // xmm0_8
int v4; // ebp
double v5; // xmm0_8
double v6; // xmm0_8
v2 = (double)a2;
if ( (double)a2 < 0.0 )
v3 = sqrt(v2);
else
v3 = sqrt(v2);
v4 = (int)v3;
v5 = (double)(a1 - 1);
if ( v5 < 0.0 )
v6 = sqrt(v5);
else
... | func0:
ENDBR64
PUSH RBP
PUSH RBX
SUB RSP,0x8
MOV EBX,EDI
PXOR XMM0,XMM0
CVTSI2SD XMM0,ESI
PXOR XMM1,XMM1
UCOMISD XMM1,XMM0
JA 0x001011b7
SQRTSD XMM0,XMM0
LAB_0010118b:
CVTTSD2SI EBP,XMM0
SUB EBX,0x1
PXOR XMM0,XMM0
CVTSI2SD XMM0,EBX
PXOR XMM1,XMM1
UCOMISD XMM1,XMM0
JA 0x001011be
SQRTSD XMM0,XMM0
LAB_001011a8:
CVTTSD2SI ... | int func0(int param_1,int param_2)
{
double dVar1;
double dVar2;
dVar1 = (double)param_2;
if (dVar1 < 0.0) {
dVar1 = sqrt(dVar1);
}
else {
dVar1 = SQRT(dVar1);
}
dVar2 = (double)(param_1 + -1);
if (dVar2 < 0.0) {
dVar2 = sqrt(dVar2);
}
else {
dVar2 = SQRT(dVar2);
}
return (... |
5,270 | func0 |
#include <math.h>
#include <assert.h>
| int func0(int n, int m) {
return (int)sqrt(m) - (int)sqrt(n - 1);
}
| int main() {
assert(func0(5, 100) == 8);
assert(func0(8, 65) == 6);
assert(func0(2, 5) == 1);
return 0;
}
| O2 | c | func0:
endbr64
pxor %xmm0,%xmm0
pxor %xmm2,%xmm2
sub $0x18,%rsp
cvtsi2sd %esi,%xmm0
ucomisd %xmm0,%xmm2
movapd %xmm0,%xmm1
sqrtsd %xmm1,%xmm1
ja 126a <func0+0x4a>
sub $0x1,%edi
cvttsd2si %xmm1,%eax
pxor %xmm0,%xmm0
cvtsi2sd %edi,%xmm0
ucomisd %xmm0,%xmm2
movapd %xmm0,%xmm1
sqrtsd %xmm1,%xmm1
ja 1287... | func0:
endbr64
pxor xmm0, xmm0
pxor xmm1, xmm1
sub rsp, 18h
cvtsi2sd xmm0, esi
ucomisd xmm1, xmm0
ja short loc_1262
sqrtsd xmm0, xmm0
loc_123E:
sub edi, 1
cvttsd2si eax, xmm0
pxor xmm0, xmm0
cvtsi2sd xmm0, edi
ucomisd xmm1, xmm0
ja short loc_1275
sqrtsd xmm0, xmm0
loc_1257:
cvttsd2si edx, x... | long long func0(int a1, int a2)
{
double v2; // xmm0_8
double v3; // xmm0_8
int v4; // eax
double v5; // xmm0_8
double v6; // xmm0_8
int v8; // [rsp+Ch] [rbp-Ch]
v2 = (double)a2;
if ( (double)a2 < 0.0 )
v3 = sqrt(v2);
else
v3 = sqrt(v2);
v4 = (int)v3;
v5 = (double)(a1 - 1);
if ( v5 < 0... | func0:
ENDBR64
PXOR XMM0,XMM0
PXOR XMM1,XMM1
SUB RSP,0x18
CVTSI2SD XMM0,ESI
UCOMISD XMM1,XMM0
JA 0x00101262
SQRTSD XMM0,XMM0
LAB_0010123e:
SUB EDI,0x1
CVTTSD2SI EAX,XMM0
PXOR XMM0,XMM0
CVTSI2SD XMM0,EDI
UCOMISD XMM1,XMM0
JA 0x00101275
SQRTSD XMM0,XMM0
LAB_00101257:
CVTTSD2SI EDX,XMM0
ADD RSP,0x18
SUB EAX,EDX
RET
LAB_00... | int func0(int param_1,int param_2)
{
double dVar1;
double dVar2;
dVar1 = (double)param_2;
if (dVar1 < 0.0) {
dVar1 = sqrt(dVar1);
}
else {
dVar1 = SQRT(dVar1);
}
dVar2 = (double)(param_1 + -1);
if (dVar2 < 0.0) {
dVar2 = sqrt(dVar2);
}
else {
dVar2 = SQRT(dVar2);
}
return (... |
5,271 | func0 |
#include <math.h>
#include <assert.h>
| int func0(int n, int m) {
return (int)sqrt(m) - (int)sqrt(n - 1);
}
| int main() {
assert(func0(5, 100) == 8);
assert(func0(8, 65) == 6);
assert(func0(2, 5) == 1);
return 0;
}
| O3 | c | func0:
endbr64
pxor %xmm0,%xmm0
pxor %xmm2,%xmm2
sub $0x18,%rsp
cvtsi2sd %esi,%xmm0
ucomisd %xmm0,%xmm2
movapd %xmm0,%xmm1
sqrtsd %xmm1,%xmm1
ja 126a <func0+0x4a>
sub $0x1,%edi
cvttsd2si %xmm1,%eax
pxor %xmm0,%xmm0
cvtsi2sd %edi,%xmm0
ucomisd %xmm0,%xmm2
movapd %xmm0,%xmm1
sqrtsd %xmm1,%xmm1
ja 1287... | func0:
endbr64
pxor xmm0, xmm0
pxor xmm1, xmm1
sub rsp, 18h
cvtsi2sd xmm0, esi; x
ucomisd xmm1, xmm0
ja short loc_1266
sqrtsd xmm0, xmm0
loc_123E:
sub edi, 1
cvttsd2si eax, xmm0
pxor xmm0, xmm0
cvtsi2sd xmm0, edi; x
pxor xmm1, xmm1
ucomisd xmm1, xmm0
ja short loc_1275
sqrtsd xmm0, xmm0
l... | long long func0(int a1, int a2)
{
double v2; // xmm0_8
double v3; // xmm0_8
int v4; // eax
double v5; // xmm0_8
double v6; // xmm0_8
int v8; // [rsp+Ch] [rbp-Ch]
v2 = (double)a2;
if ( (double)a2 < 0.0 )
v3 = sqrt(v2);
else
v3 = sqrt(v2);
v4 = (int)v3;
v5 = (double)(a1 - 1);
if ( v5 < 0... | func0:
ENDBR64
PXOR XMM0,XMM0
PXOR XMM1,XMM1
SUB RSP,0x18
CVTSI2SD XMM0,ESI
UCOMISD XMM1,XMM0
JA 0x00101266
SQRTSD XMM0,XMM0
LAB_0010123e:
SUB EDI,0x1
CVTTSD2SI EAX,XMM0
PXOR XMM0,XMM0
CVTSI2SD XMM0,EDI
PXOR XMM1,XMM1
UCOMISD XMM1,XMM0
JA 0x00101275
SQRTSD XMM0,XMM0
LAB_0010125b:
CVTTSD2SI EDX,XMM0
ADD RSP,0x18
SUB EAX... | int func0(int param_1,int param_2)
{
double dVar1;
double dVar2;
dVar1 = (double)param_2;
if (dVar1 < 0.0) {
dVar1 = sqrt(dVar1);
}
else {
dVar1 = SQRT(dVar1);
}
dVar2 = (double)(param_1 + -1);
if (dVar2 < 0.0) {
dVar2 = sqrt(dVar2);
}
else {
dVar2 = SQRT(dVar2);
}
return (... |
5,272 | func0 |
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
| int* func0(int nums[], int size, int *result_size) {
*result_size = size - 1;
int *result = malloc(*result_size * sizeof(int));
for (int i = 0; i < *result_size; i++) {
result[i] = nums[i + 1] - nums[i];
}
return result;
}
| int main() {
int result_size;
int *result;
int test1[] = {1, 1, 3, 4, 4, 5, 6, 7};
result = func0(test1, 8, &result_size);
int expected1[] = {0, 2, 1, 0, 1, 1, 1};
for (int i = 0; i < result_size; i++) {
assert(result[i] == expected1[i]);
}
free(result);
int tes... | O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
sub $0x30,%rsp
mov %rdi,-0x18(%rbp)
mov %esi,-0x1c(%rbp)
mov %rdx,-0x28(%rbp)
mov -0x1c(%rbp),%eax
lea -0x1(%rax),%edx
mov -0x28(%rbp),%rax
mov %edx,(%rax)
mov -0x28(%rbp),%rax
mov (%rax),%eax
cltq
shl $0x2,%rax
mov %rax,%rdi
callq 10b0 <m... | func0:
endbr64
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_18], rdi
mov [rbp+var_1C], esi
mov [rbp+var_28], rdx
mov eax, [rbp+var_1C]
lea edx, [rax-1]
mov rax, [rbp+var_28]
mov [rax], edx
mov rax, [rbp+var_28]
mov eax, [rax]
cdqe
shl rax, 2
mov rdi, rax; size
c... | _DWORD * func0(long long a1, int a2, int *a3)
{
int i; // [rsp+24h] [rbp-Ch]
_DWORD *v6; // [rsp+28h] [rbp-8h]
*a3 = a2 - 1;
v6 = malloc(4LL * *a3);
for ( i = 0; i < *a3; ++i )
v6[i] = *(_DWORD *)(4 * (i + 1LL) + a1) - *(_DWORD *)(4LL * i + a1);
return v6;
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV qword ptr [RBP + -0x18],RDI
MOV dword ptr [RBP + -0x1c],ESI
MOV qword ptr [RBP + -0x28],RDX
MOV EAX,dword ptr [RBP + -0x1c]
LEA EDX,[RAX + -0x1]
MOV RAX,qword ptr [RBP + -0x28]
MOV dword ptr [RAX],EDX
MOV RAX,qword ptr [RBP + -0x28]
MOV EAX,dword ptr [RAX]
CDQE
SHL R... | void * func0(long param_1,int param_2,int *param_3)
{
void *pvVar1;
int4 local_14;
*param_3 = param_2 + -1;
pvVar1 = malloc((long)*param_3 << 2);
for (local_14 = 0; local_14 < *param_3; local_14 = local_14 + 1) {
*(int *)((long)pvVar1 + (long)local_14 * 4) =
*(int *)(param_1 + ((long)local_14... |
5,273 | func0 |
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
| int* func0(int nums[], int size, int *result_size) {
*result_size = size - 1;
int *result = malloc(*result_size * sizeof(int));
for (int i = 0; i < *result_size; i++) {
result[i] = nums[i + 1] - nums[i];
}
return result;
}
| int main() {
int result_size;
int *result;
int test1[] = {1, 1, 3, 4, 4, 5, 6, 7};
result = func0(test1, 8, &result_size);
int expected1[] = {0, 2, 1, 0, 1, 1, 1};
for (int i = 0; i < result_size; i++) {
assert(result[i] == expected1[i]);
}
free(result);
int tes... | O1 | c | func0:
endbr64
push %rbp
push %rbx
sub $0x8,%rsp
mov %rdi,%rbx
mov %rdx,%rbp
sub $0x1,%esi
mov %esi,(%rdx)
movslq %esi,%rsi
lea 0x0(,%rsi,4),%rdi
callq 10b0 <malloc@plt>
mov 0x0(%rbp),%edx
test %edx,%edx
jle 11f3 <func0+0x4a>
lea -0x1(%rdx),%esi
mov $0x0,%edx
mov 0x4(%rbx,%rdx,4)... | func0:
endbr64
push rbp
push rbx
sub rsp, 8
mov rbx, rdi
mov rbp, rdx
sub esi, 1
mov [rdx], esi
movsxd rsi, esi
lea rdi, ds:0[rsi*4]
call _malloc
mov esi, [rbp+0]
test esi, esi
jle short loc_11EF
mov esi, esi
mov edx, 0
loc_11DC:
mov ecx, [rbx+rdx*4+4]
sub ec... | long long func0(long long a1, int a2, int *a3)
{
int v4; // esi
long long result; // rax
int v6; // esi
long long v7; // rdx
v4 = a2 - 1;
*a3 = v4;
result = malloc(4LL * v4);
v6 = *a3;
if ( *a3 > 0 )
{
v7 = 0LL;
do
{
*(_DWORD *)(result + 4 * v7) = *(_DWORD *)(a1 + 4 * v7 + 4) - *... | func0:
ENDBR64
PUSH RBP
PUSH RBX
SUB RSP,0x8
MOV RBX,RDI
MOV RBP,RDX
SUB ESI,0x1
MOV dword ptr [RDX],ESI
MOVSXD RSI,ESI
LEA RDI,[RSI*0x4]
CALL 0x001010b0
MOV ESI,dword ptr [RBP]
TEST ESI,ESI
JLE 0x001011ef
MOV ESI,ESI
MOV EDX,0x0
LAB_001011dc:
MOV ECX,dword ptr [RBX + RDX*0x4 + 0x4]
SUB ECX,dword ptr [RBX + RDX*0x4]
MO... | void func0(long param_1,int param_2,uint *param_3)
{
uint uVar1;
void *pvVar2;
ulong uVar3;
*param_3 = param_2 - 1U;
pvVar2 = malloc((long)(int)(param_2 - 1U) * 4);
uVar1 = *param_3;
if (0 < (int)uVar1) {
uVar3 = 0;
do {
*(int *)((long)pvVar2 + uVar3 * 4) =
*(int *)(param_1 + ... |
5,274 | func0 |
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
| int* func0(int nums[], int size, int *result_size) {
*result_size = size - 1;
int *result = malloc(*result_size * sizeof(int));
for (int i = 0; i < *result_size; i++) {
result[i] = nums[i + 1] - nums[i];
}
return result;
}
| int main() {
int result_size;
int *result;
int test1[] = {1, 1, 3, 4, 4, 5, 6, 7};
result = func0(test1, 8, &result_size);
int expected1[] = {0, 2, 1, 0, 1, 1, 1};
for (int i = 0; i < result_size; i++) {
assert(result[i] == expected1[i]);
}
free(result);
int tes... | O2 | c | func0:
endbr64
push %rbp
sub $0x1,%esi
mov %rdx,%rbp
push %rbx
mov %rdi,%rbx
sub $0x8,%rsp
mov %esi,(%rdx)
movslq %esi,%rsi
lea 0x0(,%rsi,4),%rdi
callq 10b0 <malloc@plt>
mov 0x0(%rbp),%edx
test %edx,%edx
jle 14ae <func0+0x4e>
lea -0x1(%rdx),%esi
xor %edx,%edx
nopl 0x0(%rax)
mov ... | func0:
endbr64
push rbp
sub esi, 1
mov rbp, rdx
push rbx
mov rbx, rdi
sub rsp, 8
mov [rdx], esi
movsxd rsi, esi
lea rdi, ds:0[rsi*4]
call _malloc
movsxd rsi, dword ptr [rbp+0]
test esi, esi
jle short loc_14A3
xor edx, edx
nop
loc_1490:
mov ecx, [rbx+rdx*4+4]
sub ecx... | long long func0(long long a1, int a2, int *a3)
{
int v3; // esi
long long result; // rax
long long v6; // rsi
long long i; // rdx
v3 = a2 - 1;
*a3 = v3;
result = malloc(4LL * v3);
v6 = *a3;
if ( (int)v6 > 0 )
{
for ( i = 0LL; i != v6; ++i )
*(_DWORD *)(result + 4 * i) = *(_DWORD *)(a1 + ... | func0:
ENDBR64
PUSH RBP
SUB ESI,0x1
MOV RBP,RDX
PUSH RBX
MOV RBX,RDI
SUB RSP,0x8
MOV dword ptr [RDX],ESI
MOVSXD RSI,ESI
LEA RDI,[RSI*0x4]
CALL 0x001010b0
MOVSXD RSI,dword ptr [RBP]
TEST ESI,ESI
JLE 0x001014a3
XOR EDX,EDX
NOP
LAB_00101490:
MOV ECX,dword ptr [RBX + RDX*0x4 + 0x4]
SUB ECX,dword ptr [RBX + RDX*0x4]
MOV dwo... | void func0(long param_1,int param_2,int *param_3)
{
int iVar1;
void *pvVar2;
long lVar3;
*param_3 = param_2 + -1;
pvVar2 = malloc((long)(param_2 + -1) * 4);
iVar1 = *param_3;
if (0 < iVar1) {
lVar3 = 0;
do {
*(int *)((long)pvVar2 + lVar3 * 4) =
*(int *)(param_1 + 4 + lVar3 * 4... |
5,275 | func0 |
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
| int* func0(int nums[], int size, int *result_size) {
*result_size = size - 1;
int *result = malloc(*result_size * sizeof(int));
for (int i = 0; i < *result_size; i++) {
result[i] = nums[i + 1] - nums[i];
}
return result;
}
| int main() {
int result_size;
int *result;
int test1[] = {1, 1, 3, 4, 4, 5, 6, 7};
result = func0(test1, 8, &result_size);
int expected1[] = {0, 2, 1, 0, 1, 1, 1};
for (int i = 0; i < result_size; i++) {
assert(result[i] == expected1[i]);
}
free(result);
int tes... | O3 | c | func0:
endbr64
push %rbp
sub $0x1,%esi
mov %rdx,%rbp
push %rbx
mov %rdi,%rbx
sub $0x8,%rsp
mov %esi,(%rdx)
movslq %esi,%rsi
lea 0x0(,%rsi,4),%rdi
callq 10b0 <malloc@plt>
mov 0x0(%rbp),%esi
test %esi,%esi
jle 15ec <func0+0x10c>
lea -0x1(%rsi),%edi
cmp $0x2,%edi
jbe 164a <func0+0x1... | func0:
endbr64
push rbp
sub esi, 1
mov rbp, rdx
push rbx
mov rbx, rdi
sub rsp, 8
mov [rdx], esi
movsxd rsi, esi
lea rdi, ds:0[rsi*4]; size
call _malloc
mov edx, [rbp+0]
mov rcx, rax
test edx, edx
jle loc_14D9
lea eax, [rdx-1]
cmp eax, 2
jbe loc_14E3
mov e... | _DWORD * func0(long long a1, int a2, unsigned int *a3)
{
unsigned int v3; // esi
_DWORD *v5; // rax
unsigned int v6; // edx
_DWORD *v7; // rcx
long long v8; // rax
signed int v9; // eax
unsigned int v10; // esi
unsigned int v11; // edx
v3 = a2 - 1;
*a3 = v3;
v5 = malloc(4LL * (int)v3);
v6 = *a3... | func0:
ENDBR64
PUSH RBP
SUB ESI,0x1
MOV RBP,RDX
PUSH RBX
MOV RBX,RDI
SUB RSP,0x8
MOV dword ptr [RDX],ESI
MOVSXD RSI,ESI
LEA RDI,[RSI*0x4]
CALL 0x001010b0
MOV EDX,dword ptr [RBP]
MOV RCX,RAX
TEST EDX,EDX
JLE 0x001014d9
LEA EAX,[RDX + -0x1]
CMP EAX,0x2
JBE 0x001014e3
MOV ESI,EDX
XOR EAX,EAX
SHR ESI,0x2
SHL RSI,0x4
NOP wo... | void * func0(long param_1,int param_2,uint *param_3)
{
int *piVar1;
int *piVar2;
int *piVar3;
int8 uVar4;
int8 uVar5;
int iVar6;
int iVar7;
int iVar8;
int iVar9;
int iVar10;
int iVar11;
uint uVar12;
void *pvVar13;
long lVar14;
uint uVar15;
*param_3 = param_2 - 1U;
pvVar13 = malloc(... |
5,276 | func0 |
#include <assert.h>
| int func0(int n, int k) {
if (n == 0 && k == 0) {
return 1;
}
if (k == 0) {
return 0;
}
return func0(n, k - 1) + func0(n - 1, n - k);
}
| int main() {
assert(func0(4, 3) == 5);
assert(func0(4, 2) == 4);
assert(func0(3, 1) == 1);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x18,%rsp
mov %edi,-0x14(%rbp)
mov %esi,-0x18(%rbp)
cmpl $0x0,-0x14(%rbp)
jne 116f <func0+0x26>
cmpl $0x0,-0x18(%rbp)
jne 116f <func0+0x26>
mov $0x1,%eax
jmp 11a7 <func0+0x5e>
cmpl $0x0,-0x18(%rbp)
jne 117c <func0+0x33>
mov $0... | func0:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 18h
mov [rbp+var_14], edi
mov [rbp+var_18], esi
cmp [rbp+var_14], 0
jnz short loc_116F
cmp [rbp+var_18], 0
jnz short loc_116F
mov eax, 1
jmp short loc_11A7
loc_116F:
cmp [rbp+var_18], 0
jnz short loc_117C
mov ... | long long func0(unsigned int a1, int a2)
{
int v3; // ebx
if ( !a1 && !a2 )
return 1LL;
if ( !a2 )
return 0LL;
v3 = func0(a1, (unsigned int)(a2 - 1));
return v3 + (unsigned int)func0(a1 - 1, a1 - a2);
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x18
MOV dword ptr [RBP + -0x14],EDI
MOV dword ptr [RBP + -0x18],ESI
CMP dword ptr [RBP + -0x14],0x0
JNZ 0x0010116f
CMP dword ptr [RBP + -0x18],0x0
JNZ 0x0010116f
MOV EAX,0x1
JMP 0x001011a7
LAB_0010116f:
CMP dword ptr [RBP + -0x18],0x0
JNZ 0x0010117c
MOV EAX,0x0
JMP ... | int func0(int param_1,int param_2)
{
int iVar1;
int iVar2;
if ((param_1 == 0) && (param_2 == 0)) {
iVar2 = 1;
}
else if (param_2 == 0) {
iVar2 = 0;
}
else {
iVar1 = func0(param_1,param_2 + -1);
iVar2 = func0(param_1 + -1,param_1 - param_2);
iVar2 = iVar2 + iVar1;
}
return iVar2... |
5,277 | func0 |
#include <assert.h>
| int func0(int n, int k) {
if (n == 0 && k == 0) {
return 1;
}
if (k == 0) {
return 0;
}
return func0(n, k - 1) + func0(n - 1, n - k);
}
| int main() {
assert(func0(4, 3) == 5);
assert(func0(4, 2) == 4);
assert(func0(3, 1) == 1);
return 0;
}
| O1 | c | func0:
endbr64
mov $0x1,%eax
mov %edi,%edx
or %esi,%edx
je 1187 <func0+0x3e>
push %r12
push %rbp
push %rbx
mov %edi,%ebp
mov %esi,%ebx
mov %esi,%eax
test %esi,%esi
jne 116b <func0+0x22>
pop %rbx
pop %rbp
pop %r12
retq
lea -0x1(%rsi),%esi
callq 1149 <func0>
mov %eax,%r12... | func0:
endbr64
mov eax, 1
mov edx, edi
or edx, esi
jz short locret_1189
push r12
push rbp
push rbx
mov r12d, edi
mov ebx, esi
mov eax, esi
test esi, esi
jnz short loc_116C
loc_1167:
pop rbx
pop rbp
pop r12
retn
loc_116C:
lea esi, [rsi-1]
call func0
mov ... | long long func0(long long a1, unsigned int a2)
{
long long result; // rax
int v3; // ebp
result = 1LL;
if ( a2 | (unsigned int)a1 )
{
result = a2;
if ( a2 )
{
v3 = func0(a1, a2 - 1);
return v3 + (unsigned int)func0((unsigned int)(a1 - 1), (unsigned int)a1 - a2);
}
}
return re... | func0:
ENDBR64
MOV EAX,0x1
MOV EDX,EDI
OR EDX,ESI
JZ 0x00101189
PUSH R12
PUSH RBP
PUSH RBX
MOV R12D,EDI
MOV EBX,ESI
MOV EAX,ESI
TEST ESI,ESI
JNZ 0x0010116c
LAB_00101167:
POP RBX
POP RBP
POP R12
RET
LAB_0010116c:
LEA ESI,[RSI + -0x1]
CALL 0x00101149
MOV EBP,EAX
MOV ESI,R12D
SUB ESI,EBX
LEA EDI,[R12 + -0x1]
CALL 0x001011... | int func0(int8 param_1,int param_2)
{
int iVar1;
int iVar2;
iVar2 = (int)param_1;
if (iVar2 != 0 || param_2 != 0) {
if (param_2 != 0) {
iVar1 = func0(param_1,param_2 + -1);
param_2 = func0(iVar2 + -1,iVar2 - param_2);
param_2 = param_2 + iVar1;
}
return param_2;
}
return 1;... |
5,278 | func0 |
#include <assert.h>
| int func0(int n, int k) {
if (n == 0 && k == 0) {
return 1;
}
if (k == 0) {
return 0;
}
return func0(n, k - 1) + func0(n - 1, n - k);
}
| int main() {
assert(func0(4, 3) == 5);
assert(func0(4, 2) == 4);
assert(func0(3, 1) == 1);
return 0;
}
| O2 | c | func0:
endbr64
mov %edi,%eax
push %r12
or %esi,%eax
push %rbp
push %rbx
je 1258 <func0+0x58>
mov %esi,%ebx
test %esi,%esi
je 1270 <func0+0x70>
mov %edi,%ebp
xor %r12d,%r12d
lea -0x1(%rbx),%esi
mov %ebp,%edi
callq 1200 <func0>
mov %ebp,%edx
sub $0x1,%ebp
sub %ebx,%edx
add ... | func0:
endbr64
mov eax, esi
mov esi, edi
or esi, eax
jz loc_164F
test eax, eax
jz locret_1655
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 68h
mov [rsp+98h+var_88], 0
loc_122E:
lea esi, [rax-1]
mov ebx, edi
lea r11d, [rdi-1]
sub ebx, ... | long long func0(long long a1, unsigned int a2)
{
long long result; // rax
unsigned int v3; // r11d
int v4; // esi
bool v5; // zf
unsigned int v6; // r10d
int v7; // r11d
int v8; // eax
unsigned int v9; // r11d
int v10; // r15d
int v11; // r14d
int v12; // eax
unsigned int v13; // ebx
int v14;... | func0:
ENDBR64
MOV EAX,ESI
MOV ESI,EDI
OR ESI,EAX
JZ 0x0010164f
TEST EAX,EAX
JZ 0x00101655
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x68
MOV dword ptr [RSP + 0x10],0x0
LAB_0010122e:
LEA ESI,[RAX + -0x1]
MOV EBX,EDI
LEA R11D,[RDI + -0x1]
SUB EBX,EAX
MOV EAX,ESI
MOV dword ptr [RSP + 0x14],ESI
OR EAX,... | int func0(ulong param_1,int param_2)
{
ulong uVar1;
int iVar2;
int iVar3;
int iVar4;
int iVar5;
int iVar6;
uint uVar7;
uint uVar8;
ulong uVar9;
ulong uVar10;
ulong uVar11;
ulong uVar12;
int iVar13;
int iVar14;
int iVar15;
int iVar16;
int iVar17;
uint uVar18;
uint uVar19;
int iVa... |
5,279 | func0 |
#include <assert.h>
| int func0(int n, int k) {
if (n == 0 && k == 0) {
return 1;
}
if (k == 0) {
return 0;
}
return func0(n, k - 1) + func0(n - 1, n - k);
}
| int main() {
assert(func0(4, 3) == 5);
assert(func0(4, 2) == 4);
assert(func0(3, 1) == 1);
return 0;
}
| O3 | c | func0:
endbr64
mov %edi,%eax
push %r12
or %esi,%eax
push %rbp
push %rbx
je 1258 <func0+0x58>
mov %esi,%ebx
test %esi,%esi
je 1270 <func0+0x70>
mov %edi,%ebp
xor %r12d,%r12d
lea -0x1(%rbx),%esi
mov %ebp,%edi
callq 1200 <func0>
mov %ebp,%edx
sub $0x1,%ebp
sub %ebx,%edx
add ... | func0:
endbr64
push r15
mov eax, edi
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 68h
or eax, esi
jz loc_1741
mov ebp, esi
test esi, esi
jz loc_1537
xor r14d, r14d
mov ebx, edi
loc_122B:
lea r15d, [rbp-1]
mov eax, r15d
or eax, ebx
jz loc... | long long func0(int a1, unsigned int a2)
{
unsigned int v2; // ebp
unsigned int v3; // r14d
int v4; // ebx
int v5; // r15d
unsigned int v6; // esi
int v7; // r13d
int v8; // eax
int v9; // ebp
unsigned int v10; // r9d
int v11; // r12d
int v12; // ebx
int v13; // r8d
int v14; // r13d
int v15... | func0:
ENDBR64
PUSH R15
MOV EAX,EDI
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x68
OR EAX,ESI
JZ 0x00101741
MOV EBP,ESI
TEST ESI,ESI
JZ 0x00101537
XOR R14D,R14D
MOV EBX,EDI
LAB_0010122b:
LEA R15D,[RBP + -0x1]
MOV EAX,R15D
OR EAX,EBX
JZ 0x00101728
TEST R15D,R15D
JZ 0x0010151b
LAB_00101243:
MOV dword ptr [RSP ... | int func0(int param_1,int param_2)
{
int iVar1;
int iVar2;
int iVar3;
int iVar4;
int iVar5;
int iVar6;
int iVar7;
int iVar8;
int iVar9;
int iVar10;
int iVar11;
int iVar12;
int iVar13;
int iVar14;
int iVar15;
int iVar16;
int iVar17;
int iVar18;
int iVar19;
int iVar20;
int iVar2... |
5,280 | func0 |
#include <assert.h>
| int func0(int m, int n) {
if (n < m) {
int temp = m;
m = n;
n = temp;
}
return n * (n + 1) * (3 * m - n + 1) / 6;
}
| int main() {
assert(func0(4, 3) == 20);
assert(func0(1, 2) == 2);
assert(func0(2, 2) == 5);
return 0;
}
| O0 | c | func0:
endbr64
push %rbp
mov %rsp,%rbp
mov %edi,-0x14(%rbp)
mov %esi,-0x18(%rbp)
mov -0x18(%rbp),%eax
cmp -0x14(%rbp),%eax
jge 1171 <func0+0x28>
mov -0x14(%rbp),%eax
mov %eax,-0x4(%rbp)
mov -0x18(%rbp),%eax
mov %eax,-0x14(%rbp)
mov -0x4(%rbp),%eax
mov %eax,-0x18(%rbp)
mov -0x18(... | func0:
endbr64
push rbp
mov rbp, rsp
mov [rbp+var_14], edi
mov [rbp+var_18], esi
mov eax, [rbp+var_18]
cmp eax, [rbp+var_14]
jge short loc_1171
mov eax, [rbp+var_14]
mov [rbp+var_4], eax
mov eax, [rbp+var_18]
mov [rbp+var_14], eax
mov eax, [rbp+var_4]
mov [rbp+var_18],... | long long func0(int a1, int a2)
{
int v3; // [rsp+0h] [rbp-18h]
int v4; // [rsp+4h] [rbp-14h]
v4 = a1;
v3 = a2;
if ( a2 < a1 )
{
v4 = a2;
v3 = a1;
}
return (unsigned int)(v3 * (v3 + 1) * (3 * v4 - v3 + 1) / 6);
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
MOV dword ptr [RBP + -0x14],EDI
MOV dword ptr [RBP + -0x18],ESI
MOV EAX,dword ptr [RBP + -0x18]
CMP EAX,dword ptr [RBP + -0x14]
JGE 0x00101171
MOV EAX,dword ptr [RBP + -0x14]
MOV dword ptr [RBP + -0x4],EAX
MOV EAX,dword ptr [RBP + -0x18]
MOV dword ptr [RBP + -0x14],EAX
MOV EAX,dword ... | int func0(int param_1,int param_2)
{
int4 local_20;
int4 local_1c;
local_20 = param_2;
local_1c = param_1;
if (param_2 < param_1) {
local_20 = param_1;
local_1c = param_2;
}
return (((local_1c * 3 - local_20) + 1) * (local_20 + 1) * local_20) / 6;
} |
5,281 | func0 |
#include <assert.h>
| int func0(int m, int n) {
if (n < m) {
int temp = m;
m = n;
n = temp;
}
return n * (n + 1) * (3 * m - n + 1) / 6;
}
| int main() {
assert(func0(4, 3) == 20);
assert(func0(1, 2) == 2);
assert(func0(2, 2) == 5);
return 0;
}
| O1 | c | func0:
endbr64
mov %esi,%eax
cmp %edi,%esi
jge 1159 <func0+0x10>
mov %edi,%edx
mov %esi,%edi
mov %edx,%eax
lea (%rdi,%rdi,2),%esi
sub %eax,%esi
add $0x1,%esi
lea 0x1(%rax),%edx
imul %edx,%eax
imul %eax,%esi
movslq %esi,%rax
imul $0x2aaaaaab,%rax,%rax
shr $0x20,%rax
sar $0x1f,%e... | func0:
endbr64
mov eax, esi
cmp esi, edi
jge short loc_1159
mov edx, edi
mov edi, esi
mov eax, edx
loc_1159:
lea esi, [rdi+rdi*2]
sub esi, eax
add esi, 1
lea edx, [rax+1]
imul eax, edx
imul esi, eax
movsxd rax, esi
imul rax, 2AAAAAABh
shr rax, 20h
sar esi, 1Fh
s... | long long func0(int a1, int a2)
{
int v2; // eax
int v3; // edx
v2 = a2;
if ( a2 < a1 )
{
v3 = a1;
a1 = a2;
v2 = v3;
}
return (unsigned int)((v2 + 1) * v2 * (3 * a1 - v2 + 1) / 6);
} | func0:
ENDBR64
MOV EAX,ESI
CMP ESI,EDI
JGE 0x00101159
MOV EDX,EDI
MOV EDI,ESI
MOV EAX,EDX
LAB_00101159:
LEA ESI,[RDI + RDI*0x2]
SUB ESI,EAX
ADD ESI,0x1
LEA EDX,[RAX + 0x1]
IMUL EAX,EDX
IMUL ESI,EAX
MOVSXD RAX,ESI
IMUL RAX,RAX,0x2aaaaaab
SHR RAX,0x20
SAR ESI,0x1f
SUB EAX,ESI
RET | int func0(int param_1,int param_2)
{
int iVar1;
iVar1 = param_2;
if (param_2 < param_1) {
iVar1 = param_1;
param_1 = param_2;
}
return (((param_1 * 3 - iVar1) + 1) * iVar1 * (iVar1 + 1)) / 6;
} |
Subsets and Splits
C++ Functions With Standard Library Dependencies
Identifies C++ functions that depend on standard library components, revealing patterns in how developers utilize STL libraries and potentially highlighting common coding practices or dependencies in the dataset.
C++ Standard Library Function Analysis
Filters C++ code examples that use standard library containers and types, providing useful insights into common programming patterns and data structures in the dataset.
Random Training Function Samples
Performs basic filtering and random sampling of assembly code data without revealing meaningful patterns or relationships.
Random Training Function Samples
Retrieves a random sample of 1000 records from the training dataset, providing basic data exploration but offering limited analytical value beyond seeing raw entries.