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

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

Issue 8818001: Add 64-bit stubs to call into the runtime and to call native functions. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: '' Created 9 years 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/stack_frame_x64.cc ('k') | runtime/vm/stub_code_arm.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 #include "vm/stub_code.h" 5 #include "vm/stub_code.h"
6 6
7 #include "vm/assembler.h" 7 #include "vm/assembler.h"
8 #include "vm/assert.h" 8 #include "vm/assert.h"
9 #include "vm/disassembler.h" 9 #include "vm/disassembler.h"
10 #include "vm/flags.h" 10 #include "vm/flags.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 #undef STUB_CODE_DELETER 43 #undef STUB_CODE_DELETER
44 } 44 }
45 45
46 46
47 #define STUB_CODE_GENERATE(name) \ 47 #define STUB_CODE_GENERATE(name) \
48 code ^= Generate("_stub_"#name, StubCode::Generate##name##Stub); \ 48 code ^= Generate("_stub_"#name, StubCode::Generate##name##Stub); \
49 name##_entry_ = new StubEntry("_stub_"#name, code); 49 name##_entry_ = new StubEntry("_stub_"#name, code);
50 50
51 51
52 void StubCode::InitOnce() { 52 void StubCode::InitOnce() {
53 // TODO(regis): Re-enable this after we are able to generate x64 and arm code. 53 // TODO(regis): Re-enable this after we are able to generate arm code.
54 #if defined(TARGET_ARCH_IA32) 54 #if defined(TARGET_ARCH_IA32) || defined(TARGET_ARCH_X64)
55 // Generate all the stubs. 55 // Generate all the stubs.
56 Code& code = Code::Handle(); 56 Code& code = Code::Handle();
57 VM_STUB_CODE_LIST(STUB_CODE_GENERATE); 57 VM_STUB_CODE_LIST(STUB_CODE_GENERATE);
58 #endif 58 #endif
59 } 59 }
60 60
61 61
62 void StubCode::GenerateFor(Isolate* init) { 62 void StubCode::GenerateFor(Isolate* init) {
63 // TODO(regis): Re-enable this after we are able to generate x64 and arm code. 63 // TODO(regis): Re-enable this after we are able to generate arm code.
64 #if defined(TARGET_ARCH_IA32) 64 #if defined(TARGET_ARCH_IA32) || defined(TARGET_ARCH_X64)
65 // Generate all the stubs. 65 // Generate all the stubs.
66 Code& code = Code::Handle(); 66 Code& code = Code::Handle();
67 STUB_CODE_LIST(STUB_CODE_GENERATE); 67 STUB_CODE_LIST(STUB_CODE_GENERATE);
68 #endif 68 #endif
69 } 69 }
70 70
71 #undef STUB_CODE_GENERATE 71 #undef STUB_CODE_GENERATE
72 72
73 73
74 void StubCode::Init(Isolate* isolate) { 74 void StubCode::Init(Isolate* isolate) {
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 VM_STUB_CODE_LIST(STUB_CODE_TESTER); 172 VM_STUB_CODE_LIST(STUB_CODE_TESTER);
173 Isolate* isolate = Isolate::Current(); 173 Isolate* isolate = Isolate::Current();
174 if ((isolate != NULL) && (isolate->stub_code() != NULL)) { 174 if ((isolate != NULL) && (isolate->stub_code() != NULL)) {
175 STUB_CODE_LIST(STUB_CODE_TESTER); 175 STUB_CODE_LIST(STUB_CODE_TESTER);
176 } 176 }
177 #undef STUB_CODE_TESTER 177 #undef STUB_CODE_TESTER
178 return NULL; 178 return NULL;
179 } 179 }
180 180
181 } // namespace dart 181 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/stack_frame_x64.cc ('k') | runtime/vm/stub_code_arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698