From: zianekhodja Date: Sun, 17 Jan 2016 16:06:32 +0000 (+0100) Subject: alogo 2 provisoire X-Git-Url: https://bilbo.iut-bm.univ-fcomte.fr/and/gitweb/kahina_paper2.git/commitdiff_plain/769f5a935a7453b848ad1358a006be5949b7c52f?ds=inline;hp=-c alogo 2 provisoire --- 769f5a935a7453b848ad1358a006be5949b7c52f diff --git a/paper.tex b/paper.tex index b579c69..6d8658f 100644 --- a/paper.tex +++ b/paper.tex @@ -17,8 +17,6 @@ \todo[color=orange!10,#1]{\sffamily\textbf{AS:} #2}\xspace} - - \begin{document} \title{Two parallel implementations of Ehrlich-Aberth algorithm for root-finding of polynomials on multiple GPUs with OpenMP and MPI} @@ -293,15 +291,14 @@ $id_{gpu}$ = cudaGetDevice()\; $n_{loc}$ = $n/ngpu$ (local size)\; %$idx$ = $id_{gpu}\times n_{loc}$ (local offset)\; Copy $P$, $P'$ from CPU to GPU\; -\While{\emph{not convergence}}{ +\While{$max > \epsilon$}{ Copy $Z$ from CPU to GPU\; $Z^{prev}$ = KernelSave($Z,n$)\; - $Z_{loc}$ = KernelUpdate($P,P',Z^{prev},n_{loc}$)\; + $Z_{loc}$ = KernelUpdate($P,P',Z,n_{loc}$)\; $\Delta Z_{loc}$ = KernelComputeError($Z_{loc},Z^{prev}_{loc},n_{loc}$)\; $\Delta Z_{max}[id_{gpu}]$ = CudaMaxFunction($\Delta Z_{loc},n_{loc}$)\; Copy $Z_{loc}$ from GPU to $Z$ in CPU\; - $max$ = MaxFunction($\Delta Z_{max},ngpu$)\; - TestConvergence($max,\epsilon$)\; + $max$ = MaxFunction($\Delta Z_{max},ngpu$)\; } \label{alg2-cuda-openmp} \LZK{J'ai modifié l'algo. Le $P$ est mis shared. Qu'en est-il pour