Mentions légales du service
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Chameleon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
solverstack
Chameleon
Commits
bd7d2bf0
Commit
bd7d2bf0
authored
1 year ago
by
PRUVOST Florent
Committed by
Mathieu Faverge
1 year ago
Browse files
Options
Downloads
Patches
Plain Diff
Fix example lapack_to_chameleon step7: descB instead of descA in the plrnt_cpu function
parent
9b9b6d1a
No related branches found
No related tags found
1 merge request
!446
Example comm split
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
example/lapack_to_chameleon/step7.c
+5
-4
5 additions, 4 deletions
example/lapack_to_chameleon/step7.c
example/lapack_to_chameleon/step7.h
+5
-5
5 additions, 5 deletions
example/lapack_to_chameleon/step7.h
with
10 additions
and
9 deletions
example/lapack_to_chameleon/step7.c
+
5
−
4
View file @
bd7d2bf0
...
@@ -29,7 +29,7 @@
...
@@ -29,7 +29,7 @@
* to fill the matrix with random data, CHAMELEON_dLapack_to_Tile() to fill the matrix
* to fill the matrix with random data, CHAMELEON_dLapack_to_Tile() to fill the matrix
* with data stored in a lapack-like buffer, or CHAMELEON_Desc_Create_User() that can be used
* with data stored in a lapack-like buffer, or CHAMELEON_Desc_Create_User() that can be used
* to describe an arbitrary tile matrix structure.
* to describe an arbitrary tile matrix structure.
* In this example, the map
callback
function are just wrapper towards CORE_xxx() functions, so the output
* In this example, the map function are just wrapper towards CORE_xxx() functions, so the output
* of the program step7 should be exactly similar to that of step6.
* of the program step7 should be exactly similar to that of step6.
* The difference is that the funtion used to fill the tiles is provided by the user,
* The difference is that the funtion used to fill the tiles is provided by the user,
* and therefore this approach is much more flexible.
* and therefore this approach is much more flexible.
...
@@ -133,7 +133,7 @@ int main(int argc, char *argv[]) {
...
@@ -133,7 +133,7 @@ int main(int argc, char *argv[]) {
GRID_P
,
GRID_Q
);
GRID_P
,
GRID_Q
);
/* generate A matrix with random values such that it is spd.
/* generate A matrix with random values such that it is spd.
We use the
callback
function Cham_build_plgsy() defined in step7.h
We use the function Cham_build_plgsy() defined in step7.h
In this example, it is just a wrapper toward CORE_dplgsy() */
In this example, it is just a wrapper toward CORE_dplgsy() */
struct
data_pl
plgsy_args
=
{
(
double
)
N
,
51
};
struct
data_pl
plgsy_args
=
{
(
double
)
N
,
51
};
struct
cham_map_operator_s
plgsy_op
=
{
struct
cham_map_operator_s
plgsy_op
=
{
...
@@ -148,7 +148,8 @@ int main(int argc, char *argv[]) {
...
@@ -148,7 +148,8 @@ int main(int argc, char *argv[]) {
};
};
CHAMELEON_mapv_Tile
(
ChamUpperLower
,
1
,
&
plgsy_data
,
&
plgsy_op
,
&
plgsy_args
);
CHAMELEON_mapv_Tile
(
ChamUpperLower
,
1
,
&
plgsy_data
,
&
plgsy_op
,
&
plgsy_args
);
/* generate RHS with the callback Cham_build_callback_plrnt() */
/* generate RHS with the function Cham_build_plrnt_cpu() defined in
step7.h */
struct
data_pl
plrnt_args
=
{
0
.,
5673
};
struct
data_pl
plrnt_args
=
{
0
.,
5673
};
struct
cham_map_operator_s
plrnt_op
=
{
struct
cham_map_operator_s
plrnt_op
=
{
.
name
=
"plrnt"
,
.
name
=
"plrnt"
,
...
@@ -158,7 +159,7 @@ int main(int argc, char *argv[]) {
...
@@ -158,7 +159,7 @@ int main(int argc, char *argv[]) {
};
};
struct
cham_map_data_s
plrnt_data
=
{
struct
cham_map_data_s
plrnt_data
=
{
.
access
=
ChamW
,
.
access
=
ChamW
,
.
desc
=
desc
A
,
.
desc
=
desc
B
,
};
};
CHAMELEON_mapv_Tile
(
ChamUpperLower
,
1
,
&
plrnt_data
,
&
plrnt_op
,
&
plrnt_args
);
CHAMELEON_mapv_Tile
(
ChamUpperLower
,
1
,
&
plrnt_data
,
&
plrnt_op
,
&
plrnt_args
);
...
...
This diff is collapsed.
Click to expand it.
example/lapack_to_chameleon/step7.h
+
5
−
5
View file @
bd7d2bf0
...
@@ -65,11 +65,11 @@ static void init_iparam(int iparam[IPARAM_SIZEOF]){
...
@@ -65,11 +65,11 @@ static void init_iparam(int iparam[IPARAM_SIZEOF]){
}
}
/**
/**
*
Callback f
unction used to build matrix blocks
*
F
unction used to build matrix blocks
* Cham_build_
callback_
plgsy : random symmetric positive definite
* Cham_build_plgsy
_cpu
: random symmetric positive definite
* Cham_build_
callback_
plrnt : random general
* Cham_build_plrnt
_cpu
: random general
* These 2 functions use data_pl to get data on the matrix to build, passed through the opaque pointer '
user_data
'
* These 2 functions use data_pl to get data on the matrix to build, passed through the opaque pointer '
op_args
'
* The
callback
is expected to build the block of matrix (m,n) and store it in tile
->mat
* The
function
is expected to build the block of matrix (m,n) and store it in tile
A
*/
*/
struct
data_pl
{
struct
data_pl
{
double
bump
;
double
bump
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment