// File: /workspace/github_cpp_makefile_star2_O2/gvaumour[P]cache-simulator/src/PHC.cc
// Function: PHCPredictor::initFeatures()
void
PHCPredictor::initFeatures()
{
	vector<string>* criterias_name = &m_criterias_names;
	vector<hashing_function>* features_hash = &m_features_hash;
	vector<FeatureTable*>* features = &m_features;		

	for(auto feature : *criterias_name)
	{
		features->push_back( new FeatureTable(m_tableSize, feature, false));
		if(feature == "MissPC_LSB")
			features_hash->push_back(hashingMissPC_LSB);
		else if(feature == "MissPC_LSB1")
			features_hash->push_back(hashingMissPC_LSB1);
		else if(feature == "MissPC_MSB")
			features_hash->push_back(hashingMissPC_MSB);		

		else if(feature == "TagBlock")
			features_hash->push_back(hashingTag_block);
		else if(feature == "TagPage")
			features_hash->push_back(hashingTag_page);
	
		else if(feature == "MissCounter")
			features_hash->push_back(hashing_MissCounter);	
		else if(feature == "MissCounter1")
			features_hash->push_back(hashing_MissCounter1);
		
		else if( feature == "CallStack")
			features_hash->push_back(hashing_CallStack);
		else if( feature == "CallStack1")	
			features_hash->push_back(hashing_CallStack1);
			
		else if(feature == "currentPC")
			features_hash->push_back(hashing_currentPC);
		else if(feature == "currentPC1")
			features_hash->push_back(hashing_currentPC1);
		else if(feature == "currentPC_3")
			features_hash->push_back(hashingcurrentPC_3);
		else if(feature == "currentPC_2")
			features_hash->push_back(hashingcurrentPC_2);
		else if(feature == "currentPC_1")
			features_hash->push_back(hashingcurrentPC_1);
		else
			assert(false && "Error while initializing the features , wrong name\n");


		if(feature == "CallStack" || feature == "CallStack1")
			m_need_callee_file = true;
	}	
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movq %rdi, %rbx
leaq 0x288(%rdi), %rax
movq %rax, 0x10(%rsp)
leaq 0x270(%rdi), %rax
movq %rax, 0x18(%rsp)
movq 0x2a0(%rdi), %r12
movq 0x2a8(%rdi), %rax
movq %rax, 0x20(%rsp)
leaq 0x48(%rsp), %r13
leaq 0x28(%rsp), %rbp
cmpq 0x20(%rsp), %r12
je 0x1ab5d
movq %r13, %rdi
movq %r12, %rsi
callq 0x5410
movl $0xa8, %edi
callq 0x52e0
movq %rax, %r14
movl 0x2d0(%rbx), %r15d
movq %rbp, %rdi
movq %r13, %rsi
callq 0x5410
movq %rbp, %rdx
movb $0x1, %bpl
movq %r14, %rdi
movl %r15d, %esi
movq %rdx, %r15
xorl %ecx, %ecx
callq 0x10b8c
movq %r14, 0x8(%rsp)
xorl %ebp, %ebp
movq 0x18(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0xae24
movq %r15, %rbp
movq %r15, %rdi
callq 0x5618
movq %r13, %rdi
leaq 0x107f4(%rip), %rsi     # 0x2b05e
callq 0x9f59
testb %al, %al
je 0x1a893
leaq -0x876e(%rip), %rax     # 0x1210c
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0x107cc(%rip), %rsi     # 0x2b069
callq 0x9f59
testb %al, %al
je 0x1a8c6
leaq -0x8794(%rip), %rax     # 0x12119
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0x107a5(%rip), %rsi     # 0x2b075
callq 0x9f59
testb %al, %al
je 0x1a8f9
leaq -0x879a(%rip), %rax     # 0x12146
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0x1077d(%rip), %rsi     # 0x2b080
callq 0x9f59
testb %al, %al
je 0x1a92c
leaq -0x88e8(%rip), %rax     # 0x1202b
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0x10753(%rip), %rsi     # 0x2b089
callq 0x9f59
testb %al, %al
je 0x1a95f
leaq -0x8910(%rip), %rax     # 0x12036
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0x10728(%rip), %rsi     # 0x2b091
callq 0x9f59
testb %al, %al
je 0x1a992
leaq -0x8825(%rip), %rax     # 0x12154
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0x10701(%rip), %rsi     # 0x2b09d
callq 0x9f59
testb %al, %al
je 0x1a9c5
leaq -0x884e(%rip), %rax     # 0x1215e
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0x106db(%rip), %rsi     # 0x2b0aa
callq 0x9f59
testb %al, %al
je 0x1a9f8
leaq -0x880f(%rip), %rax     # 0x121d0
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0x106b2(%rip), %rsi     # 0x2b0b4
callq 0x9f59
testb %al, %al
je 0x1aa2b
leaq -0x882a(%rip), %rax     # 0x121e8
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0xf821(%rip), %rsi      # 0x2a256
callq 0x9f59
testb %al, %al
je 0x1aa5e
leaq -0x88c3(%rip), %rax     # 0x12182
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0xf7f8(%rip), %rsi      # 0x2a260
callq 0x9f59
testb %al, %al
je 0x1aa91
leaq -0x88de(%rip), %rax     # 0x1219a
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0x10624(%rip), %rsi     # 0x2b0bf
callq 0x9f59
testb %al, %al
je 0x1aac1
leaq -0x8ab7(%rip), %rax     # 0x11ff4
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0x10600(%rip), %rsi     # 0x2b0cb
callq 0x9f59
testb %al, %al
je 0x1aaf1
leaq -0x8b1e(%rip), %rax     # 0x11fbd
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
jmp 0x1ab1f
movq %r13, %rdi
leaq 0x105dc(%rip), %rsi     # 0x2b0d7
callq 0x9f59
testb %al, %al
je 0x1ab6c
leaq -0x8b84(%rip), %rax     # 0x11f87
movq %rax, 0x8(%rsp)
movq 0x10(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1c78a
movq %r13, %rdi
leaq 0x10581(%rip), %rsi     # 0x2b0aa
callq 0x9f59
testb %al, %al
jne 0x1ab45
movq %r13, %rdi
leaq 0x10578(%rip), %rsi     # 0x2b0b4
callq 0x9f59
testb %al, %al
je 0x1ab4c
movb $0x1, 0x2e0(%rbx)
movq %r13, %rdi
callq 0x5618
addq $0x20, %r12
jmp 0x1a7f4
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x10570(%rip), %rdi     # 0x2b0e3
leaq 0x105a9(%rip), %rsi     # 0x2b123
leaq 0x105ad(%rip), %rcx     # 0x2b12e
movl $0x89, %edx
callq 0x51e0
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
jmp 0x1abac
movq %rax, %rbx
jmp 0x1abc3
movq %rax, %rbx
jmp 0x1abcb
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0x5618
testb %bpl, %bpl
je 0x1abcb
movq %r14, %rdi
callq 0x52a0
leaq 0x48(%rsp), %rdi
callq 0x5618
movq %rbx, %rdi
callq 0x5570
nop