diff options
Diffstat (limited to 'validation/optim')
| -rw-r--r-- | validation/optim/dup-cond0.c | 20 | ||||
| -rw-r--r-- | validation/optim/phi-ret.c | 22 |
2 files changed, 42 insertions, 0 deletions
diff --git a/validation/optim/dup-cond0.c b/validation/optim/dup-cond0.c new file mode 100644 index 00000000..dc4991cb --- /dev/null +++ b/validation/optim/dup-cond0.c @@ -0,0 +1,20 @@ +struct s { + int f; +}; + +static int foo(struct s *s) +{ + if (s->f) + return 0; + else if (!s->f) + return 4; +} + +/* + * check-name: dup-cond0 + * check-command: test-linearize -Wno-decl $file + * check-known-to-fail + * + * check-output-ignore + * check-output-contains: select + */ diff --git a/validation/optim/phi-ret.c b/validation/optim/phi-ret.c new file mode 100644 index 00000000..204366a9 --- /dev/null +++ b/validation/optim/phi-ret.c @@ -0,0 +1,22 @@ +int foo(int p, int q, int v) +{ + if (q) { + if (p) { + v = p; + p = 0; + } + } else + p = 0; + if (p) + return v + 1; + return q; +} + +/* + * check-name: phi-ret + * check-command: test-linearize -Wno-decl $file + * check-known-to-fail + * + * check-output-ignore + * check-output-excludes: phi\\. + */ |
