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

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

Issue 11411072: Simplify CodePatcher::GetStaticCallAt. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 1 month 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/native_entry_test.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/object.h" 5 #include "vm/object.h"
6 6
7 #include "include/dart_api.h" 7 #include "include/dart_api.h"
8 #include "platform/assert.h" 8 #include "platform/assert.h"
9 #include "vm/assembler.h" 9 #include "vm/assembler.h"
10 #include "vm/bigint_operations.h" 10 #include "vm/bigint_operations.h"
(...skipping 7296 matching lines...) Expand 10 before | Expand all | Expand 10 after
7307 } 7307 }
7308 7308
7309 7309
7310 void Code::ExtractUncalledStaticCallDeoptIds( 7310 void Code::ExtractUncalledStaticCallDeoptIds(
7311 GrowableArray<intptr_t>* deopt_ids) const { 7311 GrowableArray<intptr_t>* deopt_ids) const {
7312 ASSERT(!IsNull() && !is_optimized()); 7312 ASSERT(!IsNull() && !is_optimized());
7313 ASSERT(deopt_ids != NULL); 7313 ASSERT(deopt_ids != NULL);
7314 deopt_ids->Clear(); 7314 deopt_ids->Clear();
7315 const PcDescriptors& descriptors = 7315 const PcDescriptors& descriptors =
7316 PcDescriptors::Handle(this->pc_descriptors()); 7316 PcDescriptors::Handle(this->pc_descriptors());
7317 Function& function = Function::Handle();
7318 for (intptr_t i = 0; i < descriptors.Length(); i++) { 7317 for (intptr_t i = 0; i < descriptors.Length(); i++) {
7319 if (descriptors.DescriptorKind(i) == PcDescriptors::kFuncCall) { 7318 if (descriptors.DescriptorKind(i) == PcDescriptors::kFuncCall) {
7320 // Static call. 7319 // Static call.
7321 uword target_addr; 7320 const uword target_addr =
7322 CodePatcher::GetStaticCallAt(descriptors.PC(i), &function, &target_addr); 7321 CodePatcher::GetStaticCallTargetAt(descriptors.PC(i));
7323 if (target_addr == StubCode::CallStaticFunctionEntryPoint()) { 7322 if (target_addr == StubCode::CallStaticFunctionEntryPoint()) {
7324 deopt_ids->Add(descriptors.DeoptId(i)); 7323 deopt_ids->Add(descriptors.DeoptId(i));
7325 } 7324 }
7326 } 7325 }
7327 } 7326 }
7328 } 7327 }
7329 7328
7330 7329
7331 RawStackmap* Code::GetStackmap(uword pc, Array* maps, Stackmap* map) const { 7330 RawStackmap* Code::GetStackmap(uword pc, Array* maps, Stackmap* map) const {
7332 // This code is used during iterating frames during a GC and hence it 7331 // This code is used during iterating frames during a GC and hence it
(...skipping 4791 matching lines...) Expand 10 before | Expand all | Expand 10 after
12124 } 12123 }
12125 return result.raw(); 12124 return result.raw();
12126 } 12125 }
12127 12126
12128 12127
12129 const char* WeakProperty::ToCString() const { 12128 const char* WeakProperty::ToCString() const {
12130 return "_WeakProperty"; 12129 return "_WeakProperty";
12131 } 12130 }
12132 12131
12133 } // namespace dart 12132 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/native_entry_test.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698