summaryrefslogtreecommitdiffhomepage
path: root/ir/be/beinfo.c
diff options
context:
space:
mode:
authorMatthias Braun <matze@braunis.de>2011-08-15 13:41:11 +0200
committerMatthias Braun <matze@braunis.de>2011-08-15 14:03:03 +0200
commit41dc42afc8d00e0f364711ed0c919e4e29cb20e4 (patch)
tree89b7e8ab7e295f9fcfe18a40bfb001b91c4e5f34 /ir/be/beinfo.c
parented7cc1daadbdd28b5550157080dcbbbea348c097 (diff)
big refactoring of arch_XXX functions
This tries to get the names in a consistent format. We basically have 2 views on register allocation/constraints now: 1) Register Requirements and Assigments are per-instruction. Each instruction has requirements on its inputs and outputs, register get assigned for outputs of an instruction (assignment is an attribute of an instruction, not of the Proj-nodes). The internal datastructures model this form! The functions here have the form: arch_get_irn_register_req_in(node, input_nr) arch_get_irn_register_in(node, input_nr) arch_get_irn_register_req_out(node, output_nr) arch_set_irn_register_out(node, output_nr, register) 2) Register Requirements and Assignments are on firm-values. This view allows to query/assign requirements and registers at the Proj nodes instead of the repsective predecessors. This is a convenience interface modeled on top of the other! The functions have the form: arch_get_irn_register_req(node) arch_get_irn_register(node) arch_set_irn_register(node, register)
Diffstat (limited to 'ir/be/beinfo.c')
-rw-r--r--ir/be/beinfo.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/ir/be/beinfo.c b/ir/be/beinfo.c
index 7027e77..10ba2e1 100644
--- a/ir/be/beinfo.c
+++ b/ir/be/beinfo.c
@@ -42,7 +42,7 @@ void be_info_new_node(ir_node *node)
struct obstack *obst;
backend_info_t *info;
- /* Projs need no be info, their tuple holds all information */
+ /* Projs need no be info, all info is fetched from their predecessor */
if (is_Proj(node))
return;
@@ -57,17 +57,15 @@ void be_info_new_node(ir_node *node)
* backend graphs
*/
switch (get_irn_opcode(node)) {
- case iro_Bad:
case iro_Block:
case iro_Dummy:
- case iro_End:
- case iro_Unknown:
- info->flags |= arch_irn_flags_not_scheduled;
- break;
case iro_NoMem:
case iro_Anchor:
case iro_Pin:
case iro_Sync:
+ case iro_Bad:
+ case iro_End:
+ case iro_Unknown:
info->flags |= arch_irn_flags_not_scheduled;
info->out_infos = NEW_ARR_D(reg_out_info_t, obst, 1);
memset(info->out_infos, 0, 1 * sizeof(info->out_infos[0]));