OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gcc.dg/] [debug/] [pr36690-2.c] - Blame information for rev 774

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 689 jeremybenn
/* PR debug/36690 */
2
/* Verify that breakpoint can be put on goto f1, it is hit and
3
   varz at that spot is defined and contains 5.  Nowhere else
4
   in the function should be varz in the scope.
5
   This version of the test just checks that it can be compiled, linked
6
   and executed, further testing is done in corresponding gcc.dg/dwarf2/
7
   test and hopefully in gdb testsuite.  */
8
/* { dg-do run } */
9
/* { dg-options "-O0 -g -dA" } */
10
 
11
int cnt;
12
 
13
void
14
bar (int i)
15
{
16
  cnt += i;
17
}
18
 
19
void
20
foo (int i)
21
{
22
  if (!i)
23
    bar (0);
24
  else
25
    {
26
      static int varz = 5;
27
      goto f1;
28
    }
29
  bar (1);
30
f1:
31
  bar (2);
32
}
33
 
34
int
35
main (void)
36
{
37
  foo (0);
38
  foo (1);
39
  return 0;
40
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.