Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Zwinkau
libfirm
Commits
e1d0a7c9
Commit
e1d0a7c9
authored
Apr 24, 2011
by
Michael Beck
Browse files
Switch irg index to type size_t, making the API more consistent.
parent
2dcaef36
Changes
7
Hide whitespace changes
Inline
Side-by-side
include/libfirm/irgraph.h
View file @
e1d0a7c9
...
...
@@ -256,7 +256,7 @@ FIRM_API long get_irg_graph_nr(const ir_graph *irg);
* smaller than get_irp_last_idx()
* Note: you cannot use this number for get_irp_irg()
*/
FIRM_API
in
t
get_irg_idx
(
const
ir_graph
*
irg
);
FIRM_API
size_
t
get_irg_idx
(
const
ir_graph
*
irg
);
/**
* Get the node for an index.
...
...
include/libfirm/irprog.h
View file @
e1d0a7c9
...
...
@@ -139,7 +139,7 @@ FIRM_API void remove_irp_irg_from_list(ir_graph *irg);
FIRM_API
void
remove_irp_irg
(
ir_graph
*
irg
);
/** returns the biggest not used irg index number */
FIRM_API
in
t
get_irp_last_idx
(
void
);
FIRM_API
size_
t
get_irp_last_idx
(
void
);
/** Returns the number of ir graphs in the irp. */
FIRM_API
size_t
get_irp_n_irgs
(
void
);
...
...
ir/ir/irgraph.c
View file @
e1d0a7c9
...
...
@@ -494,7 +494,7 @@ long get_irg_graph_nr(const ir_graph *irg)
}
#endif
in
t
get_irg_idx
(
const
ir_graph
*
irg
)
size_
t
get_irg_idx
(
const
ir_graph
*
irg
)
{
return
irg
->
index
;
}
...
...
ir/ir/irprog.c
View file @
e1d0a7c9
...
...
@@ -247,7 +247,7 @@ ir_graph *(get_irp_irg)(size_t pos)
return
_get_irp_irg
(
pos
);
}
in
t
get_irp_last_idx
(
void
)
size_
t
get_irp_last_idx
(
void
)
{
return
irp
->
max_irg_idx
;
}
...
...
ir/ir/irprog_t.h
View file @
e1d0a7c9
...
...
@@ -115,7 +115,7 @@ static inline long get_irp_new_node_nr(void)
return
irp
->
max_node_nr
++
;
}
static
inline
in
t
get_irp_new_irg_idx
(
void
)
static
inline
size_
t
get_irp_new_irg_idx
(
void
)
{
assert
(
irp
);
return
irp
->
max_irg_idx
++
;
...
...
ir/ir/irtypes.h
View file @
e1d0a7c9
...
...
@@ -522,7 +522,7 @@ struct ir_graph {
irg_edges_info_t
edge_info
;
/**< edge info for automatic outs */
ir_node
**
idx_irn_map
;
/**< Array mapping node indexes to nodes. */
in
t
index
;
/**< a unique number for each graph */
size_
t
index
;
/**< a unique number for each graph */
ir_phase
*
phases
[
PHASE_LAST
+
1
];
/**< Phase information. */
void
*
be_data
;
/**< backend can put in private data here */
...
...
@@ -597,7 +597,7 @@ struct ir_prog {
ir_exc_region_t
last_region_nr
;
/**< The last exception region number that was assigned. */
ir_label_t
last_label_nr
;
/**< The highest label number for generating unique labels. */
int
max_irg_idx
;
/**< highest unused irg index */
size_t
max_irg_idx
;
/**< highest unused irg index */
long
max_node_nr
;
/**< to generate unique numbers for nodes. */
unsigned
dump_nr
;
/**< number of program info dumps */
#ifndef NDEBUG
...
...
ir/opt/funccall.c
View file @
e1d0a7c9
...
...
@@ -987,7 +987,7 @@ static void check_for_possible_endless_loops(ir_graph *irg)
void
optimize_funccalls
(
void
)
{
size_t
i
,
n
;
in
t
last_idx
;
size_
t
last_idx
;
env_t
ctx
;
size_t
num_const
=
0
;
size_t
num_pure
=
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment