/*************************************************************************** Copyright (c) 2022-2023, Advanced Micro Devices, Inc. All rights reserved. ***************************************************************************/ #include "Jacobi.hpp" //Jacobi iterative method // U = U + D^{-1}*(RHS - AU) __global__ void JacobiIterationKernel(const int N, const dfloat dx, const dfloat dy, const dfloat *__restrict__ RHS, const dfloat *__restrict__ AU, dfloat *__restrict__ RES, dfloat *__restrict__ U) { const int id = threadIdx.x+blockIdx.x*blockDim.x; if (id