Changeset 90414 in webkit for trunk/Source/JavaScriptCore/runtime/Executable.h
- Timestamp:
- Jul 5, 2011, 4:18:23 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/runtime/Executable.h
r89973 r90414 44 44 45 45 struct ExceptionInfo; 46 47 enum CodeSpecializationKind { CodeForCall, CodeForConstruct }; 46 48 47 49 class ExecutableBase : public JSCell { … … 91 93 ASSERT(m_jitCodeForConstruct); 92 94 return m_jitCodeForConstruct; 95 } 96 97 JITCode& generatedJITCodeFor(CodeSpecializationKind kind) 98 { 99 if (kind == CodeForCall) 100 return generatedJITCodeForCall(); 101 ASSERT(kind == CodeForConstruct); 102 return generatedJITCodeForConstruct(); 93 103 } 94 104 … … 388 398 return *m_codeBlockForConstruct; 389 399 } 400 401 JSObject* compileFor(ExecState* exec, ScopeChainNode* scopeChainNode, CodeSpecializationKind kind) 402 { 403 if (kind == CodeForCall) 404 return compileForCall(exec, scopeChainNode); 405 ASSERT(kind == CodeForConstruct); 406 return compileForConstruct(exec, scopeChainNode); 407 } 408 409 bool isGeneratedFor(CodeSpecializationKind kind) 410 { 411 if (kind == CodeForCall) 412 return isGeneratedForCall(); 413 ASSERT(kind == CodeForConstruct); 414 return isGeneratedForConstruct(); 415 } 416 417 FunctionCodeBlock& generatedBytecodeFor(CodeSpecializationKind kind) 418 { 419 if (kind == CodeForCall) 420 return generatedBytecodeForCall(); 421 ASSERT(kind == CodeForConstruct); 422 return generatedBytecodeForConstruct(); 423 } 390 424 391 425 const Identifier& name() { return m_name; } … … 437 471 ASSERT(m_jitCodeForConstructWithArityCheck); 438 472 return m_jitCodeForConstructWithArityCheck; 473 } 474 475 MacroAssemblerCodePtr generatedJITCodeWithArityCheckFor(CodeSpecializationKind kind) 476 { 477 if (kind == CodeForCall) 478 return generatedJITCodeForCallWithArityCheck(); 479 ASSERT(kind == CodeForConstruct); 480 return generatedJITCodeForConstructWithArityCheck(); 439 481 } 440 482 #endif
Note:
See TracChangeset
for help on using the changeset viewer.