Changes by: Brian Emre Aydemir (baydemir at cis.upenn.edu)
Date: 2003-02-28 23:16:39 -0800 (Fri, 28 Feb 2003)
Revision: 4150
Log message:
In an effort to avoid my actual homework, I decided to take a look
at M_dead, M_inline, and M_prog.
-------------------------------------------------
M_dead: Fixed a few cut-and-paste typos in the comments. My only
other observation is that it seems that something like
LetAtom{AtomBinop{DivOp; AtomInt[1]; AtomInt[0]}; v. 'e} <--> 'e
is allowed. Which might be fine, depending on what the evaluation
order is and how strictly you want to preserve the semantics of
the program.
-------------------------------------------------
M_inline: Fixed even more cut-and-paste typos. Before,
AtomBinop{SubOp; AtomInt[i:n]; AtomInt[j:n]}
could have been folded using meta_diff, meta_prod, or meta_quot.
I decided that perhaps someone intended to fold together
multiplications and divisions together, instead of specifying
three separate ways (two of which made no sense) to fold a
subtraction...
-------------------------------------------------
M_prog: Fixed a few more cut-and-paste typos in comments. Also
fixed a cut-and-paste typo present where fundecl_if_false is added
to the prog resource (the term to match against was the same as in
the fundecl_if_true case, which seemed bogus). The other change
is I added a rewrite fundef_let_pair which swaps FunDef with
LetPair. This might be wrong, but I couldn't think of any reason
why you wouldn't want to have that rule, or why that rule would be
incorrect.
I suppose if I have more time on my hands, I'll try to take a look
at closure conversion and CPS conversion, and maybe even pay
attention to the discussions about this stuff. (-:
Changes | Path |
+3 -3 | metaprl/theories/experimental/compile/m_dead.ml |
+5 -5 | metaprl/theories/experimental/compile/m_inline.ml |
+6 -2 | metaprl/theories/experimental/compile/m_prog.ml |