Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(132)

Side by Side Diff: test/cctest/compiler/graph-builder-tester.h

Issue 425003004: Implement representation selection as part of SimplifiedLowering. Representation selection also req… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « test/cctest/compiler/call-tester.h ('k') | test/cctest/compiler/test-changes-lowering.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 the V8 project authors. All rights reserved. 1 // Copyright 2014 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_ 5 #ifndef V8_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_
6 #define V8_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_ 6 #define V8_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_
7 7
8 #include "src/v8.h" 8 #include "src/v8.h"
9 #include "test/cctest/cctest.h" 9 #include "test/cctest/cctest.h"
10 10
(...skipping 23 matching lines...) Expand all
34 } 34 }
35 }; 35 };
36 36
37 37
38 class MachineCallHelper : public CallHelper { 38 class MachineCallHelper : public CallHelper {
39 public: 39 public:
40 MachineCallHelper(Zone* zone, MachineCallDescriptorBuilder* builder); 40 MachineCallHelper(Zone* zone, MachineCallDescriptorBuilder* builder);
41 41
42 Node* Parameter(int offset); 42 Node* Parameter(int offset);
43 43
44 void GenerateCode() { Generate(); }
45
44 protected: 46 protected:
45 virtual byte* Generate(); 47 virtual byte* Generate();
46 virtual void VerifyParameters(int parameter_count, 48 virtual void VerifyParameters(int parameter_count,
47 MachineRepresentation* parameters); 49 MachineRepresentation* parameters);
48 void InitParameters(GraphBuilder* builder, CommonOperatorBuilder* common); 50 void InitParameters(GraphBuilder* builder, CommonOperatorBuilder* common);
49 51
50 protected: 52 protected:
51 int parameter_count() const { 53 int parameter_count() const {
52 return call_descriptor_builder_->parameter_count(); 54 return call_descriptor_builder_->parameter_count();
53 } 55 }
(...skipping 10 matching lines...) Expand all
64 class GraphAndBuilders { 66 class GraphAndBuilders {
65 public: 67 public:
66 explicit GraphAndBuilders(Zone* zone) 68 explicit GraphAndBuilders(Zone* zone)
67 : main_graph_(new (zone) Graph(zone)), 69 : main_graph_(new (zone) Graph(zone)),
68 main_common_(zone), 70 main_common_(zone),
69 main_machine_(zone), 71 main_machine_(zone),
70 main_simplified_(zone) {} 72 main_simplified_(zone) {}
71 73
72 protected: 74 protected:
73 // Prefixed with main_ to avoid naiming conflicts. 75 // Prefixed with main_ to avoid naiming conflicts.
74 Graph* const main_graph_; 76 Graph* main_graph_;
75 CommonOperatorBuilder main_common_; 77 CommonOperatorBuilder main_common_;
76 MachineOperatorBuilder main_machine_; 78 MachineOperatorBuilder main_machine_;
77 SimplifiedOperatorBuilder main_simplified_; 79 SimplifiedOperatorBuilder main_simplified_;
78 }; 80 };
79 81
80 82
81 template <typename ReturnType> 83 template <typename ReturnType>
82 class GraphBuilderTester 84 class GraphBuilderTester
83 : public HandleAndZoneScope, 85 : public HandleAndZoneScope,
84 private GraphAndBuilders, 86 private GraphAndBuilders,
(...skipping 19 matching lines...) Expand all
104 } 106 }
105 virtual ~GraphBuilderTester() {} 107 virtual ~GraphBuilderTester() {}
106 108
107 Factory* factory() const { return isolate()->factory(); } 109 Factory* factory() const { return isolate()->factory(); }
108 }; 110 };
109 } // namespace compiler 111 } // namespace compiler
110 } // namespace internal 112 } // namespace internal
111 } // namespace v8 113 } // namespace v8
112 114
113 #endif // V8_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_ 115 #endif // V8_CCTEST_COMPILER_GRAPH_BUILDER_TESTER_H_
OLDNEW
« no previous file with comments | « test/cctest/compiler/call-tester.h ('k') | test/cctest/compiler/test-changes-lowering.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698