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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.2.2/] [gcc/] [testsuite/] [treelang/] [compile/] [extrafunc.tree] - Blame information for rev 154

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
// { dg-do compile }
2
// { dg-options "-O2 -fdump-tree-optimized -Wunused-function" }
3
// Check to see that unused functions get removed at -O2 and
4
// above.
5
static int foo (int bar);
6
static int baz (int aaa);
7
external_definition int ext (int bbb);
8
 
9
foo
10
{
11
        return bar;
12
}
13
 
14
baz // { dg-warning "defined but not used" }
15
{
16
        return foo (aaa);
17
}
18
 
19
ext
20
{
21
        return foo (bbb);
22
}
23
 
24
// { dg-final { scan-tree-dump-not "baz" "optimized" } }
25
// { dg-final { cleanup-tree-dump "optimized" } }

powered by: WebSVN 2.1.0

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