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

SCM Repository

[diderot] Annotation of /branches/vis15/src/compiler/low-ir/low-ir.sml
ViewVC logotype

Annotation of /branches/vis15/src/compiler/low-ir/low-ir.sml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 3506 - (view) (download)

1 : jhr 3480 (* low-ir.in
2 :     *
3 :     * This code is part of the Diderot Project (http://diderot-language.cs.uchicago.edu)
4 :     *
5 :     * COPYRIGHT (c) 2015 The University of Chicago
6 :     * All rights reserved.
7 :     *
8 :     * Lower-level version of the Diderot CFG IR
9 :     *
10 :     * Note: this file is generated from gen/ir/low-ir.spec and gen/ir/low-ir.in.
11 :     *)
12 :    
13 :     structure LowOps =
14 :     struct
15 :    
16 :     (* required helper functions for types *)
17 :     type ty = LowTypes.ty
18 :     val samety = LowTypes.same
19 :     val hashty = LowTypes.hash
20 :     val tyToString = LowTypes.toString
21 :    
22 :     (* required helper functions for type lists *)
23 :     type tys = ty list
24 :     fun sametys (tys1, tys2) = ListPair.allEq samety (tys1, tys2)
25 :     fun hashtys tys = List.foldl (fn (ty, s) => hashty ty + 0w3 * s) 0w0 tys
26 :     fun tysToString tys = String.concat["[", String.concatWith "," (List.map tyToString tys), "]" ]
27 :    
28 :     (* required helper functions for the int type *)
29 :     fun sameint (i1 : int, i2) = (i1 = i2)
30 :     fun hashint i = Word.fromInt i
31 :     fun intToString i = Int.toString i
32 :    
33 :     (* required helper functions for the string type *)
34 :     fun samestring (s1 : string, s2) = (s1 = s2)
35 :     val hashstring = HashString.hashString
36 :     fun stringToString s = String.concat["\"", s, "\""]
37 :    
38 :     (* required helper functions for the mask type *)
39 :     type mask = bool list
40 :     val samemask : (mask * mask -> bool) = (op =)
41 :     fun hashmask m =
42 :     List.foldl (fn (false, w) => w+w | (true, w) => w+w+0w1)
43 :     (Word.fromInt(List.length m)) m
44 :     fun maskToString m =
45 :     String.concat(List.map (fn true => "_" | false => ":") m)
46 :    
47 :     (* required helper functions for the index control type type *)
48 :     type idxctl = IndexCtl.ctl
49 :     val sameidxctl = IndexCtl.same
50 :     val hashidxctl = IndexCtl.hash
51 :     val idxctlToString = IndexCtl.toString
52 :    
53 :     datatype rator
54 :     = IAdd
55 :     | ISub
56 :     | IMul
57 :     | IDiv
58 :     | IMod
59 :     | INeg
60 :     | LT of ty
61 :     | LTE of ty
62 :     | EQ of ty
63 :     | NEQ of ty
64 :     | GT of ty
65 :     | GTE of ty
66 :     | Not
67 : jhr 3483 | Abs of ty
68 :     | Max of ty
69 :     | Min of ty
70 : jhr 3480 | VAdd of int
71 :     | VSub of int
72 :     | VMul of int
73 :     | VScale of int
74 :     | VSum of int
75 :     | VNeg of int
76 :     | Clamp of ty
77 :     | Lerp of ty
78 :     | Normalize of int
79 :     | Scale of ty
80 :     | PrincipleEvec of ty
81 :     | EigenVecs2x2
82 :     | EigenVecs3x3
83 :     | EigenVals2x2
84 :     | EigenVals3x3
85 :     | Select of ty * int
86 :     | Index of ty * int
87 :     | Subscript of ty
88 :     | MkDynamic of ty * int
89 :     | Append of ty
90 :     | Prepend of ty
91 :     | Concat of ty
92 :     | Length of ty
93 :     | Sqrt
94 :     | Cos
95 :     | ArcCos
96 :     | Sine
97 :     | ArcSin
98 :     | Tan
99 :     | ArcTan
100 :     | Ceiling of int
101 :     | Floor of int
102 :     | Round of int
103 :     | Trunc of int
104 :     | IntToReal
105 :     | RealToInt of int
106 :     | Transform of ImageInfo.info
107 :     | Translate of ImageInfo.info
108 :     | Kernel of Kernel.kernel * int
109 :     | ImageAddress of ImageInfo.info
110 :     | ControlIndex of ImageInfo.info * idxctl * int
111 :     | LoadVoxels of ImageInfo.info * int
112 :     | Inside of ImageInfo.info * int
113 :     | ImageDim of ImageInfo.info * int
114 :     | LoadSeq of ty * string
115 :     | LoadImage of ty * string
116 :     | Print of tys
117 :    
118 :     fun resultArity IAdd = 1
119 :     | resultArity ISub = 1
120 :     | resultArity IMul = 1
121 :     | resultArity IDiv = 1
122 :     | resultArity IMod = 1
123 :     | resultArity INeg = 1
124 :     | resultArity (LT _) = 1
125 :     | resultArity (LTE _) = 1
126 :     | resultArity (EQ _) = 1
127 :     | resultArity (NEQ _) = 1
128 :     | resultArity (GT _) = 1
129 :     | resultArity (GTE _) = 1
130 :     | resultArity Not = 1
131 : jhr 3483 | resultArity (Abs _) = 1
132 :     | resultArity (Max _) = 1
133 :     | resultArity (Min _) = 1
134 : jhr 3480 | resultArity (VAdd _) = 1
135 :     | resultArity (VSub _) = 1
136 :     | resultArity (VMul _) = 1
137 :     | resultArity (VScale _) = 1
138 :     | resultArity (VSum _) = 1
139 :     | resultArity (VNeg _) = 1
140 :     | resultArity (Clamp _) = 1
141 :     | resultArity (Lerp _) = 1
142 :     | resultArity (Normalize _) = 1
143 :     | resultArity (Scale _) = 1
144 :     | resultArity (PrincipleEvec _) = 1
145 :     | resultArity EigenVecs2x2 = 1
146 :     | resultArity EigenVecs3x3 = 1
147 :     | resultArity EigenVals2x2 = 1
148 :     | resultArity EigenVals3x3 = 1
149 :     | resultArity (Select _) = 1
150 :     | resultArity (Index _) = 1
151 :     | resultArity (Subscript _) = 1
152 :     | resultArity (MkDynamic _) = 1
153 :     | resultArity (Append _) = 2
154 :     | resultArity (Prepend _) = 2
155 :     | resultArity (Concat _) = 2
156 :     | resultArity (Length _) = 1
157 :     | resultArity Sqrt = 1
158 :     | resultArity Cos = 1
159 :     | resultArity ArcCos = 1
160 :     | resultArity Sine = 1
161 :     | resultArity ArcSin = 1
162 :     | resultArity Tan = 1
163 :     | resultArity ArcTan = 1
164 :     | resultArity (Ceiling _) = 1
165 :     | resultArity (Floor _) = 1
166 :     | resultArity (Round _) = 1
167 :     | resultArity (Trunc _) = 1
168 :     | resultArity IntToReal = 1
169 :     | resultArity (RealToInt _) = 1
170 :     | resultArity (Transform _) = 1
171 :     | resultArity (Translate _) = 1
172 :     | resultArity (Kernel _) = 1
173 :     | resultArity (ImageAddress _) = 1
174 :     | resultArity (ControlIndex _) = 1
175 :     | resultArity (LoadVoxels _) = 1
176 :     | resultArity (Inside _) = 1
177 :     | resultArity (ImageDim _) = 1
178 :     | resultArity (LoadSeq _) = 1
179 :     | resultArity (LoadImage _) = 1
180 :     | resultArity (Print _) = 0
181 :    
182 :     fun arity IAdd = 2
183 :     | arity ISub = 2
184 :     | arity IMul = 2
185 :     | arity IDiv = 2
186 :     | arity IMod = 2
187 :     | arity INeg = 1
188 :     | arity (LT _) = 2
189 :     | arity (LTE _) = 2
190 :     | arity (EQ _) = 2
191 :     | arity (NEQ _) = 2
192 :     | arity (GT _) = 2
193 :     | arity (GTE _) = 2
194 :     | arity Not = 1
195 : jhr 3483 | arity (Abs _) = 1
196 :     | arity (Max _) = 2
197 :     | arity (Min _) = 2
198 : jhr 3480 | arity (VAdd _) = 2
199 :     | arity (VSub _) = 2
200 :     | arity (VMul _) = 2
201 :     | arity (VScale _) = 2
202 :     | arity (VSum _) = 2
203 :     | arity (VNeg _) = 1
204 :     | arity (Clamp _) = 3
205 :     | arity (Lerp _) = 3
206 :     | arity (Normalize _) = 1
207 :     | arity (Scale _) = 2
208 :     | arity (PrincipleEvec _) = 2
209 :     | arity EigenVecs2x2 = 1
210 :     | arity EigenVecs3x3 = 1
211 :     | arity EigenVals2x2 = 1
212 :     | arity EigenVals3x3 = 1
213 :     | arity (Select _) = 1
214 :     | arity (Index _) = 1
215 :     | arity (Subscript _) = 2
216 :     | arity (MkDynamic _) = 1
217 :     | arity (Append _) = 1
218 :     | arity (Prepend _) = 1
219 :     | arity (Concat _) = 1
220 :     | arity (Length _) = 1
221 :     | arity Sqrt = 1
222 :     | arity Cos = 1
223 :     | arity ArcCos = 1
224 :     | arity Sine = 1
225 :     | arity ArcSin = 1
226 :     | arity Tan = 1
227 :     | arity ArcTan = 1
228 :     | arity (Ceiling _) = 1
229 :     | arity (Floor _) = 1
230 :     | arity (Round _) = 1
231 :     | arity (Trunc _) = 1
232 :     | arity IntToReal = 1
233 :     | arity (RealToInt _) = 1
234 :     | arity (Transform _) = 2
235 :     | arity (Translate _) = 2
236 :     | arity (Kernel _) = 0
237 :     | arity (ImageAddress _) = 1
238 :     | arity (ControlIndex _) = 2
239 :     | arity (LoadVoxels _) = 1
240 :     | arity (Inside _) = 2
241 :     | arity (ImageDim _) = 1
242 :     | arity (LoadSeq _) = 0
243 :     | arity (LoadImage _) = 0
244 :     | arity (Print _) = ~1
245 :    
246 :     fun isPure (MkDynamic _) = false
247 :     | isPure (Append _) = false
248 :     | isPure (Prepend _) = false
249 :     | isPure (Concat _) = false
250 :     | isPure (Print _) = false
251 :     | isPure _ = true
252 :    
253 :     fun same (IAdd, IAdd) = true
254 :     | same (ISub, ISub) = true
255 :     | same (IMul, IMul) = true
256 :     | same (IDiv, IDiv) = true
257 :     | same (IMod, IMod) = true
258 :     | same (INeg, INeg) = true
259 :     | same (LT(a0), LT(b0)) = samety(a0, b0)
260 :     | same (LTE(a0), LTE(b0)) = samety(a0, b0)
261 :     | same (EQ(a0), EQ(b0)) = samety(a0, b0)
262 :     | same (NEQ(a0), NEQ(b0)) = samety(a0, b0)
263 :     | same (GT(a0), GT(b0)) = samety(a0, b0)
264 :     | same (GTE(a0), GTE(b0)) = samety(a0, b0)
265 :     | same (Not, Not) = true
266 : jhr 3483 | same (Abs(a0), Abs(b0)) = samety(a0, b0)
267 :     | same (Max(a0), Max(b0)) = samety(a0, b0)
268 :     | same (Min(a0), Min(b0)) = samety(a0, b0)
269 : jhr 3480 | same (VAdd(a0), VAdd(b0)) = sameint(a0, b0)
270 :     | same (VSub(a0), VSub(b0)) = sameint(a0, b0)
271 :     | same (VMul(a0), VMul(b0)) = sameint(a0, b0)
272 :     | same (VScale(a0), VScale(b0)) = sameint(a0, b0)
273 :     | same (VSum(a0), VSum(b0)) = sameint(a0, b0)
274 :     | same (VNeg(a0), VNeg(b0)) = sameint(a0, b0)
275 :     | same (Clamp(a0), Clamp(b0)) = samety(a0, b0)
276 :     | same (Lerp(a0), Lerp(b0)) = samety(a0, b0)
277 :     | same (Normalize(a0), Normalize(b0)) = sameint(a0, b0)
278 :     | same (Scale(a0), Scale(b0)) = samety(a0, b0)
279 :     | same (PrincipleEvec(a0), PrincipleEvec(b0)) = samety(a0, b0)
280 :     | same (EigenVecs2x2, EigenVecs2x2) = true
281 :     | same (EigenVecs3x3, EigenVecs3x3) = true
282 :     | same (EigenVals2x2, EigenVals2x2) = true
283 :     | same (EigenVals3x3, EigenVals3x3) = true
284 :     | same (Select(a0,a1), Select(b0,b1)) = samety(a0, b0) andalso sameint(a1, b1)
285 :     | same (Index(a0,a1), Index(b0,b1)) = samety(a0, b0) andalso sameint(a1, b1)
286 :     | same (Subscript(a0), Subscript(b0)) = samety(a0, b0)
287 :     | same (MkDynamic(a0,a1), MkDynamic(b0,b1)) = samety(a0, b0) andalso sameint(a1, b1)
288 :     | same (Append(a0), Append(b0)) = samety(a0, b0)
289 :     | same (Prepend(a0), Prepend(b0)) = samety(a0, b0)
290 :     | same (Concat(a0), Concat(b0)) = samety(a0, b0)
291 :     | same (Length(a0), Length(b0)) = samety(a0, b0)
292 :     | same (Sqrt, Sqrt) = true
293 :     | same (Cos, Cos) = true
294 :     | same (ArcCos, ArcCos) = true
295 :     | same (Sine, Sine) = true
296 :     | same (ArcSin, ArcSin) = true
297 :     | same (Tan, Tan) = true
298 :     | same (ArcTan, ArcTan) = true
299 :     | same (Ceiling(a0), Ceiling(b0)) = sameint(a0, b0)
300 :     | same (Floor(a0), Floor(b0)) = sameint(a0, b0)
301 :     | same (Round(a0), Round(b0)) = sameint(a0, b0)
302 :     | same (Trunc(a0), Trunc(b0)) = sameint(a0, b0)
303 :     | same (IntToReal, IntToReal) = true
304 :     | same (RealToInt(a0), RealToInt(b0)) = sameint(a0, b0)
305 :     | same (Transform(a0), Transform(b0)) = ImageInfo.same(a0, b0)
306 :     | same (Translate(a0), Translate(b0)) = ImageInfo.same(a0, b0)
307 :     | same (Kernel(a0,a1), Kernel(b0,b1)) = Kernel.same(a0, b0) andalso sameint(a1, b1)
308 :     | same (ImageAddress(a0), ImageAddress(b0)) = ImageInfo.same(a0, b0)
309 :     | same (ControlIndex(a0,a1,a2), ControlIndex(b0,b1,b2)) = ImageInfo.same(a0, b0) andalso sameidxctl(a1, b1) andalso sameint(a2, b2)
310 :     | same (LoadVoxels(a0,a1), LoadVoxels(b0,b1)) = ImageInfo.same(a0, b0) andalso sameint(a1, b1)
311 :     | same (Inside(a0,a1), Inside(b0,b1)) = ImageInfo.same(a0, b0) andalso sameint(a1, b1)
312 :     | same (ImageDim(a0,a1), ImageDim(b0,b1)) = ImageInfo.same(a0, b0) andalso sameint(a1, b1)
313 :     | same (LoadSeq(a0,a1), LoadSeq(b0,b1)) = samety(a0, b0) andalso samestring(a1, b1)
314 :     | same (LoadImage(a0,a1), LoadImage(b0,b1)) = samety(a0, b0) andalso samestring(a1, b1)
315 :     | same (Print(a0), Print(b0)) = sametys(a0, b0)
316 :     | same _ = false
317 :    
318 :     fun hash IAdd = 0w3
319 :     | hash ISub = 0w5
320 :     | hash IMul = 0w7
321 :     | hash IDiv = 0w11
322 :     | hash IMod = 0w13
323 :     | hash INeg = 0w17
324 : jhr 3483 | hash (LT(a0)) = 0w19 + hashty a0
325 :     | hash (LTE(a0)) = 0w23 + hashty a0
326 :     | hash (EQ(a0)) = 0w29 + hashty a0
327 :     | hash (NEQ(a0)) = 0w31 + hashty a0
328 :     | hash (GT(a0)) = 0w37 + hashty a0
329 :     | hash (GTE(a0)) = 0w41 + hashty a0
330 :     | hash Not = 0w43
331 :     | hash (Abs(a0)) = 0w47 + hashty a0
332 :     | hash (Max(a0)) = 0w53 + hashty a0
333 :     | hash (Min(a0)) = 0w59 + hashty a0
334 : jhr 3480 | hash (VAdd(a0)) = 0w61 + hashint a0
335 :     | hash (VSub(a0)) = 0w67 + hashint a0
336 :     | hash (VMul(a0)) = 0w71 + hashint a0
337 :     | hash (VScale(a0)) = 0w73 + hashint a0
338 :     | hash (VSum(a0)) = 0w79 + hashint a0
339 :     | hash (VNeg(a0)) = 0w83 + hashint a0
340 :     | hash (Clamp(a0)) = 0w89 + hashty a0
341 :     | hash (Lerp(a0)) = 0w97 + hashty a0
342 :     | hash (Normalize(a0)) = 0w101 + hashint a0
343 :     | hash (Scale(a0)) = 0w103 + hashty a0
344 :     | hash (PrincipleEvec(a0)) = 0w107 + hashty a0
345 :     | hash EigenVecs2x2 = 0w109
346 :     | hash EigenVecs3x3 = 0w113
347 :     | hash EigenVals2x2 = 0w127
348 :     | hash EigenVals3x3 = 0w131
349 :     | hash (Select(a0,a1)) = 0w137 + hashty a0 + hashint a1
350 :     | hash (Index(a0,a1)) = 0w139 + hashty a0 + hashint a1
351 :     | hash (Subscript(a0)) = 0w149 + hashty a0
352 :     | hash (MkDynamic(a0,a1)) = 0w151 + hashty a0 + hashint a1
353 :     | hash (Append(a0)) = 0w157 + hashty a0
354 :     | hash (Prepend(a0)) = 0w163 + hashty a0
355 :     | hash (Concat(a0)) = 0w167 + hashty a0
356 :     | hash (Length(a0)) = 0w173 + hashty a0
357 :     | hash Sqrt = 0w179
358 :     | hash Cos = 0w181
359 :     | hash ArcCos = 0w191
360 :     | hash Sine = 0w193
361 :     | hash ArcSin = 0w197
362 :     | hash Tan = 0w199
363 :     | hash ArcTan = 0w211
364 :     | hash (Ceiling(a0)) = 0w223 + hashint a0
365 :     | hash (Floor(a0)) = 0w227 + hashint a0
366 :     | hash (Round(a0)) = 0w229 + hashint a0
367 :     | hash (Trunc(a0)) = 0w233 + hashint a0
368 :     | hash IntToReal = 0w239
369 :     | hash (RealToInt(a0)) = 0w241 + hashint a0
370 :     | hash (Transform(a0)) = 0w251 + ImageInfo.hash a0
371 :     | hash (Translate(a0)) = 0w257 + ImageInfo.hash a0
372 :     | hash (Kernel(a0,a1)) = 0w263 + Kernel.hash a0 + hashint a1
373 :     | hash (ImageAddress(a0)) = 0w269 + ImageInfo.hash a0
374 :     | hash (ControlIndex(a0,a1,a2)) = 0w271 + ImageInfo.hash a0 + hashidxctl a1 + hashint a2
375 :     | hash (LoadVoxels(a0,a1)) = 0w277 + ImageInfo.hash a0 + hashint a1
376 :     | hash (Inside(a0,a1)) = 0w281 + ImageInfo.hash a0 + hashint a1
377 :     | hash (ImageDim(a0,a1)) = 0w283 + ImageInfo.hash a0 + hashint a1
378 :     | hash (LoadSeq(a0,a1)) = 0w293 + hashty a0 + hashstring a1
379 :     | hash (LoadImage(a0,a1)) = 0w307 + hashty a0 + hashstring a1
380 : jhr 3506 | hash (Print(a0)) = 0w311 + hashtys a0
381 : jhr 3480
382 :     fun toString IAdd = "IAdd"
383 :     | toString ISub = "ISub"
384 :     | toString IMul = "IMul"
385 :     | toString IDiv = "IDiv"
386 :     | toString IMod = "IMod"
387 :     | toString INeg = "INeg"
388 :     | toString (LT(a0)) = concat["LT<", tyToString a0, ">"]
389 :     | toString (LTE(a0)) = concat["LTE<", tyToString a0, ">"]
390 :     | toString (EQ(a0)) = concat["EQ<", tyToString a0, ">"]
391 :     | toString (NEQ(a0)) = concat["NEQ<", tyToString a0, ">"]
392 :     | toString (GT(a0)) = concat["GT<", tyToString a0, ">"]
393 :     | toString (GTE(a0)) = concat["GTE<", tyToString a0, ">"]
394 :     | toString Not = "Not"
395 : jhr 3483 | toString (Abs(a0)) = concat["Abs<", tyToString a0, ">"]
396 :     | toString (Max(a0)) = concat["Max<", tyToString a0, ">"]
397 :     | toString (Min(a0)) = concat["Min<", tyToString a0, ">"]
398 : jhr 3480 | toString (VAdd(a0)) = concat["VAdd<", intToString a0, ">"]
399 :     | toString (VSub(a0)) = concat["VSub<", intToString a0, ">"]
400 :     | toString (VMul(a0)) = concat["VMul<", intToString a0, ">"]
401 :     | toString (VScale(a0)) = concat["VScale<", intToString a0, ">"]
402 :     | toString (VSum(a0)) = concat["VSum<", intToString a0, ">"]
403 :     | toString (VNeg(a0)) = concat["VNeg<", intToString a0, ">"]
404 :     | toString (Clamp(a0)) = concat["Clamp<", tyToString a0, ">"]
405 :     | toString (Lerp(a0)) = concat["Lerp<", tyToString a0, ">"]
406 :     | toString (Normalize(a0)) = concat["Normalize<", intToString a0, ">"]
407 :     | toString (Scale(a0)) = concat["Scale<", tyToString a0, ">"]
408 :     | toString (PrincipleEvec(a0)) = concat["PrincipleEvec<", tyToString a0, ">"]
409 :     | toString EigenVecs2x2 = "EigenVecs2x2"
410 :     | toString EigenVecs3x3 = "EigenVecs3x3"
411 :     | toString EigenVals2x2 = "EigenVals2x2"
412 :     | toString EigenVals3x3 = "EigenVals3x3"
413 :     | toString (Select(a0,a1)) = concat["Select<", tyToString a0, ",", intToString a1, ">"]
414 :     | toString (Index(a0,a1)) = concat["Index<", tyToString a0, ",", intToString a1, ">"]
415 :     | toString (Subscript(a0)) = concat["Subscript<", tyToString a0, ">"]
416 :     | toString (MkDynamic(a0,a1)) = concat["MkDynamic<", tyToString a0, ",", intToString a1, ">"]
417 :     | toString (Append(a0)) = concat["Append<", tyToString a0, ">"]
418 :     | toString (Prepend(a0)) = concat["Prepend<", tyToString a0, ">"]
419 :     | toString (Concat(a0)) = concat["Concat<", tyToString a0, ">"]
420 :     | toString (Length(a0)) = concat["Length<", tyToString a0, ">"]
421 :     | toString Sqrt = "Sqrt"
422 :     | toString Cos = "Cos"
423 :     | toString ArcCos = "ArcCos"
424 :     | toString Sine = "Sine"
425 :     | toString ArcSin = "ArcSin"
426 :     | toString Tan = "Tan"
427 :     | toString ArcTan = "ArcTan"
428 :     | toString (Ceiling(a0)) = concat["Ceiling<", intToString a0, ">"]
429 :     | toString (Floor(a0)) = concat["Floor<", intToString a0, ">"]
430 :     | toString (Round(a0)) = concat["Round<", intToString a0, ">"]
431 :     | toString (Trunc(a0)) = concat["Trunc<", intToString a0, ">"]
432 :     | toString IntToReal = "IntToReal"
433 :     | toString (RealToInt(a0)) = concat["RealToInt<", intToString a0, ">"]
434 :     | toString (Transform(a0)) = concat["Transform<", ImageInfo.toString a0, ">"]
435 :     | toString (Translate(a0)) = concat["Translate<", ImageInfo.toString a0, ">"]
436 :     | toString (Kernel(a0,a1)) = concat["Kernel<", Kernel.toString a0, ",", intToString a1, ">"]
437 :     | toString (ImageAddress(a0)) = concat["ImageAddress<", ImageInfo.toString a0, ">"]
438 :     | toString (ControlIndex(a0,a1,a2)) = concat["ControlIndex<", ImageInfo.toString a0, ",", idxctlToString a1, ",", intToString a2, ">"]
439 :     | toString (LoadVoxels(a0,a1)) = concat["LoadVoxels<", ImageInfo.toString a0, ",", intToString a1, ">"]
440 :     | toString (Inside(a0,a1)) = concat["Inside<", ImageInfo.toString a0, ",", intToString a1, ">"]
441 :     | toString (ImageDim(a0,a1)) = concat["ImageDim<", ImageInfo.toString a0, ",", intToString a1, ">"]
442 :     | toString (LoadSeq(a0,a1)) = concat["LoadSeq<", tyToString a0, ",", stringToString a1, ">"]
443 :     | toString (LoadImage(a0,a1)) = concat["LoadImage<", tyToString a0, ",", stringToString a1, ">"]
444 :     | toString (Print(a0)) = concat["Print<", tysToString a0, ">"]
445 :    
446 :     end
447 :    
448 :     structure LowIR = SSAFn(
449 :     val ilName = "low-ir"
450 :     structure Ty = LowTypes
451 :     structure Op = LowOps)
452 :    
453 :     structure LowCensus = CensusFn(LowIR)

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