commit 5f875c3261728537c0bacae50f76734547f43508
parent 8ae9f786cbc1173e2530cf86b222549ac0106670
Author: Quentin Carbonneaux <quentin.carbonneaux@yale.edu>
Date: Tue, 3 Nov 2015 17:01:12 -0500
update minic to the new IR
Diffstat:
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/minic/minic.y b/minic/minic.y
@@ -192,7 +192,7 @@ psymb(Symb s)
void
sext(Symb *s)
{
- fprintf(of, "\t%%t%d =l sext ", tmp);
+ fprintf(of, "\t%%t%d =l extsw ", tmp);
psymb(*s);
fprintf(of, "\n");
s->t = Tmp;
@@ -257,9 +257,12 @@ Scale:
void
load(Symb d, Symb s)
{
+ char t;
+
fprintf(of, "\t");
psymb(d);
- fprintf(of, " =%c load ", irtyp(d.ctyp));
+ t = irtyp(d.ctyp);
+ fprintf(of, " =%c load%c ", t, t);
psymb(s);
fprintf(of, "\n");
}