X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fbe%2Fbessaconstr.h;h=f65cdfc7c915c1166a20f954b4a5ff7ff1535ea4;hb=78bac126e7f9ca55761ab892ebfa9c19a4a65fcf;hp=c8d77f3179f1a8d42552beff42dccd6767d642dd;hpb=d1de7107f847963fbce099597e6c42c2371b053c;p=libfirm diff --git a/ir/be/bessaconstr.h b/ir/be/bessaconstr.h index c8d77f317..f65cdfc7c 100644 --- a/ir/be/bessaconstr.h +++ b/ir/be/bessaconstr.h @@ -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. * @@ -29,11 +29,11 @@ * to their closest copy while introducing phis as necessary. * * Algorithm: Mark all blocks in the iterated dominance frontiers of the value - * and it's copies. Link the copies ordered by dominance to the blocks. The - * we search for each use all all definitions in the current block, if none is + * and its copies. Link the copies ordered by dominance to the blocks. Then + * we search for each use all definitions in the current block, if none is * found, then we search one in the immediate dominator. If we are in a block - * of the dominance frontier, create a phi and search do the same search for - * the phi arguments. + * of the dominance frontier, create a phi and do the same search for all + * phi arguments. * * A copy in this context means, that you want to introduce several new * abstract values (in Firm: nodes) for which you know, that they @@ -53,23 +53,30 @@ #include "bedomfront.h" #include "irnodeset.h" #include "belive.h" +#include "bitset.h" #include "beirg.h" #include "pdeq.h" +#include "irphase.h" typedef struct be_ssa_construction_env_t { - ir_graph *irg; - const be_dom_front_info_t *domfronts; - ir_mode *mode; - waitq *worklist; - const ir_nodeset_t *ignore_uses; - ir_node **new_phis; - int iterated_domfront_calculated; + ir_graph *irg; + const be_dom_front_info_t *domfronts; + ir_mode *mode; + const arch_register_class_t *phi_cls; + waitq *worklist; + const ir_nodeset_t *ignore_uses; + ir_node **new_phis; + int iterated_domfront_calculated; + ir_phase *phase; } be_ssa_construction_env_t; /** - * Initializes an ssa construction environment. + * Initializes an SSA construction environment. + * + * @param env an empty SSA construction environment + * @param irg the graph */ -void be_ssa_construction_init(be_ssa_construction_env_t *env, be_irg_t *birg); +void be_ssa_construction_init(be_ssa_construction_env_t *env, ir_graph *irg); void be_ssa_construction_add_copy(be_ssa_construction_env_t *env, ir_node *value); @@ -81,7 +88,7 @@ void be_ssa_construction_set_ignore_uses(be_ssa_construction_env_t *env, const ir_nodeset_t *ignore_uses); /** - * Reconstructs the ssa form for all users of node @p node + * Reconstructs the SSA form for all users of node @p node */ void be_ssa_construction_fix_users(be_ssa_construction_env_t *env, ir_node *node); @@ -99,7 +106,7 @@ void be_ssa_construction_update_liveness_phis(be_ssa_construction_env_t *env, ir_node **be_ssa_construction_get_new_phis(be_ssa_construction_env_t *env); /** - * Destroys an ssa construction environment. + * Destroys an SSA construction environment. */ void be_ssa_construction_destroy(be_ssa_construction_env_t *env);