MCPcopy Create free account
hub / github.com/bytedance/bolt / fileTouched

Method fileTouched

bolt/common/caching/SsdFileTracker.cpp:36–44  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

34namespace bytedance::bolt::cache {
35
36void SsdFileTracker::fileTouched(int32_t totalEntries) {
37 ++numTouches_;
38 if (numTouches_ > kDecayInterval && numTouches_ > totalEntries / 2) {
39 numTouches_ = 0;
40 for (auto& score : regionScores_) {
41 score = (score * 15) / 16;
42 }
43 }
44}
45
46void SsdFileTracker::regionFilled(int32_t region) {
47 const uint64_t best =

Callers 2

findMethod · 0.80
TESTFunction · 0.80

Calls

no outgoing calls

Tested by 1

TESTFunction · 0.64