summaryrefslogtreecommitdiff
path: root/runtime/instruction_set.cc
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/instruction_set.cc')
-rw-r--r--runtime/instruction_set.cc13
1 files changed, 5 insertions, 8 deletions
diff --git a/runtime/instruction_set.cc b/runtime/instruction_set.cc
index d8a38f42d7..644e0556b1 100644
--- a/runtime/instruction_set.cc
+++ b/runtime/instruction_set.cc
@@ -42,21 +42,18 @@ const char* GetInstructionSetString(const InstructionSet isa) {
InstructionSet GetInstructionSetFromString(const char* isa_str) {
CHECK(isa_str != nullptr);
- if (!strcmp("arm", isa_str)) {
+ if (strcmp("arm", isa_str) == 0) {
return kArm;
- } else if (!strcmp("arm64", isa_str)) {
+ } else if (strcmp("arm64", isa_str) == 0) {
return kArm64;
- } else if (!strcmp("x86", isa_str)) {
+ } else if (strcmp("x86", isa_str) == 0) {
return kX86;
- } else if (!strcmp("x86_64", isa_str)) {
+ } else if (strcmp("x86_64", isa_str) == 0) {
return kX86_64;
- } else if (!strcmp("mips", isa_str)) {
+ } else if (strcmp("mips", isa_str) == 0) {
return kMips;
- } else if (!strcmp("none", isa_str)) {
- return kNone;
}
- LOG(FATAL) << "Unknown ISA " << isa_str;
return kNone;
}