Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
gmsh
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Romin Tomasetti
gmsh
Commits
bee3cb13
Commit
bee3cb13
authored
May 24, 2022
by
Christophe Geuzaine
Browse files
Options
Downloads
Patches
Plain Diff
skip remaining operations if exception is raised during a #pragma omp for
parent
be0a5da9
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/geo/GModelIO_MSH4.cpp
+1
-0
1 addition, 0 deletions
src/geo/GModelIO_MSH4.cpp
src/mesh/Generator.cpp
+2
-0
2 additions, 0 deletions
src/mesh/Generator.cpp
src/mesh/meshGRegionHxt.cpp
+1
-0
1 addition, 0 deletions
src/mesh/meshGRegionHxt.cpp
with
4 additions
and
0 deletions
src/geo/GModelIO_MSH4.cpp
+
1
−
0
View file @
bee3cb13
...
@@ -2851,6 +2851,7 @@ int GModel::_writePartitionedMSH4(const std::string &baseName, double version,
...
@@ -2851,6 +2851,7 @@ int GModel::_writePartitionedMSH4(const std::string &baseName, double version,
bool
exceptions
=
false
;
bool
exceptions
=
false
;
#pragma omp parallel for num_threads(nthreads)
#pragma omp parallel for num_threads(nthreads)
for
(
std
::
size_t
part
=
1
;
part
<=
getNumPartitions
();
part
++
)
{
for
(
std
::
size_t
part
=
1
;
part
<=
getNumPartitions
();
part
++
)
{
if
(
exceptions
)
continue
;
std
::
ostringstream
sstream
;
std
::
ostringstream
sstream
;
sstream
<<
baseName
<<
"_"
<<
part
<<
".msh"
;
sstream
<<
baseName
<<
"_"
<<
part
<<
".msh"
;
if
(
getNumPartitions
()
>
100
)
{
if
(
getNumPartitions
()
>
100
)
{
...
...
This diff is collapsed.
Click to expand it.
src/mesh/Generator.cpp
+
2
−
0
View file @
bee3cb13
...
@@ -383,6 +383,7 @@ static void Mesh1D(GModel *m)
...
@@ -383,6 +383,7 @@ static void Mesh1D(GModel *m)
bool
exceptions
=
false
;
bool
exceptions
=
false
;
#pragma omp parallel for schedule(dynamic) num_threads(nthreads)
#pragma omp parallel for schedule(dynamic) num_threads(nthreads)
for
(
size_t
K
=
0
;
K
<
temp
.
size
();
K
++
)
{
for
(
size_t
K
=
0
;
K
<
temp
.
size
();
K
++
)
{
if
(
exceptions
)
continue
;
int
localPending
=
0
;
int
localPending
=
0
;
GEdge
*
ed
=
temp
[
K
];
GEdge
*
ed
=
temp
[
K
];
if
(
ed
->
meshStatistics
.
status
==
GEdge
::
PENDING
)
{
if
(
ed
->
meshStatistics
.
status
==
GEdge
::
PENDING
)
{
...
@@ -538,6 +539,7 @@ static void Mesh2D(GModel *m)
...
@@ -538,6 +539,7 @@ static void Mesh2D(GModel *m)
temp
.
insert
(
temp
.
begin
(),
f
.
begin
(),
f
.
end
());
temp
.
insert
(
temp
.
begin
(),
f
.
begin
(),
f
.
end
());
#pragma omp parallel for schedule(dynamic) num_threads(nthreads)
#pragma omp parallel for schedule(dynamic) num_threads(nthreads)
for
(
size_t
K
=
0
;
K
<
temp
.
size
();
K
++
)
{
for
(
size_t
K
=
0
;
K
<
temp
.
size
();
K
++
)
{
if
(
exceptions
)
continue
;
int
localPending
=
0
;
int
localPending
=
0
;
if
(
temp
[
K
]
->
meshStatistics
.
status
==
GFace
::
PENDING
)
{
if
(
temp
[
K
]
->
meshStatistics
.
status
==
GFace
::
PENDING
)
{
backgroundMesh
::
current
()
->
unset
();
backgroundMesh
::
current
()
->
unset
();
...
...
This diff is collapsed.
Click to expand it.
src/mesh/meshGRegionHxt.cpp
+
1
−
0
View file @
bee3cb13
...
@@ -59,6 +59,7 @@ static HXTStatus nodalSizesCallBack(double *pts, uint32_t *volume,
...
@@ -59,6 +59,7 @@ static HXTStatus nodalSizesCallBack(double *pts, uint32_t *volume,
bool
exceptions
=
false
;
bool
exceptions
=
false
;
#pragma omp parallel for schedule(dynamic) num_threads(nthreads)
#pragma omp parallel for schedule(dynamic) num_threads(nthreads)
for
(
size_t
i
=
0
;
i
<
numPts
;
i
++
)
{
for
(
size_t
i
=
0
;
i
<
numPts
;
i
++
)
{
if
(
exceptions
)
continue
;
if
(
volume
[
i
]
<
0
||
volume
[
i
]
>=
allGR
->
size
())
{
if
(
volume
[
i
]
<
0
||
volume
[
i
]
>=
allGR
->
size
())
{
Msg
::
Error
(
"Invalid volume tag %d in mesh size calculation"
,
volume
[
i
]);
Msg
::
Error
(
"Invalid volume tag %d in mesh size calculation"
,
volume
[
i
]);
continue
;
continue
;
...
...
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