Mentions légales du service

Skip to content
Snippets Groups Projects
Commit 57595b92 authored by Mathieu Faverge's avatar Mathieu Faverge
Browse files

doc: update documentation of step2 accordingly

parent 31203eeb
No related branches found
No related tags found
1 merge request!500Fix descriptor creation with lapack layout matrices
...@@ -464,39 +464,44 @@ ...@@ -464,39 +464,44 @@
In Step2, we use the first way to create the descriptor: In Step2, we use the first way to create the descriptor:
#+begin_example #+begin_example
CHAMELEON_Desc_Create(&descA, NULL, ChamRealDouble, CHAMELEON_Desc_Create(&descA, A, ChamRealDouble,
NB, NB, NB*NB, N, N, NB, NB, NB*NB, N, N,
0, 0, N, N, 0, 0, N, N,
1, 1); 1, 1);
#+end_example #+end_example
* *descA* is the descriptor to create. * *descA* is the descriptor to create.
* The second argument is a pointer to existing data. The existing * The second argument is a pointer to existing data. The existing
data must follow LAPACK/PLASMA matrix layout [[sec:tile][Tile Data Layout]] data must follow LAPACK Column major layout [[sec:tile][Tile Data Layout]]
(1-D array column-major) if *CHAMELEON_Desc_Create* is used to create (1-D array column-major) if *CHAMELEON_Desc_Create* is used to create
the descriptor. The *CHAMELEON_Desc_Create_User* function can be used the descriptor. The *CHAMELEON_Desc_Create_User* function can be used
if you have data organized differently. This is discussed in if you have data organized differently. This is discussed in
the next paragraph [[sec:tuto_step3][Step3]]. Giving a *NULL* pointer means you let the next paragraph [[sec:tuto_step3][Step3]]. Giving a *NULL* pointer means you let
the function allocate memory space. This requires to copy your the function allocate memory space. This requires to copy the
data in the memory allocated by the *Desc_Create. This can be original data into the memory managed by the descriptor by
done with calling:
#+begin_example #+begin_example
CHAMELEON_Lapack_to_Tile(A, N, descA); CHAMELEON_Lap2Desc( ChamUpperLower, A, N, descA );
#+end_example #+end_example
* Third argument of @code{Desc_Create} is the datatype (used for * The third argument of @code{Desc_Create} is the datatype (used for
memory allocation). memory allocation).
* Fourth argument until sixth argument stand for respectively, * Fourth to eight arguments stand for respectively,
the number of rows (*NB*), columns (*NB*) in each tile, the total the number of rows (*NB*), columns (*NB*) in each tile, the total
number of values in a tile (*NB*NB*), the number of rows (*N*), number of values in a tile (*NB*NB*), the number of rows (*N*),
colmumns (*N*) in the entire matrix. and colmumns (*N*) in the entire matrix stored in the
* Seventh argument until ninth argument stand for respectively, memory area.
the beginning row (0), column (0) indexes of the submatrix and * The ninth (@code{i}) and tenth (@code{j}) arguments are
the number of rows (N), columns (N) in the submatrix. These deprecated and should be set to 0. Their are kept for API
backward compatibility.stand for respectively,
* The eleventh (@code{m}) and twelfth (@code{n}) gives the size
of the matrix used in the later algorithms. These
arguments are specific and used in precise cases. If you do arguments are specific and used in precise cases. If you do
not consider submatrices, just use 0, 0, NROWS, NCOLS. not consider submatrices, just use the same values as for the
* Two last arguments are the parameter of the 2-D block-cyclic entire matrix size.
* The last two arguments are the parameters of the 2-D block-cyclic
distribution grid, see [[http://www.netlib.org/scalapack/slug/node75.html][ScaLAPACK]]. To be able to use other data distribution grid, see [[http://www.netlib.org/scalapack/slug/node75.html][ScaLAPACK]]. To be able to use other data
distribution over the nodes, *CHAMELEON_Desc_Create_User* function distribution over the nodes, *CHAMELEON_Desc_Create_User* function
should be used. should be used. These should be both set to *1* if you provide
the data pointer.
**** Step3 **** Step3
<<sec:tuto_step3>> <<sec:tuto_step3>>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment