Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dune-istl
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD 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
Stephan Hilb
dune-istl
Commits
23d94ffb
Commit
23d94ffb
authored
9 years ago
by
Christoph Grüninger
Browse files
Options
Downloads
Patches
Plain Diff
[tests] Catch Dune exceptions to ease identifying problems.
parent
0ec96232
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
dune/istl/paamg/test/amgtest.cc
+7
-2
7 additions, 2 deletions
dune/istl/paamg/test/amgtest.cc
dune/istl/paamg/test/fastamg.cc
+7
-4
7 additions, 4 deletions
dune/istl/paamg/test/fastamg.cc
dune/istl/test/superlutest.cc
+7
-0
7 additions, 0 deletions
dune/istl/test/superlutest.cc
with
21 additions
and
6 deletions
dune/istl/paamg/test/amgtest.cc
+
7
−
2
View file @
23d94ffb
...
...
@@ -165,8 +165,8 @@ void testAMG(int N, int coarsenTarget, int ml)
int
main
(
int
argc
,
char
**
argv
)
try
{
int
N
=
100
;
int
coarsenTarget
=
1200
;
int
ml
=
10
;
...
...
@@ -182,5 +182,10 @@ int main(int argc, char** argv)
testAMG
<
1
>
(
N
,
coarsenTarget
,
ml
);
testAMG
<
2
>
(
N
,
coarsenTarget
,
ml
);
}
catch
(
Dune
::
Exception
&
e
)
{
std
::
cerr
<<
"Dune reported error: "
<<
e
<<
std
::
endl
;
}
catch
(...)
{}
This diff is collapsed.
Click to expand it.
dune/istl/paamg/test/fastamg.cc
+
7
−
4
View file @
23d94ffb
...
...
@@ -29,10 +29,8 @@ void randomize(const M& mat, V& b)
template
<
int
BS
>
void
testAMG
(
int
N
,
int
coarsenTarget
,
int
ml
)
{
std
::
cout
<<
"N="
<<
N
<<
" coarsenTarget="
<<
coarsenTarget
<<
" maxlevel="
<<
ml
<<
std
::
endl
;
typedef
Dune
::
ParallelIndexSet
<
int
,
LocalIndex
,
512
>
ParallelIndexSet
;
ParallelIndexSet
indices
;
...
...
@@ -110,8 +108,8 @@ void testAMG(int N, int coarsenTarget, int ml)
int
main
(
int
argc
,
char
**
argv
)
try
{
int
N
=
100
;
int
coarsenTarget
=
1200
;
int
ml
=
10
;
...
...
@@ -127,5 +125,10 @@ int main(int argc, char** argv)
testAMG
<
1
>
(
N
,
coarsenTarget
,
ml
);
testAMG
<
2
>
(
N
,
coarsenTarget
,
ml
);
}
catch
(
Dune
::
Exception
&
e
)
{
std
::
cerr
<<
"Dune reported error: "
<<
e
<<
std
::
endl
;
}
catch
(...)
{}
This diff is collapsed.
Click to expand it.
dune/istl/test/superlutest.cc
+
7
−
0
View file @
23d94ffb
...
...
@@ -35,6 +35,7 @@ typedef std::complex<double> FIELD_TYPE;
#endif
int
main
(
int
argc
,
char
**
argv
)
try
{
const
int
BS
=
1
;
std
::
size_t
N
=
100
;
...
...
@@ -80,3 +81,9 @@ int main(int argc, char** argv)
solver1
.
apply
(
x
,
b
,
res
);
solver1
.
apply
(
reinterpret_cast
<
FIELD_TYPE
*>
(
&
x
[
0
]),
reinterpret_cast
<
FIELD_TYPE
*>
(
&
b
[
0
]));
}
catch
(
Dune
::
Exception
&
e
)
{
std
::
cerr
<<
"Dune reported error: "
<<
e
<<
std
::
endl
;
}
catch
(...)
{}
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