view gcc/testsuite/gcc.c-torture/compile/pr52533.c @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents 04ced10e8804
children
line wrap: on
line source

/* PR tree-optimization/52533 */

int
foo (unsigned char x)
{
  if (x <= 9)
    return '0' + x;
  else if (x <= 15)
    return 'a' + (x - 10);
  else
    return 0;
}

void
bar (unsigned char x, unsigned char *y)
{
  y[0] = foo ((unsigned char) (x >> 4));
  y[1] = foo ((unsigned char) (x & 0x0f));
}