diff options
| -rw-r--r-- | dex2oat/dex2oat.cc | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/dex2oat/dex2oat.cc b/dex2oat/dex2oat.cc index 223be4c8e6..326fa729b2 100644 --- a/dex2oat/dex2oat.cc +++ b/dex2oat/dex2oat.cc @@ -837,7 +837,7 @@ static int dex2oat(int argc, char** argv) { InstructionSet instruction_set = kRuntimeISA; std::string error_msg; std::unique_ptr<const InstructionSetFeatures> instruction_set_features( - InstructionSetFeatures::FromFeatureString(instruction_set, "default", &error_msg)); + InstructionSetFeatures::FromFeatureString(kNone, "default", &error_msg)); CHECK(instruction_set_features.get() != nullptr) << error_msg; // Profile file to use @@ -1152,6 +1152,13 @@ static int dex2oat(int argc, char** argv) { oat_unstripped += oat_filename; } + // If no instruction set feature was given, use the default one for the target + // instruction set. + if (instruction_set_features->GetInstructionSet() == kNone) { + instruction_set_features.reset( + InstructionSetFeatures::FromFeatureString(instruction_set, "default", &error_msg)); + } + if (compiler_filter_string == nullptr) { if (instruction_set == kMips64) { // TODO: fix compiler for Mips64. |