v->unrolled = 0; v->shared = 0;
record_giv (v, insn, src_reg, dest_reg, mult_val, add_val, benefit,	    type, not_every_iteration, location, loop_start, loop_end)     struct induction *v;     rtx insn;     rtx src_reg;     rtx dest_reg;     rtx mult_val, add_val;     int benefit;     enum g_types type;     int not_every_iteration;     rtx *location;     rtx loop_start, loop_end;{  struct induction *b;  struct iv_class *bl;  rtx set = single_set (insn);  rtx p;  v->insn = insn;  v->src_reg = src_reg;  v->giv_type = type;  v->dest_reg = dest_reg;  v->mult_val = mult_val;  v->add_val = add_val;  v->benefit = benefit;  v->location = location;  v->cant_derive = 0;  v->combined_with = 0;  v->maybe_multiple = 0;  v->maybe_dead = 0;  v->derive_adjustment = 0;  v->same = 0;  v->ignore = 0;  v->new_reg = 0;  v->final_value = 0;  v->same_insn = 0;  /* The v->always_computable field is used in update_giv_derive, to     determine whether a giv can be used to derive another giv.  For a     DEST_REG giv, INSN computes a new value for the giv, so its value     isn't computable if INSN insn't executed every iteration.     However, for a DEST_ADDR giv, INSN merely uses the value of the giv;     it does not compute a new value.  Hence the value is always computable     regardless of whether INSN is executed each iteration.  */  if (type == DEST_ADDR)    v->always_computable = 1;  else    v->always_computable = ! not_every_iteration;  if (type == DEST_ADDR)    {      v->mode = GET_MODE (*location);      v->lifetime = 1;      v->times_used = 1;    }  else /* type == DEST_REG */    {      v->mode = GET_MODE (SET_DEST (set));      v->lifetime = (uid_luid[regno_last_uid[REGNO (dest_reg)]]		     - uid_luid[regno_first_uid[REGNO (dest_reg)]]);      v->times_used = n_times_used[REGNO (dest_reg)];      /* If the lifetime is zero, it means that this register is	 really a dead store.  So mark this as a giv that can be	 ignored.  This will not prevent the biv from being eliminated. */      if (v->lifetime == 0)	v->ignore = 1;      reg_iv_type[REGNO (dest_reg)] = GENERAL_INDUCT;      reg_iv_info[REGNO (dest_reg)] = v;    }  /* Add the giv to the class of givs computed from one biv.  */  bl = reg_biv_class[REGNO (src_reg)];  if (bl)    {      v->next_iv = bl->giv;      bl->giv = v;      /* Don't count DEST_ADDR.  This is supposed to count the number of	 insns that calculate givs.  */      if (type == DEST_REG)	bl->giv_count++;      bl->total_benefit += benefit;    }  else    /* Fatal error, biv missing for this giv?  */    abort ();  if (type == DEST_ADDR)    v->replaceable = 1;  else    {      /* The giv can be replaced outright by the reduced register only if all	 of the following conditions are true: 	 - the insn that sets the giv is always executed on any iteration	   on which the giv is used at all	   (there are two ways to deduce this:	    either the insn is executed on every iteration,	    or all uses follow that insn in the same basic block), 	 - the giv is not used outside the loop	 - no assignments to the biv occur during the giv's lifetime.  */      if (regno_first_uid[REGNO (dest_reg)] == INSN_UID (insn)	  /* Previous line always fails if INSN was moved by loop opt.  */	  && uid_luid[regno_last_uid[REGNO (dest_reg)]] < INSN_LUID (loop_end)	  && (! not_every_iteration	      || last_use_this_basic_block (dest_reg, insn))) 	{	  /* Now check that there are no assignments to the biv within the	     giv's lifetime.  This requires two separate checks.  */	  /* Check each biv update, and fail if any are between the first	     and last use of the giv.	     	     If this loop contains an inner loop that was unrolled, then	     the insn modifying the biv may have been emitted by the loop	     unrolling code, and hence does not have a valid luid.  Just	     mark the biv as not replaceable in this case.  It is not very	     useful as a biv, because it is used in two different loops.	     It is very unlikely that we would be able to optimize the giv	     using this biv anyways.  */	  v->replaceable = 1;	  for (b = bl->biv; b; b = b->next_iv)	    {	      if (INSN_UID (b->insn) >= max_uid_for_loop		  || ((uid_luid[INSN_UID (b->insn)]		       >= uid_luid[regno_first_uid[REGNO (dest_reg)]])		      && (uid_luid[INSN_UID (b->insn)]			  <= uid_luid[regno_last_uid[REGNO (dest_reg)]])))		{		  v->replaceable = 0;		  v->not_replaceable = 1;		  break; 		}	    }	  /* If there are any backwards branches that go from after the	     biv update to before it, then this giv is not replaceable.  */	  if (v->replaceable)	    for (b = bl->biv; b; b = b->next_iv)	      if (back_branch_in_range_p (b->insn, loop_start, loop_end))		{		  v->replaceable = 0;		  v->not_replaceable = 1;		  break;		}	}      else	{	  /* May still be replaceable, we don't have enough info here to	     decide.  */	  v->replaceable = 0;	  v->not_replaceable = 0;	}    }  if (loop_dump_stream)    {      if (type == DEST_REG) 	fprintf (loop_dump_stream, "Insn %d: giv reg %d",		 INSN_UID (insn), REGNO (dest_reg));      else 	fprintf (loop_dump_stream, "Insn %d: dest address", 		 INSN_UID (insn));      fprintf (loop_dump_stream, " src reg %d benefit %d",	       REGNO (src_reg), v->benefit);      fprintf (loop_dump_stream, " used %d lifetime %d",	       v->times_used, v->lifetime);      if (v->replaceable) 	fprintf (loop_dump_stream, " replaceable");      if (GET_CODE (mult_val) == CONST_INT)	fprintf (loop_dump_stream, " mult %d", 		 INTVAL (mult_val));      else	{	  fprintf (loop_dump_stream, " mult ");	  print_rtl (loop_dump_stream, mult_val);	}      if (GET_CODE (add_val) == CONST_INT)	fprintf (loop_dump_stream, " add %d",		 INTVAL (add_val));      else	{	  fprintf (loop_dump_stream, " add ");	  print_rtl (loop_dump_stream, add_val);	}    }  if (loop_dump_stream)    fprintf (loop_dump_stream, "\n");}