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

SCM Repository

[diderot] Diff of /branches/vis15/src/compiler/high-to-mid/high-to-mid.sml
ViewVC logotype

Diff of /branches/vis15/src/compiler/high-to-mid/high-to-mid.sml

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

revision 3990, Fri Jun 17 21:27:47 2016 UTC revision 3991, Fri Jun 17 21:28:31 2016 UTC
# Line 172  Line 172 
172                | SrcOp.MapClamp ty => assign (DstOp.MapClamp(cvtTy ty))                | SrcOp.MapClamp ty => assign (DstOp.MapClamp(cvtTy ty))
173                | SrcOp.Lerp ty => assign (DstOp.Lerp(cvtTy ty))                | SrcOp.Lerp ty => assign (DstOp.Lerp(cvtTy ty))
174                | SrcOp.Zero ty => assign (DstOp.Zero(cvtTy ty))                | SrcOp.Zero ty => assign (DstOp.Zero(cvtTy ty))
 (* QUESTION: why not create the EINAPP when translating from SimpleAST to HighIR? *)  
               | SrcOp.TensorSlice(SrcTy.TensorTy argTy, mask) => let  
                 (* extract the integer indices from the mask *)  
                   val args' = List.mapPartial Fn.id mask  
                   val mask' = List.map Option.isSome mask  
                   val DstTy.TensorTy rstTy = DstIR.Var.ty y  
                   val rator = MkOperators.slice (argTy, mask', args', rstTy)  
                   val a = Env.renameList(env, args)  
                   in  
                     [(y, DstIR.EINAPP(rator, a))]  
                   end  
175                | SrcOp.TensorIndex(ty, shp) => assign (DstOp.TensorIndex(cvtTy ty, shp))                | SrcOp.TensorIndex(ty, shp) => assign (DstOp.TensorIndex(cvtTy ty, shp))
176                | SrcOp.Select(ty, i) => assign (DstOp.Select(cvtTy ty, i))                | SrcOp.Select(ty, i) => assign (DstOp.Select(cvtTy ty, i))
177                | SrcOp.Subscript(ty as SrcTy.SeqTy _) => assign (DstOp.Subscript(cvtTy ty))                | SrcOp.Subscript(ty as SrcTy.SeqTy _) => assign (DstOp.Subscript(cvtTy ty))

Legend:
Removed from v.3990  
changed lines
  Added in v.3991

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