On Thu, 18 Oct 2012, Peter Maydell wrote:

[..snip..]

>  
> -/* FIXME:  Implement this natively.  */
> -#define tcg_gen_abs_i32(t0, t1) gen_helper_abs(t0, t1)
> +static void tcg_gen_abs_i32(TCGv dest, TCGv src)
> +{
> +    TCGv c0 = tcg_const_i32(0);
> +    printf("tcg_gen_abs_i32\n");

       ^^^^^^  doubt it was intentional

> +    tcg_gen_neg_i32(dest, src);
> +    tcg_gen_movcond_i32(TCG_COND_GT, dest, src, c0, src, dest);
> +    tcg_temp_free_i32(c0);
> +}
>  
>  static void shifter_out_im(TCGv var, int shift)
>  {
> 

-- 
mailto:av1...@comtv.ru

Reply via email to