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

Side by Side Diff: vm/flow_graph_compiler_x64.h

Issue 10407082: Reland: Migrate {Closure,Instance,Static}Call to use location-based code generation templates. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years, 7 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 | « no previous file | vm/flow_graph_compiler_x64.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 (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef VM_FLOW_GRAPH_COMPILER_X64_H_ 5 #ifndef VM_FLOW_GRAPH_COMPILER_X64_H_
6 #define VM_FLOW_GRAPH_COMPILER_X64_H_ 6 #define VM_FLOW_GRAPH_COMPILER_X64_H_
7 7
8 #ifndef VM_FLOW_GRAPH_COMPILER_H_ 8 #ifndef VM_FLOW_GRAPH_COMPILER_H_
9 #error Include flow_graph_compiler.h instead of flow_graph_compiler_x64.h. 9 #error Include flow_graph_compiler.h instead of flow_graph_compiler_x64.h.
10 #endif 10 #endif
(...skipping 25 matching lines...) Expand all
36 // Infrastructure copied from class CodeGenerator or stubbed out. 36 // Infrastructure copied from class CodeGenerator or stubbed out.
37 void FinalizePcDescriptors(const Code& code); 37 void FinalizePcDescriptors(const Code& code);
38 void FinalizeStackmaps(const Code& code); 38 void FinalizeStackmaps(const Code& code);
39 void FinalizeVarDescriptors(const Code& code); 39 void FinalizeVarDescriptors(const Code& code);
40 void FinalizeExceptionHandlers(const Code& code); 40 void FinalizeExceptionHandlers(const Code& code);
41 void FinalizeComments(const Code& code); 41 void FinalizeComments(const Code& code);
42 42
43 Assembler* assembler() const { return assembler_; } 43 Assembler* assembler() const { return assembler_; }
44 44
45 private: 45 private:
46 // TODO(fschneider): Clean up friend-class declarations once all code
47 // generator templates have been moved to intermediate_language_x64.cc.
48 #define DECLARE_FRIEND(ShortName, ClassName) friend class ClassName;
49 FOR_EACH_COMPUTATION(DECLARE_FRIEND)
50 #undef DECLARE_FRIEND
51
46 static const int kLocalsOffsetFromFP = (-1 * kWordSize); 52 static const int kLocalsOffsetFromFP = (-1 * kWordSize);
47 53
48 // Constructor is lighweight, major initialization work should occur here. 54 // Constructor is lighweight, major initialization work should occur here.
49 // This makes it easier to measure time spent in the compiler. 55 // This makes it easier to measure time spent in the compiler.
50 void InitCompiler(); 56 void InitCompiler();
51 57
52 struct BlockInfo : public ZoneAllocated { 58 struct BlockInfo : public ZoneAllocated {
53 public: 59 public:
54 BlockInfo() : label() { } 60 BlockInfo() : label() { }
55 61
(...skipping 17 matching lines...) Expand all
73 #define DECLARE_VISIT_INSTRUCTION(ShortName) \ 79 #define DECLARE_VISIT_INSTRUCTION(ShortName) \
74 virtual void Visit##ShortName(ShortName##Instr* instr); 80 virtual void Visit##ShortName(ShortName##Instr* instr);
75 81
76 FOR_EACH_COMPUTATION(DECLARE_VISIT_COMPUTATION) 82 FOR_EACH_COMPUTATION(DECLARE_VISIT_COMPUTATION)
77 FOR_EACH_INSTRUCTION(DECLARE_VISIT_INSTRUCTION) 83 FOR_EACH_INSTRUCTION(DECLARE_VISIT_INSTRUCTION)
78 84
79 #undef DECLARE_VISIT_COMPUTATION 85 #undef DECLARE_VISIT_COMPUTATION
80 #undef DECLARE_VISIT_INSTRUCTION 86 #undef DECLARE_VISIT_INSTRUCTION
81 87
82 void EmitInstructionPrologue(Instruction* instr); 88 void EmitInstructionPrologue(Instruction* instr);
83 void LoadInputs(LocationSummary* summary);
84 89
85 // Emit code to load a Value into register 'dst'. 90 // Emit code to load a Value into register 'dst'.
86 void LoadValue(Register dst, Value* value); 91 void LoadValue(Register dst, Value* value);
87 92
88 void EmitComment(Instruction* instr); 93 void EmitComment(Instruction* instr);
89 94
90 // Emit an instance call. 95 // Emit an instance call.
91 void EmitInstanceCall(intptr_t cid, 96 void EmitInstanceCall(intptr_t cid,
92 intptr_t token_index, 97 intptr_t token_index,
93 intptr_t try_index, 98 intptr_t try_index,
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
155 DescriptorList* pc_descriptors_list_; 160 DescriptorList* pc_descriptors_list_;
156 ExceptionHandlerList* exception_handlers_list_; 161 ExceptionHandlerList* exception_handlers_list_;
157 const bool is_optimizing_; 162 const bool is_optimizing_;
158 163
159 DISALLOW_COPY_AND_ASSIGN(FlowGraphCompiler); 164 DISALLOW_COPY_AND_ASSIGN(FlowGraphCompiler);
160 }; 165 };
161 166
162 } // namespace dart 167 } // namespace dart
163 168
164 #endif // VM_FLOW_GRAPH_COMPILER_X64_H_ 169 #endif // VM_FLOW_GRAPH_COMPILER_X64_H_
OLDNEW
« no previous file with comments | « no previous file | vm/flow_graph_compiler_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698