diff options
| author | Luc Van Oostenryck <luc.vanoostenryck@gmail.com> | 2020-11-06 22:20:38 +0100 |
|---|---|---|
| committer | Luc Van Oostenryck <luc.vanoostenryck@gmail.com> | 2020-11-22 15:30:12 +0100 |
| commit | eda5c718f55ac471d456752ff7138f1249289dc7 (patch) | |
| tree | a897d3f60fab63dd9f070e96ea86b18164d91d8d /validation/optim/cse-not02.c | |
| parent | b59dbdaf37400cc57e21f8b4bc72a8092d0a2332 (diff) | |
| download | sparse-dev-eda5c718f55ac471d456752ff7138f1249289dc7.tar.gz | |
not: add testcases for canonicalization & simplification of negations
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
Diffstat (limited to 'validation/optim/cse-not02.c')
| -rw-r--r-- | validation/optim/cse-not02.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/validation/optim/cse-not02.c b/validation/optim/cse-not02.c new file mode 100644 index 00000000..aa54a375 --- /dev/null +++ b/validation/optim/cse-not02.c @@ -0,0 +1,12 @@ +int and(int a, int b) { return ((a == b) & (a != b)) == 0; } +int ior(int a, int b) { return ((a == b) | (a != b)) == 1; } +int xor(int a, int b) { return ((a == b) ^ (a != b)) == 1; } + +/* + * check-name: cse-not02 + * check-command: test-linearize -Wno-decl $file + * check-known-to-fail + * + * check-output-ignore + * check-output-returns: 1 + */ |
