Open
Conversation
Tentative version of lloyd_optimize on Mesh_2 This causes a random segfault
uses pthread for linking
maxGimeno
reviewed
May 5, 2021
Author
|
Hello all, best regards yann |
janetournois
reviewed
Sep 7, 2021
|
|
||
| // create and start thread | ||
| TYPE_THREAD th = std::async(&Mesh_global_optimizer_2::threaded_move, this, | ||
| t, std::ref(itBegin), std::ref(itEnd), |
Member
There was a problem hiding this comment.
this line should be replaced by t, itBegin, itEnd
Author
There was a problem hiding this comment.
Do you mean this will solve the problem ?
Member
There was a problem hiding this comment.
It should solve the problem, yes!
Member
There was a problem hiding this comment.
However, the crash I was meeting was not the one you mention in the title message.
Member
|
Also, I think |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR is for debugging purposes.
Summary of Changes
I am trying to modify the function lloyd_optimize_mesh_2 in order to have a parallel computation of all movements.
When I simulate the threaded behavior (using a serie of different function calls), I have no problem and it seems to work. However, if I use actual threads, I get an error that occurs at Constrained_voronoi_diagram_2.h:360 (this line is polygon.push_back(m_cdt.circumcenter(face));)
This error is malloc(): unaligned tcache chunk detected