Skip to content

Commit 785c60f

Browse files
revisions needed for RISC-V vectorization; also change to v10.1.0
1 parent 7b7ab6e commit 785c60f

16 files changed

Lines changed: 47 additions & 47 deletions

File tree

Doc/ChangeLog

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
May FIXME, 2025: version 10.1.0
2+
3+
* add support for RISC-V vectorization: contributed by Rodion Suvorov
4+
15
May 5, 2025: version 10.0.5
26

37
* revised cmake build system

Doc/GraphBLAS_version.tex

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
% version of SuiteSparse:GraphBLAS
22
\date{VERSION
3-
10.0.5,
4-
May 5, 2025}
3+
10.1.0,
4+
May FIXME, 2025}
55

Doc/UserGuide/GrB_release.tex

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@ \section{Release Notes}
55

66
\begin{itemize}
77

8+
\item May FIXME, 2025: version 10.1.0
9+
10+
\begin{itemize}
11+
\item add support for RISC-V vectorization: contributed by Rodion Suvorov
12+
\end{itemize}
13+
814
\item May 5, 2025: version 10.0.5
915

1016
\begin{itemize}

FactoryKernels/GB_AxB__plus_times_fp32.c

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@
4949
// special case semirings:
5050

5151
#define GB_SEMIRING_HAS_AVX_IMPLEMENTATION 1
52-
#define GB_SEMIRING_HAS_RVV_IMPLEMENTATION 1
5352

5453
// monoid properties:
5554
#define GB_Z_TYPE float
@@ -290,16 +289,11 @@ GrB_Info GB (_Asaxpy4B__plus_times_fp32)
290289

291290
//----------------------------------------------------------------------
292291
// saxpy5 method with RISC-V vectors
293-
//---------------------------------------------------------------------
292+
//----------------------------------------------------------------------
294293

295294
#if GB_COMPILER_SUPPORTS_RVV1
296295

297296
#include <riscv_vector.h>
298-
#define VSETVL(x) __riscv_vsetvl_e32m8(x)
299-
#define VLE(x,y) __riscv_vle32_v_f32m8(x, y)
300-
#define VFMACC(x,y,z,w) __riscv_vfmacc_vf_f32m8(x, y, z, w)
301-
#define VSE(x,y,z) __riscv_vse32_v_f32m8(x, y, z)
302-
#define VECTORTYPE vfloat32m8_t
303297

304298
GB_TARGET_RVV1 static inline void GB_AxB_saxpy5_unrolled_rvv
305299
(

FactoryKernels/GB_AxB__plus_times_fp64.c

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@
4949
// special case semirings:
5050

5151
#define GB_SEMIRING_HAS_AVX_IMPLEMENTATION 1
52-
#define GB_SEMIRING_HAS_RVV_IMPLEMENTATION 1
5352

5453
// monoid properties:
5554
#define GB_Z_TYPE double
@@ -294,12 +293,7 @@ GrB_Info GB (_Asaxpy4B__plus_times_fp64)
294293

295294
#if GB_COMPILER_SUPPORTS_RVV1
296295

297-
#include <riscv_vector.h>
298-
#define VSETVL(x) __riscv_vsetvl_e64m8(x)
299-
#define VLE(x,y) __riscv_vle64_v_f64m8(x, y)
300-
#define VFMACC(x,y,z,w) __riscv_vfmacc_vf_f64m8(x, y, z, w)
301-
#define VSE(x,y,z) __riscv_vse64_v_f64m8(x, y, z)
302-
#define VECTORTYPE vfloat64m8_t
296+
#include <riscv_vector.h>
303297

304298
GB_TARGET_RVV1 static inline void GB_AxB_saxpy5_unrolled_rvv
305299
(

Include/GraphBLAS.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// SuiteSparse:GraphBLAS 10.0.5
1+
// SuiteSparse:GraphBLAS 10.1.0
22
//------------------------------------------------------------------------------
33
// GraphBLAS.h: definitions for the GraphBLAS package
44
//------------------------------------------------------------------------------
@@ -268,10 +268,10 @@
268268

269269
// The version of this implementation, and the GraphBLAS API version:
270270
#define GxB_IMPLEMENTATION_NAME "SuiteSparse:GraphBLAS"
271-
#define GxB_IMPLEMENTATION_DATE "May 5, 2025"
271+
#define GxB_IMPLEMENTATION_DATE "May FIXME, 2025"
272272
#define GxB_IMPLEMENTATION_MAJOR 10
273-
#define GxB_IMPLEMENTATION_MINOR 0
274-
#define GxB_IMPLEMENTATION_SUB 5
273+
#define GxB_IMPLEMENTATION_MINOR 1
274+
#define GxB_IMPLEMENTATION_SUB 0
275275
#define GxB_SPEC_DATE "Dec 22, 2023"
276276
#define GxB_SPEC_MAJOR 2
277277
#define GxB_SPEC_MINOR 1

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ SuiteSparse:GraphBLAS, Timothy A. Davis, (c) 2017-2025, All Rights Reserved.
44

55
SPDX-License-Identifier: Apache-2.0
66

7-
VERSION 10.0.5, May 5, 2025
7+
VERSION 10.1.0, May FIXME, 2025
88

99
SuiteSparse:GraphBLAS is a complete implementation of the GraphBLAS standard,
1010
which defines a set of sparse matrix operations on an extended algebra of

Source/codegen/Generator/GB_AxB.c

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,6 @@
77

88
//------------------------------------------------------------------------------
99

10-
#ifdef GBRISCV64
11-
#include <riscv_vector.h>
12-
#endif
1310
#include "GB_control.h"
1411
GB_type_enabled
1512
#if GB_TYPE_ENABLED
@@ -313,13 +310,15 @@ m4_divert(if_semiring_has_avx)
313310
}
314311

315312
#endif
316-
m4_divert(if_semiring_has_rvv)
313+
317314
//----------------------------------------------------------------------
318315
// saxpy5 method with RISC-V vectors
319316
//----------------------------------------------------------------------
320317

321318
#if GB_COMPILER_SUPPORTS_RVV1
322319

320+
#include <riscv_vector.h>
321+
323322
GB_TARGET_RVV1 static inline void GB_AxB_saxpy5_unrolled_rvv
324323
(
325324
GrB_Matrix C,

Source/codegen/codegen_axb_method.m

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -298,6 +298,7 @@ function codegen_axb_method (addop, multop, update, addfunc, mult, ztype, xytype
298298
% enable the avx-based methods. only two semirings (plus_times_fp32 and
299299
% plus_times_fp64) are accelerated with AVX2 or AVX512f instructions. More
300300
% semirings will be accelerated in the future.
301+
% This flag is also used to trigger the RISC-V RVV1.0 vectorization
301302
fprintf (f, 'm4_define(`if_semiring_has_avx'', `0'')\n') ;
302303
fprintf (f, 'm4_define(`GB_semiring_has_avx'', `#define GB_SEMIRING_HAS_AVX_IMPLEMENTATION 1'')\n') ;
303304
else

Source/jit_kernels/include/GB_jit_kernel_proto.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,7 @@ GrB_Info GB_jit_kernel_AxB_saxpy5 \
225225
const int64_t *restrict B_slice, \
226226
bool cpu_has_avx2, \
227227
bool cpu_has_avx512f, \
228+
bool cpu_has_rvv1, \
228229
const void *theta, \
229230
const GB_callback_struct *restrict my_callback \
230231
)

0 commit comments

Comments
 (0)