This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

overflow check in extract_range_from_binary_1 useless?


Howdy.

Am I missing something or are these two sets identical?

	  /* Get the lower and upper bounds of the type.  */
	  if (TYPE_OVERFLOW_WRAPS (expr_type))
	    {
	      type_min = wi::min_value (prec, sgn);
	      type_max = wi::max_value (prec, sgn);
	    }
	  else
	    {
	      type_min = wi::to_wide (vrp_val_min (expr_type));
	      type_max = wi::to_wide (vrp_val_max (expr_type));
	    }

Isn't wi::to_wide(TYPE_MIN/MAX_VALUE) the same as wi::min/max_value, or is there some weird language (*cough ada*) subtlety I'm missing?

Confused.
Aldy


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]