diff options
author | 2016-02-24 10:35:01 +0000 | |
---|---|---|
committer | 2016-02-24 10:35:01 +0000 | |
commit | dddfaa5ec5eee11b6ca8c489ed5e92f10a334b22 (patch) | |
tree | cd089d0c149b4704822198f5e8f3f0a64a75c8b1 /runtime/jit/jit_code_cache.h | |
parent | 21ce0dae31a72cee459dba352b4aa1ccb5157a5d (diff) | |
parent | 8d37250f7b9a7839b11488f45a1842b025026f94 (diff) |
Merge "Introduce partial code cache collection."
Diffstat (limited to 'runtime/jit/jit_code_cache.h')
-rw-r--r-- | runtime/jit/jit_code_cache.h | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/runtime/jit/jit_code_cache.h b/runtime/jit/jit_code_cache.h index 74ce7b57fd..e5b8e6ca17 100644 --- a/runtime/jit/jit_code_cache.h +++ b/runtime/jit/jit_code_cache.h @@ -234,6 +234,18 @@ class JitCodeCache { // Set the footprint limit of the code cache. void SetFootprintLimit(size_t new_footprint) REQUIRES(lock_); + void DoFullCollection(Thread* self) + REQUIRES(!lock_) + SHARED_REQUIRES(Locks::mutator_lock_); + + void RemoveUnusedCode(Thread* self) + REQUIRES(!lock_) + SHARED_REQUIRES(Locks::mutator_lock_); + + void MarkCompiledCodeOnThreadStacks(Thread* self) + REQUIRES(!lock_) + SHARED_REQUIRES(Locks::mutator_lock_); + // Lock for guarding allocations, collections, and the method_code_map_. Mutex lock_; // Condition to wait on during collection. @@ -269,8 +281,8 @@ class JitCodeCache { // The current footprint in bytes of the data portion of the code cache. size_t data_end_ GUARDED_BY(lock_); - // Whether a collection has already been done on the current capacity. - bool has_done_one_collection_ GUARDED_BY(lock_); + // Whether a full collection has already been done on the current capacity. + bool has_done_full_collection_ GUARDED_BY(lock_); // Last time the the code_cache was updated. // It is atomic to avoid locking when reading it. |