Chromium Code Reviews| Index: src/hydrogen-phases.h |
| diff --git a/src/vm-state.h b/src/hydrogen-phases.h |
| similarity index 73% |
| copy from src/vm-state.h |
| copy to src/hydrogen-phases.h |
| index 765b5701595b7f9637da05b0783662d603506463..77d7979a6eefa0bc2babb8b3acd4b0102cd7156f 100644 |
| --- a/src/vm-state.h |
| +++ b/src/hydrogen-phases.h |
| @@ -1,4 +1,4 @@ |
| -// Copyright 2010 the V8 project authors. All rights reserved. |
| +// Copyright 2013 the V8 project authors. All rights reserved. |
| // Redistribution and use in source and binary forms, with or without |
| // modification, are permitted provided that the following conditions are |
| // met: |
| @@ -25,37 +25,32 @@ |
| // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| -#ifndef V8_VM_STATE_H_ |
| -#define V8_VM_STATE_H_ |
| +#ifndef V8_HYDROGEN_PHASES_H_ |
| +#define V8_HYDROGEN_PHASES_H_ |
| -#include "allocation.h" |
| -#include "isolate.h" |
| +#include "hydrogen.h" |
| namespace v8 { |
| namespace internal { |
| -template <StateTag Tag> |
| -class VMState BASE_EMBEDDED { |
| - public: |
| - explicit inline VMState(Isolate* isolate); |
| - inline ~VMState(); |
| - private: |
| - Isolate* isolate_; |
| - StateTag previous_tag_; |
| -}; |
| +class HInferRepresentationPhase : public HPhase { |
|
danno
2013/06/27 13:45:30
For GVN, we have a separate file. Does it make sen
Benedikt Meurer
2013/06/27 19:50:57
Done.
|
| + public: |
| + explicit HInferRepresentationPhase(HGraph* graph) |
| + : HPhase("H_Infer representations", graph), |
| + worklist_(8, zone()), |
| + in_worklist_(graph->GetMaximumValueID(), zone()) { } |
| + void Run(); |
| + void AddToWorklist(HValue* current); |
| -class ExternalCallbackScope BASE_EMBEDDED { |
| - public: |
| - inline ExternalCallbackScope(Isolate* isolate, Address callback); |
| - inline ~ExternalCallbackScope(); |
| private: |
| - Isolate* isolate_; |
| - Address previous_callback_; |
| -}; |
| + ZoneList<HValue*> worklist_; |
| + BitVector in_worklist_; |
| -} } // namespace v8::internal |
| + DISALLOW_COPY_AND_ASSIGN(HInferRepresentationPhase); |
| +}; |
| -#endif // V8_VM_STATE_H_ |
| +} } // namespace v8::internal |
| +#endif // V8_HYDROGEN_PHASES_H_ |