Skip to content
Snippets Groups Projects
copy_logic.res.oracle 2.28 KiB
[kernel] Parsing copy_logic.i (no preprocessing)
[kernel] copy_logic.i:5: Warning: 
  parsing obsolete ACSL construct 'logic declaration'. 'an axiomatic block' should be used instead.
[kernel] copy_logic.i:7: Warning: 
  parsing obsolete ACSL construct 'logic declaration'. 'an axiomatic block' should be used instead.
[eva] Analyzing a complete application starting at main
[eva] Computing initial state
[eva] Initial state computed
[eva:initial-state] Values of globals at initialization
  
[eva:alarm] copy_logic.i:16: Warning: assertion got status unknown.
[eva:alarm] copy_logic.i:17: Warning: 
  signed overflow. assert y + x ≤ 2147483647;
[eva] copy_logic.i:18: 
  cannot evaluate ACSL term, unsupported ACSL construct: logic function f
[eva:alarm] copy_logic.i:18: Warning: assertion got status unknown.
[eva] done for function main
[eva] ====== VALUES COMPUTED ======
[eva:final-states] Values at end of function main:
  y ∈ [-2147483606..2147483647]
  __retres ∈ {0}
[eva:summary] ====== ANALYSIS SUMMARY ======
  ----------------------------------------------------------------------------
  1 function analyzed (out of 1): 100% coverage.
  In this function, 6 statements reached (out of 6): 100% coverage.
  ----------------------------------------------------------------------------
  No errors or warnings raised during the analysis.
  ----------------------------------------------------------------------------
  1 alarm generated by the analysis:
       1 integer overflow
  ----------------------------------------------------------------------------
  Evaluation of the logical properties reached by the analysis:
    Assertions        0 valid     2 unknown     0 invalid      2 total
    Preconditions     0 valid     0 unknown     0 invalid      0 total
  0% of the logical properties reached have been proven.
  ----------------------------------------------------------------------------
/* Generated by Frama-C */
/*@ predicate p(int x) ;
 */
/*@ predicate q(int x) = x ≡ 42;
 */
/*@ logic int f(int y) ;
 */
/*@ logic ℤ g(int x) = x + 42;
 */
/*@ frees x; */
void f(int *x);

int main(int x)
{
  int __retres;
  int y = 42;
  /*@ assert q(y) ∧ p(x); */ ;
  /*@ assert Eva: signed_overflow: y + x ≤ 2147483647; */
  y += x;
  /*@ assert g(x) ≡ f(y); */ ;
  __retres = 0;
  return __retres;
}