Mentions légales du service
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
spm
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
solverstack
spm
Commits
b8979792
Commit
b8979792
authored
7 years ago
by
Mathieu Faverge
Browse files
Options
Downloads
Patches
Plain Diff
Big cleanup in the getopt call and add the spmPrintInfo call to examples
parent
f886b4c1
No related branches found
No related tags found
Loading
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
drivers/laplacian.c
+2
-2
2 additions, 2 deletions
drivers/laplacian.c
spm_read_driver.c
+1
-11
1 addition, 11 deletions
spm_read_driver.c
with
3 additions
and
13 deletions
drivers/laplacian.c
+
2
−
2
View file @
b8979792
...
@@ -90,9 +90,9 @@ laplacian_parse_info( const char *filename,
...
@@ -90,9 +90,9 @@ laplacian_parse_info( const char *filename,
/* Look for the datatype */
/* Look for the datatype */
{
{
char
flt
;
char
flt
;
char
*
tmpf
=
strdup
(
filename
);
char
*
tmpf
=
str
n
dup
(
filename
,
256
);
if
(
sscanf
(
filename
,
"%c:%25
6
s"
,
&
flt
,
tmpf
)
==
2
)
{
if
(
sscanf
(
filename
,
"%c:%25
4
s"
,
&
flt
,
tmpf
)
==
2
)
{
filename
+=
2
;
filename
+=
2
;
switch
(
flt
){
switch
(
flt
){
case
'Z'
:
case
'Z'
:
...
...
This diff is collapsed.
Click to expand it.
spm_read_driver.c
+
1
−
11
View file @
b8979792
...
@@ -88,29 +88,22 @@ spmReadDriver( pastix_driver_t driver,
...
@@ -88,29 +88,22 @@ spmReadDriver( pastix_driver_t driver,
case
PastixDriverHB
:
case
PastixDriverHB
:
/* TODO: Possible to read the RHS, the solution or a guess of the solution */
/* TODO: Possible to read the RHS, the solution or a guess of the solution */
printf
(
"driver: HB file: %s
\n
"
,
filename
);
readHB
(
filename
,
spm
);
readHB
(
filename
,
spm
);
break
;
break
;
case
PastixDriverIJV
:
case
PastixDriverIJV
:
printf
(
"driver: 3files file: %s
\n
"
,
filename
);
readIJV
(
filename
,
spm
);
readIJV
(
filename
,
spm
);
break
;
break
;
case
PastixDriverMM
:
case
PastixDriverMM
:
printf
(
"driver: MatrixMarket file: %s
\n
"
,
filename
);
readMM
(
filename
,
spm
);
readMM
(
filename
,
spm
);
break
;
break
;
case
PastixDriverLaplacian
:
case
PastixDriverLaplacian
:
if
(
mpirank
==
0
)
printf
(
"driver Laplacian: %s
\n
"
,
filename
);
genLaplacian
(
filename
,
spm
);
genLaplacian
(
filename
,
spm
);
break
;
break
;
case
PastixDriverXLaplacian
:
case
PastixDriverXLaplacian
:
if
(
mpirank
==
0
)
printf
(
"driver Extended Laplacian: %s
\n
"
,
filename
);
genExtendedLaplacian
(
filename
,
spm
);
genExtendedLaplacian
(
filename
,
spm
);
break
;
break
;
...
@@ -148,7 +141,7 @@ spmReadDriver( pastix_driver_t driver,
...
@@ -148,7 +141,7 @@ spmReadDriver( pastix_driver_t driver,
break
;
break
;
default:
default:
fprintf
(
stderr
,
"
d
river: Driver not implemented
\n
"
);
fprintf
(
stderr
,
"
spmReadD
river: Driver not implemented
\n
"
);
}
}
}
}
...
@@ -159,9 +152,6 @@ spmReadDriver( pastix_driver_t driver,
...
@@ -159,9 +152,6 @@ spmReadDriver( pastix_driver_t driver,
MPI_Bcast
(
spm
,
sizeof
(
pastix_spm_t
),
MPI_CHAR
,
0
,
comm
);
MPI_Bcast
(
spm
,
sizeof
(
pastix_spm_t
),
MPI_CHAR
,
0
,
comm
);
MPI_Bcast
(
&
nnz
,
1
,
PASTIX_MPI_INT
,
0
,
comm
);
MPI_Bcast
(
&
nnz
,
1
,
PASTIX_MPI_INT
,
0
,
comm
);
fprintf
(
stderr
,
"%d: mtxtype=%d, flttype=%d, nnz=%ld, gN=%ld
\n
"
,
mpirank
,
spm
->
mtxtype
,
spm
->
flttype
,
(
long
)
nnz
,
(
long
)
spm
->
gN
);
if
(
mpirank
!=
0
)
if
(
mpirank
!=
0
)
{
{
spm
->
colptr
=
(
pastix_int_t
*
)
malloc
((
spm
->
gN
+
1
)
*
sizeof
(
pastix_int_t
));
spm
->
colptr
=
(
pastix_int_t
*
)
malloc
((
spm
->
gN
+
1
)
*
sizeof
(
pastix_int_t
));
...
...
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