Brussels / 1 & 2 February 2025

schedule

Easier API Interoperability: writing a bindings Generator to C/C++ with Coccinelle


Software developers using high-level programming languages often find they need to call procedures from specialized libraries only offering a C or C++ API. While most languages expose mechanisms for calling C functions, writing the bindings for potentially hundreds of procedures remains menial work: tedious and error-prone. Is there a better way? In this talk we take you on a journey of writing library bindings for BLIS, a large C library for linear algebra operations. Using Coccinelle, a powerful code matching and transformation system, we present how a handful of semantic patches (augmented by little Python scripts) can cover the full BLIS library making it available to modern Fortran.

Speakers

Michele Martone
Ivan Pribec