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

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

Issue 12703028: Adds Stop to MIPS. Starts on MIPS call patcher. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 7 years, 8 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
« runtime/vm/assembler_mips.cc ('K') | « runtime/vm/simulator_mips.cc ('k') | no next file » | 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 #include "vm/stub_code.h" 5 #include "vm/stub_code.h"
6 6
7 #include "platform/assert.h" 7 #include "platform/assert.h"
8 #include "vm/assembler.h" 8 #include "vm/assembler.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 mips code.
54 #if defined(TARGET_ARCH_IA32) || \
55 defined(TARGET_ARCH_X64) || \
56 defined(TARGET_ARCH_ARM)
57 // Generate all the stubs. 53 // Generate all the stubs.
58 Code& code = Code::Handle(); 54 Code& code = Code::Handle();
59 VM_STUB_CODE_LIST(STUB_CODE_GENERATE); 55 VM_STUB_CODE_LIST(STUB_CODE_GENERATE);
60 #endif
61 } 56 }
62 57
63 58
64 void StubCode::GenerateFor(Isolate* init) { 59 void StubCode::GenerateFor(Isolate* init) {
65 // TODO(regis): Re-enable this after we are able to generate mips code.
66 #if defined(TARGET_ARCH_IA32) || \
67 defined(TARGET_ARCH_X64) || \
68 defined(TARGET_ARCH_ARM)
69 // Generate all the stubs. 60 // Generate all the stubs.
70 Code& code = Code::Handle(); 61 Code& code = Code::Handle();
71 STUB_CODE_LIST(STUB_CODE_GENERATE); 62 STUB_CODE_LIST(STUB_CODE_GENERATE);
72 #endif
73 } 63 }
74 64
75 #undef STUB_CODE_GENERATE 65 #undef STUB_CODE_GENERATE
76 66
77 67
78 void StubCode::Init(Isolate* isolate) { 68 void StubCode::Init(Isolate* isolate) {
79 StubCode* stubs = new StubCode(); 69 StubCode* stubs = new StubCode();
80 isolate->set_stub_code(stubs); 70 isolate->set_stub_code(stubs);
81 stubs->GenerateFor(isolate); 71 stubs->GenerateFor(isolate);
82 } 72 }
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
167 VM_STUB_CODE_LIST(STUB_CODE_TESTER); 157 VM_STUB_CODE_LIST(STUB_CODE_TESTER);
168 Isolate* isolate = Isolate::Current(); 158 Isolate* isolate = Isolate::Current();
169 if ((isolate != NULL) && (isolate->stub_code() != NULL)) { 159 if ((isolate != NULL) && (isolate->stub_code() != NULL)) {
170 STUB_CODE_LIST(STUB_CODE_TESTER); 160 STUB_CODE_LIST(STUB_CODE_TESTER);
171 } 161 }
172 #undef STUB_CODE_TESTER 162 #undef STUB_CODE_TESTER
173 return NULL; 163 return NULL;
174 } 164 }
175 165
176 } // namespace dart 166 } // namespace dart
OLDNEW
« runtime/vm/assembler_mips.cc ('K') | « runtime/vm/simulator_mips.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698