aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.target/xstormy16/data_below100/13_if0_b100b_bit_3.c
blob: cbda60c274e8d918230abc2f89438d7467046017 (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
25
26
27
28
29
/* { dg-options { -nostartfiles below100.o -Tbelow100.ld -O2 } } */
/* { dg-final { scan-assembler "b\[np\] B100A,#3," } } */
/* { dg-final { scan-assembler "b\[np\] B100B,#3," } } */

char acDummy[0xf0] __attribute__ ((__BELOW100__));
unsigned char B100A __attribute__ ((__BELOW100__)) = 0x34;
unsigned char *pA = &B100A;
unsigned char B100B __attribute__ ((__BELOW100__)) = 0xcb;
unsigned char *pB = &B100B;

char *
Do (void)
{
  if (!(B100A & 0x08))
    {
      if (!(B100B & 0x08))
	return "Fail";
      else
	return "Success";
    }
  else
    return "Fail";
}

int
main (void)
{
  return Do ()[0] == 'F';
}