summaryrefslogtreecommitdiffhomepage
path: root/ir/be/besched.h
diff options
context:
space:
mode:
authorMatthias Braun <matze@braunis.de>2011-03-02 15:38:57 +0100
committerMatthias Braun <matze@braunis.de>2011-03-04 14:17:13 +0100
commita09efb2ccc91c6d720aa6aa8c5f7e3c562528b2a (patch)
treef1fd5098e7b6f1ff8f20903a68f6f77841f0cead /ir/be/besched.h
parent546bbbe4ac637fd7315b06f294432d0d09f6aecb (diff)
rework schedulers to register similar like regallocators/spillers
Diffstat (limited to 'ir/be/besched.h')
-rw-r--r--ir/be/besched.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/ir/be/besched.h b/ir/be/besched.h
index 9ef2f53..aa3d12e 100644
--- a/ir/be/besched.h
+++ b/ir/be/besched.h
@@ -228,4 +228,19 @@ static inline bool sched_comes_after(const ir_node *n1, const ir_node *n2)
#define sched_foreach_Phi(block,phi) \
for (phi = sched_first(block); is_Phi(phi); phi = sched_next(phi))
+/**
+ * Type for a function scheduling a graph
+ */
+typedef void (*schedule_func) (ir_graph *irg);
+
+/**
+ * Register new scheduling algorithm
+ */
+void be_register_scheduler(const char *name, schedule_func func);
+
+/**
+ * schedule a graph with the currenty selected scheduler.
+ */
+void be_schedule_graph(ir_graph *irg);
+
#endif