// File: /workspace/github_cpp_makefile_star2_O3/MPSLab-ASU[P]DiRAC/./src/baseAccelSim.cc
// Function: baseAccelSim::read_file_kernels(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void baseAccelSim::read_file_kernels(string kernelFileName) {
	string key, value;
	uint16_t it=0;

	ifstream inFile(kernelFileName.c_str());
	if(!inFile)
	{
		cout << "Cannot open and read file: " << kernelFileName.c_str() << endl;
		exit (EXIT_FAILURE);
	}

	string line;
 	while (getline(inFile, line)) {
		// skip reading first two lines of the file
		if(it < 2) {
			it++; continue;
		}
		istringstream tokenStream(line);
		tokenStream >> key >> value;
		kernels.push_back(value);
		nameOfKernels.push_back(key);
		it++;
	}
	inFile.close();

	assert(kernels.size() > 0 && "No bytes of the kernels in the file ");
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x3e8, %rsp            # imm = 0x3E8
movq %rsi, %r14
leaq 0x30(%rsp), %r15
movq %r15, -0x10(%r15)
xorl %eax, %eax
movq %rax, -0x8(%r15)
movb %al, (%r15)
leaq 0x10(%rsp), %r12
movq %r12, -0x10(%r12)
movq %rax, -0x8(%r12)
movb %al, (%r12)
movq (%rsi), %rsi
leaq 0x60(%rsp), %rbx
movq %rbx, %rdi
movl $0x8, %edx
callq 0x461750
movq 0x60(%rsp), %rax
movq -0x18(%rax), %rcx
testb $0x5, 0x80(%rsp,%rcx)
jne 0x404f19
leaq 0x50(%rsp), %rcx
movq %rcx, -0x10(%rcx)
movq $0x0, -0x8(%rcx)
movb $0x0, (%rcx)
xorl %r14d, %r14d
leaq 0x40(%rsp), %r15
leaq 0x268(%rsp), %r12
leaq 0x20(%rsp), %r13
movq %rsp, %rbp
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x465f00
movsbl %al, %edx
movq %rbx, %rdi
movq %r15, %rsi
callq 0x41aa00
movq (%rax), %rcx
movq -0x18(%rcx), %rcx
testb $0x5, 0x20(%rax,%rcx)
jne 0x404e8c
cmpw $0x1, %r14w
jbe 0x404e7f
movq %r12, %rdi
movq %r15, %rsi
movl $0x8, %edx
callq 0x48cfb0
movq %r12, %rdi
movq %r13, %rsi
callq 0x41a680
movq %rax, %rdi
movq %rbp, %rsi
callq 0x41a680
leaq 0x206744(%rip), %rdi    # 0x60b590
movq %rbp, %rsi
callq 0x40e050
leaq 0x20671d(%rip), %rdi    # 0x60b578
movq %r13, %rsi
callq 0x40e050
movq %r12, %rdi
movq $0x606328, %rsi         # imm = 0x606328
callq 0x48d260
leaq 0x2e0(%rsp), %rdi
callq 0x467320
incl %r14d
movq 0x60(%rsp), %rax
jmp 0x404deb
leaq 0x60(%rsp), %rdi
callq 0x461d00
movq 0x2066fb(%rip), %rax    # 0x60b598
cmpq 0x2066ec(%rip), %rax    # 0x60b590
leaq 0x30(%rsp), %rbx
leaq 0x10(%rsp), %r14
je 0x404f52
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0x404ed0
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x4177e0
leaq 0x60(%rsp), %rdi
callq 0x4620b0
movq (%rsp), %rdi
cmpq %r14, %rdi
je 0x404ef0
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x4177e0
movq 0x20(%rsp), %rdi
cmpq %rbx, %rdi
je 0x404f07
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x4177e0
addq $0x3e8, %rsp            # imm = 0x3E8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq $0x60c900, %rdi         # imm = 0x60C900
leaq 0x18f0f9(%rip), %rsi    # 0x594020
movl $0x1b, %edx
callq 0x484db0
movq (%r14), %rsi
movq $0x60c900, %rdi         # imm = 0x60C900
callq 0x4852e0
movq %rax, %rdi
callq 0x484bc0
movl $0x1, %edi
callq 0x4def10
leaq 0x18f0e3(%rip), %rdi    # 0x59403c
leaq 0x18f119(%rip), %rsi    # 0x594079
leaq 0x18f128(%rip), %rcx    # 0x59408f
movl $0x35, %edx
callq 0x4d8100
movq %rax, %rbx
leaq 0x30(%rsp), %r15
leaq 0x10(%rsp), %r12
jmp 0x404fd8
jmp 0x404faf
movq %rax, %rbx
jmp 0x404fe2
jmp 0x404faf
movq %rax, %rbx
movq $0x606328, %rsi         # imm = 0x606328
leaq 0x268(%rsp), %rdi
callq 0x48d260
leaq 0x2e0(%rsp), %rdi
callq 0x467320
jmp 0x404fb2
movq %rax, %rbx
leaq 0x30(%rsp), %r15
leaq 0x10(%rsp), %r12
leaq 0x50(%rsp), %rax
movq 0x40(%rsp), %rdi
cmpq %rax, %rdi
je 0x404fd8
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x4177e0
leaq 0x60(%rsp), %rdi
callq 0x4620b0
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x404ff8
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x4177e0
movq 0x20(%rsp), %rdi
cmpq %r15, %rdi
je 0x40500f
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x4177e0
movq %rbx, %rdi
callq 0x4c34a0
nop