Commit 110ec5d1 authored by Michael Beck's avatar Michael Beck
Browse files

rename type entity into ir_entity

parent 213c4b9f
...@@ -296,11 +296,11 @@ typedef struct { ...@@ -296,11 +296,11 @@ typedef struct {
ir_graph *irg; /**< The associated graph. */ ir_graph *irg; /**< The associated graph. */
} ia32_abi_env_t; } ia32_abi_env_t;
static entity *ia32_get_frame_entity(const void *self, const ir_node *irn) { static ir_entity *ia32_get_frame_entity(const void *self, const ir_node *irn) {
return is_ia32_irn(irn) ? get_ia32_frame_ent(irn) : NULL; return is_ia32_irn(irn) ? get_ia32_frame_ent(irn) : NULL;
} }
static void ia32_set_frame_entity(const void *self, ir_node *irn, entity *ent) { static void ia32_set_frame_entity(const void *self, ir_node *irn, ir_entity *ent) {
set_ia32_frame_ent(irn, ent); set_ia32_frame_ent(irn, ent);
} }
...@@ -512,9 +512,9 @@ static ir_type *ia32_abi_get_between_type(void *self) ...@@ -512,9 +512,9 @@ static ir_type *ia32_abi_get_between_type(void *self)
ia32_abi_env_t *env = self; ia32_abi_env_t *env = self;
if (! between_type) { if (! between_type) {
entity *old_bp_ent; ir_entity *old_bp_ent;
entity *ret_addr_ent; ir_entity *ret_addr_ent;
entity *omit_fp_ret_addr_ent; ir_entity *omit_fp_ret_addr_ent;
ir_type *old_bp_type = new_type_primitive(IDENT("bp"), mode_P); ir_type *old_bp_type = new_type_primitive(IDENT("bp"), mode_P);
ir_type *ret_addr_type = new_type_primitive(IDENT("return_addr"), mode_P); ir_type *ret_addr_type = new_type_primitive(IDENT("return_addr"), mode_P);
...@@ -984,7 +984,7 @@ static void ia32_before_ra(void *self) { ...@@ -984,7 +984,7 @@ static void ia32_before_ra(void *self) {
*/ */
static void transform_to_Load(ia32_transform_env_t *env) { static void transform_to_Load(ia32_transform_env_t *env) {
ir_node *irn = env->irn; ir_node *irn = env->irn;
entity *ent = be_get_frame_entity(irn); ir_entity *ent = be_get_frame_entity(irn);
ir_mode *mode = env->mode; ir_mode *mode = env->mode;
ir_node *noreg = ia32_new_NoReg_gp(env->cg); ir_node *noreg = ia32_new_NoReg_gp(env->cg);
ir_node *sched_point = NULL; ir_node *sched_point = NULL;
...@@ -1038,7 +1038,7 @@ static void transform_to_Load(ia32_transform_env_t *env) { ...@@ -1038,7 +1038,7 @@ static void transform_to_Load(ia32_transform_env_t *env) {
*/ */
static void transform_to_Store(ia32_transform_env_t *env) { static void transform_to_Store(ia32_transform_env_t *env) {
ir_node *irn = env->irn; ir_node *irn = env->irn;
entity *ent = be_get_frame_entity(irn); ir_entity *ent = be_get_frame_entity(irn);
ir_mode *mode = env->mode; ir_mode *mode = env->mode;
ir_node *noreg = ia32_new_NoReg_gp(env->cg); ir_node *noreg = ia32_new_NoReg_gp(env->cg);
ir_node *nomem = new_rd_NoMem(env->irg); ir_node *nomem = new_rd_NoMem(env->irg);
...@@ -1085,7 +1085,7 @@ static void transform_to_Store(ia32_transform_env_t *env) { ...@@ -1085,7 +1085,7 @@ static void transform_to_Store(ia32_transform_env_t *env) {
exchange(irn, proj); exchange(irn, proj);
} }
static ir_node *create_push(ia32_transform_env_t *env, ir_node *schedpoint, ir_node *sp, ir_node *mem, entity *ent) { static ir_node *create_push(ia32_transform_env_t *env, ir_node *schedpoint, ir_node *sp, ir_node *mem, ir_entity *ent) {
ir_node *noreg = ia32_new_NoReg_gp(env->cg); ir_node *noreg = ia32_new_NoReg_gp(env->cg);
ir_node *frame = get_irg_frame(env->irg); ir_node *frame = get_irg_frame(env->irg);
...@@ -1101,7 +1101,7 @@ static ir_node *create_push(ia32_transform_env_t *env, ir_node *schedpoint, ir_n ...@@ -1101,7 +1101,7 @@ static ir_node *create_push(ia32_transform_env_t *env, ir_node *schedpoint, ir_n
return push; return push;
} }
static ir_node *create_pop(ia32_transform_env_t *env, ir_node *schedpoint, ir_node *sp, entity *ent) { static ir_node *create_pop(ia32_transform_env_t *env, ir_node *schedpoint, ir_node *sp, ir_entity *ent) {
ir_node *noreg = ia32_new_NoReg_gp(env->cg); ir_node *noreg = ia32_new_NoReg_gp(env->cg);
ir_node *frame = get_irg_frame(env->irg); ir_node *frame = get_irg_frame(env->irg);
...@@ -1148,7 +1148,7 @@ static void transform_MemPerm(ia32_transform_env_t *env) { ...@@ -1148,7 +1148,7 @@ static void transform_MemPerm(ia32_transform_env_t *env) {
// create pushs // create pushs
for(i = 0; i < arity; ++i) { for(i = 0; i < arity; ++i) {
entity *ent = be_get_MemPerm_in_entity(node, i); ir_entity *ent = be_get_MemPerm_in_entity(node, i);
ir_type *enttype = get_entity_type(ent); ir_type *enttype = get_entity_type(ent);
int entbits = get_type_size_bits(enttype); int entbits = get_type_size_bits(enttype);
ir_node *mem = get_irn_n(node, i + 1); ir_node *mem = get_irn_n(node, i + 1);
...@@ -1170,7 +1170,7 @@ static void transform_MemPerm(ia32_transform_env_t *env) { ...@@ -1170,7 +1170,7 @@ static void transform_MemPerm(ia32_transform_env_t *env) {
// create pops // create pops
for(i = arity - 1; i >= 0; --i) { for(i = arity - 1; i >= 0; --i) {
entity *ent = be_get_MemPerm_out_entity(node, i); ir_entity *ent = be_get_MemPerm_out_entity(node, i);
ir_type *enttype = get_entity_type(ent); ir_type *enttype = get_entity_type(ent);
int entbits = get_type_size_bits(enttype); int entbits = get_type_size_bits(enttype);
......
...@@ -99,8 +99,8 @@ typedef struct _ia32_code_gen_t { ...@@ -99,8 +99,8 @@ typedef struct _ia32_code_gen_t {
const be_irg_t *birg; /**< The be-irg (contains additional information about the irg) */ const be_irg_t *birg; /**< The be-irg (contains additional information about the irg) */
ir_node **blk_sched; /**< an array containing the scheduled blocks */ ir_node **blk_sched; /**< an array containing the scheduled blocks */
ia32_optimize_t opt; /**< contains optimization information */ ia32_optimize_t opt; /**< contains optimization information */
entity *fp_to_gp; /**< allocated entity for fp to gp conversion */ ir_entity *fp_to_gp; /**< allocated entity for fp to gp conversion */
entity *gp_to_fp; /**< allocated entity for gp to fp conversion */ ir_entity *gp_to_fp; /**< allocated entity for gp to fp conversion */
nodeset *kill_conv; /**< Remember all convs to be killed */ nodeset *kill_conv; /**< Remember all convs to be killed */
int arch; /**< instruction architecture */ int arch; /**< instruction architecture */
int opt_arch; /**< optimize for architecture */ int opt_arch; /**< optimize for architecture */
...@@ -150,11 +150,11 @@ typedef struct _ia32_transform_env_t { ...@@ -150,11 +150,11 @@ typedef struct _ia32_transform_env_t {
} ia32_transform_env_t; } ia32_transform_env_t;
typedef struct _ia32_intrinsic_env_t { typedef struct _ia32_intrinsic_env_t {
ir_graph *irg; /**< the irg, these entities belong to */ ir_graph *irg; /**< the irg, these entities belong to */
entity *ll_div_op1; /**< entity for first div operand (move into FPU) */ ir_entity *ll_div_op1; /**< entity for first div operand (move into FPU) */
entity *ll_div_op2; /**< entity for second div operand (move into FPU) */ ir_entity *ll_div_op2; /**< entity for second div operand (move into FPU) */
entity *ll_d_conv; /**< entity for converts ll -> d */ ir_entity *ll_d_conv; /**< entity for converts ll -> d */
entity *d_ll_conv; /**< entity for converts d -> ll */ ir_entity *d_ll_conv; /**< entity for converts d -> ll */
} ia32_intrinsic_env_t; } ia32_intrinsic_env_t;
/** /**
...@@ -188,8 +188,8 @@ void ia32_handle_intrinsics(void); ...@@ -188,8 +188,8 @@ void ia32_handle_intrinsics(void);
* @param omode the output mode of the emulated opcode * @param omode the output mode of the emulated opcode
* @param context the context parameter * @param context the context parameter
*/ */
entity *ia32_create_intrinsic_fkt(ir_type *method, const ir_op *op, ir_entity *ia32_create_intrinsic_fkt(ir_type *method, const ir_op *op,
const ir_mode *imode, const ir_mode *omode, const ir_mode *imode, const ir_mode *omode,
void *context); void *context);
#endif /* _BEARCH_IA32_T_H_ */ #endif /* _BEARCH_IA32_T_H_ */
...@@ -1690,7 +1690,7 @@ void emit_ia32_Conv_I2I8Bit(const ir_node *irn, ia32_emit_env_t *emit_env) { ...@@ -1690,7 +1690,7 @@ void emit_ia32_Conv_I2I8Bit(const ir_node *irn, ia32_emit_env_t *emit_env) {
*/ */
static void emit_be_Call(const ir_node *irn, ia32_emit_env_t *emit_env) { static void emit_be_Call(const ir_node *irn, ia32_emit_env_t *emit_env) {
FILE *F = emit_env->out; FILE *F = emit_env->out;
entity *ent = be_Call_get_entity(irn); ir_entity *ent = be_Call_get_entity(irn);
char cmd_buf[SNPRINTF_BUF_LEN], cmnt_buf[SNPRINTF_BUF_LEN]; char cmd_buf[SNPRINTF_BUF_LEN], cmnt_buf[SNPRINTF_BUF_LEN];
if (ent) { if (ent) {
...@@ -2279,7 +2279,7 @@ static void ia32_gen_block(ir_node *block, ir_node *last_block, ia32_emit_env_t ...@@ -2279,7 +2279,7 @@ static void ia32_gen_block(ir_node *block, ir_node *last_block, ia32_emit_env_t
* Emits code for function start. * Emits code for function start.
*/ */
static void ia32_emit_func_prolog(FILE *F, ir_graph *irg, ia32_emit_env_t *emit_env) { static void ia32_emit_func_prolog(FILE *F, ir_graph *irg, ia32_emit_env_t *emit_env) {
entity *irg_ent = get_irg_entity(irg); ir_entity *irg_ent = get_irg_entity(irg);
const char *irg_name = get_entity_ld_name(irg_ent); const char *irg_name = get_entity_ld_name(irg_ent);
cpu_support cpu = emit_env->isa->opt_arch; cpu_support cpu = emit_env->isa->opt_arch;
const be_irg_t *birg = emit_env->cg->birg; const be_irg_t *birg = emit_env->cg->birg;
......
...@@ -254,7 +254,7 @@ static void dump_atomic_init(obstack_t *obst, ir_node *init) ...@@ -254,7 +254,7 @@ static void dump_atomic_init(obstack_t *obst, ir_node *init)
* @param ent The entity * @param ent The entity
* @return 1 if it is a string constant, 0 otherwise * @return 1 if it is a string constant, 0 otherwise
*/ */
static int ent_is_string_const(entity *ent) static int ent_is_string_const(ir_entity *ent)
{ {
int res = 0; int res = 0;
ir_type *ty; ir_type *ty;
...@@ -305,7 +305,7 @@ static int ent_is_string_const(entity *ent) ...@@ -305,7 +305,7 @@ static int ent_is_string_const(entity *ent)
* @param obst The obst to dump on. * @param obst The obst to dump on.
* @param ent The entity to dump. * @param ent The entity to dump.
*/ */
static void dump_string_cst(obstack_t *obst, entity *ent) static void dump_string_cst(obstack_t *obst, ir_entity *ent)
{ {
int i, n; int i, n;
...@@ -336,7 +336,7 @@ static void dump_string_cst(obstack_t *obst, entity *ent) ...@@ -336,7 +336,7 @@ static void dump_string_cst(obstack_t *obst, entity *ent)
obstack_printf(obst, "\"\n"); obstack_printf(obst, "\"\n");
} }
static void dump_array_init(obstack_t *obst, entity *ent) static void dump_array_init(obstack_t *obst, ir_entity *ent)
{ {
const ir_type *ty = get_entity_type(ent); const ir_type *ty = get_entity_type(ent);
int i; int i;
...@@ -345,7 +345,7 @@ static void dump_array_init(obstack_t *obst, entity *ent) ...@@ -345,7 +345,7 @@ static void dump_array_init(obstack_t *obst, entity *ent)
/* potential spare values should be already included! */ /* potential spare values should be already included! */
for (i = 0; i < get_compound_ent_n_values(ent); ++i) { for (i = 0; i < get_compound_ent_n_values(ent); ++i) {
entity *step = get_compound_ent_value_member(ent, i); ir_entity *step = get_compound_ent_value_member(ent, i);
ir_type *stype = get_entity_type(step); ir_type *stype = get_entity_type(step);
if (get_type_mode(stype)) { if (get_type_mode(stype)) {
...@@ -379,7 +379,7 @@ typedef struct { ...@@ -379,7 +379,7 @@ typedef struct {
} v; } v;
} normal_or_bitfield; } normal_or_bitfield;
static void dump_compound_init(obstack_t *obst, entity *ent) static void dump_compound_init(obstack_t *obst, ir_entity *ent)
{ {
ir_type *ty = get_entity_type(ent); ir_type *ty = get_entity_type(ent);
normal_or_bitfield *vals; normal_or_bitfield *vals;
...@@ -407,7 +407,7 @@ static void dump_compound_init(obstack_t *obst, entity *ent) ...@@ -407,7 +407,7 @@ static void dump_compound_init(obstack_t *obst, entity *ent)
int offset = get_compound_ent_value_offset_bytes(ent, i); int offset = get_compound_ent_value_offset_bytes(ent, i);
int offset_bits = get_compound_ent_value_offset_bit_remainder(ent, i); int offset_bits = get_compound_ent_value_offset_bit_remainder(ent, i);
ir_node *value = get_compound_ent_value(ent, i); ir_node *value = get_compound_ent_value(ent, i);
entity *last_ent = get_compound_graph_path_node(path, path_len - 1); ir_entity *last_ent = get_compound_graph_path_node(path, path_len - 1);
int value_len = get_type_size_bits(get_entity_type(last_ent)); int value_len = get_type_size_bits(get_entity_type(last_ent));
if(offset_bits != 0 || value_len % 8 != 0) { if(offset_bits != 0 || value_len % 8 != 0) {
...@@ -469,7 +469,7 @@ static void dump_compound_init(obstack_t *obst, entity *ent) ...@@ -469,7 +469,7 @@ static void dump_compound_init(obstack_t *obst, entity *ent)
} }
} }
static void dump_global(ia32_decl_env_t *env, entity *ent) static void dump_global(ia32_decl_env_t *env, ir_entity *ent)
{ {
obstack_t *obst; obstack_t *obst;
ir_type *type = get_entity_type(ent); ir_type *type = get_entity_type(ent);
...@@ -548,7 +548,7 @@ static void ia32_dump_globals(ir_type *gt, ia32_decl_env_t *env) ...@@ -548,7 +548,7 @@ static void ia32_dump_globals(ir_type *gt, ia32_decl_env_t *env)
int i, n = get_compound_n_members(gt); int i, n = get_compound_n_members(gt);
for (i = 0; i < n; i++) { for (i = 0; i < n; i++) {
entity *ent = get_compound_member(gt, i); ir_entity *ent = get_compound_member(gt, i);
dump_global(env, ent); dump_global(env, ent);
} }
} }
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
static i_record *intrinsics; static i_record *intrinsics;
/** An array to cache all entities */ /** An array to cache all entities */
static entity *i_ents[iro_MaxOpcode]; static ir_entity *i_ents[iro_MaxOpcode];
/* /*
* Maps all intrinsic calls that the backend support * Maps all intrinsic calls that the backend support
...@@ -321,24 +321,24 @@ typedef enum { ...@@ -321,24 +321,24 @@ typedef enum {
*/ */
static int DivMod_mapper(ir_node *call, void *ctx, ia32_intrinsic_divmod_t dmtp) { static int DivMod_mapper(ir_node *call, void *ctx, ia32_intrinsic_divmod_t dmtp) {
ia32_intrinsic_env_t *env = ctx; ia32_intrinsic_env_t *env = ctx;
ir_graph *irg = current_ir_graph; ir_graph *irg = current_ir_graph;
dbg_info *dbg = get_irn_dbg_info(call); dbg_info *dbg = get_irn_dbg_info(call);
ir_node *block = get_nodes_block(call); ir_node *block = get_nodes_block(call);
ir_node **params = get_Call_param_arr(call); ir_node **params = get_Call_param_arr(call);
ir_type *method = get_Call_type(call); ir_type *method = get_Call_type(call);
ir_node *a_l = params[BINOP_Left_Low]; ir_node *a_l = params[BINOP_Left_Low];
ir_node *a_h = params[BINOP_Left_High]; ir_node *a_h = params[BINOP_Left_High];
ir_node *b_l = params[BINOP_Right_Low]; ir_node *b_l = params[BINOP_Right_Low];
ir_node *b_h = params[BINOP_Right_High]; ir_node *b_h = params[BINOP_Right_High];
ir_mode *l_res_mode = get_type_mode(get_method_res_type(method, 0)); ir_mode *l_res_mode = get_type_mode(get_method_res_type(method, 0));
ir_mode *h_res_mode = get_type_mode(get_method_res_type(method, 1)); ir_mode *h_res_mode = get_type_mode(get_method_res_type(method, 1));
int mode_bytes = get_mode_size_bytes(ia32_reg_classes[CLASS_ia32_gp].mode); int mode_bytes = get_mode_size_bytes(ia32_reg_classes[CLASS_ia32_gp].mode);
entity *ent_a = env->irg == irg ? env->ll_div_op1 : NULL; ir_entity *ent_a = env->irg == irg ? env->ll_div_op1 : NULL;
entity *ent_b = env->irg == irg ? env->ll_div_op2 : NULL; ir_entity *ent_b = env->irg == irg ? env->ll_div_op2 : NULL;
ir_node *l_res, *h_res, *frame; ir_node *l_res, *h_res, *frame;
ir_node *store_l, *store_h; ir_node *store_l, *store_h;
ir_node *op_mem[2], *mem, *fa_mem, *fb_mem; ir_node *op_mem[2], *mem, *fa_mem, *fb_mem;
ir_node *fa, *fb, *fres; ir_node *fa, *fb, *fres;
/* allocate memory on frame to store args */ /* allocate memory on frame to store args */
...@@ -462,17 +462,17 @@ static int map_Mod(ir_node *call, void *ctx) { ...@@ -462,17 +462,17 @@ static int map_Mod(ir_node *call, void *ctx) {
*/ */
static int map_Conv(ir_node *call, void *ctx) { static int map_Conv(ir_node *call, void *ctx) {
ia32_intrinsic_env_t *env = ctx; ia32_intrinsic_env_t *env = ctx;
ir_graph *irg = current_ir_graph; ir_graph *irg = current_ir_graph;
dbg_info *dbg = get_irn_dbg_info(call); dbg_info *dbg = get_irn_dbg_info(call);
ir_node *block = get_nodes_block(call); ir_node *block = get_nodes_block(call);
ir_node **params = get_Call_param_arr(call); ir_node **params = get_Call_param_arr(call);
ir_type *method = get_Call_type(call); ir_type *method = get_Call_type(call);
int n = get_Call_n_params(call); int n = get_Call_n_params(call);
int gp_bytes = get_mode_size_bytes(ia32_reg_classes[CLASS_ia32_gp].mode); int gp_bytes = get_mode_size_bytes(ia32_reg_classes[CLASS_ia32_gp].mode);
entity *ent; ir_entity *ent;
ir_node *l_res, *h_res, *frame, *fres; ir_node *l_res, *h_res, *frame, *fres;
ir_node *store_l, *store_h; ir_node *store_l, *store_h;
ir_node *op_mem[2], *mem; ir_node *op_mem[2], *mem;
if (n == 1) { if (n == 1) {
/* We have a Conv float -> long long here */ /* We have a Conv float -> long long here */
...@@ -595,12 +595,12 @@ static int map_Conv(ir_node *call, void *ctx) { ...@@ -595,12 +595,12 @@ static int map_Conv(ir_node *call, void *ctx) {
} }
/* Ia32 implementation of intrinsic mapping. */ /* Ia32 implementation of intrinsic mapping. */
entity *ia32_create_intrinsic_fkt(ir_type *method, const ir_op *op, ir_entity *ia32_create_intrinsic_fkt(ir_type *method, const ir_op *op,
const ir_mode *imode, const ir_mode *omode, const ir_mode *imode, const ir_mode *omode,
void *context) void *context)
{ {
i_record elt; i_record elt;
entity **ent = NULL; ir_entity **ent = NULL;
i_mapper_func mapper; i_mapper_func mapper;
if (! intrinsics) if (! intrinsics)
......
...@@ -43,9 +43,9 @@ ...@@ -43,9 +43,9 @@
* @return The ident of the SymConst * @return The ident of the SymConst
*/ */
static ident *get_sc_ident(ir_node *symc) { static ident *get_sc_ident(ir_node *symc) {
entity *ent; ir_entity *ent;
ir_type *owner; ir_type *owner;
ident *id; ident *id;
switch (get_SymConst_kind(symc)) { switch (get_SymConst_kind(symc)) {
case symconst_addr_name: case symconst_addr_name:
...@@ -909,7 +909,7 @@ void set_ia32_tgt_mode(ir_node *node, ir_mode *mode) { ...@@ -909,7 +909,7 @@ void set_ia32_tgt_mode(ir_node *node, ir_mode *mode) {
/** /**
* Gets the frame entity assigned to this node. * Gets the frame entity assigned to this node.
*/ */
entity *get_ia32_frame_ent(const ir_node *node) { ir_entity *get_ia32_frame_ent(const ir_node *node) {
ia32_attr_t *attr = get_ia32_attr(node); ia32_attr_t *attr = get_ia32_attr(node);
return attr->frame_ent; return attr->frame_ent;
} }
...@@ -917,7 +917,7 @@ entity *get_ia32_frame_ent(const ir_node *node) { ...@@ -917,7 +917,7 @@ entity *get_ia32_frame_ent(const ir_node *node) {
/** /**
* Sets the frame entity for this node. * Sets the frame entity for this node.
*/ */
void set_ia32_frame_ent(ir_node *node, entity *ent) { void set_ia32_frame_ent(ir_node *node, ir_entity *ent) {
ia32_attr_t *attr = get_ia32_attr(node); ia32_attr_t *attr = get_ia32_attr(node);
attr->frame_ent = ent; attr->frame_ent = ent;
set_ia32_use_frame(node); set_ia32_use_frame(node);
......
...@@ -276,12 +276,12 @@ void set_ia32_tgt_mode(ir_node *node, ir_mode *mode); ...@@ -276,12 +276,12 @@ void set_ia32_tgt_mode(ir_node *node, ir_mode *mode);
/** /**
* Gets the frame entity assigned to this node; * Gets the frame entity assigned to this node;
*/ */
entity *get_ia32_frame_ent(const ir_node *node); ir_entity *get_ia32_frame_ent(const ir_node *node);
/** /**
* Sets the frame entity for this node; * Sets the frame entity for this node;
*/ */
void set_ia32_frame_ent(ir_node *node, entity *ent); void set_ia32_frame_ent(ir_node *node, ir_entity *ent);
/** /**
* Returns the argument register requirements of an ia32 node. * Returns the argument register requirements of an ia32 node.
......
...@@ -119,7 +119,7 @@ typedef struct _ia32_attr_t { ...@@ -119,7 +119,7 @@ typedef struct _ia32_attr_t {
ir_mode *src_mode; /**< source mode for conversion */ ir_mode *src_mode; /**< source mode for conversion */
ir_mode *tgt_mode; /**< target mode for conversion */ ir_mode *tgt_mode; /**< target mode for conversion */
entity *frame_ent; /**< the frame entity attached to this node */ ir_entity *frame_ent; /**< the frame entity attached to this node */
long pn_code; /**< projnum "types" (e.g. indicate compare operators and argument numbers) */ long pn_code; /**< projnum "types" (e.g. indicate compare operators and argument numbers) */
......
...@@ -139,11 +139,11 @@ static ir_type *get_prim_type(pmap *types, ir_mode *mode) ...@@ -139,11 +139,11 @@ static ir_type *get_prim_type(pmap *types, ir_mode *mode)
/** /**
* Get an entity that is initialized with a tarval * Get an entity that is initialized with a tarval
*/ */
static entity *get_entity_for_tv(ia32_code_gen_t *cg, ir_node *cnst) static ir_entity *get_entity_for_tv(ia32_code_gen_t *cg, ir_node *cnst)
{ {
tarval *tv = get_Const_tarval(cnst); tarval *tv = get_Const_tarval(cnst);
pmap_entry *e = pmap_find(cg->isa->tv_ent, tv); pmap_entry *e = pmap_find(cg->isa->tv_ent, tv);
entity *res; ir_entity *res;
ir_graph *rem; ir_graph *rem;
if (! e) { if (! e) {
...@@ -896,13 +896,13 @@ static ia32_am_cand_t is_am_candidate(ia32_code_gen_t *cg, heights_t *h, const i ...@@ -896,13 +896,13 @@ static ia32_am_cand_t is_am_candidate(ia32_code_gen_t *cg, heights_t *h, const i
static int load_store_addr_is_equal(const ir_node *load, const ir_node *store, static int load_store_addr_is_equal(const ir_node *load, const ir_node *store,
const ir_node *addr_b, const ir_node *addr_i) const ir_node *addr_b, const ir_node *addr_i)
{ {
int is_equal = (addr_b == get_irn_n(load, 0)) && (addr_i == get_irn_n(load, 1)); int is_equal = (addr_b == get_irn_n(load, 0)) && (addr_i == get_irn_n(load, 1));
entity *lent = get_ia32_frame_ent(load); ir_entity *lent = get_ia32_frame_ent(load);
entity *sent = get_ia32_frame_ent(store); ir_entity *sent = get_ia32_frame_ent(store);
ident *lid = get_ia32_am_sc(load); ident *lid = get_ia32_am_sc(load);
ident *sid = get_ia32_am_sc(store); ident *sid = get_ia32_am_sc(store);
char *loffs = get_ia32_am_offs(load); char *loffs = get_ia32_am_offs(load);
char *soffs = get_ia32_am_offs(store); char *soffs = get_ia32_am_offs(store);
/* are both entities set and equal? */ /* are both entities set and equal? */
if (is_equal && (lent || sent)) if (is_equal && (lent || sent))
...@@ -938,11 +938,11 @@ typedef enum _ia32_take_lea_attr { ...@@ -938,11 +938,11 @@ typedef enum _ia32_take_lea_attr {
static int do_new_lea(ir_node *irn, ir_node *base, ir_node *index, ir_node *lea, static int do_new_lea(ir_node *irn, ir_node *base, ir_node *index, ir_node *lea,
int have_am_sc, ia32_code_gen_t *cg) int have_am_sc, ia32_code_gen_t *cg)
{ {
entity *irn_ent = get_ia32_frame_ent(irn); ir_entity *irn_ent = get_ia32_frame_ent(irn);
entity *lea_ent = get_ia32_frame_ent(lea); ir_entity *lea_ent = get_ia32_frame_ent(lea);
int ret_val = 0; int ret_val = 0;
int is_noreg_base = be_is_NoReg(cg, base); int is_noreg_base = be_is_NoReg(cg, base);
int is_noreg_index = be_is_NoReg(cg, index); int is_noreg_index = be_is_NoReg(cg, index);
ia32_am_flavour_t am_flav = get_ia32_am_flavour(lea); ia32_am_flavour_t am_flav = get_ia32_am_flavour(lea);
/* If the Add and the LEA both have a different frame entity set: keep */ /* If the Add and the LEA both have a different frame entity set: keep */
...@@ -1085,7 +1085,7 @@ static ir_node *fold_addr(ia32_code_gen_t *cg, ir_node *irn, ir_node *noreg) { ...@@ -1085,7 +1085,7 @@ static ir_node *fold_addr(ia32_code_gen_t *cg, ir_node *irn, ir_node *noreg) {
int have_am_sc = 0; int have_am_sc = 0;
int am_sc_sign = 0; int am_sc_sign = 0;
ident *am_sc = NULL; ident *am_sc = NULL;
entity *lea_ent = NULL; ir_entity *lea_ent = NULL;
ir_node *left, *right, *temp; ir_node *left, *right, *temp;
ir_node *base, *index; ir_node *base, *index;
int consumed_left_shift; int consumed_left_shift;
...@@ -1388,8 +1388,8 @@ static ir_node *fold_addr(ia32_code_gen_t *cg, ir_node *irn, ir_node *noreg) { ...@@ -1388,8 +1388,8 @@ static ir_node *fold_addr(ia32_code_gen_t *cg, ir_node *irn, ir_node *noreg) {
* @param lea The LEA * @param lea The LEA
*/ */
static void merge_loadstore_lea(ir_node *irn, ir_node *lea) { static void merge_loadstore_lea(ir_node *irn, ir_node *lea) {
entity *irn_ent = get_ia32_frame_ent(irn); ir_entity *irn_ent = get_ia32_frame_ent(irn);
entity *lea_ent = get_ia32_frame_ent(lea); ir_entity *lea_ent = get_ia32_frame_ent(lea);
/* If the irn and the LEA both have a different frame entity set: do not merge */ /* If the irn and the LEA both have a different frame entity set: do not merge */
if (irn_ent && lea_ent && (irn_ent != lea_ent)) if (irn_ent && lea_ent && (irn_ent != lea_ent))
......
...@@ -208,13 +208,13 @@ static ident *gen_fp_known_const(ia32_known_const_t kct) { ...@@ -208,13 +208,13 @@ static ident *gen_fp_known_const(ia32_known_const_t kct) {
{ TP_SFP_ABS, ENT_SFP_ABS, SFP_ABS }, /* ia32_SABS */ { TP_SFP_ABS, ENT_SFP_ABS, SFP_ABS }, /* ia32_SABS */
{ TP_DFP_ABS, ENT_DFP_ABS, DFP_ABS } /* ia32_DABS */ { TP_DFP_ABS, ENT_DFP_ABS,