Changeset 252021 in webkit for trunk/Source/JavaScriptCore/bytecode/CodeBlock.cpp
- Timestamp:
- Nov 4, 2019, 3:47:07 PM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/bytecode/CodeBlock.cpp
r252015 r252021 1479 1479 } 1480 1480 1481 JITAddIC* CodeBlock::addJITAddIC( BinaryArithProfile* arithProfile)1481 JITAddIC* CodeBlock::addJITAddIC(ArithProfile* arithProfile) 1482 1482 { 1483 1483 ConcurrentJSLocker locker(m_lock); … … 1485 1485 } 1486 1486 1487 JITMulIC* CodeBlock::addJITMulIC( BinaryArithProfile* arithProfile)1487 JITMulIC* CodeBlock::addJITMulIC(ArithProfile* arithProfile) 1488 1488 { 1489 1489 ConcurrentJSLocker locker(m_lock); … … 1491 1491 } 1492 1492 1493 JITSubIC* CodeBlock::addJITSubIC( BinaryArithProfile* arithProfile)1493 JITSubIC* CodeBlock::addJITSubIC(ArithProfile* arithProfile) 1494 1494 { 1495 1495 ConcurrentJSLocker locker(m_lock); … … 1497 1497 } 1498 1498 1499 JITNegIC* CodeBlock::addJITNegIC( UnaryArithProfile* arithProfile)1499 JITNegIC* CodeBlock::addJITNegIC(ArithProfile* arithProfile) 1500 1500 { 1501 1501 ConcurrentJSLocker locker(m_lock); … … 3084 3084 } 3085 3085 3086 BinaryArithProfile* CodeBlock::binaryArithProfileForBytecodeIndex(BytecodeIndex bytecodeIndex) 3087 { 3088 return binaryArithProfileForPC(instructions().at(bytecodeIndex.offset()).ptr()); 3089 } 3090 3091 UnaryArithProfile* CodeBlock::unaryArithProfileForBytecodeIndex(BytecodeIndex bytecodeIndex) 3092 { 3093 return unaryArithProfileForPC(instructions().at(bytecodeIndex.offset()).ptr()); 3094 } 3095 3096 BinaryArithProfile* CodeBlock::binaryArithProfileForPC(const Instruction* pc) 3086 ArithProfile* CodeBlock::arithProfileForBytecodeIndex(BytecodeIndex bytecodeIndex) 3087 { 3088 return arithProfileForPC(instructions().at(bytecodeIndex.offset()).ptr()); 3089 } 3090 3091 ArithProfile* CodeBlock::arithProfileForPC(const Instruction* pc) 3097 3092 { 3098 3093 switch (pc->opcodeID()) { 3094 case op_negate: 3095 return &pc->as<OpNegate>().metadata(this).m_arithProfile; 3099 3096 case op_add: 3100 3097 return &pc->as<OpAdd>().metadata(this).m_arithProfile; … … 3112 3109 } 3113 3110 3114 UnaryArithProfile* CodeBlock::unaryArithProfileForPC(const Instruction* pc)3115 {3116 switch (pc->opcodeID()) {3117 case op_negate:3118 return &pc->as<OpNegate>().metadata(this).m_arithProfile;3119 default:3120 break;3121 }3122 3123 return nullptr;3124 }3125 3126 3111 bool CodeBlock::couldTakeSpecialArithFastCase(BytecodeIndex bytecodeIndex) 3127 3112 { 3128 3113 if (!hasBaselineJITProfiling()) 3129 3114 return false; 3130 BinaryArithProfile* profile = binaryArithProfileForBytecodeIndex(bytecodeIndex);3115 ArithProfile* profile = arithProfileForBytecodeIndex(bytecodeIndex); 3131 3116 if (!profile) 3132 3117 return false;
Note:
See TracChangeset
for help on using the changeset viewer.