pet_scop_add: plug memory leak on error path
[pet.git] / tests / quasi_affine.scop
blobd283897bca1a0d7c7e9ae40bfb787559a78251ab
1 context: '[N] -> {  : N >= 0 and N <= 2147483647 }'
2 arrays:
3 - context: '{  :  }'
4   extent: '{ in[] }'
5   element_type: int
6 - context: '[N] -> {  : N >= 0 }'
7   extent: '[N] -> { A[i0] : i0 >= 0 and i0 <= -1 + N }'
8   element_type: int
9 - context: '{  :  }'
10   extent: '{ out[] }'
11   element_type: int
12 statements:
13 - line: 14
14   domain: '[N] -> { S_0[] }'
15   schedule: '{ S_0[] -> [0, 0] }'
16   body:
17     type: binary
18     operation: =
19     arguments:
20     - type: access
21       relation: '[N] -> { S_0[] -> A[0] }'
22       read: 0
23       write: 1
24     - type: access
25       relation: '[N] -> { S_0[] -> in[] }'
26       read: 1
27       write: 0
28 - line: 16
29   domain: '[N] -> { S_1[i] : i >= 1 and i <= N }'
30   schedule: '[N] -> { S_1[i] -> [0, 1, i, 0] }'
31   body:
32     type: binary
33     operation: =
34     arguments:
35     - type: access
36       relation: '[N] -> { S_1[i] -> A[i] }'
37       read: 0
38       write: 1
39     - type: call
40       name: f
41       arguments:
42       - type: call
43         name: g
44         arguments:
45         - type: access
46           relation: '[N] -> { S_1[i] -> A[o0] : 2o0 <= i and 2o0 >= -1 + i }'
47           read: 1
48           write: 0
49 - line: 18
50   domain: '[N] -> { S_2[] }'
51   schedule: '{ S_2[] -> [0, 2] }'
52   body:
53     type: binary
54     operation: =
55     arguments:
56     - type: access
57       relation: '[N] -> { S_2[] -> out[] }'
58       read: 0
59       write: 1
60     - type: call
61       name: g
62       arguments:
63       - type: access
64         relation: '[N] -> { S_2[] -> A[N] }'
65         read: 1
66         write: 0