blob: 3856f34a7f4d723d6c04646c137ccd2834bec604 [file] [log] [blame]
Brian Carlstrom78128a62011-09-15 17:21:19 -07001// Copyright 2011 Google Inc. All Rights Reserved.
2
3#include <stdio.h>
4#include <stdlib.h>
5
Brian Carlstrom27ec9612011-09-19 20:20:38 -07006#include <fstream>
7#include <iostream>
Brian Carlstrom78128a62011-09-15 17:21:19 -07008#include <string>
9#include <vector>
10
11#include "class_linker.h"
Brian Carlstrom916e74e2011-09-23 11:42:01 -070012#include "file.h"
Brian Carlstrom78128a62011-09-15 17:21:19 -070013#include "image.h"
Brian Carlstrom916e74e2011-09-23 11:42:01 -070014#include "os.h"
Brian Carlstrom78128a62011-09-15 17:21:19 -070015#include "runtime.h"
16#include "space.h"
17#include "stringpiece.h"
Brian Carlstrom916e74e2011-09-23 11:42:01 -070018#include "unordered_map.h"
Brian Carlstrom78128a62011-09-15 17:21:19 -070019
20namespace art {
21
22static void usage() {
23 fprintf(stderr,
24 "Usage: oatdump [options] ...\n"
Brian Carlstrom58ae9412011-10-04 00:56:06 -070025 " Example: oatdump --image=$ANDROID_PRODUCT_OUT/system/framework/boot.art --host-prefix=$ANDROID_PRODUCT_OUT\n"
26 " Example: adb shell oatdump --image=/system/framework/boot.art\n"
Brian Carlstrom78128a62011-09-15 17:21:19 -070027 "\n");
28 fprintf(stderr,
Brian Carlstrome24fa612011-09-29 00:53:55 -070029 " --image=<file.art>: specifies the required input image filename.\n"
30 " Example: --image=/system/framework/boot.art\n"
31 "\n");
Brian Carlstrom78128a62011-09-15 17:21:19 -070032 fprintf(stderr,
Brian Carlstrome24fa612011-09-29 00:53:55 -070033 " --boot-image=<file.art>: provide the image file for the boot class path.\n"
34 " Example: --boot-image=/system/framework/boot.art\n"
Brian Carlstrom78128a62011-09-15 17:21:19 -070035 "\n");
Brian Carlstrome24fa612011-09-29 00:53:55 -070036 fprintf(stderr,
Brian Carlstrom58ae9412011-10-04 00:56:06 -070037 " --host-prefix may be used to translate host paths to target paths during\n"
38 " cross compilation.\n"
39 " Example: --host-prefix=out/target/product/crespo\n"
Brian Carlstrom78128a62011-09-15 17:21:19 -070040 "\n");
Brian Carlstrom27ec9612011-09-19 20:20:38 -070041 fprintf(stderr,
42 " --output=<file> may be used to send the output to a file.\n"
43 " Example: --output=/tmp/oatdump.txt\n"
44 "\n");
Brian Carlstrom78128a62011-09-15 17:21:19 -070045 exit(EXIT_FAILURE);
46}
47
Ian Rogersff1ed472011-09-20 13:46:24 -070048const char* image_roots_descriptions_[] = {
Brian Carlstrom78128a62011-09-15 17:21:19 -070049 "kJniStubArray",
Brian Carlstrome24fa612011-09-29 00:53:55 -070050 "kAbstractMethodErrorStubArray",
51 "kCalleeSaveMethod",
52 "kOatLocation",
Brian Carlstrom58ae9412011-10-04 00:56:06 -070053 "kDexCaches",
Brian Carlstrom34f426c2011-10-04 12:58:02 -070054 "kClassRoots",
Brian Carlstrom78128a62011-09-15 17:21:19 -070055};
56
Brian Carlstrom27ec9612011-09-19 20:20:38 -070057class OatDump {
Brian Carlstrom78128a62011-09-15 17:21:19 -070058
Brian Carlstrom27ec9612011-09-19 20:20:38 -070059 public:
Brian Carlstrom916e74e2011-09-23 11:42:01 -070060 static void Dump(const std::string& image_filename,
61 std::ostream& os,
62 Space& image_space,
63 const ImageHeader& image_header) {
Brian Carlstrom27ec9612011-09-19 20:20:38 -070064 os << "MAGIC:\n";
65 os << image_header.GetMagic() << "\n\n";
66
Brian Carlstrome24fa612011-09-29 00:53:55 -070067 os << "IMAGE BASE:\n";
68 os << reinterpret_cast<void*>(image_header.GetImageBaseAddr()) << "\n\n";
69
70 os << "OAT BASE:\n";
71 os << reinterpret_cast<void*>(image_header.GetOatBaseAddr()) << "\n\n";
Brian Carlstrom916e74e2011-09-23 11:42:01 -070072
Brian Carlstrom27ec9612011-09-19 20:20:38 -070073 os << "ROOTS:\n";
Elliott Hughes418d20f2011-09-22 14:00:39 -070074 CHECK_EQ(arraysize(image_roots_descriptions_), size_t(ImageHeader::kImageRootsMax));
Brian Carlstrom27ec9612011-09-19 20:20:38 -070075 for (int i = 0; i < ImageHeader::kImageRootsMax; i++) {
76 ImageHeader::ImageRoot image_root = static_cast<ImageHeader::ImageRoot>(i);
Brian Carlstrom34f426c2011-10-04 12:58:02 -070077 const char* image_root_description = image_roots_descriptions_[i];
78 Object* image_root_object = image_header.GetImageRoot(image_root);
79 os << StringPrintf("%s: %p\n", image_root_description, image_root_object);
80 if (image_root_object->IsObjectArray()) {
81 // TODO: replace down_cast with AsObjectArray (g++ currently has a problem with this)
82 ObjectArray<Object>* image_root_object_array
83 = down_cast<ObjectArray<Object>*>(image_root_object);
84 // = image_root_object->AsObjectArray<Object>();
85 for (int i = 0; i < image_root_object_array->GetLength(); i++) {
86 os << StringPrintf("\t%d: %p\n", i, image_root_object_array->Get(i));
87 }
88 }
Brian Carlstrom27ec9612011-09-19 20:20:38 -070089 }
90 os << "\n";
91
92 os << "OBJECTS:\n" << std::flush;
93 OatDump state(image_space, os);
94 HeapBitmap* heap_bitmap = Heap::GetLiveBits();
95 DCHECK(heap_bitmap != NULL);
96 heap_bitmap->Walk(OatDump::Callback, &state);
Brian Carlstrom916e74e2011-09-23 11:42:01 -070097 os << "\n";
98
99 os << "STATS:\n" << std::flush;
100 UniquePtr<File> file(OS::OpenFile(image_filename.c_str(), false));
101 state.stats_.file_bytes = file->Length();
Brian Carlstrome24fa612011-09-29 00:53:55 -0700102 size_t header_bytes = sizeof(ImageHeader);
103 state.stats_.header_bytes = header_bytes;
104 size_t alignment_bytes = RoundUp(header_bytes, kObjectAlignment) - header_bytes;
105 state.stats_.alignment_bytes += alignment_bytes;
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700106 state.stats_.Dump(os);
107
108 os << std::flush;
Brian Carlstrom78128a62011-09-15 17:21:19 -0700109 }
110
Brian Carlstrom27ec9612011-09-19 20:20:38 -0700111 private:
112
Elliott Hughesd1bb4f62011-09-23 14:09:45 -0700113 OatDump(const Space& dump_space, std::ostream& os) : dump_space_(dump_space), os_(os) {
114 }
115
116 ~OatDump() {
117 }
Brian Carlstrom27ec9612011-09-19 20:20:38 -0700118
Brian Carlstrom78128a62011-09-15 17:21:19 -0700119 static void Callback(Object* obj, void* arg) {
120 DCHECK(obj != NULL);
121 DCHECK(arg != NULL);
122 OatDump* state = reinterpret_cast<OatDump*>(arg);
123 if (!state->InDumpSpace(obj)) {
124 return;
125 }
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700126
127 size_t object_bytes = obj->SizeOf();
128 size_t alignment_bytes = RoundUp(object_bytes, kObjectAlignment) - object_bytes;
129 state->stats_.object_bytes += object_bytes;
130 state->stats_.alignment_bytes += alignment_bytes;
131
Brian Carlstrom78128a62011-09-15 17:21:19 -0700132 std::string summary;
133 StringAppendF(&summary, "%p: ", obj);
134 if (obj->IsClass()) {
135 Class* klass = obj->AsClass();
136 StringAppendF(&summary, "CLASS %s", klass->GetDescriptor()->ToModifiedUtf8().c_str());
Brian Carlstrome10b6972011-09-26 13:49:03 -0700137 std::stringstream ss;
138 ss << " (" << klass->GetStatus() << ")";
139 summary += ss.str();
Brian Carlstrom78128a62011-09-15 17:21:19 -0700140 } else if (obj->IsMethod()) {
141 Method* method = obj->AsMethod();
142 StringAppendF(&summary, "METHOD %s", PrettyMethod(method).c_str());
143 } else if (obj->IsField()) {
144 Field* field = obj->AsField();
145 Class* type = field->GetType();
146 std::string type_string;
147 type_string += (type == NULL) ? "<UNKNOWN>" : type->GetDescriptor()->ToModifiedUtf8();
148 StringAppendF(&summary, "FIELD %s", PrettyField(field).c_str());
149 } else if (obj->IsArrayInstance()) {
150 StringAppendF(&summary, "ARRAY %d", obj->AsArray()->GetLength());
151 } else if (obj->IsString()) {
152 StringAppendF(&summary, "STRING %s", obj->AsString()->ToModifiedUtf8().c_str());
153 } else {
154 StringAppendF(&summary, "OBJECT");
155 }
156 StringAppendF(&summary, "\n");
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700157 std::string descriptor = obj->GetClass()->GetDescriptor()->ToModifiedUtf8();
158 StringAppendF(&summary, "\tclass %p: %s\n", obj->GetClass(), descriptor.c_str());
159 state->stats_.descriptor_to_bytes[descriptor] += object_bytes;
160 state->stats_.descriptor_to_count[descriptor] += 1;
161 // StringAppendF(&summary, "\tsize %d (alignment padding %d)\n",
162 // object_bytes, RoundUp(object_bytes, kObjectAlignment) - object_bytes);
Brian Carlstrom78128a62011-09-15 17:21:19 -0700163 if (obj->IsMethod()) {
164 Method* method = obj->AsMethod();
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700165 if (!method->IsPhony()) {
Brian Carlstrome10b6972011-09-26 13:49:03 -0700166 const ByteArray* code = method->GetCodeArray();
167 const int8_t* code_base = NULL;
168 const int8_t* code_limit = NULL;
169 if (code != NULL) {
170 size_t code_bytes = code->GetLength();
171 code_base = code->GetData();
172 code_limit = code_base + code_bytes;
173 if (method->IsNative()) {
174 state->stats_.managed_to_native_code_bytes += code_bytes;
175 } else {
176 state->stats_.managed_code_bytes += code_bytes;
177 }
Brian Carlstrome24fa612011-09-29 00:53:55 -0700178 } else {
179 code_base = reinterpret_cast<const int8_t*>(method->GetCode());
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700180 }
Brian Carlstrome10b6972011-09-26 13:49:03 -0700181 StringAppendF(&summary, "\tCODE %p-%p\n", code_base, code_limit);
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700182
Ian Rogersff1ed472011-09-20 13:46:24 -0700183 const ByteArray* invoke = method->GetInvokeStubArray();
Brian Carlstrome10b6972011-09-26 13:49:03 -0700184 const int8_t* invoke_base = NULL;
185 const int8_t* invoke_limit = NULL;
186 if (invoke != NULL) {
187 size_t native_to_managed_code_bytes = invoke->GetLength();
188 invoke_base = invoke->GetData();
189 invoke_limit = invoke_base + native_to_managed_code_bytes;
190 state->stats_.native_to_managed_code_bytes += native_to_managed_code_bytes;
191 StringAppendF(&summary, "\tJNI STUB %p-%p\n", invoke_base, invoke_limit);
192 }
Ian Rogersff1ed472011-09-20 13:46:24 -0700193 }
Brian Carlstrom78128a62011-09-15 17:21:19 -0700194 if (method->IsNative()) {
195 if (method->IsRegistered()) {
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700196 StringAppendF(&summary, "\tNATIVE REGISTERED %p\n", method->GetNativeMethod());
Brian Carlstrom78128a62011-09-15 17:21:19 -0700197 } else {
198 StringAppendF(&summary, "\tNATIVE UNREGISTERED\n");
199 }
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700200 DCHECK(method->GetRegisterMapHeader() == NULL);
201 DCHECK(method->GetRegisterMapData() == NULL);
202 DCHECK(method->GetMappingTable() == NULL);
203 } else if (method->IsAbstract()) {
204 StringAppendF(&summary, "\tABSTRACT\n");
205 DCHECK(method->GetRegisterMapHeader() == NULL);
206 DCHECK(method->GetRegisterMapData() == NULL);
207 DCHECK(method->GetMappingTable() == NULL);
208 } else if (method->IsPhony()) {
209 StringAppendF(&summary, "\tPHONY\n");
210 DCHECK(method->GetRegisterMapHeader() == NULL);
211 DCHECK(method->GetRegisterMapData() == NULL);
212 DCHECK(method->GetMappingTable() == NULL);
213 } else {
214 size_t register_map_bytes = (method->GetRegisterMapHeader()->GetLength() +
215 method->GetRegisterMapData()->GetLength());
216 state->stats_.register_map_bytes += register_map_bytes;
217
Brian Carlstrome10b6972011-09-26 13:49:03 -0700218 if (method->GetMappingTable() != NULL) {
219 size_t pc_mapping_table_bytes = method->GetMappingTable()->GetLength();
220 state->stats_.pc_mapping_table_bytes += pc_mapping_table_bytes;
221 }
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700222
223 ClassLinker* class_linker = Runtime::Current()->GetClassLinker();
224 class DexCache* dex_cache = method->GetDeclaringClass()->GetDexCache();
225 const DexFile& dex_file = class_linker->FindDexFile(dex_cache);
226 const DexFile::CodeItem* code_item = dex_file.GetCodeItem(method->GetCodeItemOffset());
227 size_t dex_instruction_bytes = code_item->insns_size_ * 2;
228 state->stats_.dex_instruction_bytes += dex_instruction_bytes;
Brian Carlstrom78128a62011-09-15 17:21:19 -0700229 }
230 }
Brian Carlstrom27ec9612011-09-19 20:20:38 -0700231 state->os_ << summary << std::flush;
Brian Carlstrom78128a62011-09-15 17:21:19 -0700232 }
Brian Carlstrom27ec9612011-09-19 20:20:38 -0700233
234 bool InDumpSpace(const Object* object) {
235 const byte* o = reinterpret_cast<const byte*>(object);
236 return (o >= dump_space_.GetBase() && o < dump_space_.GetLimit());
237 }
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700238
239 public:
240 struct Stats {
241 size_t file_bytes;
242
243 size_t header_bytes;
244 size_t object_bytes;
245 size_t alignment_bytes;
246
247 size_t managed_code_bytes;
248 size_t managed_to_native_code_bytes;
249 size_t native_to_managed_code_bytes;
250
251 size_t register_map_bytes;
252 size_t pc_mapping_table_bytes;
253
254 size_t dex_instruction_bytes;
255
256 Stats()
257 : file_bytes(0),
258 header_bytes(0),
259 object_bytes(0),
260 alignment_bytes(0),
261 managed_code_bytes(0),
262 managed_to_native_code_bytes(0),
263 native_to_managed_code_bytes(0),
264 register_map_bytes(0),
265 pc_mapping_table_bytes(0),
266 dex_instruction_bytes(0) {}
267
268 typedef std::tr1::unordered_map<std::string,size_t> TableBytes;
269 TableBytes descriptor_to_bytes;
270
271 typedef std::tr1::unordered_map<std::string,size_t> TableCount;
272 TableCount descriptor_to_count;
273
274 double PercentOfFileBytes(size_t size) {
275 return (static_cast<double>(size) / static_cast<double>(file_bytes)) * 100;
276 }
277
278 double PercentOfObjectBytes(size_t size) {
279 return (static_cast<double>(size) / static_cast<double>(object_bytes)) * 100;
280 }
281
282 void Dump(std::ostream& os) {
283 os << StringPrintf("\tfile_bytes = %d\n", file_bytes);
284 os << "\n";
285
286 os << "\tfile_bytes = header_bytes + object_bytes + alignment_bytes\n";
287 os << StringPrintf("\theader_bytes = %10d (%2.0f%% of file_bytes)\n",
288 header_bytes, PercentOfFileBytes(header_bytes));
289 os << StringPrintf("\tobject_bytes = %10d (%2.0f%% of file_bytes)\n",
290 object_bytes, PercentOfFileBytes(object_bytes));
291 os << StringPrintf("\talignment_bytes = %10d (%2.0f%% of file_bytes)\n",
292 alignment_bytes, PercentOfFileBytes(alignment_bytes));
293 os << "\n";
294 os << std::flush;
295 CHECK_EQ(file_bytes, header_bytes + object_bytes + alignment_bytes);
296
297 os << "\tobject_bytes = sum of descriptor_to_bytes values below:\n";
298 size_t object_bytes_total = 0;
299 typedef TableBytes::const_iterator It; // TODO: C++0x auto
300 for (It it = descriptor_to_bytes.begin(), end = descriptor_to_bytes.end(); it != end; ++it) {
301 const std::string& descriptor = it->first;
302 size_t bytes = it->second;
303 size_t count = descriptor_to_count[descriptor];
304 double average = static_cast<double>(bytes) / static_cast<double>(count);
305 double percent = PercentOfObjectBytes(bytes);
Brian Carlstromf153fe12011-09-27 16:27:12 -0700306 os << StringPrintf("\t%32s %8d bytes %6d instances "
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700307 "(%3.0f bytes/instance) %2.0f%% of object_bytes\n",
308 descriptor.c_str(), bytes, count,
309 average, percent);
310
311 object_bytes_total += bytes;
312 }
313 os << "\n";
314 os << std::flush;
315 CHECK_EQ(object_bytes, object_bytes_total);
316
317 os << StringPrintf("\tmanaged_code_bytes = %8d (%2.0f%% of object_bytes)\n",
318 managed_code_bytes, PercentOfObjectBytes(managed_code_bytes));
319 os << StringPrintf("\tmanaged_to_native_code_bytes = %8d (%2.0f%% of object_bytes)\n",
320 managed_to_native_code_bytes,
321 PercentOfObjectBytes(managed_to_native_code_bytes));
322 os << StringPrintf("\tnative_to_managed_code_bytes = %8d (%2.0f%% of object_bytes)\n",
323 native_to_managed_code_bytes,
324 PercentOfObjectBytes(native_to_managed_code_bytes));
325 os << "\n";
326 os << std::flush;
327
328 os << StringPrintf("\tregister_map_bytes = %7d (%2.0f%% of object_bytes)\n",
329 register_map_bytes, PercentOfObjectBytes(register_map_bytes));
330 os << StringPrintf("\tpc_mapping_table_bytes = %7d (%2.0f%% of object_bytes)\n",
331 pc_mapping_table_bytes, PercentOfObjectBytes(pc_mapping_table_bytes));
332 os << "\n";
333 os << std::flush;
334
335 os << StringPrintf("\tdex_instruction_bytes = %d\n", dex_instruction_bytes);
336 os << StringPrintf("\tmanaged_code_bytes expansion = %.2f\n",
337 static_cast<double>(managed_code_bytes)
338 / static_cast<double>(dex_instruction_bytes));
339 os << "\n";
340 os << std::flush;
341
342 }
343 } stats_;
344
345 private:
Brian Carlstrom27ec9612011-09-19 20:20:38 -0700346 const Space& dump_space_;
347 std::ostream& os_;
Elliott Hughesd1bb4f62011-09-23 14:09:45 -0700348
349 DISALLOW_COPY_AND_ASSIGN(OatDump);
Brian Carlstrom78128a62011-09-15 17:21:19 -0700350};
351
352int oatdump(int argc, char** argv) {
353 // Skip over argv[0].
354 argv++;
355 argc--;
356
357 if (argc == 0) {
358 fprintf(stderr, "no arguments specified\n");
359 usage();
360 }
361
Brian Carlstrom78128a62011-09-15 17:21:19 -0700362 const char* image_filename = NULL;
363 const char* boot_image_filename = NULL;
Brian Carlstrom58ae9412011-10-04 00:56:06 -0700364 std::string host_prefix;
Brian Carlstrom27ec9612011-09-19 20:20:38 -0700365 std::ostream* os = &std::cout;
366 UniquePtr<std::ofstream> out;
Brian Carlstrom78128a62011-09-15 17:21:19 -0700367
368 for (int i = 0; i < argc; i++) {
369 const StringPiece option(argv[i]);
Brian Carlstrom58ae9412011-10-04 00:56:06 -0700370 if (option.starts_with("--image=")) {
Brian Carlstrom78128a62011-09-15 17:21:19 -0700371 image_filename = option.substr(strlen("--image=")).data();
Brian Carlstrome24fa612011-09-29 00:53:55 -0700372 } else if (option.starts_with("--boot-image=")) {
373 boot_image_filename = option.substr(strlen("--boot-image=")).data();
Brian Carlstrom58ae9412011-10-04 00:56:06 -0700374 } else if (option.starts_with("--host-prefix=")) {
375 host_prefix = option.substr(strlen("--host-prefix=")).data();
Brian Carlstrom27ec9612011-09-19 20:20:38 -0700376 } else if (option.starts_with("--output=")) {
377 const char* filename = option.substr(strlen("--output=")).data();
378 out.reset(new std::ofstream(filename));
379 if (!out->good()) {
380 fprintf(stderr, "failed to open output filename %s\n", filename);
381 usage();
382 }
383 os = out.get();
Brian Carlstrom78128a62011-09-15 17:21:19 -0700384 } else {
385 fprintf(stderr, "unknown argument %s\n", option.data());
386 usage();
387 }
388 }
389
390 if (image_filename == NULL) {
391 fprintf(stderr, "--image file name not specified\n");
392 return EXIT_FAILURE;
393 }
394
Brian Carlstrom78128a62011-09-15 17:21:19 -0700395 Runtime::Options options;
396 std::string image_option;
Brian Carlstrome24fa612011-09-29 00:53:55 -0700397 std::string oat_option;
Brian Carlstrom78128a62011-09-15 17:21:19 -0700398 std::string boot_image_option;
Brian Carlstrome24fa612011-09-29 00:53:55 -0700399 std::string boot_oat_option;
Brian Carlstrom58ae9412011-10-04 00:56:06 -0700400 if (boot_image_filename != NULL) {
401 boot_image_option += "-Ximage:";
402 boot_image_option += boot_image_filename;
403 options.push_back(std::make_pair(boot_image_option.c_str(), reinterpret_cast<void*>(NULL)));
Brian Carlstrom78128a62011-09-15 17:21:19 -0700404 }
Brian Carlstrom58ae9412011-10-04 00:56:06 -0700405 image_option += "-Ximage:";
406 image_option += image_filename;
407 options.push_back(std::make_pair(image_option.c_str(), reinterpret_cast<void*>(NULL)));
408
409 if (!host_prefix.empty()) {
410 options.push_back(std::make_pair("host-prefix", host_prefix.c_str()));
411 }
Brian Carlstrom78128a62011-09-15 17:21:19 -0700412
413 UniquePtr<Runtime> runtime(Runtime::Create(options, false));
414 if (runtime.get() == NULL) {
415 fprintf(stderr, "could not create runtime\n");
416 return EXIT_FAILURE;
417 }
Brian Carlstrom78128a62011-09-15 17:21:19 -0700418
419 Space* image_space = Heap::GetSpaces()[Heap::GetSpaces().size()-2];
420 CHECK(image_space != NULL);
421 const ImageHeader& image_header = image_space->GetImageHeader();
422 if (!image_header.IsValid()) {
423 fprintf(stderr, "invalid image header %s\n", image_filename);
424 return EXIT_FAILURE;
425 }
Brian Carlstrom916e74e2011-09-23 11:42:01 -0700426 OatDump::Dump(image_filename, *os, *image_space, image_header);
Brian Carlstrom78128a62011-09-15 17:21:19 -0700427 return EXIT_SUCCESS;
428}
429
430} // namespace art
431
432int main(int argc, char** argv) {
433 return art::oatdump(argc, argv);
434}