x86m2 is a complete Modula-2 compiler for GNU/Linux which obeys the 2nd Edition Programming in Modula-2 by N. Wirth. It generates code for the 8086 and 80?86 families and the is32 abstract machine. In particular it can generate pipelined Pentium code with detailed timing calculations presented in comments in the assembly language. It will bootstrap itself using a modified version of p2c 1.20 (which comes with the source distribution). x86m2 generates GDB debugging information and error messages are emacs compatible.
x86m2 is covered by the GNU CopyLeft license version 2. Source code is available from github:
https://github.com/gaiusm/x86m2
x86m2 manual page
Release notes
Note x86m2 can only be built on a 32 bit x86 machine. Download the sources:
$ git clone
https://github.com/gaiusm/x86m2
$ mkdir build-x86m2
$ cd build-x86m2
$ ../x86m2/configure
$ make all
$ sudo make install
Fixed an atan bug and introduced EXPORT UNQUALIFIED to allow user to create definition modules for foreign language libraries. This enables users to interface to C libraries without having to write wrapper libraries. See libm.def for a brief example.
Finally added syntax error recovery. The ASM syntax has changed to the GNU syntax. Note that not all the GNU options are implemented, floating point operands to ASM statements are not supported.
Please email gaiusmod2@gmail.com with any bug reports, suggestions and grumbles.