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

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

Issue 11365179: Fix Code::ToCString. (Closed) Base URL: https://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 | « no previous file | 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 7136 matching lines...) Expand 10 before | Expand all | Expand 10 after
7147 } 7147 }
7148 7148
7149 7149
7150 uword Code::GetDeoptAfterPcAtDeoptId(intptr_t deopt_id) const { 7150 uword Code::GetDeoptAfterPcAtDeoptId(intptr_t deopt_id) const {
7151 ASSERT(!is_optimized()); 7151 ASSERT(!is_optimized());
7152 return GetPcForDeoptId(deopt_id, PcDescriptors::kDeoptAfter); 7152 return GetPcForDeoptId(deopt_id, PcDescriptors::kDeoptAfter);
7153 } 7153 }
7154 7154
7155 7155
7156 const char* Code::ToCString() const { 7156 const char* Code::ToCString() const {
7157 const char* kFormat = "Code entry:0x%d"; 7157 const char* kFormat = "Code entry:%p";
7158 intptr_t len = OS::SNPrint(NULL, 0, kFormat, EntryPoint()) + 1; 7158 intptr_t len = OS::SNPrint(NULL, 0, kFormat, EntryPoint()) + 1;
7159 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len); 7159 char* chars = Isolate::Current()->current_zone()->Alloc<char>(len);
7160 OS::SNPrint(chars, len, kFormat, EntryPoint()); 7160 OS::SNPrint(chars, len, kFormat, EntryPoint());
7161 return chars; 7161 return chars;
7162 } 7162 }
7163 7163
7164 7164
7165 uword Code::GetPatchCodePc() const { 7165 uword Code::GetPatchCodePc() const {
7166 const PcDescriptors& descriptors = PcDescriptors::Handle(pc_descriptors()); 7166 const PcDescriptors& descriptors = PcDescriptors::Handle(pc_descriptors());
7167 return descriptors.GetPcForKind(PcDescriptors::kPatchCode); 7167 return descriptors.GetPcForKind(PcDescriptors::kPatchCode);
(...skipping 4807 matching lines...) Expand 10 before | Expand all | Expand 10 after
11975 } 11975 }
11976 return result.raw(); 11976 return result.raw();
11977 } 11977 }
11978 11978
11979 11979
11980 const char* WeakProperty::ToCString() const { 11980 const char* WeakProperty::ToCString() const {
11981 return "_WeakProperty"; 11981 return "_WeakProperty";
11982 } 11982 }
11983 11983
11984 } // namespace dart 11984 } // namespace dart
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698