diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vse-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vse-1.c
new file mode 100644
index 00000000000..c08e1e1265a
--- /dev/null
+++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vse-1.c
@@ -0,0 +1,345 @@
+/* { dg-do compile } */
+/* { dg-options "-march=rv32gcv -mabi=ilp32d -O3 -fno-schedule-insns -fno-schedule-insns2" } */
+
+#include "riscv_vector.h"
+
+void
+test___riscv_vse8_v_i8mf8(int8_t* base,vint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf8(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8mf4(int8_t* base,vint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf4(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8mf2(int8_t* base,vint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf2(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8m1(int8_t* base,vint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m1(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8m2(int8_t* base,vint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m2(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8m4(int8_t* base,vint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m4(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8m8(int8_t* base,vint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m8(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8mf8(uint8_t* base,vuint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf8(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8mf4(uint8_t* base,vuint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf4(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8mf2(uint8_t* base,vuint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf2(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8m1(uint8_t* base,vuint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m1(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8m2(uint8_t* base,vuint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m2(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8m4(uint8_t* base,vuint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m4(base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8m8(uint8_t* base,vuint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m8(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16mf4(int16_t* base,vint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf4(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16mf2(int16_t* base,vint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf2(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16m1(int16_t* base,vint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m1(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16m2(int16_t* base,vint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m2(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16m4(int16_t* base,vint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m4(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16m8(int16_t* base,vint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m8(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16mf4(uint16_t* base,vuint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf4(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16mf2(uint16_t* base,vuint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf2(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16m1(uint16_t* base,vuint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m1(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16m2(uint16_t* base,vuint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m2(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16m4(uint16_t* base,vuint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m4(base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16m8(uint16_t* base,vuint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m8(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_i32mf2(int32_t* base,vint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32mf2(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_i32m1(int32_t* base,vint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m1(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_i32m2(int32_t* base,vint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m2(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_i32m4(int32_t* base,vint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m4(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_i32m8(int32_t* base,vint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m8(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_u32mf2(uint32_t* base,vuint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32mf2(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_u32m1(uint32_t* base,vuint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m1(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_u32m2(uint32_t* base,vuint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m2(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_u32m4(uint32_t* base,vuint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m4(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_u32m8(uint32_t* base,vuint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m8(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_f32mf2(float* base,vfloat32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32mf2(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_f32m1(float* base,vfloat32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m1(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_f32m2(float* base,vfloat32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m2(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_f32m4(float* base,vfloat32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m4(base,value,vl);
+}
+
+void
+test___riscv_vse32_v_f32m8(float* base,vfloat32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m8(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_i64m1(int64_t* base,vint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m1(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_i64m2(int64_t* base,vint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m2(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_i64m4(int64_t* base,vint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m4(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_i64m8(int64_t* base,vint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m8(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_u64m1(uint64_t* base,vuint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m1(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_u64m2(uint64_t* base,vuint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m2(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_u64m4(uint64_t* base,vuint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m4(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_u64m8(uint64_t* base,vuint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m8(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_f64m1(double* base,vfloat64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m1(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_f64m2(double* base,vfloat64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m2(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_f64m4(double* base,vfloat64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m4(base,value,vl);
+}
+
+void
+test___riscv_vse64_v_f64m8(double* base,vfloat64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m8(base,value,vl);
+}
+
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m8,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m8,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m1,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m2,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m4,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m8,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vse-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vse-2.c
new file mode 100644
index 00000000000..62935c56df7
--- /dev/null
+++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vse-2.c
@@ -0,0 +1,345 @@
+/* { dg-do compile } */
+/* { dg-options "-march=rv32gcv -mabi=ilp32d -O3 -fno-schedule-insns -fno-schedule-insns2" } */
+
+#include "riscv_vector.h"
+
+void
+test___riscv_vse8_v_i8mf8(int8_t* base,vint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf8(base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8mf4(int8_t* base,vint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf4(base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8mf2(int8_t* base,vint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf2(base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8m1(int8_t* base,vint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m1(base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8m2(int8_t* base,vint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m2(base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8m4(int8_t* base,vint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m4(base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8m8(int8_t* base,vint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m8(base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8mf8(uint8_t* base,vuint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf8(base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8mf4(uint8_t* base,vuint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf4(base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8mf2(uint8_t* base,vuint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf2(base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8m1(uint8_t* base,vuint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m1(base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8m2(uint8_t* base,vuint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m2(base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8m4(uint8_t* base,vuint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m4(base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8m8(uint8_t* base,vuint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m8(base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16mf4(int16_t* base,vint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf4(base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16mf2(int16_t* base,vint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf2(base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16m1(int16_t* base,vint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m1(base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16m2(int16_t* base,vint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m2(base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16m4(int16_t* base,vint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m4(base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16m8(int16_t* base,vint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m8(base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16mf4(uint16_t* base,vuint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf4(base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16mf2(uint16_t* base,vuint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf2(base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16m1(uint16_t* base,vuint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m1(base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16m2(uint16_t* base,vuint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m2(base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16m4(uint16_t* base,vuint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m4(base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16m8(uint16_t* base,vuint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m8(base,value,31);
+}
+
+void
+test___riscv_vse32_v_i32mf2(int32_t* base,vint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32mf2(base,value,31);
+}
+
+void
+test___riscv_vse32_v_i32m1(int32_t* base,vint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m1(base,value,31);
+}
+
+void
+test___riscv_vse32_v_i32m2(int32_t* base,vint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m2(base,value,31);
+}
+
+void
+test___riscv_vse32_v_i32m4(int32_t* base,vint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m4(base,value,31);
+}
+
+void
+test___riscv_vse32_v_i32m8(int32_t* base,vint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m8(base,value,31);
+}
+
+void
+test___riscv_vse32_v_u32mf2(uint32_t* base,vuint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32mf2(base,value,31);
+}
+
+void
+test___riscv_vse32_v_u32m1(uint32_t* base,vuint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m1(base,value,31);
+}
+
+void
+test___riscv_vse32_v_u32m2(uint32_t* base,vuint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m2(base,value,31);
+}
+
+void
+test___riscv_vse32_v_u32m4(uint32_t* base,vuint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m4(base,value,31);
+}
+
+void
+test___riscv_vse32_v_u32m8(uint32_t* base,vuint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m8(base,value,31);
+}
+
+void
+test___riscv_vse32_v_f32mf2(float* base,vfloat32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32mf2(base,value,31);
+}
+
+void
+test___riscv_vse32_v_f32m1(float* base,vfloat32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m1(base,value,31);
+}
+
+void
+test___riscv_vse32_v_f32m2(float* base,vfloat32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m2(base,value,31);
+}
+
+void
+test___riscv_vse32_v_f32m4(float* base,vfloat32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m4(base,value,31);
+}
+
+void
+test___riscv_vse32_v_f32m8(float* base,vfloat32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m8(base,value,31);
+}
+
+void
+test___riscv_vse64_v_i64m1(int64_t* base,vint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m1(base,value,31);
+}
+
+void
+test___riscv_vse64_v_i64m2(int64_t* base,vint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m2(base,value,31);
+}
+
+void
+test___riscv_vse64_v_i64m4(int64_t* base,vint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m4(base,value,31);
+}
+
+void
+test___riscv_vse64_v_i64m8(int64_t* base,vint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m8(base,value,31);
+}
+
+void
+test___riscv_vse64_v_u64m1(uint64_t* base,vuint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m1(base,value,31);
+}
+
+void
+test___riscv_vse64_v_u64m2(uint64_t* base,vuint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m2(base,value,31);
+}
+
+void
+test___riscv_vse64_v_u64m4(uint64_t* base,vuint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m4(base,value,31);
+}
+
+void
+test___riscv_vse64_v_u64m8(uint64_t* base,vuint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m8(base,value,31);
+}
+
+void
+test___riscv_vse64_v_f64m1(double* base,vfloat64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m1(base,value,31);
+}
+
+void
+test___riscv_vse64_v_f64m2(double* base,vfloat64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m2(base,value,31);
+}
+
+void
+test___riscv_vse64_v_f64m4(double* base,vfloat64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m4(base,value,31);
+}
+
+void
+test___riscv_vse64_v_f64m8(double* base,vfloat64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m8(base,value,31);
+}
+
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m8,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m8,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e64,\s*m1,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e64,\s*m2,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e64,\s*m4,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e64,\s*m8,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vse-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vse-3.c
new file mode 100644
index 00000000000..c06931b46b4
--- /dev/null
+++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vse-3.c
@@ -0,0 +1,345 @@
+/* { dg-do compile } */
+/* { dg-options "-march=rv32gcv -mabi=ilp32d -O3 -fno-schedule-insns -fno-schedule-insns2" } */
+
+#include "riscv_vector.h"
+
+void
+test___riscv_vse8_v_i8mf8(int8_t* base,vint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf8(base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8mf4(int8_t* base,vint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf4(base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8mf2(int8_t* base,vint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf2(base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8m1(int8_t* base,vint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m1(base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8m2(int8_t* base,vint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m2(base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8m4(int8_t* base,vint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m4(base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8m8(int8_t* base,vint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m8(base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8mf8(uint8_t* base,vuint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf8(base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8mf4(uint8_t* base,vuint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf4(base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8mf2(uint8_t* base,vuint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf2(base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8m1(uint8_t* base,vuint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m1(base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8m2(uint8_t* base,vuint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m2(base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8m4(uint8_t* base,vuint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m4(base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8m8(uint8_t* base,vuint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m8(base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16mf4(int16_t* base,vint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf4(base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16mf2(int16_t* base,vint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf2(base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16m1(int16_t* base,vint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m1(base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16m2(int16_t* base,vint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m2(base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16m4(int16_t* base,vint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m4(base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16m8(int16_t* base,vint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m8(base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16mf4(uint16_t* base,vuint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf4(base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16mf2(uint16_t* base,vuint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf2(base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16m1(uint16_t* base,vuint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m1(base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16m2(uint16_t* base,vuint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m2(base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16m4(uint16_t* base,vuint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m4(base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16m8(uint16_t* base,vuint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m8(base,value,32);
+}
+
+void
+test___riscv_vse32_v_i32mf2(int32_t* base,vint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32mf2(base,value,32);
+}
+
+void
+test___riscv_vse32_v_i32m1(int32_t* base,vint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m1(base,value,32);
+}
+
+void
+test___riscv_vse32_v_i32m2(int32_t* base,vint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m2(base,value,32);
+}
+
+void
+test___riscv_vse32_v_i32m4(int32_t* base,vint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m4(base,value,32);
+}
+
+void
+test___riscv_vse32_v_i32m8(int32_t* base,vint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m8(base,value,32);
+}
+
+void
+test___riscv_vse32_v_u32mf2(uint32_t* base,vuint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32mf2(base,value,32);
+}
+
+void
+test___riscv_vse32_v_u32m1(uint32_t* base,vuint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m1(base,value,32);
+}
+
+void
+test___riscv_vse32_v_u32m2(uint32_t* base,vuint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m2(base,value,32);
+}
+
+void
+test___riscv_vse32_v_u32m4(uint32_t* base,vuint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m4(base,value,32);
+}
+
+void
+test___riscv_vse32_v_u32m8(uint32_t* base,vuint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m8(base,value,32);
+}
+
+void
+test___riscv_vse32_v_f32mf2(float* base,vfloat32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32mf2(base,value,32);
+}
+
+void
+test___riscv_vse32_v_f32m1(float* base,vfloat32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m1(base,value,32);
+}
+
+void
+test___riscv_vse32_v_f32m2(float* base,vfloat32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m2(base,value,32);
+}
+
+void
+test___riscv_vse32_v_f32m4(float* base,vfloat32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m4(base,value,32);
+}
+
+void
+test___riscv_vse32_v_f32m8(float* base,vfloat32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m8(base,value,32);
+}
+
+void
+test___riscv_vse64_v_i64m1(int64_t* base,vint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m1(base,value,32);
+}
+
+void
+test___riscv_vse64_v_i64m2(int64_t* base,vint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m2(base,value,32);
+}
+
+void
+test___riscv_vse64_v_i64m4(int64_t* base,vint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m4(base,value,32);
+}
+
+void
+test___riscv_vse64_v_i64m8(int64_t* base,vint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m8(base,value,32);
+}
+
+void
+test___riscv_vse64_v_u64m1(uint64_t* base,vuint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m1(base,value,32);
+}
+
+void
+test___riscv_vse64_v_u64m2(uint64_t* base,vuint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m2(base,value,32);
+}
+
+void
+test___riscv_vse64_v_u64m4(uint64_t* base,vuint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m4(base,value,32);
+}
+
+void
+test___riscv_vse64_v_u64m8(uint64_t* base,vuint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m8(base,value,32);
+}
+
+void
+test___riscv_vse64_v_f64m1(double* base,vfloat64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m1(base,value,32);
+}
+
+void
+test___riscv_vse64_v_f64m2(double* base,vfloat64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m2(base,value,32);
+}
+
+void
+test___riscv_vse64_v_f64m4(double* base,vfloat64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m4(base,value,32);
+}
+
+void
+test___riscv_vse64_v_f64m8(double* base,vfloat64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m8(base,value,32);
+}
+
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m8,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m8,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m1,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m2,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m4,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m8,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\)} 3 } } */
diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vse_m-1.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vse_m-1.c
new file mode 100644
index 00000000000..46a79c0c308
--- /dev/null
+++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vse_m-1.c
@@ -0,0 +1,345 @@
+/* { dg-do compile } */
+/* { dg-options "-march=rv32gcv -mabi=ilp32d -O3 -fno-schedule-insns -fno-schedule-insns2" } */
+
+#include "riscv_vector.h"
+
+void
+test___riscv_vse8_v_i8mf8_m(vbool64_t mask,int8_t* base,vint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf8_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8mf4_m(vbool32_t mask,int8_t* base,vint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8mf2_m(vbool16_t mask,int8_t* base,vint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8m1_m(vbool8_t mask,int8_t* base,vint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m1_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8m2_m(vbool4_t mask,int8_t* base,vint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8m4_m(vbool2_t mask,int8_t* base,vint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_i8m8_m(vbool1_t mask,int8_t* base,vint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m8_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8mf8_m(vbool64_t mask,uint8_t* base,vuint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf8_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8mf4_m(vbool32_t mask,uint8_t* base,vuint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8mf2_m(vbool16_t mask,uint8_t* base,vuint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8m1_m(vbool8_t mask,uint8_t* base,vuint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m1_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8m2_m(vbool4_t mask,uint8_t* base,vuint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8m4_m(vbool2_t mask,uint8_t* base,vuint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse8_v_u8m8_m(vbool1_t mask,uint8_t* base,vuint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m8_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16mf4_m(vbool64_t mask,int16_t* base,vint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16mf2_m(vbool32_t mask,int16_t* base,vint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16m1_m(vbool16_t mask,int16_t* base,vint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m1_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16m2_m(vbool8_t mask,int16_t* base,vint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16m4_m(vbool4_t mask,int16_t* base,vint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_i16m8_m(vbool2_t mask,int16_t* base,vint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m8_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16mf4_m(vbool64_t mask,uint16_t* base,vuint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16mf2_m(vbool32_t mask,uint16_t* base,vuint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16m1_m(vbool16_t mask,uint16_t* base,vuint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m1_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16m2_m(vbool8_t mask,uint16_t* base,vuint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16m4_m(vbool4_t mask,uint16_t* base,vuint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse16_v_u16m8_m(vbool2_t mask,uint16_t* base,vuint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m8_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_i32mf2_m(vbool64_t mask,int32_t* base,vint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32mf2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_i32m1_m(vbool32_t mask,int32_t* base,vint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m1_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_i32m2_m(vbool16_t mask,int32_t* base,vint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_i32m4_m(vbool8_t mask,int32_t* base,vint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_i32m8_m(vbool4_t mask,int32_t* base,vint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m8_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_u32mf2_m(vbool64_t mask,uint32_t* base,vuint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32mf2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_u32m1_m(vbool32_t mask,uint32_t* base,vuint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m1_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_u32m2_m(vbool16_t mask,uint32_t* base,vuint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_u32m4_m(vbool8_t mask,uint32_t* base,vuint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_u32m8_m(vbool4_t mask,uint32_t* base,vuint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m8_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_f32mf2_m(vbool64_t mask,float* base,vfloat32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32mf2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_f32m1_m(vbool32_t mask,float* base,vfloat32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m1_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_f32m2_m(vbool16_t mask,float* base,vfloat32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_f32m4_m(vbool8_t mask,float* base,vfloat32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse32_v_f32m8_m(vbool4_t mask,float* base,vfloat32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m8_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_i64m1_m(vbool64_t mask,int64_t* base,vint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m1_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_i64m2_m(vbool32_t mask,int64_t* base,vint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_i64m4_m(vbool16_t mask,int64_t* base,vint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_i64m8_m(vbool8_t mask,int64_t* base,vint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m8_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_u64m1_m(vbool64_t mask,uint64_t* base,vuint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m1_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_u64m2_m(vbool32_t mask,uint64_t* base,vuint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_u64m4_m(vbool16_t mask,uint64_t* base,vuint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_u64m8_m(vbool8_t mask,uint64_t* base,vuint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m8_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_f64m1_m(vbool64_t mask,double* base,vfloat64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m1_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_f64m2_m(vbool32_t mask,double* base,vfloat64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m2_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_f64m4_m(vbool16_t mask,double* base,vfloat64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m4_m(mask,base,value,vl);
+}
+
+void
+test___riscv_vse64_v_f64m8_m(vbool8_t mask,double* base,vfloat64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m8_m(mask,base,value,vl);
+}
+
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m8,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m8,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m1,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m2,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m4,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m8,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vse_m-2.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vse_m-2.c
new file mode 100644
index 00000000000..c1fa00e6dd6
--- /dev/null
+++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vse_m-2.c
@@ -0,0 +1,345 @@
+/* { dg-do compile } */
+/* { dg-options "-march=rv32gcv -mabi=ilp32d -O3 -fno-schedule-insns -fno-schedule-insns2" } */
+
+#include "riscv_vector.h"
+
+void
+test___riscv_vse8_v_i8mf8_m(vbool64_t mask,int8_t* base,vint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf8_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8mf4_m(vbool32_t mask,int8_t* base,vint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8mf2_m(vbool16_t mask,int8_t* base,vint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8m1_m(vbool8_t mask,int8_t* base,vint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m1_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8m2_m(vbool4_t mask,int8_t* base,vint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8m4_m(vbool2_t mask,int8_t* base,vint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_i8m8_m(vbool1_t mask,int8_t* base,vint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m8_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8mf8_m(vbool64_t mask,uint8_t* base,vuint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf8_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8mf4_m(vbool32_t mask,uint8_t* base,vuint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8mf2_m(vbool16_t mask,uint8_t* base,vuint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8m1_m(vbool8_t mask,uint8_t* base,vuint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m1_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8m2_m(vbool4_t mask,uint8_t* base,vuint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8m4_m(vbool2_t mask,uint8_t* base,vuint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse8_v_u8m8_m(vbool1_t mask,uint8_t* base,vuint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m8_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16mf4_m(vbool64_t mask,int16_t* base,vint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16mf2_m(vbool32_t mask,int16_t* base,vint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16m1_m(vbool16_t mask,int16_t* base,vint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m1_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16m2_m(vbool8_t mask,int16_t* base,vint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16m4_m(vbool4_t mask,int16_t* base,vint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_i16m8_m(vbool2_t mask,int16_t* base,vint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m8_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16mf4_m(vbool64_t mask,uint16_t* base,vuint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16mf2_m(vbool32_t mask,uint16_t* base,vuint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16m1_m(vbool16_t mask,uint16_t* base,vuint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m1_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16m2_m(vbool8_t mask,uint16_t* base,vuint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16m4_m(vbool4_t mask,uint16_t* base,vuint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse16_v_u16m8_m(vbool2_t mask,uint16_t* base,vuint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m8_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_i32mf2_m(vbool64_t mask,int32_t* base,vint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32mf2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_i32m1_m(vbool32_t mask,int32_t* base,vint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m1_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_i32m2_m(vbool16_t mask,int32_t* base,vint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_i32m4_m(vbool8_t mask,int32_t* base,vint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_i32m8_m(vbool4_t mask,int32_t* base,vint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m8_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_u32mf2_m(vbool64_t mask,uint32_t* base,vuint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32mf2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_u32m1_m(vbool32_t mask,uint32_t* base,vuint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m1_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_u32m2_m(vbool16_t mask,uint32_t* base,vuint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_u32m4_m(vbool8_t mask,uint32_t* base,vuint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_u32m8_m(vbool4_t mask,uint32_t* base,vuint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m8_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_f32mf2_m(vbool64_t mask,float* base,vfloat32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32mf2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_f32m1_m(vbool32_t mask,float* base,vfloat32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m1_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_f32m2_m(vbool16_t mask,float* base,vfloat32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_f32m4_m(vbool8_t mask,float* base,vfloat32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse32_v_f32m8_m(vbool4_t mask,float* base,vfloat32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m8_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_i64m1_m(vbool64_t mask,int64_t* base,vint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m1_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_i64m2_m(vbool32_t mask,int64_t* base,vint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_i64m4_m(vbool16_t mask,int64_t* base,vint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_i64m8_m(vbool8_t mask,int64_t* base,vint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m8_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_u64m1_m(vbool64_t mask,uint64_t* base,vuint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m1_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_u64m2_m(vbool32_t mask,uint64_t* base,vuint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_u64m4_m(vbool16_t mask,uint64_t* base,vuint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_u64m8_m(vbool8_t mask,uint64_t* base,vuint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m8_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_f64m1_m(vbool64_t mask,double* base,vfloat64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m1_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_f64m2_m(vbool32_t mask,double* base,vfloat64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m2_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_f64m4_m(vbool16_t mask,double* base,vfloat64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m4_m(mask,base,value,31);
+}
+
+void
+test___riscv_vse64_v_f64m8_m(vbool8_t mask,double* base,vfloat64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m8_m(mask,base,value,31);
+}
+
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e8,\s*m8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e16,\s*m8,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e32,\s*m8,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e64,\s*m1,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e64,\s*m2,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e64,\s*m4,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetivli\s+zero,\s*31,\s*e64,\s*m8,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
diff --git a/gcc/testsuite/gcc.target/riscv/rvv/base/vse_m-3.c b/gcc/testsuite/gcc.target/riscv/rvv/base/vse_m-3.c
new file mode 100644
index 00000000000..82a3da759b5
--- /dev/null
+++ b/gcc/testsuite/gcc.target/riscv/rvv/base/vse_m-3.c
@@ -0,0 +1,345 @@
+/* { dg-do compile } */
+/* { dg-options "-march=rv32gcv -mabi=ilp32d -O3 -fno-schedule-insns -fno-schedule-insns2" } */
+
+#include "riscv_vector.h"
+
+void
+test___riscv_vse8_v_i8mf8_m(vbool64_t mask,int8_t* base,vint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf8_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8mf4_m(vbool32_t mask,int8_t* base,vint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8mf2_m(vbool16_t mask,int8_t* base,vint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8mf2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8m1_m(vbool8_t mask,int8_t* base,vint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m1_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8m2_m(vbool4_t mask,int8_t* base,vint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8m4_m(vbool2_t mask,int8_t* base,vint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_i8m8_m(vbool1_t mask,int8_t* base,vint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_i8m8_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8mf8_m(vbool64_t mask,uint8_t* base,vuint8mf8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf8_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8mf4_m(vbool32_t mask,uint8_t* base,vuint8mf4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8mf2_m(vbool16_t mask,uint8_t* base,vuint8mf2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8mf2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8m1_m(vbool8_t mask,uint8_t* base,vuint8m1_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m1_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8m2_m(vbool4_t mask,uint8_t* base,vuint8m2_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8m4_m(vbool2_t mask,uint8_t* base,vuint8m4_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse8_v_u8m8_m(vbool1_t mask,uint8_t* base,vuint8m8_t value,size_t vl)
+{
+  __riscv_vse8_v_u8m8_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16mf4_m(vbool64_t mask,int16_t* base,vint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16mf2_m(vbool32_t mask,int16_t* base,vint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16mf2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16m1_m(vbool16_t mask,int16_t* base,vint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m1_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16m2_m(vbool8_t mask,int16_t* base,vint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16m4_m(vbool4_t mask,int16_t* base,vint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_i16m8_m(vbool2_t mask,int16_t* base,vint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_i16m8_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16mf4_m(vbool64_t mask,uint16_t* base,vuint16mf4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16mf2_m(vbool32_t mask,uint16_t* base,vuint16mf2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16mf2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16m1_m(vbool16_t mask,uint16_t* base,vuint16m1_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m1_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16m2_m(vbool8_t mask,uint16_t* base,vuint16m2_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16m4_m(vbool4_t mask,uint16_t* base,vuint16m4_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse16_v_u16m8_m(vbool2_t mask,uint16_t* base,vuint16m8_t value,size_t vl)
+{
+  __riscv_vse16_v_u16m8_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_i32mf2_m(vbool64_t mask,int32_t* base,vint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32mf2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_i32m1_m(vbool32_t mask,int32_t* base,vint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m1_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_i32m2_m(vbool16_t mask,int32_t* base,vint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_i32m4_m(vbool8_t mask,int32_t* base,vint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_i32m8_m(vbool4_t mask,int32_t* base,vint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_i32m8_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_u32mf2_m(vbool64_t mask,uint32_t* base,vuint32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32mf2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_u32m1_m(vbool32_t mask,uint32_t* base,vuint32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m1_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_u32m2_m(vbool16_t mask,uint32_t* base,vuint32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_u32m4_m(vbool8_t mask,uint32_t* base,vuint32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_u32m8_m(vbool4_t mask,uint32_t* base,vuint32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_u32m8_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_f32mf2_m(vbool64_t mask,float* base,vfloat32mf2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32mf2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_f32m1_m(vbool32_t mask,float* base,vfloat32m1_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m1_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_f32m2_m(vbool16_t mask,float* base,vfloat32m2_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_f32m4_m(vbool8_t mask,float* base,vfloat32m4_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse32_v_f32m8_m(vbool4_t mask,float* base,vfloat32m8_t value,size_t vl)
+{
+  __riscv_vse32_v_f32m8_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_i64m1_m(vbool64_t mask,int64_t* base,vint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m1_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_i64m2_m(vbool32_t mask,int64_t* base,vint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_i64m4_m(vbool16_t mask,int64_t* base,vint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_i64m8_m(vbool8_t mask,int64_t* base,vint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_i64m8_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_u64m1_m(vbool64_t mask,uint64_t* base,vuint64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m1_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_u64m2_m(vbool32_t mask,uint64_t* base,vuint64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_u64m4_m(vbool16_t mask,uint64_t* base,vuint64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_u64m8_m(vbool8_t mask,uint64_t* base,vuint64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_u64m8_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_f64m1_m(vbool64_t mask,double* base,vfloat64m1_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m1_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_f64m2_m(vbool32_t mask,double* base,vfloat64m2_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m2_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_f64m4_m(vbool16_t mask,double* base,vfloat64m4_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m4_m(mask,base,value,32);
+}
+
+void
+test___riscv_vse64_v_f64m8_m(vbool8_t mask,double* base,vfloat64m8_t value,size_t vl)
+{
+  __riscv_vse64_v_f64m8_m(mask,base,value,32);
+}
+
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*mf2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m1,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m2,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m4,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e8,\s*m8,\s*t[au],\s*m[au]\s+vse8\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*mf2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m1,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m2,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m4,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e16,\s*m8,\s*t[au],\s*m[au]\s+vse16\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 2 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*mf2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m1,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m2,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m4,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e32,\s*m8,\s*t[au],\s*m[au]\s+vse32\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m1,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m2,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m4,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
+/* { dg-final { scan-assembler-times {vsetvli\s+zero,\s*[a-x0-9]+,\s*e64,\s*m8,\s*t[au],\s*m[au]\s+vse64\.v\s+v[0-9]+,\s*0\([a-x0-9]+\),\s*v0.t} 3 } } */
