extern void *calloc(unsigned int nmemb, unsigned int size); extern void free(void *); extern int __VERIFIER_nondet_int(void); extern void abort(void); void assume_abort_if_not(int cond) { if(!cond) {abort();} } extern void abort(void); extern void __assert_fail(const char *, const char *, unsigned int, const char *) __attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); void reach_error() { __assert_fail("0", "lcp.c", 11, "reach_error"); } void __VERIFIER_assert(int cond) { if(!cond) {reach_error();abort();} } int lcp(int *a, int n, int x, int y) { int l = 0; while (x+l= 0 && n < (1 << 30)); int *a = calloc(n, sizeof(int)); int x = __VERIFIER_nondet_int(); int y = __VERIFIER_nondet_int(); assume_abort_if_not(x >= 0 && y >= 0); int l = lcp(a, n, x, y); check(a, n, x, y, l); free(a); return 0; }