@@ -119,12 +119,20 @@ endif
119119
120120DGEMMKERNEL = dgemm_kernel_$(DGEMM_UNROLL_M)x$(DGEMM_UNROLL_N)_zvl256b.c
121121DGEMMONCOPY = ../generic/gemm_ncopy_$(DGEMM_UNROLL_N).c
122+ ifneq ($(filter $(DGEMM_UNROLL_N),4 8 16),)
123+ DGEMMOTCOPY = gemm_tcopy_$(DGEMM_UNROLL_N)_rvv.c
124+ else
122125DGEMMOTCOPY = ../generic/gemm_tcopy_$(DGEMM_UNROLL_N).c
126+ endif
123127DGEMMONCOPYOBJ = dgemm_oncopy$(TSUFFIX).$(SUFFIX)
124128DGEMMOTCOPYOBJ = dgemm_otcopy$(TSUFFIX).$(SUFFIX)
125129ifneq ($(DGEMM_UNROLL_M), $(DGEMM_UNROLL_N))
126130DGEMMINCOPY = ../generic/gemm_ncopy_$(DGEMM_UNROLL_M).c
131+ ifneq ($(filter $(DGEMM_UNROLL_M),4 8 16),)
132+ DGEMMITCOPY = gemm_tcopy_$(DGEMM_UNROLL_M)_rvv.c
133+ else
127134DGEMMITCOPY = ../generic/gemm_tcopy_$(DGEMM_UNROLL_M).c
135+ endif
128136DGEMMINCOPYOBJ = dgemm_incopy$(TSUFFIX).$(SUFFIX)
129137DGEMMITCOPYOBJ = dgemm_itcopy$(TSUFFIX).$(SUFFIX)
130138endif
@@ -226,13 +234,23 @@ SOMATCOPY_CT = omatcopy_ct_rvv.c
226234ifeq ($(BUILD_HFLOAT16), 1)
227235SHGEMMKERNEL = shgemm_kernel_$(SHGEMM_UNROLL_M)x$(SHGEMM_UNROLL_N)_zvl256b.c
228236ifneq ($(SHGEMM_UNROLL_M), $(SHGEMM_UNROLL_N))
237+ ifneq ($(filter $(SHGEMM_UNROLL_M),8 16),)
238+ SHGEMMINCOPY = gemm_ncopy_$(SHGEMM_UNROLL_M)fp_rvv.c
239+ SHGEMMITCOPY = gemm_tcopy_$(SHGEMM_UNROLL_M)fp_rvv.c
240+ else
229241SHGEMMINCOPY = ../generic/gemm_ncopy_$(SHGEMM_UNROLL_M).c
230242SHGEMMITCOPY = ../generic/gemm_tcopy_$(SHGEMM_UNROLL_M).c
243+ endif
231244SHGEMMINCOPYOBJ = shgemm_incopy$(TSUFFIX).$(SUFFIX)
232245SHGEMMITCOPYOBJ = shgemm_itcopy$(TSUFFIX).$(SUFFIX)
233246endif
247+ ifneq ($(filter $(SHGEMM_UNROLL_N),8 16),)
248+ SHGEMMONCOPY = gemm_ncopy_$(SHGEMM_UNROLL_N)fp_rvv.c
249+ SHGEMMOTCOPY = gemm_tcopy_$(SHGEMM_UNROLL_N)fp_rvv.c
250+ else
234251SHGEMMONCOPY = ../generic/gemm_ncopy_$(SHGEMM_UNROLL_N).c
235252SHGEMMOTCOPY = ../generic/gemm_tcopy_$(SHGEMM_UNROLL_N).c
253+ endif
236254SHGEMMONCOPYOBJ = shgemm_oncopy$(TSUFFIX).$(SUFFIX)
237255SHGEMMOTCOPYOBJ = shgemm_otcopy$(TSUFFIX).$(SUFFIX)
238256ifndef SHGEMM_BETA
@@ -243,13 +261,23 @@ endif
243261ifeq ($(BUILD_BFLOAT16), 1)
244262SBGEMMKERNEL = sbgemm_kernel_$(SBGEMM_UNROLL_M)x$(SBGEMM_UNROLL_N)_zvl256b.c
245263ifneq ($(SBGEMM_UNROLL_M), $(SBGEMM_UNROLL_N))
264+ ifneq ($(filter $(SBGEMM_UNROLL_M),8 16),)
265+ SBGEMMINCOPY = gemm_ncopy_$(SBGEMM_UNROLL_M)fp_rvv.c
266+ SBGEMMITCOPY = gemm_tcopy_$(SBGEMM_UNROLL_M)fp_rvv.c
267+ else
246268SBGEMMINCOPY = ../generic/gemm_ncopy_$(SBGEMM_UNROLL_M).c
247269SBGEMMITCOPY = ../generic/gemm_tcopy_$(SBGEMM_UNROLL_M).c
270+ endif
248271SBGEMMINCOPYOBJ = sbgemm_incopy$(TSUFFIX).$(SUFFIX)
249272SBGEMMITCOPYOBJ = sbgemm_itcopy$(TSUFFIX).$(SUFFIX)
250273endif
274+ ifneq ($(filter $(SBGEMM_UNROLL_N),8 16),)
275+ SBGEMMONCOPY = gemm_ncopy_$(SBGEMM_UNROLL_N)fp_rvv.c
276+ SBGEMMOTCOPY = gemm_tcopy_$(SBGEMM_UNROLL_N)fp_rvv.c
277+ else
251278SBGEMMONCOPY = ../generic/gemm_ncopy_$(SBGEMM_UNROLL_N).c
252279SBGEMMOTCOPY = ../generic/gemm_tcopy_$(SBGEMM_UNROLL_N).c
280+ endif
253281SBGEMMONCOPYOBJ = sbgemm_oncopy$(TSUFFIX).$(SUFFIX)
254282SBGEMMOTCOPYOBJ = sbgemm_otcopy$(TSUFFIX).$(SUFFIX)
255283ifndef SBGEMM_BETA
0 commit comments