1 /* { dg-do compile } */
2 /* { dg-options "-O1 -fno-trapping-math -fdump-tree-optimized" } */
5 extern void link_error ();
14 double nan
= __builtin_nan ("");
15 float nanf
= __builtin_nanf ("");
16 long double nanl
= __builtin_nanl ("");
18 double pinf
= __builtin_inf ();
19 float pinff
= __builtin_inff ();
20 long double pinfl
= __builtin_infl ();
22 if (__builtin_finite (pinf
))
24 if (__builtin_finitef (pinff
))
26 if (__builtin_finitel (pinfl
))
29 if (__builtin_finite (nan
))
31 if (__builtin_finitef (nanf
))
33 if (__builtin_finitel (nanl
))
36 if (!__builtin_finite (4.0))
38 if (!__builtin_finitef (4.0))
40 if (!__builtin_finitel (4.0))
45 /* Check that all instances of link_error were subject to DCE. */
46 /* { dg-final { scan-tree-dump-times "link_error" 0 "optimized" } } */
47 /* { dg-final { cleanup-tree-dump "optimized" } } */