Chromium Code Reviews

Unified Diff: src/objects.cc

Issue 1607433005: [interpreter] Implement exception handler table building. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebased. Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Index: src/objects.cc
diff --git a/src/objects.cc b/src/objects.cc
index 326b6f169ceb29b9c6364866bb21775fcbf73d3d..ac64ebdc97d2d0920235f3b7967f462cc9612cd5 100644
--- a/src/objects.cc
+++ b/src/objects.cc
@@ -15012,8 +15012,17 @@ void BytecodeArray::Disassemble(std::ostream& os) {
os << "\n";
}
- os << "Constant pool (size = " << constant_pool()->length() << ")\n";
- constant_pool()->Print();
+ if (constant_pool()->length() > 0) {
+ os << "Constant pool (size = " << constant_pool()->length() << ")\n";
+ constant_pool()->Print();
+ }
+
+#ifdef ENABLE_DISASSEMBLER
+ if (handler_table()->length() > 0) {
+ os << "Handler Table (size = " << handler_table()->Size() << ")\n";
+ HandlerTable::cast(handler_table())->HandlerTableRangePrint(os);
+ }
+#endif
}

Powered by Google App Engine