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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [g++.dg/] [tree-prof/] [indir-call-prof.C] - Blame information for rev 749

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

Line No. Rev Author Line
1 693 jeremybenn
/* { dg-options "-O2 -fdump-tree-optimized -fdump-ipa-profile" } */
2
 
3
struct A {
4
  A () {}
5
 
6
  virtual int AA (void)
7
  { return 0; }
8
 
9
};
10
 
11
struct B : public A {
12
  B () {}
13
 
14
  virtual int AA (void)
15
  { return 1; }
16
};
17
 
18
void * __attribute__((noinline,noclone)) wrap (void *p) { return p; }
19
int
20
main (void)
21
{
22
  A a;
23
  B b;
24
 
25
  A* p;
26
 
27
  p = (A *)wrap ((void *)&a);
28
  p->AA ();
29
 
30
  p = (B *)wrap ((void *)&b);
31
  p->AA ();
32
 
33
  return 0;
34
}
35
 
36
/* { dg-final-use { scan-ipa-dump "Indirect call -> direct call.* AA transformation on insn" "profile" } } */
37
/* { dg-final-use { scan-tree-dump-not "Invalid sum" "optimized" } } */
38
/* { dg-final-use { cleanup-tree-dump "optimized" } } */
39
/* { dg-final-use { cleanup-ipa-dump "profile" } } */

powered by: WebSVN 2.1.0

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