Compile-Time Malloc: Static Analysis and Replacement of Formerly Dynamic Memory Allocations using LLVM and the ARA Framework.

The LibrePilot quadrocopter firmware is based on the FreeRTOS real-time operating system. It consists of multiple tasks that perform a lot of allocations at boot time. These are the same allocations on every boot, ever and ever again.

With ARA, a whole-system analyzer and compiler, we already have the tool to perform a static analysis and optimization of the LibrePilot application. Your task is it to extend ARA to analyze the malloc call and replace it with static memory where possible. Therefore, the analysis has to prove that no freeing of the memory occurs. Your approach should be implemented in an application independent way but evaluated on the LibrePilot firmware.

Next to the analysis and implementation your task is to evaluate the approach towards memory consumption and start-up time consumption.

Topics covered by this thesis:
whole system compiler, static analysis, LLVM, C++, Python

Further Reading

LibrePilot website: https://www.librepilot.org

OSPERT Workshop B
ARA: Automatic Instance-Level Analysis in Real-Time Systems
Gerion Entrup, Benedikt Steinmeier, Christian DietrichProceedings of the 15th Annual Workshop on Operating Systems Platforms for Embedded Real-Time Applications (OSPERT '19)2019.
PDF [BibTex]
OSPERT Workshop B Best Paper Award
Levels of Specialization in Real-Time Operating Systems
Björn Fiedler, Gerion Entrup, Christian Dietrich, Daniel LohmannProceedings of the 14th Annual Workshop on Operating Systems Platforms for Embedded Real-Time Applications (OSPERT '18)2018Best Paper Award.
PDF [BibTex]