[--trace-ic] Print map pointer value too
This might help with some further investigations when using the IC-Explorer. BUG= Review-Url: https://codereview.chromium.org/2046943003 Cr-Commit-Position: refs/heads/master@{#36821}
This commit is contained in:
parent
e8b10cec4c
commit
c8e286c918
@ -126,8 +126,12 @@ void IC::TraceIC(const char* type, Handle<Object> name, State old_state,
|
|||||||
casted_nexus<KeyedStoreICNexus>()->GetKeyedAccessStoreMode();
|
casted_nexus<KeyedStoreICNexus>()->GetKeyedAccessStoreMode();
|
||||||
modifier = GetTransitionMarkModifier(mode);
|
modifier = GetTransitionMarkModifier(mode);
|
||||||
}
|
}
|
||||||
PrintF(" (%c->%c%s) ", TransitionMarkFromState(old_state),
|
void* map = nullptr;
|
||||||
TransitionMarkFromState(new_state), modifier);
|
if (!receiver_map().is_null()) {
|
||||||
|
map = reinterpret_cast<void*>(*receiver_map());
|
||||||
|
}
|
||||||
|
PrintF(" (%c->%c%s) map=%p ", TransitionMarkFromState(old_state),
|
||||||
|
TransitionMarkFromState(new_state), modifier, map);
|
||||||
#ifdef OBJECT_PRINT
|
#ifdef OBJECT_PRINT
|
||||||
OFStream os(stdout);
|
OFStream os(stdout);
|
||||||
name->Print(os);
|
name->Print(os);
|
||||||
|
@ -51,6 +51,7 @@ code is governed by a BSD-style license that can be found in the LICENSE file.
|
|||||||
if (parts[1] === "patching") return;
|
if (parts[1] === "patching") return;
|
||||||
this.type = parts[0].substr(1);
|
this.type = parts[0].substr(1);
|
||||||
this.category = "Other";
|
this.category = "Other";
|
||||||
|
this.map = undefined;
|
||||||
if (this.type.indexOf("Store") !== -1) {
|
if (this.type.indexOf("Store") !== -1) {
|
||||||
this.category = "Store";
|
this.category = "Store";
|
||||||
} else if (this.type.indexOf("Load") !== -1) {
|
} else if (this.type.indexOf("Load") !== -1) {
|
||||||
@ -69,6 +70,13 @@ code is governed by a BSD-style license that can be found in the LICENSE file.
|
|||||||
var offset = this.parsePositionAndFile(parts, 2);
|
var offset = this.parsePositionAndFile(parts, 2);
|
||||||
if (offset == -1) return
|
if (offset == -1) return
|
||||||
this.state = parts[++offset];
|
this.state = parts[++offset];
|
||||||
|
this.map = parts[offset + 1];
|
||||||
|
if (this.map.startsWith("map=")) {
|
||||||
|
this.map = this.map.substring(4);
|
||||||
|
offset++;
|
||||||
|
} else {
|
||||||
|
this.map = undefined;
|
||||||
|
}
|
||||||
if (this.type !== "CompareIC") {
|
if (this.type !== "CompareIC") {
|
||||||
// if there is no address we have a smi key
|
// if there is no address we have a smi key
|
||||||
var address = parts[++offset];
|
var address = parts[++offset];
|
||||||
@ -135,7 +143,6 @@ code is governed by a BSD-style license that can be found in the LICENSE file.
|
|||||||
next = this.result.indexOf("\n", current);
|
next = this.result.indexOf("\n", current);
|
||||||
if (next === -1) break;
|
if (next === -1) break;
|
||||||
i++;
|
i++;
|
||||||
|
|
||||||
line = this.result.substring(current, next);
|
line = this.result.substring(current, next);
|
||||||
current = next + 1;
|
current = next + 1;
|
||||||
entry = new Entry(i, line);
|
entry = new Entry(i, line);
|
||||||
@ -152,7 +159,7 @@ code is governed by a BSD-style license that can be found in the LICENSE file.
|
|||||||
|
|
||||||
|
|
||||||
var properties = ['type', 'category', 'file', 'filePosition', 'state',
|
var properties = ['type', 'category', 'file', 'filePosition', 'state',
|
||||||
'key', 'isNative'
|
'key', 'isNative', 'map'
|
||||||
]
|
]
|
||||||
|
|
||||||
class Group {
|
class Group {
|
||||||
@ -209,6 +216,14 @@ code is governed by a BSD-style license that can be found in the LICENSE file.
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
function escapeHtml(unsafe) {
|
||||||
|
return unsafe.toString()
|
||||||
|
.replace(/&/g, "&")
|
||||||
|
.replace(/</g, "<")
|
||||||
|
.replace(/>/g, ">")
|
||||||
|
.replace(/"/g, """)
|
||||||
|
.replace(/'/g, "'");
|
||||||
|
}
|
||||||
|
|
||||||
function updateTable() {
|
function updateTable() {
|
||||||
var select = document.getElementById("group-key");
|
var select = document.getElementById("group-key");
|
||||||
@ -248,7 +263,7 @@ code is governed by a BSD-style license that can be found in the LICENSE file.
|
|||||||
td(tr, '<span onclick="toggleDetails(this)">details</a>', 'details');
|
td(tr, '<span onclick="toggleDetails(this)">details</a>', 'details');
|
||||||
td(tr, entry.percentage + "%", 'percentage');
|
td(tr, entry.percentage + "%", 'percentage');
|
||||||
td(tr, entry.count, 'count');
|
td(tr, entry.count, 'count');
|
||||||
td(tr, entry.key, 'key');
|
td(tr, escapeHtml(entry.key), 'key');
|
||||||
fragment.appendChild(tr);
|
fragment.appendChild(tr);
|
||||||
}
|
}
|
||||||
var omitted = entries.length - max;
|
var omitted = entries.length - max;
|
||||||
@ -282,7 +297,7 @@ code is governed by a BSD-style license that can be found in the LICENSE file.
|
|||||||
var group = entry.groups[key];
|
var group = entry.groups[key];
|
||||||
var div = document.createElement("div")
|
var div = document.createElement("div")
|
||||||
div.className = 'drilldown-group-title'
|
div.className = 'drilldown-group-title'
|
||||||
div.innerHTML = key + ' [top ' + max + ']';
|
div.innerHTML = key + ' [top ' + max + ' out of ' + group.length + ']';
|
||||||
var table = document.createElement("table");
|
var table = document.createElement("table");
|
||||||
display(group.slice(0, max), table, false)
|
display(group.slice(0, max), table, false)
|
||||||
div.appendChild(table);
|
div.appendChild(table);
|
||||||
|
Loading…
Reference in New Issue
Block a user