1 /* { dg-do compile } */
2 /* { dg-options "-O1 -fdump-tree-dom2" } */
4 extern void abort (void);
6 typedef struct rtx_def *rtx;
8 typedef struct rtvec_def *rtvec;
10 typedef union tree_node *tree;
17 struct tree_common common;
19 extern tree current_function_decl;
20 struct cgraph_rtl_info
24 struct cgraph_rtl_info *cgraph_rtl_info (tree);
26 mark_constant_function (void)
29 int nonlocal_memory_referenced;
31 if (current_function_decl->common.code != 42)
34 cgraph_rtl_info (current_function_decl)->pure_function = 1;
37 /* current_function_decl should be loaded once into a temporary
38 and the temporary used as the argument to cgraph_rtl_info.
39 This if we find current_function_decl used as an argument, then
41 /* { dg-final { scan-tree-dump-times "\\(current_function_decl\\)" 0 "dom2"} } */
42 /* { dg-final { cleanup-tree-dump "dom2" } } */