-
Notifications
You must be signed in to change notification settings - Fork 75
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
62 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
// SKIP PARAM: --enable ana.int.interval --set ana.activated[+] apron --set ana.apron.domain polyhedra --enable ana.apron.strengthening --set ana.activated[+] unassume --set witness.yaml.unassume 63-hh-ex3-term.yml --enable ana.widen.tokens --disable witness.invariant.other --enable exp.arg | ||
extern void __assert_fail (const char *__assertion, const char *__file, | ||
unsigned int __line, const char *__function) | ||
__attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); | ||
extern void __assert_perror_fail (int __errnum, const char *__file, | ||
unsigned int __line, const char *__function) | ||
__attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); | ||
extern void __assert (const char *__assertion, const char *__file, int __line) | ||
__attribute__ ((__nothrow__ , __leaf__)) __attribute__ ((__noreturn__)); | ||
|
||
extern void abort(void); | ||
void reach_error() { ((void) sizeof ((0) ? 1 : 0), __extension__ ({ if (0) ; else __assert_fail ("0", "hh-ex3.c", 3, __extension__ __PRETTY_FUNCTION__); })); } | ||
void __VERIFIER_assert(int cond) { if(!(cond)) { ERROR: {reach_error();abort();} } } | ||
int main() { | ||
int i = 0; | ||
while (i < 4) { | ||
int j = 0; | ||
while (j < 4) { | ||
i++; | ||
j++; | ||
__VERIFIER_assert(0 <= j); | ||
__VERIFIER_assert(j <= i); | ||
__VERIFIER_assert(i <= j + 3); | ||
__VERIFIER_assert(j <= 4); | ||
} | ||
__VERIFIER_assert(0 <= j); | ||
__VERIFIER_assert(j <= i); | ||
__VERIFIER_assert(i <= j + 3); | ||
__VERIFIER_assert(j <= 4); | ||
i = i - j + 1; | ||
} | ||
return 0; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
- entry_type: location_invariant | ||
metadata: | ||
format_version: "0.1" | ||
uuid: d834761a-d0d7-4fea-bf42-2ff2b9a19143 | ||
creation_time: 2022-10-12T10:59:25Z | ||
producer: | ||
name: Simmo Saan | ||
version: n/a | ||
task: | ||
input_files: | ||
- /home/vagrant/eval-prec/prec/hh-ex3.i | ||
input_file_hashes: | ||
/home/vagrant/eval-prec/prec/hh-ex3.i: 9c984e89a790b595d2b37ca8a05e5967a15130592cb2567fac2fae4aff668a4f | ||
data_model: LP64 | ||
language: C | ||
location: | ||
file_name: 63-hh-ex3-term.c | ||
file_hash: 9c984e89a790b595d2b37ca8a05e5967a15130592cb2567fac2fae4aff668a4f | ||
line: 17 | ||
column: 4 | ||
function: main | ||
location_invariant: | ||
string: 0 <= i && i <= 3 | ||
type: assertion | ||
format: C |