diff options
author | Ian Rogers <irogers@google.com> | 2014-03-06 12:13:39 -0800 |
---|---|---|
committer | Ian Rogers <irogers@google.com> | 2014-03-06 19:16:01 -0800 |
commit | 719d1a33f6569864f529e5a3fff59e7bca97aad0 (patch) | |
tree | fcd84efd7b9806b93ec1a44e2317e6f882e7fe0e /runtime/entrypoints/quick | |
parent | 5365eea9940269b662cfbe103caa348816ff1558 (diff) | |
download | art-719d1a33f6569864f529e5a3fff59e7bca97aad0.zip art-719d1a33f6569864f529e5a3fff59e7bca97aad0.tar.gz art-719d1a33f6569864f529e5a3fff59e7bca97aad0.tar.bz2 |
Enable annotalysis on clang ART builds.
Fix clang build errors aswell as restructure locking/mutex code for correct
thread safety analysis support.
Reorder make dependencies so that host builds build first as they should
provide better compilation errors than target.
Remove host's use of -fno-omit-frame-pointer as it has no value with correct
use of CFI, which we should have.
Change-Id: I72cea8da9a3757b1a0b3acb4081feccb7c6cef90
Diffstat (limited to 'runtime/entrypoints/quick')
-rw-r--r-- | runtime/entrypoints/quick/callee_save_frame.h | 4 | ||||
-rw-r--r-- | runtime/entrypoints/quick/quick_lock_entrypoints.cc | 6 |
2 files changed, 6 insertions, 4 deletions
diff --git a/runtime/entrypoints/quick/callee_save_frame.h b/runtime/entrypoints/quick/callee_save_frame.h index 8f70049..3fd4adc 100644 --- a/runtime/entrypoints/quick/callee_save_frame.h +++ b/runtime/entrypoints/quick/callee_save_frame.h @@ -26,8 +26,8 @@ class ArtMethod; } // namespace mirror // Place a special frame at the TOS that will save the callee saves for the given type. -static void FinishCalleeSaveFrameSetup(Thread* self, mirror::ArtMethod** sp, - Runtime::CalleeSaveType type) +static inline void FinishCalleeSaveFrameSetup(Thread* self, mirror::ArtMethod** sp, + Runtime::CalleeSaveType type) SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) { // Be aware the store below may well stomp on an incoming argument. Locks::mutator_lock_->AssertSharedHeld(self); diff --git a/runtime/entrypoints/quick/quick_lock_entrypoints.cc b/runtime/entrypoints/quick/quick_lock_entrypoints.cc index 5bc7f4c..817d053 100644 --- a/runtime/entrypoints/quick/quick_lock_entrypoints.cc +++ b/runtime/entrypoints/quick/quick_lock_entrypoints.cc @@ -21,7 +21,8 @@ namespace art { extern "C" int artLockObjectFromCode(mirror::Object* obj, Thread* self, mirror::ArtMethod** sp) - EXCLUSIVE_LOCK_FUNCTION(monitor_lock_) { + SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) + NO_THREAD_SAFETY_ANALYSIS /* EXCLUSIVE_LOCK_FUNCTION(Monitor::monitor_lock_) */ { FinishCalleeSaveFrameSetup(self, sp, Runtime::kRefsOnly); if (UNLIKELY(obj == NULL)) { ThrowLocation throw_location(self->GetCurrentLocationForThrow()); @@ -42,7 +43,8 @@ extern "C" int artLockObjectFromCode(mirror::Object* obj, Thread* self, mirror:: } extern "C" int artUnlockObjectFromCode(mirror::Object* obj, Thread* self, mirror::ArtMethod** sp) - UNLOCK_FUNCTION(monitor_lock_) { + SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) + NO_THREAD_SAFETY_ANALYSIS /* UNLOCK_FUNCTION(Monitor::monitor_lock_) */ { FinishCalleeSaveFrameSetup(self, sp, Runtime::kRefsOnly); if (UNLIKELY(obj == NULL)) { ThrowLocation throw_location(self->GetCurrentLocationForThrow()); |