summaryrefslogtreecommitdiffstats
path: root/compiler/dex/quick/gen_invoke.cc
diff options
context:
space:
mode:
authorIan Rogers <irogers@google.com>2014-10-09 21:56:44 -0700
committerIan Rogers <irogers@google.com>2014-10-09 22:22:46 -0700
commitfc787ecd91127b2c8458afd94e5148e2ae51a1f5 (patch)
treeef48c0f511ee9bf4ed85607cc4d530bace7e6cae /compiler/dex/quick/gen_invoke.cc
parent8fa8c904f7c783204a1dc9438429391d256658da (diff)
downloadandroid_art-fc787ecd91127b2c8458afd94e5148e2ae51a1f5.tar.gz
android_art-fc787ecd91127b2c8458afd94e5148e2ae51a1f5.tar.bz2
android_art-fc787ecd91127b2c8458afd94e5148e2ae51a1f5.zip
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/dex/quick/gen_invoke.cc')
-rwxr-xr-xcompiler/dex/quick/gen_invoke.cc9
1 files changed, 6 insertions, 3 deletions
diff --git a/compiler/dex/quick/gen_invoke.cc b/compiler/dex/quick/gen_invoke.cc
index 408c73d1b0..2bef7c53c5 100755
--- a/compiler/dex/quick/gen_invoke.cc
+++ b/compiler/dex/quick/gen_invoke.cc
@@ -552,7 +552,8 @@ static int NextSDCallInsn(CompilationUnit* cu, CallInfo* info,
} else {
break;
}
- // Intentional fallthrough for x86
+ DCHECK(cu->instruction_set == kX86 || cu->instruction_set == kX86_64);
+ FALLTHROUGH_INTENDED;
default:
return -1;
}
@@ -596,7 +597,8 @@ static int NextVCallInsn(CompilationUnit* cu, CallInfo* info,
if (CommonCallCodeLoadCodePointerIntoInvokeTgt(info, nullptr, cu, cg)) {
break; // kInvokeTgt := kArg0->entrypoint
}
- // Intentional fallthrough for X86
+ DCHECK(cu->instruction_set == kX86 || cu->instruction_set == kX86_64);
+ FALLTHROUGH_INTENDED;
default:
return -1;
}
@@ -641,7 +643,8 @@ static int NextInterfaceCallInsn(CompilationUnit* cu, CallInfo* info, int state,
if (CommonCallCodeLoadCodePointerIntoInvokeTgt(info, nullptr, cu, cg)) {
break; // kInvokeTgt := kArg0->entrypoint
}
- // Intentional fallthrough for X86
+ DCHECK(cu->instruction_set == kX86 || cu->instruction_set == kX86_64);
+ FALLTHROUGH_INTENDED;
default:
return -1;
}