This is the mail archive of the java@gcc.gnu.org mailing list for the Java 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]

Re: real_zerop thinks -0 == 0


>>>>> "Mark" == Mark Wielaard <mark@klomp.org> writes:

Mark> -	if (real_zerop (exp))
Mark> -	  OP1 (prec == 1 ? OPCODE_fconst_0 : OPCODE_dconst_0);
Mark> -	else if (real_onep (exp))
Mark> +	if (real_onep (exp))

Mark> This isn't a real solution, but I don't know how to correctly
Mark> test for positive zero and I really must get some sleep
Mark> now. Maybe someone more familiar with this code can suggest the
Mark> proper solution.

I don't know if it is the proper solution but in gcc/real.h I see
REAL_VALUE_MINUS_ZERO.  Would it be appropriate to use this?

Tom


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