- if (get_irn_link(node) == PRED_SEARCH)
- set_irn_link(node, NULL);
-}
-
-/**
- * Create a link for blocks, that have Phi, Load or Store nodes for scalar_replacement.
- *
- * @param node A Phi, Load or Store node, that block muss get a link.
- * @param env Contains information about scalars number and mode.
- * @param repairs A set, that contains all blocks, that have a link, and all Phis, that
- * have copies to repair.
- */
-static void block_link(ir_node *node, env_t *env, set *repairs)
-{
- repairs_t key, *value;
- ir_node *nods_block ;
- int i;
- nods_block = get_nodes_block(node);
- /* If the block of the node have no link. */
- if (get_irn_link(nods_block) == NULL) {
- DDMN(nods_block);
- key.irn = nods_block;
- value = set_insert(repairs, &key, sizeof(key), HASH_PTR(key.irn));
- value->link = obstack_alloc(&env->obst, sizeof(ir_node *) * env->nvals);
- /* The block of the node be inserted in the set repairs, because it have yet a link.
- The link is a array with size equal to number of scalars.*/
- for (i = 0; i < env->nvals; i++)
- /* First all links member be set to NULL. */
- value->link[i] = NULL;
- set_irn_link(nods_block, value->link);
- }
-}
-
-/**
- * Handle Phis, that get the memory edge of Loads or Stors, that were been scalar replaced or
- * will be scalar replaced.
- *
- * @param phi A Phi node, that muss have mode_M.
- * @param env Contains information about scalars number and mode.
- * @param repairs A set that contains all blocks having a link and all Phis that
- * have copies to repair.
- */
-static void phi_handling(ir_node *phi, env_t *env, set *repairs)
-{
- ir_node *phi_block, **link;
- repairs_t key, *value;
- int rem;
- int p = 0, i, phi_preds;
- ir_node **in;