+2014-12-16 Cary Coutant <ccoutant@google.com>
+
+ * mapfile.cc (Mapfile::print_input_section): Print uncompressed sizes.
+ (Mapfile::print_output_data): Use current_data_size() to avoid
+ assert for sections requiring postprocessing; if address is not valid,
+ print 0.
+ (Mapfile::print_output_section): Use current_data_size(); print note
+ that addresses and sizes are before compression.
+
2014-12-14 H.J. Lu <hongjiu.lu@intel.com>
* aarch64.cc (AArch64_relocate_functions::maybe_apply_stub):
}
char sizebuf[50];
+ section_size_type size;
+ if (!relobj->section_is_compressed(shndx, &size))
+ size = relobj->section_size(shndx);
snprintf(sizebuf, sizeof sizebuf, "0x%llx",
- static_cast<unsigned long long>(relobj->section_size(shndx)));
+ static_cast<unsigned long long>(size));
fprintf(this->map_file_, "0x%0*llx %10s %s\n",
parameters->target().get_size() / 4,
char sizebuf[50];
snprintf(sizebuf, sizeof sizebuf, "0x%llx",
- static_cast<unsigned long long>(od->data_size()));
+ static_cast<unsigned long long>(od->current_data_size()));
fprintf(this->map_file_, "0x%0*llx %10s\n",
parameters->target().get_size() / 4,
- static_cast<unsigned long long>(od->address()),
+ (od->is_address_valid()
+ ? static_cast<unsigned long long>(od->address())
+ : 0),
sizebuf);
}
char sizebuf[50];
snprintf(sizebuf, sizeof sizebuf, "0x%llx",
- static_cast<unsigned long long>(os->data_size()));
+ static_cast<unsigned long long>(os->current_data_size()));
fprintf(this->map_file_, "0x%0*llx %10s",
parameters->target().get_size() / 4,
parameters->target().get_size() / 4,
static_cast<unsigned long long>(os->load_address()));
+ if (os->requires_postprocessing())
+ fprintf(this->map_file_, " (before compression)");
+
putc('\n', this->map_file_);
}