Table of Contents
Fetching ...

ReDAG-RT: Global Rate-Priority Scheduling for Real-Time Multi-DAG Execution in ROS 2

Md. Mehedi Hasan, Rafid Mostafiz, Bikash Kumar Paul, Md. Abir Hossain, Ziaur Rahman

Abstract

ROS 2 has become a dominant middleware for robotic systems, where perception, estimation, planning, and control pipelines are structured as directed acyclic graphs of callbacks executed under a shared executor. However, default ROS 2 executors use best-effort dispatch without cross-DAG priority enforcement, leading to callback contention, structural priority inversion, and deadline instability under concurrent workloads. These limitations restrict deployment in time-critical and safety-sensitive cyber-physical systems. This paper presents ReDAGRT, a user-space global scheduling framework for deterministic multi-DAG execution in unmodified ROS 2. The framework introduces a Rate-Priority driven global ready queue that orders callbacks by activation rate, enforces per-DAG concurrency bounds, and mitigates cross-graph priority inversion without modifying the ROS 2 API, executor interface, or underlying operating system scheduler. We formalize a multi-DAG task model for ROS 2 callback pipelines and analyze cross-DAG interference under Rate-Priority scheduling. Response-time recurrences and schedulability conditions are derived within classical Rate-Monotonic theory. Experiments in a ROS 2 Humble environment compare ReDAGRT against SingleThreadedExecutor and MultiThreadedExecutor using synthetic multi-DAG workloads. Results show up to 29.7 percent reduction in deadline miss rate, 42.9 percent reduction in 99th percentile response time, and 13.7 percent improvement over MultiThreadedExecutor under comparable utilization. Asymmetric per-DAG concurrency bounds further reduce interference by 40.8 percent. These results demonstrate that deterministic and analyzable multi-DAG scheduling can be achieved entirely in the ROS 2 user-space execution layer, providing a practical foundation for real-time robotic middleware in safety-critical systems.

ReDAG-RT: Global Rate-Priority Scheduling for Real-Time Multi-DAG Execution in ROS 2

Abstract

ROS 2 has become a dominant middleware for robotic systems, where perception, estimation, planning, and control pipelines are structured as directed acyclic graphs of callbacks executed under a shared executor. However, default ROS 2 executors use best-effort dispatch without cross-DAG priority enforcement, leading to callback contention, structural priority inversion, and deadline instability under concurrent workloads. These limitations restrict deployment in time-critical and safety-sensitive cyber-physical systems. This paper presents ReDAGRT, a user-space global scheduling framework for deterministic multi-DAG execution in unmodified ROS 2. The framework introduces a Rate-Priority driven global ready queue that orders callbacks by activation rate, enforces per-DAG concurrency bounds, and mitigates cross-graph priority inversion without modifying the ROS 2 API, executor interface, or underlying operating system scheduler. We formalize a multi-DAG task model for ROS 2 callback pipelines and analyze cross-DAG interference under Rate-Priority scheduling. Response-time recurrences and schedulability conditions are derived within classical Rate-Monotonic theory. Experiments in a ROS 2 Humble environment compare ReDAGRT against SingleThreadedExecutor and MultiThreadedExecutor using synthetic multi-DAG workloads. Results show up to 29.7 percent reduction in deadline miss rate, 42.9 percent reduction in 99th percentile response time, and 13.7 percent improvement over MultiThreadedExecutor under comparable utilization. Asymmetric per-DAG concurrency bounds further reduce interference by 40.8 percent. These results demonstrate that deterministic and analyzable multi-DAG scheduling can be achieved entirely in the ROS 2 user-space execution layer, providing a practical foundation for real-time robotic middleware in safety-critical systems.
Paper Structure (29 sections, 18 equations, 6 figures, 4 tables, 1 algorithm)

This paper contains 29 sections, 18 equations, 6 figures, 4 tables, 1 algorithm.

Figures (6)

  • Figure 1: Cross-DAG priority inversion under the default ROS 2 executor and the ReDAG$^{\mathrm{RT}}$ solution. (A) Multiple independent DAGs collapse into a shared FIFO queue with no global priority ordering. (B) Low-frequency callbacks execute before high-frequency ones, causing priority inversion and deadline misses. (C) ReDAG$^{\mathrm{RT}}$ enforces Rate-Monotonic ordering via a unified priority queue. (D) Deterministic execution eliminates priority inversion and bounds response times.
  • Figure 2: ReDAG$^{\mathrm{RT}}$ layered user-space scheduling architecture. Periodic DAG workloads $G_k = (V_k, E_k)$ release tasks upon period expiration. A dependency-aware release stage validates timing and precedence constraints before admitting ready tasks into a unified global Rate-Monotonic priority queue ordered by $\arg\min_{\tau_i \in \mathcal{R}}\,T_i$. The ReDAG$^{\mathrm{RT}}$ executor performs fixed-priority preemptive arbitration across all DAGs and dispatches to the unmodified Linux execution layer. An integrated Timing Monitor computes $R_i$, $L_i$, and $\mathrm{MR}_i$ online, with event-driven re-scheduling closing the control loop.
  • Figure 3: Effect of thread count on ReDAG$^{\mathrm{RT}}$ deadline miss rate. Increasing worker threads reduces interference until saturation near eight threads.
  • Figure 4: Sensitivity of ReDAG$^{\mathrm{RT}}$ performance to deadline scaling. Moderate deadline relaxation reduces miss rate, while excessive slack increases interference windows.
  • Figure 5: Impact of per-DAG concurrency limits on combined deadline miss rate. Asymmetric concurrency bounds significantly reduce cross-DAG interference.
  • ...and 1 more figures