X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fbe%2Fbespillremat.c;h=2d418f6374c3c7478fec1b7d9f2b95c430bf0787;hb=5cb14f12bacb0c7d1c646112b4660d57e14236a2;hp=b0e1e3696c1e86950635d79ca1c3de5be82569b2;hpb=b519dd6a1e6d85e843eff533be787d1f138a07ff;p=libfirm diff --git a/ir/be/bespillremat.c b/ir/be/bespillremat.c index b0e1e3696..2d418f637 100644 --- a/ir/be/bespillremat.c +++ b/ir/be/bespillremat.c @@ -1,5 +1,5 @@ /* - * Copyright (C) 1995-2007 University of Karlsruhe. All right reserved. + * Copyright (C) 1995-2008 University of Karlsruhe. All right reserved. * * This file is part of libFirm. * @@ -51,6 +51,7 @@ #include "execfreq.h" #include "irvrfy.h" #include "irbackedge_t.h" +#include "irprofile.h" #include #include @@ -70,13 +71,12 @@ #include "bespillremat.h" #include "bespill.h" #include "bepressurestat.h" -#include "beprofile.h" #include "bespilloptions.h" #include "bechordal_t.h" #include "bemodule.h" -#include -#include +#include "lc_opts.h" +#include "lc_opts_enum.h" #define DUMP_PROBLEM 1 #define DUMP_MPS 2 @@ -440,11 +440,11 @@ static double execution_frequency(const spill_ilp_t *si, const ir_node * irn) { #define FUDGE 0.001 - if(be_profile_has_data()) - return ((double)be_profile_get_block_execcount(get_block(irn))) + FUDGE; + if(ir_profile_has_data()) + return ((double)ir_profile_get_block_execcount(get_block_const(irn))) + FUDGE; #ifndef EXECFREQ_LOOPDEPH - return get_block_execfreq(si->birg->exec_freq, get_block(irn)) + FUDGE; + return get_block_execfreq(si->birg->exec_freq, get_block_const(irn)) + FUDGE; #else if(is_Block(irn)) return exp(get_loop_depth(get_irn_loop(irn)) * log(10)) + FUDGE; @@ -3247,6 +3247,9 @@ is_zero(double x) return fabs(x) < 0.00001; } +/** + * node attribute hook for changing colors + */ static int mark_remat_nodes_hook(FILE *F, ir_node *n, ir_node *l) { spill_ilp_t *si = get_irg_link(current_ir_graph); @@ -3466,7 +3469,6 @@ delete_remat(spill_ilp_t * si, ir_node * remat) { } } -/* FIXME: is this still correct:? Proj's are neither scheduled anymore nor they have a block ... */ static void clean_remat_info(spill_ilp_t * si) { @@ -3602,7 +3604,7 @@ new_r_PhiM_nokeep(ir_graph * irg, ir_node *block, int arity, ir_node **in) assert( get_irn_arity(block) == arity ); res = new_ir_node(NULL, irg, block, op_Phi, mode_M, arity, in); - res->attr.phi_backedge = new_backedge_arr(irg->obst, arity); + res->attr.phi.u.backedge = new_backedge_arr(irg->obst, arity); return res; } @@ -4618,8 +4620,8 @@ BE_REGISTER_MODULE_CONSTRUCTOR(be_init_spillremat); #else /* WITH_ILP */ -static void INLINE -only_that_you_can_compile_without_WITH_ILP_defined(void) +static __attribute__((unused)) +void only_that_you_can_compile_without_WITH_ILP_defined(void) { }