Skip to content

Commit 9aaa81f

Browse files
committed
Add adaptive replacement cache
Current basic block management consumes a significant amount of memory, which leads to unnecessary waste due to frequent map allocation and release. Adaptive Replacement Cache (ARC) is a page replacement algorithm with better performance than least recently used (LRU). After the translated blocks are handled by ARC, better memory usage and hit rates can be achieved by keeping track of frequently used and recently used pages, as well as a recent eviction history for both. According to the cache information obtained while running CoreMark, the cache hit rate of ARC can reach over 99%.
1 parent a713b4c commit 9aaa81f

File tree

4 files changed

+462
-0
lines changed

4 files changed

+462
-0
lines changed

.clang-format

+4
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,7 @@ UseTab: Never
1313
IndentWidth: 4
1414
BreakBeforeBraces: Linux
1515
AccessModifierOffset: -4
16+
ForEachMacros:
17+
- list_for_each_entry
18+
- list_for_each_entry_safe
19+
- hlist_for_each_entry

0 commit comments

Comments
 (0)