keep track of indentation of extracted code
[pet.git] / tests / conditional_assignment.scop
blob640e0bd30e0b1dda7a28c7c54542cda296b3debd
1 start: 218
2 end: 496
3 indent: "\t"
4 context: '[N, M] -> {  : N >= 0 and M >= 0 and N <= 2147483647 and M <= 2147483647
5   }'
6 arrays:
7 - context: '[N] -> {  : N >= 0 }'
8   extent: '[N, M] -> { A[i0, i1] : i0 >= 0 and i0 <= -1 + N and i1 >= 0 and i1 <=
9     9 }'
10   element_type: int
11   element_size: 4
12 - context: '[N] -> {  : N >= 0 }'
13   extent: '[N, M] -> { C[i0] : i0 <= -1 + N and i0 >= 0 }'
14   element_type: int
15   element_size: 4
16 - context: '[M, N] -> {  : N >= 0 and M >= 0 }'
17   extent: '[N, M] -> { in1[i0, i1] : i1 <= -1 + M and i1 >= 0 and i0 <= -1 + N and
18     i0 >= 0 }'
19   element_type: int
20   element_size: 4
21 - context: '[N] -> {  : N >= 0 }'
22   extent: '[N, M] -> { in2[i0] : i0 <= -1 + N and i0 >= 0 }'
23   value_bounds: '{ [i0] : i0 >= -1 and i0 <= 1 }'
24   element_type: int
25   element_size: 4
26 - context: '{  :  }'
27   extent: '[N, M] -> { m[] }'
28   element_type: int
29   element_size: 4
30 statements:
31 - line: 21
32   domain: '[N, M] -> { S_0[i] : i <= -1 + N and i >= 0 }'
33   schedule: '[N] -> { S_0[i] -> [0, i, 0] }'
34   body:
35     type: op
36     operation: =
37     arguments:
38     - type: access
39       relation: '[N, M] -> { S_0[i] -> m[] }'
40       index: '[N, M] -> { S_0[i] -> m[] }'
41       reference: __pet_ref_0
42       read: 0
43       write: 1
44     - type: op
45       operation: +
46       arguments:
47       - type: access
48         relation: '[N, M] -> { S_0[i] -> [i] }'
49         index: '[N, M] -> { S_0[i] -> [(i)] }'
50         reference: __pet_ref_1
51         read: 1
52         write: 0
53       - type: int
54         value: 1
55 - line: 23
56   domain: '[N, M] -> { S_1[i, j] : j <= -1 + M and j >= 0 and i <= -1 + N and i >=
57     0 }'
58   schedule: '[N, M] -> { S_1[i, j] -> [0, i, 1, j] }'
59   body:
60     type: op
61     operation: =
62     arguments:
63     - type: access
64       relation: '[N, M] -> { S_1[i, j] -> m[] }'
65       index: '[N, M] -> { S_1[i, j] -> m[] }'
66       reference: __pet_ref_2
67       read: 0
68       write: 1
69     - type: call
70       name: g
71       arguments:
72       - type: call
73         name: h
74         arguments:
75         - type: access
76           relation: '[N, M] -> { S_1[i, j] -> m[] }'
77           index: '[N, M] -> { S_1[i, j] -> m[] }'
78           reference: __pet_ref_3
79           read: 1
80           write: 0
81       - type: access
82         relation: '[N, M] -> { S_1[i, j] -> in1[i, j] }'
83         index: '[N, M] -> { S_1[i, j] -> in1[(i), (j)] }'
84         reference: __pet_ref_4
85         read: 1
86         write: 0
87 - line: 24
88   domain: '[N, M] -> { S_2[i] : i <= -1 + N and i >= 0 }'
89   schedule: '[N] -> { S_2[i] -> [0, i, 2] }'
90   body:
91     type: call
92     name: compute_row
93     arguments:
94     - type: call
95       name: h
96       arguments:
97       - type: access
98         relation: '[N, M] -> { S_2[i] -> m[] }'
99         index: '[N, M] -> { S_2[i] -> m[] }'
100         reference: __pet_ref_5
101         read: 1
102         write: 0
103     - type: access
104       relation: '[N, M] -> { S_2[i] -> A[i, o1] }'
105       index: '[N, M] -> { S_2[i] -> A[(i)] }'
106       reference: __pet_ref_6
107       read: 0
108       write: 1
109 - line: 26
110   domain: '[N, M] -> { S_3[] }'
111   schedule: '{ S_3[] -> [1] }'
112   body:
113     type: op
114     operation: =
115     arguments:
116     - type: access
117       relation: '[N, M] -> { S_3[] -> A[5, 6] }'
118       index: '[N, M] -> { S_3[] -> A[(5), (6)] }'
119       reference: __pet_ref_7
120       read: 0
121       write: 1
122     - type: int
123       value: 0
124 - line: 28
125   domain: '[N, M] -> { S_4[i] : i <= -1 + N and i >= 0 }'
126   schedule: '[N] -> { S_4[i] -> [2, i] }'
127   body:
128     type: op
129     operation: =
130     arguments:
131     - type: access
132       relation: '[N, M] -> { S_4[i] -> C[i] }'
133       index: '[N, M] -> { S_4[i] -> C[(i)] }'
134       reference: __pet_ref_8
135       read: 0
136       write: 1
137     - type: op
138       operation: '?:'
139       arguments:
140       - type: access
141         relation: '[N, M] -> { [S_4[i] -> [i1]] -> [1] : i1 >= -i and i1 <= -1 + N
142           - i; [S_4[-1 + N] -> [1]] -> [0]; [S_4[0] -> [-1]] -> [0] }'
143         index: '[N, M] -> { [S_4[i] -> [i1]] -> [((1) : i1 >= -i and i1 <= -1 + N
144           - i; (0) : i = -1 + N and i1 = 1; (0) : i = 0 and i1 = -1)] }'
145         reference: __pet_ref_10
146         read: 1
147         write: 0
148         arguments:
149         - type: access
150           relation: '[N, M] -> { S_4[i] -> in2[i] }'
151           index: '[N, M] -> { S_4[i] -> in2[(i)] }'
152           reference: __pet_ref_9
153           read: 1
154           write: 0
155       - type: call
156         name: f
157         arguments:
158         - type: access
159           relation: '[N, M] -> { [S_4[i] -> [i1]] -> A[i + i1, o1] : i1 >= -i and
160             i1 <= -1 + N - i }'
161           index: '[N, M] -> { [S_4[i] -> [i1]] -> A[((i + i1) : i1 >= -i)] }'
162           reference: __pet_ref_12
163           read: 1
164           write: 0
165           arguments:
166           - type: access
167             relation: '[N, M] -> { S_4[i] -> in2[i] }'
168             index: '[N, M] -> { S_4[i] -> in2[(i)] }'
169             reference: __pet_ref_11
170             read: 1
171             write: 0
172       - type: int
173         value: 0