summaryrefslogtreecommitdiff
path: root/runtime/jit/jit_code_cache.h
diff options
context:
space:
mode:
author Nicolas Geoffray <ngeoffray@google.com> 2023-12-06 10:31:10 +0000
committer Nicolas Geoffray <ngeoffray@google.com> 2023-12-07 09:20:17 +0000
commitfee0362d03e5ee1b0beaa4839e7f3653ed5ce72d (patch)
treeaf4d5634ac93669d644d174a380e9b9c2f2a784c /runtime/jit/jit_code_cache.h
parentc60b6f7754974809f7467a07d63475248274026b (diff)
Remove logic of polling liveness of compiled code.
Data shows the current logic is having too many misses by deleting baseline compiled code which could still be useful. Reduces jank on compose view scrolling for 20 seconds, average of 50 runs: - For Go Mokey: - Before: ~433 frames drawn / ~18.47% janky frames - After: ~485 frames drawn / ~17.02% janky frames - For Pixel 8 pro: - Before: ~2428 frames drawn / 1.20% janky frames - After: ~2433 frames drawn / 1.02% jank frames Test: test.py Change-Id: I06b24ce069be493394a1af5f7402f0a381e00dfb
Diffstat (limited to 'runtime/jit/jit_code_cache.h')
-rw-r--r--runtime/jit/jit_code_cache.h11
1 files changed, 1 insertions, 10 deletions
diff --git a/runtime/jit/jit_code_cache.h b/runtime/jit/jit_code_cache.h
index 88b54d5a5b..82510fbe3c 100644
--- a/runtime/jit/jit_code_cache.h
+++ b/runtime/jit/jit_code_cache.h
@@ -496,12 +496,7 @@ class JitCodeCache {
// Return whether the code cache's capacity is at its maximum.
bool IsAtMaxCapacity() const REQUIRES(Locks::jit_lock_);
- // Return whether we should do a full collection given the current state of the cache.
- bool ShouldDoFullCollection()
- REQUIRES(Locks::jit_lock_)
- REQUIRES_SHARED(Locks::mutator_lock_);
-
- void DoCollection(Thread* self, bool collect_profiling_info)
+ void DoCollection(Thread* self)
REQUIRES(!Locks::jit_lock_)
REQUIRES_SHARED(Locks::mutator_lock_);
@@ -594,9 +589,6 @@ class JitCodeCache {
// Bitmap for collecting code and data.
std::unique_ptr<CodeCacheBitmap> live_bitmap_;
- // Whether the last collection round increased the code cache.
- bool last_collection_increased_code_cache_ GUARDED_BY(Locks::jit_lock_);
-
// Whether we can do garbage collection. Not 'const' as tests may override this.
bool garbage_collect_code_ GUARDED_BY(Locks::jit_lock_);
@@ -623,7 +615,6 @@ class JitCodeCache {
// Histograms for keeping track of profiling info statistics.
Histogram<uint64_t> histogram_profiling_info_memory_use_ GUARDED_BY(Locks::jit_lock_);
- friend class art::JitJniStubTestHelper;
friend class ScopedCodeCacheWrite;
friend class MarkCodeClosure;