Skip to content

Commit

Permalink
Merge pull request #446 from Cytnx-dev/fix-cuda-build
Browse files Browse the repository at this point in the history
Fix typo
  • Loading branch information
IvanaGyro authored Aug 26, 2024
2 parents c6dddb6 + 6c400be commit 4a84b67
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/backend/linalg_internal_gpu/cudaMemcpyTruncation.cu
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ namespace cytnx {
}
cytnx_uint64 truc_dim = Kdim;
for (cytnx_int64 i = Kdim - 1; i >= 0; i--) {
if (((cytnx_double *)S._impl->storage()._impl->Mem)[i] < err and truc - 1 >= mindim) {
if (((cytnx_double *)S._impl->storage()._impl->Mem)[i] < err and truc_dim - 1 >= mindim) {
truc_dim--;
} else {
break;
Expand Down Expand Up @@ -112,7 +112,7 @@ namespace cytnx {
}
cytnx_uint64 truc_dim = Kdim;
for (cytnx_int64 i = Kdim - 1; i >= 0; i--) {
if (((cytnx_double *)S._impl->storage()._impl->Mem)[i] < err and truc - 1 >= mindim) {
if (((cytnx_double *)S._impl->storage()._impl->Mem)[i] < err and truc_dim - 1 >= mindim) {
truc_dim--;
} else {
break;
Expand Down Expand Up @@ -183,7 +183,7 @@ namespace cytnx {
}
cytnx_uint64 truc_dim = Kdim;
for (cytnx_int64 i = Kdim - 1; i >= 0; i--) {
if (((cytnx_double *)S._impl->storage()._impl->Mem)[i] < err and truc - 1 >= mindim) {
if (((cytnx_double *)S._impl->storage()._impl->Mem)[i] < err and truc_dim - 1 >= mindim) {
truc_dim--;
} else {
break;
Expand Down Expand Up @@ -254,7 +254,7 @@ namespace cytnx {
}
cytnx_uint64 truc_dim = Kdim;
for (cytnx_int64 i = Kdim - 1; i >= 0; i--) {
if (((cytnx_double *)S._impl->storage()._impl->Mem)[i] < err and truc - 1 >= mindim) {
if (((cytnx_double *)S._impl->storage()._impl->Mem)[i] < err and truc_dim - 1 >= mindim) {
truc_dim--;
} else {
break;
Expand Down

0 comments on commit 4a84b67

Please sign in to comment.