[llvm-commits] CVS: llvm/lib/Reoptimizer/TraceCache/VirtualMem.cpp
Anand Shukla
ashukla at cs.uiuc.edu
Sat May 31 21:34:01 PDT 2003
Changes in directory llvm/lib/Reoptimizer/TraceCache:
VirtualMem.cpp updated: 1.9 -> 1.10
---
Log message:
Simple additions to the runtime API
---
Diffs of the changes:
Index: llvm/lib/Reoptimizer/TraceCache/VirtualMem.cpp
diff -u llvm/lib/Reoptimizer/TraceCache/VirtualMem.cpp:1.9 llvm/lib/Reoptimizer/TraceCache/VirtualMem.cpp:1.10
--- llvm/lib/Reoptimizer/TraceCache/VirtualMem.cpp:1.9 Fri Feb 14 14:45:42 2003
+++ llvm/lib/Reoptimizer/TraceCache/VirtualMem.cpp Sat May 31 21:33:18 2003
@@ -143,9 +143,10 @@
//write branch inst, followed by a null inst in delay slot
void VirtualMem::writeBranchInstruction(uint64_t location, uint64_t target){
//uint64_t instToWrite = getDepJumpInstr(0x10800000, target, location);
- unsigned int instToWrite = getDepJumpInstr(0x10800000, target, location);
+ //create branch will annul bit set
+ unsigned int instToWrite = getDepJumpInstr(0x30800000, target, location);
writeInstToVM(location, instToWrite);
- writeInstToVM(location+4, 0x01000000);
+ //writeInstToVM(location+4, 0x01000000);
}
#ifdef GET_TRACE_TIME
@@ -179,13 +180,15 @@
void VirtualMem::setBranches(std::map<int, uint64_t> &branchMap,
uint64_t startAddr){
-
+
+ //std::cerr<<"In branch map!\n";
for(std::map<int, uint64_t>::iterator MI = branchMap.begin(),
ME = branchMap.end(); MI != ME; ++MI){
uint64_t frm = startAddr+ 4*MI->first;
uint64_t to = MI->second;
+ //std::cerr<<"From: "<<(void *)frm<<"\t To: "<<(void *)to<<"\n";
unsigned int instr = readInstrFrmVm(frm);
//check if instr is a branch
@@ -218,7 +221,7 @@
}
}
-unsigned int VirtualMem::getInvertedBranch(uint64_t br1){
+unsigned int VirtualMem::getInvertedBranch(unsigned int br1){
assert(isBranchInstr(br1) && "Not a branch!");
unsigned int cond = 0;
More information about the llvm-commits
mailing list