Show builtin name when printing Code objects.

BUG=

Review URL: https://codereview.chromium.org/1419143003

Cr-Commit-Position: refs/heads/master@{#31500}
This commit is contained in:
cbruni 2015-10-23 02:19:02 -07:00 committed by Commit bot
parent 11cd1f77ae
commit 1c50fc1162

View File

@ -13314,6 +13314,11 @@ void Code::Disassemble(const char* name, std::ostream& os) { // NOLINT
} }
if ((name != NULL) && (name[0] != '\0')) { if ((name != NULL) && (name[0] != '\0')) {
os << "name = " << name << "\n"; os << "name = " << name << "\n";
} else if (kind() == BUILTIN) {
name = GetIsolate()->builtins()->Lookup(instruction_start());
if (name != NULL) {
os << "name = " << name << "\n";
}
} }
if (kind() == OPTIMIZED_FUNCTION) { if (kind() == OPTIMIZED_FUNCTION) {
os << "stack_slots = " << stack_slots() << "\n"; os << "stack_slots = " << stack_slots() << "\n";