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

SCM Repository

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

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

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

revision 3193, Mon Apr 27 21:19:16 2015 UTC revision 3194, Wed May 13 02:57:42 2015 UTC
# Line 264  Line 264 
264    
265  val (e1',params',args',code,fieldset)=  rewriteOps("add",e1,params,index,[],args,fieldset,flag)  val (e1',params',args',code,fieldset)=  rewriteOps("add",e1,params,index,[],args,fieldset,flag)
266  fun pb es=String.concatWith "\n\n\t-*-" (List.map P.printbody es)  fun pb es=String.concatWith "\n\n\t-*-" (List.map P.printbody es)
267  val _ =print("\n****Inside Add:"^Int.toString(length index)^"\n -"^ pb e1 ^"----- newbies\n-"^ pb e1')  (*)val _ =print("\n****Inside Add:"^Int.toString(length index)^"\n -"^ pb e1 ^"----- newbies\n-"^ pb e1')*)
268    
269  val body =E.Add e1'  val body =E.Add e1'
270  val einapp= rewriteOrig(y,body,params',index,[],args')  val einapp= rewriteOrig(y,body,params',index,[],args')
# Line 347  Line 347 
347              | E.Sum(_,E.Probe(E.Conv _,_))    => default              | E.Sum(_,E.Probe(E.Conv _,_))    => default
348              | E.Sum(sx,E.Prod e1)     => handleSumProd(y,e1,params,index,sx,args,fieldset,flag)              | E.Sum(sx,E.Prod e1)     => handleSumProd(y,e1,params,index,sx,args,fieldset,flag)
349              | E.Sum(sx,E.Delta d)     => handleSumProd(y,[E.Delta d],params,index,sx,args,fieldset,flag)              | E.Sum(sx,E.Delta d)     => handleSumProd(y,[E.Delta d],params,index,sx,args,fieldset,flag)
350                | E.Sum(sx,E.Tensor _)    => default
351              | E.Sum(sx,_)             => err(" summation not distributed:"^str)              | E.Sum(sx,_)             => err(" summation not distributed:"^str)
352              | E.Add e1                => handleAdd(y,e1,params,index,args,fieldset,flag)              | E.Add e1                => handleAdd(y,e1,params,index,args,fieldset,flag)
353              | E.Prod e1               => handleProd(y,e1,params,index,args,fieldset,flag)              | E.Prod e1               => handleProd(y,e1,params,index,args,fieldset,flag)
# Line 381  Line 382 
382          | itercode(e1::newbies,rest,code,cnt)=let          | itercode(e1::newbies,rest,code,cnt)=let
383              val ((einapp3,code3),_) = split(e1,fieldset,numFlag)              val ((einapp3,code3),_) = split(e1,fieldset,numFlag)
384              val (rest4,code4)=itercode(code3,[],[],cnt+1)              val (rest4,code4)=itercode(code3,[],[],cnt+1)
385                  val _ =print(String.concat[printEINAPP(e1),"\n\t===>\n",printEINAPP(einapp3),"\nand\n",(String.concatWith",\n\t"(List.map printEINAPP (code4@rest4)))])                  val _ =testp [printEINAPP(e1),"\n\t===>\n",printEINAPP(einapp3),"\nand\n",(String.concatWith",\n\t"(List.map printEINAPP (code4@rest4)))]
386              in              in
387                  itercode(newbies,rest@[einapp3],code4@( rest4)@code,cnt+2)                  itercode(newbies,rest@[einapp3],code4@( rest4)@code,cnt+2)
388              end              end

Legend:
Removed from v.3193  
changed lines
  Added in v.3194

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