becopyopt: Inline the thin wrapper nodes_interfere(), so we do not need to fetch...
[libfirm] / include / libfirm / analyze_irg_args.h
1 /*
2  * This file is part of libFirm.
3  * Copyright (C) 2012 University of Karlsruhe.
4  */
5
6 /**
7  * @file
8  * @brief     read/write analyze of graph argument, which have mode reference
9  * @author    Beyhan Veliev
10  */
11 #ifndef FIRM_ANA_ANALYZE_IRG_ARGS_H
12 #define FIRM_ANA_ANALYZE_IRG_ARGS_H
13
14 #include "irgraph.h"
15 #include "firm_types.h"
16 #include "typerep.h"
17 #include "begin.h"
18
19 /**
20  * Returns for a method with pointer parameter
21  * if they will be read or written.
22  *
23  * @param ent  The entity that represent this method.
24  * @param pos  The position of method's parameter for that
25  *             we need information.
26
27  * If the pos'th parameter is NOT of a pointer type, ptr_access_none
28  * is returned;
29  */
30 FIRM_API ptr_access_kind get_method_param_access(ir_entity *ent, size_t pos);
31
32 /**
33  * Analyze how pointer arguments of a given
34  * ir graph are accessed.
35  *
36  * @param irg   The ir graph to analyze.
37  */
38 FIRM_API void analyze_irg_args(ir_graph *irg);
39
40 /**
41  * Returns for a method the 'weight' that every parameter
42  * has on optimization possibility. Higher values allows
43  * higher optimization with procedure cloning.
44  *
45  * The values are calculation on demand only.
46  */
47 FIRM_API unsigned get_method_param_weight(ir_entity *ent, size_t pos);
48
49 /**
50  * Analyze the parameters of a given ir graph.
51  *
52  * @param irg The ir graph to analyze.
53  */
54 FIRM_API void analyze_irg_args_weight(ir_graph *irg);
55
56 #include "end.h"
57
58 #endif