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

Unified Diff: runtime/vm/disassembler_ia32.cc

Issue 182703003: Cleanup native, collected, and stub code handling in profiler (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/disassembler.cc ('k') | runtime/vm/disassembler_x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/disassembler_ia32.cc
diff --git a/runtime/vm/disassembler_ia32.cc b/runtime/vm/disassembler_ia32.cc
index 1a6877ff77f66a8489ae3f653c6f8eaa1b0e2d8d..eca4dd4aaddef30683ed07ef817f061c363e4968 100644
--- a/runtime/vm/disassembler_ia32.cc
+++ b/runtime/vm/disassembler_ia32.cc
@@ -485,7 +485,6 @@ static const char* ObjectToCStringNoGC(const Object& obj) {
void X86Decoder::PrintAddress(uword addr) {
- NoGCScope no_gc;
char addr_buffer[32];
OS::SNPrint(addr_buffer, sizeof(addr_buffer), "%#" Px "", addr);
Print(addr_buffer);
@@ -494,6 +493,7 @@ void X86Decoder::PrintAddress(uword addr) {
reinterpret_cast<RawObject*>(addr)->IsOldObject() &&
!Isolate::Current()->heap()->CodeContains(addr) &&
Disassembler::CanFindOldObject(addr)) {
+ NoGCScope no_gc;
const Object& obj = Object::Handle(reinterpret_cast<RawObject*>(addr));
if (obj.IsArray()) {
const Array& arr = Array::Cast(obj);
@@ -526,15 +526,11 @@ void X86Decoder::PrintAddress(uword addr) {
// Print only if jumping to entry point.
const Code& code = Code::Handle(Code::LookupCode(addr));
if (!code.IsNull() && (code.EntryPoint() == addr)) {
- const Function& function = Function::Handle(code.function());
- if (function.IsNull()) {
- Print(" [ stub ]");
- } else {
- const char* name_of_function = function.ToFullyQualifiedCString();
- Print(" [");
- Print(name_of_function);
- Print("]");
- }
+ const String& name = String::Handle(code.UserName());
+ const char* name_c = name.ToCString();
+ Print(" [");
+ Print(name_c);
+ Print("]");
}
}
}
« no previous file with comments | « runtime/vm/disassembler.cc ('k') | runtime/vm/disassembler_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698