On 4/26/23 15:45, Michael Collison wrote:
2023-04-24  Michael Collison  <colli...@rivosinc.com>
            Juzhe Zhong  <juzhe.zh...@rivai.ai>

        * config/riscv/riscv-v.cc
        (riscv_vector_preferred_simd_mode): New function.
        (get_mask_policy_no_pred): Ditto.
        (get_tail_policy_no_pred): Ditto.
        (riscv_vector_mask_mode_p): Ditto.
        (riscv_vector_get_mask_mode): Ditto.
---

@@ -176,6 +178,46 @@ calculate_ratio (unsigned int sew, enum vlmul_type vlmul)
    return ratio;
  }
+/* Implement TARGET_VECTORIZE_PREFERRED_SIMD_MODE for RVV. */
Doesn't really tell me much.

/* Return the preferred SIMD mode for MODE.  */


@@ -421,6 +463,43 @@ get_avl_type_rtx (enum avl_type type)
    return gen_int_mode (type, Pmode);
  }
+rtx
+get_mask_policy_no_pred ()
+{
+  return get_mask_policy_for_pred (PRED_TYPE_none);
+}
+
+rtx
+get_tail_policy_no_pred ()
+{
+  return get_mask_policy_for_pred (PRED_TYPE_none);
+}
I'm guessing the call in get_tail_policy_no_pred should have been to get_tail_policy_for_pred rather than get_mask_policy_for_pred.
    ^^^^                                 ^^^^


A short function comment for the two functions seems appropriate.



+
+/* Implement TARGET_VECTORIZE_GET_MASK_MODE for RVV.  */
How about
/* Return the appropriate mask mode for MODE.  */


OK with the trivial fixes noted above.

Jeff

Reply via email to