Modified combinators and also slightly the transformation.

olaf: Wed Mar 28 20:33:58 CEST 2001 Update of /usr/src/master/nhc/src/prelude/PreludeDebug In directory hinken:/tmp/cvs-serv11925/src/prelude/PreludeDebug Modified Files: PreludeDebug.hs Log Message: Modified combinators and also slightly the transformation. Moved introduction of Sat's from functions side (fun?, prim?) to application side (ap?, rap?). - Removes previous bug that transformed program was too eager, e.g. in (True || h True) the application of h was evaluated. - Creation of Sat and App? trace nodes now next to each other. Integration of writing a Sat and an App? now straightforward. - Subsequent RHS-optimisation possible. Corrected bug in transformation of let. Expression after in is only in projective context if whole let is in projective context. This bug could lead to missing Hidden node in trusted code and too eager evaluation when the RHS-optimisation is used. Introduced separate combinator trif for if in projective context. The use of original tif could lead to too eager evaluation (never observed) and this would have become worse with the RHS-optimisation. RHS-optimisation: If an application (or if) is in projective context, then it doesn't need a Sat, because the application node only serves as a parent, but is never pointed to from an App? as an argument. So modified rap? and trif to not produce Sats. This halfs the number of SatCs and reduces runtime by ~10%.
participants (1)
-
olaf@sparud.net