Changeset 80738 in webkit for trunk/Source/JavaScriptCore/bytecode/CodeBlock.h
- Timestamp:
- Mar 10, 2011, 11:27:49 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/bytecode/CodeBlock.h
r80684 r80738 97 97 struct CallLinkInfo { 98 98 CallLinkInfo() 99 : callee(0) 100 , position(0) 99 : position(0) 101 100 , hasSeenShouldRepatch(0) 102 101 { … … 106 105 CodeLocationDataLabelPtr hotPathBegin; 107 106 CodeLocationNearCall hotPathOther; 108 CodeBlock* ownerCodeBlock; 109 CodeBlock* callee; 107 WriteBarrier<JSFunction> callee; 110 108 unsigned position : 31; 111 109 unsigned hasSeenShouldRepatch : 1; 112 110 113 void setUnlinked() { callee = 0; }111 void setUnlinked() { callee.clear(); } 114 112 bool isLinked() { return callee; } 115 113 … … 258 256 void refStructures(Instruction* vPC) const; 259 257 void derefStructures(Instruction* vPC) const; 260 #if ENABLE(JIT_OPTIMIZE_CALL)261 void unlinkCallers();262 #endif263 258 264 259 static void dumpStatistics(); … … 293 288 294 289 #if ENABLE(JIT) 295 void addCaller( CallLinkInfo* caller)296 { 297 caller->callee = this;290 void addCaller(JSGlobalData& globalData, CallLinkInfo* caller, JSFunction* callee) 291 { 292 caller->callee.set(globalData, ownerExecutable(), callee); 298 293 caller->position = m_linkedCallerList.size(); 299 294 m_linkedCallerList.append(caller); 300 }301 302 void removeCaller(CallLinkInfo* caller)303 {304 unsigned pos = caller->position;305 unsigned lastPos = m_linkedCallerList.size() - 1;306 307 if (pos != lastPos) {308 m_linkedCallerList[pos] = m_linkedCallerList[lastPos];309 m_linkedCallerList[pos]->position = pos;310 }311 m_linkedCallerList.shrink(lastPos);312 295 } 313 296
Note:
See TracChangeset
for help on using the changeset viewer.