I am a Haskell programmer (I generally implement algorithms in Haskell ) and try to understand HOOPL but I cannot decrypt it. I don’t have a compiler background (currently learning from Coursera and Compilers: Principles, Techniques and Tools), and it would be great if you would offer me a systematic way to get started with understanding the HOOPL library (which is a prerequisite). Let's say I have a little Haskell code on which I want to apply data stream optimization using HOOPL
add :: Int -> Int -> Int
add x y = z where
x' = 1
y' = 1 -- this will be dead code elimination
z = x' + 1
How to write HOOPL code to optimize it. It would be great if you could give a little better example and have mercy on me if I seem stupid.
source
share