Index: src/profile-generator.cc |
diff --git a/src/profile-generator.cc b/src/profile-generator.cc |
index 977c67c8cc8aaa71bc4597325613c6268bf9b14a..a4d9a828dd4ea7b5b05fada3f0d391c7b9002c0b 100644 |
--- a/src/profile-generator.cc |
+++ b/src/profile-generator.cc |
@@ -1319,11 +1319,9 @@ HeapEntry* HeapSnapshot::AddEntry(HeapObject* object, |
retainers_count); |
} else if (object->IsSharedFunctionInfo()) { |
SharedFunctionInfo* shared = SharedFunctionInfo::cast(object); |
- String* name = String::cast(shared->name())->length() > 0 ? |
- String::cast(shared->name()) : shared->inferred_name(); |
return AddEntry(object, |
HeapEntry::kCode, |
- collection_->GetFunctionName(name), |
+ collection_->GetName(String::cast(shared->name())), |
children_count, |
retainers_count); |
} else if (object->IsScript()) { |