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/probe-ein.sml
ViewVC logotype

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

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

revision 3977, Wed Jun 15 19:06:30 2016 UTC revision 3978, Wed Jun 15 19:07:40 2016 UTC
# Line 162  Line 162 
162            val s = Kernel.support h            val s = Kernel.support h
163          (* creating summation Index *)          (* creating summation Index *)
164            val vs = List.tabulate (dim, fn i => (i +sx))            val vs = List.tabulate (dim, fn i => (i +sx))
165            val esum = List.map (fn i => (E.V i, 1-s, s)) vs            val esum = List.map (fn i => (i, 1-s, s)) vs
166          (* represent image in ein expression with tensor *)          (* represent image in ein expression with tensor *)
167            val imgexp= E.Img(Vidnew, alpha, List.map (fn i=> E.Value i)  vs, s, E.None)            val imgexp= E.Img(Vidnew, alpha, List.map (fn i=> E.Value i)  vs, s, E.None)
168          (* create load voxel operator for image *)          (* create load voxel operator for image *)
# Line 191  Line 191 
191      *)      *)
192      fun getsumshift ([], n) = n      fun getsumshift ([], n) = n
193        | getsumshift (sx, n) = let        | getsumshift (sx, n) = let
194            val (E.V v, _, _) = List.hd(List.rev sx)            val (v, _, _) = List.hd(List.rev sx)
195            in            in
196              v+1              v+1
197            end            end
# Line 213  Line 213 
213              formBody(E.Sum(sx, E.Opn(E.Prod, exp)))              formBody(E.Sum(sx, E.Opn(E.Prod, exp)))
214            end            end
215    
216    (* FIXME: what does this do??? *)      (* arrangeBody - function changes the ordering of multiplication
217        * to match vis12 branch and pass regression tests *)
218      fun arrangeBody (body, Ps, newsx, exp) = (case body      fun arrangeBody (body, Ps, newsx, exp) = (case body
219             of E.Sum(sx, E.Probe _ ) => (true, multiPs(Ps, sx@newsx,exp))             of E.Sum(sx, E.Probe _ ) => (true, multiPs(Ps, sx@newsx,exp))
220              | E.Sum(sx, E.Opn(E.Prod,[eps0,E.Probe _ ])) =>              | E.Sum(sx, E.Opn(E.Prod,[eps0,E.Probe _ ])) =>

Legend:
Removed from v.3977  
changed lines
  Added in v.3978

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