commit:     ac7d0de84087159e469ae53c84f838e8cea30f70
Author:     Yiyang Wu <xgreenlandforwyy <AT> gmail <DOT> com>
AuthorDate: Sat Jun 11 02:04:54 2022 +0000
Commit:     Benda XU <heroxbd <AT> gentoo <DOT> org>
CommitDate: Mon Jun 20 11:51:58 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ac7d0de8

sci-libs/rocSPARSE: backport upstream fix for test

Signed-off-by: Yiyang Wu <xgreenlandforwyy <AT> gmail.com>
Signed-off-by: Benda Xu <heroxbd <AT> gentoo.org>

 .../rocSPARSE-5.0.2-remove-incorrect-assert.patch  | 34 ++++++++++++++++++++++
 sci-libs/rocSPARSE/rocSPARSE-5.0.2.ebuild          |  3 +-
 2 files changed, 36 insertions(+), 1 deletion(-)

diff --git 
a/sci-libs/rocSPARSE/files/rocSPARSE-5.0.2-remove-incorrect-assert.patch 
b/sci-libs/rocSPARSE/files/rocSPARSE-5.0.2-remove-incorrect-assert.patch
new file mode 100644
index 000000000000..9baa962c05f5
--- /dev/null
+++ b/sci-libs/rocSPARSE/files/rocSPARSE-5.0.2-remove-incorrect-assert.patch
@@ -0,0 +1,34 @@
+From 48b763f01b658dece7f71784fe4362e56167db2f Mon Sep 17 00:00:00 2001
+From: James Sandham <33790278+jsand...@users.noreply.github.com>
+Date: Fri, 28 Jan 2022 10:24:08 -0800
+Subject: [PATCH] remove incorrect assert from spmm_bell (#302)
+
+Co-authored-by: jsandham <james.sand...@amd.com>
+---
+ library/src/level3/rocsparse_bellmm_template_general.cpp | 7 +++----
+ 1 file changed, 3 insertions(+), 4 deletions(-)
+
+diff --git a/library/src/level3/rocsparse_bellmm_template_general.cpp 
b/library/src/level3/rocsparse_bellmm_template_general.cpp
+index 81f36a32..bbce9a17 100644
+--- a/library/src/level3/rocsparse_bellmm_template_general.cpp
++++ b/library/src/level3/rocsparse_bellmm_template_general.cpp
+@@ -1,6 +1,6 @@
+ /*! \file */
+ /* ************************************************************************
+- * Copyright (c) 2021 Advanced Micro Devices, Inc.
++ * Copyright (c) 2021-2022 Advanced Micro Devices, Inc.
+  *
+  * Permission is hereby granted, free of charge, to any person obtaining a 
copy
+  * of this software and associated documentation files (the "Software"), to 
deal
+@@ -101,9 +101,8 @@ rocsparse_status 
rocsparse_bellmm_template_general(rocsparse_handle          han
+                                                    I                         
ldc)
+ {
+     hipStream_t stream = handle->stream;
+-    assert(block_dim > 32);
+-    dim3 bellmm_blocks((mb - 1) / 1 + 1, (n - 1) / 32 + 1);
+-    dim3 bellmm_threads(32, 32, 1);
++    dim3        bellmm_blocks((mb - 1) / 1 + 1, (n - 1) / 32 + 1);
++    dim3        bellmm_threads(32, 32, 1);
+     assert(trans_A == rocsparse_operation_none);
+     //
+     // What happends if A needs to be transposed?

diff --git a/sci-libs/rocSPARSE/rocSPARSE-5.0.2.ebuild 
b/sci-libs/rocSPARSE/rocSPARSE-5.0.2.ebuild
index 3a6f6c8063ad..90733f9a5e59 100644
--- a/sci-libs/rocSPARSE/rocSPARSE-5.0.2.ebuild
+++ b/sci-libs/rocSPARSE/rocSPARSE-5.0.2.ebuild
@@ -59,7 +59,8 @@ RESTRICT="!test? ( test )"
 S="${WORKDIR}/rocSPARSE-rocm-${PV}"
 
 PATCHES=( "${FILESDIR}/${PN}-5.0.2-remove-matrices-unpacking.patch"
-       "${FILESDIR}/${PN}-5.0.2-enable-gfx1031.patch" )
+       "${FILESDIR}/${PN}-5.0.2-enable-gfx1031.patch"
+       "${FILESDIR}/${PN}-5.0.2-remove-incorrect-assert.patch" )
 
 python_check_deps() {
        if use test; then

Reply via email to