Commit cb13d128 authored by Christoph Mallon's avatar Christoph Mallon
Browse files

be: Pass an ir_graph* to the arch_pretrans_nodes callback instead of using current_ir_graph.

parent fb2b9fc2
......@@ -339,7 +339,7 @@ static void transform_nodes(ir_graph *irg, arch_pretrans_nodes *pre_transform)
pre_transform_anchor(irg, anchor_frame);
if (pre_transform)
pre_transform();
pre_transform(irg);
/* process worklist (this should transform all nodes in the graph) */
while (! waitq_empty(env.worklist)) {
......
......@@ -18,7 +18,7 @@
/**
* A callback to pre-transform some nodes before the transformation starts.
*/
typedef void (arch_pretrans_nodes)(void);
typedef void (arch_pretrans_nodes)(ir_graph*);
/**
* The type of a transform function.
......
......@@ -5398,9 +5398,8 @@ static void register_transformers(void)
/**
* Pre-transform all unknown and noreg nodes.
*/
static void ia32_pretransform_node(void)
static void ia32_pretransform_node(ir_graph *const irg)
{
ir_graph *irg = current_ir_graph;
ia32_irg_data_t *irg_data = ia32_get_irg_data(irg);
irg_data->noreg_gp = be_pre_transform_node(irg_data->noreg_gp);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment