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/compiler/CodeGen/x86/x86MLTreeExtComp.sml
ViewVC logotype

Diff of /sml/trunk/src/compiler/CodeGen/x86/x86MLTreeExtComp.sml

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

revision 1002, Fri Nov 30 17:11:33 2001 UTC revision 1003, Fri Dec 7 02:45:32 2001 UTC
# Line 34  Line 34 
34     fun compileFext (TS.REDUCER{reduceFexp, emit, ...}:reducer) = let     fun compileFext (TS.REDUCER{reduceFexp, emit, ...}:reducer) = let
35       fun comp{e=(64, fexp), fd:CB.cell, an:T.an list} = let       fun comp{e=(64, fexp), fd:CB.cell, an:T.an list} = let
36             fun trig(f, foper) =             fun trig(f, foper) =
37               (reduceFexp f; emit(I.FUNARY foper, an))               (reduceFexp f; emit(I.funary foper, an))
38           in           in
39             case fexp             case fexp
40             of Ext.FSINE f => trig(f, I.FSIN)             of Ext.FSINE f => trig(f, I.FSIN)
41              | Ext.FCOSINE f => trig(f, I.FCOS)              | Ext.FCOSINE f => trig(f, I.FCOS)
42              | Ext.FTANGENT f =>              | Ext.FTANGENT f =>
43                 (trig(f, I.FPTAN);                 (trig(f, I.FPTAN);
44                  emit(I.FSTPL(I.ST(C.ST 0)), [])                  emit(I.fstpl(I.ST(C.ST 0)), [])
45                 )                 )
46           end           end
47         | comp _ = MLRiscErrorMsg.impossible "compileFext"         | comp _ = MLRiscErrorMsg.impossible "compileFext"
# Line 56  Line 56 
56                         Ext.FSINE f => (I.FSIN, f)                         Ext.FSINE f => (I.FSIN, f)
57                       | Ext.FCOSINE f => (I.FCOS, f)                       | Ext.FCOSINE f => (I.FCOS, f)
58                       | Ext.FTANGENT f => (I.FPTAN, f)                       | Ext.FTANGENT f => (I.FPTAN, f)
59           in  emit(I.FUNOP{fsize=I.FP64,           in  emit(I.funop{fsize=I.FP64,
60                            unOp=unOp,src=Freg(reduceFexp f),dst=Freg fd}, an)                            unOp=unOp,src=Freg(reduceFexp f),dst=Freg fd}, an)
61           end           end
62         | fastComp _ = MLRiscErrorMsg.impossible "compileFext"         | fastComp _ = MLRiscErrorMsg.impossible "compileFext"

Legend:
Removed from v.1002  
changed lines
  Added in v.1003

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