adds an option to interleave the generated code with snippets from the original source

Lines from the original source are outputted as comments next to line directives.
Hopefully, this will make debugging codegen problems easier.

Other changes:
The frame setup code now uses a single-line C macro. My motivation was to reduce
the noise in the generated output and make it easier to step over the boiler-plate
code, but counter-intuitively this also improved the overall compilation speed a
little bit so I applied the same treatment to line tracking too (this reduces the size of
the generated files and the explanation is that probably the I/O overhead dominates
the macro expansion costs).
This commit is contained in:
Zahary Karadjov 2012-12-02 20:36:29 +02:00
commit d0edb1826b
9 changed files with 149 additions and 85 deletions

View file

@ -52,6 +52,8 @@ Advanced options:
(Nimrod, mangled) identifier pairs
--project document the whole project (doc2)
--lineDir:on|off generation of #line directive on|off
--embedsrc embeds the original source code as comments
in the generated output
--threadanalysis:on|off turn thread analysis on|off
--tlsEmulation:on|off turn thread local storage emulation on|off
--taintMode:on|off turn taint mode on|off