gcc/testsuite/gcc.dg/tree-ssa/shifts-2.c
raw| 1 | /* { dg-options "-O2 -fdump-tree-optimized-raw" } */ |
| 2 | |
| 3 | unsigned int |
| 4 | f1 (unsigned int x) |
| 5 | { |
| 6 | if (x & 3) |
| 7 | __builtin_unreachable (); |
| 8 | x >>= 3; |
| 9 | return x << 4; |
| 10 | } |
| 11 | |
| 12 | unsigned int |
| 13 | f2 (unsigned int x) |
| 14 | { |
| 15 | if (x & 3) |
| 16 | __builtin_unreachable (); |
| 17 | x >>= 2; |
| 18 | return x << 1; |
| 19 | } |
| 20 | |
| 21 | /* { dg-final { scan-tree-dump-times {<rshift_expr,} 2 "optimized" } } */ |