Adds a crude at&t assembly parser to resolve constants
authorMoritz Angermann <moritz.angermann@gmail.com>
Wed, 21 Feb 2018 02:33:59 +0000 (10:33 +0800)
committerMoritz Angermann <moritz.angermann@gmail.com>
Wed, 21 Feb 2018 10:03:34 +0000 (18:03 +0800)
commit31c348093894e748d3e1eff3f9b1db2f30c58aa5
treef9cfe6f5c8c77a391e653c4526dd44db1e1b21d8
parent738f3666c878ee9e79c3d5e819ef8b3460288edf
Adds a crude at&t assembly parser to resolve constants

Our current approach is taken from autoconf, and requires a binary search to
find constants.  This is not only very time consuming but also breaks when the
compiler fails to recognize an expression as constant.  As such we ask the
compiler to produce assembly, crudely parse that assembly and try to extract the
constant directly from the generated assembly.
ATTParser.hs [new file with mode: 0644]
CrossCodegen.hs
Flags.hs
Main.hs
hsc2hs.cabal