Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
iwr
amdis
Commits
209f7b44
Commit
209f7b44
authored
Oct 22, 2016
by
Praetorius, Simon
Browse files
changed DEBUG to NOT NDEBUG and removed separate debug target from cmake
parent
a877b6da
Changes
28
Hide whitespace changes
Inline
Side-by-side
AMDiS/src/parallel/MeshManipulation.cc
View file @
209f7b44
...
...
@@ -98,7 +98,7 @@ namespace AMDiS { namespace Parallel {
elInfo
=
stack
.
traverseNext
(
elInfo
);
}
#if
(DEBUG != 0)
#if
ndef NDEBUG
DOFVector
<
WorldVector
<
double
>
>
coords
(
feSpace
,
"dofCorrds"
);
feSpace
->
getMesh
()
->
getDofIndexCoords
(
coords
);
#endif
...
...
@@ -173,7 +173,7 @@ namespace AMDiS { namespace Parallel {
el1
->
getAllDofs
(
feSpace
,
b1
,
dofs1
,
true
,
&
dofGeoIndex1
);
#if
(DEBUG != 0)
#if
ndef NDEBUG
if
(
feSpaces
.
size
())
debug
::
testDofsByCoords
(
coords
,
dofs0
,
dofs1
);
else
...
...
@@ -222,7 +222,7 @@ namespace AMDiS { namespace Parallel {
el0
->
getAllDofs
(
feSpace
,
b0
,
dofs0
,
true
,
&
dofGeoIndex0
);
el1
->
getAllDofs
(
feSpace
,
b1
,
dofs1
,
true
,
&
dofGeoIndex1
);
#if
(DEBUG != 0)
#if
ndef NDEBUG
if
(
feSpaces
.
size
())
debug
::
testDofsByCoords
(
coords
,
dofs0
,
dofs1
);
else
...
...
@@ -327,7 +327,7 @@ namespace AMDiS { namespace Parallel {
// Create traverse stack and traverse within the mesh until the element,
// which should be fitted to the mesh structure code, is reached.
TraverseStack
stack
;
#if
(DEBUG != 0)
#if
ndef NDEBUG
ElInfo
*
elInfo
=
stack
.
traverseFirstOneMacro
(
mesh
,
boundEl
.
elIndex
,
-
1
,
traverseFlag
);
...
...
AMDiS/src/parallel/PetscHelper.cc
View file @
209f7b44
...
...
@@ -177,7 +177,7 @@ namespace AMDiS
int
firstRow
=
firstRow0
+
firstRow1
;
int
mpiSize
=
MPI
::
COMM_WORLD
.
Get_size
();
#if
(DEBUG != 0)
#if
ndef NDEBUG
int
mpiRank
=
MPI
::
COMM_WORLD
.
Get_rank
();
#endif
vector
<
int
>
allFirstRow0
(
mpiSize
+
1
,
0
);
...
...
@@ -303,7 +303,7 @@ namespace AMDiS
PCFactorSetMatSolverPackage
(
pc
,
matSolverPackage
);
PCSetFromOptions
(
pc
);
#if
DEBUG != 0
#if
ndef NDEBUG
MSG
(
"PetscOptionsView:
\n
"
);
PetscViewer
viewer
;
PetscViewerCreate
(
PETSC_COMM_WORLD
,
&
viewer
);
...
...
AMDiS/src/parallel/PetscSolverFeti.cc
View file @
209f7b44
...
...
@@ -147,7 +147,7 @@ namespace AMDiS { namespace Parallel {
{
FUNCNAME
(
"PetscSolverFeti::initialize()"
);
#if
(DEBUG != 0)
#if
ndef NDEBUG
MSG
(
"Init FETI-DP on mesh level %d
\n
"
,
meshLevel
);
#endif
...
...
@@ -751,7 +751,7 @@ namespace AMDiS { namespace Parallel {
MatAssemblyEnd
(
mat_lagrange
,
MAT_FINAL_ASSEMBLY
);
#if
(DEBUG != 0)
#if
ndef NDEBUG
{
int
nZeroRows
=
PetscSolverFetiDebug
::
testZeroRows
(
mat_lagrange
);
int
m
,
n
;
...
...
@@ -1833,7 +1833,7 @@ namespace AMDiS { namespace Parallel {
Vec
nullSpaceBasis
;
VecCreateNest
(
domainComm
,
2
,
PETSC_NULL
,
vecArray
,
&
nullSpaceBasis
);
#if
(DEBUG != 0)
#if
ndef NDEBUG
PetscSolverFetiDebug
::
writeNullSpace
(
*
this
,
nullSpaceBasis
);
#endif
...
...
@@ -1870,7 +1870,7 @@ namespace AMDiS { namespace Parallel {
return
;
}
#if
(DEBUG != 0)
#if
ndef NDEBUG
PetscInt
nRow
,
nCol
;
MatGetLocalSize
(
subdomain
->
getMatInterior
(),
&
nRow
,
&
nCol
);
mpi
::
globalAdd
(
nRow
);
...
...
AMDiS/src/parallel/PetscSolverGlobalBlockMatrix.cc
View file @
209f7b44
...
...
@@ -44,7 +44,7 @@ namespace AMDiS { namespace Parallel {
int
nRankRows
=
(
*
interiorMap
)[
feSpace
].
nRankDofs
;
int
nOverallRows
=
(
*
interiorMap
)[
feSpace
].
nOverallDofs
;
#if
(DEBUG != 0)
#if
ndef NDEBUG
MSG
(
"Fill petsc matrix 1 needed %.5f seconds
\n
"
,
MPI
::
Wtime
()
-
wtime
);
#endif
...
...
@@ -97,7 +97,7 @@ namespace AMDiS { namespace Parallel {
MatCreateNest
(
domainComm
,
nBlocks
,
PETSC_NULL
,
nBlocks
,
PETSC_NULL
,
&
(
nestMat
[
0
]),
&
getMatInterior
());
#if
(DEBUG != 0)
#if
ndef NDEBUG
MSG
(
"Fill petsc matrix 2 needed %.5f seconds
\n
"
,
MPI
::
Wtime
()
-
wtime
);
#endif
...
...
AMDiS/src/parallel/PetscSolverGlobalMatrix.cc
View file @
209f7b44
...
...
@@ -87,7 +87,7 @@ namespace AMDiS { namespace Parallel {
}
Parameters
::
get
(
"parallel->print matrix info"
,
printMatInfo
);
#if
DEBUG != 0
#if
ndef NDEBUG
bool
printOptionsInfo
=
false
;
Parameters
::
get
(
"parallel->debug->print options info"
,
printOptionsInfo
);
if
(
printOptionsInfo
)
{
...
...
@@ -110,7 +110,7 @@ namespace AMDiS { namespace Parallel {
TEST_EXIT_DBG
(
interiorMap
)(
"No parallel mapping object defined!
\n
"
);
TEST_EXIT_DBG
(
seqMat
)(
"No DOF matrix defined!
\n
"
);
#if
(DEBUG != 0)
#if
ndef NDEBUG
Timer
t
;
#endif
...
...
@@ -123,7 +123,7 @@ namespace AMDiS { namespace Parallel {
// === Create PETSc vector (solution and a temporary vector). ===
#if
(DEBUG != 0)
#if
ndef NDEBUG
MSG
(
"Fill petsc matrix 1 needed %.5f seconds
\n
"
,
t
.
elapsed
());
t
.
reset
();
#endif
...
...
@@ -136,7 +136,7 @@ namespace AMDiS { namespace Parallel {
if
((
*
seqMat
)[
i
][
j
])
setDofMatrix
((
*
seqMat
)[
i
][
j
],
i
,
j
);
#if
(DEBUG != 0)
#if
ndef NDEBUG
MSG
(
"Fill petsc matrix 2 needed %.5f seconds
\n
"
,
t
.
elapsed
());
t
.
reset
();
#endif
...
...
@@ -162,7 +162,7 @@ namespace AMDiS { namespace Parallel {
initPreconditioner
(
*
seqMat
,
mat
[
0
][
0
]);
#if
(DEBUG != 0)
#if
ndef NDEBUG
MSG
(
"Fill petsc matrix 3 needed %.5f seconds
\n
"
,
t
.
elapsed
());
#endif
...
...
AMDiS/src/parallel/StdMpi.h
View file @
209f7b44
...
...
@@ -532,7 +532,7 @@ namespace AMDiS { namespace Parallel {
MPI
::
Request
::
Waitall
(
requestCounter
,
request
);
#if
(DEBUG != 0)
#if
ndef NDEBUG
bool
testall
=
MPI
::
Request
::
Testall
(
requestCounter
,
request
);
TEST_EXIT
(
testall
)(
"Should not happen!
\n
"
);
#endif
...
...
AMDiS/src/parallel/ZoltanPartitioner.cc
View file @
209f7b44
...
...
@@ -140,7 +140,7 @@ namespace AMDiS { namespace Parallel {
zoltan
.
Set_Param
(
"OBJ_WEIGHT_DIM"
,
"1"
);
#if
(DEBUG != 0)
#if
ndef NDEBUG
zoltan
.
Set_Param
(
"DEBUG_LEVEL"
,
"1"
);
#else
zoltan
.
Set_Param
(
"DEBUG_LEVEL"
,
"0"
);
...
...
AMDiS/src/solver/LinearSolverInterface.h
View file @
209f7b44
...
...
@@ -127,7 +127,7 @@ namespace AMDiS {
MSG
(
"Residual norm: ||b-Ax|| = %e
\n
"
,
residual
);
}
#if
DEBUG != 0
#if
ndef NDEBUG
if
(
getIterations
()
>
0
)
{
MSG
(
"Nr. of iterations needed = %d
\n
"
,
getIterations
());
}
...
...
Prev
1
2
Next
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment