---
title: Cache Sharing Protocols in Modern Systems
url: https://www.emergentmind.com/topics/cache-sharing-protocol
type: topic
---

# Cache Sharing Protocols in Modern Systems

A cache sharing protocol comprises the set of mechanisms, metadata, and policies by which multiple clients, agents, or systems can effectively share access to a cache—typically in multi-core computers, distributed storage, multi-tenant machine learning serving, or content delivery networks. By coherently managing shared or partitioned cache capacity, controlling replacement, enforcing consistency and/or security policies, and exposing appropriate abstractions to clients, these protocols aim to maximize performance, fairness, compatibility, or security subject to system-specific constraints.

## 1. Architectural Models for Cache Sharing

Cache sharing protocols vary fundamentally according to architecture and target workload. Representative models include:

- **Way-Partitioned and Reuse-Aware Shared LLCs:** In multicore systems, shared last-level caches (LLCs) may be split into statically assigned “ways” or dynamically partitioned among cores or threads. Protocols such as SRCP overlay partitioning with per-line sharing- and reuse-metadata, distinguishing local from remote usage to avoid duplication and premature eviction of shared data [2201.11638].

- **Layered Caching Topologies in Distributed Systems:** Systems like DistCache comprise multi-layer cache networks where objects are mapped via independent hashes to distinct nodes in each layer, supporting provable load balancing, minimal coherence overhead, and scalable throughput [1901.08200].

- **Multi-Agent and Multi-Tenant ML Inference:** Shared key-value (KV) cache systems enable cross-user, cross-agent, or cross-request reuse in large language model (LLM) inference workloads, sometimes with complex semantic alignment or quantifiable security guarantees [2503.16525, 2410.18517, 2603.10726, 2602.01053].

- **Shared Caching in Content Distribution:** Schemes use logical or physical partitions per provider, workload, or subset, sometimes coordinated using utility maximization, information-theoretic coding, or rigorous admission-control policies [1702.01823, 2201.10577, 1905.07641].

A table summarizing select protocol classes:

| Protocol/Domain         | Key Architectural Feature         | Representative Work                                                  |
|------------------------ |-----------------------------------|---------------------------------------------------------------------|
| Way-Partitioned LLC     | Per-core partitioning + metadata  | SRCP [2201.11638]                                                   |
| Multilayer Distributed  | Independent-hash bipartite graph  | DistCache [1901.08200]                                              |
| LLM Inference KV Reuse  | Cross-request, semantic alignment | KVShare [2503.16525], KVSharer [2410.18517], CacheSolidarity [2603.10726] |
| Multi-Provider CDN      | LRU-partition, object sharing     | Utility partitioning [1702.01823], Object sharing [1905.07641]      |
| Coded Caching           | Placement Delivery Arrays (PDA)   | [2201.10577], [2110.11110]                                          |

## 2. Protocol Mechanisms: Metadata, Replacement, and Consistency

- **Per-line Metadata:** Advanced protocols encode sharing status, frequency, and recency. SRCP tracks AFC, Global Count, and local access bits to prioritize shared and frequently reused lines in replacement decisions [2201.11638]. In distributed LRU sharing, effective “length” of an object is fractionally charged across owners [1905.07641]. LLCs optimized for remote-sharing maintain “shared‐by‐remote” bits and per-set counters to bias retention towards cache lines seen in remote cache-to-cache transfers [1909.09463].

- **Victim Selection and Replacement:** Protocols replace cache entries using custom lexicographic orderings on sharing/usage counters, explicit utility functions, coded sub-packetization maps, or secret-sharing logic. In multi-tenant ML serving, replacement or recomputation may be driven by semantic edit distance or layerwise dissimilarity [2503.16525, 2410.18517].

- **Consistency and Atomicity:** Shared caches in distributed or disaggregated memory contexts require rigorously enforced coherence semantics, often mapping lock or latch state to classic MOESI or MSI protocols but realized atop RDMA atomics with embedded ownership metadata, as in SELCC [2409.02088]. In many self-invalidate designs (e.g., Neat), the system forgoes per-line/byte transient states in favor of phase-based flush and invalidate operations, sometimes with further optimization like write signatures or partial-invalidation states [2107.05453].

- **Security and Access Control:** Coded caching schemes for shared environments apply Placement Delivery Arrays, secret-sharing, and/or one-time-pad keys to guarantee information-theoretic secrecy against unauthorized access [2110.11110]. Time-dependent access control overlays hierarchical key distribution atop encrypted content caches, balancing key-management state and scalability [2302.11292]. Defenses against timing side channels, as in CacheSolidarity, track cache entry ownership and isolation flags, enforcing prefix-granular isolation only upon suspicious cross-user reuse [2603.10726].

## 3. Performance and Scalability Considerations

Quantitative benefits and costs are tightly linked to the selection of sharing protocol:

- **Cache Hit and Throughput:** Adding sharing/reuse-aware policies to partitioned hardware (e.g., SRCP) increases LLC hit-rate (13.3% over LRU) and IPC (10.4%), outperforming alternative replacement schemes [2201.11638]. In multi-proxy object-sharing caches, real system prototypes show that the working-set approximation predicts hit rates within 5% of simulation, and ripple-eviction cost (from cascaded evictions across logical lists) can be largely amortized with batched/thresholded replacement [1905.07641].

- **Distributed Scaling:** In DistCache, object partitioning across two layers of hash functions and adaptive query routing (“power-of-two-choices”) achieve linear scaling of cache throughput across 32 racks and 1.5–2× performance improvements on write-intensive workloads vs. replication [1901.08200].

- **Inference Efficiency in LLMs:** Protocols such as KVShare leverage semantic alignment, DELTA-trees, and partial recomputation to preserve accuracy while reducing prefill compute cycles by up to 60%, yielding rough 1.2× system throughput gains and dramatic reductions in time-to-first-token for matching requests [2503.16525]. KVSharer demonstrates that selective, layerwise cache sharing delivers a 30% memory reduction and at least 1.3× generation acceleration at cost of negligible task degradation [2410.18517]. LRAgent exploits shared and low-rank decomposed caches to approach fully shared throughput and memory consumption in multi-LoRA agent systems, outperforming baseline and partial-share implementations [2602.01053].

- **Overhead and Complexity:** Additional metadata (counters, flags, per-entry or per-line bits) incurs minimal storage and logic overhead in most hardware designs, e.g., SRCP’s sharing/usage bits or CacheSolidarity’s 32-byte per-KV metadata [2201.11638, 2603.10726]. Some schemes such as cache-coded caching with PDAs are designed specifically to avoid exponential subpacketization costs [2201.10577].

## 4. Theoretical Foundations and Formal Analysis

- **Analytic Models:** Multi-proxy LRU sharing uses Poisson/IRM-based working-set approximations with independence assumptions and coupled nonlinear equations to accurately estimate per-proxy hit rates and size allocations [1905.07641]. Utility-based partitioning frameworks are formulated as convex optimization problems—the unique maximizer can be found by online gradient ascent, guided only by empirical hit-rate measurements [1702.01823].

- **Coded and Secretive Shared Caching:** Formal properties of Placement Delivery Arrays (PDA) underlie the ability to support low-subpacketization, coded-multicast communication with precise storage and transmission guarantees [2201.10577]. Information-theoretic secrecy is enforced using non-perfect secret-sharing, one-time pad keys, and precise rate/subpacketization bounds; the cut-set lower bounds and order-optimality proofs frame achievable performance [2110.11110].

- **Security Guarantees:** CacheSolidarity provides a formal (informal theorem) guarantee that no non-owner can exploit timing side channels by observing cache hits on secret-dependent intervals beyond a flagged prefix, rendering incremental probing attacks ineffective on reused prefixes [2603.10726].

## 5. Practical Algorithms and Implementation

- **Adaptive Enablement:** Certain replacement and retention policies are made dynamic, with hardware or software logic toggling behavior in response to observed workload conditions, such as the proportion of remote cache transfers (e.g., high-water mark gating in remote-sharing LLCs [1909.09463]) or run-time measurement of kernel density TTFT overlap to control prefix isolation [2603.10726].

- **Online Control and Admission:** Utility-driven LRU partitioning implements a discrete-time gradient algorithm responsive to instantaneous hit-count measurements and utility derivatives, adjusting allocations in real time to converge to optimal partitions [1702.01823]. Admission-control in multi-proxy shared caches makes explicit use of the working-set equation root for new virtual proxies, guaranteeing system-wide feasibility and fairness [1905.07641].

- **Cache Sharing in Modern ML Serving:** Semantic editing via DELTA-Trees and partial recomputation, as in KVShare, is implemented using global embedding indices, cache alignment editors, and partial attention that flags exact recomputation points during model prefill [2503.16525]. KVSharer and LRAgent protocols are compatible with intra-layer compression and readily combine with existing attention/reuse kernels [2410.18517, 2602.01053].

## 6. Trade-Offs, Limitations, and Future Directions

- **Interference vs. Reuse:** Dedicated way-partitioned caches eliminate interference but block cross-core data reuse; sharing-aware, reuse-sensitive protocols mitigate this at modest complexity cost [2201.11638]. In ML systems, cache sharing is often balanced with strict multi-tenant isolation or the risk of side-channel leakage, motivating granular tracking solutions [2503.16525, 2603.10726].

- **Metadata, State, and Scalability:** Increasing sharing state—per-line, per-prefix or per-user—can challenge capacity or verification for large-scale systems. Macroscopically, batch/threshold approaches (as in ripple control [1905.07641]) can reduce overhead. In coded caching, construction techniques (e.g., PDAs from combinatorial design) can achieve sub-exponential subpacketization [2201.10577, 2110.11110].

- **Assumptions and Generalization:** The efficacy of self-invalidate coherence approaches depends on the data-race-free (DRF) model. Rigid DRF is necessary for Neat's protocol simplicity and correctness, limiting its applicability in non-DRF or weakly ordered workloads [2107.05453]. Security-driven shared cache protocols are only resistant to side-channel probing after the first sharing event and may require further engineering for more aggressive attackers [2603.10726].

- **Prospective Research:** Research directions include dynamic partition resizing based on runtime observations [2201.11638], integration of sharing-aware protocols into nonuniform or composable memory architectures [2409.02088], and co-design of hardware–software annotations for advanced sharing pattern control.

## 7. Comparative Summary and Representative Results

A concise table highlighting representative protocols and primary quantitative improvements:

| Protocol                 | Domain         | Quantitative Benefit                                    | Reference     |
|--------------------------|---------------|---------------------------------------------------------|---------------|
| SRCP                     | Multicore LLC | +13.34% LLC hit-rate, +10.4% IPC over LRU              | [2201.11638]  |
| DistCache                | Distributed   | Linear scaling, 1.5–2× throughput over Replication      | [1901.08200]  |
| KVShare                  | LLM Inference | ≤60% token reuse, ~1.2× throughput, BLEU Δ<1%           | [2503.16525]  |
| KVSharer                 | LLM Inference | 30% memory saved, ≥1.3× decoding speed                  | [2410.18517]  |
| Utility Partitioning     | CDN           | Up to 10% utility increase (shared→optimal partition)   | [1702.01823]  |
| Object-Sharing LRU       | CDN           | Working-set approx. within 5% of simulation; 15% o/h    | [1905.07641]  |
| SELCC                    | Disaggregated | 2.2–5.6× vs. RPC-based, 80%+ hit ratio under Zipf(0.99) | [2409.02088]  |
| CacheSolidarity          | LLM Security  | Cache reuse ↑70%, TTFT ↓30% vs. static isolation        | [2603.10726]  |

The cache sharing protocol landscape spans a diversity of architectures, objectives, and implementation techniques. By integrating fine-grained metadata, theoretical rigor, and workload-tailored optimization, these protocols collectively represent the state of the art in efficient, secure, and scalable shared caching for contemporary computing infrastructure.

Source: https://www.emergentmind.com/topics/cache-sharing-protocol