LLDSAL: a low-level domain-specific aspect language for dynamic code-generation and program modification

  • Authors:
  • Mathias Payer;Boris Bluntschli;Thomas R. Gross

  • Affiliations:
  • ETH Zurich, Zurich, Switzerland;ETH Zurich, Zurich, Switzerland;ETH Zurich, Zurich, Switzerland

  • Venue:
  • Proceedings of the seventh workshop on Domain-Specific Aspect Languages
  • Year:
  • 2012

Quantified Score

Hi-index 0.00

Visualization

Abstract

Dynamic binary translation frameworks enable late modifications of binary programs. The binary translator needs to generate dynamic code at runtime for trampolines, translated control flow instructions, additional runtime checks, and lookups. The code must be efficient, low-level, and cannot rely on any calling conventions. A Low-Level Domain Specific Aspect Language (LLDSAL) is a natural fit to specify dynamically generated code snippets at compile time. The code is then generated by the translator on demand at runtime and integrated into the translated application code. The LLDSAL is tightly coupled to a host language and provides full access to data structures of the host language. The syntax of the LLDSAL is comparable to inline assembler but the code is generated at runtime. The advantage of an LLDSAL that generates dynamic code is that references to runtime data structures are encoded directly in the machine code without indirections. Most parameters in the generated low-level aspects can be hard coded to reduce the number of passed parameters. This paper presents the design and implementation of such an LLDSAL. The LLDSAL is integrated into a binary translation framework that enforces application security.