Since there are a lot of similar code for other intrinsics, this patch looks
fine to me. Please check it in.

2010/9/10 Yiran Wang <yiran.w...@gmail.com>

> Hi All,
>
> Could a gatekeeper please review it?
>
> Simply, the ret_mtype should be reset automatically, if it is void. This is
> already done for a number of other intrinsics.
>
> The bug is triggered when the combination of > and ?: operator is used, as
> the result type is not set by parent of the intrinsic.
>
> Best Regards,
> yiran
>
>
> Index: wgen_expr.cxx
> ===================================================================
> --- wgen_expr.cxx       (revision 3338)
> +++ wgen_expr.cxx       (working copy)
> @@ -8153,6 +8153,7 @@
>  #ifndef TARG_MIPS  // MIPS needs quad emulation for sqrt operation
>                case GSBI_BUILT_IN_SQRTL:
>  #endif
> +               if (ret_mtype == MTYPE_V) ret_mtype = MTYPE_F8;
>                 if (! gs_flag_errno_math(program)) {
>                   arg_wn = WGEN_Expand_Expr (gs_tree_value (gs_tree_operand
> (exp, 1)));
>                   wn = WN_CreateExp1 (OPR_SQRT, ret_mtype, MTYPE_V,
> arg_wn);
>
>
>
> ------------------------------------------------------------------------------
> Start uncovering the many advantages of virtual appliances
> and start using them to simplify application deployment and
> accelerate your shift to cloud computing
> http://p.sf.net/sfu/novell-sfdev2dev
>
> _______________________________________________
> Open64-devel mailing list
> Open64-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/open64-devel
>
>


-- 
Regards,
Lai Jian-Xin
------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
Open64-devel mailing list
Open64-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/open64-devel

Reply via email to