From 2c5abaf6a6c31ac160a839c9cf5177c0a6410237 Mon Sep 17 00:00:00 2001
From: Mathieu Faverge <mathieu.faverge@inria.fr>
Date: Tue, 11 Apr 2017 13:57:31 +0200
Subject: [PATCH] Add documentation to cuda_zgeadd kernel

---
 cudablas/compute/cuda_zgeadd.c | 64 ++++++++++++++++++++++++++++++----
 1 file changed, 58 insertions(+), 6 deletions(-)

diff --git a/cudablas/compute/cuda_zgeadd.c b/cudablas/compute/cuda_zgeadd.c
index 43b27291f..6ed44c20b 100644
--- a/cudablas/compute/cuda_zgeadd.c
+++ b/cudablas/compute/cuda_zgeadd.c
@@ -1,13 +1,11 @@
 /**
  *
- * @copyright (c) 2009-2014 The University of Tennessee and The University
- *                          of Tennessee Research Foundation.
- *                          All rights reserved.
- * @copyright (c) 2012-2016 Inria. All rights reserved.
- * @copyright (c) 2012-2014 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria, Univ. Bordeaux. All rights reserved.
+ * @copyright (c) 2009-2014 The University of Tennessee and The University of
+ *                          Tennessee Research Foundation.  All rights reserved.
+ * @copyright (c) 2012-2017 Bordeaux INP, CNRS (LaBRI UMR 5800), Inria,
+ *                          Univ. Bordeaux. All rights reserved.
  *
  **/
-
 /**
  *
  * @file cuda_zgeadd.c
@@ -29,6 +27,60 @@
 #error "This file requires cublas api v2 support"
 #endif
 
+/**
+ ******************************************************************************
+ *
+ * @ingroup CUDA_MORSE_Complex64_t
+ *
+ *  CUDA_zgeadd adds to matrices together as in PBLAS pzgeadd.
+ *
+ *       B <- alpha * op(A)  + beta * B,
+ *
+ * where op(X) = X, X', or conj(X')
+ *
+ *******************************************************************************
+ *
+ * @param[in] trans
+ *          Specifies whether the matrix A is non-transposed, transposed, or
+ *          conjugate transposed
+ *          = MorseNoTrans:   op(A) = A
+ *          = MorseTrans:     op(A) = A'
+ *          = MorseConjTrans: op(A) = conj(A')
+ *
+ * @param[in] M
+ *          Number of rows of the matrices op(A) and B.
+ *
+ * @param[in] N
+ *          Number of columns of the matrices op(A) and B.
+ *
+ * @param[in] alpha
+ *          Scalar factor of A.
+ *
+ * @param[in] A
+ *          Matrix of size LDA-by-N, if trans = MorseNoTrans, LDA-by-M
+ *          otherwise.
+ *
+ * @param[in] LDA
+ *          Leading dimension of the array A. LDA >= max(1,k), with k=M, if
+ *          trans = MorseNoTrans, and k=N otherwise.
+ *
+ * @param[in] beta
+ *          Scalar factor of B.
+ *
+ * @param[in,out] B
+ *          Matrix of size LDB-by-N.
+ *          On exit, B = alpha * op(A) + beta * B
+ *
+ * @param[in] LDB
+ *          Leading dimension of the array B. LDB >= max(1,M)
+ *
+ *******************************************************************************
+ *
+ * @return
+ *          \retval MORSE_SUCCESS successful exit
+ *          \retval <0 if -i, the i-th argument had an illegal value
+ *
+ ******************************************************************************/
 int CUDA_zgeadd(MORSE_enum trans,
                 int m, int n,
                 const cuDoubleComplex *alpha,
-- 
GitLab