[profiler] Add extra CHECK to track down crbug.com/665398

BUG=chromium:665398

Review-Url: https://codereview.chromium.org/2556833003
Cr-Commit-Position: refs/heads/master@{#41545}
This commit is contained in:
alph 2016-12-07 02:23:50 -08:00 committed by Commit bot
parent 331b0df6e4
commit dfc0bb63a1
2 changed files with 12 additions and 1 deletions

View File

@ -27,7 +27,13 @@ CodeEntry::CodeEntry(CodeEventListener::LogEventsAndTags tag, const char* name,
deopt_reason_(kNoDeoptReason),
deopt_id_(kNoDeoptimizationId),
line_info_(line_info),
instruction_start_(instruction_start) {}
instruction_start_(instruction_start) {
// TODO(alph): Extra check to help catch crbug.com/665398
// Remove before 5.8 branch
#if V8_MAJOR_VERSION == 5 && V8_MINOR_VERSION == 7
CHECK(name);
#endif
}
ProfileNode::ProfileNode(ProfileTree* tree, CodeEntry* entry,
ProfileNode* parent)

View File

@ -424,6 +424,11 @@ namespace {
void BuildNodeValue(const ProfileNode* node, TracedValue* value) {
const CodeEntry* entry = node->entry();
value->BeginDictionary("callFrame");
// TODO(alph): Extra check to help catch crbug.com/665398
// Remove before 5.8 branch
#if V8_MAJOR_VERSION == 5 && V8_MINOR_VERSION == 7
CHECK(entry->name());
#endif
value->SetString("functionName", entry->name());
if (*entry->resource_name()) {
value->SetString("url", entry->resource_name());