Klepsydra AI successfully ported to RTEMS6 SMP

Klepsydra AI successfully ported to RTEMS6 SMP for a Cortex-A9

The ZedBoard, based on the Xilinx Zynq-7000 All Programmable SoC, features a dual-core ARM Cortex-A9 processor supporting the ARMv7-A 32-bit architecture, typically running up to 1 GHz. Alongside this, it includes programmable logic based on Xilinx FPGA technology, enabling custom hardware acceleration, peripherals, and additional processing capabilities. This combination offers a versatile platform for various applications, including embedded systems, signal processing, and hardware-software co-design projects.

Running AI algorithms on the ZedBoard, featuring the dual-core ARM Cortex-A9 processor, presents challenges due to limited processing power and memory constraints typical of embedded systems. Developing AI applications on the ZedBoard requires skills in embedded systems programming and optimization techniques, making it feasible yet demanding, especially for real-time or edge AI applications where efficiency and compact form factor are crucial.

RTEMS 6 SMP is designed to fully leverage multi-core processors, offering robust Symmetric Multiprocessing (SMP) support with enhanced scheduling algorithms to optimize task distribution across cores. It features improved synchronization primitives, including mutexes, semaphores, and condition variables, ensuring efficient and safe concurrent access. The system’s scalability and performance have been optimized to maintain real-time performance with increasing cores, featuring dynamic load balancing to evenly distribute tasks and core affinity for assigning tasks to specific processors. Comprehensive thread safety across all services and APIs guarantees consistent behavior, while efficient interrupt management minimizes latency. Advanced memory management techniques ensure efficient memory utilization, making RTEMS 6 SMP a powerful solution for real-time applications on multi-core embedded systems.

RTEMS 6 SMP benefits from lock-free programming by reducing contention, improving performance, and enhancing scalability across multi-core systems. This approach eliminates the overhead of acquiring and releasing locks, thus increasing system responsiveness and avoiding deadlocks. Lock-free algorithms ensure better fault tolerance and fine-grained parallelism, allowing more threads to progress simultaneously. This results in higher throughput and more predictable real-time performance, making RTEMS 6 SMP a robust and efficient choice for real-time applications on multi-core embedded systems.

Klepsydra AI, on the other hand, a novel approach to on-board artificial intelligence (AI) is presented that is based on state-of-the-art academic research of the well known technique of data pipeline. Algorithm pipelining has seen a resurgence in the high performance computing work due its low power use and high throughput capabilities. The approach presented here provides a very sophisticated threading model combination of pipeline and parallelization techniques applied to deep neural networks (DNN), making these type of AI applications much more efficient and reliable. This new approach has been validated with several DNN models and different computer architectures. The results show that the data processing rate and power saving of the applications increase substantially with respect to standard AI solutions, enabling real AI on harsh environments like onboard computers of satellites or deep-space missions.

As part of an ongoing contract with ESA, Klepsydra team has recently completed the porting of Klepsydra AI to RTEMS6 SMP. This software has been performance benchmarked on the ZedBoard with excellent performance results for two of models included in ESA’s OBPMark-ML. The ZedBoard was previously used for benchmarking Klepsydra AI on PetaLinux as part of an ESA project. The comparison of the new performance results with those obtained in the previous project show the benefit of using Klepsydra AI lock-free parallelisation approach in RTEMS as the performance is approximately 10% better than Klepsydra AI on PetaLinux.

This version of Klepsydra AI for RTEMS 6 SMP will soon be available as a trial for customers. Stay tuned for further updates.