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

Side by Side Diff: runtime/vm/stub_code.h

Issue 8234016: Inline allocation of implicit closures. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 9 years, 2 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 | « runtime/vm/parser.cc ('k') | runtime/vm/stub_code.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) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, 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_STUB_CODE_H_ 5 #ifndef VM_STUB_CODE_H_
6 #define VM_STUB_CODE_H_ 6 #define VM_STUB_CODE_H_
7 7
8 #include "vm/allocation.h" 8 #include "vm/allocation.h"
9 #include "vm/assembler.h" 9 #include "vm/assembler.h"
10 10
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 return name##_entry()->EntryPoint(); \ 127 return name##_entry()->EntryPoint(); \
128 } \ 128 } \
129 static intptr_t name##Size() { \ 129 static intptr_t name##Size() { \
130 return name##_entry()->Size(); \ 130 return name##_entry()->Size(); \
131 } 131 }
132 STUB_CODE_LIST(STUB_CODE_ACCESSOR); 132 STUB_CODE_LIST(STUB_CODE_ACCESSOR);
133 #undef STUB_CODE_ACCESSOR 133 #undef STUB_CODE_ACCESSOR
134 134
135 static RawCode* GetAllocationStubForClass(const Class& cls); 135 static RawCode* GetAllocationStubForClass(const Class& cls);
136 static RawCode* GetAllocationStubForClosure(const Function& func); 136 static RawCode* GetAllocationStubForClosure(const Function& func);
137 static RawCode* GetAllocationStubForStaticImplicitClosure(
138 const Function& func);
139 137
140 private: 138 private:
141 static const int kStubCodeSize = 4 * KB; 139 static const int kStubCodeSize = 4 * KB;
142 140
143 #define STUB_CODE_GENERATE(name) \ 141 #define STUB_CODE_GENERATE(name) \
144 static void Generate##name##Stub(Assembler* assembler); 142 static void Generate##name##Stub(Assembler* assembler);
145 VM_STUB_CODE_LIST(STUB_CODE_GENERATE); 143 VM_STUB_CODE_LIST(STUB_CODE_GENERATE);
146 STUB_CODE_LIST(STUB_CODE_GENERATE); 144 STUB_CODE_LIST(STUB_CODE_GENERATE);
147 #undef STUB_CODE_GENERATE 145 #undef STUB_CODE_GENERATE
148 146
(...skipping 11 matching lines...) Expand all
160 158
161 // Generate the stub and finalize the generated code into the stub 159 // Generate the stub and finalize the generated code into the stub
162 // code executable area. 160 // code executable area.
163 static RawCode* Generate(const char* name, 161 static RawCode* Generate(const char* name,
164 void (*GenerateStub)(Assembler* assembler)); 162 void (*GenerateStub)(Assembler* assembler));
165 163
166 static void GenerateAllocationStubForClass(Assembler* assembler, 164 static void GenerateAllocationStubForClass(Assembler* assembler,
167 const Class& cls); 165 const Class& cls);
168 static void GenerateAllocationStubForClosure(Assembler* assembler, 166 static void GenerateAllocationStubForClosure(Assembler* assembler,
169 const Function& func); 167 const Function& func);
170 static void GenerateAllocationStubForStaticImplicitClosure(
171 Assembler* assembler, const Function& func);
172 }; 168 };
173 169
174 } // namespace dart 170 } // namespace dart
175 171
176 #endif // VM_STUB_CODE_H_ 172 #endif // VM_STUB_CODE_H_
OLDNEW
« no previous file with comments | « runtime/vm/parser.cc ('k') | runtime/vm/stub_code.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698