- BugFix: ensure that Convs are created in the right block
[libfirm] / ir / be / test / unknown_combo2.c
1 /*$ -fcombo $*/
2
3 /*
4  * This is a example for the 'Top reaches if first'
5  * problem.
6  *
7  * If the Cond is evaluated BEFORE the Phi(Unknown, 1)
8  * gets the Const 1, we decide for != and cannot revert
9  * this decision...
10  */
11 int main(int argc) {
12         int x;
13
14         if (argc) {
15                 x = 1;
16         } else {
17                 ++argc;
18         }
19
20         if (x == 1) {
21                 printf("x == 1\n");
22         } else {
23                 printf("x != 1\n");
24         }
25         return 0;
26 }