summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.target/mips/reg-var-1.c
blob: d8b8118103ac503c72b172acd21d5eecd9750875 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
/* { dg-do run } */
register int g asm ("$18");

void __attribute__((noinline))
test (void)
{
  g = g + 1;
}

int
main (void)
{
  g = 2;
  test ();
  return g != 3;
}