Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] Diff of /sml/trunk/src/MLRISC/sparc/ra/sparcRewrite.sml
ViewVC logotype

Diff of /sml/trunk/src/MLRISC/sparc/ra/sparcRewrite.sml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 900, Tue Aug 14 15:10:12 2001 UTC revision 901, Tue Aug 14 19:21:17 2001 UTC
# Line 3  Line 3 
3     structure I = Instr     structure I = Instr
4     structure C = I.C     structure C = I.C
5     structure CB = CellsBasis     structure CB = CellsBasis
6       structure CS = CB.CellSet
7    
8     fun rewriteUse(instr,rs,rt) =     fun rewriteUse(instr,rs,rt) =
9     let fun match r = CB.sameColor(r,rs)     let fun match r = CB.sameColor(r,rs)
# Line 24  Line 25 
25         | I.JMP{r,i,labs,nop} => I.JMP{r=R r,i=O i,labs=labs,nop=nop}         | I.JMP{r,i,labs,nop} => I.JMP{r=R r,i=O i,labs=labs,nop=nop}
26         | I.JMPL{r,i,d,defs,uses,cutsTo,nop,mem} =>         | I.JMPL{r,i,d,defs,uses,cutsTo,nop,mem} =>
27              I.JMPL{r=R r,i=O i,d=d,defs=defs,              I.JMPL{r=R r,i=O i,d=d,defs=defs,
28                     uses=C.CellSet.map {from=rs,to=rt} uses,                     uses=CS.map {from=rs,to=rt} uses,
29                     cutsTo=cutsTo,nop=nop,mem=mem}                     cutsTo=cutsTo,nop=nop,mem=mem}
30         | I.CALL{defs,uses,label,cutsTo,nop,mem} =>         | I.CALL{defs,uses,label,cutsTo,nop,mem} =>
31              I.CALL{defs=defs,uses=C.CellSet.map {from=rs,to=rt} uses,              I.CALL{defs=defs,uses=CS.map {from=rs,to=rt} uses,
32                     label=label,cutsTo=cutsTo,nop=nop,mem=mem}                     label=label,cutsTo=cutsTo,nop=nop,mem=mem}
33         | I.SAVE{r,i,d} => I.SAVE{r=R r,i=O i,d=d}         | I.SAVE{r,i,d} => I.SAVE{r=R r,i=O i,d=d}
34         | I.RESTORE{r,i,d} => I.RESTORE{r=R r,i=O i,d=d}         | I.RESTORE{r,i,d} => I.RESTORE{r=R r,i=O i,d=d}
# Line 59  Line 60 
60         | I.MOVfcc{b,i,d} => I.MOVfcc{b=b,i=i,d=R d}         | I.MOVfcc{b,i,d} => I.MOVfcc{b=b,i=i,d=R d}
61         | I.MOVR{rcond,r,i,d} => I.MOVR{rcond=rcond,r=r,i=i,d=R d}         | I.MOVR{rcond,r,i,d} => I.MOVR{rcond=rcond,r=r,i=i,d=R d}
62         | I.JMPL{r,i,d,defs,uses,cutsTo,nop,mem} =>         | I.JMPL{r,i,d,defs,uses,cutsTo,nop,mem} =>
63              I.JMPL{r=r,i=i,d=R d,defs=C.CellSet.map {from=rs,to=rt} defs,              I.JMPL{r=r,i=i,d=R d,defs=CS.map {from=rs,to=rt} defs,
64                     uses=uses,cutsTo=cutsTo,nop=nop,mem=mem}                     uses=uses,cutsTo=cutsTo,nop=nop,mem=mem}
65         | I.CALL{defs,uses,label,cutsTo,nop,mem} =>         | I.CALL{defs,uses,label,cutsTo,nop,mem} =>
66              I.CALL{defs=C.CellSet.map {from=rs,to=rt} defs,              I.CALL{defs=CS.map {from=rs,to=rt} defs,
67                     uses=uses,label=label,cutsTo=cutsTo,nop=nop,mem=mem}                     uses=uses,label=label,cutsTo=cutsTo,nop=nop,mem=mem}
68         | I.SAVE{r,i,d} => I.SAVE{r=r,i=i,d=R d}         | I.SAVE{r,i,d} => I.SAVE{r=r,i=i,d=R d}
69         | I.RESTORE{r,i,d} => I.RESTORE{r=r,i=i,d=R d}         | I.RESTORE{r,i,d} => I.RESTORE{r=r,i=i,d=R d}
# Line 91  Line 92 
92         | I.FMOVfcc{sz,b,r,d} => I.FMOVfcc{sz=sz,b=b,r=R r,d=R d}         | I.FMOVfcc{sz,b,r,d} => I.FMOVfcc{sz=sz,b=b,r=R r,d=R d}
93         | I.JMPL{r,i,d,defs,uses,cutsTo,nop,mem} =>         | I.JMPL{r,i,d,defs,uses,cutsTo,nop,mem} =>
94             I.JMPL{r=r,i=i,d=d,defs=defs,             I.JMPL{r=r,i=i,d=d,defs=defs,
95                    uses=C.CellSet.map {from=rs,to=rt} uses,                    uses=CS.map {from=rs,to=rt} uses,
96                    cutsTo=cutsTo,nop=nop,mem=mem}                    cutsTo=cutsTo,nop=nop,mem=mem}
97         | I.CALL{defs,uses,label,cutsTo,nop,mem} =>         | I.CALL{defs,uses,label,cutsTo,nop,mem} =>
98             I.CALL{defs=defs,uses=C.CellSet.map {from=rs,to=rt} uses,             I.CALL{defs=defs,uses=CS.map {from=rs,to=rt} uses,
99                    label=label,cutsTo=cutsTo,nop=nop,mem=mem}                    label=label,cutsTo=cutsTo,nop=nop,mem=mem}
100         | I.FCOPY{src,dst,tmp,impl} =>         | I.FCOPY{src,dst,tmp,impl} =>
101             I.FCOPY{src=map R src,dst=dst,tmp=tmp,impl=impl}             I.FCOPY{src=map R src,dst=dst,tmp=tmp,impl=impl}
# Line 120  Line 121 
121         | I.FMOVicc{sz,b,r,d} => I.FMOVicc{sz=sz,b=b,r=r,d=R d}         | I.FMOVicc{sz,b,r,d} => I.FMOVicc{sz=sz,b=b,r=r,d=R d}
122         | I.FMOVfcc{sz,b,r,d} => I.FMOVfcc{sz=sz,b=b,r=r,d=R d}         | I.FMOVfcc{sz,b,r,d} => I.FMOVfcc{sz=sz,b=b,r=r,d=R d}
123         | I.JMPL{r,i,d,defs,uses,cutsTo,nop,mem} =>         | I.JMPL{r,i,d,defs,uses,cutsTo,nop,mem} =>
124             I.JMPL{r=r,i=i,d=d,defs=C.CellSet.map {from=rs,to=rt} defs,             I.JMPL{r=r,i=i,d=d,defs=CS.map {from=rs,to=rt} defs,
125                    uses=uses,cutsTo=cutsTo,nop=nop,mem=mem}                    uses=uses,cutsTo=cutsTo,nop=nop,mem=mem}
126         | I.CALL{defs,uses,label,cutsTo,nop,mem} =>         | I.CALL{defs,uses,label,cutsTo,nop,mem} =>
127             I.CALL{defs=C.CellSet.map {from=rs,to=rt} defs,             I.CALL{defs=CS.map {from=rs,to=rt} defs,
128                    uses=uses,label=label,cutsTo=cutsTo,nop=nop,mem=mem}                    uses=uses,label=label,cutsTo=cutsTo,nop=nop,mem=mem}
129         | I.FCOPY{src,dst,tmp,impl} =>         | I.FCOPY{src,dst,tmp,impl} =>
130             I.FCOPY{src=src,dst=map R dst,tmp=ea tmp,impl=impl}             I.FCOPY{src=src,dst=map R dst,tmp=ea tmp,impl=impl}

Legend:
Removed from v.900  
changed lines
  Added in v.901

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0