mirror of
https://github.com/Steffo99/unimore-hpc-assignments.git
synced 2025-02-16 17:13:57 +00:00
More variable name improvements
This commit is contained in:
parent
c96a67bcf7
commit
2b97507229
1 changed files with 6 additions and 6 deletions
12
atax/atax.cu
12
atax/atax.cu
|
@ -80,21 +80,21 @@ __host__ static void kernel_atax(DATA_TYPE** A, DATA_TYPE* X, DATA_TYPE* Y)
|
|||
{
|
||||
for (unsigned int x = 0; x < NY; x++)
|
||||
{
|
||||
Y[i] = 0;
|
||||
Y[x] = 0;
|
||||
}
|
||||
|
||||
for (unsigned int i = 0; i < NX; i++)
|
||||
for (unsigned int x = 0; x < NX; x++)
|
||||
{
|
||||
DATA_TYPE tmp = 0;
|
||||
|
||||
for (unsigned int j = 0; j < NY; j++)
|
||||
for (unsigned int y = 0; y < NY; y++)
|
||||
{
|
||||
tmp += A[i][j] * X[j];
|
||||
tmp += A[x][y] * X[y];
|
||||
}
|
||||
|
||||
for (unsigned int j = 0; j < NY; j++)
|
||||
for (unsigned int y = 0; y < NY; y++)
|
||||
{
|
||||
Y[j] = Y[j] + A[i][j] * tmp;
|
||||
Y[y] = Y[y] + A[x][y] * tmp;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue