On Wed, Jul 20, 2016 at 06:00:53PM +0100, Jiong Wang wrote:
> On 07/07/16 17:17, Jiong Wang wrote:
> >This patch add ARMv8.2-A FP16 one operand scalar intrinsics
> >
> >Scalar intrinsics are kept in arm_fp16.h instead of arm_neon.h.
> 
> The updated patch resolve the conflict with
> 
>    https://gcc.gnu.org/ml/gcc-patches/2016-06/msg00308.html
> 
> The change is to let aarch64_emit_approx_sqrt return false for HFmode.

OK, but...

> diff --git a/gcc/config/aarch64/aarch64.c b/gcc/config/aarch64/aarch64.c
> index 
> a7437c04eb936a5e3ebd0bc77eb4afd8c052df28..27866ccd605abec6ea7c9110022f329c9b172ee0
>  100644
> --- a/gcc/config/aarch64/aarch64.c
> +++ b/gcc/config/aarch64/aarch64.c
> @@ -7599,7 +7599,7 @@ aarch64_emit_approx_sqrt (rtx dst, rtx src, bool recp)
>  {
>    machine_mode mode = GET_MODE (dst);
>  
> -  if (mode == V4HFmode || mode == V8HFmode)
> +  if (mode == HFmode || mode == V4HFmode || mode == V8HFmode)
>      return false;

...if you take my advice on patch 2/14, you won't need this change.

Otherwise, OK.

Thanks,
James

> gcc/
> 2016-07-20  Jiong Wang<jiong.w...@arm.com>
> 
>         * config.gcc (aarch64*-*-*): Install arm_fp16.h.
>         * config/aarch64/aarch64-builtins.c (hi_UP): New.
>         * config/aarch64/aarch64-simd-builtins.def: Register new builtins.
>         * config/aarch64/aarch64-simd.md (aarch64_frsqrte<mode>): Extend to 
> HF mode.
>         (aarch64_frecp<FRECP:frecp_suffix><mode>): Likewise.
>         (aarch64_cm<optab><mode>): Likewise.
>         * config/aarch64/aarch64.md (<frint_pattern><mode>2): Likewise.
>         (l<fcvt_pattern><su_optab><GPF:mode><GPI:mode>2): Likewise.
>         (fix_trunc<GPF:mode><GPI:mode>2): Likewise.
>         (sqrt<mode>2): Likewise.
>         (*sqrt<mode>2): Likewise.
>         (abs<mode>2): Likewise.
>         (<optab><mode>hf2): New pattern for HF mode.
>         (<optab>hihf2): Likewise.
>         * config/aarch64/aarch64.c (aarch64_emit_approx_sqrt): Return
>         for HF mode.
>         * config/aarch64/arm_neon.h: Include arm_fp16.h.
>         * config/aarch64/iterators.md (GPF_F16): New.
>         (GPI_F16): Likewise.
>         (VHSDF_HSDF): Likewise.
>         (w1): Support HF mode.
>         (w2): Likewise.
>         (v): Likewise.
>         (s): Likewise.
>         (q): Likewise.
>         (Vmtype): Likewise.
>         (V_cmp_result): Likewise.
>         (fcvt_iesize): Likewise.
>         (FCVT_IESIZE): Likewise.
>         * config/aarch64/arm_fp16.h: New file.
>         (vabsh_f16): New.
>         (vceqzh_f16): Likewise.
>         (vcgezh_f16): Likewise.
>         (vcgtzh_f16): Likewise.
>         (vclezh_f16): Likewise.
>         (vcltzh_f16): Likewise.
>         (vcvth_f16_s16): Likewise.
>         (vcvth_f16_s32): Likewise.
>         (vcvth_f16_s64): Likewise.
>         (vcvth_f16_u16): Likewise.
>         (vcvth_f16_u32): Likewise.
>         (vcvth_f16_u64): Likewise.
>         (vcvth_s16_f16): Likewise.
>         (vcvth_s32_f16): Likewise.
>         (vcvth_s64_f16): Likewise.
>         (vcvth_u16_f16): Likewise.
>         (vcvth_u32_f16): Likewise.
>         (vcvth_u64_f16): Likewise.
>         (vcvtah_s16_f16): Likewise.
>         (vcvtah_s32_f16): Likewise.
>         (vcvtah_s64_f16): Likewise.
>         (vcvtah_u16_f16): Likewise.
>         (vcvtah_u32_f16): Likewise.
>         (vcvtah_u64_f16): Likewise.
>         (vcvtmh_s16_f16): Likewise.
>         (vcvtmh_s32_f16): Likewise.
>         (vcvtmh_s64_f16): Likewise.
>         (vcvtmh_u16_f16): Likewise.
>         (vcvtmh_u32_f16): Likewise.
>         (vcvtmh_u64_f16): Likewise.
>         (vcvtnh_s16_f16): Likewise.
>         (vcvtnh_s32_f16): Likewise.
>         (vcvtnh_s64_f16): Likewise.
>         (vcvtnh_u16_f16): Likewise.
>         (vcvtnh_u32_f16): Likewise.
>         (vcvtnh_u64_f16): Likewise.
>         (vcvtph_s16_f16): Likewise.
>         (vcvtph_s32_f16): Likewise.
>         (vcvtph_s64_f16): Likewise.
>         (vcvtph_u16_f16): Likewise.
>         (vcvtph_u32_f16): Likewise.
>         (vcvtph_u64_f16): Likewise.
>         (vnegh_f16): Likewise.
>         (vrecpeh_f16): Likewise.
>         (vrecpxh_f16): Likewise.
>         (vrndh_f16): Likewise.
>         (vrndah_f16): Likewise.
>         (vrndih_f16): Likewise.
>         (vrndmh_f16): Likewise.
>         (vrndnh_f16): Likewise.
>         (vrndph_f16): Likewise.
>         (vrndxh_f16): Likewise.
>         (vrsqrteh_f16): Likewise.
>         (vsqrth_f16): Likewise.

Reply via email to