Revert "Make class loader context fail for unknown class loaders"
This reverts commit 2d3de3a40015af07f7645a298f77b398af0c6c2c.
Reason for revert: 8s regression in boot time b/149517940
Change-Id: I81365d1bd63c691d715b8f970dac9da64ab419ff
diff --git a/runtime/oat_file_assistant.h b/runtime/oat_file_assistant.h
index aa4d83b..b5812f9 100644
--- a/runtime/oat_file_assistant.h
+++ b/runtime/oat_file_assistant.h
@@ -144,10 +144,10 @@
// the oat location. Returns a negative status code if the status refers to
// the oat file in the odex location.
int GetDexOptNeeded(CompilerFilter::Filter target_compiler_filter,
- ClassLoaderContext* context,
- const std::vector<int>& context_fds,
bool profile_changed = false,
- bool downgrade = false);
+ bool downgrade = false,
+ ClassLoaderContext* context = nullptr,
+ const std::vector<int>& context_fds = std::vector<int>());
// Returns true if there is up-to-date code for this dex location,
// irrespective of the compiler filter of the up-to-date code.
@@ -292,10 +292,10 @@
// downgrade should be true if the purpose of dexopt is to downgrade the
// compiler filter.
DexOptNeeded GetDexOptNeeded(CompilerFilter::Filter target_compiler_filter,
- ClassLoaderContext* context,
- const std::vector<int>& context_fds,
bool profile_changed,
- bool downgrade);
+ bool downgrade,
+ ClassLoaderContext* context,
+ const std::vector<int>& context_fds);
// Returns the loaded file.
// Loads the file if needed. Returns null if the file failed to load.