* tree-loop-distribution.c (struct partition): New field recording
[official-gcc.git] / gcc / testsuite / gcc.c-torture / compile / pr39845.c
blobbd731989d082a67a6c91a7d73a7823d04d3e5d90
2 /* { dg-options "-fno-short-enums" {target short_enums} } */
3 typedef union tree_node *tree;
4 enum tree_code { EXCESS_PRECISION_EXPR };
5 enum built_in_function { BUILT_IN_ACOS, BUILT_IN_FPCLASSIFY, BUILT_IN_ISFINITE };
6 struct tree_base {
7 __extension__ enum tree_code code : 16;
8 unsigned side_effects_flag : 1;
9 };
10 struct tree_exp {
11 tree operands[1];
13 struct tree_function_decl {
14 __extension__ enum built_in_function function_code : 11;
15 unsigned static_ctor_flag : 1;
17 union tree_node {
18 struct tree_base base;
19 struct tree_function_decl function_decl;
20 struct tree_exp exp;
22 static tree
23 convert_arguments (tree fundecl)
25 tree val = (void *)0;
26 unsigned int parmnum;
27 unsigned char type_generic_remove_excess_precision = 0;
28 switch (((fundecl)->function_decl.function_code))
30 case BUILT_IN_ISFINITE:
31 case BUILT_IN_FPCLASSIFY:
32 type_generic_remove_excess_precision = 1;
34 for (parmnum = 0;; ++parmnum)
35 if (((enum tree_code) (val)->base.code) == EXCESS_PRECISION_EXPR
36 && !type_generic_remove_excess_precision)
37 val = ((val)->exp.operands[0]);
38 return val;
40 tree
41 build_function_call_vec (tree function)
43 return convert_arguments (function);