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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [warn/] [pr30636.C] - Blame information for rev 774

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

Line No. Rev Author Line
1 693 jeremybenn
/* { dg-do compile } */
2
/* { dg-options "-O2 -Warray-bounds" } */
3
 
4
typedef char one_buffer[512];
5
static one_buffer emergency_buffer[4];
6
 
7
void free_exception (void *vptr)
8
{
9
  char *base = (char *) &emergency_buffer[0][0];
10
  char *ptr = (char *) vptr;
11
  if (ptr >= base && ptr < base + sizeof (emergency_buffer)) /* { dg-bogus "subscript" } */
12
    {
13
      /* Do something. */
14
      __builtin_exit (0);
15
    }
16
}
17
 

powered by: WebSVN 2.1.0

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