Changeset 153121 in webkit for trunk/Source/JavaScriptCore/ftl/FTLValueSource.h
- Timestamp:
- Jul 24, 2013, 8:58:38 PM (12 years ago)
- Location:
- trunk/Source/JavaScriptCore/ftl
- Files:
-
- 1 added
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ftl/FTLValueSource.h
r153120 r153121 24 24 */ 25 25 26 #ifndef DFGOSRExitCompilerCommon_h27 #define DFGOSRExitCompilerCommon_h26 #ifndef FTLValueSource_h 27 #define FTLValueSource_h 28 28 29 29 #include <wtf/Platform.h> 30 30 31 #if ENABLE( DFG_JIT)31 #if ENABLE(FTL_JIT) 32 32 33 #include "DFGCCallHelpers.h" 34 #include "DFGOSRExit.h" 33 #include "DFGNode.h" 34 #include <wtf/PrintStream.h> 35 #include <wtf/StdLibExtras.h> 35 36 36 namespace JSC { namespace DFG{37 namespace JSC { namespace FTL { 37 38 38 void handleExitCounts(CCallHelpers&, const OSRExit&); 39 void reifyInlinedCallFrames(CCallHelpers&, const OSRExit&); 40 void adjustAndJumpToTarget(CCallHelpers&, const OSRExit&); 39 enum ValueSourceKind { 40 SourceNotSet, 41 ValueInJSStack, 42 Int32InJSStack, 43 DoubleInJSStack, 44 ValueInLocals, 45 Int32InLocals, 46 BooleanInLocals, 47 DoubleInLocals, 48 ArgumentsSource, 49 SourceIsDead, 50 HaveNode 51 }; 41 52 42 } } // namespace JSC::DFG 53 class ValueSource { 54 public: 55 ValueSource() 56 : m_value(SourceNotSet) 57 { 58 } 59 60 explicit ValueSource(ValueSourceKind kind) 61 : m_value(kind) 62 { 63 } 64 65 explicit ValueSource(DFG::Node* node) 66 : m_value(bitwise_cast<uintptr_t>(node)) 67 { 68 } 69 70 ValueSourceKind kind() const 71 { 72 if (m_value < static_cast<uintptr_t>(HaveNode)) 73 return static_cast<ValueSourceKind>(m_value); 74 return HaveNode; 75 } 76 77 bool operator!() const { return kind() != SourceNotSet; } 78 79 DFG::Node* node() const 80 { 81 ASSERT(kind() == HaveNode); 82 return bitwise_cast<DFG::Node*>(m_value); 83 } 84 85 void dump(PrintStream&) const; 43 86 44 #endif // ENABLE(DFG_JIT) 87 private: 88 uintptr_t m_value; 89 }; 45 90 46 #endif // DFGOSRExitCompilerCommon_h 91 } } // namespace JSC::FTL 47 92 93 #endif // ENABLE(FTL_JIT) 94 95 #endif // FTLValueSource_h 96
Note:
See TracChangeset
for help on using the changeset viewer.