On Wed, Jan 21, 2026 at 5:29 PM Andre Vieira
<[email protected]> wrote:
>
> Hi,
>
> This uses 'get_related_vectype_for_scalar_type' to construct a standard 
> vectype
> for any non scalar masks, which resolves the ICE caused by the sve type
> attribute in SVE types used for simdclones.
>
> Tested on aarch64-none-linux-gnu. OK for trunk?

So we're essentially re-building the simdclone masktype to avoid the ICE.  And
we want exactly the same vector type.  IMO

  masktype = build_truth_vector_type_for_mode (TYPE_VECTOR_SUBPARTS
(masktype), TYPE_MODE (masktype));

would achieve this in a more obvious way?

Thanks,
Richard.

> PR target/123016
> gcc/ChangeLog:
>
>         * tree-vect-stmts.cc (vectorizable_simd_clone_call): use
>         get_related_vectype_for_scalar_type to reconstruct standard vectype 
> for
>         non-scalar masks.
>
> gcc/testsuite/ChangeLog:
>
>          * gfortran.dg/vect/pr123016.f90: New test.
>

Reply via email to