LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: gvaumour[P]cache-simulator/src/DBAMBPredictor.hh
// Function: DHPEntry::initEntry(Access)
void initEntry(Access element) {
		 	cpts =  std::vector<int>(NUM_RW_TYPE,0);
		 	lastWrite = 0;
		 	signature = 0;
		 	des = ALLOCATE_PREEMPTIVELY;
		 	
		 	policyInfo = 0;
			cptBypassLearning = 0;
			rd_history.clear();
			rw_history.clear();
			nbAccess = 0;
			isValid = true;
			
			state_rw = RW_NOT_ACCURATE;
			state_rd = RD_NOT_ACCURATE;
			
			nbKeepCurrentState = 0;
			nbKeepState = 0;
			nbSwitchState = 0;
			cptWindow = 0;
			
			dead_counter = 0;
		 }

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x40(%rsp)
movq 0x40(%rsp), %rax
movq %rax, (%rsp)
movl $0x0, 0x24(%rsp)
leaq 0x23(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0xed30
movq 0x8(%rsp), %rcx
leaq 0x28(%rsp), %rdi
movl $0x5, %esi
leaq 0x24(%rsp), %rdx
callq 0xed40
jmp 0x209e4
movq (%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0xf150
leaq 0x28(%rsp), %rdi
callq 0xef00
leaq 0x23(%rsp), %rdi
callq 0xef60
movq (%rsp), %rdi
movl $0x0, 0x1c(%rdi)
movq $0x0, 0x20(%rdi)
movl $0x3, 0x28(%rdi)
movl $0x0, 0x2c(%rdi)
movl $0x0, 0x38(%rdi)
addq $0x40, %rdi
callq 0x20c50
movq (%rsp), %rdi
addq $0x58, %rdi
callq 0x20c70
movq (%rsp), %rax
movl $0x0, 0x80(%rax)
movb $0x1, 0x88(%rax)
movl $0x4, 0x98(%rax)
movl $0x2, 0x9c(%rax)
movl $0x0, 0x94(%rax)
movl $0x0, 0x8c(%rax)
movl $0x0, 0x90(%rax)
movl $0x0, 0x84(%rax)
movl $0x0, 0xb8(%rax)
addq $0x48, %rsp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
leaq 0x23(%rsp), %rdi
callq 0xef60
movq 0x18(%rsp), %rdi
callq 0x5690
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/Directory.cc
// Function: Directory::Directory()
Directory::Directory()
{
	m_nb_set = DIRECTORY_NB_SETS;
	m_assoc = DIRECTORY_ASSOC;

	//DPRINTF("DIRECTORY::Constructor , assoc=%d , m_nb_set=%d\n", m_assoc , m_nb_set);

	m_table.resize(m_nb_set);
	for(int i = 0  ; i < m_nb_set ; i++){
//		m_table[i].resize(m_assoc);
		m_table[i].clear();
		/*
		for(int j = 0 ; j < m_assoc ; j++){
			m_table[i][j] = new DirectoryEntry();
		}*/
	}
		
	m_policy = new DirectoryReplacementPolicy(m_assoc , m_nb_set , m_table);
	m_start_index = log2(BLOCK_SIZE)-1;
	m_end_index = log2(BLOCK_SIZE) + log2(m_nb_set);
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x40(%rsp)
movq 0x40(%rsp), %rdi
movq %rdi, 0x28(%rsp)
movq %rdi, %rax
movq %rax, 0x20(%rsp)
callq 0x283f0
movq 0x28(%rsp), %rdi
movl $0x800, 0x20(%rdi)      # imm = 0x800
movl $0x40, 0x24(%rdi)
movslq 0x20(%rdi), %rsi
callq 0x28400
jmp 0x2776e
movl $0x0, 0x30(%rsp)
movq 0x20(%rsp), %rcx
movl 0x30(%rsp), %eax
cmpl 0x20(%rcx), %eax
jge 0x277bb
movq 0x20(%rsp), %rdi
movslq 0x30(%rsp), %rsi
callq 0x284a0
movq %rax, %rdi
callq 0x284c0
movl 0x30(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x30(%rsp)
jmp 0x27776
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x38(%rsp)
movl %eax, 0x34(%rsp)
jmp 0x2787f
movl $0x18, %edi
callq 0x53a0
movq %rax, 0x18(%rsp)
jmp 0x277cc
movq 0x20(%rsp), %rcx
movq 0x18(%rsp), %rdi
movl 0x20(%rcx), %edx
movl 0x24(%rcx), %esi
callq 0x283a0
jmp 0x277e3
movq 0x20(%rsp), %rax
movq 0x18(%rsp), %rcx
movq %rcx, 0x18(%rax)
movl $0x40, %edi
callq 0x284e0
movsd %xmm0, 0x10(%rsp)
jmp 0x27803
movq 0x20(%rsp), %rax
movsd 0x10(%rsp), %xmm0
movsd 0x4a73a(%rip), %xmm1    # 0x71f50
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %ecx
movl %ecx, 0x2c(%rax)
movl $0x40, %edi
callq 0x284e0
movsd %xmm0, 0x8(%rsp)
jmp 0x27833
movq 0x20(%rsp), %rax
movl 0x20(%rax), %edi
callq 0x284e0
movsd %xmm0, (%rsp)
jmp 0x27847
movq 0x20(%rsp), %rax
movsd (%rsp), %xmm1
movsd 0x8(%rsp), %xmm0
addsd %xmm1, %xmm0
cvttsd2si %xmm0, %ecx
movl %ecx, 0x28(%rax)
addq $0x48, %rsp
retq
movq 0x18(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x38(%rsp)
movl %eax, 0x34(%rsp)
callq 0x5340
movq 0x28(%rsp), %rdi
callq 0x28500
movq 0x38(%rsp), %rdi
callq 0x5690
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/Directory.cc
// Function: Directory::~Directory()
Directory::~Directory()
{
	for(auto sets : m_table)
	{
		for(auto entry : sets)
			delete entry;
	}
	delete m_policy;
}

// Assembly:
subq $0x78, %rsp
movq %rdi, 0x70(%rsp)
movq 0x70(%rsp), %rax
movq %rax, 0x18(%rsp)
movq %rax, 0x68(%rsp)
movq 0x68(%rsp), %rdi
callq 0x28560
movq %rax, 0x60(%rsp)
movq 0x68(%rsp), %rdi
callq 0x28590
movq %rax, 0x58(%rsp)
leaq 0x60(%rsp), %rdi
leaq 0x58(%rsp), %rsi
callq 0x285c0
testb $0x1, %al
jne 0x278ee
jmp 0x279a1
leaq 0x60(%rsp), %rdi
callq 0x28600
movq %rax, %rsi
leaq 0x40(%rsp), %rdi
callq 0x28610
jmp 0x27907
leaq 0x40(%rsp), %rax
movq %rax, 0x38(%rsp)
movq 0x38(%rsp), %rdi
callq 0x28710
movq %rax, 0x30(%rsp)
movq 0x38(%rsp), %rdi
callq 0x28740
movq %rax, 0x28(%rsp)
leaq 0x30(%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0x28770
testb $0x1, %al
jne 0x27944
jmp 0x27988
leaq 0x30(%rsp), %rdi
callq 0x287b0
movq (%rax), %rax
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x10(%rsp)
cmpq $0x0, %rax
je 0x2797a
movq 0x10(%rsp), %rdi
callq 0x287c0
movq 0x10(%rsp), %rdi
callq 0x5340
jmp 0x2797c
leaq 0x30(%rsp), %rdi
callq 0x287d0
jmp 0x2792f
leaq 0x40(%rsp), %rdi
callq 0x287f0
leaq 0x60(%rsp), %rdi
callq 0x28850
jmp 0x278d6
movq 0x18(%rsp), %rax
movq 0x18(%rax), %rax
movq %rax, 0x8(%rsp)
cmpq $0x0, %rax
je 0x279bf
movq 0x8(%rsp), %rdi
callq 0x5340
movq 0x18(%rsp), %rdi
callq 0x28500
addq $0x78, %rsp
retq
movq %rax, %rdi
callq 0x10690
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/Directory.cc
// Function: Directory::addEntry(unsigned long, bool)
DirectoryEntry*
Directory::addEntry(uint64_t addr , bool isInst)
{
	if(getEntry(addr) != NULL)
		return getEntry(addr);	
	
	uint64_t id_set = indexFunction(addr);
//	int assoc_victim = m_policy->evictPolicy(id_set);
		
	DirectoryEntry* entry = new DirectoryEntry();
	
	/*if(entry->isValid)
	{
	
//		cout << "ID SET =" << id_set << endl;
		//DPRINTF("DIRECTORY::Eviction of dir entry, Block_addr[%#lx] \n", entry->block_addr);
		cout << "Assoc victim =" << assoc_victim << endl;
//		entry->print();	
//		for(int i  = 0 ; i < m_table[id_set].size(); i++)
//		{
//			cout << "\t Way " << i << endl;
//			m_table[id_set][i]->print();
//		}
	}*/
	
	entry->initEntry();
	entry->block_addr = addr;
	entry->isValid = true;
	entry->isInst = isInst;
	m_policy->insertionPolicy(entry);

	m_table[id_set].push_back(entry);

	return entry;
}

// Assembly:
subq $0x58, %rsp
movb %dl, %al
movq %rdi, 0x48(%rsp)
movq %rsi, 0x40(%rsp)
andb $0x1, %al
movb %al, 0x3f(%rsp)
movq 0x48(%rsp), %rdi
movq %rdi, 0x10(%rsp)
movq 0x40(%rsp), %rsi
callq 0x27b00
cmpq $0x0, %rax
je 0x27a29
movq 0x10(%rsp), %rdi
movq 0x40(%rsp), %rsi
callq 0x27b00
movq %rax, 0x50(%rsp)
jmp 0x27ae8
movq 0x10(%rsp), %rdi
movq 0x40(%rsp), %rsi
callq 0x27bd0
movq %rax, 0x30(%rsp)
movl $0x48, %edi
callq 0x53a0
movq %rax, %rdi
movq %rdi, %rax
movq %rax, 0x8(%rsp)
callq 0x28870
jmp 0x27a59
movq 0x8(%rsp), %rax
movq %rax, 0x28(%rsp)
movq 0x28(%rsp), %rdi
callq 0x288c0
movq 0x10(%rsp), %rax
movq 0x40(%rsp), %rdx
movq 0x28(%rsp), %rcx
movq %rdx, 0x30(%rcx)
movq 0x28(%rsp), %rcx
movb $0x1, 0x3c(%rcx)
movb 0x3f(%rsp), %dl
movq 0x28(%rsp), %rcx
andb $0x1, %dl
movb %dl, 0x3d(%rcx)
movq 0x18(%rax), %rdi
movq 0x28(%rsp), %rsi
callq 0x288f0
movq 0x10(%rsp), %rdi
movq 0x30(%rsp), %rsi
callq 0x284a0
movq %rax, %rdi
leaq 0x28(%rsp), %rsi
callq 0x28920
movq 0x28(%rsp), %rax
movq %rax, 0x50(%rsp)
jmp 0x27ae8
movq 0x8(%rsp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x20(%rsp)
movl %eax, 0x1c(%rsp)
callq 0x5340
jmp 0x27af2
movq 0x50(%rsp), %rax
addq $0x58, %rsp
retq
movq 0x20(%rsp), %rdi
callq 0x5690
nopl (%rax)
// File: gvaumour[P]cache-simulator/src/Directory.cc
// Function: Directory::getEntry(unsigned long)
DirectoryEntry*
Directory::getEntry(uint64_t addr)
{
	int id_set = indexFunction(addr);
	for(auto entry : m_table[id_set])
	{
		if(entry->block_addr == addr && entry->isValid)
			return entry;
	}
	return NULL;
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movq %rsi, 0x30(%rsp)
movq 0x38(%rsp), %rdi
movq %rdi, (%rsp)
movq 0x30(%rsp), %rsi
callq 0x27bd0
movq (%rsp), %rdi
movl %eax, 0x2c(%rsp)
movslq 0x2c(%rsp), %rsi
callq 0x284a0
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rdi
callq 0x28710
movq %rax, 0x18(%rsp)
movq 0x20(%rsp), %rdi
callq 0x28740
movq %rax, 0x10(%rsp)
leaq 0x18(%rsp), %rdi
leaq 0x10(%rsp), %rsi
callq 0x28770
testb $0x1, %al
jne 0x27b6b
jmp 0x27bb2
leaq 0x18(%rsp), %rdi
callq 0x287b0
movq (%rax), %rax
movq %rax, 0x8(%rsp)
movq 0x8(%rsp), %rax
movq 0x30(%rax), %rax
cmpq 0x30(%rsp), %rax
jne 0x27ba4
movq 0x8(%rsp), %rax
testb $0x1, 0x3c(%rax)
je 0x27ba4
movq 0x8(%rsp), %rax
movq %rax, 0x40(%rsp)
jmp 0x27bbb
jmp 0x27ba6
leaq 0x18(%rsp), %rdi
callq 0x287d0
jmp 0x27b56
movq $0x0, 0x40(%rsp)
movq 0x40(%rsp), %rax
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/Directory.cc
// Function: Directory::indexFunction(unsigned long)
uint64_t 
Directory::indexFunction(uint64_t block_addr)
{
	uint64_t a =block_addr;
	a = bitRemove(a , m_end_index,64);	
	a = a >> (m_start_index+1);
	assert(a < (unsigned int)m_nb_set);
	
	return (int)a;
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rcx
movq %rcx, 0x10(%rsp)
movq 0x10(%rsp), %rdi
movl 0x28(%rax), %esi
movl $0x40, %edx
callq 0x655b0
movq 0x8(%rsp), %rcx
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rax
movl 0x2c(%rcx), %ecx
addl $0x1, %ecx
movl %ecx, %ecx
shrq %cl, %rax
movq 0x8(%rsp), %rcx
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rax
movl 0x20(%rcx), %ecx
cmpq %rcx, %rax
jae 0x27c37
jmp 0x27c56
leaq 0x4a4e9(%rip), %rdi     # 0x72127
leaq 0x4a313(%rip), %rsi     # 0x71f58
movl $0xfb, %edx
leaq 0x4a4f1(%rip), %rcx     # 0x72142
callq 0x5260
movq 0x10(%rsp), %rax
cltq
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/Directory.cc
// Function: Directory::lookup(unsigned long)
bool
Directory::lookup(uint64_t addr)
{
	
	uint64_t id_set = indexFunction(addr);
	for(unsigned i = 0 ; i < m_table[id_set].size() ; i++)
	{
		if(m_table[id_set][i]->block_addr == addr)
			return true;
	}	
	return false;
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x28(%rsp)
movq %rsi, 0x20(%rsp)
movq 0x28(%rsp), %rdi
movq %rdi, 0x8(%rsp)
movq 0x20(%rsp), %rsi
callq 0x27bd0
movq %rax, 0x18(%rsp)
movl $0x0, 0x14(%rsp)
movq 0x8(%rsp), %rdi
movl 0x14(%rsp), %eax
movq %rax, (%rsp)
movq 0x18(%rsp), %rsi
callq 0x284a0
movq %rax, %rdi
callq 0x28990
movq %rax, %rcx
movq (%rsp), %rax
cmpq %rcx, %rax
jae 0x27d0b
movq 0x8(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq 0x284a0
movq %rax, %rdi
movl 0x14(%rsp), %eax
movl %eax, %esi
callq 0x289b0
movq (%rax), %rax
movq 0x30(%rax), %rax
cmpq 0x20(%rsp), %rax
jne 0x27cfc
movb $0x1, 0x37(%rsp)
jmp 0x27d10
jmp 0x27cfe
movl 0x14(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x14(%rsp)
jmp 0x27c9f
movb $0x0, 0x37(%rsp)
movb 0x37(%rsp), %al
andb $0x1, %al
addq $0x38, %rsp
retq
nopl (%rax,%rax)
// File: gvaumour[P]cache-simulator/src/Directory.cc
// Function: Directory::setTrackerToEntry(unsigned long, int)
void 
Directory::setTrackerToEntry(uint64_t addr , int node)
{
	DirectoryEntry* entry = getEntry(addr);
	assert(entry != NULL);

	entry->nodeTrackers.clear();
	entry->nodeTrackers.insert(node);

//	m_policy->updatePolicy(entry);
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq %rsi, 0x28(%rsp)
movl %edx, 0x24(%rsp)
movq 0x30(%rsp), %rdi
movq 0x28(%rsp), %rsi
callq 0x27b00
movq %rax, 0x18(%rsp)
cmpq $0x0, 0x18(%rsp)
je 0x27d50
jmp 0x27d6f
leaq 0x4be07(%rip), %rdi     # 0x73b5e
leaq 0x4a1fa(%rip), %rsi     # 0x71f58
movl $0x78, %edx
leaq 0x4a1ff(%rip), %rcx     # 0x71f69
callq 0x5260
movq 0x18(%rsp), %rdi
callq 0x289d0
movq 0x18(%rsp), %rdi
leaq 0x24(%rsp), %rsi
callq 0x289e0
movq %rax, 0x8(%rsp)
movb %dl, 0x10(%rsp)
addq $0x38, %rsp
retq
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/Directory.cc
// Function: Directory::removeTracker(unsigned long, int)
void 
Directory::removeTracker(uint64_t addr, int node)
{
	DirectoryEntry* entry = getEntry(addr);
	assert(entry != NULL);

	//DPRINTF("DIRECTORY::removeTracker Addr %#lx, Node %d\n", addr, node );	

	set<int>::iterator it = entry->nodeTrackers.find(node);
	if(it != entry->nodeTrackers.end())
		entry->nodeTrackers.erase(it);

	//if the cl is no longer in a L1 cache
	if(entry->nodeTrackers.empty())
		entry->coherence_state = CLEAN_LLC;
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x40(%rsp)
movq %rsi, 0x38(%rsp)
movl %edx, 0x34(%rsp)
movq 0x40(%rsp), %rdi
movq 0x38(%rsp), %rsi
callq 0x27b00
movq %rax, 0x28(%rsp)
cmpq $0x0, 0x28(%rsp)
je 0x27eb0
jmp 0x27ecf
leaq 0x4bca7(%rip), %rdi     # 0x73b5e
leaq 0x4a09a(%rip), %rsi     # 0x71f58
movl $0x96, %edx
leaq 0x4a12c(%rip), %rcx     # 0x71ff6
callq 0x5260
movq 0x28(%rsp), %rdi
leaq 0x34(%rsp), %rsi
callq 0x28a70
movq %rax, 0x20(%rsp)
movq 0x28(%rsp), %rdi
callq 0x28ad0
movq %rax, 0x18(%rsp)
leaq 0x20(%rsp), %rdi
leaq 0x18(%rsp), %rsi
callq 0x28ab0
testb $0x1, %al
jne 0x27f07
jmp 0x27f25
movq 0x28(%rsp), %rdi
movq 0x20(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rsi
callq 0x28b00
movq %rax, 0x8(%rsp)
movq 0x28(%rsp), %rdi
callq 0x28b50
testb $0x1, %al
jne 0x27f35
jmp 0x27f41
movq 0x28(%rsp), %rax
movl $0x6, 0x38(%rax)
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/Directory.cc
// Function: Directory::setCoherenceState(unsigned long, DirectoryState)
void
Directory::setCoherenceState(uint64_t addr, DirectoryState dir_state)
{

	DirectoryEntry* entry = getEntry(addr);
	assert(entry != NULL);
	entry->coherence_state = dir_state;
	entry->print();
//	m_policy->updatePolicy(entry);
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movl %edx, 0x14(%rsp)
movq 0x20(%rsp), %rdi
movq 0x18(%rsp), %rsi
callq 0x27b00
movq %rax, 0x8(%rsp)
cmpq $0x0, 0x8(%rsp)
je 0x27f80
jmp 0x27f9f
leaq 0x4bbd7(%rip), %rdi     # 0x73b5e
leaq 0x49fca(%rip), %rsi     # 0x71f58
movl $0xa8, %edx
leaq 0x4a089(%rip), %rcx     # 0x72023
callq 0x5260
movl 0x14(%rsp), %ecx
movq 0x8(%rsp), %rax
movl %ecx, 0x38(%rax)
movq 0x8(%rsp), %rdi
callq 0x27720
addq $0x28, %rsp
retq
nopw (%rax,%rax)
// File: gvaumour[P]cache-simulator/src/Directory.cc
// Function: Directory::removeEntry(unsigned long)
void
Directory::removeEntry(uint64_t addr)
{
	DirectoryEntry* entry = getEntry(addr);
	assert(entry != NULL);
	//DPRINTF("DIRECTORY::removeEntry Addr %#lx\n" , addr);
	int id_set = indexFunction(addr);
	for(unsigned i = 0 ; i < m_table[id_set].size(); i++)
	{
		if(addr == m_table[id_set][i]->block_addr && m_table[id_set][i]->isValid){
			m_table[id_set].erase(m_table[id_set].begin() + i);
			break;
		}
	}
}

// Assembly:
subq $0x68, %rsp
movq %rdi, 0x60(%rsp)
movq %rsi, 0x58(%rsp)
movq 0x60(%rsp), %rdi
movq %rdi, 0x20(%rsp)
movq 0x58(%rsp), %rsi
callq 0x27b00
movq %rax, 0x50(%rsp)
cmpq $0x0, 0x50(%rsp)
je 0x28051
jmp 0x28070
leaq 0x4bb06(%rip), %rdi     # 0x73b5e
leaq 0x49ef9(%rip), %rsi     # 0x71f58
movl $0xcc, %edx
leaq 0x4a023(%rip), %rcx     # 0x7208e
callq 0x5260
movq 0x20(%rsp), %rdi
movq 0x58(%rsp), %rsi
callq 0x27bd0
movl %eax, 0x4c(%rsp)
movl $0x0, 0x48(%rsp)
movq 0x20(%rsp), %rdi
movl 0x48(%rsp), %eax
movq %rax, 0x18(%rsp)
movslq 0x4c(%rsp), %rsi
callq 0x284a0
movq %rax, %rdi
callq 0x28990
movq %rax, %rcx
movq 0x18(%rsp), %rax
cmpq %rcx, %rax
jae 0x2819a
movq 0x20(%rsp), %rdi
movq 0x58(%rsp), %rax
movq %rax, 0x10(%rsp)
movslq 0x4c(%rsp), %rsi
callq 0x284a0
movq %rax, %rdi
movl 0x48(%rsp), %eax
movl %eax, %esi
callq 0x289b0
movq %rax, %rcx
movq 0x10(%rsp), %rax
movq (%rcx), %rcx
cmpq 0x30(%rcx), %rax
jne 0x28188
movq 0x20(%rsp), %rdi
movslq 0x4c(%rsp), %rsi
callq 0x284a0
movq %rax, %rdi
movl 0x48(%rsp), %eax
movl %eax, %esi
callq 0x289b0
movq (%rax), %rax
testb $0x1, 0x3c(%rax)
je 0x28188
movq 0x20(%rsp), %rdi
movslq 0x4c(%rsp), %rsi
callq 0x284a0
movq 0x20(%rsp), %rdi
movq %rax, 0x8(%rsp)
movslq 0x4c(%rsp), %rsi
callq 0x284a0
movq %rax, %rdi
callq 0x28710
movq %rax, 0x30(%rsp)
movl 0x48(%rsp), %eax
movl %eax, %esi
leaq 0x30(%rsp), %rdi
callq 0x28bf0
movq %rax, 0x38(%rsp)
leaq 0x40(%rsp), %rdi
leaq 0x38(%rsp), %rsi
callq 0x28c30
movq 0x8(%rsp), %rdi
movq 0x40(%rsp), %rsi
callq 0x28b80
movq %rax, 0x28(%rsp)
jmp 0x2819a
jmp 0x2818a
movl 0x48(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x48(%rsp)
jmp 0x2808b
addq $0x68, %rsp
retq
nop
// File: gvaumour[P]cache-simulator/src/Directory.hh
// Function: DirectoryEntry::initEntry()
void initEntry()
		{
			block_addr = 0;
			isInst = false;
			coherence_state = NOT_PRESENT;
			nodeTrackers.clear();
		}

// Assembly:
pushq %rax
movq %rdi, (%rsp)
movq (%rsp), %rdi
movq $0x0, 0x30(%rdi)
movb $0x0, 0x3d(%rdi)
movl $0x8, 0x38(%rdi)
callq 0x289d0
popq %rax
retq
nopw %cs:(%rax,%rax)
nopl (%rax)
// File: gvaumour[P]cache-simulator/src/FeatureTable.cc
// Function: FeatureTable::recordAccess(int, bool, RD_TYPE)
void 
FeatureTable::recordAccess(int index, bool isWrite, RD_TYPE rd)
{
	FeatureEntry* feature_entry = lookup(index);
	
	if(!feature_entry->isValid)
	{	
		//Init the feature entry
		feature_entry->cpts = vector< vector<int> >(NUM_RW_TYPE, vector<int>(NUM_RD_TYPE, 0));
		feature_entry->cptWindow = 0;
		feature_entry->isValid = true;
	}

	if( isWrite ) 
		feature_entry->cpts[WRITE_ACCESS][rd]++;
	else
		feature_entry->cpts[READ_ACCESS][rd]++;
	
	feature_entry->cptWindow++;

	if(feature_entry->cptWindow >= simu_parameters.perceptron_windowSize)
		feature_entry->updateDatasetState();
}

// Assembly:
subq $0x78, %rsp
movb %dl, %al
movq %rdi, 0x70(%rsp)
movl %esi, 0x6c(%rsp)
andb $0x1, %al
movb %al, 0x6b(%rsp)
movl %ecx, 0x64(%rsp)
movq 0x70(%rsp), %rdi
movl 0x6c(%rsp), %esi
callq 0x2cf40
movq %rax, 0x58(%rsp)
movq 0x58(%rsp), %rax
testb $0x1, 0x4c(%rax)
jne 0x2d0e4
movl $0x0, 0x24(%rsp)
leaq 0x23(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0xed30
movq 0x8(%rsp), %rcx
leaq 0x28(%rsp), %rdi
movl $0x3, %esi
leaq 0x24(%rsp), %rdx
callq 0xed40
jmp 0x2d02d
leaq 0x13(%rsp), %rdi
movq %rdi, (%rsp)
callq 0xedc0
movq (%rsp), %rcx
leaq 0x40(%rsp), %rdi
movl $0x5, %esi
leaq 0x28(%rsp), %rdx
callq 0xedd0
jmp 0x2d055
movq 0x58(%rsp), %rdi
leaq 0x40(%rsp), %rsi
callq 0xee50
leaq 0x40(%rsp), %rdi
callq 0xee90
leaq 0x13(%rsp), %rdi
callq 0xeef0
leaq 0x28(%rsp), %rdi
callq 0xef00
leaq 0x23(%rsp), %rdi
callq 0xef60
movq 0x58(%rsp), %rax
movl $0x0, 0x48(%rax)
movq 0x58(%rsp), %rax
movb $0x1, 0x4c(%rax)
jmp 0x2d0e4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
jmp 0x2d0d5
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x18(%rsp)
movl %eax, 0x14(%rsp)
leaq 0x13(%rsp), %rdi
callq 0xeef0
leaq 0x28(%rsp), %rdi
callq 0xef00
leaq 0x23(%rsp), %rdi
callq 0xef60
jmp 0x2d168
testb $0x1, 0x6b(%rsp)
je 0x2d111
movq 0x58(%rsp), %rdi
movl $0x1, %esi
callq 0xef70
movq %rax, %rdi
movl 0x64(%rsp), %eax
movl %eax, %esi
callq 0xef90
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
jmp 0x2d134
movq 0x58(%rsp), %rdi
xorl %eax, %eax
movl %eax, %esi
callq 0xef70
movq %rax, %rdi
movl 0x64(%rsp), %eax
movl %eax, %esi
callq 0xef90
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
movq 0x58(%rsp), %rax
movl 0x48(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x48(%rax)
movq 0x58(%rsp), %rax
movl 0x48(%rax), %eax
leaq 0x66e9f(%rip), %rcx     # 0x93ff0
cmpl 0x1b4(%rcx), %eax
jl 0x2d163
movq 0x58(%rsp), %rdi
callq 0x2bf60
addq $0x78, %rsp
retq
movq 0x18(%rsp), %rdi
callq 0x5690
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/FeatureTable.cc
// Function: FeatureTable::recordAccess(int, bool, bool, bool)
void
FeatureTable::recordAccess(int index, bool isWrite, bool isHitSRAM, bool isHitNVM)
{
	FeatureEntry* feature_entry = lookup(index);
	
	if(!feature_entry->isValid)
	{	
		//Init the feature entry
		feature_entry->cpts = vector< vector<int> >(NUM_RW_TYPE, vector<int>(NUM_RD_TYPE, 0));
		feature_entry->cptWindow = 0;
		feature_entry->isValid = true;
	}

	feature_entry->SRAM_seq[isWrite][isHitSRAM]++;
	feature_entry->NVM_seq[isWrite][isHitNVM]++;
	
	feature_entry->cptWindow++;

	if(feature_entry->cptWindow >= simu_parameters.perceptron_windowSize)
		feature_entry->updateDatasetState();
}

// Assembly:
subq $0x78, %rsp
movb %r8b, %al
movq %rdi, 0x70(%rsp)
movl %esi, 0x6c(%rsp)
andb $0x1, %dl
movb %dl, 0x6b(%rsp)
andb $0x1, %cl
movb %cl, 0x6a(%rsp)
andb $0x1, %al
movb %al, 0x69(%rsp)
movq 0x70(%rsp), %rdi
movl 0x6c(%rsp), %esi
callq 0x2cf40
movq %rax, 0x60(%rsp)
movq 0x60(%rsp), %rax
testb $0x1, 0x4c(%rax)
jne 0x2d2b1
movl $0x0, 0x2c(%rsp)
leaq 0x2b(%rsp), %rdi
movq %rdi, 0x10(%rsp)
callq 0xed30
movq 0x10(%rsp), %rcx
leaq 0x30(%rsp), %rdi
movl $0x3, %esi
leaq 0x2c(%rsp), %rdx
callq 0xed40
jmp 0x2d1f8
leaq 0x1b(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0xedc0
movq 0x8(%rsp), %rcx
leaq 0x48(%rsp), %rdi
movl $0x5, %esi
leaq 0x30(%rsp), %rdx
callq 0xedd0
jmp 0x2d222
movq 0x60(%rsp), %rdi
leaq 0x48(%rsp), %rsi
callq 0xee50
leaq 0x48(%rsp), %rdi
callq 0xee90
leaq 0x1b(%rsp), %rdi
callq 0xeef0
leaq 0x30(%rsp), %rdi
callq 0xef00
leaq 0x2b(%rsp), %rdi
callq 0xef60
movq 0x60(%rsp), %rax
movl $0x0, 0x48(%rax)
movq 0x60(%rsp), %rax
movb $0x1, 0x4c(%rax)
jmp 0x2d2b1
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x20(%rsp)
movl %eax, 0x1c(%rsp)
jmp 0x2d2a2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x20(%rsp)
movl %eax, 0x1c(%rsp)
leaq 0x1b(%rsp), %rdi
callq 0xeef0
leaq 0x30(%rsp), %rdi
callq 0xef00
leaq 0x2b(%rsp), %rdi
callq 0xef60
jmp 0x2d34b
movq 0x60(%rsp), %rdi
addq $0x18, %rdi
movb 0x6b(%rsp), %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, %esi
callq 0xef70
movq %rax, %rdi
movb 0x6a(%rsp), %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, %esi
callq 0xef90
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
movq 0x60(%rsp), %rdi
addq $0x30, %rdi
movb 0x6b(%rsp), %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, %esi
callq 0xef70
movq %rax, %rdi
movb 0x69(%rsp), %al
andb $0x1, %al
movzbl %al, %eax
movl %eax, %esi
callq 0xef90
movl (%rax), %ecx
addl $0x1, %ecx
movl %ecx, (%rax)
movq 0x60(%rsp), %rax
movl 0x48(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x48(%rax)
movq 0x60(%rsp), %rax
movl 0x48(%rax), %eax
leaq 0x66cbc(%rip), %rcx     # 0x93ff0
cmpl 0x1b4(%rcx), %eax
jl 0x2d346
movq 0x60(%rsp), %rdi
callq 0x2bf60
addq $0x78, %rsp
retq
movq 0x20(%rsp), %rdi
callq 0x5690
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/FeatureTable.cc
// Function: FeatureTable::getAllocDecision(int, bool)
allocDecision
FeatureTable::getAllocDecision(int index, bool isWrite)
{
	FeatureEntry* entry = lookup(index);
	allocDecision result = entry->des;
	
	if(result == ALLOCATE_PREEMPTIVELY)
	{
		if(isWrite)
			result = ALLOCATE_IN_SRAM;
		else 
			result = ALLOCATE_IN_NVM;
	}

	if(simu_parameters.perceptron_drawFeatureMaps)
	{
		int sign = result == ALLOCATE_IN_NVM ? -1 : +1;
		stats_allocation_buffer[index].push_back( sign * 32);
	}


	return result;
}

// Assembly:
subq $0x38, %rsp
movb %dl, %al
movq %rdi, 0x30(%rsp)
movl %esi, 0x2c(%rsp)
andb $0x1, %al
movb %al, 0x2b(%rsp)
movq 0x30(%rsp), %rdi
movq %rdi, 0x8(%rsp)
movl 0x2c(%rsp), %esi
callq 0x2cf40
movq %rax, 0x20(%rsp)
movq 0x20(%rsp), %rax
movl 0x58(%rax), %eax
movl %eax, 0x1c(%rsp)
cmpl $0x3, 0x1c(%rsp)
jne 0x2d3bb
testb $0x1, 0x2b(%rsp)
je 0x2d3b1
movl $0x0, 0x1c(%rsp)
jmp 0x2d3b9
movl $0x1, 0x1c(%rsp)
jmp 0x2d3bb
leaq 0x66c2e(%rip), %rax     # 0x93ff0
testb $0x1, 0x1cc(%rax)
je 0x2d40e
movq 0x8(%rsp), %rdi
movl 0x1c(%rsp), %edx
movl $0x1, %eax
movl $0xffffffff, %ecx       # imm = 0xFFFFFFFF
cmpl $0x1, %edx
cmovel %ecx, %eax
movl %eax, 0x18(%rsp)
addq $0x78, %rdi
movslq 0x2c(%rsp), %rsi
callq 0xef70
movq %rax, %rdi
movl 0x18(%rsp), %eax
shll $0x5, %eax
movl %eax, 0x14(%rsp)
leaq 0x14(%rsp), %rsi
callq 0x20450
movl 0x1c(%rsp), %eax
addq $0x38, %rsp
retq
nopw (%rax,%rax)
// File: gvaumour[P]cache-simulator/src/FeatureTable.cc
// Function: FeatureTable::decreaseAlloc(int)
void 
FeatureTable::decreaseAlloc(int index)
{
	FeatureEntry* entry = lookup(index);
	entry->allocation_counter--;
	
	if(entry->allocation_counter < -m_counter_size)
		entry->allocation_counter = -m_counter_size;
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movl %esi, 0x1c(%rsp)
movq 0x20(%rsp), %rdi
movq %rdi, 0x8(%rsp)
movl 0x1c(%rsp), %esi
callq 0x2cf40
movq 0x8(%rsp), %rdx
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rax
movl 0x54(%rax), %ecx
addl $-0x1, %ecx
movl %ecx, 0x54(%rax)
movq 0x10(%rsp), %rax
movl 0x54(%rax), %eax
xorl %ecx, %ecx
subl 0x2c(%rdx), %ecx
cmpl %ecx, %eax
jge 0x2d47b
movq 0x8(%rsp), %rax
xorl %ecx, %ecx
subl 0x2c(%rax), %ecx
movq 0x10(%rsp), %rax
movl %ecx, 0x54(%rax)
addq $0x28, %rsp
retq
// File: gvaumour[P]cache-simulator/src/FeatureTable.cc
// Function: FeatureTable::increaseAlloc(int)
void 
FeatureTable::increaseAlloc(int index)
{
	FeatureEntry* entry = lookup(index);
	entry->allocation_counter++;
	
	if(entry->allocation_counter > m_counter_size)
		entry->allocation_counter = m_counter_size;	
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movl %esi, 0x1c(%rsp)
movq 0x20(%rsp), %rdi
movq %rdi, 0x8(%rsp)
movl 0x1c(%rsp), %esi
callq 0x2cf40
movq 0x8(%rsp), %rcx
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rax
movl 0x54(%rax), %edx
addl $0x1, %edx
movl %edx, 0x54(%rax)
movq 0x10(%rsp), %rax
movl 0x54(%rax), %eax
cmpl 0x2c(%rcx), %eax
jle 0x2d4d5
movq 0x8(%rsp), %rax
movl 0x2c(%rax), %ecx
movq 0x10(%rsp), %rax
movl %ecx, 0x54(%rax)
addq $0x28, %rsp
retq
nopw (%rax,%rax)
// File: gvaumour[P]cache-simulator/src/FeatureTable.cc
// Function: FeatureTable::getConfidence(int, bool)
int
FeatureTable::getConfidence(int index, bool isLegal)
{
	int result = lookup(index)->weight;
	
	if(simu_parameters.perceptron_drawFeatureMaps && isLegal)
		stats_weight_buffer[index].push_back(result);
			
	return result;
}

// Assembly:
subq $0x28, %rsp
movb %dl, %al
movq %rdi, 0x20(%rsp)
movl %esi, 0x1c(%rsp)
andb $0x1, %al
movb %al, 0x1b(%rsp)
movq 0x20(%rsp), %rdi
movq %rdi, 0x8(%rsp)
movl 0x1c(%rsp), %esi
callq 0x2cf40
movl 0x50(%rax), %eax
movl %eax, 0x14(%rsp)
leaq 0x66a9a(%rip), %rax     # 0x93ff0
testb $0x1, 0x1cc(%rax)
je 0x2d589
testb $0x1, 0x1b(%rsp)
je 0x2d589
movq 0x8(%rsp), %rdi
addq $0x90, %rdi
movslq 0x1c(%rsp), %rsi
callq 0xef70
movq %rax, %rdi
leaq 0x14(%rsp), %rsi
callq 0xfb70
movl 0x14(%rsp), %eax
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/FeatureTable.cc
// Function: FeatureTable::decreaseConfidence(int)
void
FeatureTable::decreaseConfidence(int index)
{
	FeatureEntry* feature_entry = lookup(index);
	feature_entry->weight -= simu_parameters.Cerebron_decrement_value;
	if(feature_entry->weight < 1)
		feature_entry->weight = 1;	
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
movq 0x10(%rsp), %rdi
movl 0xc(%rsp), %esi
callq 0x2cf40
movq %rax, (%rsp)
leaq 0x66a2a(%rip), %rax     # 0x93ff0
movl 0x228(%rax), %edx
movq (%rsp), %rax
movl 0x50(%rax), %ecx
subl %edx, %ecx
movl %ecx, 0x50(%rax)
movq (%rsp), %rax
cmpl $0x1, 0x50(%rax)
jge 0x2d5ed
movq (%rsp), %rax
movl $0x1, 0x50(%rax)
addq $0x18, %rsp
retq
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/FeatureTable.cc
// Function: FeatureTable::increaseConfidence(int)
void
FeatureTable::increaseConfidence(int index)
{
	FeatureEntry* feature_entry = lookup(index);
	feature_entry->weight++;
	if(feature_entry->weight > simu_parameters.perceptron_counter_size)
		feature_entry->weight = simu_parameters.perceptron_counter_size;	
}

// Assembly:
subq $0x18, %rsp
movq %rdi, 0x10(%rsp)
movl %esi, 0xc(%rsp)
movq 0x10(%rsp), %rdi
movl 0xc(%rsp), %esi
callq 0x2cf40
movq %rax, (%rsp)
movq (%rsp), %rax
movl 0x50(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x50(%rax)
movq (%rsp), %rax
movl 0x50(%rax), %eax
leaq 0x669b6(%rip), %rcx     # 0x93ff0
cmpl 0x1b0(%rcx), %eax
jle 0x2d656
leaq 0x669a7(%rip), %rax     # 0x93ff0
movl 0x1b0(%rax), %ecx
movq (%rsp), %rax
movl %ecx, 0x50(%rax)
addq $0x18, %rsp
retq
nopl (%rax,%rax)
// File: gvaumour[P]cache-simulator/src/FeaturesFunction.cc
// Function: hashingMissPC(unsigned long, unsigned long, int, bool)
int
hashingMissPC(uint64_t addr , uint64_t missPC, int block, bool hash_with_PC)
{
	assert( block < 8);
	
	uint64_t tag = bitSelect( missPC , 8*block , 8*block+7);
	if( hash_with_PC)
		tag = (tag ^ Predictor::m_global_PChistory[0])%256;

	return tag;
}

// Assembly:
subq $0x28, %rsp
movb %cl, %al
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movl %edx, 0x14(%rsp)
andb $0x1, %al
movb %al, 0x13(%rsp)
cmpl $0x8, 0x14(%rsp)
jge 0x304e3
jmp 0x30502
leaq 0x41d4b(%rip), %rdi     # 0x72235
leaq 0x41d4e(%rip), %rsi     # 0x7223f
movl $0x5b, %edx
leaq 0x41deb(%rip), %rcx     # 0x722e8
callq 0x5260
movq 0x18(%rsp), %rdi
movl 0x14(%rsp), %esi
shll $0x3, %esi
movl 0x14(%rsp), %edx
shll $0x3, %edx
addl $0x7, %edx
callq 0x65540
movq %rax, 0x8(%rsp)
testb $0x1, 0x13(%rsp)
je 0x30557
movq 0x8(%rsp), %rax
movq %rax, (%rsp)
leaq 0x637c7(%rip), %rdi     # 0x93d00
xorl %eax, %eax
movl %eax, %esi
callq 0x30840
movq %rax, %rcx
movq (%rsp), %rax
xorq (%rcx), %rax
andq $0xff, %rax
movq %rax, 0x8(%rsp)
movq 0x8(%rsp), %rax
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/FeaturesFunction.cc
// Function: hashingAddr(unsigned long, unsigned long, int, bool)
int
hashingAddr(uint64_t addr , uint64_t missPC, int block, bool hash_with_PC)
{
	assert( block < 8);
	
	uint64_t tag = bitSelect( addr , 8*block , 8*block+7);
	if( hash_with_PC)
		tag = (tag ^ Predictor::m_global_PChistory[0])%256;

	return tag;
}

// Assembly:
subq $0x28, %rsp
movb %cl, %al
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movl %edx, 0x14(%rsp)
andb $0x1, %al
movb %al, 0x13(%rsp)
cmpl $0x8, 0x14(%rsp)
jge 0x30593
jmp 0x305b2
leaq 0x41c9b(%rip), %rdi     # 0x72235
leaq 0x41c9e(%rip), %rsi     # 0x7223f
movl $0x67, %edx
leaq 0x41d6c(%rip), %rcx     # 0x72319
callq 0x5260
movq 0x20(%rsp), %rdi
movl 0x14(%rsp), %esi
shll $0x3, %esi
movl 0x14(%rsp), %edx
shll $0x3, %edx
addl $0x7, %edx
callq 0x65540
movq %rax, 0x8(%rsp)
testb $0x1, 0x13(%rsp)
je 0x30607
movq 0x8(%rsp), %rax
movq %rax, (%rsp)
leaq 0x63717(%rip), %rdi     # 0x93d00
xorl %eax, %eax
movl %eax, %esi
callq 0x30840
movq %rax, %rcx
movq (%rsp), %rax
xorq (%rcx), %rax
andq $0xff, %rax
movq %rax, 0x8(%rsp)
movq 0x8(%rsp), %rax
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/Hierarchy.cc
// Function: Hierarchy::printConfig(std::ostream&)
void
Hierarchy::printConfig(ostream& out)
{
	out << "ConfigCache : " << m_configFile << endl;
	out << "NbLevel : " << m_nbLevel << endl;
	out << "NbCore : " << m_nbCores << endl;
	
	for(unsigned j = 0 ; j < m_private_caches.size() ; j++)
	{
		out << "Core n°" << j << endl;		
		m_private_caches[j]->printConfig(out);
	}
	out << "***************" << endl;
	out << "Last Level Cache : " << endl;
	m_LLC->printConfig(out);
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rdi
leaq 0x40b32(%rip), %rsi     # 0x72456
callq 0x5380
movq 0x8(%rsp), %rsi
movq %rax, %rdi
addq $0x38, %rsi
callq 0x5330
movq %rax, %rdi
movq 0x61674(%rip), %rsi     # 0x92fb8
callq 0x53d0
movq 0x18(%rsp), %rdi
leaq 0x40b10(%rip), %rsi     # 0x72465
callq 0x5380
movq %rax, %rdi
movq 0x8(%rsp), %rax
movl 0x30(%rax), %esi
callq 0x5510
movq %rax, %rdi
movq 0x61644(%rip), %rsi     # 0x92fb8
callq 0x53d0
movq 0x18(%rsp), %rdi
leaq 0x40aeb(%rip), %rsi     # 0x72470
callq 0x5380
movq %rax, %rdi
movq 0x8(%rsp), %rax
movl 0x34(%rax), %esi
callq 0x5510
movq %rax, %rdi
movq 0x61614(%rip), %rsi     # 0x92fb8
callq 0x53d0
movl $0x0, 0x14(%rsp)
movq 0x8(%rsp), %rdi
movl 0x14(%rsp), %eax
movq %rax, (%rsp)
callq 0x33ea0
movq %rax, %rcx
movq (%rsp), %rax
cmpq %rcx, %rax
jae 0x31a25
movq 0x18(%rsp), %rdi
leaq 0x40a9f(%rip), %rsi     # 0x7247a
callq 0x5380
movq %rax, %rdi
movl 0x14(%rsp), %esi
callq 0x5510
movq %rax, %rdi
movq 0x615c2(%rip), %rsi     # 0x92fb8
callq 0x53d0
movq 0x8(%rsp), %rdi
movl 0x14(%rsp), %eax
movl %eax, %esi
callq 0x33ec0
movq (%rax), %rdi
movq 0x18(%rsp), %rsi
callq 0x470f0
movl 0x14(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x14(%rsp)
jmp 0x319b1
movq 0x18(%rsp), %rdi
leaq 0x414fd(%rip), %rsi     # 0x72f2e
callq 0x5380
movq %rax, %rdi
movq 0x61578(%rip), %rsi     # 0x92fb8
callq 0x53d0
movq 0x18(%rsp), %rdi
leaq 0x40a32(%rip), %rsi     # 0x72483
callq 0x5380
movq %rax, %rdi
movq 0x61558(%rip), %rsi     # 0x92fb8
callq 0x53d0
movq 0x8(%rsp), %rax
movq 0x18(%rax), %rdi
movq 0x18(%rsp), %rsi
callq 0x470f0
addq $0x28, %rsp
retq
nopl (%rax)
// File: gvaumour[P]cache-simulator/src/Hierarchy.cc
// Function: Hierarchy::finishSimu()
void 
Hierarchy::finishSimu()
{
	cout << "\tSimulation done, finishing up ..." << endl;
	for(unsigned j = 0 ; j < m_private_caches.size() ; j++)
	{
		m_private_caches[j]->finishSimu();
	}
	m_LLC->finishSimu();
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x10(%rsp)
movq 0x60c36(%rip), %rdi     # 0x92fd0
leaq 0x401eb(%rip), %rsi     # 0x7258c
callq 0x5380
movq %rax, %rdi
movq 0x60c08(%rip), %rsi     # 0x92fb8
callq 0x53d0
movl $0x0, 0x1c(%rsp)
movq 0x10(%rsp), %rdi
movl 0x1c(%rsp), %eax
movq %rax, 0x8(%rsp)
callq 0x33ea0
movq %rax, %rcx
movq 0x8(%rsp), %rax
cmpq %rcx, %rax
jae 0x32402
movq 0x10(%rsp), %rdi
movl 0x1c(%rsp), %eax
movl %eax, %esi
callq 0x33ec0
movq (%rax), %rdi
callq 0x46e00
movl 0x1c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x1c(%rsp)
jmp 0x323bd
movq 0x10(%rsp), %rax
movq 0x18(%rax), %rdi
callq 0x46e00
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/HybridCache.cc
// Function: HybridCache::~HybridCache()
HybridCache::~HybridCache(){
	for (int i = 0; i < m_nb_set; i++) {
		for (int j = 0; j < m_nbSRAMways; j++) {
		    delete m_tableSRAM[i][j];
		}
		for (int j = 0; j < m_nbNVMways; j++) {
		    delete m_tableNVM[i][j];
		}
	}
//	delete m_predictor;
}

// Assembly:
subq $0x38, %rsp
movq %rdi, 0x30(%rsp)
movq 0x30(%rsp), %rax
movq %rax, 0x18(%rsp)
movl $0x0, 0x2c(%rsp)
movq 0x18(%rsp), %rcx
movl 0x2c(%rsp), %eax
cmpl 0xac(%rcx), %eax
jge 0x37dd6
movl $0x0, 0x28(%rsp)
movq 0x18(%rsp), %rcx
movl 0x28(%rsp), %eax
cmpl 0xa8(%rcx), %eax
jge 0x37d5a
movq 0x18(%rsp), %rdi
addq $0x20, %rdi
movslq 0x2c(%rsp), %rsi
callq 0xf9a0
movq %rax, %rdi
movslq 0x28(%rsp), %rsi
callq 0xf9c0
movq (%rax), %rax
movq %rax, 0x10(%rsp)
cmpq $0x0, %rax
je 0x37d4b
movq 0x10(%rsp), %rdi
callq 0x3d800
movq 0x10(%rsp), %rdi
callq 0x5340
jmp 0x37d4d
movl 0x28(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x28(%rsp)
jmp 0x37cf8
movl $0x0, 0x24(%rsp)
movq 0x18(%rsp), %rcx
movl 0x24(%rsp), %eax
cmpl 0xa4(%rcx), %eax
jge 0x37dc4
movq 0x18(%rsp), %rdi
addq $0x8, %rdi
movslq 0x2c(%rsp), %rsi
callq 0xf9a0
movq %rax, %rdi
movslq 0x24(%rsp), %rsi
callq 0xf9c0
movq (%rax), %rax
movq %rax, 0x8(%rsp)
cmpq $0x0, %rax
je 0x37db5
movq 0x8(%rsp), %rdi
callq 0x3d800
movq 0x8(%rsp), %rdi
callq 0x5340
jmp 0x37db7
movl 0x24(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x24(%rsp)
jmp 0x37d62
jmp 0x37dc6
movl 0x2c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x2c(%rsp)
jmp 0x37cdb
movq 0x18(%rsp), %rdi
addq $0x1f0, %rdi            # imm = 0x1F0
callq 0x3d340
movq 0x18(%rsp), %rdi
addq $0x188, %rdi            # imm = 0x188
callq 0xf0e0
movq 0x18(%rsp), %rdi
addq $0x170, %rdi            # imm = 0x170
callq 0xf0e0
movq 0x18(%rsp), %rdi
addq $0x128, %rdi            # imm = 0x128
callq 0xf0e0
movq 0x18(%rsp), %rdi
addq $0x110, %rdi            # imm = 0x110
callq 0xf0e0
movq 0x18(%rsp), %rdi
addq $0xd8, %rdi
callq 0xf0e0
movq 0x18(%rsp), %rdi
addq $0xc0, %rdi
callq 0xf0e0
movq 0x18(%rsp), %rdi
addq $0x70, %rdi
callq 0x5768
movq 0x18(%rsp), %rdi
addq $0x38, %rdi
callq 0x3d350
movq 0x18(%rsp), %rdi
addq $0x20, %rdi
callq 0x3d360
movq 0x18(%rsp), %rdi
addq $0x8, %rdi
callq 0x3d360
addq $0x38, %rsp
retq
nopw (%rax,%rax)
// File: gvaumour[P]cache-simulator/src/HybridCache.cc
// Function: HybridCache::finishSimu()
void 
HybridCache::finishSimu()
{
	for (int i = 0; i < m_nb_set; i++) {
		for (int j = 0; j < m_nbSRAMways; j++) {
		    updateStatsDeallocate(m_tableSRAM[i][j]);
		}
		for (int j = 0; j < m_nbNVMways; j++) {
		    updateStatsDeallocate(m_tableNVM[i][j]);
		}
	}
	m_predictor->finishSimu();
	
	if(simu_parameters.traceLLC && m_ID == -1)
	{
		gzclose(LLC_trace);
	}

}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
movl $0x0, 0x1c(%rsp)
movq 0x8(%rsp), %rcx
movl 0x1c(%rsp), %eax
cmpl 0xac(%rcx), %eax
jge 0x37f78
movl $0x0, 0x18(%rsp)
movq 0x8(%rsp), %rcx
movl 0x18(%rsp), %eax
cmpl 0xa8(%rcx), %eax
jge 0x37f13
movq 0x8(%rsp), %rdi
addq $0x20, %rdi
movslq 0x1c(%rsp), %rsi
callq 0xf9a0
movq %rax, %rdi
movslq 0x18(%rsp), %rsi
callq 0xf9c0
movq 0x8(%rsp), %rdi
movq (%rax), %rsi
callq 0x37fc0
movl 0x18(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x18(%rsp)
jmp 0x37ec8
movl $0x0, 0x14(%rsp)
movq 0x8(%rsp), %rcx
movl 0x14(%rsp), %eax
cmpl 0xa4(%rcx), %eax
jge 0x37f66
movq 0x8(%rsp), %rdi
addq $0x8, %rdi
movslq 0x1c(%rsp), %rsi
callq 0xf9a0
movq %rax, %rdi
movslq 0x14(%rsp), %rsi
callq 0xf9c0
movq 0x8(%rsp), %rdi
movq (%rax), %rsi
callq 0x37fc0
movl 0x14(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x14(%rsp)
jmp 0x37f1b
jmp 0x37f68
movl 0x1c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x1c(%rsp)
jmp 0x37eab
movq 0x8(%rsp), %rax
movq 0x68(%rax), %rdi
movq (%rdi), %rax
callq *0x38(%rax)
leaq 0x5c062(%rip), %rax     # 0x93ff0
testb $0x1, 0x89(%rax)
je 0x37fad
movq 0x8(%rsp), %rax
cmpl $-0x1, (%rax)
jne 0x37fad
movq 0x5bb80(%rip), %rdi     # 0x93b28
callq 0x5650
addq $0x28, %rsp
retq
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/HybridCache.cc
// Function: HybridCache::entete_debug()
void
HybridCache::entete_debug()
{
	DPRINTF(DebugCache , "CACHE[%d]-", m_ID);
	if(m_isInstructionCache){
		DPRINTF(DebugCache , "I:");	
	}
	else{	
		DPRINTF(DebugCache , "D:");
	}
}

// Assembly:
subq $0xc8, %rsp
movq %rdi, 0xc0(%rsp)
movq 0xc0(%rsp), %rax
movq %rax, 0x28(%rsp)
leaq 0x9f(%rsp), %rdi
movq %rdi, 0x30(%rsp)
callq 0x56a0
movq 0x30(%rsp), %rdx
leaq 0x3a2d4(%rip), %rsi     # 0x7286e
leaq 0xa0(%rsp), %rdi
callq 0x5530
jmp 0x385a9
leaq 0x5ba40(%rip), %rdi     # 0x93ff0
addq $0x8, %rdi
leaq 0xa0(%rsp), %rsi
callq 0x33a00
movq %rax, 0x20(%rsp)
jmp 0x385c8
leaq 0xa0(%rsp), %rdi
callq 0x5768
leaq 0x9f(%rsp), %rdi
callq 0x53e0
movq 0x20(%rsp), %rax
cmpq $0x0, %rax
je 0x3864d
movq 0x28(%rsp), %rax
movl (%rax), %esi
leaq 0x3a7ad(%rip), %rdi     # 0x72da8
movb $0x0, %al
callq 0x5060
jmp 0x3864d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x90(%rsp)
movl %eax, 0x8c(%rsp)
jmp 0x3863b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x90(%rsp)
movl %eax, 0x8c(%rsp)
leaq 0xa0(%rsp), %rdi
callq 0x5768
leaq 0x9f(%rsp), %rdi
callq 0x53e0
jmp 0x387d0
movq 0x28(%rsp), %rax
testb $0x1, 0x4(%rax)
je 0x38716
leaq 0x67(%rsp), %rdi
movq %rdi, 0x18(%rsp)
callq 0x56a0
movq 0x18(%rsp), %rdx
leaq 0x3a1f7(%rip), %rsi     # 0x7286e
leaq 0x68(%rsp), %rdi
callq 0x5530
jmp 0x38683
leaq 0x5b966(%rip), %rdi     # 0x93ff0
addq $0x8, %rdi
leaq 0x68(%rsp), %rsi
callq 0x33a00
movq %rax, 0x10(%rsp)
jmp 0x3869f
leaq 0x68(%rsp), %rdi
callq 0x5768
leaq 0x67(%rsp), %rdi
callq 0x53e0
movq 0x10(%rsp), %rax
cmpq $0x0, %rax
je 0x38711
leaq 0x3a6ee(%rip), %rdi     # 0x72db3
movb $0x0, %al
callq 0x5060
jmp 0x38711
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x90(%rsp)
movl %eax, 0x8c(%rsp)
jmp 0x38702
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x90(%rsp)
movl %eax, 0x8c(%rsp)
leaq 0x68(%rsp), %rdi
callq 0x5768
leaq 0x67(%rsp), %rdi
callq 0x53e0
jmp 0x387d0
jmp 0x387c8
leaq 0x3f(%rsp), %rdi
movq %rdi, 0x8(%rsp)
callq 0x56a0
movq 0x8(%rsp), %rdx
leaq 0x3a13d(%rip), %rsi     # 0x7286e
leaq 0x40(%rsp), %rdi
callq 0x5530
jmp 0x3873d
leaq 0x5b8ac(%rip), %rdi     # 0x93ff0
addq $0x8, %rdi
leaq 0x40(%rsp), %rsi
callq 0x33a00
movq %rax, (%rsp)
jmp 0x38758
leaq 0x40(%rsp), %rdi
callq 0x5768
leaq 0x3f(%rsp), %rdi
callq 0x53e0
movq (%rsp), %rax
cmpq $0x0, %rax
je 0x387c6
leaq 0x3a639(%rip), %rdi     # 0x72db6
movb $0x0, %al
callq 0x5060
jmp 0x387c6
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x90(%rsp)
movl %eax, 0x8c(%rsp)
jmp 0x387ba
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x90(%rsp)
movl %eax, 0x8c(%rsp)
leaq 0x40(%rsp), %rdi
callq 0x5768
leaq 0x3f(%rsp), %rdi
callq 0x53e0
jmp 0x387d0
jmp 0x387c8
addq $0xc8, %rsp
retq
movq 0x90(%rsp), %rdi
callq 0x5690
nopl (%rax)
// File: gvaumour[P]cache-simulator/src/HybridCache.cc
// Function: HybridCache::getEntry(unsigned long)
CacheEntry*
HybridCache::getEntry(uint64_t block_addr)
{
//	uint64_t block_addr =  bitRemove(addr , 0 , m_start_index+1);

	map<uint64_t,HybridLocation>::iterator p = m_tag_index.find(block_addr);
	
	if (p != m_tag_index.end()){
	
		int id_set = addressToCacheSet(block_addr);
		HybridLocation loc = p->second;
		if(loc.m_inNVM)
			return m_tableNVM[id_set][loc.m_way];
		else 
			return m_tableSRAM[id_set][loc.m_way];	
	

	}
	else{
		return NULL;
	}
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x38(%rsp)
movq %rsi, 0x30(%rsp)
movq 0x38(%rsp), %rdi
movq %rdi, 0x8(%rsp)
addq $0x38, %rdi
leaq 0x30(%rsp), %rsi
callq 0x3d9b0
movq 0x8(%rsp), %rdi
movq %rax, 0x28(%rsp)
addq $0x38, %rdi
callq 0x3db60
movq %rax, 0x20(%rsp)
leaq 0x28(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x3db40
testb $0x1, %al
jne 0x38836
jmp 0x388b7
movq 0x8(%rsp), %rdi
movq 0x30(%rsp), %rsi
callq 0x3a0c0
movl %eax, 0x1c(%rsp)
leaq 0x28(%rsp), %rdi
callq 0x3d9e0
movq 0x8(%rax), %rax
movq %rax, 0x14(%rsp)
testb $0x1, 0x18(%rsp)
je 0x3888d
movq 0x8(%rsp), %rdi
addq $0x8, %rdi
movslq 0x1c(%rsp), %rsi
callq 0xf9a0
movq %rax, %rdi
movslq 0x14(%rsp), %rsi
callq 0xf9c0
movq (%rax), %rax
movq %rax, 0x40(%rsp)
jmp 0x388c0
movq 0x8(%rsp), %rdi
addq $0x20, %rdi
movslq 0x1c(%rsp), %rsi
callq 0xf9a0
movq %rax, %rdi
movslq 0x14(%rsp), %rsi
callq 0xf9c0
movq (%rax), %rax
movq %rax, 0x40(%rsp)
jmp 0x388c0
movq $0x0, 0x40(%rsp)
movq 0x40(%rsp), %rax
addq $0x48, %rsp
retq
nopw (%rax,%rax)
// File: gvaumour[P]cache-simulator/src/HybridCache.cc
// Function: HybridCache::addressToCacheSet(unsigned long)
int 
HybridCache::addressToCacheSet(uint64_t address) 
{
	uint64_t a = address;
	a = bitRemove(a , 0, m_start_index);
	a = bitRemove(a , m_end_index,64);
	
	a = a >> (m_start_index+1);
	assert(a < (unsigned int)m_nb_set);
	
	return (int)a;
}

// Assembly:
subq $0x28, %rsp
movq %rdi, 0x20(%rsp)
movq %rsi, 0x18(%rsp)
movq 0x20(%rsp), %rax
movq %rax, 0x8(%rsp)
movq 0x18(%rsp), %rcx
movq %rcx, 0x10(%rsp)
movq 0x10(%rsp), %rdi
movl 0x94(%rax), %edx
xorl %esi, %esi
callq 0x655b0
movq %rax, %rcx
movq 0x8(%rsp), %rax
movq %rcx, 0x10(%rsp)
movq 0x10(%rsp), %rdi
movl 0x98(%rax), %esi
movl $0x40, %edx
callq 0x655b0
movq 0x8(%rsp), %rcx
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rax
movl 0x94(%rcx), %ecx
addl $0x1, %ecx
movl %ecx, %ecx
shrq %cl, %rax
movq 0x8(%rsp), %rcx
movq %rax, 0x10(%rsp)
movq 0x10(%rsp), %rax
movl 0xac(%rcx), %ecx
cmpq %rcx, %rax
jae 0x3a14f
jmp 0x3a16e
leaq 0x37fd1(%rip), %rdi     # 0x72127
leaq 0x385f5(%rip), %rsi     # 0x72752
movl $0x29b, %edx            # imm = 0x29B
leaq 0x389de(%rip), %rcx     # 0x72b47
callq 0x5260
movq 0x10(%rsp), %rax
addq $0x28, %rsp
retq
nopl (%rax,%rax)
// File: gvaumour[P]cache-simulator/src/HybridCache.cc
// Function: HybridCache::signalWB(Access, bool)
void
HybridCache::signalWB(Access wb_request, bool isKept)
{
	CacheEntry* entry = getEntry(wb_request.m_address);
	if(entry != NULL)
	{
		entete_debug();
		DPRINTF(DebugCache , "Invalidation of the block [%#lx]\n" , entry->address);
		m_system->signalWB(wb_request , isKept);		
	}
	
}

// Assembly:
subq $0xe8, %rsp
movb %sil, %cl
leaq 0xf0(%rsp), %rax
movq %rax, 0x50(%rsp)
movq %rdi, 0xe0(%rsp)
andb $0x1, %cl
movb %cl, 0xdf(%rsp)
movq 0xe0(%rsp), %rdi
movq %rdi, 0x58(%rsp)
movq (%rax), %rsi
callq 0x387e0
movq %rax, 0xd0(%rsp)
cmpq $0x0, 0xd0(%rsp)
je 0x3a31a
movq 0x58(%rsp), %rdi
callq 0x38560
leaq 0xaf(%rsp), %rdi
movq %rdi, 0x48(%rsp)
callq 0x56a0
movq 0x48(%rsp), %rdx
leaq 0x38671(%rip), %rsi     # 0x7286e
leaq 0xb0(%rsp), %rdi
callq 0x5530
jmp 0x3a20c
leaq 0x59ddd(%rip), %rdi     # 0x93ff0
addq $0x8, %rdi
leaq 0xb0(%rsp), %rsi
callq 0x33a00
movq %rax, 0x40(%rsp)
jmp 0x3a22b
leaq 0xb0(%rsp), %rdi
callq 0x5768
leaq 0xaf(%rsp), %rdi
callq 0x53e0
movq 0x40(%rsp), %rax
cmpq $0x0, %rax
je 0x3a2b2
movq 0xd0(%rsp), %rax
movq 0x8(%rax), %rsi
leaq 0x38911(%rip), %rdi     # 0x72b74
movb $0x0, %al
callq 0x5060
jmp 0x3a2b2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa0(%rsp)
movl %eax, 0x9c(%rsp)
jmp 0x3a2a3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0xa0(%rsp)
movl %eax, 0x9c(%rsp)
leaq 0xb0(%rsp), %rdi
callq 0x5768
leaq 0xaf(%rsp), %rdi
callq 0x53e0
jmp 0x3a322
movq 0x50(%rsp), %rsi
movq 0x58(%rsp), %rax
movq 0xb8(%rax), %rax
movq %rax, 0x38(%rsp)
leaq 0x60(%rsp), %rdi
movl $0x38, %edx
callq 0x52f0
movq 0x38(%rsp), %rdi
movb 0xdf(%rsp), %al
movq 0x90(%rsp), %rdx
movq %rsp, %rcx
movq %rdx, 0x30(%rcx)
movups 0x60(%rsp), %xmm0
movups 0x70(%rsp), %xmm1
movups 0x80(%rsp), %xmm2
movups %xmm2, 0x20(%rcx)
movups %xmm1, 0x10(%rcx)
movups %xmm0, (%rcx)
movzbl %al, %esi
andl $0x1, %esi
callq 0x46ec0
addq $0xe8, %rsp
retq
movq 0xa0(%rsp), %rdi
callq 0x5690
nop
// File: gvaumour[P]cache-simulator/src/HybridCache.cc
// Function: HybridCache::deallocate(CacheEntry*)
void 
HybridCache::deallocate(CacheEntry* destination_entry)
{
	uint64_t addr = destination_entry->address;
	updateStatsDeallocate(destination_entry);

	map<uint64_t,HybridLocation>::iterator it = m_tag_index.find(addr);	
	if(it != m_tag_index.end()){
		m_tag_index.erase(it);	
	}	

	destination_entry->initEntry();
	
	
}

// Assembly:
subq $0x48, %rsp
movq %rdi, 0x40(%rsp)
movq %rsi, 0x38(%rsp)
movq 0x40(%rsp), %rdi
movq %rdi, 0x8(%rsp)
movq 0x38(%rsp), %rax
movq 0x8(%rax), %rax
movq %rax, 0x30(%rsp)
movq 0x38(%rsp), %rsi
callq 0x37fc0
movq 0x8(%rsp), %rdi
addq $0x38, %rdi
leaq 0x30(%rsp), %rsi
callq 0x3d9b0
movq 0x8(%rsp), %rdi
movq %rax, 0x28(%rsp)
addq $0x38, %rdi
callq 0x3db60
movq %rax, 0x20(%rsp)
leaq 0x28(%rsp), %rdi
leaq 0x20(%rsp), %rsi
callq 0x3db40
testb $0x1, %al
jne 0x3a3a0
jmp 0x3a3c2
movq 0x8(%rsp), %rdi
addq $0x38, %rdi
movq 0x28(%rsp), %rax
movq %rax, 0x18(%rsp)
movq 0x18(%rsp), %rsi
callq 0x3db90
movq %rax, 0x10(%rsp)
movq 0x38(%rsp), %rdi
callq 0x3dbd0
addq $0x48, %rsp
retq
nopw %cs:(%rax,%rax)
// File: gvaumour[P]cache-simulator/src/HybridCache.cc
// Function: HybridCache::classifyRD(int, int)
RD_TYPE
HybridCache::classifyRD(int set , int index)
{
	vector<CacheEntry*> line;
	int64_t ref_rd = m_tableSRAM[set][index]->policyInfo;
	
	line = m_tableSRAM[set];
	
	int position = 0;
	
	/* Determine the position of the cache line in the LRU stack */
	for(unsigned i = 0 ; i < line.size() ; i ++)
	{
		if(line[i]->policyInfo < ref_rd && line[i]->isValid)
			position++;
	}	

	if(position < 4)
		return RD_SHORT;
	else
		return RD_MEDIUM;
}

// Assembly:
subq $0x78, %rsp
movq %rdi, 0x68(%rsp)
movl %esi, 0x64(%rsp)
movl %edx, 0x60(%rsp)
movq 0x68(%rsp), %rax
movq %rax, 0x10(%rsp)
leaq 0x48(%rsp), %rdi
movq %rdi, 0x20(%rsp)
callq 0xfe30
movq 0x10(%rsp), %rdi
addq $0x20, %rdi
movq %rdi, 0x18(%rsp)
movslq 0x64(%rsp), %rsi
callq 0xf9a0
movq %rax, %rdi
movslq 0x60(%rsp), %rsi
callq 0xf9c0
movq 0x18(%rsp), %rdi
movq (%rax), %rax
movslq 0x38(%rax), %rax
movq %rax, 0x40(%rsp)
movslq 0x64(%rsp), %rsi
callq 0xf9a0
movq 0x20(%rsp), %rdi
movq %rax, %rsi
callq 0xfe40
jmp 0x3a879
movl $0x0, 0x30(%rsp)
movl $0x0, 0x2c(%rsp)
movl 0x2c(%rsp), %eax
movq %rax, 0x8(%rsp)
leaq 0x48(%rsp), %rdi
callq 0x10100
movq %rax, %rcx
movq 0x8(%rsp), %rax
cmpq %rcx, %rax
jae 0x3a918
movl 0x2c(%rsp), %eax
movl %eax, %esi
leaq 0x48(%rsp), %rdi
callq 0xf9c0
movq (%rax), %rax
movslq 0x38(%rax), %rax
cmpq 0x40(%rsp), %rax
jge 0x3a906
movl 0x2c(%rsp), %eax
movl %eax, %esi
leaq 0x48(%rsp), %rdi
callq 0xf9c0
movq (%rax), %rax
testb $0x1, (%rax)
je 0x3a906
movl 0x30(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x30(%rsp)
jmp 0x3a906
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x38(%rsp)
movl %eax, 0x34(%rsp)
leaq 0x48(%rsp), %rdi
callq 0x10120
jmp 0x3a954
jmp 0x3a908
movl 0x2c(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x2c(%rsp)
jmp 0x3a889
cmpl $0x4, 0x30(%rsp)
jge 0x3a931
movl $0x0, 0x74(%rsp)
movl $0x1, 0x28(%rsp)
jmp 0x3a941
movl $0x1, 0x74(%rsp)
movl $0x1, 0x28(%rsp)
leaq 0x48(%rsp), %rdi
callq 0x10120
movl 0x74(%rsp), %eax
addq $0x78, %rsp
retq
movq 0x38(%rsp), %rdi
callq 0x5690
nop