summaryrefslogtreecommitdiff
path: root/compiler/optimizing
diff options
context:
space:
mode:
author Ian Rogers <irogers@google.com> 2014-10-09 21:56:44 -0700
committer Ian Rogers <irogers@google.com> 2014-10-09 22:22:46 -0700
commitfc787ecd91127b2c8458afd94e5148e2ae51a1f5 (patch)
treeef48c0f511ee9bf4ed85607cc4d530bace7e6cae /compiler/optimizing
parent8fa8c904f7c783204a1dc9438429391d256658da (diff)
Enable -Wimplicit-fallthrough.
Falling through switch cases on a clang build must now annotate the fallthrough with the FALLTHROUGH_INTENDED macro. Bug: 17731372 Change-Id: I836451cd5f96b01d1ababdbf9eef677fe8fa8324
Diffstat (limited to 'compiler/optimizing')
-rw-r--r--compiler/optimizing/code_generator_arm.cc12
-rw-r--r--compiler/optimizing/code_generator_x86.cc12
-rw-r--r--compiler/optimizing/code_generator_x86_64.cc12
3 files changed, 24 insertions, 12 deletions
diff --git a/compiler/optimizing/code_generator_arm.cc b/compiler/optimizing/code_generator_arm.cc
index d555a0d553..eb0158bd08 100644
--- a/compiler/optimizing/code_generator_arm.cc
+++ b/compiler/optimizing/code_generator_arm.cc
@@ -1288,9 +1288,10 @@ void InstructionCodeGeneratorARM::VisitInstanceFieldSet(HInstanceFieldSet* instr
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << field_type;
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << field_type;
+ UNREACHABLE();
}
}
@@ -1348,9 +1349,10 @@ void InstructionCodeGeneratorARM::VisitInstanceFieldGet(HInstanceFieldGet* instr
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << instruction->GetType();
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << instruction->GetType();
+ UNREACHABLE();
}
}
@@ -1478,9 +1480,10 @@ void InstructionCodeGeneratorARM::VisitArrayGet(HArrayGet* instruction) {
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << instruction->GetType();
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << instruction->GetType();
+ UNREACHABLE();
}
}
@@ -1575,9 +1578,10 @@ void InstructionCodeGeneratorARM::VisitArraySet(HArraySet* instruction) {
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << instruction->GetType();
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << instruction->GetType();
+ UNREACHABLE();
}
}
diff --git a/compiler/optimizing/code_generator_x86.cc b/compiler/optimizing/code_generator_x86.cc
index 5f6d45845f..6ad627a517 100644
--- a/compiler/optimizing/code_generator_x86.cc
+++ b/compiler/optimizing/code_generator_x86.cc
@@ -1276,9 +1276,10 @@ void InstructionCodeGeneratorX86::VisitInstanceFieldSet(HInstanceFieldSet* instr
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << field_type;
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << field_type;
+ UNREACHABLE();
}
}
@@ -1348,9 +1349,10 @@ void InstructionCodeGeneratorX86::VisitInstanceFieldGet(HInstanceFieldGet* instr
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << instruction->GetType();
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << instruction->GetType();
+ UNREACHABLE();
}
}
@@ -1478,9 +1480,10 @@ void InstructionCodeGeneratorX86::VisitArrayGet(HArrayGet* instruction) {
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << instruction->GetType();
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << instruction->GetType();
+ UNREACHABLE();
}
}
@@ -1631,9 +1634,10 @@ void InstructionCodeGeneratorX86::VisitArraySet(HArraySet* instruction) {
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << instruction->GetType();
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << instruction->GetType();
+ UNREACHABLE();
}
}
diff --git a/compiler/optimizing/code_generator_x86_64.cc b/compiler/optimizing/code_generator_x86_64.cc
index 393eb1a2d4..c15cca62af 100644
--- a/compiler/optimizing/code_generator_x86_64.cc
+++ b/compiler/optimizing/code_generator_x86_64.cc
@@ -1158,9 +1158,10 @@ void InstructionCodeGeneratorX86_64::VisitInstanceFieldSet(HInstanceFieldSet* in
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << field_type;
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << field_type;
+ UNREACHABLE();
}
}
@@ -1212,9 +1213,10 @@ void InstructionCodeGeneratorX86_64::VisitInstanceFieldGet(HInstanceFieldGet* in
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << instruction->GetType();
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << instruction->GetType();
+ UNREACHABLE();
}
}
@@ -1339,9 +1341,10 @@ void InstructionCodeGeneratorX86_64::VisitArrayGet(HArrayGet* instruction) {
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << instruction->GetType();
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << instruction->GetType();
+ UNREACHABLE();
}
}
@@ -1465,9 +1468,10 @@ void InstructionCodeGeneratorX86_64::VisitArraySet(HArraySet* instruction) {
case Primitive::kPrimFloat:
case Primitive::kPrimDouble:
LOG(FATAL) << "Unimplemented register type " << instruction->GetType();
-
+ UNREACHABLE();
case Primitive::kPrimVoid:
LOG(FATAL) << "Unreachable type " << instruction->GetType();
+ UNREACHABLE();
}
}