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/x86/mltree/x86.sml
ViewVC logotype

Diff of /sml/trunk/src/MLRISC/x86/mltree/x86.sml

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

revision 469, Wed Nov 10 22:42:52 1999 UTC revision 475, Wed Nov 10 22:59:58 1999 UTC
# Line 6  Line 6 
6  functor X86  functor X86
7    (structure X86Instr : X86INSTR    (structure X86Instr : X86INSTR
8     structure X86MLTree : MLTREE     structure X86MLTree : MLTREE
9       where Region = X86Instr.Region       sharing X86MLTree.Region = X86Instr.Region
10         and Constant = X86Instr.Constant       sharing X86MLTree.Constant = X86Instr.Constant
        and type cond = MLTreeBasis.cond  
        and type fcond = MLTreeBasis.fcond  
11     val tempMem : X86Instr.operand) : MLTREECOMP =     val tempMem : X86Instr.operand) : MLTREECOMP =
12  struct  struct
13    structure T = X86MLTree    structure T = X86MLTree
# Line 316  Line 314 
314        in  if isImmediate opnd1 andalso isImmediate opnd2 then        in  if isImmediate opnd1 andalso isImmediate opnd2 then
315              cmpAndBranch(cc, moveToReg opnd1, opnd2)              cmpAndBranch(cc, moveToReg opnd1, opnd2)
316            else if isImmediate opnd1 then            else if isImmediate opnd1 then
317              cmpAndBranch(MLTreeUtil.swapCond cc, opnd2, opnd1)              cmpAndBranch(T.Util.swapCond cc, opnd2, opnd1)
318            else if isImmediate opnd2 then            else if isImmediate opnd2 then
319              cmpAndBranch(cc, opnd1, opnd2)              cmpAndBranch(cc, opnd1, opnd2)
320            else case (opnd1, opnd2)            else case (opnd1, opnd2)
# Line 623  Line 621 
621          (case fexp          (case fexp
622            of T.FABS(_, t) => (emit(I.FLD(leafEA t)); mark(I.FUNARY(I.FABS),an))            of T.FABS(_, t) => (emit(I.FLD(leafEA t)); mark(I.FUNARY(I.FABS),an))
623             | T.FNEG(_, t) => (emit(I.FLD(leafEA t)); mark(I.FUNARY(I.FCHS),an))             | T.FNEG(_, t) => (emit(I.FLD(leafEA t)); mark(I.FUNARY(I.FCHS),an))
624             | T.CVTI2F(_,_,t) => cvti2d(t,an)             | T.CVTI2F(_,_,_,t) => cvti2d(t,an)
625           (*esac*))           (*esac*))
626        | gencode(fexp, UNARY(_, su), an) = let        | gencode(fexp, UNARY(_, su), an) = let
627            fun doit(oper, t) = (gencode(t, su, []); mark(I.FUNARY(oper),an))            fun doit(oper, t) = (gencode(t, su, []); mark(I.FUNARY(oper),an))

Legend:
Removed from v.469  
changed lines
  Added in v.475

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