QFabric:Linux-RTOS 板上的受保护跨域任务恢复及其限制
研究论文 · 2026/11/05
QFabric 是一个原型系统,将跨域任务放置视为对违反经验软实时契约的受保护恢复:任务同时编译到 Linux 和 MCU 两个域,在带滞回的窗口内监控,仅在静默纪元边界通过语义和容量准入后切换,并在试用期后提交或回滚。在 Arduino UNO Q(Cortex-A53 Linux 与运行 Zephyr 的 Cortex-M33)上,作者表征了原生 Bridge RPC 互连,并在空闲、CPU 负载和高优先级 SCHED_FIFO 争用下,用普通和实时调用者测量了五个工作负载在两个域中的表现。每次 MCU 调用无论计算量如何都产生约 19 ms 的调度开销,MCU 运行最重内核慢 34 倍,且由于每次调用都穿越 Linux 用户空间,Linux 争用对 MCU 路径的膨胀远大于 Linux 路径(p99 高达 400 ms 对 17.0 ms)。在四节点链的 30 个单元中,Linux 满足所有契约,错过率在 0.8% 以内,QFabric 正确从不迁移;无滞回的控制器在 7 个单元中迁移,使 p95 最高增加 177 倍,试用期回滚了其中 5 次迁移。因此,在 Linux 调度的异构板上,迁移无法将任务与 Linux 干扰隔离,恢复保护的主要作用在于防止有害迁移。本文取代了早期工件版本,其报告的改进源于作者识别的测量缺陷。所有源代码、原始跟踪和生成器均已公开。
本文通过严谨的实测揭示了在 Linux 调度的异构嵌入式板上跨域迁移的固有局限:迁移无法隔离 Linux 干扰,恢复保护的核心价值在于防止有害迁移而非提升性能。其方法论(带滞回的监控、准入、试用期回滚)和公开的测量缺陷修正对实时系统研究者具有重要参考价值。
Heterogeneous embedded boards pair a Linux application processor with a real-time microcontroller (MCU), which suggests moving a task between the two domains when its timing degrades. We present QFabric, a prototype that treats cross-domain placement as guarded recovery from a violated empirical soft real-time contract: a bounded task is compiled for both domains, monitored in windows with hysteresis, switched only after semantic and capacity admission at a quiescent epoch boundary, and committed or rolled back after probation. On an Arduino UNO Q (Cortex-A53 Linux and a Cortex-M33 running Zephyr), we characterize the stock Bridge RPC interconnect and measure five workloads in both domains under idle, CPU-load, and higher-priority SCHED_FIFO contention, with ordinary and real-time callers. Each MCU invocation costs about 19 ms of dispatch regardless of compute, the MCU runs the heaviest kernel 34x slower, and because every call traverses Linux userspace, Linux contention inflates the MCU path far more than the Linux path (p99 up to 400 ms versus 17.0 ms). Across 30 cells of a four-node chain, Linux meets every contract within 0.8% misses and QFabric correctly never migrates; a controller without hysteresis migrates in 7 cells, raising p95 by up to 177x, and probation rolls back 5 of those moves. On Linux-dispatched heterogeneous boards, migration therefore cannot isolate a task from Linux interference, and recovery guards matter chiefly by preventing harmful moves. This paper supersedes an earlier artifact release whose reported improvement arose from measurement defects that we identify. All source, raw traces, and generators are public.