Papers for

legacy systems maintainers

Papers whose findings have a practical use for this group, as judged from the abstract. Open a paper to read what it means in practice.

C to Rust translation keeps macros to preserve original code structure

Lifting the Preprocessor with Oxidize: Structure-Preserving C-to-Rust Translation (Technical Report)

Abstract: This technical report accompanies our EuroSys 2027 paper "Lifting the Preprocessor with Oxidize: Structure-Preserving C-to-Rust Translation" (DOI 10.1145/3842654.3848533). Oxidize is a C-to-Rust translator that retains C macros as Rust macros instead of expanding them away, so that the translated code keeps the abstractions its developers wrote. The report collects material the paper cites but has no room for: the translator's intermediate representation, pass structure and back-end emission; the details of macro typing through helper traits and the generic cast macro; the sources and pinned revisions of the nine evaluated C codebases; the per-codebase macro population and how macros are attributed to classes; a roadmap from structure-preserving translation toward safe Rust; the performance overhead study and its methodology; and the configuration and prompt used for the LLM-based baselines.

Thu 24 SeptProgramming Languages
The gist
Translating C code to Rust usually loses some parts like macros, which are shortcuts that programmers use to simplify their code. The authors created Oxidize, a tool that translates C to Rust while keeping these macros intact as Rust macros, so the original code’s structure and intent are preserved. This makes it easier for developers to maintain and understand the translated code. The report includes technical details, evaluations on real C projects, and performance studies to back up this approach.
Open → 2609.30062v1