This is the mail archive of the gcc-patches@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]

Re: [patch] Fixed-point patch 8/10


Fu, Chao-Ying wrote:

>   The unreviewd patches are 7, 9 and 10.

[I've added gcc-patches to the CC list.]

> http://gcc.gnu.org/ml/gcc-patches/2007-08/msg00096.html

I have a few questions about this patch.

Why does stdfix.h #undef things before defining them?  Does the draft
standard say it should do that?

Why does convert_to_fixed special case integer_zero_node and
integer_one_node?  Why not check integer_zerop, for example?  And, do we
want fold to use FCONST[01] if it reduces something to zero too?

+      /* Check if it is a fixed-point mode to do an ordinary binary
operator. */
+      if (ALL_FIXED_POINT_MODE_P (mode))
+	goto binop;

Would you please expand on this comment?  The comment says what the code
does, but why?  I think you want something like:

  /* If this is a fixed-point operation, then we cannot use the code
below because ...  */

Thanks,

-- 
Mark Mitchell
CodeSourcery
mark@codesourcery.com
(650) 331-3385 x713


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