File: inline_calls.0.res.oracle

package info (click to toggle)
frama-c 20220511-manganese-5
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 66,492 kB
  • sloc: ml: 278,834; ansic: 47,093; sh: 4,823; makefile: 3,613; javascript: 2,436; python: 1,919; perl: 897; lisp: 293; xml: 62
file content (361 lines) | stat: -rw-r--r-- 7,281 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
[kernel] Parsing inline_calls.i (no preprocessing)
[kernel:CERT:MSC:37] inline_calls.i:40: Warning: 
  Body of function f1 falls-through. Adding a return statement
/* Generated by Frama-C */
int f(void)
{
  int __retres;
  __retres = 2;
  return __retres;
}

__inline static int in_f__fc_inline(void)
{
  int __retres;
  __retres = 3;
  return __retres;
}

int volatile v;
int g(void)
{
  int __retres;
  if (v) {
    int tmp;
    {
       /* __blockattribute__(____fc_inlined__("f")) */int __retres_5;
      __retres_5 = 2;
      tmp = __retres_5;
    }
    __retres = tmp;
    goto return_label;
  }
  else {
    int tmp_0;
    {
       /* __blockattribute__(____fc_inlined__("in_f__fc_inline")) */int __retres_6;
      __retres_6 = 3;
      tmp_0 = __retres_6;
    }
    __retres = tmp_0;
    goto return_label;
  }
  return_label: return __retres;
}

int h(void)
{
  int tmp;
  {
     /* __blockattribute__(____fc_inlined__("g")) */int __retres;
    if (v) {
      int tmp_3;
      {
         /* __blockattribute__(____fc_inlined__("f")) */int __retres_5;
        __retres_5 = 2;
        tmp_3 = __retres_5;
      }
      __retres = tmp_3;
      goto return_label;
    }
    else {
      int tmp_0;
      {
         /* __blockattribute__(____fc_inlined__("in_f__fc_inline")) */
        int __retres_6;
        __retres_6 = 3;
        tmp_0 = __retres_6;
      }
      __retres = tmp_0;
      goto return_label;
    }
    return_label: tmp = __retres;
  }
  return tmp;
}

int i(void)
{
  int __retres;
  /*@ assert i: \true; */ ;
  __retres = 0;
  return __retres;
}

int rec(int x_0)
{
  int __retres;
  int tmp;
  if (x_0 < 0) {
    __retres = x_0;
    goto return_label;
  }
  {
     /* __blockattribute__(____fc_inlined__("rec")) */int __retres_7;
                                                      int tmp_6;
    int x_0_5 = x_0 - 1;
    if (x_0_5 < 0) {
      __retres_7 = x_0_5;
      goto return_label_0;
    }
    tmp_6 = rec(x_0_5 - 1);
    __retres_7 = tmp_6;
    return_label_0: tmp = __retres_7;
  }
  __retres = tmp;
  return_label: return __retres;
}

int f1(int a);

int g1(int a);

int volatile nondet;
int f1(int a)
{
  int __retres;
  if (nondet) {
    int __inline_tmp;
    {
       /* __blockattribute__(____fc_inlined__("g1")) */int a_5 = 1;
      if (nondet) g1(4);
      __inline_tmp = a_5;
    }
  }
  else 
    if (nondet) {
      int __inline_tmp_6;
      {
         /* __blockattribute__(____fc_inlined__("f1")) */int __retres_9;
        int a_8 = 2;
        if (nondet) {
          int __inline_tmp_10;
          {
             /* __blockattribute__(____fc_inlined__("g1")) */int a_5_11 = 1;
            if (nondet) g1(4);
            __inline_tmp_10 = a_5_11;
          }
        }
        else 
          if (nondet) {
            int __inline_tmp_6_12;
            f1(2);
          }
        /*@ assert missing_return: \false; */ ;
        __retres_9 = 0;
        __inline_tmp_6 = __retres_9;
      }
    }
  /*@ assert missing_return: \false; */ ;
  __retres = 0;
  return __retres;
}

int g1(int a)
{
  if (nondet) {
    int __inline_tmp;
    {
       /* __blockattribute__(____fc_inlined__("g1")) */int a_4 = 4;
      if (nondet) {
        int __inline_tmp_5;
        g1(4);
      }
      __inline_tmp = a_4;
    }
  }
  return a;
}

int main(void)
{
  int __inline_tmp_11;
  int __inline_tmp_8;
  int __inline_tmp;
  int tmp_1;
  {
     /* __blockattribute__(____fc_inlined__("i")) */int __retres;
    /*@ assert i: \true; */ ;
    __retres = 0;
    __inline_tmp = __retres;
  }
  int local_init = __inline_tmp;
  {
     /* __blockattribute__(____fc_inlined__("rec")) */int __retres_10;
                                                      int tmp;
    int x_0 = local_init;
    if (x_0 < 0) {
      __retres_10 = x_0;
      goto return_label;
    }
    {
       /* __blockattribute__(____fc_inlined__("rec")) */int __retres_7;
                                                        int tmp_6;
      int x_0_5 = x_0 - 1;
      if (x_0_5 < 0) {
        __retres_7 = x_0_5;
        goto return_label_0;
      }
      tmp_6 = rec(x_0_5 - 1);
      __retres_7 = tmp_6;
      return_label_0: tmp = __retres_7;
    }
    __retres_10 = tmp;
    return_label: __inline_tmp_8 = __retres_10;
  }
  int t = __inline_tmp_8;
  {
     /* __blockattribute__(____fc_inlined__("f1")) */int __retres_13;
    int a = 2;
    if (nondet) {
      int __inline_tmp_14;
      {
         /* __blockattribute__(____fc_inlined__("g1")) */int a_5 = 1;
        if (nondet) g1(4);
        __inline_tmp_14 = a_5;
      }
    }
    else 
      if (nondet) {
        int __inline_tmp_6;
        {
           /* __blockattribute__(____fc_inlined__("f1")) */int __retres_9;
          int a_8 = 2;
          if (nondet) {
            int __inline_tmp_10;
            {
               /* __blockattribute__(____fc_inlined__("g1")) */int a_5_11 =
                                                                 1;
              if (nondet) g1(4);
              __inline_tmp_10 = a_5_11;
            }
          }
          else 
            if (nondet) {
              int __inline_tmp_6_12;
              f1(2);
            }
          /*@ assert missing_return: \false; */ ;
          __retres_9 = 0;
          __inline_tmp_6 = __retres_9;
        }
      }
    /*@ assert missing_return: \false; */ ;
    __retres_13 = 0;
    __inline_tmp_11 = __retres_13;
  }
  {
     /* __blockattribute__(____fc_inlined__("h")) */int tmp_15;
    {
       /* __blockattribute__(____fc_inlined__("g")) */int __retres_16;
      if (v) {
        int tmp_3;
        {
           /* __blockattribute__(____fc_inlined__("f")) */int __retres_5;
          __retres_5 = 2;
          tmp_3 = __retres_5;
        }
        __retres_16 = tmp_3;
        goto return_label_1;
      }
      else {
        int tmp_0;
        {
           /* __blockattribute__(____fc_inlined__("in_f__fc_inline")) */
          int __retres_6;
          __retres_6 = 3;
          tmp_0 = __retres_6;
        }
        __retres_16 = tmp_0;
        goto return_label_1;
      }
      return_label_1: tmp_15 = __retres_16;
    }
    tmp_1 = tmp_15;
  }
  return tmp_1;
}

int with_static(void);

static int with_static_count = 0;
int with_static(void)
{
  with_static_count ++;
  return with_static_count;
}

int call_with_static(void)
{
  int tmp;
  {
     /* __blockattribute__(____fc_inlined__("with_static")) */with_static_count ++;
    tmp = with_static_count;
  }
  return tmp;
}

void builtin_acsl(void)
{
  float g_0 = 0.f;
  /*@ assert ¬\is_NaN(g_0); */ ;
  return;
}

void call_builtin_acsl(void)
{
  {
     /* __blockattribute__(____fc_inlined__("builtin_acsl")) */float g_0 =
                                                                 0.f;
    /*@ assert ¬\is_NaN(g_0); */ ;
    ;
  }
  return;
}

void f_slevel(void)
{
  /*@ slevel 0; */ ;
  return;
}

void call_f_slevel(void)
{
  {
     /* __blockattribute__(____fc_inlined__("f_slevel")) *//*@ slevel 0; */ ;
    ;
  }
  return;
}

void pre_decl(void);

extern int x;

int y;

void post_decl(void);

void middle_decl(void)
{
  {
     /* __blockattribute__(____fc_inlined__("pre_decl")) */x ++;
    y ++;
    post_decl();
    ;
  }
  return;
}

void post_decl(void);

int y = 23;
void pre_decl(void)
{
  x ++;
  y ++;
  post_decl();
  return;
}