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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [g++.dg/] [opt/] [nrv12.C] - Blame information for rev 315

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

Line No. Rev Author Line
1 301 jeremybenn
/* Verify that gimple-level NRV is occurring even for RESULT_DECLs.  *./
2
/* { dg-do compile { target i?86-*-* x86_64-*-* } } */
3
/* { dg-options "-O -fdump-tree-optimized" } */
4
/* { dg-require-effective-target ilp32 } */
5
 
6
struct P
7
{
8
  long long l;
9
  int a;
10
  unsigned int b;
11
  P(long long x) : l(x) {}
12
};
13
 
14
P foo (P);
15
P bar (P);
16
 
17
P foo (P x)
18
{
19
  P y = P (-1LL);
20
  y = bar (x);
21
  return y;
22
}
23
 
24
/* { dg-final { scan-tree-dump-times "return slot optimization" 1 "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.