From c2437b73e92f54be18dbd0b8a9cea6e81fe174cc Mon Sep 17 00:00:00 2001 From: Michael Beck Date: Thu, 30 Jun 2005 12:10:53 +0000 Subject: [PATCH] get_IJmp_target() and set_IJmp_target() added [r6154] --- ir/ir/irnode.c | 11 +++++++++++ ir/ir/irnode.h | 5 +++++ 2 files changed, 16 insertions(+) diff --git a/ir/ir/irnode.c b/ir/ir/irnode.c index 69c517339..e7b77be42 100644 --- a/ir/ir/irnode.c +++ b/ir/ir/irnode.c @@ -779,6 +779,17 @@ free_End (ir_node *end) { in array afterwards ... */ } +/* Return the target address of an IJmp */ +ir_node *get_IJmp_target(ir_node *ijmp) { + assert(ijmp->op == op_IJmp); + return get_irn_n(ijmp, 0); +} + +/** Sets the target address of an IJmp */ +void set_IJmp_target(ir_node *ijmp, ir_node *tgt) { + assert(ijmp->op == op_IJmp); + set_irn_n(ijmp, 0, tgt); +} /* > Implementing the case construct (which is where the constant Proj node is diff --git a/ir/ir/irnode.h b/ir/ir/irnode.h index a1cae7a57..486430499 100644 --- a/ir/ir/irnode.h +++ b/ir/ir/irnode.h @@ -332,6 +332,11 @@ void set_End_keepalive(ir_node *end, int pos, ir_node *ka); free_End() frees these data structures. */ void free_End (ir_node *end); +/** Return the target address of an IJmp */ +ir_node *get_IJmp_target(ir_node *ijmp); + +/** Sets the target address of an IJmp */ +void set_IJmp_target(ir_node *ijmp, ir_node *tgt); /* We distinguish three kinds of Cond nodes. These can be distinguished by the mode of the selector operand and an internal flag of type cond_kind. -- 2.20.1