// verifast_options{disable_overflow_check target:ILP32} extern void abort(void);//@ requires true; //@ ensures true; extern void __assert_fail(const char *, const char *, unsigned int, const char *) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); void reach_error() //@ requires false; //@ ensures true; { __assert_fail("0", "trex04.c", 3, "reach_error"); } extern void abort(void); void assume_abort_if_not(int cond) //@ requires true; //@ ensures true; { if(!cond) {abort();} } void __VERIFIER_assert(int cond) //@ requires (cond != 0); //@ ensures (cond != 0); { if (!(cond)) { ERROR: {reach_error();abort();} } return; } extern _Bool __VERIFIER_nondet_bool();//@ requires true; //@ ensures true; extern int __VERIFIER_nondet_int();//@ requires true; //@ ensures true; void foo()//@ requires true; //@ ensures true; { int y=0; _Bool c1=__VERIFIER_nondet_bool(), c2=__VERIFIER_nondet_bool(); if (c1) y++; if (c2) y--; else y+=10; } int main()//@ requires module(trex04__verifast_instrumented_modified, true); //@ ensures junk(); { int d = 1; int x = __VERIFIER_nondet_int(); if (!(x <= 1000000 && x >= -1000000)) return 0; _Bool c1=__VERIFIER_nondet_bool(), c2=__VERIFIER_nondet_bool(); if (c1) d = d - 1; if (c2) foo(); c1=__VERIFIER_nondet_bool(), c2=__VERIFIER_nondet_bool(); if (c1) foo(); if (c2) d = d - 1; while(x>0)//@ invariant true; { x=x-d; } __VERIFIER_assert(x<=0); }