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 |
|---|---|---|---|---|---|---|---|---|---|---|---|
1,282 | func0 |
#include <string>
#include <assert.h>
| std::string func0(std::string s) {
int l = s.length();
std::string res = "";
for (int i = 1; i <= l; i++) {
res += std::to_string(i);
}
for (int i = l - 1; i > 0; i--) {
res += std::to_string(i);
}
return res;
}
| int main() {
assert(func0("111111") == "12345654321");
assert(func0("1111") == "1234321");
assert(func0("13333122222") == "123456789101110987654321");
return 0;
}
| O2 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >):
endbr64
push %r15
lea 0x10(%rdi),%rcx
push %r14
push %r13
push %r12
mov %rdi,%r12
push %rbp
push %rbx
sub $0x48,%rsp
mov %fs:0x28,%rax
mov %rax,0x38(%rsp)
xor %eax,%eax
mov 0x8(%rsi),%rax
mov %rcx... | _Z5func0NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r15
push r14
push r13
push r12
mov r12, rdi
push rbp
push rbx
sub rsp, 118h
mov rcx, [rsi+8]
mov rax, fs:28h
mov [rsp+148h+var_40], rax
xor eax, eax
lea rax, [rdi+10h]
mov qword ptr [rdi+8], 0
mo... | long long func0(long long a1, long long a2)
{
long long v3; // rcx
int v4; // ebp
unsigned int v5; // ebx
unsigned int v6; // ecx
unsigned int v7; // r15d
long long v8; // rsi
_BYTE *v9; // rsi
unsigned int v10; // eax
unsigned int v11; // edi
long long v12; // rax
long long v13; // r9
long lon... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
MOV R12,RDI
PUSH RBP
PUSH RBX
SUB RSP,0x118
MOV RCX,qword ptr [RSI + 0x8]
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x108],RAX
XOR EAX,EAX
LEA RAX,[RDI + 0x10]
MOV qword ptr [RDI + 0x8],0x0
MOV qword ptr [RSP + 0x8],RCX
MOV dword ptr [RSP + 0x4],ECX
MOV qword pt... | /* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* func0(std::string) */
long * func0(long *param_1,long param_2)
{
int uVar1;
int8 uVar2;
uint uVar3;
long *plVar4;
int iVar5;
uint uVar6;
uint uVar7;
uint uVar8;
uint uVar9;
char cVar10;
uint uVar11;
ulong u... |
1,283 | func0 |
#include <string>
#include <assert.h>
| std::string func0(std::string s) {
int l = s.length();
std::string res = "";
for (int i = 1; i <= l; i++) {
res += std::to_string(i);
}
for (int i = l - 1; i > 0; i--) {
res += std::to_string(i);
}
return res;
}
| int main() {
assert(func0("111111") == "12345654321");
assert(func0("1111") == "1234321");
assert(func0("13333122222") == "123456789101110987654321");
return 0;
}
| O3 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >):
endbr64
push %r15
lea 0x10(%rdi),%rcx
push %r14
push %r13
push %r12
mov %rdi,%r12
push %rbp
push %rbx
sub $0x58,%rsp
mov %fs:0x28,%rax
mov %rax,0x48(%rsp)
xor %eax,%eax
mov 0x8(%rsi),%rax
mov %rcx... | _Z5func0NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r15
push r14
push r13
push r12
mov r12, rdi
push rbp
mov ebp, 1
push rbx
sub rsp, 118h
mov rcx, [rsi+8]
mov rax, fs:28h
mov [rsp+148h+var_40], rax
xor eax, eax
lea rax, [rdi+10h]
mov byte ptr... | long long func0(long long a1, long long a2)
{
int v3; // ebp
long long v4; // rcx
unsigned int v5; // ebx
unsigned int v6; // ecx
unsigned int v7; // r15d
long long v8; // rsi
_BYTE *v9; // rsi
unsigned int v10; // eax
unsigned int v11; // edi
long long v12; // rax
long long v13; // r9
long lon... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
MOV R12,RDI
PUSH RBP
MOV EBP,0x1
PUSH RBX
SUB RSP,0x118
MOV RCX,qword ptr [RSI + 0x8]
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x108],RAX
XOR EAX,EAX
LEA RAX,[RDI + 0x10]
MOV byte ptr [RDI + 0x10],0x0
LEA R14,[RSP + 0x10]
MOV qword ptr [RSP + 0x8],RCX
LEA R13,[... | /* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* func0(std::string) */
long * func0(long *param_1,long param_2)
{
int uVar1;
int8 uVar2;
uint uVar3;
long *plVar4;
int iVar5;
uint uVar6;
uint uVar7;
uint uVar8;
uint uVar9;
char cVar10;
uint uVar11;
ulong u... |
1,284 | func0 |
#include <assert.h>
#include <vector>
#include <algorithm>
| std::vector<int> func0(const std::vector<int>& list1) {
int min_val = *min_element(list1.begin(), list1.end());
std::vector<int> min_result;
for (int i = 0; i < list1.size(); ++i) {
if (list1[i] == min_val) {
min_result.push_back(i);
}
}
return min_result;
}
| int main() {
assert((func0({12, 33, 23, 10, 67, 89, 45, 667, 23, 12, 11, 10, 54}) == std::vector<int>{3, 11}));
assert((func0({1, 2, 2, 2, 4, 4, 4, 5, 5, 5, 5}) == std::vector<int>{0}));
assert((func0({2, 1, 5, 6, 8, 3, 4, 9, 10, 11, 8, 12}) == std::vector<int>{1}));
return 0;
}
| O0 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x38,%rsp
mov %rdi,-0x38(%rbp)
mov %rsi,-0x40(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
mov -0x40(%rbp),%rax
mov %rax,%rdi
callq 1b32 <_ZNKSt6vectorIiSaIiEE3endEv>
mov ... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 38h
mov [rbp+var_38], rdi
mov [rbp+var_40], rsi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
mov rax, [rbp+var_40]
mov rdi, rax
call _ZNKSt6vectorIiSaIiEE3endEv; std::vector<int>::end(void)
mo... | long long func0(long long a1, long long a2)
{
long long v2; // rbx
long long v3; // rax
unsigned long long v4; // rbx
int v6; // [rsp+1Ch] [rbp-24h]
_QWORD v7[3]; // [rsp+20h] [rbp-20h] BYREF
v7[1] = __readfsqword(0x28u);
v2 = std::vector<int>::end(a2);
v3 = std::vector<int>::begin(a2);
v7[0] = std:... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x38
MOV qword ptr [RBP + -0x38],RDI
MOV qword ptr [RBP + -0x40],RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
MOV RAX,qword ptr [RBP + -0x40]
MOV RDI,RAX
CALL 0x00101b4e
MOV RBX,RAX
MOV RAX,qword ptr [RBP + -0x40]
MOV RDI,RAX
CALL 0x001... | /* func0(std::vector<int, std::allocator<int> > const&) */
vector * func0(vector *param_1)
{
int iVar1;
__normal_iterator _Var2;
__normal_iterator _Var3;
uint extraout_var;
int *piVar4;
ulong uVar5;
ulong uVar6;
vector<int,std::allocator<int>> *in_RSI;
long in_FS_OFFSET;
int8 local_28;
long loca... |
1,285 | func0 |
#include <assert.h>
#include <vector>
#include <algorithm>
| std::vector<int> func0(const std::vector<int>& list1) {
int min_val = *min_element(list1.begin(), list1.end());
std::vector<int> min_result;
for (int i = 0; i < list1.size(); ++i) {
if (list1[i] == min_val) {
min_result.push_back(i);
}
}
return min_result;
}
| int main() {
assert((func0({12, 33, 23, 10, 67, 89, 45, 667, 23, 12, 11, 10, 54}) == std::vector<int>{3, 11}));
assert((func0({1, 2, 2, 2, 4, 4, 4, 5, 5, 5, 5}) == std::vector<int>{0}));
assert((func0({2, 1, 5, 6, 8, 3, 4, 9, 10, 11, 8, 12}) == std::vector<int>{1}));
return 0;
}
| O1 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %r13
push %r12
push %rbp
push %rbx
sub $0x18,%rsp
mov %rdi,%rbp
mov %rsi,%rbx
mov %fs:0x28,%rax
mov %rax,0x8(%rsp)
xor %eax,%eax
mov 0x8(%rsi),%rcx
mov (%rsi),%rdx
cmp %rcx,%rdx
je 12d0 <_Z5func0RKSt6vectorIiSaIiEE... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 10h
mov r12, rdi
mov rbp, rsi
mov rax, fs:28h
mov [rsp+38h+var_30], rax
xor eax, eax
mov rcx, [rsi+8]
mov rdx, [rsi]
cmp rdx, rcx
jz short loc_12CF
lea rax, [rdx+4]
cmp ... | _QWORD * func0(_QWORD *a1, int **a2)
{
int *v3; // rcx
int *v4; // rdx
int *i; // rax
int v6; // r13d
int *v7; // rdx
unsigned long long v8; // rbx
_DWORD *v9; // rsi
int v11; // [rsp+4h] [rbp-34h] BYREF
unsigned long long v12; // [rsp+8h] [rbp-30h]
v12 = __readfsqword(0x28u);
v3 = a2[1];
v4 = ... | func0:
ENDBR64
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x10
MOV R12,RDI
MOV RBP,RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x8],RAX
XOR EAX,EAX
MOV RCX,qword ptr [RSI + 0x8]
MOV RDX,qword ptr [RSI]
CMP RDX,RCX
JZ 0x001012cf
LEA RAX,[RDX + 0x4]
CMP RCX,RAX
JZ 0x00101295
LAB_00101284:
MOV EDI,dword... | /* func0(std::vector<int, std::allocator<int> > const&) */
vector * func0(vector *param_1)
{
int iVar1;
int *piVar2;
int *piVar3;
int *piVar4;
int *piVar5;
long lVar6;
ulong uVar7;
long *in_RSI;
long in_FS_OFFSET;
int local_34;
long local_30;
local_30 = *(long *)(in_FS_OFFSET + 0x28);
piV... |
1,286 | func0 |
#include <assert.h>
#include <vector>
#include <algorithm>
| std::vector<int> func0(const std::vector<int>& list1) {
int min_val = *min_element(list1.begin(), list1.end());
std::vector<int> min_result;
for (int i = 0; i < list1.size(); ++i) {
if (list1[i] == min_val) {
min_result.push_back(i);
}
}
return min_result;
}
| int main() {
assert((func0({12, 33, 23, 10, 67, 89, 45, 667, 23, 12, 11, 10, 54}) == std::vector<int>{3, 11}));
assert((func0({1, 2, 2, 2, 4, 4, 4, 5, 5, 5, 5}) == std::vector<int>{0}));
assert((func0({2, 1, 5, 6, 8, 3, 4, 9, 10, 11, 8, 12}) == std::vector<int>{1}));
return 0;
}
| O2 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %r13
push %r12
mov %rdi,%r12
push %rbp
mov %rsi,%rbp
push %rbx
sub $0x18,%rsp
mov 0x8(%rsi),%rcx
mov %fs:0x28,%rax
mov %rax,0x8(%rsp)
xor %eax,%eax
mov (%rsi),%rax
mov (%rax),%ebx
cmp %rax,%rcx
jne 16cf <_Z5func0... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push r14
push r13
mov r13, rdi
push r12
mov r12, rsi
push rbp
push rbx
sub rsp, 10h
mov rcx, [rsi+8]
mov rdx, [rsi]
mov rax, fs:28h
mov [rsp+38h+var_30], rax
xor eax, eax
cmp rdx, rcx
jz loc_1730
lea rax, [rdx+4]
mov eb... | long long func0(long long a1, int **a2)
{
int *v3; // rcx
int *v4; // rdx
int *v5; // rax
int v6; // ebp
int v7; // eax
unsigned long long v8; // rbx
int *v9; // rdx
int *v10; // rax
int v11; // r14d
_DWORD *v12; // rsi
int v14; // [rsp+4h] [rbp-34h] BYREF
unsigned long long v15; // [rsp+8h] [r... | func0:
ENDBR64
PUSH R14
PUSH R13
MOV R13,RDI
PUSH R12
MOV R12,RSI
PUSH RBP
PUSH RBX
SUB RSP,0x10
MOV RCX,qword ptr [RSI + 0x8]
MOV RDX,qword ptr [RSI]
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x8],RAX
XOR EAX,EAX
CMP RDX,RCX
JZ 0x00101730
LEA RAX,[RDX + 0x4]
MOV EBP,dword ptr [RDX]
CMP RCX,RAX
JZ 0x001016a8
MOV... | /* func0(std::vector<int, std::allocator<int> > const&) */
vector * func0(vector *param_1)
{
int *piVar1;
int *piVar2;
int *piVar3;
long lVar4;
ulong uVar5;
int iVar6;
long *in_RSI;
long in_FS_OFFSET;
int local_34;
long local_30;
piVar1 = (int *)in_RSI[1];
piVar2 = (int *)*in_RSI;
local_3... |
1,287 | func0 |
#include <assert.h>
#include <vector>
#include <algorithm>
| std::vector<int> func0(const std::vector<int>& list1) {
int min_val = *min_element(list1.begin(), list1.end());
std::vector<int> min_result;
for (int i = 0; i < list1.size(); ++i) {
if (list1[i] == min_val) {
min_result.push_back(i);
}
}
return min_result;
}
| int main() {
assert((func0({12, 33, 23, 10, 67, 89, 45, 667, 23, 12, 11, 10, 54}) == std::vector<int>{3, 11}));
assert((func0({1, 2, 2, 2, 4, 4, 4, 5, 5, 5, 5}) == std::vector<int>{0}));
assert((func0({2, 1, 5, 6, 8, 3, 4, 9, 10, 11, 8, 12}) == std::vector<int>{1}));
return 0;
}
| O3 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %r13
push %r12
mov %rdi,%r12
push %rbp
mov %rsi,%rbp
push %rbx
sub $0x18,%rsp
mov 0x8(%rsi),%rsi
mov %fs:0x28,%rax
mov %rax,0x8(%rsp)
xor %eax,%eax
mov 0x0(%rbp),%rax
mov (%rax),%ebx
cmp %rax,%rsi
je 170a <_Z5fu... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push r14
push r13
mov r13, rsi
push r12
mov r12, rdi
push rbp
push rbx
sub rsp, 10h
mov rdi, [rsi+8]
mov rax, fs:28h
mov [rsp+38h+var_30], rax
xor eax, eax
mov rax, [rsi]
cmp rax, rdi
jz loc_17E0
lea rcx, [rax+4]
mov eb... | long long func0(long long a1, signed int **a2)
{
signed int *v4; // rdi
signed int *v5; // rax
signed int *v6; // rcx
signed int v7; // ebp
unsigned long long v8; // rsi
__m128i v9; // xmm0
signed int *v10; // rdx
__m128i v11; // xmm1
__m128i v12; // xmm3
__m128i v13; // xmm1
__m128i v14; // xmm2... | func0:
ENDBR64
PUSH R14
PUSH R13
MOV R13,RSI
PUSH R12
MOV R12,RDI
PUSH RBP
PUSH RBX
SUB RSP,0x10
MOV RDI,qword ptr [RSI + 0x8]
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x8],RAX
XOR EAX,EAX
MOV RAX,qword ptr [RSI]
CMP RAX,RDI
JZ 0x001017e0
LEA RCX,[RAX + 0x4]
MOV EBP,dword ptr [RAX]
CMP RDI,RCX
JZ 0x00101748
LEA... | /* func0(std::vector<int, std::allocator<int> > const&) */
vector * func0(vector *param_1)
{
uint *puVar1;
uint *puVar2;
uint *puVar3;
int *piVar4;
uint *puVar5;
uint *puVar6;
uint *puVar7;
uint *puVar8;
uint *puVar9;
uint *puVar10;
uint *puVar11;
uint *puVar12;
long lVar13;
ulong uVar14;
... |
1,288 | func0 |
#include <cassert>
#include <vector>
using namespace std;
vector<int> right_rotate(vector<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;
return arr;
}
| vector<int> func0(vector<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)){
arr = right_rotate(arr, n, out... | int main(){
vector<int> result1 = func0(vector<int>{-5, -2, 5, 2, 4, 7, 1, 8, 0, -8}, 10);
vector<int> expected1 = {-5, 5, -2, 2, -8, 4, 7, 1, 8, 0};
assert(result1 == expected1);
vector<int> result2 = func0(vector<int>{1, 2, 3, -4, -1, 4}, 6);
vector<int> expected2 = {-4, 1, -1, 2, 3, 4};
... | O0 | cpp | func0(std::vector<int, std::allocator<int> >, int):
endbr64
push %rbp
mov %rsp,%rbp
sub $0x50,%rsp
mov %rdi,-0x38(%rbp)
mov %rsi,-0x40(%rbp)
mov %edx,-0x44(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x8(%rbp)
xor %eax,%eax
movl $0xffffffff,-0x28(%rbp)
movl $0x0,-0x24(%rbp)
mov -0x24(%rbp),%eax
c... | _Z5func0St6vectorIiSaIiEEi:
endbr64
push rbp
mov rbp, rsp
sub rsp, 50h
mov [rbp+var_38], rdi
mov [rbp+var_40], rsi
mov [rbp+var_44], edx
mov rax, fs:28h
mov [rbp+var_8], rax
xor eax, eax
mov [rbp+var_28], 0FFFFFFFFh
mov [rbp+var_24], 0
jmp loc_14A9
loc_1357:
cmp [rbp+v... | long long func0(long long a1, long long a2, int a3)
{
int v7; // [rsp+28h] [rbp-28h]
int i; // [rsp+2Ch] [rbp-24h]
_BYTE v9[24]; // [rsp+30h] [rbp-20h] BYREF
unsigned long long v10; // [rsp+48h] [rbp-8h]
v10 = __readfsqword(0x28u);
v7 = -1;
for ( i = 0; i < a3; ++i )
{
if ( v7 >= 0
&& (*(int... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x50
MOV qword ptr [RBP + -0x38],RDI
MOV qword ptr [RBP + -0x40],RSI
MOV dword ptr [RBP + -0x44],EDX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
XOR EAX,EAX
MOV dword ptr [RBP + -0x28],0xffffffff
MOV dword ptr [RBP + -0x24],0x0
JMP 0x001014a9
LAB_00101357:
CMP ... | /* func0(std::vector<int, std::allocator<int> >, int) */
vector<int,std::allocator<int>> *
func0(vector<int,std::allocator<int>> *param_1,vector<int,std::allocator<int>> *param_2,int param_3)
{
bool bVar1;
int *piVar2;
long in_FS_OFFSET;
uint local_30;
uint local_2c;
vector local_28 [24];
long local_10;... |
1,289 | func0 |
#include <cassert>
#include <vector>
using namespace std;
vector<int> right_rotate(vector<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;
return arr;
}
| vector<int> func0(vector<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)){
arr = right_rotate(arr, n, out... | int main(){
vector<int> result1 = func0(vector<int>{-5, -2, 5, 2, 4, 7, 1, 8, 0, -8}, 10);
vector<int> expected1 = {-5, 5, -2, 2, -8, 4, 7, 1, 8, 0};
assert(result1 == expected1);
vector<int> result2 = func0(vector<int>{1, 2, 3, -4, -1, 4}, 6);
vector<int> expected2 = {-4, 1, -1, 2, 3, 4};
... | O1 | cpp | func0(std::vector<int, std::allocator<int> >, int):
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x38,%rsp
mov %rdi,%r15
mov %rsi,%rbp
mov %edx,0xc(%rsp)
mov %fs:0x28,%rcx
mov %rcx,0x28(%rsp)
xor %ecx,%ecx
test %edx,%edx
jle 149a <_Z5func0St6vectorIiSaIi... | _Z5func0St6vectorIiSaIiEEi:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 38h
mov r15, rdi
mov rbp, rsi
mov [rsp+68h+var_5C], edx
mov rax, fs:28h
mov [rsp+68h+var_40], rax
xor eax, eax
test edx, edx
jle loc_146C
movsxd r14, edx
mov ebx, ... | int ** func0(int **a1, int **a2, int a3)
{
long long v5; // r14
long long v6; // rbx
int v7; // r12d
int *v8; // rax
int *v9; // rdi
int *v10; // rsi
int v11; // eax
_QWORD v14[11]; // [rsp+10h] [rbp-58h] BYREF
v14[3] = __readfsqword(0x28u);
if ( a3 > 0 )
{
v5 = a3;
v6 = 0LL;
v7 = -1;... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x38
MOV R15,RDI
MOV RBP,RSI
MOV dword ptr [RSP + 0xc],EDX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x28],RAX
XOR EAX,EAX
TEST EDX,EDX
JLE 0x0010146c
MOVSXD R14,EDX
MOV EBX,0x0
MOV R12D,0xffffffff
JMP 0x001013d4
LAB_0010139a:
MOVSXD RD... | /* func0(std::vector<int, std::allocator<int> >, int) */
long * func0(long *param_1,long *param_2,int param_3)
{
long lVar1;
void *pvVar2;
uint uVar3;
ulong uVar4;
int iVar5;
ulong uVar6;
long in_FS_OFFSET;
long local_58;
long local_50;
long local_48;
long local_40;
local_40 = *(long *)(in_... |
1,290 | func0 |
#include <cassert>
#include <vector>
using namespace std;
vector<int> right_rotate(vector<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;
return arr;
}
| vector<int> func0(vector<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)){
arr = right_rotate(arr, n, out... | int main(){
vector<int> result1 = func0(vector<int>{-5, -2, 5, 2, 4, 7, 1, 8, 0, -8}, 10);
vector<int> expected1 = {-5, 5, -2, 2, -8, 4, 7, 1, 8, 0};
assert(result1 == expected1);
vector<int> result2 = func0(vector<int>{1, 2, 3, -4, -1, 4}, 6);
vector<int> expected2 = {-4, 1, -1, 2, 3, 4};
... | O2 | cpp | func0(std::vector<int, std::allocator<int> >, int):
endbr64
push %r15
mov %rsi,%r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x48,%rsp
mov %rdi,0x10(%rsp)
mov %fs:0x28,%rax
mov %rax,0x38(%rsp)
xor %eax,%eax
mov (%rsi),%rax
test %edx,%edx
jle 19a0 <_Z5func0St6vectorIiS... | _Z5func0St6vectorIiSaIiEEi:
endbr64
push r15
push r14
push r13
push r12
push rbp
mov rbp, rsi
push rbx
sub rsp, 48h
mov [rsp+78h+var_68], rdi
mov [rsp+78h+var_6C], edx
mov rax, fs:28h
mov [rsp+78h+var_40], rax
mov rax, [rsi]
test edx, edx
jle short loc_1840
lea r... | __m128 * func0(__m128 *a1, long long a2, int a3)
{
_DWORD *v4; // rax
long long v5; // r14
unsigned int j; // r15d
long long i; // rbx
long long v8; // r13
unsigned long long v9; // rax
__m128 v10; // xmm0
unsigned int v12; // r12d
int v13; // edx
__m128i v14; // xmm0
long long v15; // rax
_DWOR... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
MOV RBP,RSI
PUSH RBX
SUB RSP,0x48
MOV qword ptr [RSP + 0x10],RDI
MOV dword ptr [RSP + 0xc],EDX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x38],RAX
MOV RAX,qword ptr [RSI]
TEST EDX,EDX
JLE 0x00101840
LEA RCX,[RSP + 0x20]
MOVSXD R14,EDX
XOR R15D,R15D
XOR ... | /* func0(std::vector<int, std::allocator<int> >, int) */
long * func0(long *param_1,int (*param_2) [16],int param_3)
{
int iVar1;
void *pvVar2;
long lVar3;
uint uVar4;
long lVar5;
uint uVar6;
long lVar7;
uint uVar8;
long lVar9;
long in_FS_OFFSET;
long local_58;
int8 uStack_50;
int8 local_48;... |
1,291 | func0 |
#include <cassert>
#include <vector>
using namespace std;
vector<int> right_rotate(vector<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;
return arr;
}
| vector<int> func0(vector<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)){
arr = right_rotate(arr, n, out... | int main(){
vector<int> result1 = func0(vector<int>{-5, -2, 5, 2, 4, 7, 1, 8, 0, -8}, 10);
vector<int> expected1 = {-5, 5, -2, 2, -8, 4, 7, 1, 8, 0};
assert(result1 == expected1);
vector<int> result2 = func0(vector<int>{1, 2, 3, -4, -1, 4}, 6);
vector<int> expected2 = {-4, 1, -1, 2, 3, 4};
... | O3 | cpp | func0(std::vector<int, std::allocator<int> >, int):
endbr64
push %r15
mov %rsi,%r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x38,%rsp
mov (%rsi),%rcx
mov %rdi,(%rsp)
mov %fs:0x28,%rax
mov %rax,0x28(%rsp)
xor %eax,%eax
test %edx,%edx
jle 1950 <_Z5func0St6vectorIiSaIiE... | _Z5func0St6vectorIiSaIiEEi:
endbr64
push r15
push r14
push r13
push r12
push rbp
mov rbp, rsi
push rbx
sub rsp, 48h
mov [rsp+78h+var_68], rdi
mov [rsp+78h+var_6C], edx
mov rax, fs:28h
mov [rsp+78h+var_40], rax
mov rax, [rsi]
test edx, edx
jle short loc_1850
lea r... | __m128 * func0(__m128 *a1, long long a2, int a3)
{
_DWORD *v4; // rax
long long v5; // r14
unsigned int v6; // r15d
long long i; // rbx
long long v8; // r13
unsigned long long v9; // rax
__m128 v10; // xmm0
unsigned int v12; // r12d
int v13; // edx
__m128i v14; // xmm0
long long v15; // rax
_DWO... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
MOV RBP,RSI
PUSH RBX
SUB RSP,0x48
MOV qword ptr [RSP + 0x10],RDI
MOV dword ptr [RSP + 0xc],EDX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x38],RAX
MOV RAX,qword ptr [RSI]
TEST EDX,EDX
JLE 0x00101850
LEA RCX,[RSP + 0x20]
MOVSXD R14,EDX
XOR R15D,R15D
XOR ... | /* func0(std::vector<int, std::allocator<int> >, int) */
long * func0(long *param_1,int (*param_2) [16],int param_3)
{
int iVar1;
void *pvVar2;
long lVar3;
uint uVar4;
long lVar5;
uint uVar6;
long lVar7;
uint uVar8;
long lVar9;
long in_FS_OFFSET;
long local_58;
int8 uStack_50;
int8 local_48;... |
1,292 | func0 |
#include <tuple>
#include <vector>
#include <cassert>
| std::tuple<int, int> func0(const std::vector<int>& test_vector) {
int sum1 = 0;
int sum2 = 0;
for (int idx = 0; idx < test_vector.size(); ++idx) {
if (idx % 2) {
sum1 += test_vector[idx];
} else {
sum2 += test_vector[idx];
}
}
return std::mak... | int main() {
assert(func0({5, 6, 3, 6, 10, 34}) == std::make_tuple(46, 18));
assert(func0({1, 2, 3, 4, 5}) == std::make_tuple(6, 9));
assert(func0({6, 7, 8, 9, 4, 5}) == std::make_tuple(21, 18));
return 0;
}
| O0 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x38,%rsp
mov %rdi,-0x38(%rbp)
mov %rsi,-0x40(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
movl $0x0,-0x24(%rbp)
movl $0x0,-0x20(%rbp)
movl $0x0,-0x1c(%rbp)
mov -0x1c(%rbp... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 38h
mov [rbp+var_38], rdi
mov [rbp+var_40], rsi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
mov [rbp+var_24], 0
mov [rbp+var_20], 0
mov [rbp+var_1C], 0
jmp short loc_12D2
loc_1284:
mov ... | long long func0(long long a1, long long a2)
{
int v3; // [rsp+1Ch] [rbp-24h] BYREF
int v4; // [rsp+20h] [rbp-20h] BYREF
int i; // [rsp+24h] [rbp-1Ch]
unsigned long long v6; // [rsp+28h] [rbp-18h]
v6 = __readfsqword(0x28u);
v3 = 0;
v4 = 0;
for ( i = 0; i < (unsigned long long)std::vector<int>::size(a2)... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x38
MOV qword ptr [RBP + -0x38],RDI
MOV qword ptr [RBP + -0x40],RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
MOV dword ptr [RBP + -0x24],0x0
MOV dword ptr [RBP + -0x20],0x0
MOV dword ptr [RBP + -0x1c],0x0
JMP 0x001012d2
LAB_00101284:
M... | /* func0(std::vector<int, std::allocator<int> > const&) */
vector * func0(vector *param_1)
{
int *piVar1;
ulong uVar2;
ulong uVar3;
vector<int,std::allocator<int>> *in_RSI;
long in_FS_OFFSET;
int local_2c;
int local_28;
uint local_24;
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
... |
1,293 | func0 |
#include <tuple>
#include <vector>
#include <cassert>
| std::tuple<int, int> func0(const std::vector<int>& test_vector) {
int sum1 = 0;
int sum2 = 0;
for (int idx = 0; idx < test_vector.size(); ++idx) {
if (idx % 2) {
sum1 += test_vector[idx];
} else {
sum2 += test_vector[idx];
}
}
return std::mak... | int main() {
assert(func0({5, 6, 3, 6, 10, 34}) == std::make_tuple(46, 18));
assert(func0({1, 2, 3, 4, 5}) == std::make_tuple(6, 9));
assert(func0({6, 7, 8, 9, 4, 5}) == std::make_tuple(21, 18));
return 0;
}
| O1 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
mov %rdi,%rax
mov (%rsi),%rcx
mov 0x8(%rsi),%rdx
sub %rcx,%rdx
sar $0x2,%rdx
mov %rdx,%r9
je 124c <_Z5func0RKSt6vectorIiSaIiEE+0x43>
mov $0x0,%r8d
mov $0x0,%esi
mov $0x0,%edx
jmp 1242 <_Z5func0RKSt6vectorIiSaIiEE+0x39>
add ... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
mov rax, rdi
mov rdx, [rsi+8]
mov rcx, [rsi]
mov rsi, rdx
sub rsi, rcx
sar rsi, 2
cmp rdx, rcx
jz short loc_1251
mov r9d, 0
mov r8d, 0
mov edx, 0
jmp short loc_1246
loc_1239:
add r9d, [rcx+rdx*4]
loc_123D:
add rdx, 1
cmp r... | _DWORD * func0(_DWORD *a1, long long *a2)
{
_DWORD *result; // rax
long long v3; // rdx
long long v4; // rcx
unsigned long long v5; // rsi
int v6; // r9d
int v7; // r8d
unsigned long long v8; // rdx
result = a1;
v3 = a2[1];
v4 = *a2;
v5 = (v3 - *a2) >> 2;
if ( v3 == v4 )
{
v6 = 0;
v7 ... | func0:
ENDBR64
MOV RAX,RDI
MOV RDX,qword ptr [RSI + 0x8]
MOV RCX,qword ptr [RSI]
MOV RSI,RDX
SUB RSI,RCX
SAR RSI,0x2
CMP RDX,RCX
JZ 0x00101251
MOV R9D,0x0
MOV R8D,0x0
MOV EDX,0x0
JMP 0x00101246
LAB_00101239:
ADD R9D,dword ptr [RCX + RDX*0x4]
LAB_0010123d:
ADD RDX,0x1
CMP RDX,RSI
JNC 0x0010125d
LAB_00101246:
TEST DL,0x1... | /* func0(std::vector<int, std::allocator<int> > const&) */
void func0(vector *param_1)
{
long lVar1;
ulong uVar2;
long *in_RSI;
int iVar3;
int iVar4;
lVar1 = *in_RSI;
if (in_RSI[1] == lVar1) {
iVar4 = 0;
iVar3 = 0;
}
else {
iVar4 = 0;
iVar3 = 0;
uVar2 = 0;
do {
if ((... |
1,294 | func0 |
#include <tuple>
#include <vector>
#include <cassert>
| std::tuple<int, int> func0(const std::vector<int>& test_vector) {
int sum1 = 0;
int sum2 = 0;
for (int idx = 0; idx < test_vector.size(); ++idx) {
if (idx % 2) {
sum1 += test_vector[idx];
} else {
sum2 += test_vector[idx];
}
}
return std::mak... | int main() {
assert(func0({5, 6, 3, 6, 10, 34}) == std::make_tuple(46, 18));
assert(func0({1, 2, 3, 4, 5}) == std::make_tuple(6, 9));
assert(func0({6, 7, 8, 9, 4, 5}) == std::make_tuple(21, 18));
return 0;
}
| O2 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
mov (%rsi),%r8
mov 0x8(%rsi),%rsi
xor %r10d,%r10d
xor %r9d,%r9d
mov %rdi,%rax
sub %r8,%rsi
sar $0x2,%rsi
je 1439 <_Z5func0RKSt6vectorIiSaIiEE+0x49>
xor %edx,%edx
jmp 1424 <_Z5func0RKSt6vectorIiSaIiEE+0x34>
nopl 0x0(%rax)
add ... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
mov rdx, [rsi+8]
mov rsi, [rsi]
mov rax, rdi
xor r10d, r10d
xor r9d, r9d
mov r8, rdx
sub r8, rsi
sar r8, 2
cmp rdx, rsi
jz short loc_1400
xor edx, edx
jmp short loc_13EC
loc_13E0:
add rdx, 1
add r9d, ecx
cmp rdx, r8
jnb ... | _DWORD * func0(_DWORD *a1, long long *a2)
{
long long v2; // rdx
long long v3; // rsi
_DWORD *result; // rax
int v5; // r10d
int v6; // r9d
unsigned long long v7; // r8
unsigned long long v8; // rdx
int v9; // ecx
v2 = a2[1];
v3 = *a2;
result = a1;
v5 = 0;
v6 = 0;
v7 = (v2 - v3) >> 2;
if ... | func0:
ENDBR64
MOV RDX,qword ptr [RSI + 0x8]
MOV RSI,qword ptr [RSI]
MOV RAX,RDI
XOR R10D,R10D
XOR R9D,R9D
MOV R8,RDX
SUB R8,RSI
SAR R8,0x2
CMP RDX,RSI
JZ 0x00101400
XOR EDX,EDX
JMP 0x001013ec
LAB_001013e0:
ADD RDX,0x1
ADD R9D,ECX
CMP RDX,R8
JNC 0x00101400
LAB_001013ec:
MOV ECX,dword ptr [RSI + RDX*0x4]
TEST DL,0x1
JNZ... | /* func0(std::vector<int, std::allocator<int> > const&) */
void func0(vector *param_1)
{
int iVar1;
long lVar2;
ulong uVar3;
long *in_RSI;
ulong uVar4;
int iVar5;
int iVar6;
lVar2 = *in_RSI;
iVar6 = 0;
iVar5 = 0;
uVar4 = in_RSI[1] - lVar2 >> 2;
if (in_RSI[1] != lVar2) {
uVar3 = 0;
d... |
1,295 | func0 |
#include <tuple>
#include <vector>
#include <cassert>
| std::tuple<int, int> func0(const std::vector<int>& test_vector) {
int sum1 = 0;
int sum2 = 0;
for (int idx = 0; idx < test_vector.size(); ++idx) {
if (idx % 2) {
sum1 += test_vector[idx];
} else {
sum2 += test_vector[idx];
}
}
return std::mak... | int main() {
assert(func0({5, 6, 3, 6, 10, 34}) == std::make_tuple(46, 18));
assert(func0({1, 2, 3, 4, 5}) == std::make_tuple(6, 9));
assert(func0({6, 7, 8, 9, 4, 5}) == std::make_tuple(21, 18));
return 0;
}
| O3 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
mov (%rsi),%r9
mov 0x8(%rsi),%rsi
mov %rdi,%rax
sub %r9,%rsi
sar $0x2,%rsi
je 1520 <_Z5func0RKSt6vectorIiSaIiEE+0x150>
lea -0x1(%rsi),%rdx
cmp $0x4,%rdx
jbe 152a <_Z5func0RKSt6vectorIiSaIiEE+0x15a>
mov %rsi,%rcx
pxor %xmm2,%x... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
mov rdx, [rsi+8]
mov rcx, [rsi]
mov rax, rdx
sub rax, rcx
mov r8, rax
sar r8, 2
cmp rdx, rcx
jz loc_14F8
test rax, rax
mov esi, 1
cmovnz rsi, r8
cmp rax, 10h
jbe loc_150D
mov rdx, rsi
pxor xmm1, xmm1
movdqa xmm3, cs:xmmword_21... | _DWORD * func0(_DWORD *a1, long long a2)
{
unsigned int *v2; // rcx
long long v3; // rax
unsigned long long v4; // r8
unsigned long long v5; // rsi
__m128i v6; // xmm1
__m128i si128; // xmm3
__m128i v8; // xmm7
__m128i v9; // xmm2
const __m128i *v10; // rax
__m128i v11; // xmm6
__m128i v12; // xmm... | func0:
ENDBR64
MOV RDX,qword ptr [RSI + 0x8]
MOV RCX,qword ptr [RSI]
MOV RAX,RDX
SUB RAX,RCX
MOV R8,RAX
SAR R8,0x2
CMP RDX,RCX
JZ 0x001014f8
TEST RAX,RAX
MOV ESI,0x1
CMOVNZ RSI,R8
CMP RAX,0x10
JBE 0x0010150d
MOV RDX,RSI
PXOR XMM1,XMM1
MOVDQA XMM3,xmmword ptr [0x00102110]
MOVDQA XMM7,xmmword ptr [0x00102120]
SHR RDX,0x2... | /* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* func0(std::vector<int, std::allocator<int> > const&) */
vector * func0(vector *param_1)
{
uint *puVar1;
uint uVar2;
ulong uVar3;
uint *puVar4;
uint *puVar5;
int8 *in_RSI;
ulong uVar6;
ulong uVar7;
uint uVar8;
u... |
1,296 | func0 |
#include <iostream>
#include <climits>
#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 = std::min(res, 1 + func0(n - temp));
}
}
return res;
}
| int main() {
assert(func0(6) == 3);
assert(func0(2) == 2);
assert(func0(4) == 1);
return 0;
}
| O0 | cpp | func0(int):
endbr64
push %rbp
mov %rsp,%rbp
sub $0x30,%rsp
mov %edi,-0x24(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x8(%rbp)
xor %eax,%eax
cmpl $0x3,-0x24(%rbp)
jg 11d2 <_Z5func0i+0x29>
mov -0x24(%rbp),%eax
jmp 122d <_Z5func0i+0x84>
mov -0x24(%rbp),%eax
mov %eax,-0x18(%rbp)
movl $0x1,-0... | _Z5func0i:
endbr64
push rbp
mov rbp, rsp
sub rsp, 30h
mov [rbp+var_24], edi
mov rax, fs:28h
mov [rbp+var_8], rax
xor eax, eax
cmp [rbp+var_24], 3
jg short loc_1192
mov eax, [rbp+var_24]
jmp short loc_11EF
loc_1192:
mov eax, [rbp+var_24]
mov [rbp+var_18], eax
mov [... | long long func0(int a1)
{
unsigned int v2; // [rsp+18h] [rbp-18h] BYREF
int v3; // [rsp+1Ch] [rbp-14h] BYREF
int i; // [rsp+20h] [rbp-10h]
int v5; // [rsp+24h] [rbp-Ch]
unsigned long long v6; // [rsp+28h] [rbp-8h]
v6 = __readfsqword(0x28u);
if ( a1 <= 3 )
return (unsigned int)a1;
v2 = a1;
for ( ... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x30
MOV dword ptr [RBP + -0x24],EDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
XOR EAX,EAX
CMP dword ptr [RBP + -0x24],0x3
JG 0x00101192
MOV EAX,dword ptr [RBP + -0x24]
JMP 0x001011ef
LAB_00101192:
MOV EAX,dword ptr [RBP + -0x24]
MOV dword ptr [RBP + -0x18],E... | /* func0(int) */
int func0(int param_1)
{
int iVar1;
int *piVar2;
long in_FS_OFFSET;
int local_20;
int local_1c;
int local_18;
int local_14;
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
iVar1 = param_1;
if (3 < param_1) {
local_20 = param_1;
for (local_18 = 1;
(iV... |
1,297 | func0 |
#include <iostream>
#include <climits>
#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 = std::min(res, 1 + func0(n - temp));
}
}
return res;
}
| int main() {
assert(func0(6) == 3);
assert(func0(2) == 2);
assert(func0(4) == 1);
return 0;
}
| O1 | cpp | func0(int):
endbr64
push %r12
push %rbp
push %rbx
mov %edi,%ebp
cmp $0x3,%edi
jle 11d5 <_Z5func0i+0x4c>
mov %edi,%ebx
lea -0x1(%rdi),%edi
callq 1189 <_Z5func0i>
lea 0x1(%rax),%ebp
cmp %ebx,%ebp
cmovg %ebx,%ebp
mov $0x2,%r12d
mov %r12d,%eax
imul %r12d,%eax
cmp %eax,%ebx
jl 11d... | _Z5func0i:
endbr64
push r12
push rbp
push rbx
mov r12d, edi
cmp edi, 3
jle short loc_1188
mov ebx, edi
mov eax, 1
mov ebp, 1
loc_1165:
mov edi, ebx
sub edi, eax; int
call _Z5func0i; func0(int)
add eax, 1
cmp r12d, eax
cmovg r12d, eax
add ebp, 1
cmp ebx, ebp
... | 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(a1 - v2) + 1;
if ( v1 > v4 )
v1 = v4;
if ( a1 < ++v3 )
break;
v2 = v3 * v3;
}
while ( a1 >= v3 *... | func0:
ENDBR64
PUSH R12
PUSH RBP
PUSH RBX
MOV R12D,EDI
CMP EDI,0x3
JLE 0x00101188
MOV EBX,EDI
MOV EAX,0x1
MOV EBP,0x1
LAB_00101165:
MOV EDI,EBX
SUB EDI,EAX
CALL 0x00101149
ADD EAX,0x1
CMP R12D,EAX
CMOVG R12D,EAX
ADD EBP,0x1
CMP EBX,EBP
JL 0x00101188
MOV EAX,EBP
IMUL EAX,EBP
CMP EBX,EAX
JGE 0x00101165
LAB_00101188:
MOV ... | /* func0(int) */
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 + 1 < iVar3) {
iVar3 = iVar1 + 1;
}
iVar2 = iVar2 + 1;
} while ((iVar2 <= par... |
1,298 | func0 |
#include <iostream>
#include <climits>
#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 = std::min(res, 1 + func0(n - temp));
}
}
return res;
}
| int main() {
assert(func0(6) == 3);
assert(func0(2) == 2);
assert(func0(4) == 1);
return 0;
}
| O2 | cpp | func0(int):
endbr64
cmp $0x3,%edi
jle 1250 <_Z5func0i+0x10>
jmp 1260 <_Z5func0i.part.0>
nopl 0x0(%rax,%rax,1)
mov %edi,%eax
retq
data16 nopw %cs:0x0(%rax,%rax,1)
xchg %ax,%ax
| _Z5func0i_part_0:
push r12
mov eax, 1
mov r12d, edi
push rbp
mov ebp, edi
push rbx
mov ebx, 1
test edi, edi
jle short loc_1202
loc_11D7:
mov edi, r12d
sub edi, eax
cmp edi, 3
jle short loc_11E8
call _Z5func0i_part_0; func0(int) [clone]
mov edi, eax
loc_11E8:
add ... | long long func0(int a1)
{
int v1; // eax
int v3; // ebp
int v4; // ebx
int v5; // edi
int v6; // edi
v1 = 1;
v3 = a1;
v4 = 1;
if ( a1 > 0 )
{
do
{
v5 = a1 - v1;
if ( a1 - v1 > 3 )
v5 = func0();
v6 = v5 + 1;
if ( v3 > v6 )
v3 = v6;
if ( a1 < ++v... | func0:
PUSH R12
MOV EAX,0x1
MOV R12D,EDI
PUSH RBP
MOV EBP,EDI
PUSH RBX
MOV EBX,0x1
TEST EDI,EDI
JLE 0x00101202
LAB_001011d7:
MOV EDI,R12D
SUB EDI,EAX
CMP EDI,0x3
JLE 0x001011e8
CALL 0x001011c0
MOV EDI,EAX
LAB_001011e8:
ADD EDI,0x1
CMP EBP,EDI
CMOVG EBP,EDI
ADD EBX,0x1
CMP R12D,EBX
JL 0x00101202
MOV EAX,EBX
IMUL EAX,EBX... | /* func0(int) [clone .part.0] */
int func0(int param_1)
{
int iVar1;
int iVar2;
int iVar3;
iVar3 = 1;
iVar1 = 1;
iVar2 = param_1;
if (0 < param_1) {
do {
iVar3 = param_1 - iVar3;
if (3 < iVar3) {
iVar3 = func0(iVar3);
}
if (iVar3 + 1 < iVar2) {
iVar2 = iVar... |
1,299 | func0 |
#include <iostream>
#include <climits>
#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 = std::min(res, 1 + func0(n - temp));
}
}
return res;
}
| int main() {
assert(func0(6) == 3);
assert(func0(2) == 2);
assert(func0(4) == 1);
return 0;
}
| O3 | cpp | func0(int) [clone .part.0]:
push %r12
mov %edi,%r12d
push %rbp
mov %edi,%ebp
push %rbx
test %edi,%edi
jle 1281 <_Z5func0i.part.0+0x41>
mov $0x1,%eax
mov $0x1,%ebx
mov %ebp,%edi
sub %eax,%edi
cmp $0x3,%edi
jle 1267 <_Z5func0i.part.0+0x27>
callq 1240 <_Z5func0i.part.0>
mov %eax,%edi... | _Z5func0i_part_0:
push r15
push r14
mov r14d, edi
push r13
push r12
push rbp
push rbx
sub rsp, 38h
test edi, edi
jle loc_1368
mov ebx, 1
mov eax, 1
mov r15d, edi
mov r12d, edi
mov ebp, ebx
loc_11EB:
mov ecx, r12d
sub ecx, eax
mov ebx, ecx
cmp ecx, 3
j... | long long func0(int a1)
{
unsigned int v1; // r14d
int v2; // eax
int v3; // r15d
int v5; // ebp
int v6; // ecx
int v7; // ebx
int v8; // eax
int v9; // r14d
int v10; // r13d
int v11; // esi
int v12; // r8d
int v13; // edx
int v14; // r15d
int v15; // eax
int v16; // ebp
int v17; // r11... | func0:
PUSH R15
PUSH R14
MOV R14D,EDI
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x38
TEST EDI,EDI
JLE 0x00101368
MOV EBX,0x1
MOV EAX,0x1
MOV R15D,EDI
MOV R12D,EDI
MOV EBP,EBX
LAB_001011eb:
MOV ECX,R12D
SUB ECX,EAX
MOV EBX,ECX
CMP ECX,0x3
JLE 0x00101345
MOV EAX,0x1
MOV R14D,0x1
MOV R13D,EBP
MOV ESI,ECX
MOV R8D,R15D
LA... | /* func0(int) [clone .part.0] */
int func0(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;
iVar14 = param_1;
if (0 < param_1) {
iVar1 = 1;
... |
1,300 | func0 | #include <cassert>
#include <string>
#include <vector>
#include <sstream>
#include <unordered_map>
using namespace std;
| string func0(const vector<string>& test_list) {
unordered_map<string, int> freq;
// To preserve the order of first occurrence
vector<string> order;
for (const auto &sub : test_list) {
istringstream iss(sub);
string word;
while (iss >> word) {
if (freq.fi... | int main() {
vector<string> test1 = {"UTS is best for RTF", "RTF love UTS", "UTS is best"};
vector<string> test2 = {"Its been a great year", "this year is so worse", "this year is okay"};
vector<string> test3 = {"Families can be reunited", "people can be reunited", "Tasks can be achieved "};
asser... | O0 | cpp | func0(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&):
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x278,%rsp
mov %rdi,-0x278(%rbp)
mov %rsi,-0x280(%... | _Z5func0RKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 278h
mov [rbp+var_278], rdi
mov [rbp+var_280], rsi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
lea rax, [rbp+var_200]
mov rdi, rax
call _Z... | long long func0(long long a1, long long a2)
{
_DWORD *v2; // rax
_QWORD *v3; // rax
int v5; // [rsp+1Ch] [rbp-264h]
long long v6; // [rsp+20h] [rbp-260h] BYREF
long long v7; // [rsp+28h] [rbp-258h] BYREF
long long v8; // [rsp+30h] [rbp-250h] BYREF
_QWORD v9[2]; // [rsp+38h] [rbp-248h] BYREF
_BYTE *v10;... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x278
MOV qword ptr [RBP + -0x278],RDI
MOV qword ptr [RBP + -0x280],RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
LEA RAX,[RBP + -0x200]
MOV RDI,RAX
CALL 0x001030f0
LEA RAX,[RBP + -0x220]
MOV RDI,RAX
CALL 0x00103178
MOV RAX,qword ptr [RB... | /* func0(std::vector<std::string, std::allocator<std::string > > const&) */
vector * func0(vector *param_1)
{
char cVar1;
bool bVar2;
int4 *puVar3;
istream *piVar4;
int *piVar5;
vector<std::string,std::allocator<std::string>> *in_RSI;
long in_FS_OFFSET;
int local_26c;
int8 local_268;
int8 local_26... |
1,301 | func0 | #include <cassert>
#include <string>
#include <vector>
#include <sstream>
#include <unordered_map>
using namespace std;
| string func0(const vector<string>& test_list) {
unordered_map<string, int> freq;
// To preserve the order of first occurrence
vector<string> order;
for (const auto &sub : test_list) {
istringstream iss(sub);
string word;
while (iss >> word) {
if (freq.fi... | int main() {
vector<string> test1 = {"UTS is best for RTF", "RTF love UTS", "UTS is best"};
vector<string> test2 = {"Its been a great year", "this year is so worse", "this year is okay"};
vector<string> test3 = {"Families can be reunited", "people can be reunited", "Tasks can be achieved "};
asser... | O1 | cpp | func0(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&):
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x228,%rsp
mov %rdi,0x... | _Z5func0RKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 228h
mov [rsp+258h+var_250], rdi
mov rax, fs:28h
mov [rsp+258h+var_40], rax
xor eax, eax
lea rax, [rsp+258h+var_1F8]
mov ... | long long func0(long long a1, long long **a2)
{
long long *v2; // r13
long long v3; // rdx
long long v4; // rsi
long long **v5; // rbx
unsigned long long v6; // rax
_QWORD *v7; // rax
_DWORD *v8; // rax
char *v9; // rbx
_QWORD *v10; // rax
size_t v11; // rbp
void *v12; // r12
void **v13; // r15... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x228
MOV qword ptr [RSP + 0x8],RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x218],RAX
XOR EAX,EAX
LEA RAX,[RSP + 0x60]
MOV qword ptr [RSP + 0x30],RAX
MOV qword ptr [RSP + 0x38],0x1
MOV qword ptr [RSP + 0x40],0x0
MOV qword ptr [RSP + ... | /* func0(std::vector<std::string, std::allocator<std::string > > const&) */
vector * func0(vector *param_1)
{
int8 *puVar1;
char *pcVar2;
string *psVar3;
string *psVar4;
int8 *puVar5;
int8 uVar6;
size_t __n;
int iVar7;
int8 uVar8;
ulong uVar9;
long *plVar10;
int *piVar11;
int4 *puVar12;
is... |
1,302 | func0 | #include <cassert>
#include <string>
#include <vector>
#include <sstream>
#include <unordered_map>
using namespace std;
| string func0(const vector<string>& test_list) {
unordered_map<string, int> freq;
// To preserve the order of first occurrence
vector<string> order;
for (const auto &sub : test_list) {
istringstream iss(sub);
string word;
while (iss >> word) {
if (freq.fi... | int main() {
vector<string> test1 = {"UTS is best for RTF", "RTF love UTS", "UTS is best"};
vector<string> test2 = {"Its been a great year", "this year is so worse", "this year is okay"};
vector<string> test3 = {"Families can be reunited", "people can be reunited", "Tasks can be achieved "};
asser... | O2 | cpp | func0(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&):
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x258,%rsp
mov 0x8(%rs... | _Z5func0RKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE:
endbr64
push r15
pxor xmm0, xmm0
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 268h
mov rcx, [rsi+8]
mov [rsp+298h+var_260], rdi
mov rax, fs:28h
mov [rsp+298h+var_40], rax
xor eax, eax
... | long long func0(long long a1, long long *a2)
{
long long v2; // rcx
long long v3; // rax
_BYTE *v4; // rbp
char *v5; // rbx
_QWORD *v6; // rax
_QWORD *v7; // rax
long long **v8; // r12
size_t v9; // r13
void *v10; // rbx
_DWORD *v11; // rax
char *v12; // r13
size_t v13; // rdx
void *v14; // r... | func0:
ENDBR64
PUSH R15
PXOR XMM0,XMM0
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x268
MOV RCX,qword ptr [RSI + 0x8]
MOV qword ptr [RSP + 0x38],RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x258],RAX
XOR EAX,EAX
LEA RAX,[RSP + 0xa0]
MOV qword ptr [RSP + 0x30],RCX
MOV qword ptr [RSP + 0x70],RAX
MOV RA... | /* func0(std::vector<std::string, std::allocator<std::string > > const&) */
vector * func0(vector *param_1)
{
int8 *puVar1;
int *__src;
int8 *puVar2;
int8 uVar3;
int8 uVar4;
char *__s1;
size_t __n;
int iVar5;
istream *piVar6;
int *piVar7;
int4 *puVar8;
ulong uVar9;
long *plVar10;
string *p... |
1,303 | func0 | #include <cassert>
#include <string>
#include <vector>
#include <sstream>
#include <unordered_map>
using namespace std;
| string func0(const vector<string>& test_list) {
unordered_map<string, int> freq;
// To preserve the order of first occurrence
vector<string> order;
for (const auto &sub : test_list) {
istringstream iss(sub);
string word;
while (iss >> word) {
if (freq.fi... | int main() {
vector<string> test1 = {"UTS is best for RTF", "RTF love UTS", "UTS is best"};
vector<string> test2 = {"Its been a great year", "this year is so worse", "this year is okay"};
vector<string> test3 = {"Families can be reunited", "people can be reunited", "Tasks can be achieved "};
asser... | O3 | cpp | func0(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&):
endbr64
push %r15
pxor %xmm0,%xmm0
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x288,... | _Z5func0RKSt6vectorINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EE:
endbr64
push r15
pxor xmm0, xmm0
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 278h
mov [rsp+2A8h+var_268], rdi
mov rdi, [rsi+8]
mov rax, fs:28h
mov [rsp+2A8h+var_40], rax
xor eax, eax
... | long long func0(long long a1, long long *a2)
{
long long v2; // rdi
long long v3; // rax
int **v4; // r14
_BYTE *v5; // rbp
char *v6; // rbx
_QWORD *v7; // rax
void **p_s1; // rbp
_QWORD *v9; // rax
void *v10; // rbx
size_t v11; // r12
void *v12; // r13
_DWORD *v13; // rax
unsigned long long ... | func0:
ENDBR64
PUSH R15
PXOR XMM0,XMM0
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x278
MOV qword ptr [RSP + 0x40],RDI
MOV RDI,qword ptr [RSI + 0x8]
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x268],RAX
XOR EAX,EAX
LEA RAX,[RSP + 0xb0]
MOV qword ptr [RSP + 0x38],RDI
MOV qword ptr [RSP + 0x48],RAX
MOV qw... | /* func0(std::vector<std::string, std::allocator<std::string > > const&) */
vector * func0(vector *param_1)
{
int8 *puVar1;
int *puVar2;
ulong uVar3;
long *plVar4;
int8 uVar5;
int8 uVar6;
size_t sVar7;
int iVar8;
istream *piVar9;
int *piVar10;
ulong uVar11;
int4 *puVar12;
ulong *__dest;
ul... |
1,304 | func0 | #include <assert.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 | cpp | func0(int, int, int):
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 <_Z5func0iii+0x29>
mov -0x8(%rbp),%eax
cmp -0xc(%rbp),%eax
je 1172 <_Z5func0iii+0x29>
mov -0xc(%rbp),%eax
cmp -0x4(%rb... | _Z5func0iii:
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]... | _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,... | /* func0(int, int, int) */
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;
} |
1,305 | func0 | #include <assert.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 | cpp | func0(int, int, int):
endbr64
cmp %esi,%edi
sete %al
cmp %edx,%edi
sete %cl
or %ecx,%eax
cmp %edx,%esi
sete %dl
or %edx,%eax
retq
| _Z5func0iii:
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 | /* func0(int, int, int) */
uint func0(int param_1,int param_2,int param_3)
{
int8 in_RAX;
int4 in_ECX;
return (uint)CONCAT71((int7)((ulong)in_RAX >> 8),param_1 == param_2) |
CONCAT31((int3)((uint)in_ECX >> 8),param_1 == param_3) |
CONCAT31((int3)((uint)param_3 >> 8),param_2 == param_3);
} |
1,306 | func0 | #include <assert.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 | cpp | func0(int, int, int):
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)
| _Z5func0iii:
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 | /* func0(int, int, int) */
uint func0(int param_1,int param_2,int param_3)
{
int8 in_RAX;
int4 in_ECX;
return (uint)CONCAT71((int7)((ulong)in_RAX >> 8),param_1 == param_2) |
CONCAT31((int3)((uint)in_ECX >> 8),param_1 == param_3) |
CONCAT31((int3)((uint)param_3 >> 8),param_2 == param_3);
} |
1,307 | func0 | #include <assert.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 | cpp | func0(int, int, int):
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)
| _Z5func0iii:
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 | /* func0(int, int, int) */
uint func0(int param_1,int param_2,int param_3)
{
int8 in_RAX;
int4 in_ECX;
return (uint)CONCAT71((int7)((ulong)in_RAX >> 8),param_1 == param_2) |
CONCAT31((int3)((uint)in_ECX >> 8),param_1 == param_3) |
CONCAT31((int3)((uint)param_3 >> 8),param_2 == param_3);
} |
1,308 | func0 |
#include <vector>
#include <cassert>
| std::vector<int> func0(const std::vector<int>& list1, int m, int n) {
std::vector<int> result;
result.insert(result.end(), list1.begin() + m, list1.end());
result.insert(result.end(), list1.begin(), list1.begin() + n);
return result;
}
| int main() {
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 3, 4) == std::vector<int>{4, 5, 6, 7, 8, 9, 10, 1, 2, 3, 4}));
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 2, 2) == std::vector<int>{3, 4, 5, 6, 7, 8, 9, 10, 1, 2}));
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 5, 2) == std::vector<int>{6,... | O0 | cpp | func0(std::vector<int, std::allocator<int> > const&, int, int):
endbr64
push %rbp
mov %rsp,%rbp
push %r12
push %rbx
sub $0x40,%rsp
mov %rdi,-0x38(%rbp)
mov %rsi,-0x40(%rbp)
mov %edx,-0x44(%rbp)
mov %ecx,-0x48(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
mov -0x38(%rbp),... | _Z5func0RKSt6vectorIiSaIiEEii:
endbr64
push rbp
mov rbp, rsp
push r12
push rbx
sub rsp, 40h
mov [rbp+var_38], rdi
mov [rbp+var_40], rsi
mov [rbp+var_44], edx
mov [rbp+var_48], ecx
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
mov rax, [rbp+var_38]
mov rdi, rax
c... | long long func0(long long a1, long long a2, int a3, int a4)
{
long long v4; // r12
long long v5; // rbx
long long v6; // r12
long long v7; // rbx
long long v11; // [rsp+20h] [rbp-30h] BYREF
long long v12; // [rsp+28h] [rbp-28h] BYREF
_QWORD v13[4]; // [rsp+30h] [rbp-20h] BYREF
v13[1] = __readfsqword(0... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH R12
PUSH RBX
SUB RSP,0x40
MOV qword ptr [RBP + -0x38],RDI
MOV qword ptr [RBP + -0x40],RSI
MOV dword ptr [RBP + -0x44],EDX
MOV dword ptr [RBP + -0x48],ECX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
MOV RAX,qword ptr [RBP + -0x38]
MOV RDI,RAX
CALL 0x00... | /* func0(std::vector<int, std::allocator<int> > const&, int, int) */
vector * func0(vector *param_1,int param_2,int param_3)
{
int8 uVar1;
int8 uVar2;
int in_ECX;
int4 in_register_00000034;
vector<int,std::allocator<int>> *this;
long in_FS_OFFSET;
int8 local_38;
int8 local_30;
int8 local_28;
long ... |
1,309 | func0 |
#include <vector>
#include <cassert>
| std::vector<int> func0(const std::vector<int>& list1, int m, int n) {
std::vector<int> result;
result.insert(result.end(), list1.begin() + m, list1.end());
result.insert(result.end(), list1.begin(), list1.begin() + n);
return result;
}
| int main() {
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 3, 4) == std::vector<int>{4, 5, 6, 7, 8, 9, 10, 1, 2, 3, 4}));
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 2, 2) == std::vector<int>{3, 4, 5, 6, 7, 8, 9, 10, 1, 2}));
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 5, 2) == std::vector<int>{6,... | O1 | cpp | func0(std::vector<int, std::allocator<int> > const&, int, int):
endbr64
push %r12
push %rbp
push %rbx
mov %rdi,%rbx
mov %rsi,%r12
mov %ecx,%ebp
movq $0x0,(%rdi)
movq $0x0,0x8(%rdi)
movq $0x0,0x10(%rdi)
mov 0x8(%rsi),%rcx
movslq %edx,%rdx
mov (%rsi),%rax
lea (%rax,%rdx,4),%rdx
mov $0x0,%... | _Z5func0RKSt6vectorIiSaIiEEii:
endbr64
push r12
push rbp
push rbx
mov rbx, rdi
mov r12, rsi
mov ebp, ecx
mov qword ptr [rdi], 0
mov qword ptr [rdi+8], 0
mov qword ptr [rdi+10h], 0
mov rcx, [rsi+8]
movsxd rdx, edx
mov rax, [rsi]
lea rdx, [rax+rdx*4]
mov esi, 0
call _Z... | _QWORD * func0(_QWORD *a1, _QWORD *a2, int a3, int a4)
{
*a1 = 0LL;
a1[1] = 0LL;
a1[2] = 0LL;
std::vector<int>::_M_range_insert<__gnu_cxx::__normal_iterator<int const*,std::vector<int>>>(
a1,
0LL,
*a2 + 4LL * a3,
a2[1]);
std::vector<int>::_M_range_insert<__gnu_cxx::__normal_iterator<int const*... | func0:
ENDBR64
PUSH R12
PUSH RBP
PUSH RBX
MOV RBX,RDI
MOV R12,RSI
MOV EBP,ECX
MOV qword ptr [RDI],0x0
MOV qword ptr [RDI + 0x8],0x0
MOV qword ptr [RDI + 0x10],0x0
MOV RCX,qword ptr [RSI + 0x8]
MOVSXD RDX,EDX
MOV RAX,qword ptr [RSI]
LEA RDX,[RAX + RDX*0x4]
MOV ESI,0x0
LAB_00101283:
CALL 0x00101952
MOV RDX,qword ptr [R12... | /* func0(std::vector<int, std::allocator<int> > const&, int, int) */
vector * func0(vector *param_1,int param_2,int param_3)
{
int in_ECX;
int4 in_register_00000034;
int8 *puVar1;
puVar1 = (int8 *)CONCAT44(in_register_00000034,param_2);
*(int8 *)param_1 = 0;
*(int8 *)(param_1 + 8) = 0;
*(int8 *)(para... |
1,310 | func0 |
#include <vector>
#include <cassert>
| std::vector<int> func0(const std::vector<int>& list1, int m, int n) {
std::vector<int> result;
result.insert(result.end(), list1.begin() + m, list1.end());
result.insert(result.end(), list1.begin(), list1.begin() + n);
return result;
}
| int main() {
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 3, 4) == std::vector<int>{4, 5, 6, 7, 8, 9, 10, 1, 2, 3, 4}));
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 2, 2) == std::vector<int>{3, 4, 5, 6, 7, 8, 9, 10, 1, 2}));
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 5, 2) == std::vector<int>{6,... | O2 | cpp | func0(std::vector<int, std::allocator<int> > const&, int, int):
endbr64
push %r12
movslq %edx,%rdx
mov %rdi,%r12
push %rbp
mov %rsi,%rbp
push %rbx
movslq %ecx,%rbx
movq $0x0,(%rdi)
movq $0x0,0x8(%rdi)
movq $0x0,0x10(%rdi)
mov (%rsi),%rax
mov 0x8(%rsi),%rcx
xor %esi,%esi
lea (%rax,%rdx,4),%... | _Z5func0RKSt6vectorIiSaIiEEii:
endbr64
pxor xmm0, xmm0
push r12
movsxd rdx, edx
mov r12, rsi
push rbp
movsxd rbp, ecx
push rbx
mov rbx, rdi
mov qword ptr [rdi+10h], 0
movups xmmword ptr [rdi], xmm0
mov rax, [rsi]
mov rcx, [rsi+8]
xor esi, esi
lea rdx, [rax+rdx*4]
call _ZNSt... | long long func0(long long a1, _QWORD *a2, int a3, int a4)
{
long long v4; // rbp
v4 = a4;
*(_QWORD *)(a1 + 16) = 0LL;
*(_OWORD *)a1 = 0LL;
std::vector<int>::_M_range_insert<__gnu_cxx::__normal_iterator<int const*,std::vector<int>>>(
a1,
0LL,
*a2 + 4LL * a3,
a2[1]);
std::vector<int>::_M_ran... | func0:
ENDBR64
PXOR XMM0,XMM0
PUSH R12
MOVSXD RDX,EDX
MOV R12,RSI
PUSH RBP
MOVSXD RBP,ECX
PUSH RBX
MOV RBX,RDI
MOV qword ptr [RDI + 0x10],0x0
MOVUPS xmmword ptr [RDI],XMM0
MOV RAX,qword ptr [RSI]
MOV RCX,qword ptr [RSI + 0x8]
XOR ESI,ESI
LEA RDX,[RAX + RDX*0x4]
LAB_00101a10:
CALL 0x00101690
MOV RDX,qword ptr [R12]
MOV ... | /* func0(std::vector<int, std::allocator<int> > const&, int, int) */
vector * func0(vector *param_1,int param_2,int param_3)
{
int in_ECX;
int4 in_register_00000034;
int8 *puVar1;
puVar1 = (int8 *)CONCAT44(in_register_00000034,param_2);
*(int8 *)(param_1 + 0x10) = 0;
*(int (*) [16])param_1 = (int [16]... |
1,311 | func0 |
#include <vector>
#include <cassert>
| std::vector<int> func0(const std::vector<int>& list1, int m, int n) {
std::vector<int> result;
result.insert(result.end(), list1.begin() + m, list1.end());
result.insert(result.end(), list1.begin(), list1.begin() + n);
return result;
}
| int main() {
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 3, 4) == std::vector<int>{4, 5, 6, 7, 8, 9, 10, 1, 2, 3, 4}));
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 2, 2) == std::vector<int>{3, 4, 5, 6, 7, 8, 9, 10, 1, 2}));
assert((func0({1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, 5, 2) == std::vector<int>{6,... | O3 | cpp | func0(std::vector<int, std::allocator<int> > const&, int, int):
endbr64
push %r15
pxor %xmm0,%xmm0
movslq %edx,%rdx
push %r14
push %r13
push %r12
mov %rdi,%r12
push %rbp
push %rbx
mov %ecx,%ebx
sub $0x28,%rsp
movq $0x0,0x10(%rdi)
movups %xmm0,(%rdi)
mov (%rsi),%rbp
mov 0x8(%rsi),%rax
lea ... | _Z5func0RKSt6vectorIiSaIiEEii:
endbr64
push r15
pxor xmm0, xmm0
movsxd rdx, edx
push r14
push r13
push r12
push rbp
mov rbp, rdi
push rbx
movsxd rbx, ecx
sub rsp, 28h
mov qword ptr [rdi+10h], 0
movups xmmword ptr [rdi], xmm0
mov r15, [rsi]
mov r12, [rsi+8]
lea r14, [r15+r... | long long func0(long long a1, long long a2, int a3, int a4)
{
long long v4; // rbx
_DWORD *v5; // r15
char *v6; // r12
char *v7; // r14
signed long long v8; // r12
_DWORD *v9; // rax
signed long long v10; // rbx
unsigned long long v12; // rax
_DWORD *v13; // r14
_DWORD *v14; // r13
char *v15; // ... | func0:
ENDBR64
PUSH R15
PXOR XMM0,XMM0
MOVSXD RDX,EDX
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
MOV RBP,RDI
PUSH RBX
MOVSXD RBX,ECX
SUB RSP,0x28
MOV qword ptr [RDI + 0x10],0x0
MOVUPS xmmword ptr [RDI],XMM0
MOV R15,qword ptr [RSI]
MOV R12,qword ptr [RSI + 0x8]
LEA R14,[R15 + RDX*0x4]
CMP R14,R12
JZ 0x00101760
MOV RAX,0x7fffff... | /* func0(std::vector<int, std::allocator<int> > const&, int, int) */
vector * func0(vector *param_1,int param_2,int param_3)
{
void *pvVar1;
ulong uVar2;
int4 *in_RCX;
ulong __n;
int4 *puVar3;
int4 in_register_00000034;
int8 *puVar4;
int8 *unaff_R13;
int4 *__src;
int4 *__src_00;
int4 *local_50;
... |
1,312 | func0 |
#include <iostream>
#include <vector>
#include <assert.h>
| int func0(std::vector<int> list) {
int neg_count = 0;
for (int num : list) {
if (num <= 0) {
neg_count += 1;
}
}
return neg_count;
}
| int main() {
assert(func0(std::vector<int>{-1, -2, 3, -4, -5}) == 4);
assert(func0(std::vector<int>{1, 2, 3}) == 0);
assert(func0(std::vector<int>{1, 2, -3, -10, 20}) == 2);
return 0;
}
| O0 | cpp | func0(std::vector<int, std::allocator<int> >):
endbr64
push %rbp
mov %rsp,%rbp
sub $0x40,%rsp
mov %rdi,-0x38(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x8(%rbp)
xor %eax,%eax
movl $0x0,-0x28(%rbp)
mov -0x38(%rbp),%rax
mov %rax,-0x10(%rbp)
mov -0x10(%rbp),%rax
mov %rax,%rdi
callq 161c <_ZNSt6v... | _Z5func0St6vectorIiSaIiEE:
endbr64
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_38], rdi
mov rax, fs:28h
mov [rbp+var_8], rax
xor eax, eax
mov [rbp+var_28], 0
mov rax, [rbp+var_38]
mov [rbp+var_10], rax
mov rax, [rbp+var_10]
mov rdi, rax
call _ZNSt6vectorIiSaIiEE5beg... | long long func0(long long a1)
{
unsigned int v2; // [rsp+18h] [rbp-28h]
long long v3; // [rsp+20h] [rbp-20h] BYREF
_QWORD v4[3]; // [rsp+28h] [rbp-18h] BYREF
v4[2] = __readfsqword(0x28u);
v2 = 0;
v4[1] = a1;
v3 = std::vector<int>::begin(a1);
v4[0] = std::vector<int>::end(a1);
while ( (unsigned __int... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x38],RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
XOR EAX,EAX
MOV dword ptr [RBP + -0x28],0x0
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,RAX
CALL 0x001015fa
MOV qword pt... | /* func0(std::vector<int, std::allocator<int> >) */
int func0(vector param_1)
{
bool bVar1;
int *piVar2;
int4 in_register_0000003c;
long in_FS_OFFSET;
int local_30;
int8 local_28;
int8 local_20;
vector<int,std::allocator<int>> *local_18;
long local_10;
local_18 = (vector<int,std::allocator<int>... |
1,313 | func0 |
#include <iostream>
#include <vector>
#include <assert.h>
| int func0(std::vector<int> list) {
int neg_count = 0;
for (int num : list) {
if (num <= 0) {
neg_count += 1;
}
}
return neg_count;
}
| int main() {
assert(func0(std::vector<int>{-1, -2, 3, -4, -5}) == 4);
assert(func0(std::vector<int>{1, 2, 3}) == 0);
assert(func0(std::vector<int>{1, 2, -3, -10, 20}) == 2);
return 0;
}
| O1 | cpp | func0(std::vector<int, std::allocator<int> >):
endbr64
mov (%rdi),%rax
mov 0x8(%rdi),%rsi
cmp %rsi,%rax
je 1275 <_Z5func0St6vectorIiSaIiEE+0x2c>
mov $0x0,%edx
cmpl $0x0,(%rax)
setle %cl
movzbl %cl,%ecx
add %ecx,%edx
add $0x4,%rax
cmp %rax,%rsi
jne 125e <_Z5func0St6vectorIiSaIiEE+0x15>
mov... | _Z5func0St6vectorIiSaIiEE:
endbr64
mov rax, [rdi]
mov rsi, [rdi+8]
cmp rsi, rax
jz short loc_1235
mov edx, 0
loc_121E:
cmp dword ptr [rax], 0
setle cl
movzx ecx, cl
add edx, ecx
add rax, 4
cmp rax, rsi
jnz short loc_121E
loc_1232:
mov eax, edx
retn
loc_1235:
mov edx,... | long long func0(long long a1)
{
_DWORD *v1; // rax
_DWORD *v2; // rsi
unsigned int v3; // edx
v1 = *(_DWORD **)a1;
v2 = *(_DWORD **)(a1 + 8);
if ( v2 == *(_DWORD **)a1 )
{
return 0;
}
else
{
v3 = 0;
do
v3 += *v1++ <= 0;
while ( v1 != v2 );
}
return v3;
} | func0:
ENDBR64
MOV RAX,qword ptr [RDI]
MOV RSI,qword ptr [RDI + 0x8]
CMP RSI,RAX
JZ 0x00101235
MOV EDX,0x0
LAB_0010121e:
CMP dword ptr [RAX],0x0
SETLE CL
MOVZX ECX,CL
ADD EDX,ECX
ADD RAX,0x4
CMP RAX,RSI
JNZ 0x0010121e
LAB_00101232:
MOV EAX,EDX
RET
LAB_00101235:
MOV EDX,0x0
JMP 0x00101232 | /* func0(std::vector<int, std::allocator<int> >) */
int func0(vector param_1)
{
int *piVar1;
int *piVar2;
int iVar3;
int4 in_register_0000003c;
piVar2 = *(int **)CONCAT44(in_register_0000003c,param_1);
piVar1 = *(int **)(CONCAT44(in_register_0000003c,param_1) + 8);
if (piVar1 == piVar2) {
iVar3 =... |
1,314 | func0 |
#include <iostream>
#include <vector>
#include <assert.h>
| int func0(std::vector<int> list) {
int neg_count = 0;
for (int num : list) {
if (num <= 0) {
neg_count += 1;
}
}
return neg_count;
}
| int main() {
assert(func0(std::vector<int>{-1, -2, 3, -4, -5}) == 4);
assert(func0(std::vector<int>{1, 2, 3}) == 0);
assert(func0(std::vector<int>{1, 2, -3, -10, 20}) == 2);
return 0;
}
| O2 | cpp | func0(std::vector<int, std::allocator<int> >):
endbr64
mov (%rdi),%rax
mov 0x8(%rdi),%rcx
xor %r8d,%r8d
cmp %rcx,%rax
je 14cd <_Z5func0St6vectorIiSaIiEE+0x2d>
nopl 0x0(%rax,%rax,1)
mov (%rax),%esi
xor %edx,%edx
test %esi,%esi
setle %dl
add $0x4,%rax
add %edx,%r8d
cmp %rax,%rcx
jne ... | _Z5func0St6vectorIiSaIiEE:
endbr64
mov rax, [rdi]
mov rsi, [rdi+8]
xor edx, edx
cmp rsi, rax
jz short loc_140C
nop word ptr [rax+rax+00h]
loc_13F8:
mov edi, [rax]
xor ecx, ecx
test edi, edi
setle cl
add rax, 4
add edx, ecx
cmp rsi, rax
jnz short loc_13F8
loc_140C:
m... | long long func0(long long a1)
{
_DWORD *v1; // rax
_DWORD *v2; // rsi
unsigned int v3; // edx
int v4; // ecx
v1 = *(_DWORD **)a1;
v2 = *(_DWORD **)(a1 + 8);
v3 = 0;
if ( v2 != *(_DWORD **)a1 )
{
do
{
v4 = *v1++ <= 0;
v3 += v4;
}
while ( v2 != v1 );
}
return v3;
} | func0:
ENDBR64
MOV RAX,qword ptr [RDI]
MOV RSI,qword ptr [RDI + 0x8]
XOR EDX,EDX
CMP RSI,RAX
JZ 0x0010140c
NOP word ptr [RAX + RAX*0x1]
LAB_001013f8:
MOV EDI,dword ptr [RAX]
XOR ECX,ECX
TEST EDI,EDI
SETLE CL
ADD RAX,0x4
ADD EDX,ECX
CMP RSI,RAX
JNZ 0x001013f8
LAB_0010140c:
MOV EAX,EDX
RET | /* func0(std::vector<int, std::allocator<int> >) */
int func0(vector param_1)
{
int *piVar1;
int iVar2;
int4 in_register_0000003c;
iVar2 = 0;
for (piVar1 = *(int **)CONCAT44(in_register_0000003c,param_1);
(int *)((int8 *)CONCAT44(in_register_0000003c,param_1))[1] != piVar1;
piVar1 = piVar1 + ... |
1,315 | func0 |
#include <iostream>
#include <vector>
#include <assert.h>
| int func0(std::vector<int> list) {
int neg_count = 0;
for (int num : list) {
if (num <= 0) {
neg_count += 1;
}
}
return neg_count;
}
| int main() {
assert(func0(std::vector<int>{-1, -2, 3, -4, -5}) == 4);
assert(func0(std::vector<int>{1, 2, 3}) == 0);
assert(func0(std::vector<int>{1, 2, -3, -10, 20}) == 2);
return 0;
}
| O3 | cpp | func0(std::vector<int, std::allocator<int> >):
endbr64
mov (%rdi),%rdx
mov 0x8(%rdi),%rsi
cmp %rsi,%rdx
je 1820 <_Z5func0St6vectorIiSaIiEE+0xf0>
lea -0x4(%rsi),%rcx
mov %rdx,%rax
movabs $0x3ffffffffffffffc,%r8
sub %rdx,%rcx
shr $0x2,%rcx
lea 0x1(%rcx),%rdi
test %r8,%rcx
je 1829 <_Z5fun... | _Z5func0St6vectorIiSaIiEE:
endbr64
mov rdx, [rdi]
mov rdi, [rdi+8]
cmp rdi, rdx
jz loc_1740
lea rcx, [rdi-4]
mov rax, rdx
sub rcx, rdx
mov rsi, rcx
shr rsi, 2
add rsi, 1
cmp rcx, 8
jbe loc_1743
mov rcx, rsi
movdqa xmm2, cs:xmmword_2100
pxor xmm0, xmm0
shr rcx... | long long func0(const __m128i **a1)
{
const __m128i *v1; // rdx
const __m128i *v2; // rdi
const __m128i *v3; // rax
unsigned long long v4; // rsi
__m128i si128; // xmm2
__m128i v6; // xmm0
__m128i v7; // xmm3
__m128i v8; // xmm0
long long result; // rax
v1 = *a1;
v2 = a1[1];
if ( v2 == v1 )
... | func0:
ENDBR64
MOV RDX,qword ptr [RDI]
MOV RDI,qword ptr [RDI + 0x8]
CMP RDI,RDX
JZ 0x00101740
LEA RCX,[RDI + -0x4]
MOV RAX,RDX
SUB RCX,RDX
MOV RSI,RCX
SHR RSI,0x2
ADD RSI,0x1
CMP RCX,0x8
JBE 0x00101743
MOV RCX,RSI
MOVDQA XMM2,xmmword ptr [0x00102100]
PXOR XMM0,XMM0
SHR RCX,0x2
SHL RCX,0x4
ADD RCX,RDX
NOP dword ptr [RA... | /* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* func0(std::vector<int, std::allocator<int> >) */
int func0(vector param_1)
{
int *piVar1;
int iVar2;
int *piVar3;
int *piVar4;
int *piVar5;
int *piVar6;
ulong uVar7;
int *piVar8;
ulong uVar9;
int4 in_register_0... |
1,316 | func0 |
#include <iostream>
#include <string>
#include <vector>
#include <regex>
#include <assert.h>
| std::vector<std::string> func0(const std::string& text) {
std::regex word_regex(R"(\b\w{3,5}\b)");
std::sregex_iterator words_begin = std::sregex_iterator(text.begin(), text.end(), word_regex);
std::sregex_iterator words_end = std::sregex_iterator();
std::vector<std::string> words;
for (std::... | int main() {
std::vector<std::string> result;
result = func0("For the four consumer complaints contact manager AKR reddy");
assert((result == std::vector<std::string>{"For", "the", "four", "AKR", "reddy"}));
result = func0("Certain service are subject to change MSR");
assert((result == std:... | O0 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x148,%rsp
mov %rdi,-0x148(%rbp)
mov %rsi,-0x150(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
lea -0x140(%rbp),%rax
mov $0x10,%edx
le... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 148h
mov [rbp+var_148], rdi
mov [rbp+var_150], rsi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
lea rax, [rbp+var_140]
mov edx, 10h
lea rcx, aBW35B; "\\b\\w... | long long func0(long long a1, long long a2)
{
long long v2; // rbx
long long v3; // rax
long long v4; // rax
_BYTE v6[32]; // [rsp+10h] [rbp-140h] BYREF
_BYTE v7[32]; // [rsp+30h] [rbp-120h] BYREF
_BYTE v8[64]; // [rsp+50h] [rbp-100h] BYREF
_OWORD v9[4]; // [rsp+90h] [rbp-C0h] BYREF
_BYTE v10[64]; // [... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x148
MOV qword ptr [RBP + -0x148],RDI
MOV qword ptr [RBP + -0x150],RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
LEA RAX,[RBP + -0x140]
MOV EDX,0x10
LEA RCX,[0x134051]
MOV RSI,RCX
MOV RDI,RAX
LAB_00104b6f:
CALL 0x00106b5e
MOV RAX,qword ... | /* func0(std::string const&) */
string * func0(string *param_1)
{
char cVar1;
__normal_iterator _Var2;
__normal_iterator _Var3;
match_results *pmVar4;
long in_FS_OFFSET;
regex local_148 [32];
match_results<__normal_iterator<char_const*,std::string>,std::allocator<std::sub_match<__normal_iterator<char_co... |
1,317 | func0 |
#include <iostream>
#include <string>
#include <vector>
#include <regex>
#include <assert.h>
| std::vector<std::string> func0(const std::string& text) {
std::regex word_regex(R"(\b\w{3,5}\b)");
std::sregex_iterator words_begin = std::sregex_iterator(text.begin(), text.end(), word_regex);
std::sregex_iterator words_end = std::sregex_iterator();
std::vector<std::string> words;
for (std::... | int main() {
std::vector<std::string> result;
result = func0("For the four consumer complaints contact manager AKR reddy");
assert((result == std::vector<std::string>{"For", "the", "four", "AKR", "reddy"}));
result = func0("Certain service are subject to change MSR");
assert((result == std:... | O1 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x298,%rsp
mov %rdi,%rbp
mov %rsi,%rbx
mov %fs:0x28,%rax
mov %rax,0x288(%rsp)
xor %eax,%eax
lea 0xb0(%rsp),%r13
mov ... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push rbp
mov rbp, rsp
push r15
push r14
push r13
push r12
push rbx
sub rsp, 2C8h
mov r12, rdi
mov rbx, rsi
mov rax, fs:28h
mov [rbp+var_38], rax
xor eax, eax
lea rax, [rbp+var_2C8]
mov r14, rax
... | _QWORD * func0(_QWORD *a1, long long *a2)
{
long long v4; // rdx
long long v5; // rax
long long v6; // rdi
long long v7; // rsi
unsigned long long v8; // rbx
char *v9; // rdx
struct _Unwind_Exception *v10; // rbx
char *v11; // rbx
long long v12; // rax
char *v13; // rdx
void **v14; // rsi
_QWORD... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBX
SUB RSP,0x2c8
MOV R12,RDI
MOV RBX,RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x38],RAX
XOR EAX,EAX
LEA RAX,[RBP + -0x2c8]
MOV R14,RAX
MOV RDI,RAX
CALL 0x001046f0
MOV qword ptr [RBP + -0x2c0],0x0
MOV qword ptr [RBP + -0x2b8],0x0
... | /* func0(std::string const&) */
string * func0(string *param_1)
{
long *plVar1;
int *__src;
_Sp_counted_base<(_Lock_policy)2> *this;
_Sp_counted_base<(_Lock_policy)2> *p_Var2;
bool bVar3;
char cVar4;
uint uVar5;
ulong uVar6;
int8 uVar7;
ulong uVar8;
uint uVar9;
sub_match *psVar10;
sub_match ... |
1,318 | func0 |
#include <iostream>
#include <string>
#include <vector>
#include <regex>
#include <assert.h>
| std::vector<std::string> func0(const std::string& text) {
std::regex word_regex(R"(\b\w{3,5}\b)");
std::sregex_iterator words_begin = std::sregex_iterator(text.begin(), text.end(), word_regex);
std::sregex_iterator words_end = std::sregex_iterator();
std::vector<std::string> words;
for (std::... | int main() {
std::vector<std::string> result;
result = func0("For the four consumer complaints contact manager AKR reddy");
assert((result == std::vector<std::string>{"For", "the", "four", "AKR", "reddy"}));
result = func0("Certain service are subject to change MSR");
assert((result == std:... | O2 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r15
push %r14
push %r13
push %r12
mov %rdi,%r12
push %rbp
push %rbx
mov %rsi,%rbx
sub $0x288,%rsp
mov %fs:0x28,%rax
mov %rax,0x278(%rsp)
xor %eax,%eax
lea 0xa0(%rsp),%r14
lea ... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push rbp
mov rbp, rsp
push r15
push r14
lea r15, [rbp+var_2C8]
push r13
push r12
push rbx
mov rbx, rsi
sub rsp, 2E8h
mov [rbp+var_2E8], rdi
mov rdi, r15; this
mov rax, fs:28h
mov [rbp+var_38], rax
x... | long long func0(long long a1, unsigned long long *a2)
{
__m128i v3; // rdi
__m128i v4; // xmm0
volatile signed __int32 *v5; // r12
long long v6; // rdx
volatile signed __int32 *v7; // rcx
signed __int32 v8; // eax
long long v9; // r12
long long v10; // rdx
volatile signed __int32 *v11; // rcx
signe... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
LEA R15,[RBP + -0x2c8]
PUSH R13
PUSH R12
PUSH RBX
MOV RBX,RSI
SUB RSP,0x2e8
MOV qword ptr [RBP + -0x2e8],RDI
MOV RDI,R15
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x38],RAX
XOR EAX,EAX
MOV qword ptr [RBP + -0x300],R15
CALL 0x001036d0
LEA RDX,[0x119722]
PXOR ... | /* func0(std::string const&) */
string * func0(string *param_1)
{
int *__src;
int auVar1 [16];
int auVar2 [16];
bool bVar3;
int iVar4;
long *plVar5;
long *plVar6;
long *plVar7;
uint uVar8;
regex *prVar9;
uint uVar10;
long *plVar11;
long *plVar12;
long lVar13;
long *in_RSI;
_Sp_counted_... |
1,319 | func0 |
#include <iostream>
#include <string>
#include <vector>
#include <regex>
#include <assert.h>
| std::vector<std::string> func0(const std::string& text) {
std::regex word_regex(R"(\b\w{3,5}\b)");
std::sregex_iterator words_begin = std::sregex_iterator(text.begin(), text.end(), word_regex);
std::sregex_iterator words_end = std::sregex_iterator();
std::vector<std::string> words;
for (std::... | int main() {
std::vector<std::string> result;
result = func0("For the four consumer complaints contact manager AKR reddy");
assert((result == std::vector<std::string>{"For", "the", "four", "AKR", "reddy"}));
result = func0("Certain service are subject to change MSR");
assert((result == std:... | O3 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r15
push %r14
push %r13
push %r12
mov %rdi,%r12
push %rbp
mov %rsi,%rbp
push %rbx
sub $0x288,%rsp
mov %fs:0x28,%rax
mov %rax,0x278(%rsp)
xor %eax,%eax
lea 0xa0(%rsp),%r14
lea ... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push rbp
mov rbp, rsp
push r15
push r14
push r13
mov r13, rsi
push r12
push rbx
lea rbx, [rbp+var_2C8]
sub rsp, 2E8h
mov [rbp+var_2E8], rdi
mov rdi, rbx; this
mov rax, fs:28h
mov [rbp+var_38], rax
x... | long long func0(long long a1, unsigned long long *a2)
{
void **v2; // r12
long long v3; // r15
signed long long v4; // r13
__m128i v5; // xmm0
long long v6; // rdi
void *v7; // rdi
void **v8; // rbx
void *v9; // rdi
unsigned long long v10; // rax
unsigned long long v11; // rdx
__m128i v12; // rdi... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH R15
PUSH R14
PUSH R13
MOV R13,RSI
PUSH R12
PUSH RBX
LEA RBX,[RBP + -0x2c8]
SUB RSP,0x2e8
MOV qword ptr [RBP + -0x2e8],RDI
MOV RDI,RBX
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x38],RAX
XOR EAX,EAX
MOV qword ptr [RBP + -0x308],RBX
CALL 0x00104710
LEA RDX,[0x11b75b]
PXOR ... | /* func0(std::string const&) */
string * func0(string *param_1)
{
int8 uVar1;
int auVar2 [16];
int auVar3 [16];
bool bVar4;
int8 *puVar5;
ulong uVar6;
int auVar7 [8];
vector<std::sub_match<__normal_iterator<char_const*,std::string>>,std::allocator<std::sub_match<__normal_iterator<char_const*,std::stri... |
1,320 | 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 | cpp | func0(int):
endbr64
push %rbp
mov %rsp,%rbp
mov %edi,-0x14(%rbp)
movl $0x0,-0x8(%rbp)
movl $0x1,-0x4(%rbp)
mov -0x14(%rbp),%eax
cmp -0x4(%rbp),%eax
jl 117d <_Z5func0i+0x34>
mov -0x4(%rbp),%eax
and -0x14(%rbp),%eax
test %eax,%eax
jne 1178 <_Z5func0i+0x2f>
addl $0x1,-0x8(%rbp)
shll -0... | _Z5func0i:
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 ea... | 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... | /* func0(int) */
int func0(int param_1)
{
int4 local_10;
int4 local_c;
local_10 = 0;
for (local_c = 1; (int)local_c <= param_1; local_c = local_c << 1) {
if ((local_c & param_1) == 0) {
local_10 = local_10 + 1;
}
}
return local_10;
} |
1,321 | 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 | cpp | func0(int):
endbr64
test %edi,%edi
jle 116e <_Z5func0i+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 <_Z5func0i+0x12>
mov %edx,%eax
retq
mov $0x0,%edx
jmp 116b <_Z5func0i+0x22>
| _Z5func0i:
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 | /* func0(int) */
int func0(int param_1)
{
uint uVar1;
int iVar2;
if (param_1 < 1) {
iVar2 = 0;
}
else {
uVar1 = 1;
iVar2 = 0;
do {
iVar2 = iVar2 + (uint)((param_1 & uVar1) == 0);
uVar1 = uVar1 * 2;
} while ((int)uVar1 <= param_1);
}
return iVar2;
} |
1,322 | 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 | cpp | func0(int):
endbr64
test %edi,%edi
jle 1218 <_Z5func0i+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 <_Z5func0i+0x10>
mov %r8d,%eax
retq
nopl (%rax)
xor %r8d,%r8d
mov %r8d,%eax
retq
| _Z5func0i:
endbr64
test edi, edi
jle short loc_1218
mov eax, 1
xor edx, edx
nop
loc_1200:
mov ecx, edi
and ecx, eax
cmp ecx, 1
adc edx, 0
add eax, eax
cmp edi, eax
jge short loc_1200
mov eax, edx
retn
loc_1218:
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 0x00101218
MOV EAX,0x1
XOR EDX,EDX
NOP
LAB_00101200:
MOV ECX,EDI
AND ECX,EAX
CMP ECX,0x1
ADC EDX,0x0
ADD EAX,EAX
CMP EDI,EAX
JGE 0x00101200
MOV EAX,EDX
RET
LAB_00101218:
XOR EDX,EDX
MOV EAX,EDX
RET | /* func0(int) */
int func0(int param_1)
{
uint uVar1;
int iVar2;
if (0 < param_1) {
uVar1 = 1;
iVar2 = 0;
do {
iVar2 = iVar2 + (uint)((param_1 & uVar1) == 0);
uVar1 = uVar1 * 2;
} while ((int)uVar1 <= param_1);
return iVar2;
}
return 0;
} |
1,323 | 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 | cpp | func0(int):
endbr64
test %edi,%edi
jle 1168 <_Z5func0i+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 <_Z5func0i+0x10>
mov %r8d,%eax
retq
nopl (%rax)
xor %r8d,%r8d
mov %r8d,%eax
retq
| _Z5func0i:
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 | /* func0(int) */
int func0(int param_1)
{
uint uVar1;
int iVar2;
if (0 < param_1) {
uVar1 = 1;
iVar2 = 0;
do {
iVar2 = iVar2 + (uint)((param_1 & uVar1) == 0);
uVar1 = uVar1 * 2;
} while ((int)uVar1 <= param_1);
return iVar2;
}
return 0;
} |
1,324 | func0 |
#include <iostream>
#include <string>
#include <map>
#include <cassert>
| std::map<char, int> func0(const std::string& str1) {
std::map<char, int> dict;
for(char n : str1){
if(dict.find(n) != dict.end()){
dict[n] += 1;
}
else{
dict[n] = 1;
}
}
return dict;
}
| int main() {
std::map<char, int> expected1 = { {'p', 1}, {'y', 1}, {'t', 1}, {'h', 1}, {'o', 1}, {'n', 1} };
std::map<char, int> expected2 = { {'p', 1}, {'r', 2}, {'o', 1}, {'g', 1}, {'a', 1}, {'m', 1} };
std::map<char, int> expected3 = { {'l', 1}, {'a', 2}, {'n', 1}, {'g', 2}, {'u', 1}, {'e', 1} };
... | O0 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x58,%rsp
mov %rdi,-0x58(%rbp)
mov %rsi,-0x60(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
mov -0x58(%rbp),%rax
mov %rax,%rdi
callq ... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 58h
mov [rbp+var_58], rdi
mov [rbp+var_60], rsi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
mov rax, [rbp+var_58]
mov rdi, rax
call _ZNSt3mapIciSt4lessIcESa... | long long func0(long long a1, long long a2)
{
_DWORD *v2; // rax
char v4; // [rsp+1Fh] [rbp-41h] BYREF
long long v5; // [rsp+20h] [rbp-40h] BYREF
long long v6; // [rsp+28h] [rbp-38h] BYREF
long long v7; // [rsp+30h] [rbp-30h] BYREF
_QWORD v8[4]; // [rsp+38h] [rbp-28h] BYREF
v8[2] = __readfsqword(0x28u);... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x58
MOV qword ptr [RBP + -0x58],RDI
MOV qword ptr [RBP + -0x60],RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
MOV RAX,qword ptr [RBP + -0x58]
MOV RDI,RAX
CALL 0x00102d66
MOV RAX,qword ptr [RBP + -0x60]
MOV qword ptr [RBP + -0x20],RAX
MO... | /* func0(std::string const&) */
string * func0(string *param_1)
{
char cVar1;
bool bVar2;
char *pcVar3;
int *piVar4;
int4 *puVar5;
long in_FS_OFFSET;
char local_49;
int8 local_48;
int8 local_40;
int8 local_38;
int8 local_30 [2];
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
... |
1,325 | func0 |
#include <iostream>
#include <string>
#include <map>
#include <cassert>
| std::map<char, int> func0(const std::string& str1) {
std::map<char, int> dict;
for(char n : str1){
if(dict.find(n) != dict.end()){
dict[n] += 1;
}
else{
dict[n] = 1;
}
}
return dict;
}
| int main() {
std::map<char, int> expected1 = { {'p', 1}, {'y', 1}, {'t', 1}, {'h', 1}, {'o', 1}, {'n', 1} };
std::map<char, int> expected2 = { {'p', 1}, {'r', 2}, {'o', 1}, {'g', 1}, {'a', 1}, {'m', 1} };
std::map<char, int> expected3 = { {'l', 1}, {'a', 2}, {'n', 1}, {'g', 2}, {'u', 1}, {'e', 1} };
... | O1 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x20,%rsp
mov %rdi,%r12
mov %fs:0x28,%rax
mov %rax,0x18(%rsp)
xor %eax,%eax
movl $0x0,0x8(%rdi)
movq $0x0,0x10(%rdi)
lea 0x8(%rdi)... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 20h
mov r12, rdi
mov rax, fs:28h
mov [rsp+48h+var_30], rax
xor eax, eax
mov dword ptr [rdi+8], 0
mov qword ptr [rdi+10h], 0
lea rbp, [rdi+8]
mov ... | long long func0(long long a1, long long a2)
{
long long v3; // rbp
char *v4; // rbx
char *v5; // r13
long long v6; // rcx
long long v7; // rsi
long long v8; // rsi
long long v9; // rdx
char v10; // di
char v12; // [rsp+5h] [rbp-43h] BYREF
char v13; // [rsp+6h] [rbp-42h] BYREF
char v14; // [rsp+7h... | func0:
ENDBR64
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x20
MOV R12,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x18],RAX
XOR EAX,EAX
MOV dword ptr [RDI + 0x8],0x0
MOV qword ptr [RDI + 0x10],0x0
LEA RBP,[RDI + 0x8]
MOV qword ptr [RDI + 0x18],RBP
MOV qword ptr [RDI + 0x20],RBP
MOV qword ptr [RDI + ... | /* func0(std::string const&) */
string * func0(string *param_1)
{
piecewise_construct_t *ppVar1;
_Rb_tree_iterator _Var2;
int4 extraout_var;
piecewise_construct_t *ppVar4;
piecewise_construct_t *ppVar5;
char *pcVar6;
int8 *in_RSI;
piecewise_construct_t *ppVar7;
char *pcVar8;
long in_FS_OFFSET;
c... |
1,326 | func0 |
#include <iostream>
#include <string>
#include <map>
#include <cassert>
| std::map<char, int> func0(const std::string& str1) {
std::map<char, int> dict;
for(char n : str1){
if(dict.find(n) != dict.end()){
dict[n] += 1;
}
else{
dict[n] = 1;
}
}
return dict;
}
| int main() {
std::map<char, int> expected1 = { {'p', 1}, {'y', 1}, {'t', 1}, {'h', 1}, {'o', 1}, {'n', 1} };
std::map<char, int> expected2 = { {'p', 1}, {'r', 2}, {'o', 1}, {'g', 1}, {'a', 1}, {'m', 1} };
std::map<char, int> expected3 = { {'l', 1}, {'a', 2}, {'n', 1}, {'g', 2}, {'u', 1}, {'e', 1} };
... | O2 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r14
push %r13
push %r12
mov %rdi,%r12
push %rbp
lea 0x8(%rdi),%rbp
push %rbx
sub $0x20,%rsp
mov (%rsi),%rbx
mov %fs:0x28,%rax
mov %rax,0x18(%rsp)
xor %eax,%eax
movq $0x0,0x28(%rd... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r14
push r13
push r12
mov r12, rdi
push rbp
lea rbp, [rdi+8]
push rbx
sub rsp, 20h
mov rbx, [rsi]
mov rax, fs:28h
mov [rsp+48h+var_30], rax
xor eax, eax
mov qword ptr [rdi+28h], 0
mov r13, [rs... | long long func0(long long a1, long long a2)
{
long long v3; // rbp
char *v4; // rbx
long long v5; // r13
char *v6; // r13
long long i; // rdx
char v8; // di
long long v9; // rsi
long long v10; // rcx
long long v11; // r8
long long v12; // r9
bool v13; // cc
long long v14; // rax
long long v15... | func0:
ENDBR64
PUSH R14
PUSH R13
PUSH R12
MOV R12,RDI
PUSH RBP
LEA RBP,[RDI + 0x8]
PUSH RBX
SUB RSP,0x20
MOV RBX,qword ptr [RSI]
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x18],RAX
XOR EAX,EAX
MOV qword ptr [RDI + 0x28],0x0
MOV R13,qword ptr [RSI + 0x8]
MOV dword ptr [RDI + 0x8],0x0
ADD R13,RBX
MOV qword ptr [RD... | /* func0(std::string const&) */
string * func0(string *param_1)
{
tuple *ptVar1;
long lVar2;
_Rb_tree_iterator _Var3;
tuple *ptVar4;
int4 extraout_var_00;
tuple *in_RCX;
tuple *ptVar6;
char *pcVar7;
int8 *in_RSI;
tuple *ptVar8;
char *pcVar9;
long in_FS_OFFSET;
char local_41;
char *local_40... |
1,327 | func0 |
#include <iostream>
#include <string>
#include <map>
#include <cassert>
| std::map<char, int> func0(const std::string& str1) {
std::map<char, int> dict;
for(char n : str1){
if(dict.find(n) != dict.end()){
dict[n] += 1;
}
else{
dict[n] = 1;
}
}
return dict;
}
| int main() {
std::map<char, int> expected1 = { {'p', 1}, {'y', 1}, {'t', 1}, {'h', 1}, {'o', 1}, {'n', 1} };
std::map<char, int> expected2 = { {'p', 1}, {'r', 2}, {'o', 1}, {'g', 1}, {'a', 1}, {'m', 1} };
std::map<char, int> expected3 = { {'l', 1}, {'a', 2}, {'n', 1}, {'g', 2}, {'u', 1}, {'e', 1} };
... | O3 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r15
push %r14
push %r13
mov %rdi,%r13
push %r12
push %rbp
lea 0x8(%rdi),%rbp
push %rbx
sub $0x18,%rsp
movq $0x0,0x28(%rdi)
mov (%rsi),%r12
mov 0x8(%rsi),%rax
movl $0x0,0x8(%rdi)
mo... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r14
push r13
push r12
mov r12, rdi
push rbp
lea rbp, [rdi+8]
push rbx
sub rsp, 20h
mov rbx, [rsi]
mov rax, fs:28h
mov [rsp+48h+var_30], rax
xor eax, eax
mov qword ptr [rdi+28h], 0
mov r13, [rs... | long long func0(long long a1, long long a2, long long a3, long long a4, long long a5)
{
long long v6; // rbp
char *v7; // rbx
long long v8; // r13
char *v9; // r13
long long i; // rax
long long v11; // rdi
long long v12; // rcx
long long v13; // rdi
long long v14; // rax
long long v15; // rsi
lon... | func0:
ENDBR64
PUSH R14
PUSH R13
PUSH R12
MOV R12,RDI
PUSH RBP
LEA RBP,[RDI + 0x8]
PUSH RBX
SUB RSP,0x20
MOV RBX,qword ptr [RSI]
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x18],RAX
XOR EAX,EAX
MOV qword ptr [RDI + 0x28],0x0
MOV R13,qword ptr [RSI + 0x8]
MOV dword ptr [RDI + 0x8],0x0
ADD R13,RBX
MOV qword ptr [RD... | /* func0(std::string const&) */
string * func0(string *param_1)
{
tuple *ptVar1;
tuple tVar2;
long lVar3;
tuple *ptVar4;
tuple *ptVar5;
tuple *ptVar6;
_Rb_tree_iterator _Var7;
tuple *ptVar8;
tuple *ptVar9;
tuple *ptVar10;
int4 extraout_var_00;
tuple *in_RCX;
char *pcVar11;
int8 *in_RSI;
... |
1,328 | func0 |
#include <iostream>
#include <vector>
#include <algorithm>
#include <assert.h>
using namespace std;
bool compareSecond(const vector<string>& first, const vector<string>& second) {
return stoi(first[1]) < stoi(second[1]);
}
| vector<vector<string>> func0(vector<vector<string>> sub_li) {
sort(sub_li.begin(), sub_li.end(), compareSecond);
return sub_li;
}
| int main() {
vector<vector<string>> result;
vector<vector<string>> expected;
result = func0({{"a", "10"}, {"b", "5"}, {"c", "20"}, {"d", "15"}});
expected = {{"b", "5"}, {"a", "10"}, {"d", "15"}, {"c", "20"}};
assert(result == expected);
result = func0({{"452", "10"}, {"256", "5"},... | O0 | cpp | func0(std::vector<std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >, std::allocator<std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, s... | _Z5func0St6vectorIS_INSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EESaIS7_EE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 18h
mov [rbp+var_18], rdi
mov [rbp+var_20], rsi
mov rax, [rbp+var_20]
mov rdi, rax
call _ZNSt6vectorIS_INSt7__cxx1112basic_stringIcSt11char_traitsIc... | long long func0(long long a1, long long a2)
{
long long v2; // rbx
long long v3; // rax
v2 = std::vector<std::vector<std::string>>::end(a2);
v3 = std::vector<std::vector<std::string>>::begin(a2);
std::sort<__gnu_cxx::__normal_iterator<std::vector<std::string> *,std::vector<std::vector<std::string>>>,bool (*... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x18
MOV qword ptr [RBP + -0x18],RDI
MOV qword ptr [RBP + -0x20],RSI
MOV RAX,qword ptr [RBP + -0x20]
MOV RDI,RAX
CALL 0x00103c40
MOV RBX,RAX
MOV RAX,qword ptr [RBP + -0x20]
MOV RDI,RAX
CALL 0x00103bf4
MOV RCX,RAX
LEA RAX,[0x102529]
MOV RDX,RAX
MOV RSI,RBX
MOV RDI,RCX... | /* func0(std::vector<std::vector<std::string, std::allocator<std::string > >,
std::allocator<std::vector<std::string, std::allocator<std::string > > > >) */
vector<std::vector<std::string,std::allocator<std::string>>,std::allocator<std::vector<std::string,std::allocator<std::string>>>>
* func0(vector<std::vector<st... |
1,329 | func0 |
#include <iostream>
#include <vector>
#include <algorithm>
#include <assert.h>
using namespace std;
bool compareSecond(const vector<string>& first, const vector<string>& second) {
return stoi(first[1]) < stoi(second[1]);
}
| vector<vector<string>> func0(vector<vector<string>> sub_li) {
sort(sub_li.begin(), sub_li.end(), compareSecond);
return sub_li;
}
| int main() {
vector<vector<string>> result;
vector<vector<string>> expected;
result = func0({{"a", "10"}, {"b", "5"}, {"c", "20"}, {"d", "15"}});
expected = {{"b", "5"}, {"a", "10"}, {"d", "15"}, {"c", "20"}};
assert(result == expected);
result = func0({{"452", "10"}, {"256", "5"},... | O1 | cpp | func0(std::vector<std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >, std::allocator<std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, s... | _Z5func0St6vectorIS_INSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EESaIS7_EE:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 8
mov r12, rdi
mov rbp, rsi
mov r13, [rsi+8]
mov r14, [rsi]
cmp r14, r13
jz loc_14D5
mov rbx, r13
sub r... | long long * func0(long long *a1, long long *a2)
{
long long v2; // r13
long long v3; // r14
unsigned long long v4; // rax
int v5; // ecx
unsigned long long v6; // rcx
long long v7; // rbx
int v8; // edx
int v9; // ecx
int v10; // r8d
int v11; // r9d
int v13; // [rsp+0h] [rbp-38h]
char v14; // [r... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x8
MOV R12,RDI
MOV RBP,RSI
MOV R13,qword ptr [RSI + 0x8]
MOV R14,qword ptr [RSI]
CMP R14,R13
JZ 0x001014d5
MOV RBX,R13
SUB RBX,R14
MOV RAX,RBX
SAR RAX,0x3
MOV RDX,-0x5555555555555555
IMUL RAX,RDX
MOV ECX,0x40
TEST RAX,RAX
JZ 0x00101469
BSR RC... | /* func0(std::vector<std::vector<std::string, std::allocator<std::string > >,
std::allocator<std::vector<std::string, std::allocator<std::string > > > >) */
long * func0(long *param_1,long *param_2)
{
long lVar1;
long lVar2;
ulong uVar3;
uint uVar4;
long lVar5;
__normal_iterator _Var6;
lVar1 = par... |
1,330 | func0 |
#include <iostream>
#include <vector>
#include <algorithm>
#include <assert.h>
using namespace std;
bool compareSecond(const vector<string>& first, const vector<string>& second) {
return stoi(first[1]) < stoi(second[1]);
}
| vector<vector<string>> func0(vector<vector<string>> sub_li) {
sort(sub_li.begin(), sub_li.end(), compareSecond);
return sub_li;
}
| int main() {
vector<vector<string>> result;
vector<vector<string>> expected;
result = func0({{"a", "10"}, {"b", "5"}, {"c", "20"}, {"d", "15"}});
expected = {{"b", "5"}, {"a", "10"}, {"d", "15"}, {"c", "20"}};
assert(result == expected);
result = func0({{"452", "10"}, {"256", "5"},... | O2 | cpp | func0(std::vector<std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >, std::allocator<std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, s... | _Z5func0St6vectorIS_INSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EESaIS7_EE:
endbr64
push r15
push r14
push r13
mov r13, rdi
push r12
push rbp
mov rbp, rsi
push rbx
sub rsp, 8
movdqu xmm0, xmmword ptr [rsi]
movhlps xmm1, xmm0
movq r15, xmm0
movq r12, xmm1
cmp r12, ... | __m128 * func0(__m128 *a1, const __m128i *a2, double a3, __m128 a4)
{
__m128 v5; // xmm0
unsigned long long v6; // xmm1_8
unsigned long long v7; // rax
long long v8; // rdx
unsigned long long v9; // rbx
unsigned long long v10; // rdi
long long v11; // rax
__m128 *result; // rax
v5 = (__m128)_mm_loadu... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
MOV R13,RDI
PUSH R12
PUSH RBP
MOV RBP,RSI
PUSH RBX
SUB RSP,0x8
MOVDQU XMM0,xmmword ptr [RSI]
MOVHLPS XMM1,XMM0
MOVQ R15,XMM0
MOVQ R12,XMM1
CMP R12,R15
JZ 0x00102539
MOV RDX,-0x5555555555555555
MOV RBX,R12
SUB RBX,R15
MOV RAX,RBX
SAR RAX,0x3
IMUL RAX,RDX
MOV RDX,-0x2
TEST RAX,RA... | /* func0(std::vector<std::vector<std::string, std::allocator<std::string > >,
std::allocator<std::vector<std::string, std::allocator<std::string > > > >) */
long * func0(long *param_1,int (*param_2) [16])
{
ulong uVar1;
long lVar2;
long lVar3;
__normal_iterator _Var4;
long lVar5;
lVar3 = *(long *)*p... |
1,331 | func0 |
#include <iostream>
#include <vector>
#include <algorithm>
#include <assert.h>
using namespace std;
bool compareSecond(const vector<string>& first, const vector<string>& second) {
return stoi(first[1]) < stoi(second[1]);
}
| vector<vector<string>> func0(vector<vector<string>> sub_li) {
sort(sub_li.begin(), sub_li.end(), compareSecond);
return sub_li;
}
| int main() {
vector<vector<string>> result;
vector<vector<string>> expected;
result = func0({{"a", "10"}, {"b", "5"}, {"c", "20"}, {"d", "15"}});
expected = {{"b", "5"}, {"a", "10"}, {"d", "15"}, {"c", "20"}};
assert(result == expected);
result = func0({{"452", "10"}, {"256", "5"},... | O3 | cpp | func0(std::vector<std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >, std::allocator<std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, s... | _Z5func0St6vectorIS_INSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESaIS5_EESaIS7_EE:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 68h
movdqu xmm0, xmmword ptr [rsi]
mov [rsp+98h+var_88], rdi
mov [rsp+98h+var_80], rsi
movhlps xmm4, xmm0
movq rbp, xmm0
mov... | __m128 * func0(__m128 *a1, const __m128i *a2, double a3, double a4, double a5, double a6, __m128 a7)
{
__m128 v7; // xmm0
unsigned long long v8; // xmm4_8
const __m128i *v9; // rbp
__m128i *v10; // r14
unsigned long long v11; // rax
unsigned long long v12; // r13
long long v13; // r13
__m128i *v14; // r... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x68
MOVDQU XMM0,xmmword ptr [RSI]
MOV qword ptr [RSP + 0x10],RDI
MOV qword ptr [RSP + 0x18],RSI
MOVHLPS XMM4,XMM0
MOVQ RBP,XMM0
MOVQ R14,XMM4
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x58],RAX
XOR EAX,EAX
MOVQ qword ptr [RSP],XMM4
CMP... | /* func0(std::vector<std::vector<std::string, std::allocator<std::string > >,
std::allocator<std::vector<std::string, std::allocator<std::string > > > >) */
int8 * func0(int8 *param_1,int (*param_2) [16])
{
int8 uVar1;
__normal_iterator _Var2;
int8 uVar3;
int8 uVar4;
int8 uVar5;
code *pcVar6;
code *p... |
1,332 | func0 |
#include <assert.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 | cpp | func0(int, int, int):
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 <_Z5func0iii+0x38>
mov -0x4(%rbp),%edx
mov -0xc(%rbp),%eax
add %edx,%eax
cmp %eax,... | _Z5func0iii:
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+... | _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... | /* func0(int, int, int) */
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;
} |
1,333 | func0 |
#include <assert.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 | cpp | func0(int, int, int):
endbr64
lea (%rdi,%rsi,1),%ecx
mov $0x0,%eax
cmp %edx,%ecx
jle 1147 <_Z5func0iii+0x1e>
lea (%rdi,%rdx,1),%ecx
cmp %esi,%ecx
jle 1147 <_Z5func0iii+0x1e>
add %edx,%esi
cmp %edi,%esi
setg %al
retq
| _Z5func0iii:
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 | /* func0(int, int, int) */
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;
} |
1,334 | func0 |
#include <assert.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 | cpp | func0(int, int, int):
endbr64
lea (%rdi,%rsi,1),%ecx
xor %eax,%eax
cmp %edx,%ecx
jle 115b <_Z5func0iii+0x1b>
lea (%rdi,%rdx,1),%ecx
cmp %esi,%ecx
jle 115b <_Z5func0iii+0x1b>
add %edx,%esi
cmp %edi,%esi
setg %al
retq
nopl 0x0(%rax)
| _Z5func0iii:
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 | /* func0(int, int, int) */
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;
} |
1,335 | func0 |
#include <assert.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 | cpp | func0(int, int, int):
endbr64
lea (%rdi,%rsi,1),%ecx
xor %eax,%eax
cmp %edx,%ecx
jle 115b <_Z5func0iii+0x1b>
lea (%rdi,%rdx,1),%ecx
cmp %esi,%ecx
jle 115b <_Z5func0iii+0x1b>
add %edx,%esi
cmp %edi,%esi
setg %al
retq
nopl 0x0(%rax)
| _Z5func0iii:
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 | /* func0(int, int, int) */
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;
} |
1,336 | func0 |
#include <cassert>
| double func0(int a, int n, int d) {
double total = (n * (2 * a + (n - 1) * d)) / 2;
return total;
}
| int main() {
assert(func0(1, 5, 2) == 25);
assert(func0(2, 6, 4) == 72);
assert(func0(1, 4, 5) == 34);
return 0;
}
| O0 | cpp | func0(int, int, int):
endbr64
push %rbp
mov %rsp,%rbp
mov %edi,-0x14(%rbp)
mov %esi,-0x18(%rbp)
mov %edx,-0x1c(%rbp)
mov -0x14(%rbp),%eax
lea (%rax,%rax,1),%edx
mov -0x18(%rbp),%eax
sub $0x1,%eax
imul -0x1c(%rbp),%eax
add %edx,%eax
imul -0x18(%rbp),%eax
mov %eax,%edx
shr $0x1f,%ed... | _Z5func0iii:
endbr64
push rbp
mov rbp, rsp
mov [rbp+var_14], edi
mov [rbp+var_18], esi
mov [rbp+var_1C], edx
mov eax, [rbp+var_14]
lea edx, [rax+rax]
mov eax, [rbp+var_18]
sub eax, 1
imul eax, [rbp+var_1C]
add eax, edx
imul eax, [rbp+var_18]
mov edx, eax
shr edx, 1Fh... | double func0(int a1, int a2, int a3)
{
return (double)(a2 * (2 * a1 + a3 * (a2 - 1)) / 2);
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
MOV dword ptr [RBP + -0x14],EDI
MOV dword ptr [RBP + -0x18],ESI
MOV dword ptr [RBP + -0x1c],EDX
MOV EAX,dword ptr [RBP + -0x14]
LEA EDX,[RAX + RAX*0x1]
MOV EAX,dword ptr [RBP + -0x18]
SUB EAX,0x1
IMUL EAX,dword ptr [RBP + -0x1c]
ADD EAX,EDX
IMUL EAX,dword ptr [RBP + -0x18]
MOV EDX,EA... | /* func0(int, int, int) */
double func0(int param_1,int param_2,int param_3)
{
return (double)((((param_2 + -1) * param_3 + param_1 * 2) * param_2) / 2);
} |
1,337 | func0 |
#include <cassert>
| double func0(int a, int n, int d) {
double total = (n * (2 * a + (n - 1) * d)) / 2;
return total;
}
| int main() {
assert(func0(1, 5, 2) == 25);
assert(func0(2, 6, 4) == 72);
assert(func0(1, 4, 5) == 34);
return 0;
}
| O1 | cpp | func0(int, int, int):
endbr64
mov %esi,%eax
mov %edx,%ecx
lea -0x1(%rsi),%edx
imul %ecx,%edx
lea (%rdx,%rdi,2),%esi
imul %esi,%eax
mov %eax,%esi
shr $0x1f,%esi
add %eax,%esi
sar %esi
pxor %xmm0,%xmm0
cvtsi2sd %esi,%xmm0
retq
| _Z5func0iii:
endbr64
lea eax, [rsi-1]
imul eax, edx
lea eax, [rax+rdi*2]
imul eax, esi
mov esi, eax
shr esi, 1Fh
add esi, eax
sar esi, 1
pxor xmm0, xmm0
cvtsi2sd xmm0, esi
retn | double func0(int a1, int a2, int a3)
{
return (double)(a2 * (a3 * (a2 - 1) + 2 * a1) / 2);
} | func0:
ENDBR64
LEA EAX,[RSI + -0x1]
IMUL EAX,EDX
LEA EAX,[RAX + RDI*0x2]
IMUL EAX,ESI
MOV ESI,EAX
SHR ESI,0x1f
ADD ESI,EAX
SAR ESI,0x1
PXOR XMM0,XMM0
CVTSI2SD XMM0,ESI
RET | /* func0(int, int, int) */
double func0(int param_1,int param_2,int param_3)
{
return (double)((((param_2 + -1) * param_3 + param_1 * 2) * param_2) / 2);
} |
1,338 | func0 |
#include <cassert>
| double func0(int a, int n, int d) {
double total = (n * (2 * a + (n - 1) * d)) / 2;
return total;
}
| int main() {
assert(func0(1, 5, 2) == 25);
assert(func0(2, 6, 4) == 72);
assert(func0(1, 4, 5) == 34);
return 0;
}
| O2 | cpp | func0(int, int, int):
endbr64
mov %edx,%r8d
lea -0x1(%rsi),%edx
pxor %xmm0,%xmm0
mov %esi,%eax
imul %r8d,%edx
lea (%rdx,%rdi,2),%esi
imul %esi,%eax
mov %eax,%esi
shr $0x1f,%esi
add %eax,%esi
sar %esi
cvtsi2sd %esi,%xmm0
retq
nopl 0x0(%rax,%rax,1)
| _Z5func0iii:
endbr64
lea eax, [rsi-1]
pxor xmm0, xmm0
imul eax, edx
lea eax, [rax+rdi*2]
imul eax, esi
mov esi, eax
shr esi, 1Fh
add esi, eax
sar esi, 1
cvtsi2sd xmm0, esi
retn | double func0(int a1, int a2, int a3)
{
return (double)(a2 * (a3 * (a2 - 1) + 2 * a1) / 2);
} | func0:
ENDBR64
LEA EAX,[RSI + -0x1]
PXOR XMM0,XMM0
IMUL EAX,EDX
LEA EAX,[RAX + RDI*0x2]
IMUL EAX,ESI
MOV ESI,EAX
SHR ESI,0x1f
ADD ESI,EAX
SAR ESI,0x1
CVTSI2SD XMM0,ESI
RET | /* func0(int, int, int) */
double func0(int param_1,int param_2,int param_3)
{
return (double)((((param_2 + -1) * param_3 + param_1 * 2) * param_2) / 2);
} |
1,339 | func0 |
#include <cassert>
| double func0(int a, int n, int d) {
double total = (n * (2 * a + (n - 1) * d)) / 2;
return total;
}
| int main() {
assert(func0(1, 5, 2) == 25);
assert(func0(2, 6, 4) == 72);
assert(func0(1, 4, 5) == 34);
return 0;
}
| O3 | cpp | func0(int, int, int):
endbr64
mov %edx,%r8d
lea -0x1(%rsi),%edx
pxor %xmm0,%xmm0
mov %esi,%eax
imul %r8d,%edx
lea (%rdx,%rdi,2),%esi
imul %esi,%eax
mov %eax,%esi
shr $0x1f,%esi
add %eax,%esi
sar %esi
cvtsi2sd %esi,%xmm0
retq
nopl 0x0(%rax,%rax,1)
| _Z5func0iii:
endbr64
lea eax, [rsi-1]
pxor xmm0, xmm0
imul eax, edx
lea eax, [rax+rdi*2]
imul eax, esi
mov esi, eax
shr esi, 1Fh
add esi, eax
sar esi, 1
cvtsi2sd xmm0, esi
retn | double func0(int a1, int a2, int a3)
{
return (double)(a2 * (a3 * (a2 - 1) + 2 * a1) / 2);
} | func0:
ENDBR64
LEA EAX,[RSI + -0x1]
PXOR XMM0,XMM0
IMUL EAX,EDX
LEA EAX,[RAX + RDI*0x2]
IMUL EAX,ESI
MOV ESI,EAX
SHR ESI,0x1f
ADD ESI,EAX
SAR ESI,0x1
CVTSI2SD XMM0,ESI
RET | /* func0(int, int, int) */
double func0(int param_1,int param_2,int param_3)
{
return (double)((((param_2 + -1) * param_3 + param_1 * 2) * param_2) / 2);
} |
1,340 | func0 |
#include <cassert>
#include <string>
| bool func0(std::string monthname1) {
if (monthname1 == "February") {
return true;
} else {
return false;
}
}
| int main() {
assert(func0("February") == true);
assert(func0("January") == false);
assert(func0("March") == false);
return 0;
}
| O0 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >):
endbr64
push %rbp
mov %rsp,%rbp
sub $0x10,%rsp
mov %rdi,-0x8(%rbp)
mov -0x8(%rbp),%rax
lea 0xc24(%rip),%rsi
mov %rax,%rdi
callq 16e5 <_ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_>... | _Z5func0NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push rbp
mov rbp, rsp
sub rsp, 10h
mov [rbp+var_8], rdi
mov rax, [rbp+var_8]
lea rdx, aFebruary; "February"
mov rsi, rdx
mov rdi, rax
call _ZSteqIcSt11char_traitsIcESaIcEEbRKNSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_;... | _BOOL8 func0(long long a1)
{
return (unsigned __int8)std::operator==<char>(a1, "February") != 0;
} | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x10
MOV qword ptr [RBP + -0x8],RDI
MOV RAX,qword ptr [RBP + -0x8]
LEA RDX,[0x102008]
MOV RSI,RDX
MOV RDI,RAX
CALL 0x001017ec
TEST AL,AL
JZ 0x0010139a
MOV EAX,0x1
JMP 0x0010139f
LAB_0010139a:
MOV EAX,0x0
LAB_0010139f:
LEAVE
RET | /* func0(std::string) */
bool func0(string *param_1)
{
bool bVar1;
bVar1 = std::operator==(param_1,"February");
return bVar1;
} |
1,341 | func0 |
#include <cassert>
#include <string>
| bool func0(std::string monthname1) {
if (monthname1 == "February") {
return true;
} else {
return false;
}
}
| int main() {
assert(func0("February") == true);
assert(func0("January") == false);
assert(func0("March") == false);
return 0;
}
| O1 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >):
endbr64
sub $0x8,%rsp
lea 0xdec(%rip),%rsi
callq 10b0 <_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc@plt>
test %eax,%eax
sete %al
add $0x8,%rsp
retq
| _Z5func0NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
mov eax, 0
cmp qword ptr [rdi+8], 8
jz short loc_123A
retn
loc_123A:
sub rsp, 8
mov rdi, [rdi]; s1
mov edx, 8; n
lea rsi, aFebruary; "February"
call _memcmp
test eax, eax
setz al
add rsp, 8
retn | bool func0(long long a1)
{
bool result; // al
result = 0;
if ( *(_QWORD *)(a1 + 8) == 8LL )
return memcmp(*(const void **)a1, "February", 8uLL) == 0;
return result;
} | func0:
ENDBR64
MOV EAX,0x0
CMP qword ptr [RDI + 0x8],0x8
JZ 0x0010123a
RET
LAB_0010123a:
SUB RSP,0x8
MOV RDI,qword ptr [RDI]
MOV EDX,0x8
LEA RSI,[0x102004]
CALL 0x001010d0
TEST EAX,EAX
SETZ AL
ADD RSP,0x8
RET | /* func0(std::string) */
int8 func0(int8 *param_1)
{
int iVar1;
int4 extraout_var;
if (param_1[1] != 8) {
return 0;
}
iVar1 = memcmp((void *)*param_1,"February",8);
return CONCAT71((int7)(CONCAT44(extraout_var,iVar1) >> 8),iVar1 == 0);
} |
1,342 | func0 |
#include <cassert>
#include <string>
| bool func0(std::string monthname1) {
if (monthname1 == "February") {
return true;
} else {
return false;
}
}
| int main() {
assert(func0("February") == true);
assert(func0("January") == false);
assert(func0("March") == false);
return 0;
}
| O2 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >):
endbr64
sub $0x8,%rsp
lea 0xc75(%rip),%rsi
callq 10c0 <_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc@plt>
test %eax,%eax
sete %al
add $0x8,%rsp
retq
xchg %ax,%ax
| _Z5func0NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
xor eax, eax
cmp qword ptr [rdi+8], 8
jz short loc_1370
retn
loc_1370:
mov rax, 7972617572626546h
mov rdx, [rdi]
cmp [rdx], rax
setz al
retn | bool func0(long long a1)
{
bool result; // al
result = 0;
if ( *(_QWORD *)(a1 + 8) == 8LL )
return **(_QWORD **)a1 == 0x7972617572626546LL;
return result;
} | func0:
ENDBR64
XOR EAX,EAX
CMP qword ptr [RDI + 0x8],0x8
JZ 0x00101370
RET
LAB_00101370:
MOV RAX,0x7972617572626546
MOV RDX,qword ptr [RDI]
CMP qword ptr [RDX],RAX
SETZ AL
RET | /* func0(std::string) */
int8 func0(int8 *param_1)
{
if (param_1[1] != 8) {
return 0;
}
return CONCAT71(0x79726175726265,*(long *)*param_1 == 0x7972617572626546);
} |
1,343 | func0 |
#include <cassert>
#include <string>
| bool func0(std::string monthname1) {
if (monthname1 == "February") {
return true;
} else {
return false;
}
}
| int main() {
assert(func0("February") == true);
assert(func0("January") == false);
assert(func0("March") == false);
return 0;
}
| O3 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >):
endbr64
sub $0x8,%rsp
lea 0xc75(%rip),%rsi
callq 10c0 <_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE7compareEPKc@plt>
test %eax,%eax
sete %al
add $0x8,%rsp
retq
xchg %ax,%ax
| _Z5func0NSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
xor eax, eax
cmp qword ptr [rdi+8], 8
jz short loc_1370
retn
loc_1370:
mov rax, 7972617572626546h
mov rdx, [rdi]
cmp [rdx], rax
setz al
retn | bool func0(long long a1)
{
bool result; // al
result = 0;
if ( *(_QWORD *)(a1 + 8) == 8LL )
return **(_QWORD **)a1 == 0x7972617572626546LL;
return result;
} | func0:
ENDBR64
XOR EAX,EAX
CMP qword ptr [RDI + 0x8],0x8
JZ 0x00101370
RET
LAB_00101370:
MOV RAX,0x7972617572626546
MOV RDX,qword ptr [RDI]
CMP qword ptr [RDX],RAX
SETZ AL
RET | /* func0(std::string) */
int8 func0(int8 *param_1)
{
if (param_1[1] != 8) {
return 0;
}
return CONCAT71(0x79726175726265,*(long *)*param_1 == 0x7972617572626546);
} |
1,344 | func0 |
#include <iostream>
#include <regex>
#include <string>
#include <assert.h>
| std::string func0(const std::string &text) {
std::regex pattern("\\w+\\S*$");
if (std::regex_search(text, pattern)) {
return "Found a match!";
} else {
return "Not matched!";
}
}
| int main() {
assert(func0("python.") == "Found a match!");
assert(func0(" lang .") == "Not matched!");
return 0;
}
| O0 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x58,%rsp
mov %rdi,-0x58(%rbp)
mov %rsi,-0x60(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
lea -0x40(%rbp),%rax
mov $0x10,%edx
lea ... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 68h
mov [rbp+var_68], rdi
mov [rbp+var_70], rsi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
lea rax, [rbp+var_40]
mov edx, 10h
lea rcx, aWS; "\\w+\\S*$"
mo... | long long func0(long long a1, long long a2)
{
char v3; // [rsp+1Fh] [rbp-51h] BYREF
char *v4; // [rsp+20h] [rbp-50h]
char *v5; // [rsp+28h] [rbp-48h]
_BYTE v6[40]; // [rsp+30h] [rbp-40h] BYREF
unsigned long long v7; // [rsp+58h] [rbp-18h]
v7 = __readfsqword(0x28u);
std::basic_regex<char,std::regex_trait... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x68
MOV qword ptr [RBP + -0x68],RDI
MOV qword ptr [RBP + -0x70],RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
LEA RAX,[RBP + -0x40]
MOV EDX,0x10
LEA RCX,[0x132051]
MOV RSI,RCX
MOV RDI,RAX
LAB_00104b43:
CALL 0x001060be
LEA RCX,[RBP + -0x... | /* func0(std::string const&) */
string * func0(string *param_1)
{
bool bVar1;
string *in_RSI;
long in_FS_OFFSET;
allocator local_59;
allocator *local_58;
allocator *local_50;
regex local_48 [40];
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
std::regex::basic_regex(local_48,"\\w+\\S... |
1,345 | func0 |
#include <iostream>
#include <regex>
#include <string>
#include <assert.h>
| std::string func0(const std::string &text) {
std::regex pattern("\\w+\\S*$");
if (std::regex_search(text, pattern)) {
return "Found a match!";
} else {
return "Not matched!";
}
}
| int main() {
assert(func0("python.") == "Found a match!");
assert(func0(" lang .") == "Not matched!");
return 0;
}
| O1 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r13
push %r12
push %rbp
push %rbx
sub $0x58,%rsp
mov %rdi,%rbx
mov %rsi,%rbp
mov %fs:0x28,%rax
mov %rax,0x48(%rsp)
xor %eax,%eax
lea 0x20(%rsp),%r13
mov %r13,%rdi
callq 4730 <_ZN... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push rbp
mov rbp, rsp
push r14
push r12
push rbx
sub rsp, 58h
mov rbx, rdi
mov r14, rsi
mov rax, fs:28h
mov [rbp+var_28], rax
xor eax, eax
lea r12, [rbp+var_70]
lea rdi, [rbp+var_68]; this
call __Z... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH R14
PUSH R12
PUSH RBX
SUB RSP,0x58
MOV RBX,RDI
MOV R14,RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x28],RAX
XOR EAX,EAX
LEA R12,[RBP + -0x70]
LEA RDI,[RBP + -0x68]
CALL 0x001046f0
MOV qword ptr [RBP + -0x60],0x0
MOV qword ptr [RBP + -0x58],0x0
MOV ECX,0x10
LEA RDX,[0x... | /* func0(std::string const&) */
string * func0(string *param_1)
{
_Sp_counted_base<(_Lock_policy)2> *p_Var1;
_Sp_counted_base<(_Lock_policy)2> *p_Var2;
bool bVar3;
int iVar4;
int8 *in_RSI;
long in_FS_OFFSET;
regex local_78 [8];
int local_70 [8];
int8 local_68;
_Sp_counted_base<(_Lock_policy)2> *lo... | |
1,346 | func0 |
#include <iostream>
#include <regex>
#include <string>
#include <assert.h>
| std::string func0(const std::string &text) {
std::regex pattern("\\w+\\S*$");
if (std::regex_search(text, pattern)) {
return "Found a match!";
} else {
return "Not matched!";
}
}
| int main() {
assert(func0("python.") == "Found a match!");
assert(func0(" lang .") == "Not matched!");
return 0;
}
| O2 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r14
push %r13
push %r12
mov %rdi,%r12
push %rbp
push %rbx
mov %rsi,%rbx
sub $0x50,%rsp
mov %fs:0x28,%rax
mov %rax,0x48(%rsp)
xor %eax,%eax
lea 0x20(%rsp),%r13
lea 0x8(%rsp),%rbp... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push rbp
mov rbp, rsp
push r14
mov r14, rsi
push r13
lea r13, [rbp+var_70]
push r12
lea r12, [rbp+var_68]
push rbx
mov rbx, rdi
mov rdi, r12; this
sub rsp, 50h
mov rax, fs:28h
mov [rbp+var_28], rax... | _QWORD * func0(_QWORD *a1, long long *a2)
{
long long v3; // rdi
long long v4; // rsi
char v5; // r14
char *v6; // rsi
long long v7; // rdi
long long v8; // rdx
volatile signed __int32 *v9; // rcx
signed __int32 v10; // eax
long long v12; // rax
_BYTE v13[8]; // [rsp+0h] [rbp-70h] BYREF
_BYTE v14[... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH R14
MOV R14,RSI
PUSH R13
LEA R13,[RBP + -0x70]
PUSH R12
LEA R12,[RBP + -0x68]
PUSH RBX
MOV RBX,RDI
MOV RDI,R12
SUB RSP,0x50
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x28],RAX
XOR EAX,EAX
CALL 0x001036d0
LEA RDX,[0x11862e]
PXOR XMM0,XMM0
MOV RDI,R13
MOV ECX,0x10
LEA RSI,... | /* func0(std::string const&) */
string * func0(string *param_1)
{
_Sp_counted_base<(_Lock_policy)2> *p_Var1;
int8 uVar2;
bool bVar3;
int iVar4;
int8 *in_RSI;
long in_FS_OFFSET;
regex local_78 [8];
int local_70 [8];
int local_68 [16];
int local_58 [16];
int local_48 [16];
long local_30;
lo... |
1,347 | func0 |
#include <iostream>
#include <regex>
#include <string>
#include <assert.h>
| std::string func0(const std::string &text) {
std::regex pattern("\\w+\\S*$");
if (std::regex_search(text, pattern)) {
return "Found a match!";
} else {
return "Not matched!";
}
}
| int main() {
assert(func0("python.") == "Found a match!");
assert(func0(" lang .") == "Not matched!");
return 0;
}
| O3 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r14
push %r13
push %r12
mov %rdi,%r12
push %rbp
push %rbx
mov %rsi,%rbx
sub $0x50,%rsp
mov %fs:0x28,%rax
mov %rax,0x48(%rsp)
xor %eax,%eax
lea 0x20(%rsp),%r13
lea 0x8(%rsp),%rbp... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r15
mov r15, rsi
push r14
push r13
push r12
push rbp
push rbx
mov rbx, rdi
sub rsp, 2B8h
mov rax, fs:28h
mov [rsp+2E8h+var_40], rax
xor eax, eax
lea r14, [rsp+2E8h+var_2A0]
mov rdi, r14; this
c... | long long func0(long long a1, unsigned long long *a2)
{
__m128i v3; // xmm0
long long v4; // rdi
void *v5; // rdi
void **v6; // rbp
unsigned long long v7; // r12
void *v8; // rdi
unsigned long long v9; // r13
unsigned long long v10; // rbp
long long v11; // rax
long long v12; // rcx
unsigned long... | func0:
ENDBR64
PUSH R15
MOV R15,RSI
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
MOV RBX,RDI
SUB RSP,0x2b8
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x2a8],RAX
XOR EAX,EAX
LEA R14,[RSP + 0x48]
MOV RDI,R14
CALL 0x00104730
LEA RDX,[0x11a673]
PXOR XMM0,XMM0
LEA RDI,[RSP + 0x110]
MOV R8D,0x10
MOV RCX,R14
LEA RSI,[RD... | /* func0(std::string const&) */
string * func0(string *param_1)
{
ulong uVar1;
int8 uVar2;
ulong uVar3;
int auVar4 [16];
bool bVar5;
char cVar6;
long lVar7;
int8 *puVar8;
int8 *puVar9;
ulong uVar10;
ulong *puVar11;
long lVar12;
ulong uVar13;
ulong *in_RSI;
uint *puVar14;
_Match_mode _V... |
1,348 | func0 |
#include <iostream>
#include <string>
#include <assert.h>
| int func0(const std::string& s) {
int result = 0;
int n = s.length();
for (int i = 0; i < n; ++i) {
for (int j = 1; j <= n - i; ++j) {
std::string substr = s.substr(i, j);
if (substr[0] == substr[substr.length() - 1]) {
result++;
}
... | int main() {
assert(func0("aba") == 4);
assert(func0("abcab") == 7);
assert(func0("abc") == 3);
return 0;
}
| O0 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x58,%rsp
mov %rdi,-0x58(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
movl $0x0,-0x50(%rbp)
mov -0x58(%rbp),%rax
mov %rax,%rdi
callq ... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 58h
mov [rbp+var_58], rdi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
mov [rbp+var_50], 0
mov rax, [rbp+var_58]
mov rdi, rax
call __ZNKSt7__cxx1112basic_str... | long long func0(long long a1)
{
char v1; // bl
long long v2; // rax
unsigned int v4; // [rsp+10h] [rbp-50h]
int i; // [rsp+14h] [rbp-4Ch]
int j; // [rsp+18h] [rbp-48h]
int v7; // [rsp+1Ch] [rbp-44h]
_BYTE v8[40]; // [rsp+20h] [rbp-40h] BYREF
unsigned long long v9; // [rsp+48h] [rbp-18h]
v9 = __readf... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x58
MOV qword ptr [RBP + -0x58],RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
MOV dword ptr [RBP + -0x50],0x0
MOV RAX,qword ptr [RBP + -0x58]
MOV RDI,RAX
CALL 0x00101230
MOV dword ptr [RBP + -0x44],EAX
MOV dword ptr [RBP + -0x4c],0x0
JM... | /* func0(std::string const&) */
int func0(string *param_1)
{
char cVar1;
int iVar2;
char *pcVar3;
long in_FS_OFFSET;
int local_58;
int local_54;
int local_50;
string local_48 [40];
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
local_58 = 0;
iVar2 = std::string::length();
for (... |
1,349 | func0 |
#include <iostream>
#include <string>
#include <assert.h>
| int func0(const std::string& s) {
int result = 0;
int n = s.length();
for (int i = 0; i < n; ++i) {
for (int j = 1; j <= n - i; ++j) {
std::string substr = s.substr(i, j);
if (substr[0] == substr[substr.length() - 1]) {
result++;
}
... | int main() {
assert(func0("aba") == 4);
assert(func0("abcab") == 7);
assert(func0("abc") == 3);
return 0;
}
| O1 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x48,%rsp
mov %fs:0x28,%rax
mov %rax,0x38(%rsp)
xor %eax,%eax
mov 0x8(%rdi),%rax
test %eax,%eax
jle 1351 <_Z5func0RKNSt7... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 48h
mov rax, fs:28h
mov [rsp+78h+var_40], rax
xor eax, eax
mov rax, [rdi+8]
test eax, eax
jle loc_1374
mov r12, rdi
mov [rsp+78h+var... | long long func0(_QWORD *a1)
{
unsigned long long v1; // rbp
unsigned int v2; // r15d
unsigned long long v3; // rbx
unsigned long long v4; // rcx
unsigned long long v5; // rcx
int v7; // [rsp+Ch] [rbp-6Ch]
void *v8[2]; // [rsp+10h] [rbp-68h] BYREF
_QWORD v9[11]; // [rsp+20h] [rbp-58h] BYREF
v9[3] = _... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x48
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x38],RAX
XOR EAX,EAX
MOV RAX,qword ptr [RDI + 0x8]
TEST EAX,EAX
JLE 0x00101374
MOV R12,RDI
MOV dword ptr [RSP + 0xc],EAX
MOV EBP,0x0
MOV R15D,0x0
LEA R14,[RSP + 0x10]
JMP 0x00101359
LAB_00... | /* func0(std::string const&) */
int func0(string *param_1)
{
ulong uVar1;
ulong uVar2;
ulong uVar3;
int iVar4;
long in_FS_OFFSET;
int local_6c;
long *local_68;
long local_60;
long local_58 [3];
long local_40;
local_40 = *(long *)(in_FS_OFFSET + 0x28);
local_6c = (int)*(int8 *)(param_1 + 8);... |
1,350 | func0 |
#include <iostream>
#include <string>
#include <assert.h>
| int func0(const std::string& s) {
int result = 0;
int n = s.length();
for (int i = 0; i < n; ++i) {
for (int j = 1; j <= n - i; ++j) {
std::string substr = s.substr(i, j);
if (substr[0] == substr[substr.length() - 1]) {
result++;
}
... | int main() {
assert(func0("aba") == 4);
assert(func0("abcab") == 7);
assert(func0("abc") == 3);
return 0;
}
| O2 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x48,%rsp
mov 0x8(%rdi),%rdx
mov %fs:0x28,%rax
mov %rax,0x38(%rsp)
xor %eax,%eax
test %edx,%edx
jle 1537 <_Z5func0RKNSt7... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 68h
mov rbx, [rdi+8]
mov rax, fs:28h
mov [rsp+98h+var_40], rax
xor eax, eax
test ebx, ebx
jle loc_154E
lea eax, [rbx-1]
mov rbp, rdi... | long long func0(long long *a1)
{
unsigned long long v1; // rbx
int v3; // r12d
unsigned long long v4; // r15
unsigned long long v5; // r14
_QWORD *v6; // rax
long long v7; // r11
size_t v8; // rbx
_BYTE *v9; // r11
void *v10; // rax
_QWORD *v11; // rdi
_BYTE *src; // [rsp+0h] [rbp-98h]
unsigned... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x68
MOV RBX,qword ptr [RDI + 0x8]
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x58],RAX
XOR EAX,EAX
TEST EBX,EBX
JLE 0x0010154e
LEA EAX,[RBX + -0x1]
MOV RBP,RDI
MOV R12D,EBX
XOR R15D,R15D
MOV qword ptr [RSP + 0x18],RAX
LEA RAX,[RSP + 0x3... | /* func0(std::string const&) */
int func0(string *param_1)
{
long lVar1;
int iVar2;
ulong uVar3;
ulong __n;
ulong uVar4;
ulong uVar5;
ulong uVar6;
long in_FS_OFFSET;
int local_8c;
ulong local_70;
ulong *local_68;
ulong local_60;
ulong local_58 [3];
long local_40;
uVar3 = *(ulong *)(pa... |
1,351 | func0 |
#include <iostream>
#include <string>
#include <assert.h>
| int func0(const std::string& s) {
int result = 0;
int n = s.length();
for (int i = 0; i < n; ++i) {
for (int j = 1; j <= n - i; ++j) {
std::string substr = s.substr(i, j);
if (substr[0] == substr[substr.length() - 1]) {
result++;
}
... | int main() {
assert(func0("aba") == 4);
assert(func0("abcab") == 7);
assert(func0("abc") == 3);
return 0;
}
| O3 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x68,%rsp
mov 0x8(%rdi),%r12
mov %fs:0x28,%rax
mov %rax,0x58(%rsp)
xor %eax,%eax
test %r12d,%r12d
jle 15d7 <_Z5func0RKNS... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 68h
mov rbx, [rdi+8]
mov rax, fs:28h
mov [rsp+98h+var_40], rax
xor eax, eax
test ebx, ebx
jle loc_155E
lea eax, [rbx-1]
mov rbp, rdi... | long long func0(long long *a1)
{
unsigned long long v1; // rbx
int v3; // r12d
unsigned long long v4; // r15
unsigned long long v5; // r14
_QWORD *v6; // rax
long long v7; // r11
size_t v8; // rbx
_BYTE *v9; // r11
void *v10; // rax
_QWORD *v11; // rdi
_BYTE *src; // [rsp+0h] [rbp-98h]
unsigned... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x68
MOV RBX,qword ptr [RDI + 0x8]
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x58],RAX
XOR EAX,EAX
TEST EBX,EBX
JLE 0x0010155e
LEA EAX,[RBX + -0x1]
MOV RBP,RDI
MOV R12D,EBX
XOR R15D,R15D
MOV qword ptr [RSP + 0x18],RAX
LEA RAX,[RSP + 0x3... | /* func0(std::string const&) */
int func0(string *param_1)
{
long lVar1;
int iVar2;
ulong uVar3;
ulong __n;
ulong uVar4;
ulong uVar5;
ulong uVar6;
long in_FS_OFFSET;
int local_8c;
ulong local_70;
ulong *local_68;
ulong local_60;
ulong local_58 [3];
long local_40;
uVar3 = *(ulong *)(pa... |
1,352 | func0 |
#include <iostream>
#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 | cpp | func0(int, int):
endbr64
push %rbp
mov %rsp,%rbp
mov %edi,-0x4(%rbp)
mov %esi,-0x8(%rbp)
mov -0x4(%rbp),%eax
cmp -0x8(%rbp),%eax
jne 11a4 <_Z5func0ii+0x1b>
mov -0x8(%rbp),%eax
jmp 11a9 <_Z5func0ii+0x20>
mov $0x2,%eax
pop %rbp
retq
| _Z5func0ii:
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 | /* func0(int, int) */
int func0(int param_1,int param_2)
{
if (param_1 != param_2) {
param_2 = 2;
}
return param_2;
} |
1,353 | func0 |
#include <iostream>
#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 | cpp | func0(int, int):
endbr64
cmp %esi,%edi
mov $0x2,%eax
cmove %esi,%eax
retq
| _Z5func0ii:
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 | /* func0(int, int) */
int func0(int param_1,int param_2)
{
int iVar1;
iVar1 = 2;
if (param_1 == param_2) {
iVar1 = param_2;
}
return iVar1;
} |
1,354 | func0 |
#include <iostream>
#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 | cpp | func0(int, int):
endbr64
cmp %esi,%edi
mov $0x2,%eax
cmove %edi,%eax
retq
| _Z5func0ii:
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 | /* func0(int, int) */
int func0(int param_1,int param_2)
{
int iVar1;
iVar1 = 2;
if (param_1 == param_2) {
iVar1 = param_1;
}
return iVar1;
} |
1,355 | func0 |
#include <iostream>
#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 | cpp | func0(int, int):
endbr64
cmp %esi,%edi
mov $0x2,%eax
cmove %edi,%eax
retq
| _Z5func0ii:
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 | /* func0(int, int) */
int func0(int param_1,int param_2)
{
int iVar1;
iVar1 = 2;
if (param_1 == param_2) {
iVar1 = param_1;
}
return iVar1;
} |
1,356 | func0 |
#include <iostream>
#include <vector>
#include <algorithm>
#include <assert.h>
| int func0(const std::vector<int>& lst) {
std::vector<int> positive_numbers;
for (int num : lst) {
if (num > 0) {
positive_numbers.push_back(num);
}
}
std::sort(positive_numbers.begin(), positive_numbers.end());
int sum = 0;
for (int i = 0; i < 3... | int main() {
assert(func0({10,20,30,40,50,60,7}) == 37);
assert(func0({1,2,3,4,5}) == 6);
assert(func0({0,1,2,3,4,5}) == 6);
return 0;
}
| O0 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x68,%rsp
mov %rdi,-0x68(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
lea -0x30(%rbp),%rax
mov %rax,%rdi
callq 1842 <_ZNSt6vectorIiSaIiEEC1Ev>
mov -0x68(%rbp),%rax
mov %r... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 68h
mov [rbp+var_68], rdi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
lea rax, [rbp+var_30]
mov rdi, rax
call _ZNSt6vectorIiSaIiEEC2Ev; std::vector<int>::vector(void)
mov rax, [rbp+var_68]
mo... | long long func0(long long a1)
{
long long v1; // rbx
long long v2; // rax
_DWORD *v3; // rax
unsigned long long v4; // rbx
unsigned int v6; // ebx
int v8; // [rsp+1Ch] [rbp-54h] BYREF
unsigned int v9; // [rsp+20h] [rbp-50h]
int i; // [rsp+24h] [rbp-4Ch]
long long v11; // [rsp+28h] [rbp-48h] BYREF
_... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x68
MOV qword ptr [RBP + -0x68],RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
LEA RAX,[RBP + -0x30]
MOV RDI,RAX
CALL 0x001017c2
MOV RAX,qword ptr [RBP + -0x68]
MOV qword ptr [RBP + -0x38],RAX
MOV RAX,qword ptr [RBP + -0x38]
MOV RDI,RAX
... | /* func0(std::vector<int, std::allocator<int> > const&) */
int func0(vector *param_1)
{
int iVar1;
bool bVar2;
int8 uVar3;
int8 uVar4;
int *piVar5;
ulong uVar6;
ulong uVar7;
long in_FS_OFFSET;
int local_5c;
int local_58;
int local_54;
int8 local_50;
int8 local_48;
vector<int,std::allocator... |
1,357 | func0 |
#include <iostream>
#include <vector>
#include <algorithm>
#include <assert.h>
| int func0(const std::vector<int>& lst) {
std::vector<int> positive_numbers;
for (int num : lst) {
if (num > 0) {
positive_numbers.push_back(num);
}
}
std::sort(positive_numbers.begin(), positive_numbers.end());
int sum = 0;
for (int i = 0; i < 3... | int main() {
assert(func0({10,20,30,40,50,60,7}) == 37);
assert(func0({1,2,3,4,5}) == 6);
assert(func0({0,1,2,3,4,5}) == 6);
return 0;
}
| O1 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %r12
push %rbp
push %rbx
sub $0x30,%rsp
mov %fs:0x28,%rax
mov %rax,0x28(%rsp)
xor %eax,%eax
movq $0x0,0x10(%rsp)
movq $0x0,0x18(%rsp)
movq $0x0,0x20(%rsp)
mov (%rdi),%rbx
mov 0x8(%rdi),%rbp
cmp %rbp,%rbx
je 12e9 <_Z5... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push r13
push r12
push rbp
push rbx
sub rsp, 38h
mov rax, fs:28h
mov [rsp+58h+var_30], rax
xor eax, eax
mov [rsp+58h+src], 0
mov [rsp+58h+var_40], 0
mov [rsp+58h+var_38], 0
mov rbx, [rdi]
mov rbp, [rdi+8]
cmp rbp, rbx
jnz loc_1... | long long func0(int **a1)
{
int *v1; // rbx
int *v2; // rbp
int *v3; // r12
int *v4; // rbp
unsigned int v5; // ebx
long long v6; // r13
int v7; // eax
unsigned long long v8; // rax
int *v9; // rbx
int v10; // ecx
int *v11; // rax
int v12; // edx
int *v13; // rsi
int v14; // eax
int *v15;... | func0:
ENDBR64
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x38
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x28],RAX
XOR EAX,EAX
MOV qword ptr [RSP + 0x10],0x0
MOV qword ptr [RSP + 0x18],0x0
MOV qword ptr [RSP + 0x20],0x0
MOV RBX,qword ptr [RDI]
MOV RBP,qword ptr [RDI + 0x8]
CMP RBP,RBX
JNZ 0x0010131d
LAB_0010127... | /* func0(std::vector<int, std::allocator<int> > const&) */
int func0(vector *param_1,int param_2,int param_3,int param_4,int param_5,
int param_6,int param_7,int param_8,int param_9,int8 param_10
,int8 param_11)
{
int iVar1;
int *piVar2;
long lVar3;
int *piVar4;
int *piVar5;
int *piVar6;... |
1,358 | func0 |
#include <iostream>
#include <vector>
#include <algorithm>
#include <assert.h>
| int func0(const std::vector<int>& lst) {
std::vector<int> positive_numbers;
for (int num : lst) {
if (num > 0) {
positive_numbers.push_back(num);
}
}
std::sort(positive_numbers.begin(), positive_numbers.end());
int sum = 0;
for (int i = 0; i < 3... | int main() {
assert(func0({10,20,30,40,50,60,7}) == 37);
assert(func0({1,2,3,4,5}) == 6);
assert(func0({0,1,2,3,4,5}) == 6);
return 0;
}
| O2 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %r13
push %r12
push %rbp
push %rbx
sub $0x38,%rsp
mov (%rdi),%rbx
mov 0x8(%rdi),%r12
mov %fs:0x28,%rax
mov %rax,0x28(%rsp)
xor %eax,%eax
movq $0x0,0x10(%rsp)
movq $0x0,0x18(%rsp)
movq $0x0,0x20(%rsp)
cmp %r12,%rbx
je ... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push r14
pxor xmm0, xmm0
push r13
push r12
push rbp
push rbx
sub rsp, 30h
mov r12, [rdi+8]
mov rbx, [rdi]
mov rax, fs:28h
mov [rsp+58h+var_30], rax
xor eax, eax
movaps xmmword ptr [rsp+58h+src], xmm0
mov [rsp+58h+var_38], 0
cmp r12,... | long long func0(int **a1)
{
int *v1; // r12
int *v2; // rbx
int *v3; // r13
int *v4; // rbp
int v5; // eax
int *v6; // r12
long long v7; // rdx
long long v8; // r14
unsigned long long v9; // rax
int *i; // rdi
int v11; // ecx
int v12; // edx
int *v13; // rsi
int *v14; // rax
unsigned int ... | func0:
ENDBR64
PUSH R14
PXOR XMM0,XMM0
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x30
MOV R12,qword ptr [RDI + 0x8]
MOV RBX,qword ptr [RDI]
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x28],RAX
XOR EAX,EAX
MOVAPS xmmword ptr [RSP + 0x10],XMM0
MOV qword ptr [RSP + 0x20],0x0
CMP R12,RBX
JZ 0x00101961
XOR R13D,R13D... | /* func0(std::vector<int, std::allocator<int> > const&) */
int func0(vector *param_1,int param_2,int param_3,int param_4,int param_5,
int param_6,int param_7,int param_8,int param_9,int param_10,
int8 param_11)
{
int iVar1;
int *piVar2;
int *piVar3;
ulong uVar4;
_Iter_less_iter _Var5;
in... |
1,359 | func0 |
#include <iostream>
#include <vector>
#include <algorithm>
#include <assert.h>
| int func0(const std::vector<int>& lst) {
std::vector<int> positive_numbers;
for (int num : lst) {
if (num > 0) {
positive_numbers.push_back(num);
}
}
std::sort(positive_numbers.begin(), positive_numbers.end());
int sum = 0;
for (int i = 0; i < 3... | int main() {
assert(func0({10,20,30,40,50,60,7}) == 37);
assert(func0({1,2,3,4,5}) == 6);
assert(func0({0,1,2,3,4,5}) == 6);
return 0;
}
| O3 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %r15
pxor %xmm0,%xmm0
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x38,%rsp
mov (%rdi),%rbx
mov 0x8(%rdi),%r12
mov %fs:0x28,%rax
mov %rax,0x28(%rsp)
xor %eax,%eax
movaps %xmm0,0x10(%rsp)
movq $0x0,0x20(%rsp)
... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push r15
pxor xmm0, xmm0
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 38h
mov r13, [rdi+8]
mov rbx, [rdi]
mov rax, fs:28h
mov [rsp+68h+var_40], rax
xor eax, eax
movaps xmmword ptr [rsp+68h+src], xmm0
mov [rsp+68h+var_48], 0
... | long long func0(int **a1)
{
int *v1; // r13
int *v2; // rbx
int *v3; // rbp
int *v4; // r12
int v5; // eax
unsigned int *v6; // rbx
int *v7; // r15
long long v8; // r13
unsigned long long v9; // rdx
int *v10; // r14
signed int v11; // r13d
int *v12; // rsi
signed int v13; // edx
int *j; // ... | func0:
ENDBR64
PUSH R15
PXOR XMM0,XMM0
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x38
MOV R13,qword ptr [RDI + 0x8]
MOV RBX,qword ptr [RDI]
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x28],RAX
XOR EAX,EAX
MOVAPS xmmword ptr [RSP + 0x10],XMM0
MOV qword ptr [RSP + 0x20],0x0
CMP R13,RBX
JZ 0x001018ad
XOR ... | /* func0(std::vector<int, std::allocator<int> > const&) */
int func0(vector *param_1,int param_2,int param_3,int param_4,int param_5,
int param_6,int param_7,int param_8,int param_9,int param_10,
int8 param_11)
{
int *piVar1;
long lVar2;
ulong uVar3;
int *piVar4;
_Iter_less_iter _Var5;
i... |
1,360 | func0 | #include <iostream>
#include <set>
#include <tuple>
#include <cassert>
#include <iterator>
| std::tuple<int, int, int, int, int> func0(const std::set<int>& s) {
// Create a tuple from the set elements (assuming the set size is 5 for simplicity)
auto it = s.begin();
std::tuple<int, int, int, int, int> t;
// Fill the tuple with the set values
std::get<0>(t) = *it++;
std::get<1... | int main() {
// Test case 1
assert(func0({1, 2, 3, 4, 5}) == std::make_tuple(1, 2, 3, 4, 5));
// Test case 2
assert(func0({6, 7, 8, 9, 10}) == std::make_tuple(6, 7, 8, 9, 10));
// Test case 3
assert(func0({12, 13, 14, 15, 16}) == std::make_tuple(12, 13, 14, 15, 16));
std... | O0 | cpp | func0(std::set<int, std::less<int>, std::allocator<int> > const&):
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x38,%rsp
mov %rdi,-0x38(%rbp)
mov %rsi,-0x40(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
mov -0x40(%rbp),%rax
mov %rax,%rdi
callq 1a86 <_ZNKSt3setIiSt4lessIiE... | _Z5func0RKSt3setIiSt4lessIiESaIiEE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 38h
mov [rbp+var_38], rdi
mov [rbp+var_40], rsi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
mov rax, [rbp+var_40]
mov rdi, rax
call _ZNKSt3setIiSt4lessIiESaIiEE5beginEv; std::set<int>:... | _DWORD * func0(_DWORD *a1, long long a2)
{
int v2; // ebx
int v3; // ebx
int v4; // ebx
int v5; // ebx
int v6; // ebx
long long v8; // [rsp+18h] [rbp-28h] BYREF
_QWORD v9[3]; // [rsp+20h] [rbp-20h] BYREF
v9[1] = __readfsqword(0x28u);
v8 = std::set<int>::begin(a2);
*a1 = 0;
a1[1] = 0;
a1[2] = 0;... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x38
MOV qword ptr [RBP + -0x38],RDI
MOV qword ptr [RBP + -0x40],RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
MOV RAX,qword ptr [RBP + -0x40]
MOV RDI,RAX
CALL 0x00101a58
MOV qword ptr [RBP + -0x28],RAX
MOV RAX,qword ptr [RBP + -0x38]
MO... | /* func0(std::set<int, std::less<int>, std::allocator<int> > const&) */
set * func0(set *param_1)
{
int4 uVar1;
int4 *puVar2;
type *ptVar3;
type *ptVar4;
type *ptVar5;
type *ptVar6;
type *ptVar7;
set<int,std::less<int>,std::allocator<int>> *in_RSI;
long in_FS_OFFSET;
int8 local_30;
int8 local_28... |
1,361 | func0 | #include <iostream>
#include <set>
#include <tuple>
#include <cassert>
#include <iterator>
| std::tuple<int, int, int, int, int> func0(const std::set<int>& s) {
// Create a tuple from the set elements (assuming the set size is 5 for simplicity)
auto it = s.begin();
std::tuple<int, int, int, int, int> t;
// Fill the tuple with the set values
std::get<0>(t) = *it++;
std::get<1... | int main() {
// Test case 1
assert(func0({1, 2, 3, 4, 5}) == std::make_tuple(1, 2, 3, 4, 5));
// Test case 2
assert(func0({6, 7, 8, 9, 10}) == std::make_tuple(6, 7, 8, 9, 10));
// Test case 3
assert(func0({12, 13, 14, 15, 16}) == std::make_tuple(12, 13, 14, 15, 16));
std... | O1 | cpp | func0(std::set<int, std::less<int>, std::allocator<int> > const&):
endbr64
push %r12
push %rbp
push %rbx
mov %rdi,%rbx
mov 0x18(%rsi),%r12
movl $0x0,(%rdi)
movl $0x0,0x4(%rdi)
movl $0x0,0x8(%rdi)
movl $0x0,0xc(%rdi)
movl $0x0,0x10(%rdi)
mov %r12,%rdi
callq 11b0 <_ZSt18_Rb_tree_incrementPKSt18_... | _Z5func0RKSt3setIiSt4lessIiESaIiEE:
endbr64
push r12
push rbp
push rbx
mov rbx, rdi
mov r12, [rsi+18h]
mov dword ptr [rdi], 0
mov dword ptr [rdi+4], 0
mov dword ptr [rdi+8], 0
mov dword ptr [rdi+0Ch], 0
mov dword ptr [rdi+10h], 0
mov rdi, r12
call __ZSt18_Rb_tree_incrementPKS... | _DWORD * func0(_DWORD *a1, long long a2)
{
long long v2; // r12
long long v3; // rbp
long long v4; // r12
long long v5; // rbp
long long v6; // rax
v2 = *(_QWORD *)(a2 + 24);
*a1 = 0;
a1[1] = 0;
a1[2] = 0;
a1[3] = 0;
a1[4] = 0;
v3 = std::_Rb_tree_increment(v2);
a1[4] = *(_DWORD *)(v2 + 32);
... | func0:
ENDBR64
PUSH R12
PUSH RBP
PUSH RBX
MOV RBX,RDI
MOV R12,qword ptr [RSI + 0x18]
MOV dword ptr [RDI],0x0
MOV dword ptr [RDI + 0x4],0x0
MOV dword ptr [RDI + 0x8],0x0
MOV dword ptr [RDI + 0xc],0x0
MOV dword ptr [RDI + 0x10],0x0
MOV RDI,R12
CALL 0x00101180
MOV RBP,RAX
MOV EAX,dword ptr [R12 + 0x20]
MOV dword ptr [RBX ... | /* func0(std::set<int, std::less<int>, std::allocator<int> > const&) */
set * func0(set *param_1)
{
_Rb_tree_node_base *p_Var1;
_Rb_tree_node_base *p_Var2;
long lVar3;
long in_RSI;
p_Var2 = *(_Rb_tree_node_base **)(in_RSI + 0x18);
*(int4 *)param_1 = 0;
*(int4 *)(param_1 + 4) = 0;
*(int4 *)(param_1 ... |
1,362 | func0 | #include <iostream>
#include <set>
#include <tuple>
#include <cassert>
#include <iterator>
| std::tuple<int, int, int, int, int> func0(const std::set<int>& s) {
// Create a tuple from the set elements (assuming the set size is 5 for simplicity)
auto it = s.begin();
std::tuple<int, int, int, int, int> t;
// Fill the tuple with the set values
std::get<0>(t) = *it++;
std::get<1... | int main() {
// Test case 1
assert(func0({1, 2, 3, 4, 5}) == std::make_tuple(1, 2, 3, 4, 5));
// Test case 2
assert(func0({6, 7, 8, 9, 10}) == std::make_tuple(6, 7, 8, 9, 10));
// Test case 3
assert(func0({12, 13, 14, 15, 16}) == std::make_tuple(12, 13, 14, 15, 16));
std... | O2 | cpp | func0(std::set<int, std::less<int>, std::allocator<int> > const&):
endbr64
push %r12
mov %rdi,%r12
push %rbp
push %rbx
mov 0x18(%rsi),%rbp
movq $0x0,(%rdi)
movq $0x0,0x8(%rdi)
movl $0x0,0x10(%rdi)
mov %rbp,%rdi
callq 11b0 <_ZSt18_Rb_tree_incrementPKSt18_Rb_tree_node_base@plt>
mov %rax,%rbx
mov ... | _Z5func0RKSt3setIiSt4lessIiESaIiEE:
endbr64
push r12
pxor xmm0, xmm0
push rbp
push rbx
mov r12, [rsi+18h]
mov rbx, rdi
mov dword ptr [rdi+10h], 0
movups xmmword ptr [rdi], xmm0
mov rdi, r12
call __ZSt18_Rb_tree_incrementPKSt18_Rb_tree_node_base; std::_Rb_tree_increment(std::_Rb_tree_node... | long long func0(long long a1, long long a2)
{
long long v2; // r12
long long v3; // rbp
long long v4; // r12
long long v5; // rbp
long long v6; // rax
v2 = *(_QWORD *)(a2 + 24);
*(_DWORD *)(a1 + 16) = 0;
*(_OWORD *)a1 = 0LL;
v3 = std::_Rb_tree_increment(v2);
*(_DWORD *)(a1 + 16) = *(_DWORD *)(v2 +... | func0:
ENDBR64
PUSH R12
PXOR XMM0,XMM0
PUSH RBP
PUSH RBX
MOV R12,qword ptr [RSI + 0x18]
MOV RBX,RDI
MOV dword ptr [RDI + 0x10],0x0
MOVUPS xmmword ptr [RDI],XMM0
MOV RDI,R12
CALL 0x001011b0
MOV RBP,RAX
MOV EAX,dword ptr [R12 + 0x20]
MOV RDI,RBP
MOV dword ptr [RBX + 0x10],EAX
CALL 0x001011b0
MOV R12,RAX
MOV EAX,dword ptr... | /* func0(std::set<int, std::less<int>, std::allocator<int> > const&) */
set * func0(set *param_1)
{
_Rb_tree_node_base *p_Var1;
_Rb_tree_node_base *p_Var2;
long lVar3;
long in_RSI;
p_Var2 = *(_Rb_tree_node_base **)(in_RSI + 0x18);
*(int4 *)(param_1 + 0x10) = 0;
*(int (*) [16])param_1 = (int [16])0x0... |
1,363 | func0 | #include <iostream>
#include <set>
#include <tuple>
#include <cassert>
#include <iterator>
| std::tuple<int, int, int, int, int> func0(const std::set<int>& s) {
// Create a tuple from the set elements (assuming the set size is 5 for simplicity)
auto it = s.begin();
std::tuple<int, int, int, int, int> t;
// Fill the tuple with the set values
std::get<0>(t) = *it++;
std::get<1... | int main() {
// Test case 1
assert(func0({1, 2, 3, 4, 5}) == std::make_tuple(1, 2, 3, 4, 5));
// Test case 2
assert(func0({6, 7, 8, 9, 10}) == std::make_tuple(6, 7, 8, 9, 10));
// Test case 3
assert(func0({12, 13, 14, 15, 16}) == std::make_tuple(12, 13, 14, 15, 16));
std... | O3 | cpp | func0(std::set<int, std::less<int>, std::allocator<int> > const&):
endbr64
push %r12
pxor %xmm0,%xmm0
mov %rdi,%r12
push %rbp
push %rbx
mov 0x18(%rsi),%rbp
movl $0x0,0x10(%rdi)
movups %xmm0,(%rdi)
mov %rbp,%rdi
callq 1190 <_ZSt18_Rb_tree_incrementPKSt18_Rb_tree_node_base@plt>
mov %rax,%rbx
mov ... | _Z5func0RKSt3setIiSt4lessIiESaIiEE:
endbr64
push r12
pxor xmm0, xmm0
push rbp
push rbx
mov r12, [rsi+18h]
mov rbx, rdi
mov dword ptr [rdi+10h], 0
movups xmmword ptr [rdi], xmm0
mov rdi, r12
call __ZSt18_Rb_tree_incrementPKSt18_Rb_tree_node_base; std::_Rb_tree_increment(std::_Rb_tree_node... | long long func0(long long a1, long long a2)
{
long long v2; // r12
long long v3; // rbp
long long v4; // r12
long long v5; // rbp
long long v6; // rax
v2 = *(_QWORD *)(a2 + 24);
*(_DWORD *)(a1 + 16) = 0;
*(_OWORD *)a1 = 0LL;
v3 = std::_Rb_tree_increment(v2);
*(_DWORD *)(a1 + 16) = *(_DWORD *)(v2 +... | func0:
ENDBR64
PUSH R12
PXOR XMM0,XMM0
PUSH RBP
PUSH RBX
MOV R12,qword ptr [RSI + 0x18]
MOV RBX,RDI
MOV dword ptr [RDI + 0x10],0x0
MOVUPS xmmword ptr [RDI],XMM0
MOV RDI,R12
CALL 0x001011b0
MOV RBP,RAX
MOV EAX,dword ptr [R12 + 0x20]
MOV RDI,RBP
MOV dword ptr [RBX + 0x10],EAX
CALL 0x001011b0
MOV R12,RAX
MOV EAX,dword ptr... | /* func0(std::set<int, std::less<int>, std::allocator<int> > const&) */
set * func0(set *param_1)
{
_Rb_tree_node_base *p_Var1;
_Rb_tree_node_base *p_Var2;
long lVar3;
long in_RSI;
p_Var2 = *(_Rb_tree_node_base **)(in_RSI + 0x18);
*(int4 *)(param_1 + 0x10) = 0;
*(int (*) [16])param_1 = (int [16])0x0... |
1,364 | func0 |
#include <vector>
#include <queue>
#include <limits>
#include <utility>
#include <assert.h>
class Node {
public:
int value;
int list_num;
int index;
Node(int value, int list_num, int index) : value(value), list_num(list_num), index(index) {}
bool operator<(const Node &other) const... | std::pair<int, int> func0(const std::vector<std::vector<int>>& list) {
int high = std::numeric_limits<int>::min();
std::pair<int, int> p = {0, std::numeric_limits<int>::max()};
std::priority_queue<Node> pq;
for (int i = 0; i < list.size(); i++) {
pq.push(Node(list[i][0], i, 0));
hi... | int main() {
assert(func0({{3, 6, 8, 10, 15}, {1, 5, 12}, {4, 8, 15, 16}, {2, 6}}) == std::make_pair(4, 6));
assert(func0({{2, 3, 4, 8, 10, 15}, {1, 5, 12}, {7, 8, 15, 16}, {3, 6}}) == std::make_pair(4, 7));
assert(func0({{4, 7, 9, 11, 16}, {2, 6, 13}, {5, 9, 16, 17}, {3, 7}}) == std::make_pair(5, 7));
... | O0 | cpp | func0(std::vector<std::vector<int, std::allocator<int> >, std::allocator<std::vector<int, std::allocator<int> > > > const&):
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x88,%rsp
mov %rdi,-0x88(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
movl $0x80000000,-0x74(%rbp)
movq $0x0... | _Z5func0RKSt6vectorIS_IiSaIiEESaIS1_EE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 88h
mov [rbp+var_88], rdi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
mov [rbp+var_74], 80000000h
mov [rbp+var_60], 0
mov dword ptr [rbp+var_60+4], 7FFFFFFFh
lea rax, [rbp+var_40]... | long long func0(long long a1)
{
long long v1; // rax
int *v2; // rax
long long v3; // rax
long long v4; // rax
unsigned long long v5; // rbx
long long v6; // rax
long long v7; // rbx
long long v8; // rax
long long v9; // rbx
int v11; // ebx
long long v12; // rax
int *v13; // rax
long long v14... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x88
MOV qword ptr [RBP + -0x88],RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
MOV dword ptr [RBP + -0x74],0x80000000
MOV qword ptr [RBP + -0x60],0x0
MOV dword ptr [RBP + -0x5c],0x7fffffff
LEA RAX,[RBP + -0x40]
MOV RDI,RAX
CALL 0x0010232... | /* func0(std::vector<std::vector<int, std::allocator<int> >, std::allocator<std::vector<int,
std::allocator<int> > > > const&) */
int8 func0(vector *param_1)
{
int iVar1;
int8 uVar2;
ulong uVar3;
int8 *puVar4;
vector<int,std::allocator<int>> *pvVar5;
long lVar6;
int *piVar7;
ulong uVar8;
long lVa... |
1,365 | func0 |
#include <vector>
#include <queue>
#include <limits>
#include <utility>
#include <assert.h>
class Node {
public:
int value;
int list_num;
int index;
Node(int value, int list_num, int index) : value(value), list_num(list_num), index(index) {}
bool operator<(const Node &other) const... | std::pair<int, int> func0(const std::vector<std::vector<int>>& list) {
int high = std::numeric_limits<int>::min();
std::pair<int, int> p = {0, std::numeric_limits<int>::max()};
std::priority_queue<Node> pq;
for (int i = 0; i < list.size(); i++) {
pq.push(Node(list[i][0], i, 0));
hi... | int main() {
assert(func0({{3, 6, 8, 10, 15}, {1, 5, 12}, {4, 8, 15, 16}, {2, 6}}) == std::make_pair(4, 6));
assert(func0({{2, 3, 4, 8, 10, 15}, {1, 5, 12}, {7, 8, 15, 16}, {3, 6}}) == std::make_pair(4, 7));
assert(func0({{4, 7, 9, 11, 16}, {2, 6, 13}, {5, 9, 16, 17}, {3, 7}}) == std::make_pair(5, 7));
... | O1 | cpp | func0(std::vector<std::vector<int, std::allocator<int> >, std::allocator<std::vector<int, std::allocator<int> > > > const&):
endbr64
push %r15
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x68,%rsp
mov %rdi,%rbx
mov %fs:0x28,%rax
mov %rax,0x58(%rsp)
xor %eax,%eax
movl $0x80000000,... | _Z5func0RKSt6vectorIS_IiSaIiEESaIS1_EE:
endbr64
push r15
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 68h
mov r12, rdi
mov rax, fs:28h
mov [rsp+98h+var_40], rax
xor eax, eax
mov [rsp+98h+var_84], 80000000h
mov [rsp+98h+var_68], 0
mov [rsp+98h+var_60], 0
mov ... | long long func0(long long *a1)
{
long long v2; // rdx
unsigned long long v3; // rbx
unsigned int *v4; // rax
long long v5; // r14
unsigned int v6; // r13d
unsigned int v7; // edi
unsigned int v8; // esi
unsigned int v9; // ecx
unsigned long long v10; // rax
long long i; // rdx
long long v12; // r... | func0:
ENDBR64
PUSH R15
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x68
MOV R12,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x58],RAX
XOR EAX,EAX
MOV dword ptr [RSP + 0x14],0x80000000
MOV qword ptr [RSP + 0x30],0x0
MOV qword ptr [RSP + 0x38],0x0
MOV qword ptr [RSP + 0x40],0x0
MOV RDX,qword ptr [RDI]
... | /* func0(std::vector<std::vector<int, std::allocator<int> >, std::allocator<std::vector<int,
std::allocator<int> > > > const&) */
int8 func0(vector *param_1)
{
long *plVar1;
Node NVar2;
int iVar3;
int iVar4;
int iVar5;
long lVar6;
int iVar7;
long lVar8;
long lVar9;
long lVar10;
ulong uVar11;
... |
1,366 | func0 |
#include <vector>
#include <queue>
#include <limits>
#include <utility>
#include <assert.h>
class Node {
public:
int value;
int list_num;
int index;
Node(int value, int list_num, int index) : value(value), list_num(list_num), index(index) {}
bool operator<(const Node &other) const... | std::pair<int, int> func0(const std::vector<std::vector<int>>& list) {
int high = std::numeric_limits<int>::min();
std::pair<int, int> p = {0, std::numeric_limits<int>::max()};
std::priority_queue<Node> pq;
for (int i = 0; i < list.size(); i++) {
pq.push(Node(list[i][0], i, 0));
hi... | int main() {
assert(func0({{3, 6, 8, 10, 15}, {1, 5, 12}, {4, 8, 15, 16}, {2, 6}}) == std::make_pair(4, 6));
assert(func0({{2, 3, 4, 8, 10, 15}, {1, 5, 12}, {7, 8, 15, 16}, {3, 6}}) == std::make_pair(4, 7));
assert(func0({{4, 7, 9, 11, 16}, {2, 6, 13}, {5, 9, 16, 17}, {3, 7}}) == std::make_pair(5, 7));
... | O2 | cpp | func0(std::vector<std::vector<int, std::allocator<int> >, std::allocator<std::vector<int, std::allocator<int> > > > const&):
endbr64
push %r15
xor %esi,%esi
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x88,%rsp
mov 0x8(%rdi),%r10
mov %rdi,0x38(%rsp)
mov %fs:0x28,%rbx
mov %rbx,0x... | _Z5func0RKSt6vectorIS_IiSaIiEESaIS1_EE:
endbr64
push r15
pxor xmm0, xmm0
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 88h
mov r9, [rdi]
mov r10, [rdi+8]
mov [rsp+0B8h+var_80], rdi
mov rax, fs:28h
mov [rsp+0B8h+var_40], rax
xor eax, eax
mov [rsp+0B8h+var_A0],... | long long func0(long long *a1)
{
long long v1; // r9
long long v2; // r10
unsigned long long v3; // rbp
signed int v4; // ebx
__int128 v5; // rdi
unsigned long long v6; // rax
__m128i v7; // xmm0
int v8; // r11d
int v9; // r8d
unsigned long long v10; // rdx
long long v11; // r14
long long v12; ... | func0:
ENDBR64
PUSH R15
PXOR XMM0,XMM0
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x88
MOV R9,qword ptr [RDI]
MOV R10,qword ptr [RDI + 0x8]
MOV qword ptr [RSP + 0x38],RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x78],RAX
XOR EAX,EAX
MOV qword ptr [RSP + 0x18],R9
MOV qword ptr [RSP + 0x60],0x0
MOVAPS ... | /* func0(std::vector<std::vector<int, std::allocator<int> >, std::allocator<std::vector<int,
std::allocator<int> > > > const&) */
ulong func0(vector *param_1)
{
long *plVar1;
uint *puVar2;
uint *puVar3;
int8 *puVar4;
int8 uVar5;
uint uVar6;
uint uVar7;
uint uVar8;
uint uVar9;
long lVar10;
lon... |
1,367 | func0 |
#include <vector>
#include <queue>
#include <limits>
#include <utility>
#include <assert.h>
class Node {
public:
int value;
int list_num;
int index;
Node(int value, int list_num, int index) : value(value), list_num(list_num), index(index) {}
bool operator<(const Node &other) const... | std::pair<int, int> func0(const std::vector<std::vector<int>>& list) {
int high = std::numeric_limits<int>::min();
std::pair<int, int> p = {0, std::numeric_limits<int>::max()};
std::priority_queue<Node> pq;
for (int i = 0; i < list.size(); i++) {
pq.push(Node(list[i][0], i, 0));
hi... | int main() {
assert(func0({{3, 6, 8, 10, 15}, {1, 5, 12}, {4, 8, 15, 16}, {2, 6}}) == std::make_pair(4, 6));
assert(func0({{2, 3, 4, 8, 10, 15}, {1, 5, 12}, {7, 8, 15, 16}, {3, 6}}) == std::make_pair(4, 7));
assert(func0({{4, 7, 9, 11, 16}, {2, 6, 13}, {5, 9, 16, 17}, {3, 7}}) == std::make_pair(5, 7));
... | O3 | cpp | func0(std::vector<std::vector<int, std::allocator<int> >, std::allocator<std::vector<int, std::allocator<int> > > > const&):
endbr64
push %r15
pxor %xmm0,%xmm0
push %r14
push %r13
push %r12
push %rbp
push %rbx
sub $0x88,%rsp
mov 0x8(%rdi),%r11
mov %rdi,0x38(%rsp)
mov %fs:0x28,%rbx
mov %rbx,... | _Z5func0RKSt6vectorIS_IiSaIiEESaIS1_EE:
endbr64
push r15
pxor xmm0, xmm0
push r14
push r13
push r12
push rbp
push rbx
sub rsp, 88h
mov r10, [rdi+8]
mov r11, [rdi]
mov [rsp+0B8h+var_80], rdi
mov rax, fs:28h
mov [rsp+0B8h+var_40], rax
xor eax, eax
movaps xmmword ptr [rsp+... | unsigned long long func0(long long *a1)
{
long long v1; // r10
long long v2; // r11
unsigned long long v3; // rbp
char *v4; // rdi
char *v5; // rsi
signed int v6; // ebx
unsigned long long v7; // rax
__m128i v8; // xmm0
int v9; // r9d
int v10; // r8d
unsigned long long v11; // rdx
long long v12... | func0:
ENDBR64
PUSH R15
PXOR XMM0,XMM0
PUSH R14
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x88
MOV R10,qword ptr [RDI + 0x8]
MOV R11,qword ptr [RDI]
MOV qword ptr [RSP + 0x38],RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x78],RAX
XOR EAX,EAX
MOVAPS xmmword ptr [RSP + 0x50],XMM0
MOV qword ptr [RSP + 0x60],0x0... | /* func0(std::vector<std::vector<int, std::allocator<int> >, std::allocator<std::vector<int,
std::allocator<int> > > > const&) */
int8 func0(vector *param_1)
{
long *plVar1;
int *piVar2;
int8 *puVar3;
int8 uVar4;
int iVar5;
int iVar6;
int iVar7;
int iVar8;
int *piVar9;
int *piVar10;
long lVar... |
1,368 | func0 |
#include <iostream>
#include <string>
#include <assert.h>
| std::pair<int, int> func0(const std::string& s) {
int d = 0, l = 0;
for (char c : s) {
if (isdigit(c))
d++;
else if (isalpha(c))
l++;
}
return std::make_pair(l, d);
}
| int main() {
assert(func0("python") == std::make_pair(6, 0));
assert(func0("program") == std::make_pair(7, 0));
assert(func0("python3.0") == std::make_pair(6, 2));
return 0;
}
| O0 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %rbp
mov %rsp,%rbp
sub $0x40,%rsp
mov %rdi,-0x38(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x8(%rbp)
xor %eax,%eax
movl $0x0,-0x28(%rbp)
movl $0x0,-0x24(%rbp)
mov -0x38(%rbp),%rax
mov %rax,-... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push rbp
mov rbp, rsp
sub rsp, 40h
mov [rbp+var_38], rdi
mov rax, fs:28h
mov [rbp+var_8], rax
xor eax, eax
mov [rbp+var_28], 0
mov [rbp+var_24], 0
mov rax, [rbp+var_38]
mov [rbp+var_10], rax
mov rax, [... | long long func0(long long a1)
{
char v2; // [rsp+17h] [rbp-29h]
int v3; // [rsp+18h] [rbp-28h] BYREF
int v4; // [rsp+1Ch] [rbp-24h] BYREF
long long v5; // [rsp+20h] [rbp-20h] BYREF
_QWORD v6[3]; // [rsp+28h] [rbp-18h] BYREF
v6[2] = __readfsqword(0x28u);
v3 = 0;
v4 = 0;
v6[1] = a1;
v5 = std::string... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
SUB RSP,0x40
MOV qword ptr [RBP + -0x38],RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x8],RAX
XOR EAX,EAX
MOV dword ptr [RBP + -0x28],0x0
MOV dword ptr [RBP + -0x24],0x0
MOV RAX,qword ptr [RBP + -0x38]
MOV qword ptr [RBP + -0x10],RAX
MOV RAX,qword ptr [RBP + -0x10]
MOV RDI,... | /* func0(std::string const&) */
void func0(string *param_1)
{
bool bVar1;
int iVar2;
char *pcVar3;
long in_FS_OFFSET;
int local_30;
int local_2c;
int8 local_28;
int8 local_20;
string *local_18;
long local_10;
local_10 = *(long *)(in_FS_OFFSET + 0x28);
local_30 = 0;
local_2c = 0;
local_1... |
1,369 | func0 |
#include <iostream>
#include <string>
#include <assert.h>
| std::pair<int, int> func0(const std::string& s) {
int d = 0, l = 0;
for (char c : s) {
if (isdigit(c))
d++;
else if (isalpha(c))
l++;
}
return std::make_pair(l, d);
}
| int main() {
assert(func0("python") == std::make_pair(6, 0));
assert(func0("program") == std::make_pair(7, 0));
assert(func0("python3.0") == std::make_pair(6, 2));
return 0;
}
| O1 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r13
push %r12
push %rbp
push %rbx
sub $0x8,%rsp
mov (%rdi),%rbx
mov %rbx,%r13
add 0x8(%rdi),%r13
cmp %rbx,%r13
je 12a0 <_Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE+0... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r13
push r12
push rbp
push rbx
sub rsp, 8
mov rbx, [rdi]
mov r13, rbx
add r13, [rdi+8]
cmp r13, rbx
jz short loc_1280
mov ebp, 0
mov r12d, 0
jmp short loc_126B
loc_1253:
movsx edi, dil; int
ca... | long long func0(char **a1)
{
char *v1; // rbx
char *v2; // r13
unsigned int v3; // ebp
long long v4; // r12
v1 = *a1;
v2 = &(*a1)[(_QWORD)a1[1]];
if ( v2 == *a1 )
{
v3 = 0;
v4 = 0LL;
}
else
{
v3 = 0;
v4 = 0LL;
do
{
if ( (unsigned int)(*v1 - 48) > 9 )
v3 -= (... | func0:
ENDBR64
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x8
MOV RBX,qword ptr [RDI]
MOV R13,RBX
ADD R13,qword ptr [RDI + 0x8]
CMP R13,RBX
JZ 0x00101280
MOV EBP,0x0
MOV R12D,0x0
JMP 0x0010126b
LAB_00101253:
MOVSX EDI,DIL
CALL 0x00101120
CMP EAX,0x1
SBB EBP,-0x1
LAB_00101262:
ADD RBX,0x1
CMP RBX,R13
JZ 0x0010128b
LAB_... | /* func0(std::string const&) */
int8 func0(string *param_1)
{
int iVar1;
char *pcVar2;
int iVar3;
int iVar4;
char *pcVar5;
pcVar2 = *(char **)param_1;
pcVar5 = pcVar2 + *(long *)(param_1 + 8);
if (pcVar5 == pcVar2) {
iVar3 = 0;
iVar4 = 0;
}
else {
iVar3 = 0;
iVar4 = 0;
do {
... |
1,370 | func0 |
#include <iostream>
#include <string>
#include <assert.h>
| std::pair<int, int> func0(const std::string& s) {
int d = 0, l = 0;
for (char c : s) {
if (isdigit(c))
d++;
else if (isalpha(c))
l++;
}
return std::make_pair(l, d);
}
| int main() {
assert(func0("python") == std::make_pair(6, 0));
assert(func0("program") == std::make_pair(7, 0));
assert(func0("python3.0") == std::make_pair(6, 2));
return 0;
}
| O2 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r13
push %r12
xor %r12d,%r12d
push %rbp
xor %ebp,%ebp
push %rbx
sub $0x8,%rsp
mov (%rdi),%rbx
mov 0x8(%rdi),%r13
add %rbx,%r13
cmp %rbx,%r13
jne 1435 <_Z5func0RKNSt7__cxx1112basic... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r13
push r12
xor r12d, r12d
push rbp
xor ebp, ebp
push rbx
sub rsp, 8
mov rbx, [rdi]
mov r13, [rdi+8]
add r13, rbx
cmp r13, rbx
jnz short loc_1395
jmp short loc_13B4
loc_1388:
add rbx, 1
add ... | long long func0(char **a1)
{
long long v1; // r12
unsigned int v2; // ebp
char *v3; // rbx
char *v4; // r13
int v5; // edi
v1 = 0LL;
v2 = 0;
v3 = *a1;
v4 = &a1[1][(_QWORD)*a1];
if ( v4 != *a1 )
{
do
{
while ( 1 )
{
v5 = *v3;
if ( (unsigned int)(v5 - 48) > 9 )
... | func0:
ENDBR64
PUSH R13
PUSH R12
XOR R12D,R12D
PUSH RBP
XOR EBP,EBP
PUSH RBX
SUB RSP,0x8
MOV RBX,qword ptr [RDI]
MOV R13,qword ptr [RDI + 0x8]
ADD R13,RBX
CMP R13,RBX
JNZ 0x00101395
JMP 0x001013b4
LAB_00101388:
ADD RBX,0x1
ADD R12D,0x1
CMP RBX,R13
JZ 0x001013b4
LAB_00101395:
MOVSX EDI,byte ptr [RBX]
LEA EAX,[RDI + -0x3... | /* func0(std::string const&) */
int8 func0(string *param_1)
{
int iVar1;
char *pcVar2;
int iVar3;
int iVar4;
char *pcVar5;
iVar4 = 0;
iVar3 = 0;
pcVar2 = *(char **)param_1;
pcVar5 = pcVar2 + *(long *)(param_1 + 8);
for (; pcVar5 != pcVar2; pcVar2 = pcVar2 + 1) {
while ((int)*pcVar2 - 0x30U ... |
1,371 | func0 |
#include <iostream>
#include <string>
#include <assert.h>
| std::pair<int, int> func0(const std::string& s) {
int d = 0, l = 0;
for (char c : s) {
if (isdigit(c))
d++;
else if (isalpha(c))
l++;
}
return std::make_pair(l, d);
}
| int main() {
assert(func0("python") == std::make_pair(6, 0));
assert(func0("program") == std::make_pair(7, 0));
assert(func0("python3.0") == std::make_pair(6, 2));
return 0;
}
| O3 | cpp | func0(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&):
endbr64
push %r13
push %r12
xor %r12d,%r12d
push %rbp
xor %ebp,%ebp
push %rbx
sub $0x8,%rsp
mov (%rdi),%rbx
mov 0x8(%rdi),%r13
add %rbx,%r13
cmp %rbx,%r13
jne 1435 <_Z5func0RKNSt7__cxx1112basic... | _Z5func0RKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE:
endbr64
push r13
push r12
xor r12d, r12d
push rbp
xor ebp, ebp
push rbx
sub rsp, 8
mov rbx, [rdi]
mov r13, [rdi+8]
add r13, rbx
cmp r13, rbx
jnz short loc_1395
jmp short loc_13B4
loc_1388:
add rbx, 1
add ... | long long func0(char **a1)
{
long long v1; // r12
unsigned int v2; // ebp
char *v3; // rbx
char *v4; // r13
int v5; // edi
v1 = 0LL;
v2 = 0;
v3 = *a1;
v4 = &a1[1][(_QWORD)*a1];
if ( v4 != *a1 )
{
do
{
while ( 1 )
{
v5 = *v3;
if ( (unsigned int)(v5 - 48) > 9 )
... | func0:
ENDBR64
PUSH R13
PUSH R12
XOR R12D,R12D
PUSH RBP
XOR EBP,EBP
PUSH RBX
SUB RSP,0x8
MOV RBX,qword ptr [RDI]
MOV R13,qword ptr [RDI + 0x8]
ADD R13,RBX
CMP R13,RBX
JNZ 0x00101395
JMP 0x001013b4
LAB_00101388:
ADD RBX,0x1
ADD R12D,0x1
CMP RBX,R13
JZ 0x001013b4
LAB_00101395:
MOVSX EDI,byte ptr [RBX]
LEA EAX,[RDI + -0x3... | /* func0(std::string const&) */
int8 func0(string *param_1)
{
int iVar1;
char *pcVar2;
int iVar3;
int iVar4;
char *pcVar5;
iVar4 = 0;
iVar3 = 0;
pcVar2 = *(char **)param_1;
pcVar5 = pcVar2 + *(long *)(param_1 + 8);
for (; pcVar5 != pcVar2; pcVar2 = pcVar2 + 1) {
while ((int)*pcVar2 - 0x30U ... |
1,372 | func0 |
#include <cmath>
#include <cassert>
| 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 | cpp | func0(int, int):
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... | _Z5func0ii:
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 x... | 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 ... | /* func0(int, int) */
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;
} |
1,373 | func0 |
#include <cmath>
#include <cassert>
| 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 | cpp | func0(int, int):
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 <_Z5func0ii+0x66>
cvttsd2si 0x8(%rsp),%ebp
sub $0x1,%ebx
pxor %xmm0,%xmm0
cvtsi2... | _Z5func0ii:
endbr64
push rbp
push rbx
sub rsp, 8
mov ebx, edi
pxor xmm0, xmm0
cvtsi2sd xmm0, esi; x
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; x
pxor xmm1, xmm1
ucomisd xmm1, xmm0... | 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 ... | /* func0(int, int) */
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... |
1,374 | func0 |
#include <cmath>
#include <cassert>
| 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 | cpp | func0(int, int):
endbr64
pxor %xmm0,%xmm0
pxor %xmm2,%xmm2
sub $0x18,%rsp
cvtsi2sd %esi,%xmm0
ucomisd %xmm0,%xmm2
movapd %xmm0,%xmm1
sqrtsd %xmm1,%xmm1
ja 126a <_Z5func0ii+0x4a>
sub $0x1,%edi
cvttsd2si %xmm1,%eax
pxor %xmm0,%xmm0
cvtsi2sd %edi,%xmm0
ucomisd %xmm0,%xmm2
movapd %xmm0,%xmm1
sqrtsd %xmm1,%x... | _Z5func0ii:
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, 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 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... | /* func0(int, int) */
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... |
1,375 | func0 |
#include <cmath>
#include <cassert>
| 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 | cpp | func0(int, int):
endbr64
pxor %xmm0,%xmm0
pxor %xmm2,%xmm2
sub $0x18,%rsp
cvtsi2sd %esi,%xmm0
ucomisd %xmm0,%xmm2
movapd %xmm0,%xmm1
sqrtsd %xmm1,%xmm1
ja 126a <_Z5func0ii+0x4a>
sub $0x1,%edi
cvttsd2si %xmm1,%eax
pxor %xmm0,%xmm0
cvtsi2sd %edi,%xmm0
ucomisd %xmm0,%xmm2
movapd %xmm0,%xmm1
sqrtsd %xmm1,%x... | _Z5func0ii:
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, 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 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... | /* func0(int, int) */
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... |
1,376 | func0 |
#include <vector>
#include <cassert>
| std::vector<int> func0(const std::vector<int>& nums) {
std::vector<int> result;
for (size_t i = 0; i < nums.size() - 1; ++i) {
result.push_back(nums[i+1] - nums[i]);
}
return result;
}
| int main() {
assert((func0({1, 1, 3, 4, 4, 5, 6, 7}) == std::vector<int>{0, 2, 1, 0, 1, 1, 1}));
assert((func0({4, 5, 8, 9, 6, 10}) == std::vector<int>{1, 3, 1, -3, 4}));
assert((func0({0, 1, 2, 3, 4, 4, 4, 4, 5, 7}) == std::vector<int>{1, 1, 1, 1, 0, 0, 0, 1, 2}));
return 0;
}
| O0 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %rbp
mov %rsp,%rbp
push %rbx
sub $0x38,%rsp
mov %rdi,-0x38(%rbp)
mov %rsi,-0x40(%rbp)
mov %fs:0x28,%rax
mov %rax,-0x18(%rbp)
xor %eax,%eax
mov -0x38(%rbp),%rax
mov %rax,%rdi
callq 1a78 <_ZNSt6vectorIiSaIiEEC1Ev>
movq $0... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push rbp
mov rbp, rsp
push rbx
sub rsp, 38h
mov [rbp+var_38], rdi
mov [rbp+var_40], rsi
mov rax, fs:28h
mov [rbp+var_18], rax
xor eax, eax
mov rax, [rbp+var_38]
mov rdi, rax
call _ZNSt6vectorIiSaIiEEC2Ev; std::vector<int>::vector(void)
mo... | long long func0(long long a1, long long a2)
{
int v2; // ebx
long long v3; // rax
int v5; // [rsp+1Ch] [rbp-24h] BYREF
unsigned long long i; // [rsp+20h] [rbp-20h]
unsigned long long v7; // [rsp+28h] [rbp-18h]
v7 = __readfsqword(0x28u);
std::vector<int>::vector(a1);
for ( i = 0LL; ; ++i )
{
v3 =... | func0:
ENDBR64
PUSH RBP
MOV RBP,RSP
PUSH RBX
SUB RSP,0x38
MOV qword ptr [RBP + -0x38],RDI
MOV qword ptr [RBP + -0x40],RSI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RBP + -0x18],RAX
XOR EAX,EAX
MOV RAX,qword ptr [RBP + -0x38]
MOV RDI,RAX
CALL 0x00101afc
MOV qword ptr [RBP + -0x20],0x0
JMP 0x001012f0
LAB_001012a3:
MOV R... | /* func0(std::vector<int, std::allocator<int> > const&) */
vector * func0(vector *param_1)
{
int iVar1;
int *piVar2;
long lVar3;
vector<int,std::allocator<int>> *in_RSI;
long in_FS_OFFSET;
int local_2c;
ulong local_28;
long local_20;
local_20 = *(long *)(in_FS_OFFSET + 0x28);
std::vector<int,st... |
1,377 | func0 |
#include <vector>
#include <cassert>
| std::vector<int> func0(const std::vector<int>& nums) {
std::vector<int> result;
for (size_t i = 0; i < nums.size() - 1; ++i) {
result.push_back(nums[i+1] - nums[i]);
}
return result;
}
| int main() {
assert((func0({1, 1, 3, 4, 4, 5, 6, 7}) == std::vector<int>{0, 2, 1, 0, 1, 1, 1}));
assert((func0({4, 5, 8, 9, 6, 10}) == std::vector<int>{1, 3, 1, -3, 4}));
assert((func0({0, 1, 2, 3, 4, 4, 4, 4, 5, 7}) == std::vector<int>{1, 1, 1, 1, 0, 0, 0, 1, 2}));
return 0;
}
| O1 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %r13
push %r12
push %rbp
push %rbx
sub $0x18,%rsp
mov %rdi,%rbp
mov %fs:0x28,%rax
mov %rax,0x8(%rsp)
xor %eax,%eax
movq $0x0,(%rdi)
movq $0x0,0x8(%rdi)
movq $0x0,0x10(%rdi)
mov (%rsi),%rdx
mov 0x8(%rsi),%rax
sub %rd... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push r13
push r12
push rbp
push rbx
sub rsp, 18h
mov rbp, rdi
mov rax, fs:28h
mov [rsp+38h+var_30], rax
xor eax, eax
mov qword ptr [rdi], 0
mov qword ptr [rdi+8], 0
mov qword ptr [rdi+10h], 0
mov rdx, [rsi]
mov rax, [rsi+8]
sub ... | _QWORD * func0(_QWORD *a1, long long *a2)
{
long long v2; // rdx
unsigned long long v4; // rbx
int v5; // eax
int *v6; // rsi
int v8; // [rsp+4h] [rbp-34h] BYREF
unsigned long long v9; // [rsp+8h] [rbp-30h]
v9 = __readfsqword(0x28u);
*a1 = 0LL;
a1[1] = 0LL;
a1[2] = 0LL;
v2 = *a2;
if ( a2[1] - *... | func0:
ENDBR64
PUSH R13
PUSH R12
PUSH RBP
PUSH RBX
SUB RSP,0x18
MOV RBP,RDI
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x8],RAX
XOR EAX,EAX
MOV qword ptr [RDI],0x0
MOV qword ptr [RDI + 0x8],0x0
MOV qword ptr [RDI + 0x10],0x0
MOV RDX,qword ptr [RSI]
MOV RAX,qword ptr [RSI + 0x8]
SUB RAX,RDX
CMP RAX,0x4
JZ 0x001013... | /* func0(std::vector<int, std::allocator<int> > const&) */
vector * func0(vector *param_1)
{
int *piVar1;
long lVar2;
ulong uVar3;
long *in_RSI;
long in_FS_OFFSET;
int local_34;
long local_30;
local_30 = *(long *)(in_FS_OFFSET + 0x28);
*(int8 *)param_1 = 0;
*(int8 *)(param_1 + 8) = 0;
*(int8 ... |
1,378 | func0 |
#include <vector>
#include <cassert>
| std::vector<int> func0(const std::vector<int>& nums) {
std::vector<int> result;
for (size_t i = 0; i < nums.size() - 1; ++i) {
result.push_back(nums[i+1] - nums[i]);
}
return result;
}
| int main() {
assert((func0({1, 1, 3, 4, 4, 5, 6, 7}) == std::vector<int>{0, 2, 1, 0, 1, 1, 1}));
assert((func0({4, 5, 8, 9, 6, 10}) == std::vector<int>{1, 3, 1, -3, 4}));
assert((func0({0, 1, 2, 3, 4, 4, 4, 4, 5, 7}) == std::vector<int>{1, 1, 1, 1, 0, 0, 0, 1, 2}));
return 0;
}
| O2 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %r13
push %r12
mov %rdi,%r12
push %rbp
push %rbx
sub $0x18,%rsp
mov %fs:0x28,%rax
mov %rax,0x8(%rsp)
xor %eax,%eax
movq $0x0,(%rdi)
movq $0x0,0x8(%rdi)
movq $0x0,0x10(%rdi)
mov (%rsi),%rdx
mov 0x8(%rsi),%rax
sub %rd... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push r13
pxor xmm0, xmm0
push r12
push rbp
mov rbp, rdi
push rbx
sub rsp, 18h
mov rax, fs:28h
mov [rsp+38h+var_30], rax
xor eax, eax
movups xmmword ptr [rdi], xmm0
mov rdx, [rsi]
mov rax, [rsi+8]
mov qword ptr [rdi+10h], 0
sub rax,... | long long func0(long long a1, long long *a2)
{
long long v2; // rdx
long long v3; // rax
int *v5; // rcx
int *v6; // rsi
unsigned long long v7; // rbx
int v8; // eax
int v10; // [rsp+0h] [rbp-34h] BYREF
unsigned long long v11; // [rsp+4h] [rbp-30h]
v11 = __readfsqword(0x28u);
*(_OWORD *)a1 = 0LL;
... | func0:
ENDBR64
PUSH R13
PXOR XMM0,XMM0
PUSH R12
PUSH RBP
MOV RBP,RDI
PUSH RBX
SUB RSP,0x18
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x8],RAX
XOR EAX,EAX
MOVUPS xmmword ptr [RDI],XMM0
MOV RDX,qword ptr [RSI]
MOV RAX,qword ptr [RSI + 0x8]
MOV qword ptr [RDI + 0x10],0x0
SUB RAX,RDX
CMP RAX,0x4
JZ 0x001016f0
MOV R1... | /* func0(std::vector<int, std::allocator<int> > const&) */
vector * func0(vector *param_1)
{
long lVar1;
int *piVar2;
long lVar3;
ulong uVar4;
long *in_RSI;
int *piVar5;
long in_FS_OFFSET;
int local_34;
long local_30;
local_30 = *(long *)(in_FS_OFFSET + 0x28);
*(int (*) [16])param_1 = (int [... |
1,379 | func0 |
#include <vector>
#include <cassert>
| std::vector<int> func0(const std::vector<int>& nums) {
std::vector<int> result;
for (size_t i = 0; i < nums.size() - 1; ++i) {
result.push_back(nums[i+1] - nums[i]);
}
return result;
}
| int main() {
assert((func0({1, 1, 3, 4, 4, 5, 6, 7}) == std::vector<int>{0, 2, 1, 0, 1, 1, 1}));
assert((func0({4, 5, 8, 9, 6, 10}) == std::vector<int>{1, 3, 1, -3, 4}));
assert((func0({0, 1, 2, 3, 4, 4, 4, 4, 5, 7}) == std::vector<int>{1, 1, 1, 1, 0, 0, 0, 1, 2}));
return 0;
}
| O3 | cpp | func0(std::vector<int, std::allocator<int> > const&):
endbr64
push %r13
pxor %xmm0,%xmm0
push %r12
mov %rdi,%r12
push %rbp
push %rbx
sub $0x18,%rsp
mov %fs:0x28,%rax
mov %rax,0x8(%rsp)
xor %eax,%eax
movq $0x0,0x10(%rdi)
movups %xmm0,(%rdi)
mov (%rsi),%rdx
mov 0x8(%rsi),%rax
sub %rdx,... | _Z5func0RKSt6vectorIiSaIiEE:
endbr64
push r13
pxor xmm0, xmm0
push r12
push rbp
mov rbp, rdi
push rbx
sub rsp, 18h
mov rax, fs:28h
mov [rsp+38h+var_30], rax
xor eax, eax
movups xmmword ptr [rdi], xmm0
mov rdx, [rsi]
mov rax, [rsi+8]
mov qword ptr [rdi+10h], 0
sub rax,... | long long func0(long long a1, long long *a2)
{
long long v2; // rdx
long long v3; // rax
int *v5; // rcx
int *v6; // rsi
unsigned long long v7; // rbx
int v8; // eax
int v10; // [rsp+0h] [rbp-34h] BYREF
unsigned long long v11; // [rsp+4h] [rbp-30h]
v11 = __readfsqword(0x28u);
*(_OWORD *)a1 = 0LL;
... | func0:
ENDBR64
PUSH R13
PXOR XMM0,XMM0
PUSH R12
PUSH RBP
MOV RBP,RDI
PUSH RBX
SUB RSP,0x18
MOV RAX,qword ptr FS:[0x28]
MOV qword ptr [RSP + 0x8],RAX
XOR EAX,EAX
MOVUPS xmmword ptr [RDI],XMM0
MOV RDX,qword ptr [RSI]
MOV RAX,qword ptr [RSI + 0x8]
MOV qword ptr [RDI + 0x10],0x0
SUB RAX,RDX
CMP RAX,0x4
JZ 0x001016f0
MOV R1... | /* func0(std::vector<int, std::allocator<int> > const&) */
vector * func0(vector *param_1)
{
long lVar1;
int *piVar2;
long lVar3;
ulong uVar4;
long *in_RSI;
int *piVar5;
long in_FS_OFFSET;
int local_34;
long local_30;
local_30 = *(long *)(in_FS_OFFSET + 0x28);
*(int (*) [16])param_1 = (int [... |
1,380 | func0 |
#include <cassert>
| 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 | cpp | func0(int, int):
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 <_Z5func0ii+0x26>
cmpl $0x0,-0x18(%rbp)
jne 116f <_Z5func0ii+0x26>
mov $0x1,%eax
jmp 11a7 <_Z5func0ii+0x5e>
cmpl $0x0,-0x18(%rbp)
jne 11... | _Z5func0ii:
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
m... | long long func0(int a1, int a2)
{
int v3; // ebx
if ( !a1 && !a2 )
return 1LL;
if ( !a2 )
return 0LL;
v3 = func0(a1, 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 ... | /* func0(int, int) */
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 + iV... |
1,381 | func0 |
#include <cassert>
| 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 | cpp | func0(int, int):
endbr64
mov $0x1,%eax
mov %edi,%edx
or %esi,%edx
je 1187 <_Z5func0ii+0x3e>
push %r12
push %rbp
push %rbx
mov %edi,%ebp
mov %esi,%ebx
mov %esi,%eax
test %esi,%esi
jne 116b <_Z5func0ii+0x22>
pop %rbx
pop %rbp
pop %r12
retq
lea -0x1(%rsi),%esi
callq 1149 <_Z5... | _Z5func0ii:
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]; int
call _Z... | long long func0(int a1, unsigned int a2)
{
long long result; // rax
int v3; // ebp
result = 1LL;
if ( a2 | a1 )
{
result = a2;
if ( a2 )
{
v3 = func0(a1, a2 - 1);
return v3 + (unsigned int)func0(a1 - 1, a1 - a2);
}
}
return result;
} | 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... | /* func0(int, int) */
int func0(int param_1,int param_2)
{
int iVar1;
int iVar2;
if (param_1 != 0 || param_2 != 0) {
if (param_2 != 0) {
iVar1 = func0(param_1,param_2 + -1);
iVar2 = func0(param_1 + -1,param_1 - param_2);
param_2 = iVar2 + iVar1;
}
return param_2;
}
return 1;... |
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.