summaryrefslogtreecommitdiffstats
path: root/cmdline
diff options
context:
space:
mode:
authorRichard Uhler <ruhler@google.com>2015-01-15 09:37:19 -0800
committerRichard Uhler <ruhler@google.com>2015-03-09 14:46:23 -0700
commit66d874d96d5699bb090c59f47a5a528956ca053e (patch)
treed59bf83a08fead7d9823230831bea63c9e43a62c /cmdline
parent2cfdabd2bb4833d7092819d27ef08a9e1cdffead (diff)
downloadart-66d874d96d5699bb090c59f47a5a528956ca053e.zip
art-66d874d96d5699bb090c59f47a5a528956ca053e.tar.gz
art-66d874d96d5699bb090c59f47a5a528956ca053e.tar.bz2
Create OatFileAssistant class for assisting with oat files.
The oat file assistant is used for determining whether dex2oat or patchoat is needed, for running dex2oat or patchoat as needed to make an oat file up to date, and to load dex files associated with a given dex location. The introduction of the OatFileAssistant class is meant to clean up and consolidate code related to the management of oat files that was duplicated and spread across dalvik_system_DexFile.cc and class_linker.cc. Bug: 11301553 Change-Id: I0c16027b9bae4570c2c50faa9c14f581c0cbafb8
Diffstat (limited to 'cmdline')
-rw-r--r--cmdline/cmdline_parser_test.cc7
-rw-r--r--cmdline/cmdline_types.h2
2 files changed, 9 insertions, 0 deletions
diff --git a/cmdline/cmdline_parser_test.cc b/cmdline/cmdline_parser_test.cc
index 130eed2..9f873b3 100644
--- a/cmdline/cmdline_parser_test.cc
+++ b/cmdline/cmdline_parser_test.cc
@@ -260,6 +260,13 @@ TEST_F(CmdlineParserTest, TestLogVerbosity) {
}
EXPECT_SINGLE_PARSE_FAIL("-verbose:blablabla", CmdlineResult::kUsage); // invalid verbose opt
+
+ {
+ const char* log_args = "-verbose:oat";
+ LogVerbosity log_verbosity = LogVerbosity();
+ log_verbosity.oat = true;
+ EXPECT_SINGLE_PARSE_VALUE(log_verbosity, log_args, M::Verbose);
+ }
} // TEST_F
// TODO: Enable this b/19274810
diff --git a/cmdline/cmdline_types.h b/cmdline/cmdline_types.h
index de99278..03165ed 100644
--- a/cmdline/cmdline_types.h
+++ b/cmdline/cmdline_types.h
@@ -591,6 +591,8 @@ struct CmdlineType<LogVerbosity> : CmdlineTypeParser<LogVerbosity> {
log_verbosity.jni = true;
} else if (verbose_options[j] == "monitor") {
log_verbosity.monitor = true;
+ } else if (verbose_options[j] == "oat") {
+ log_verbosity.oat = true;
} else if (verbose_options[j] == "profiler") {
log_verbosity.profiler = true;
} else if (verbose_options[j] == "signals") {