LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O1/tobias93[P]piano/./Synth.hpp
// Function: SimpleSynth::noteOff(unsigned char)
void noteOff(unsigned char note) 
        {
            for (std::size_t i=0; i<max_concurrency; ++i) 
            {
                if (notes[i].note == note && notes[i].pressed)
                {
                    notes[i].last_event_time_code = time_code;
                    notes[i].pressed = false;
                }
            }	
        }

// Assembly:
movl 0x18(%rdi), %eax
xorl %ecx, %ecx
cmpb %sil, 0x24(%rdi,%rcx)
jne 0x2d08
cmpb $0x1, 0x1c(%rdi,%rcx)
jne 0x2d08
movl %eax, 0x20(%rdi,%rcx)
movb $0x0, 0x1c(%rdi,%rcx)
addq $0xc, %rcx
cmpq $0x78, %rcx
jne 0x2cf1
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/tobias93[P]piano/./Synth.hpp
// Function: SimpleSynth::getEnvelopeVolume(SimpleSynth::Note const&, Envelope const&, unsigned int)
double getEnvelopeVolume(const Note& note, const Envelope& env, unsigned int t)
    {
        unsigned int time_since_last_event = t - note.last_event_time_code;
        if (note.pressed) 
        {
            unsigned int attack_time = env.attack * audio_settings->sampleRate;
            unsigned int decay_time = env.decay * audio_settings->sampleRate;
            
            if (time_since_last_event <= attack_time)
            {
                // attack
                double pos = (double)time_since_last_event / attack_time;
                return pos * env.amplitude;
            }

            time_since_last_event -= attack_time;
            if (time_since_last_event <= decay_time)
            {
                // decay
                double pos = (double)time_since_last_event / decay_time;
                return (1 - pos) * env.amplitude + pos * env.sustain;
            }

            // sustain
            return env.sustain;
            
        }
        else 
        {
            unsigned int release_time = env.release * audio_settings->sampleRate;
            if (time_since_last_event <= release_time) 
            {
                // release
                double pos = (double)time_since_last_event / release_time;
                return (double)(1 - pos) * env.sustain;
            }
            
            // off
            return 0;
            
        }
    }

// Assembly:
movq 0x8(%rdi), %rax
movl (%rax), %eax
cvtsi2sd %rax, %xmm0
subl 0x4(%rsi), %ecx
cmpb $0x1, (%rsi)
jne 0x2d81
movsd 0x8(%rdx), %xmm1
mulsd %xmm0, %xmm1
cvttsd2si %xmm1, %rsi
movl %ecx, %eax
subl %esi, %eax
jbe 0x2dba
mulsd 0x10(%rdx), %xmm0
cvttsd2si %xmm0, %rcx
cmpl %ecx, %eax
jbe 0x2dd7
movsd 0x18(%rdx), %xmm0
retq
mulsd 0x20(%rdx), %xmm0
cvttsd2si %xmm0, %rax
xorpd %xmm0, %xmm0
cmpl %eax, %ecx
ja 0x2db9
movl %ecx, %ecx
cvtsi2sd %rcx, %xmm1
movl %eax, %eax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
divsd %xmm0, %xmm1
movsd 0x258(%rip), %xmm0      # 0x3008
subsd %xmm1, %xmm0
mulsd 0x18(%rdx), %xmm0
retq
movl %ecx, %eax
xorps %xmm0, %xmm0
cvtsi2sd %rax, %xmm0
movl %esi, %eax
xorps %xmm1, %xmm1
cvtsi2sd %rax, %xmm1
mulsd (%rdx), %xmm0
divsd %xmm1, %xmm0
retq
movl %eax, %eax
xorps %xmm1, %xmm1
cvtsi2sd %rax, %xmm1
movl %ecx, %eax
cvtsi2sd %rax, %xmm2
movsd (%rdx), %xmm3
movsd 0x18(%rdx), %xmm0
subsd %xmm3, %xmm0
mulsd %xmm1, %xmm0
divsd %xmm2, %xmm0
addsd %xmm3, %xmm0
retq
// File: /workspace/github_cpp_makefile_star2_O1/iZhangHui[P]CppPrimer/CH01_GettingStarted/examples/item_io.cc
// Function: main
int main()
{
    Sales_item book;

    // read ISBN, number of copies sold, and sales price
    while(std::cin >> book) {
        // write ISBN, number of copies sold, total revenue, and average price
        std::cout << book << std::endl;
    }

    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x30, %rsp
leaq -0x40(%rbp), %r12
movq %r12, -0x10(%r12)
xorl %eax, %eax
movq %rax, -0x8(%r12)
movb $0x0, (%r12)
movl $0x0, 0x10(%r12)
movq %rax, 0x18(%r12)
movq 0x2abc(%rip), %rbx      # 0x3fe0
leaq -0x50(%rbp), %r14
movq 0x2aa1(%rip), %r15      # 0x3fd0
movq %rbx, %rdi
movq %r14, %rsi
callq 0x12f3
movq (%rbx), %rax
movq -0x18(%rax), %rax
testb $0x5, 0x20(%rbx,%rax)
jne 0x157c
movq %r15, %rdi
movq %r14, %rsi
callq 0x13c1
movq (%r15), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x10a0
movsbl %al, %esi
movq %r15, %rdi
callq 0x1030
movq %rax, %rdi
callq 0x1060
jmp 0x152f
movq -0x50(%rbp), %rdi
cmpq %r12, %rdi
je 0x1591
movq -0x40(%rbp), %rsi
incq %rsi
callq 0x10b0
xorl %eax, %eax
addq $0x30, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq -0x50(%rbp), %rdi
cmpq %r12, %rdi
je 0x15b8
movq -0x40(%rbp), %rsi
incq %rsi
callq 0x10b0
movq %rbx, %rdi
callq 0x1120
// File: /workspace/github_cpp_makefile_star2_O1/iZhangHui[P]CppPrimer/CH02_VariablesAndBasicTypes/examples/ref-ex.cc
// Function: main
int main()
{
	int i = 0, &ri = i;  // ri is a reference to i
	// ri is just another name for i; 
	// this statement prints the value of i twice
	std::cout << i << " " << ri << std::endl;

	i = 5; // changing i is reflected through ri as well
	std::cout << i << " " << ri << std::endl;

	ri = 10; // assigning to ri actually assigns to i
	std::cout << i << " " << ri << std::endl;

	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq 0x2deb(%rip), %r14      # 0x3fd8
movq %r14, %rdi
xorl %esi, %esi
callq 0x1090
movq %rax, %r15
leaq 0xe03(%rip), %rbx       # 0x2004
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x1070
movq %r15, %rdi
xorl %esi, %esi
callq 0x1090
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x1060
movsbl %al, %esi
movq %r15, %rdi
callq 0x1030
movq %rax, %rdi
callq 0x1040
movq %r14, %rdi
movl $0x5, %esi
callq 0x1090
movq %rax, %r15
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x1070
movq %r15, %rdi
movl $0x5, %esi
callq 0x1090
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x1060
movsbl %al, %esi
movq %r15, %rdi
callq 0x1030
movq %rax, %rdi
callq 0x1040
movq %r14, %rdi
movl $0xa, %esi
callq 0x1090
movq %rax, %r14
movl $0x1, %edx
movq %rax, %rdi
movq %rbx, %rsi
callq 0x1070
movq %r14, %rdi
movl $0xa, %esi
callq 0x1090
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x1060
movsbl %al, %esi
movq %rbx, %rdi
callq 0x1030
movq %rax, %rdi
callq 0x1040
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/IlyaSamoylov45[P]MapReduce-Project/main.cpp
// Function: split_input(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, int)
std::vector<std::string> split_input(std::string file, int maps){
  int word_count = count_words(file);
  //if there are more maps than words return an error
  if(maps > word_count){
    std::cout << "More maps than there are words! You gave " << maps << " maps but there are only " << word_count << " words!" << "\n" << std::endl;
    exit(EXIT_FAILURE);
  }

  std::cout << "Total words: " << word_count << std::endl;
  std::vector<std::string> ary = map_words_to_array(file, maps, word_count);
  //print for error checking
  //for (std::vector<std::string>::const_iterator i = ary.begin(); i != ary.end(); i++){
  //  std::cout << *i << '\n';
  //}
  //
  return ary;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x48, %rsp
movl %edx, %r14d
movq %rsi, %r12
movq %rdi, %rbx
leaq -0x58(%rbp), %r13
movq %r13, -0x10(%r13)
movq (%rsi), %rsi
movq 0x8(%r12), %rdx
addq %rsi, %rdx
leaq -0x68(%rbp), %r15
movq %r15, %rdi
callq 0x7b88
movq %r15, %rdi
callq 0x5d81
movl %eax, %r15d
movq -0x68(%rbp), %rdi
cmpq %r13, %rdi
je 0x4c3e
callq 0x32f0
cmpl %r14d, %r15d
jl 0x4ce8
movq 0x1b382(%rip), %r13     # 0x1ffd0
leaq 0x1152d(%rip), %rsi     # 0x16182
movl $0xd, %edx
movq %r13, %rdi
callq 0x3340
movq %r13, %rdi
movl %r15d, %esi
callq 0x3550
movq %rax, %r13
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r13, %rdi
movl $0xa, %esi
callq 0x3300
movsbl %al, %esi
movq %r13, %rdi
callq 0x3030
movq %rax, %rdi
callq 0x3200
leaq -0x38(%rbp), %r13
movq %r13, -0x10(%r13)
movq (%r12), %rsi
movq 0x8(%r12), %rdx
addq %rsi, %rdx
leaq -0x48(%rbp), %r12
movq %r12, %rdi
callq 0x7b88
movq %rbx, %rdi
movq %r12, %rsi
movl %r14d, %edx
movl %r15d, %ecx
callq 0x5f44
movq -0x48(%rbp), %rdi
cmpq %r13, %rdi
je 0x4cd6
callq 0x32f0
movq %rbx, %rax
addq $0x48, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x1b2e1(%rip), %rdi     # 0x1ffd0
leaq 0x11440(%rip), %rsi     # 0x16136
callq 0x3310
movq %rax, %rdi
movl %r14d, %esi
callq 0x3550
leaq 0x11453(%rip), %rsi     # 0x16160
movq %rax, %rdi
callq 0x3310
movq %rax, %rdi
movl %r15d, %esi
callq 0x3550
leaq 0x11453(%rip), %rsi     # 0x1617a
movq %rax, %rdi
callq 0x3310
leaq 0x112ea(%rip), %rsi     # 0x16020
movq %rax, %rdi
callq 0x3310
movq %rax, %rdi
callq 0x3170
movl $0x1, %edi
callq 0x3370
movq %rax, %rbx
movq -0x48(%rbp), %rdi
jmp 0x4d60
movq %rax, %rbx
movq -0x68(%rbp), %rdi
cmpq %r13, %rdi
je 0x4d6a
callq 0x32f0
movq %rbx, %rdi
callq 0x3560
// File: /workspace/github_cpp_makefile_star2_O1/IlyaSamoylov45[P]MapReduce-Project/main.cpp
// Function: map_threads(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>>>>, int, ThreadData*)
void map_threads(std::vector<std::string> array, int maps, ThreadData thread_data[]){
  pthread_t threads[maps];
  int iret;
  for(int i = 0; i < maps; i++){
    //std::cout << "Creating thread: " << std::endl;
    thread_data[i].id = i;
    thread_data[i].line_array= array[i];

    iret = pthread_create(&threads[i], NULL, map_function_thread, (void*) &thread_data[i]);
    if (iret != 0) {
			std::cout << "Error: Creating thread: " << iret << std::endl;
			exit(EXIT_FAILURE);
		}
  }
  for (int i = 0; i < maps; i++) {
		iret = pthread_join(threads[i], NULL);
		if (iret) {
			std::cout << "Error: Joining thread: " << iret << std::endl;
			exit(EXIT_FAILURE);
		}
		/*
		std::map<std::string, int> testMap = thread_data[i].counter;
		for(auto it = testMap.begin(); it != testMap.end(); it++){
		  std::cout << it->first << " " << it->second << std::endl;
		} */
	}

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdi, -0x50(%rbp)
movl %esi, %eax
movq %rsp, %rcx
movq %rax, -0x40(%rbp)
leaq 0xf(,%rax,8), %rax
andq $-0x10, %rax
subq %rax, %rcx
movq %rcx, -0x38(%rbp)
movq %rcx, %rsp
movl %esi, -0x2c(%rbp)
testl %esi, %esi
jle 0x4e09
movq %rdx, %r14
movq -0x40(%rbp), %rax
shlq $0x5, %rax
movq %rax, -0x48(%rbp)
xorl %r15d, %r15d
movq -0x38(%rbp), %r13
xorl %r12d, %r12d
movl %r12d, (%r14)
movq -0x50(%rbp), %rax
movq (%rax), %rsi
addq %r15, %rsi
leaq 0x8(%r14), %rdi
callq 0x31a0
movq %r13, %rdi
xorl %esi, %esi
leaq 0xa31(%rip), %rdx       # 0x5819
movq %r14, %rcx
callq 0x3590
testl %eax, %eax
jne 0x4e40
incl %r12d
addq $0x8, %r13
addq $0x58, %r14
addq $0x20, %r15
cmpq %r15, -0x48(%rbp)
jne 0x4dc6
cmpl $0x0, -0x2c(%rbp)
movq -0x40(%rbp), %r15
movq -0x38(%rbp), %r12
jle 0x4e31
xorl %r14d, %r14d
movq (%r12,%r14,8), %rdi
xorl %esi, %esi
callq 0x32c0
testl %eax, %eax
jne 0x4e52
incq %r14
cmpq %r14, %r15
jne 0x4e1a
leaq -0x28(%rbp), %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl %eax, %ebx
movq 0x1b187(%rip), %rdi     # 0x1ffd0
leaq 0x112b5(%rip), %rsi     # 0x16105
jmp 0x4e62
movl %eax, %ebx
movq 0x1b175(%rip), %rdi     # 0x1ffd0
leaq 0x112bc(%rip), %rsi     # 0x1611e
callq 0x3310
movq %rax, %rdi
movl %ebx, %esi
callq 0x3550
movq %rax, %rdi
callq 0x3170
movl $0x1, %edi
callq 0x3370
// File: /workspace/github_cpp_makefile_star2_O1/IlyaSamoylov45[P]MapReduce-Project/main.cpp
// Function: map_function_thread(void*)
void *map_function_thread(void* thread) {
	struct ThreadData *curr_thread_data;
	curr_thread_data = (struct ThreadData *) thread;

	std::vector<std::string> words = split_string_by_space(curr_thread_data->line_array);
	std::map<std::string, int> counterMap;

	for(int i = 0; i < words.size(); i++){
	  if(counterMap.count(words[i])){
	    counterMap[words[i]] = counterMap[words[i]] + 1;
	  } else {
	    counterMap[words[i]] = 1;
	  }
	}

	//test output
	curr_thread_data->counter = counterMap;
	std::map<std::string, int> testMap = curr_thread_data->counter;
	for(auto it = testMap.begin(); it != testMap.end(); it++){
	  //std::cout << it->first << " " << it->second << std::endl;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xa8, %rsp
movq %rdi, %rbx
leaq -0x58(%rbp), %r15
movq %r15, -0x10(%r15)
movq 0x8(%rdi), %rsi
movq 0x10(%rdi), %rdx
addq %rsi, %rdx
leaq -0x68(%rbp), %r14
movq %r14, %rdi
callq 0x7b88
leaq -0x40(%rbp), %rdi
movq %r14, %rsi
callq 0x5c80
movq %rbx, -0x48(%rbp)
movq -0x68(%rbp), %rdi
cmpq %r15, %rdi
je 0x586d
callq 0x32f0
leaq -0x90(%rbp), %r15
movl $0x0, (%r15)
xorl %eax, %eax
movq %rax, 0x8(%r15)
movq %r15, 0x10(%r15)
movq %r15, 0x18(%r15)
movq %rax, 0x20(%r15)
movq -0x40(%rbp), %rsi
cmpq %rsi, -0x38(%rbp)
je 0x5903
xorl %r12d, %r12d
leaq -0x98(%rbp), %r14
xorl %r13d, %r13d
addq %r12, %rsi
movq %r14, %rdi
callq 0x87ce
movq -0x40(%rbp), %rsi
addq %r12, %rsi
cmpq %r15, %rax
je 0x58da
movq %r14, %rdi
callq 0x71e4
movl (%rax), %ebx
movq -0x40(%rbp), %rsi
addq %r12, %rsi
movq %r14, %rdi
callq 0x71e4
incl %ebx
movl %ebx, (%rax)
jmp 0x58e8
movq %r14, %rdi
callq 0x71e4
movl $0x1, (%rax)
incq %r13
movq -0x40(%rbp), %rsi
movq -0x38(%rbp), %rax
subq %rsi, %rax
sarq $0x5, %rax
addq $0x20, %r12
cmpq %r13, %rax
ja 0x58a4
movq -0x48(%rbp), %rbx
addq $0x28, %rbx
leaq -0x98(%rbp), %rsi
movq %rbx, %rdi
callq 0x7856
leaq -0xc8(%rbp), %rdi
movq %rbx, %rsi
callq 0x759e
jmp 0x592d
jmp 0x592d
movq %rax, %rbx
leaq -0x98(%rbp), %rdi
callq 0x783e
leaq -0x40(%rbp), %rdi
callq 0x6f70
jmp 0x5958
movq %rax, %rbx
movq -0x68(%rbp), %rdi
cmpq %r15, %rdi
je 0x5958
callq 0x32f0
movq %rbx, %rdi
callq 0x3560
// File: /workspace/github_cpp_makefile_star2_O1/IlyaSamoylov45[P]MapReduce-Project/main.cpp
// Function: assignJobs(int, int)
std::vector<std::vector<int>> assignJobs(int reduces, int maps){
  std::vector<std::vector<int>> result;
  int amount = maps / reduces;
  int leftOver = maps % reduces;
  int counter = 0;

  for(int i = 0; i < reduces; i++){
    std::vector<int> currentReduce;
    for(int j = 0; j < amount; j++){
      currentReduce.push_back(counter);
      counter++;
    }
    result.push_back(currentReduce);
  }
  for(int i = 0; i < leftOver; i++){
    result[i].push_back(counter);
    counter++;
  }
  return result;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %edx, %eax
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
movq %rdi, -0x38(%rbp)
movq $0x0, 0x10(%rdi)
cltd
idivl %esi
movl %edx, -0x3c(%rbp)
movl $0x0, -0x2c(%rbp)
movl %esi, -0x40(%rbp)
testl %esi, %esi
jle 0x5a0b
movl %eax, %ebx
xorl %r14d, %r14d
leaq -0x60(%rbp), %r13
leaq -0x2c(%rbp), %r15
xorps %xmm0, %xmm0
movaps %xmm0, -0x60(%rbp)
movq $0x0, -0x50(%rbp)
movl %ebx, %r12d
testl %ebx, %ebx
jle 0x59e8
movq -0x58(%rbp), %rsi
cmpq -0x50(%rbp), %rsi
je 0x59d5
movl -0x2c(%rbp), %eax
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, -0x58(%rbp)
jmp 0x59e0
movq %r13, %rdi
movq %r15, %rdx
callq 0x841e
incl -0x2c(%rbp)
decl %r12d
jne 0x59bc
movq -0x38(%rbp), %rdi
movq %r13, %rsi
callq 0x71a8
movq -0x60(%rbp), %rdi
testq %rdi, %rdi
je 0x5a02
callq 0x32f0
incl %r14d
cmpl -0x40(%rbp), %r14d
jne 0x59a6
movl -0x3c(%rbp), %eax
testl %eax, %eax
jle 0x5a5d
movl %eax, %eax
shlq $0x3, %rax
leaq (%rax,%rax,2), %r15
xorl %r12d, %r12d
leaq -0x2c(%rbp), %r14
movq -0x38(%rbp), %rax
movq (%rax), %rax
leaq (%rax,%r12), %rdi
movq 0x8(%rax,%r12), %rsi
cmpq 0x10(%rax,%r12), %rsi
je 0x5a49
movl -0x2c(%rbp), %eax
movl %eax, (%rsi)
addq $0x4, %rsi
movq %rsi, 0x8(%rdi)
jmp 0x5a51
movq %r14, %rdx
callq 0x841e
incl -0x2c(%rbp)
addq $0x18, %r12
cmpq %r12, %r15
jne 0x5a23
movq -0x38(%rbp), %rax
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
jmp 0x5a88
jmp 0x5a77
movq %rax, %r14
movq -0x60(%rbp), %rdi
testq %rdi, %rdi
je 0x5a88
callq 0x32f0
movq -0x38(%rbp), %rdi
callq 0x715e
movq %r14, %rdi
callq 0x3560
// File: /workspace/github_cpp_makefile_star2_O1/IlyaSamoylov45[P]MapReduce-Project/main.cpp
// Function: split_string_by_space(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
std::vector<std::string> split_string_by_space(std::string input){
  std::string buf;
  std::stringstream ss(input);

  std::vector<std::string> words;
  while(ss >> buf)
    words.push_back(buf);

  return words;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x1b0, %rsp            # imm = 0x1B0
movq %rdi, %rbx
leaq -0x30(%rbp), %r12
movq %r12, -0x10(%r12)
movq $0x0, -0x8(%r12)
movb $0x0, (%r12)
leaq -0x1c8(%rbp), %rdi
movl $0x18, %edx
callq 0x34c0
xorps %xmm0, %xmm0
movups %xmm0, (%rbx)
movq $0x0, 0x10(%rbx)
leaq -0x1c8(%rbp), %r14
leaq -0x40(%rbp), %r15
movq %r14, %rdi
movq %r15, %rsi
callq 0x33a0
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x5cfc
movq %rbx, %rdi
movq %r15, %rsi
callq 0x74ea
jmp 0x5cd6
movq 0x1a2ad(%rip), %rsi     # 0x1ffb0
leaq -0x1c8(%rbp), %rdi
callq 0x3250
leaq -0x148(%rbp), %rdi
callq 0x30e0
movq -0x40(%rbp), %rdi
cmpq %r12, %rdi
je 0x5d29
callq 0x32f0
movq %rbx, %rax
addq $0x1b0, %rsp            # imm = 0x1B0
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
jmp 0x5d6b
movq %rax, %r14
movq %rbx, %rdi
callq 0x6f70
movq 0x1a25d(%rip), %rsi     # 0x1ffb0
leaq -0x1c8(%rbp), %rdi
callq 0x3250
leaq -0x148(%rbp), %rdi
callq 0x30e0
movq -0x40(%rbp), %rdi
cmpq %r12, %rdi
je 0x5d79
callq 0x32f0
movq %r14, %rdi
callq 0x3560
// File: /workspace/github_cpp_makefile_star2_O1/IlyaSamoylov45[P]MapReduce-Project/main.cpp
// Function: check_values(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void check_values(std::string value, std::string correct){
  if(value.compare(correct) != 0){
    std::cout << "\n" << "Usage is: --app [wordcount, sort] --impl [procs, threads] --maps num_maps --reduces num_reduces --input infile --output outfile" << std::endl;
    std::cout << "Error was in the argument " << correct << std::endl;
    std::cout << "You wrote: " << value << "\n" << std::endl;
    exit(EXIT_FAILURE);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %r15
movq %rdi, %rbx
callq 0x3040
testl %eax, %eax
jne 0x6a51
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq 0x19578(%rip), %r12     # 0x1ffd0
leaq 0xf5c1(%rip), %r14      # 0x16020
movq %r12, %rdi
movq %r14, %rsi
callq 0x3310
leaq 0xf767(%rip), %rsi      # 0x161d8
movq %rax, %rdi
callq 0x3310
movq %rax, %rdi
callq 0x3170
leaq 0xf7d0(%rip), %rsi      # 0x16258
movq %r12, %rdi
callq 0x3310
movq %rax, %rdi
movq %r15, %rsi
callq 0x32b0
movq %rax, %rdi
callq 0x3170
leaq 0xf7f1(%rip), %rsi      # 0x1629b
movq %r12, %rdi
callq 0x3310
movq %rax, %rdi
movq %rbx, %rsi
callq 0x32b0
movq %rax, %rdi
movq %r14, %rsi
callq 0x3310
movq %rax, %rdi
callq 0x3170
movl $0x1, %edi
callq 0x3370
// File: /workspace/github_cpp_makefile_star2_O1/IlyaSamoylov45[P]MapReduce-Project/main.cpp
// Function: check_file(char*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void check_file(char* filename, std::string correct){
  struct stat test;
  if (stat(filename, &test) != 0) {
    std::cout << "\n" << "Usage is: --app [wordcount, sort] --impl [procs, threads] --maps num_maps --reduces num_reduces --input infile --output outfile" << std::endl;
    std::cout << "Error was in the argument " << correct << std::endl;
    std::cout << "Error was:" << strerror(errno) << std::endl;
    std::cout << "You wrote: " << filename << "\n" << std::endl;
    exit(EXIT_FAILURE);
  }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x90, %rsp
movq %rsi, %r12
movq %rdi, %rbx
leaq -0xb0(%rbp), %rsi
callq 0x32d0
testl %eax, %eax
jne 0x6d9f
addq $0x90, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movq 0x1922a(%rip), %r15     # 0x1ffd0
leaq 0xf273(%rip), %r14      # 0x16020
movq %r15, %rdi
movq %r14, %rsi
callq 0x3310
leaq 0xf419(%rip), %rsi      # 0x161d8
movq %rax, %rdi
callq 0x3310
movq %rax, %rdi
callq 0x3170
leaq 0xf482(%rip), %rsi      # 0x16258
movq %r15, %rdi
callq 0x3310
movq %rax, %rdi
movq %r12, %rsi
callq 0x32b0
movq %rax, %rdi
callq 0x3170
leaq 0xf5ad(%rip), %rsi      # 0x163a5
movq %r15, %rdi
callq 0x3310
movq %rax, %r12
callq 0x3050
movl (%rax), %edi
callq 0x30f0
movq %r12, %rdi
movq %rax, %rsi
callq 0x3310
movq %rax, %rdi
callq 0x3170
leaq 0xf472(%rip), %rsi      # 0x1629b
movq %r15, %rdi
callq 0x3310
movq %rax, %rdi
movq %rbx, %rsi
callq 0x3310
movq %rax, %rdi
movq %r14, %rsi
callq 0x3310
movq %rax, %rdi
callq 0x3170
movl $0x1, %edi
callq 0x3370
// File: /workspace/github_cpp_makefile_star2_O1/aman-agrawal[P]Terminal-based-file-explorer/cursor_handle.cpp
// Function: cursor_handle(int&, int&)
int cursor_handle(int &x, int &y)
{
	printf("\033[%d;%dH",x,y) ; // going to x row y column
	char c;
	while(1)
{		c=getchar();
	if(c==65 && x>1) {
		//cursorup
		x--;
		mov(x,y);
	}

	else if(c==66) {
		//cursordown
		x++;
		mov(x,y);
	}		
		
	else if(c==68) {
		//cursorbackward
		return 3;
	}
	else if(c==67) {
		//cursorforward
		return 4;
	}
	else if(c==10) {
		//enter key is tapped
		return 1;
	}
	else if(c=='h'|| c=='H') {
		//home key is pressed
		return 2;
	}
	else if(c==127) {
		//backspace key is pressed
		return 5;
	}
	else if(c==':') {
		//colon is pressed
		return 6;
	}

	return -1;
		
}

}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movl (%rdi), %esi
movl (%rbx), %edx
leaq 0x3ed8(%rip), %rdi      # 0x804f
xorl %eax, %eax
callq 0x3040
callq 0x32b0
movl %eax, %ecx
movl %eax, %edx
shll $0x18, %edx
movl $0x3, %eax
cmpl $0x41ffffff, %edx       # imm = 0x41FFFFFF
jle 0x41b5
cmpl $0x42000000, %edx       # imm = 0x42000000
je 0x41f0
cmpl $0x43000000, %edx       # imm = 0x43000000
je 0x41d1
cmpl $0x44000000, %edx       # imm = 0x44000000
je 0x4244
jmp 0x4216
cmpl $0xa000000, %edx        # imm = 0xA000000
je 0x420f
cmpl $0x41000000, %edx       # imm = 0x41000000
jne 0x4216
movl (%r14), %esi
cmpl $0x2, %esi
jl 0x41d8
decl %esi
jmp 0x41f5
movl $0x4, %eax
jmp 0x4244
cmpl $0x42ffffff, %edx       # imm = 0x42FFFFFF
jg 0x419f
cmpl $0xa000000, %edx        # imm = 0xA000000
je 0x420f
cmpl $0x42000000, %edx       # imm = 0x42000000
jne 0x4216
movl (%r14), %esi
incl %esi
movl %esi, (%r14)
movl (%rbx), %edx
leaq 0x3e4e(%rip), %rdi      # 0x804f
xorl %eax, %eax
callq 0x3040
movl $0xffffffff, %eax       # imm = 0xFFFFFFFF
jmp 0x4244
movl $0x1, %eax
jmp 0x4244
andl $0xdf, %ecx
movl $0x2, %eax
cmpl $0x48, %ecx
je 0x4244
xorl %ecx, %ecx
cmpl $0x3a000000, %edx       # imm = 0x3A000000
setne %cl
negl %ecx
orl $0x6, %ecx
cmpl $0x7f000000, %edx       # imm = 0x7F000000
movl $0x5, %eax
cmovnel %ecx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O1/aman-agrawal[P]Terminal-based-file-explorer/keyboard.cpp
// Function: off_keyboard()
void off_keyboard()
{
tcgetattr(0,&initial_settings);
new_settings = initial_settings;
new_settings.c_lflag &= ~ICANON;
new_settings.c_lflag &= ~ECHO;
tcsetattr(0, TCSANOW, &new_settings);
}

// Assembly:
pushq %rax
leaq 0x6fec(%rip), %rsi      # 0xb240
xorl %edi, %edi
callq 0x3250
movups 0x6fde(%rip), %xmm0     # 0xb240
movups %xmm0, 0x7013(%rip)     # 0xb27c
movups 0x6fe0(%rip), %xmm0     # 0xb250
movups %xmm0, 0x7015(%rip)     # 0xb28c
movups 0x6fe2(%rip), %xmm0     # 0xb260
movups %xmm0, 0x7017(%rip)     # 0xb29c
movups 0x6fe0(%rip), %xmm0     # 0xb26c
movups %xmm0, 0x7015(%rip)     # 0xb2a8
andb $-0xb, 0x6fee(%rip)     # 0xb288
leaq 0x6fdb(%rip), %rdx      # 0xb27c
xorl %edi, %edi
xorl %esi, %esi
popq %rax
jmp 0x32a0
// File: /workspace/github_cpp_makefile_star2_O1/aman-agrawal[P]Terminal-based-file-explorer/aman.cpp
// Function: mycwd[abi:cxx11]()
string mycwd() {

    char cwd[1000];
   if (getcwd(cwd, sizeof(cwd)) != NULL)
   {
        string ans=cwd;
       return ans;
   }
   else
    return "error";
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x3e8, %rsp            # imm = 0x3E8
movq %rdi, %rbx
movq %rsp, %rdi
movl $0x3e8, %esi            # imm = 0x3E8
callq 0x3130
leaq 0x10(%rbx), %rcx
movq %rcx, (%rbx)
testq %rax, %rax
je 0x432d
movq %rsp, %r14
movq %r14, %rdi
callq 0x3100
leaq (%rsp,%rax), %rdx
movq %rbx, %rdi
movq %r14, %rsi
jmp 0x433e
leaq 0x3d78(%rip), %rsi      # 0x80ac
leaq 0x3d76(%rip), %rdx      # 0x80b1
movq %rbx, %rdi
callq 0x3df8
movq %rbx, %rax
addq $0x3e8, %rsp            # imm = 0x3E8
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O1/aman-agrawal[P]Terminal-based-file-explorer/aman.cpp
// Function: copyfile(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void copyfile(string a,string b){       //copy files

    ifstream f1;
    f1.open(a);

    if(!f1){
        cout<<"error in read file";
        return;
    }
    ofstream f2;
    f2.open(b);


    if(!f2){
        cout<<"error";
        return;
    }

    char line[80];

    while(f1.good()) {
        f1.getline(line, 80);
        f2 << line;
        f2 << endl;
    }
    f1.close();
    f2.close();
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x460, %rsp            # imm = 0x460
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x208(%rsp), %r15
movq %r15, %rdi
callq 0x3260
movq %r15, %rdi
movq %rbx, %rsi
movl $0x8, %edx
callq 0x31c0
movq 0x208(%rsp), %rax
movq -0x18(%rax), %rax
testb $0x5, 0x228(%rsp,%rax)
je 0x43b6
movq 0x6c30(%rip), %rdi      # 0xafd0
leaq 0x3d0b(%rip), %rsi      # 0x80b2
movl $0x12, %edx
callq 0x3270
jmp 0x44da
leaq 0x8(%rsp), %rdi
callq 0x33a0
leaq 0x8(%rsp), %rbx
movq %rbx, %rdi
movq %r14, %rsi
movl $0x10, %edx
callq 0x3120
movq 0x8(%rsp), %rax
movq -0x18(%rax), %rax
testb $0x5, 0x28(%rsp,%rax)
je 0x4402
movq 0x6be4(%rip), %rdi      # 0xafd0
leaq 0x3cb9(%rip), %rsi      # 0x80ac
movl $0x5, %edx
callq 0x3270
jmp 0x44a8
leaq 0x208(%rsp), %r14
leaq 0x410(%rsp), %r15
movq 0x208(%rsp), %rax
movq -0x18(%rax), %rax
cmpl $0x0, 0x228(%rsp,%rax)
jne 0x4491
leaq (%rsp,%rax), %rdi
addq $0x208, %rdi            # imm = 0x208
movl $0xa, %esi
callq 0x3200
movsbl %al, %ecx
movl $0x50, %edx
movq %r14, %rdi
movq %r15, %rsi
callq 0x3400
movq %r15, %rdi
callq 0x3100
movq %rbx, %rdi
movq %r15, %rsi
movq %rax, %rdx
callq 0x3270
movq 0x8(%rsp), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x3200
movsbl %al, %esi
movq %rbx, %rdi
callq 0x3030
movq %rax, %rdi
callq 0x3160
jmp 0x4412
leaq 0x208(%rsp), %rdi
callq 0x3070
leaq 0x8(%rsp), %rdi
callq 0x32d0
movq 0x6b11(%rip), %rax      # 0xafc0
movq (%rax), %rcx
movq 0x18(%rax), %rax
leaq 0x10(%rsp), %rdi
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, 0x8(%rsp,%rcx)
callq 0x31a0
leaq 0x100(%rsp), %rdi
callq 0x30c0
leaq 0x208(%rsp), %rdi
callq 0x3080
addq $0x460, %rsp            # imm = 0x460
popq %rbx
popq %r14
popq %r15
retq
jmp 0x44ff
jmp 0x44fa
jmp 0x44ff
movq %rax, %rbx
jmp 0x450c
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x32f0
leaq 0x208(%rsp), %rdi
callq 0x3080
movq %rbx, %rdi
callq 0x33b0
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./DataGenerator.cpp
// Function: DataGenerator::get_stat_one_sample(int, double*, double*)
double DataGenerator::get_stat_one_sample(int num_buckets, double *upper_intervals, double *lower_intervals)
{
  if (num_buckets <= 0)
    throw ParameterError();
  double expected = (double)stream_size / num_buckets;
  double chi_squared = 0;
  for (int i = 1; i <= num_buckets; i++)
  { 
    double observed = 0;
    for (int j = 0; j < stream_size; j++)
    {
      if (stream[j] <= upper_intervals[i] && stream[j] > lower_intervals[i])
	observed++;
    }
    chi_squared += (observed - expected) * (observed - expected) / expected;
  }
  return chi_squared;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
testl %esi, %esi
jle 0x27db
movl 0x8(%rdi), %eax
cvtsi2sd %eax, %xmm1
cvtsi2sd %esi, %xmm0
divsd %xmm0, %xmm1
movq (%rdi), %rdi
incl %esi
xorpd %xmm0, %xmm0
movl $0x1, %r8d
movsd 0x6878(%rip), %xmm2     # 0x9008
xorpd %xmm3, %xmm3
testl %eax, %eax
jle 0x27c1
movsd (%rdx,%r8,8), %xmm4
xorl %r9d, %r9d
movsd (%rdi,%r9,8), %xmm5
ucomisd %xmm5, %xmm4
jb 0x27b9
ucomisd (%rcx,%r8,8), %xmm5
jbe 0x27b9
addsd %xmm2, %xmm3
incq %r9
cmpq %r9, %rax
jne 0x27a1
subsd %xmm1, %xmm3
mulsd %xmm3, %xmm3
divsd %xmm1, %xmm3
addsd %xmm3, %xmm0
incq %r8
cmpq %rsi, %r8
jne 0x2790
popq %rbp
retq
movl $0x1, %edi
callq 0x2100
leaq 0xa48c(%rip), %rsi      # 0xcc78
movq %rax, %rdi
xorl %edx, %edx
callq 0x2330
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./DataGenerator.cpp
// Function: DataGenerator::get_stat_two_sample(DataGenerator const&, int, double*, double*)
double DataGenerator::get_stat_two_sample(const DataGenerator& other, int num_buckets, double *upper_intervals, double *lower_intervals)
{
  if (num_buckets <= 0)
    throw ParameterError();
  double *stream2 = other.stream;
  int stream2_size = other.stream_size;
  double constant_1 = sqrt((double)stream2_size/stream_size);
  double constant_2 = sqrt((double)stream_size/stream2_size);
  double chi_squared = 0;
  for (int i = 0; i < num_buckets; i++)
  {
    double frequency1 = 0, frequency2 = 0;
    for (int j = 0; j < stream_size; j++)
    {
      if (stream[j] <= upper_intervals[i+1] && stream[j] > lower_intervals[i+1])
	frequency1++;
    }
    for (int j = 0; j < stream2_size; j++)
    {
      if (stream2[j] <= upper_intervals[i+1] && stream2[j] > lower_intervals[i+1])
	frequency2++;
    }
    double lambda = frequency1 * constant_1 - frequency2 * constant_2;
    chi_squared += (lambda * lambda) / (frequency1 + frequency2);
  }
  return chi_squared;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
testl %edx, %edx
jle 0x294b
movq %r8, %rbx
movq %rcx, %r14
movq %rdi, %r12
movl 0x8(%rsi), %r13d
cvtsi2sd %r13d, %xmm2
movq (%rsi), %r15
cvtsi2sdl 0x8(%rdi), %xmm1
movapd %xmm2, %xmm0
divsd %xmm1, %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
movl %edx, -0x2c(%rbp)
jb 0x2844
sqrtsd %xmm0, %xmm7
jmp 0x285b
movsd %xmm2, -0x38(%rbp)
callq 0x2190
xorpd %xmm1, %xmm1
movsd -0x38(%rbp), %xmm2
movapd %xmm0, %xmm7
xorps %xmm0, %xmm0
cvtsi2sdl 0x8(%r12), %xmm0
divsd %xmm2, %xmm0
ucomisd %xmm1, %xmm0
jb 0x2875
sqrtsd %xmm0, %xmm0
jmp 0x2884
movsd %xmm7, -0x38(%rbp)
callq 0x2190
movsd -0x38(%rbp), %xmm7
movl -0x2c(%rbp), %edx
movl 0x8(%r12), %eax
movq (%r12), %rcx
movl %edx, %edx
xorpd %xmm1, %xmm1
xorl %esi, %esi
movsd 0x6768(%rip), %xmm2     # 0x9008
xorpd %xmm3, %xmm3
testl %eax, %eax
jle 0x28d0
movsd 0x8(%r14,%rsi,8), %xmm4
xorl %edi, %edi
movsd (%rcx,%rdi,8), %xmm5
ucomisd %xmm5, %xmm4
jb 0x28c8
ucomisd 0x8(%rbx,%rsi,8), %xmm5
jbe 0x28c8
addsd %xmm2, %xmm3
incq %rdi
cmpq %rdi, %rax
jne 0x28b1
testl %r13d, %r13d
jle 0x2904
movsd 0x8(%r14,%rsi,8), %xmm5
xorpd %xmm4, %xmm4
xorl %edi, %edi
movsd (%r15,%rdi,8), %xmm6
ucomisd %xmm6, %xmm5
jb 0x28fa
ucomisd 0x8(%rbx,%rsi,8), %xmm6
jbe 0x28fa
addsd %xmm2, %xmm4
incq %rdi
cmpq %rdi, %r13
jne 0x28e2
jmp 0x2908
xorpd %xmm4, %xmm4
movapd %xmm0, %xmm5
mulsd %xmm4, %xmm5
movapd %xmm3, %xmm6
mulsd %xmm7, %xmm6
subsd %xmm5, %xmm6
mulsd %xmm6, %xmm6
addsd %xmm4, %xmm3
divsd %xmm3, %xmm6
addsd %xmm6, %xmm1
incq %rsi
cmpq %rdx, %rsi
jne 0x28a0
movapd %xmm1, %xmm0
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movl $0x1, %edi
callq 0x2100
leaq 0xa31c(%rip), %rsi      # 0xcc78
movq %rax, %rdi
xorl %edx, %edx
callq 0x2330
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/QuantileSketch.h
// Function: QuantileSketch::reverseQuantile(double, int)
double QuantileSketch::reverseQuantile(double r, int n)
{
  int lo=0, hi= n;
  while (lo < hi)
  {
    int mid = (lo+hi)/2;
    double value = getQuantile(((double)mid)/n);
    if (value < r)
      lo = mid+1;
    else
      hi = mid;
  }
  return lo;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x10, %rsp
movsd %xmm0, -0x30(%rbp)
testl %esi, %esi
jle 0x29d4
movl %esi, %ebx
movq %rdi, %r14
xorps %xmm0, %xmm0
cvtsi2sd %esi, %xmm0
movsd %xmm0, -0x28(%rbp)
xorl %r15d, %r15d
leal (%r15,%rbx), %r12d
shrl %r12d
xorps %xmm0, %xmm0
cvtsi2sd %r12d, %xmm0
divsd -0x28(%rbp), %xmm0
movq (%r14), %rax
movq %r14, %rdi
callq *0x8(%rax)
movsd -0x30(%rbp), %xmm1
ucomisd %xmm0, %xmm1
ja 0x29bf
movl %r12d, %ebx
jmp 0x29c5
incl %r12d
movl %r12d, %r15d
cmpl %ebx, %r15d
jl 0x2992
xorps %xmm0, %xmm0
cvtsi2sd %r15d, %xmm0
jmp 0x29d8
xorpd %xmm0, %xmm0
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/GK.cpp
// Function: GK::GK(int)
GK::GK(int maxTuples)
{
	num_tuples=0;
	num_observations=0;
	max=maxTuples;
	summary=new Tuple*[maxTuples];
	for (int i = 0; i < max; i++)
		summary[i] = NULL;
	stream_size =0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %r14d
movq %rdi, %rbx
leaq 0xa29b(%rip), %rax      # 0xcc98
movq %rax, (%rdi)
movl $0x0, 0x18(%rdi)
movq $0x0, 0x20(%rdi)
movl %esi, 0x8(%rdi)
movslq %esi, %r15
leaq (,%r15,8), %rax
testl %r15d, %r15d
movq $-0x1, %rdi
cmovnsq %rax, %rdi
callq 0x2030
movq %rax, 0x10(%rbx)
testl %r15d, %r15d
jle 0x2a52
movl %r14d, %eax
xorl %ecx, %ecx
movq 0x10(%rbx), %rdx
movq $0x0, (%rdx,%rcx,8)
incq %rcx
cmpq %rcx, %rax
jne 0x2a3e
movq $0x0, 0x28(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/GK.cpp
// Function: GK::insert(double)
void GK::insert(double val)
{ 
	stream_size +=1; 
	int index= find_index(val);
	if(summary[index]==NULL)
	{
		insert_tuple(new Tuple(val),index); 
	}
	else
	{
		double store=summary[index]->g+summary[index]->delta-1; 
		insert_tuple(new Tuple(val,1.0,store),index);
	}
	if(num_tuples==max)
		delete_merge();
	num_observations++;

}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
incq 0x28(%rdi)
movl 0x18(%rdi), %r12d
movl %r12d, %eax
testl %r12d, %r12d
jle 0x2b14
movq 0x10(%rbx), %rcx
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
movl %r12d, %eax
leal (%rdx,%rax), %edi
movl %edi, %esi
shrl $0x1f, %esi
addl %edi, %esi
sarl %esi
movslq %esi, %rdi
movq (%rcx,%rdi,8), %rdi
movsd (%rdi), %xmm1
ucomisd %xmm0, %xmm1
ja 0x2b09
movl %esi, %edx
jmp 0x2b0b
movl %esi, %eax
movl %eax, %esi
subl %edx, %esi
cmpl $0x1, %esi
jg 0x2ae8
movq 0x10(%rbx), %rcx
movslq %eax, %r13
leaq (%rcx,%r13,8), %r14
movq (%r14), %rax
testq %rax, %rax
movsd %xmm0, -0x38(%rbp)
je 0x2b40
movsd 0x8(%rax), %xmm0
addsd 0x10(%rax), %xmm0
addsd 0x64da(%rip), %xmm0     # 0x9018
jmp 0x2b44
xorpd %xmm0, %xmm0
movsd %xmm0, -0x30(%rbp)
movl $0x18, %edi
callq 0x2220
movq %rax, %r15
movsd -0x38(%rbp), %xmm0
movsd %xmm0, (%rax)
movabsq $0x3ff0000000000000, %rax # imm = 0x3FF0000000000000
movq %rax, 0x8(%r15)
movsd -0x30(%rbp), %xmm0
movsd %xmm0, 0x10(%r15)
subl %r13d, %r12d
shll $0x3, %r12d
leaq 0x8(%r14), %rdi
movslq %r12d, %rdx
movq %r14, %rsi
callq 0x22e0
movq 0x10(%rbx), %rax
movq %r15, (%rax,%r13,8)
movl 0x18(%rbx), %eax
incl %eax
movl %eax, 0x18(%rbx)
cmpl 0x8(%rbx), %eax
jne 0x2bab
movq %rbx, %rdi
callq 0x2c4e
incq 0x20(%rbx)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/GK.cpp
// Function: GK::find_index(double)
int GK::find_index(double val)
{
	int high= num_tuples;int low=-1,mid;
	while(high-low >1)
	{
		mid=(high+low)/2;
		if(summary[mid]->v >val)
			high=mid;
		else
			low=mid;
	}
	return high;
}

// Assembly:
movl 0x18(%rdi), %eax
testl %eax, %eax
jle 0x2bff
pushq %rbp
movq %rsp, %rbp
movq 0x10(%rdi), %rcx
movl $0xffffffff, %edx       # imm = 0xFFFFFFFF
leal (%rax,%rdx), %edi
movl %edi, %esi
shrl $0x1f, %esi
addl %edi, %esi
sarl %esi
movslq %esi, %rdi
movq (%rcx,%rdi,8), %rdi
movsd (%rdi), %xmm1
ucomisd %xmm0, %xmm1
ja 0x2bf3
movl %esi, %edx
jmp 0x2bf5
movl %esi, %eax
movl %eax, %esi
subl %edx, %esi
cmpl $0x1, %esi
jg 0x2bd2
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/GK.cpp
// Function: GK::insert_tuple(Tuple*, int)
void GK::insert_tuple(Tuple* t,int index)
{	
	/*int destpos=num_tuples;
	int srcpos=num_tuples-1;
	for(int i=0;i<num_tuples-index;i++)
	{	
		summary[destpos]=summary[srcpos];
		srcpos--;
		destpos--;
	}*/
	
	int size_of_pointer= sizeof(summary[0]);
        int total_size=size_of_pointer * (num_tuples-index);
        memmove(&(summary[index+1]),&(summary[index]),total_size);
	
	summary[index]=t;
	num_tuples++;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movslq 0x18(%rdi), %rax
movslq %edx, %r15
subq %r15, %rax
shlq $0x3, %rax
movq 0x10(%rdi), %rcx
leaq (%rcx,%r15,8), %rsi
leaq (%rcx,%r15,8), %rdi
addq $0x8, %rdi
movq %rax, %rdx
callq 0x22e0
movq 0x10(%r14), %rax
movq %rbx, (%rax,%r15,8)
incl 0x18(%r14)
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/GK.cpp
// Function: GK::delete_merge()
void GK::delete_merge()
{	
	int leastIndex = 0;
	long leastFull= LLONG_MAX;
        for (int i = 1; i <num_tuples - 1; i++) 
        {
            long f = summary[i]->g + summary[i + 1]->g+summary[i + 1]->delta;   
            if ((summary[i]->delta >=summary[i + 1]->delta)
                    && (f < leastFull)) 
            {
                leastFull = f;
                leastIndex = i;
            }
        }
        if (leastIndex > 0) 
            delete_tuple(leastIndex);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl 0x18(%rdi), %eax
xorl %esi, %esi
cmpl $0x3, %eax
jl 0x2cc4
decl %eax
movq 0x10(%rdi), %rcx
movabsq $0x7fffffffffffffff, %rdx # imm = 0x7FFFFFFFFFFFFFFF
xorl %esi, %esi
movl $0x1, %r8d
movq (%rcx,%r8,8), %r9
movq 0x8(%rcx,%r8,8), %r10
movsd 0x8(%r9), %xmm0
movsd 0x10(%r9), %xmm1
addsd 0x8(%r10), %xmm0
movsd 0x10(%r10), %xmm2
addsd %xmm2, %xmm0
cvttsd2si %xmm0, %r9
ucomisd %xmm2, %xmm1
setae %r10b
cmpq %r9, %rdx
setg %r11b
testb %r11b, %r10b
cmovnel %r8d, %esi
leaq 0x1(%r8), %r10
cmovneq %r9, %rdx
movq %r10, %r8
cmpq %r10, %rax
jne 0x2c74
testl %esi, %esi
jle 0x2cce
popq %rbp
jmp 0x2cd0
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/GK.cpp
// Function: GK::delete_tuple(int)
void GK::delete_tuple(int index)
{	
        Tuple *hold  = summary[index];
	summary[index] = new Tuple(summary[index + 1]->v,
                summary[index]->g + summary[index + 1]->g,
                summary[index + 1]->delta);
        delete hold;
	delete summary[index+1];
        int size_of_pointer= sizeof(summary[0]);
        int total_size=size_of_pointer * (num_tuples-index-2);
        memmove(&(summary[index+1]),&(summary[index+2]),total_size);
	summary[num_tuples-1]=NULL;
	num_tuples--;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x10(%rdi), %r13
movslq %esi, %r15
movq (%r13,%r15,8), %r14
movl $0x18, %edi
callq 0x2220
movq (%r13,%r15,8), %rcx
movq 0x8(%r13,%r15,8), %rdx
movsd 0x8(%rcx), %xmm0
addsd 0x8(%rdx), %xmm0
leaq 0x1(%r15), %r12
movsd (%rdx), %xmm1
movsd 0x10(%rdx), %xmm2
movsd %xmm1, (%rax)
movsd %xmm0, 0x8(%rax)
movsd %xmm2, 0x10(%rax)
movq %rax, (%r13,%r15,8)
testq %r14, %r14
je 0x2d38
movq %r14, %rdi
callq 0x21f0
movq 0x10(%rbx), %rax
movq (%rax,%r12,8), %rdi
testq %rdi, %rdi
je 0x2d4a
callq 0x21f0
movl 0x18(%rbx), %eax
subl %r15d, %eax
leal -0x10(,%rax,8), %eax
movq 0x10(%rbx), %rcx
leaq (%rcx,%r12,8), %rdi
leaq (%rcx,%r15,8), %rsi
addq $0x10, %rsi
movslq %eax, %rdx
callq 0x22e0
movq 0x10(%rbx), %rax
movslq 0x18(%rbx), %rcx
movq $0x0, -0x8(%rax,%rcx,8)
leal -0x1(%rcx), %eax
movl %eax, 0x18(%rbx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/GK.cpp
// Function: GK::getQuantile(double)
double GK::getQuantile(double quant)
{
	long rank= (long) ceil(quant* num_observations);
	long current_rank=0;
	for (int i = 0; i < num_tuples - 1; i++)
	{
		current_rank +=summary[i]->g;
		if ((current_rank +summary[i + 1]->g) > rank)
            	    return summary[i]->v;
        }
        return summary[num_tuples - 1]->v;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %rbx
pushq %rax
movq %rdi, %rbx
cvtsi2sdq 0x20(%rdi), %xmm1
mulsd %xmm1, %xmm0
callq 0x2080
cvttsd2si %xmm0, %rdx
movslq 0x18(%rbx), %rax
leaq -0x1(%rax), %rcx
movq 0x10(%rbx), %rsi
xorps %xmm0, %xmm0
cvtsi2sd %rdx, %xmm0
xorl %edx, %edx
testl %ecx, %ecx
movl $0x0, %edi
cmovgl %ecx, %edi
xorl %r9d, %r9d
cmpq %rdx, %rdi
je 0x2e1e
movq (%rsi,%rdx,8), %r8
xorps %xmm1, %xmm1
cvtsi2sd %r9, %xmm1
addsd 0x8(%r8), %xmm1
cvttsd2si %xmm1, %r9
movq 0x8(%rsi,%rdx,8), %r10
xorps %xmm1, %xmm1
cvtsi2sd %r9, %xmm1
incq %rdx
addsd 0x8(%r10), %xmm1
ucomisd %xmm0, %xmm1
jbe 0x2dd6
decq %rdx
cmpq %rcx, %rdx
setl %cl
movsd (%r8), %xmm0
jmp 0x2e24
cmpq %rcx, %rdx
setl %cl
testb %cl, %cl
jne 0x2e35
movq 0x10(%rbx), %rcx
movq -0x8(%rcx,%rax,8), %rax
movsd (%rax), %xmm0
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/ReservoirSampling.cpp
// Function: ReservoirSampling::copy(ReservoirSampling const&)
void ReservoirSampling::copy(const ReservoirSampling& other)
{
  sample_size = other.sample_size;
  stream_size = other.stream_size;
  array = new double[sample_size];
  for (int i = 0; i < sample_size; i++)
    array[i] = other.array[i];
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
movslq 0xc(%rsi), %r15
leaq (,%r15,8), %rax
testq %r15, %r15
movl %r15d, 0xc(%rdi)
movl 0x8(%rsi), %ecx
movl %ecx, 0x8(%rdi)
movq $-0x1, %rdi
cmovnsq %rax, %rdi
callq 0x2030
movq %rax, 0x10(%r14)
testq %r15, %r15
jle 0x2ef0
movq 0x10(%rbx), %rcx
xorl %edx, %edx
movsd (%rcx,%rdx,8), %xmm0
movsd %xmm0, (%rax,%rdx,8)
incq %rdx
cmpq %rdx, %r15
jne 0x2ede
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/ReservoirSampling.cpp
// Function: ReservoirSampling::insert(double)
void ReservoirSampling::insert(double value)
{
  stream_size += 1; //incrementing the size of the stream as a new element is inserted
  if (stream_size <= sample_size) //Checking if stream size is less than random sample size
    array[stream_size - 1] = value;
  else if ((rand() % stream_size + 1) <= sample_size)
    array[(rand() % sample_size)] = value;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movl 0x8(%rdi), %edx
leal 0x1(%rdx), %eax
movl %eax, 0x8(%rdi)
cmpl 0xc(%rdi), %edx
jge 0x2f6c
movq 0x10(%rbx), %r14
jmp 0x2f91
movsd %xmm0, -0x18(%rbp)
callq 0x2090
cltd
idivl 0x8(%rbx)
cmpl 0xc(%rbx), %edx
jge 0x2f9a
movq 0x10(%rbx), %r14
callq 0x2090
cltd
idivl 0xc(%rbx)
movsd -0x18(%rbp), %xmm0
movslq %edx, %rax
movsd %xmm0, (%r14,%rax,8)
addq $0x10, %rsp
popq %rbx
popq %r14
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/ReservoirSampling.cpp
// Function: ReservoirSampling::getQuantile(double)
double ReservoirSampling::getQuantile(double fraction)
{
  sort(array, array + sample_size); // sorting from range s to s+k
  if (fraction >= 1) 
    return array[sample_size - 1];// if f is greater than one
  else if (fraction < 0) 
    return array[0];//if f is less than 1
  else
    return array[(int)(fraction * sample_size)]; //if f is between 0 and 1. 
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
movslq 0xc(%rdi), %rax
testq %rax, %rax
je 0x2fef
movq 0x10(%rbx), %r14
leaq (%r14,%rax,8), %r15
bsrq %rax, %rdx
xorl $0x3f, %edx
addl %edx, %edx
xorq $0x7e, %rdx
movq %r14, %rdi
movq %r15, %rsi
movsd %xmm0, -0x20(%rbp)
callq 0x70d4
movq %r14, %rdi
movq %r15, %rsi
callq 0x71be
movsd -0x20(%rbp), %xmm0
ucomisd 0x6011(%rip), %xmm0     # 0x9008
jae 0x3020
xorpd %xmm1, %xmm1
ucomisd %xmm0, %xmm1
movq 0x10(%rbx), %rax
ja 0x3030
xorps %xmm1, %xmm1
cvtsi2sdl 0xc(%rbx), %xmm1
mulsd %xmm0, %xmm1
cvttsd2si %xmm1, %ecx
movslq %ecx, %rcx
leaq (%rax,%rcx,8), %rax
jmp 0x3030
movq 0x10(%rbx), %rax
movslq 0xc(%rbx), %rcx
leaq (%rax,%rcx,8), %rax
addq $-0x8, %rax
movsd (%rax), %xmm0
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/Q-Digest.cpp
// Function: QDigest::QDigest(double)
QDigest::QDigest(double compression)
{
  compression_factor = compression; 
  capacity = 1;
  size = 0;
  stream_size = 0;
  min = MAX_VALUE;
  max = -MAX_VALUE;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
leaq 0x9c9d(%rip), %rax      # 0xcce8
movq %rax, (%rdi)
leaq 0x38(%rdi), %rax
movq %rax, 0x8(%rdi)
movl $0x1, %eax
movq %rax, 0x10(%rdi)
xorps %xmm1, %xmm1
movups %xmm1, 0x18(%rdi)
movl $0x3f800000, 0x28(%rdi) # imm = 0x3F800000
movups %xmm1, 0x30(%rdi)
movsd %xmm0, 0x60(%rdi)
movq %rax, 0x48(%rdi)
xorl %eax, %eax
movq %rax, 0x40(%rdi)
movq %rax, 0x68(%rdi)
movq $0x3b9aca00, 0x50(%rdi) # imm = 0x3B9ACA00
movq $-0x3b9aca00, 0x58(%rdi) # imm = 0xC4653600
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/Q-Digest.cpp
// Function: QDigest::copy(QDigest const&)
void QDigest::copy(const QDigest& other)
{
  node2count = other.node2count;
  compression_factor = other.compression_factor;
  capacity = other.capacity;
  size = other.size;
  min = other.min;
  max = other.max;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r14
pushq %rbx
movq %rsi, %r14
movq %rdi, %rbx
cmpq %rdi, %rsi
je 0x3109
leaq 0x8(%rbx), %rdi
leaq 0x8(%r14), %rsi
callq 0x6ade
movsd 0x60(%r14), %xmm0
movsd %xmm0, 0x60(%rbx)
movq 0x48(%r14), %rax
movq %rax, 0x48(%rbx)
movq 0x40(%r14), %rax
movq %rax, 0x40(%rbx)
movq 0x50(%r14), %rax
movq %rax, 0x50(%rbx)
movq 0x58(%r14), %rax
movq %rax, 0x58(%rbx)
popq %rbx
popq %r14
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O1/ashlall[P]StreamStats/ChiSquareExperiments/./../SourceCode/ChiSquare/../Quantiles/Q-Digest.cpp
// Function: QDigest::insert(double)
void QDigest::insert(double value)
{
  stream_size += 1;
  if (value < min)
    min = value;
  if (value > max)
    max = value;
  offer(value);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
incq 0x68(%rdi)
cvtsi2sdq 0x50(%rdi), %xmm1
ucomisd %xmm0, %xmm1
cvttsd2si %xmm0, %rsi
jbe 0x316f
movq %rsi, 0x50(%rdi)
xorps %xmm1, %xmm1
cvtsi2sdq 0x58(%rdi), %xmm1
ucomisd %xmm1, %xmm0
jbe 0x3182
movq %rsi, 0x58(%rdi)
popq %rbp
jmp 0x3188