Repository logo
 

Cinnamon: A Domain-Specific Language for Binary Profiling and Monitoring

Accepted version
Peer-reviewed

Type

Conference Object

Change log

Authors

Arif, M 
Zhou, R 
Ho, HM 
Jones, TM 

Abstract

Binary instrumentation and rewriting frameworks provide a powerful way of implementing custom analysis and transformation techniques for applications ranging from performance profiling to security monitoring. However, using these frameworks to write even simple analyses and transformations is non-trivial. Developers often need to write framework-specific boilerplate code and work with low-level and complex programming details. This not only results in hundreds (or thousands) of lines of code, but also leaves significant room for error.

To address this, we introduce Cinnamon, a domain-specific language designed to write programs for binary profiling and monitoring. Cinnamon’s abstractions allow the programmer to focus on implementing their technique in a platform-independent way, without worrying about complex lower-level details. Programmers can use these abstractions to perform analysis and instrumentation at different locations and granularity levels in the binary. The flexibility of Cinnamon also enables its programs to be mapped to static, dynamic or hybrid analysis and instrumentation approaches. As a proof of concept, we target Cinnamon to three different binary frameworks by implementing a custom Cinnamon to C/C++ compiler and integrating the generated code within these frameworks. We further demonstrate the ability of Cinnamon to express a range of profiling and monitoring tools through different use-cases.

Description

Keywords

Domain-Specific language, Profiling, Binary analysis and instrumentation

Journal Title

CGO 2021 - Proceedings of the 2021 IEEE/ACM International Symposium on Code Generation and Optimization

Conference Name

2021 IEEE/ACM International Symposium on Code Generation and Optimization (CGO)

Journal ISSN

2164-2397

Volume Title

Publisher

IEEE

Rights

All rights reserved
Sponsorship
Engineering and Physical Sciences Research Council (EP/P020011/1)
Relationships
Is supplemented by: