Skip to content
bmeurer edited this page Dec 14, 2011 · 11 revisions

This repository contains my work on a new ARM backend for the OCaml native code compiler, currently based on the 3.12.1 release. Compared to the old ARM backend, this one does the following:

  • Support for both software and hardware floating-point (VFPv3).
  • Properly supports interworking with Thumb/Thumb-2 code for both OCaml and C code.
  • Supports dynamic linking and large memory models.
  • Optional support for position-independent code via a command line option -fPIC. This is disabled by default and not required for natdynlink.
  • Can emit both ARM and Thumb-2 code, with avg. code size savings of 27% for Thumb-2 (quite close the optimal 30% advertised by ARM Ltd.).
  • Supports both AAPCS (armel) as well as extended VFP calling conventions (armhf).
  • Recognizes several special ARM instructions to reduce code size and latency.
  • Uses standard ARM EABI runtime functions instead of relying on GCC internals.
  • Supports exception backtraces.

Clone this wiki locally