aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/pr103837.c
blob: 43593d52b6c916f0ef7e1e151b5136ef901ef44b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
/* PR rtl-optimization/103837 */
/* { dg-do compile } */
/* { dg-options "-Og -fcompare-debug -fmove-loop-invariants -fnon-call-exceptions -fexceptions -fdelete-dead-exceptions -fno-tree-dce -w" } */

unsigned long int
foo (int x)
{
  double a;
  int b;
  unsigned long int ret = a;

  for (;;)
    {
      b = !!((int) a);
      a = x;
    }

  return ret;
}