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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-stable/] [gcc-4.5.1/] [libmudflap/] [testsuite/] [libmudflap.c/] [fail22-frag.c] - Diff between revs 816 and 826

Go to most recent revision | Only display areas with differences | Details | Blame | View Log

Rev 816 Rev 826
#include <stdio.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdlib.h>
#include <string.h>
#include <string.h>
int main ()
int main ()
{
{
struct boo { int a; };
struct boo { int a; };
int c;
int c;
struct boo *b = malloc (sizeof (struct boo));
struct boo *b = malloc (sizeof (struct boo));
__mf_set_options ("-check-initialization");
__mf_set_options ("-check-initialization");
c = b->a;
c = b->a;
(void) malloc (c); /* some dummy use of c */
(void) malloc (c); /* some dummy use of c */
return 0;
return 0;
}
}
/* { dg-output "mudflap violation 1.*" } */
/* { dg-output "mudflap violation 1.*" } */
/* { dg-output "Nearby object 1.*" } */
/* { dg-output "Nearby object 1.*" } */
/* { dg-output "mudflap object.*.malloc region.*1r/0w.*" } */
/* { dg-output "mudflap object.*.malloc region.*1r/0w.*" } */
/* { dg-do run { xfail *-*-* } } */
/* { dg-do run { xfail *-*-* } } */
 
 

powered by: WebSVN 2.1.0

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