summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/i386/20000614-1.c
blob: 5e86f02e4625e5b4e183d141a443ff73cac82799 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
/* { dg-do run } */
/* { dg-options "-O2" } */

void bar(char *p)
{
}

static inline void foo (unsigned long base, unsigned char val)
{
  val ^= (1<<2);
  bar (val & (1<<5) ? "1" : "2");
  bar (val & (1<<4) ? "1" : "2");
  bar (val & (1<<3) ? "1" : "2");
  bar (val & (1<<2) ? "1" : "2");
  bar (val & (1<<1) ? "1" : "2");
  bar (val & (1<<0) ? "1" : "2");
  asm volatile ("": :"a" (val), "d" (base));
}

int main (void)
{
  foo (23, 1);
  return 0;
}