Add a comment to oatdump for 0 size symbols
The symbolizer inside oatdump generates 0 size symbols for the
trampoline symbols. Add a comment explaining why we emitting them with
0 size.
Change-Id: I16ed87554681ce57aafc26517a1e674647b5f9ac
diff --git a/oatdump/oatdump.cc b/oatdump/oatdump.cc
index 5d06919..af08fc4 100644
--- a/oatdump/oatdump.cc
+++ b/oatdump/oatdump.cc
@@ -170,6 +170,8 @@
if (code_offset != 0) {
uint32_t name_offset = builder_->GetStrTab()->Write(name);
uint64_t symbol_value = code_offset - oat_file_->GetOatHeader().GetExecutableOffset();
+ // Specifying 0 as the symbol size means that the symbol lasts until the next symbol or until
+ // the end of the section in case of the last symbol.
builder_->GetSymTab()->Add(name_offset, builder_->GetText(), symbol_value,
/* is_relative */ true, /* size */ 0, STB_GLOBAL, STT_FUNC);
}