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

SCM Repository

[diderot] Diff of /branches/vis12/src/compiler/mid-il/mid-il.sml
ViewVC logotype

Diff of /branches/vis12/src/compiler/mid-il/mid-il.sml

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

revision 1688, Wed Jan 25 13:36:13 2012 UTC revision 1689, Wed Jan 25 14:55:43 2012 UTC
# Line 70  Line 70 
70        | Select of ty * int        | Select of ty * int
71        | Index of ty * int        | Index of ty * int
72        | Subscript of ty        | Subscript of ty
73          | MkDynamic of ty * int
74          | Append of ty
75          | Prepend of ty
76          | Concat of ty
77        | Ceiling of int        | Ceiling of int
78        | Floor of int        | Floor of int
79        | Round of int        | Round of int
# Line 123  Line 127 
127        | resultArity (Select _) = 1        | resultArity (Select _) = 1
128        | resultArity (Index _) = 1        | resultArity (Index _) = 1
129        | resultArity (Subscript _) = 1        | resultArity (Subscript _) = 1
130          | resultArity (MkDynamic _) = 1
131          | resultArity (Append _) = 2
132          | resultArity (Prepend _) = 2
133          | resultArity (Concat _) = 2
134        | resultArity (Ceiling _) = 1        | resultArity (Ceiling _) = 1
135        | resultArity (Floor _) = 1        | resultArity (Floor _) = 1
136        | resultArity (Round _) = 1        | resultArity (Round _) = 1
# Line 176  Line 184 
184        | arity (Select _) = 1        | arity (Select _) = 1
185        | arity (Index _) = 1        | arity (Index _) = 1
186        | arity (Subscript _) = 2        | arity (Subscript _) = 2
187          | arity (MkDynamic _) = 1
188          | arity (Append _) = 1
189          | arity (Prepend _) = 1
190          | arity (Concat _) = 1
191        | arity (Ceiling _) = 1        | arity (Ceiling _) = 1
192        | arity (Floor _) = 1        | arity (Floor _) = 1
193        | arity (Round _) = 1        | arity (Round _) = 1
# Line 229  Line 241 
241        | same (Select(a0,a1), Select(b0,b1)) = samety(a0, b0) andalso sameint(a1, b1)        | same (Select(a0,a1), Select(b0,b1)) = samety(a0, b0) andalso sameint(a1, b1)
242        | same (Index(a0,a1), Index(b0,b1)) = samety(a0, b0) andalso sameint(a1, b1)        | same (Index(a0,a1), Index(b0,b1)) = samety(a0, b0) andalso sameint(a1, b1)
243        | same (Subscript(a0), Subscript(b0)) = samety(a0, b0)        | same (Subscript(a0), Subscript(b0)) = samety(a0, b0)
244          | same (MkDynamic(a0,a1), MkDynamic(b0,b1)) = samety(a0, b0) andalso sameint(a1, b1)
245          | same (Append(a0), Append(b0)) = samety(a0, b0)
246          | same (Prepend(a0), Prepend(b0)) = samety(a0, b0)
247          | same (Concat(a0), Concat(b0)) = samety(a0, b0)
248        | same (Ceiling(a0), Ceiling(b0)) = sameint(a0, b0)        | same (Ceiling(a0), Ceiling(b0)) = sameint(a0, b0)
249        | same (Floor(a0), Floor(b0)) = sameint(a0, b0)        | same (Floor(a0), Floor(b0)) = sameint(a0, b0)
250        | same (Round(a0), Round(b0)) = sameint(a0, b0)        | same (Round(a0), Round(b0)) = sameint(a0, b0)
# Line 283  Line 299 
299        | hash (Select(a0,a1)) = 0w149 + hashty a0 + hashint a1        | hash (Select(a0,a1)) = 0w149 + hashty a0 + hashint a1
300        | hash (Index(a0,a1)) = 0w151 + hashty a0 + hashint a1        | hash (Index(a0,a1)) = 0w151 + hashty a0 + hashint a1
301        | hash (Subscript(a0)) = 0w157 + hashty a0        | hash (Subscript(a0)) = 0w157 + hashty a0
302        | hash (Ceiling(a0)) = 0w163 + hashint a0        | hash (MkDynamic(a0,a1)) = 0w163 + hashty a0 + hashint a1
303        | hash (Floor(a0)) = 0w167 + hashint a0        | hash (Append(a0)) = 0w167 + hashty a0
304        | hash (Round(a0)) = 0w173 + hashint a0        | hash (Prepend(a0)) = 0w173 + hashty a0
305        | hash (Trunc(a0)) = 0w179 + hashint a0        | hash (Concat(a0)) = 0w179 + hashty a0
306        | hash IntToReal = 0w181        | hash (Ceiling(a0)) = 0w181 + hashint a0
307        | hash (RealToInt(a0)) = 0w191 + hashint a0        | hash (Floor(a0)) = 0w191 + hashint a0
308        | hash (VoxelAddress(a0,a1)) = 0w193 + ImageInfo.hash a0 + hashint a1        | hash (Round(a0)) = 0w193 + hashint a0
309        | hash (LoadVoxels(a0,a1)) = 0w197 + ImageInfo.hash a0 + hashint a1        | hash (Trunc(a0)) = 0w197 + hashint a0
310        | hash (PosToImgSpace(a0)) = 0w199 + ImageInfo.hash a0        | hash IntToReal = 0w199
311        | hash (TensorToWorldSpace(a0,a1)) = 0w211 + ImageInfo.hash a0 + hashty a1        | hash (RealToInt(a0)) = 0w211 + hashint a0
312        | hash (EvalKernel(a0,a1,a2)) = 0w223 + hashint a0 + Kernel.hash a1 + hashint a2        | hash (VoxelAddress(a0,a1)) = 0w223 + ImageInfo.hash a0 + hashint a1
313        | hash (LoadImage(a0)) = 0w227 + ImageInfo.hash a0        | hash (LoadVoxels(a0,a1)) = 0w227 + ImageInfo.hash a0 + hashint a1
314        | hash (Inside(a0,a1)) = 0w229 + ImageInfo.hash a0 + hashint a1        | hash (PosToImgSpace(a0)) = 0w229 + ImageInfo.hash a0
315        | hash (Input(a0,a1,a2)) = 0w233 + hashty a0 + hashstring a1 + hashstring a2        | hash (TensorToWorldSpace(a0,a1)) = 0w233 + ImageInfo.hash a0 + hashty a1
316        | hash (InputWithDefault(a0,a1,a2)) = 0w239 + hashty a0 + hashstring a1 + hashstring a2        | hash (EvalKernel(a0,a1,a2)) = 0w239 + hashint a0 + Kernel.hash a1 + hashint a2
317        | hash (Print(a0)) = 0w241 + hashtys a0        | hash (LoadImage(a0)) = 0w241 + ImageInfo.hash a0
318          | hash (Inside(a0,a1)) = 0w251 + ImageInfo.hash a0 + hashint a1
319          | hash (Input(a0,a1,a2)) = 0w257 + hashty a0 + hashstring a1 + hashstring a2
320          | hash (InputWithDefault(a0,a1,a2)) = 0w263 + hashty a0 + hashstring a1 + hashstring a2
321          | hash (Print(a0)) = 0w269 + hashtys a0
322    
323      fun toString (Add(a0)) = concat["Add<", tyToString a0, ">"]      fun toString (Add(a0)) = concat["Add<", tyToString a0, ">"]
324        | toString (Sub(a0)) = concat["Sub<", tyToString a0, ">"]        | toString (Sub(a0)) = concat["Sub<", tyToString a0, ">"]
# Line 336  Line 356 
356        | toString (Select(a0,a1)) = concat["Select<", tyToString a0, ",", intToString a1, ">"]        | toString (Select(a0,a1)) = concat["Select<", tyToString a0, ",", intToString a1, ">"]
357        | toString (Index(a0,a1)) = concat["Index<", tyToString a0, ",", intToString a1, ">"]        | toString (Index(a0,a1)) = concat["Index<", tyToString a0, ",", intToString a1, ">"]
358        | toString (Subscript(a0)) = concat["Subscript<", tyToString a0, ">"]        | toString (Subscript(a0)) = concat["Subscript<", tyToString a0, ">"]
359          | toString (MkDynamic(a0,a1)) = concat["MkDynamic<", tyToString a0, ",", intToString a1, ">"]
360          | toString (Append(a0)) = concat["Append<", tyToString a0, ">"]
361          | toString (Prepend(a0)) = concat["Prepend<", tyToString a0, ">"]
362          | toString (Concat(a0)) = concat["Concat<", tyToString a0, ">"]
363        | toString (Ceiling(a0)) = concat["Ceiling<", intToString a0, ">"]        | toString (Ceiling(a0)) = concat["Ceiling<", intToString a0, ">"]
364        | toString (Floor(a0)) = concat["Floor<", intToString a0, ">"]        | toString (Floor(a0)) = concat["Floor<", intToString a0, ">"]
365        | toString (Round(a0)) = concat["Round<", intToString a0, ">"]        | toString (Round(a0)) = concat["Round<", intToString a0, ">"]

Legend:
Removed from v.1688  
changed lines
  Added in v.1689

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