[论文解读] Telepathic Datacenters: Fast RPCs using Shared CXL Memory
RPCool 是一种新型的 RPC 框架,通过利用共享 CXL 内存来消除序列化开销,实现了快速、安全且可扩展的远程过程调用。它通过使用指针传递、内存权限封印、沙箱验证以及自动 RDMA 回退机制,在实现可扩展性的同时,将往返延迟降低至业界最先进的 RDMA 的 1.93 倍以下,且比基于 CXL 的 RPC 降低 7.2 倍。
Datacenter applications often rely on remote procedure calls (RPCs) for fast, efficient, and secure communication. However, RPCs are slow, inefficient, and hard to use as they require expensive serialization and compression to communicate over a packetized serial network link. Compute Express Link 3.0 (CXL) offers an alternative solution, allowing applications to share data using a cache-coherent, shared-memory interface across clusters of machines. RPCool is a new framework that exploits CXL's shared memory capabilities. RPCool avoids serialization by passing pointers to data structures in shared memory. While avoiding serialization is useful, directly sharing pointer-rich data eliminates the isolation that copying data over traditional networks provides, leaving the receiver vulnerable to invalid pointers and concurrent updates to shared data by the sender. RPCool restores this safety with careful and efficient management of memory permissions. Another significant challenge with CXL shared memory capabilities is that they are unlikely to scale to an entire datacenter. RPCool addresses this by falling back to RDMA-based communication. Overall, RPCool reduces the round-trip latency by 1.93$ imes$ and 7.2$ imes$ compared to state-of-the-art RDMA and CXL-based RPC mechanisms, respectively. Moreover, RPCool performs either comparably or better than other RPC mechanisms across a range of workloads.
研究动机与目标
- 解决传统 RPC 因指针丰富数据结构的序列化与压缩而产生的高延迟与 CPU 开销问题。
- 通过利用 CXL 在机架规模集群中实现缓存一致的共享内存,实现在数据中心内低延迟、高吞吐量的通信。
- 通过防止并发修改并检测无效或野指针,恢复在共享内存 RPC 中的安全性与隔离性。
- 通过无缝回退至 RDMA 通信,确保在超越单机架 CXL 限制时仍具备可扩展性。
- 提供统一、应用透明的内存管理机制,包含故障检测与内存泄漏防护,用于共享内存区域。
提出的方法
- 通过 CXL 共享内存直接在客户端与服务器之间传递原生指针丰富的数据结构,彻底消除序列化与反序列化开销。
- 使用内存封印机制,防止发送方在 RPC 处理期间修改数据,确保数据一致性。
- 实现轻量级沙箱验证层,在解引用共享内存数据前检测无效或野指针。
- 集成全局协调器以管理共享内存区域,跟踪连接,并协调 CXL 与 RDMA 通信路径之间的交互。
- 当 CXL 不可用或需扩展至单个机架之外时,自动回退至 RDMA,保持一致的 RPC 接口。
- 支持内存管理功能,包括故障通知与使用限制,以防止内存泄漏与数据丢失。

实验结果
研究问题
- RQ1使用 CXL 的共享内存 RPC 是否能消除序列化开销,并在数据中心工作负载中实现亚微秒级延迟?
- RQ2在通过共享内存跨不受信应用程序共享指针丰富数据结构时,如何确保安全性和数据一致性?
- RQ3在 RPC 处理期间,如何防止发送方并发修改数据,同时保持极低的性能开销?
- RQ4如何在不牺牲性能的前提下,高效检测共享内存中的无效或野指针?
- RQ5混合 CXL/RDMA 通信模型是否能同时在机架规模内实现低延迟,并在整个数据中心范围内实现无缝可扩展性?
主要发现
- 与业界最先进的基于 RDMA 的 RPC 相比,RPCool 将往返延迟降低了 1.93 倍;与基于 CXL 的 RPC 相比,延迟降低了 7.2 倍。
- 在类似 JSON 的文档存储工作负载中,RPCool 在数据库构建阶段实现了 4.7 倍的性能提升,在搜索操作中实现了 1.3 倍的性能提升,优于所有竞争框架中的最快者。
- 在修改后的 MongoDB 和 Memcached 基准测试中,RPCool 在所有工作负载下均优于基于 TCP 的 RPC,展现出更优的吞吐量与更低的延迟。
- 在 DeathStarBench 社交网络微服务套件中,RPCool 的性能与 Thrift RPC 相当,但其性能受限于关键路径上数据库更新的瓶颈。
- 该框架的沙箱指针验证机制引入了极低的开销,同时能有效检测 RPC 处理期间的无效或野指针。
- 自动 RDMA 回退机制支持在超越机架规模 CXL 部署的环境中无缝运行,确保端到端可扩展性,且无需修改应用程序。

阅读本论文
在 Nubint 阅读器中打开原文,边读边就任意段落提问。
在 Nubint 中阅读本论文本解读由 AI 根据论文原文生成,引用前请核对原文。