diff options
| author | 2013-08-30 14:58:10 -0700 | |
|---|---|---|
| committer | 2013-08-30 14:58:10 -0700 | |
| commit | 1ccee24f15cb8aa9e13b816a8a0071924116780c (patch) | |
| tree | 90e0c9170007295e1689e129769b040da0d46924 | |
| parent | b971853c45f01a681b1547dd3770083056faec70 (diff) | |
| parent | 144a1397d09af54c0d098b7c2254e4d04bbddf9b (diff) | |
am 144a1397: Merge "Fix oatdump to take bitmap bytes into its accounting." into klp-dev
* commit '144a1397d09af54c0d098b7c2254e4d04bbddf9b':
Fix oatdump to take bitmap bytes into its accounting.
| -rw-r--r-- | oatdump/oatdump.cc | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/oatdump/oatdump.cc b/oatdump/oatdump.cc index d683c8effc..cf1b6af809 100644 --- a/oatdump/oatdump.cc +++ b/oatdump/oatdump.cc @@ -780,6 +780,8 @@ class ImageDumper { stats_.header_bytes = header_bytes; size_t alignment_bytes = RoundUp(header_bytes, kObjectAlignment) - header_bytes; stats_.alignment_bytes += alignment_bytes; + stats_.alignment_bytes += image_header_.GetImageBitmapOffset() - image_header_.GetImageSize(); + stats_.bitmap_bytes += image_header_.GetImageBitmapSize(); stats_.Dump(os); os << "\n"; @@ -1066,6 +1068,7 @@ class ImageDumper { size_t header_bytes; size_t object_bytes; + size_t bitmap_bytes; size_t alignment_bytes; size_t managed_code_bytes; @@ -1092,6 +1095,7 @@ class ImageDumper { file_bytes(0), header_bytes(0), object_bytes(0), + bitmap_bytes(0), alignment_bytes(0), managed_code_bytes(0), managed_code_bytes_ignoring_deduplication(0), @@ -1250,12 +1254,14 @@ class ImageDumper { std::ostream indent_os(&indent_filter); indent_os << StringPrintf("header_bytes = %8zd (%2.0f%% of art file bytes)\n" "object_bytes = %8zd (%2.0f%% of art file bytes)\n" + "bitmap_bytes = %8zd (%2.0f%% of art file bytes)\n" "alignment_bytes = %8zd (%2.0f%% of art file bytes)\n\n", header_bytes, PercentOfFileBytes(header_bytes), object_bytes, PercentOfFileBytes(object_bytes), + bitmap_bytes, PercentOfFileBytes(bitmap_bytes), alignment_bytes, PercentOfFileBytes(alignment_bytes)) << std::flush; - CHECK_EQ(file_bytes, header_bytes + object_bytes + alignment_bytes); + CHECK_EQ(file_bytes, bitmap_bytes + header_bytes + object_bytes + alignment_bytes); } os << "object_bytes breakdown:\n"; |