2018-04-30 Richard Biener <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / gcc.dg / tree-ssa / inline-1.c
blobc9398edfb54df1c8c6cc0137e00f8c53d0cb0797
1 /* { dg-do compile } */
2 /* { dg-options "-O2 -fdump-tree-optimized" } */
5 typedef struct {
6 double min;
7 double max;
8 } interval;
9 inline interval add(interval x, interval y) __attribute__((always_inline));
10 inline interval add(interval x, interval y)
12 interval r;
13 r.min = x.min + y.min;
14 r.max = x.max + y.max;
15 return r;
17 interval foo (interval a, interval b, interval c)
19 return add (a, add (b, c));
23 /* { dg-final { scan-tree-dump-times "\\(struct interval\\)" 0 "optimized"} } */