Remove unnecessary argument in mju_mulSymVecSparse
PiperOrigin-RevId: 758688536 Change-Id: Ife1099b948215363ddaa6d0b0edcf3492edcddcc
This commit is contained in:
committed by
Copybara-Service
parent
71bdd915f7
commit
e1baa15776
@@ -227,7 +227,7 @@ void mju_addToSymSparse(mjtNum* res, const mjtNum* mat, int n,
|
||||
void mju_mulSymVecSparse(mjtNum* restrict res, const mjtNum* restrict mat,
|
||||
const mjtNum* restrict vec, int n,
|
||||
const int* restrict rownnz, const int* restrict rowadr,
|
||||
const int* restrict diagnum, const int* restrict colind) {
|
||||
const int* restrict colind) {
|
||||
// clear res
|
||||
mju_zero(res, n);
|
||||
|
||||
@@ -240,13 +240,6 @@ void mju_mulSymVecSparse(mjtNum* restrict res, const mjtNum* restrict mat,
|
||||
// diagonal
|
||||
res[i] = row[diag] * vec[i];
|
||||
|
||||
// TODO: consider using SIMD if diagnum[i] >= 4
|
||||
|
||||
// shortcut for diagonal row/column
|
||||
if (diagnum[i]) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// off-diagonals
|
||||
const int* ind = colind + adr;
|
||||
for (int k=diag-1; k >= 0; k--) {
|
||||
|
||||
Reference in New Issue
Block a user