From 9758f79a6c1ef7f662caca9c1df39de1934166b8 Mon Sep 17 00:00:00 2001 From: Ian Rogers Date: Thu, 13 Mar 2014 09:02:55 -0700 Subject: Implement FINAL/OVERRIDE for clang. Separate declaration from definition in certain places to work-around issues with clang. Remove bogus lock annotation at definition in compilers.cc that is already present at the declaration. Remove duplicate definition of ClassReference. Change-Id: I5368057bb36319a259110b2198610d9d2b2e5041 --- compiler/driver/compiler_callbacks_impl.h | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) (limited to 'compiler/driver/compiler_callbacks_impl.h') diff --git a/compiler/driver/compiler_callbacks_impl.h b/compiler/driver/compiler_callbacks_impl.h index ed6a9255b9..92adb20c1f 100644 --- a/compiler/driver/compiler_callbacks_impl.h +++ b/compiler/driver/compiler_callbacks_impl.h @@ -36,15 +36,7 @@ class CompilerCallbacksImpl FINAL : public CompilerCallbacks { ~CompilerCallbacksImpl() { } bool MethodVerified(verifier::MethodVerifier* verifier) - SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) OVERRIDE { - bool result = verification_results_->ProcessVerifiedMethod(verifier); - if (result) { - MethodReference ref = verifier->GetMethodReference(); - method_inliner_map_->GetMethodInliner(ref.dex_file) - ->AnalyseMethodCode(verifier); - } - return result; - } + SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) OVERRIDE; void ClassRejected(ClassReference ref) OVERRIDE { verification_results_->AddRejectedClass(ref); } @@ -54,6 +46,16 @@ class CompilerCallbacksImpl FINAL : public CompilerCallbacks { DexFileToMethodInlinerMap* const method_inliner_map_; }; +inline bool CompilerCallbacksImpl::MethodVerified(verifier::MethodVerifier* verifier) { + bool result = verification_results_->ProcessVerifiedMethod(verifier); + if (result) { + MethodReference ref = verifier->GetMethodReference(); + method_inliner_map_->GetMethodInliner(ref.dex_file) + ->AnalyseMethodCode(verifier); + } + return result; +} + } // namespace art #endif // ART_COMPILER_DRIVER_COMPILER_CALLBACKS_IMPL_H_ -- cgit v1.2.3-59-g8ed1b