This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH]: add missing FIX_ROUND_EXPR case
- From: "Kaveh R. Ghazi" <ghazi at caip dot rutgers dot edu>
- To: gcc-patches at gcc dot gnu dot org
- Date: Wed, 9 Mar 2005 08:19:00 -0500 (EST)
- Subject: [PATCH]: add missing FIX_ROUND_EXPR case
I noticed this when looking at something else, downstream in
fold_convert_const_int_from_real() we handle FIX_ROUND_EXPR, so we
should pass it along upstream in fold_unary_to_constant().
Bootstrapped on x86_64-unknown-linux-gnu, no regressions.
Ok for mainline?
Thanks,
--Kaveh
2005-03-09 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* fold-const.c (fold_unary_to_constant): Add FIX_ROUND_EXPR case.
diff -rcp orig/egcc-CVS20050308/gcc/fold-const.c egcc-CVS20050308/gcc/fold-const.c
*** orig/egcc-CVS20050308/gcc/fold-const.c Tue Mar 8 21:24:38 2005
--- egcc-CVS20050308/gcc/fold-const.c Tue Mar 8 21:37:30 2005
*************** fold_unary_to_constant (enum tree_code c
*** 11126,11131 ****
--- 11126,11132 ----
case FIX_TRUNC_EXPR:
case FIX_FLOOR_EXPR:
case FIX_CEIL_EXPR:
+ case FIX_ROUND_EXPR:
return fold_convert_const (code, type, op0);
case NEGATE_EXPR: