diff options
Diffstat (limited to 'validation/optim')
| -rw-r--r-- | validation/optim/bool-eq0.c | 12 | ||||
| -rw-r--r-- | validation/optim/bool-ne0.c | 12 |
2 files changed, 24 insertions, 0 deletions
diff --git a/validation/optim/bool-eq0.c b/validation/optim/bool-eq0.c new file mode 100644 index 00000000..dbc93d95 --- /dev/null +++ b/validation/optim/bool-eq0.c @@ -0,0 +1,12 @@ +int beq0(int a) { return a == 0; } +int bnotne0(int a) { return !(a != 0); } +int bnot(int a) { return !a; } + +/* + * check-name: bool-eq0 + * check-command: test-linearize -Wno-decl $file + * check-output-ignore + * + * check-output-excludes: setne\\. + * check-output-contains: seteq\\. + */ diff --git a/validation/optim/bool-ne0.c b/validation/optim/bool-ne0.c new file mode 100644 index 00000000..b8206f6c --- /dev/null +++ b/validation/optim/bool-ne0.c @@ -0,0 +1,12 @@ +int bne0(int a) { return a != 0; } +int bnoteq0(int a) { return !(a == 0); } +int bnotnot(int a) { return !(!a); } + +/* + * check-name: bool-ne0 + * check-command: test-linearize -Wno-decl $file + * check-output-ignore + * + * check-output-excludes: seteq\\. + * check-output-contains: setne\\. + */ |
