Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/charisee/src/compiler/low-il/check-low-il.sml
ViewVC logotype

Diff of /branches/charisee/src/compiler/low-il/check-low-il.sml

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

revision 2826, Mon Nov 10 21:06:46 2014 UTC revision 2827, Tue Nov 11 00:18:38 2014 UTC
# Line 77  Line 77 
77              | Op.Transform info => let              | Op.Transform info => let
78                  val dim = ImageInfo.dim info                  val dim = ImageInfo.dim info
79                  in                  in
80                  (Ty.TensorTy[dim,dim], [Ty.StringTy])                  (Ty.TensorTy[dim,dim], [Ty.ImageTy info])
81                  end                  end
82              | Op.Translate info  => let              | Op.Translate info  => let
83                  val dim = ImageInfo.dim info                  val dim = ImageInfo.dim info
84                  in                  in
85                  (Ty.TensorTy[dim], [Ty.StringTy])                  (Ty.TensorTy[dim], [Ty.ImageTy info])
86                  end                  end
87                  (*real or int argument?*)                  (*real or int argument?*)
88              | Op.IndexTensor ( _ ,_, Ty.TensorTy argTy)              | Op.IndexTensor ( _ ,_, Ty.TensorTy argTy)
# Line 109  Line 109 
109    
110          (*imgAddr:  shape of IMG, dim, Args:  dim number of ints*)          (*imgAddr:  shape of IMG, dim, Args:  dim number of ints*)
111          | Op.imgAddr(info , ty,dim)=> let          | Op.imgAddr(info , ty,dim)=> let
112              val arg=List.tabulate(dim+1,fn _=>Ty.intTy)              val arg=List.tabulate(dim,fn _=>Ty.intTy)
113               in (Ty.intTy, arg)              val ptrTy=Ty.AddrTy info
114                 in (ptrTy, [ptrTy]@arg)
115              end              end
116    
117          (*imgLoad, dim, int-2*support:Args:addrVar*)          (*imgLoad, dim, int-2*support:Args:addrVar*)
118          | Op.imgLoad (info ,i,j)=>(Ty.TensorTy([j]), [Ty.intTy])          | Op.imgLoad (info ,i,j)=>(Ty.TensorTy([j]), [Ty.AddrTy info])
119          | Op.baseAddr _ =>(Ty.IntTy,[Ty.StringTy])          | Op.baseAddr info =>(Ty.AddrTy info,[Ty.ImageTy info])
120    
121             | Op.Kernel _ => (Ty.KernelTy, [])             | Op.Kernel _ => (Ty.KernelTy, [])
122              | _ => raise Fail("sigOf: In low-IL Does not have: invalid operator " ^ Op.toString rator)              | _ => raise Fail("sigOf: In low-IL Does not have: invalid operator " ^ Op.toString rator)

Legend:
Removed from v.2826  
changed lines
  Added in v.2827

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