Nef_3: Proof of concept for no-hashmap approach.#6415
Closed
GilesBathgate wants to merge 4 commits intoCGAL:mainfrom
Closed
Nef_3: Proof of concept for no-hashmap approach.#6415GilesBathgate wants to merge 4 commits intoCGAL:mainfrom
GilesBathgate wants to merge 4 commits intoCGAL:mainfrom
Conversation
Contributor
Author
|
What I don't like about the PoC is it has to wrap the original info in a value type, and copying that value type is expensive. It also has to https://gist.github.com/GilesBathgate/8ac8e314df53ec844e385ebd56ff071d |
e88b896 to
6964486
Compare
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.
Summary of Changes
In Nef_3 hashmaps are used to associate information with objects at runtime, for example, to flag that a HalfEdge has been visited there might be a
Unique_hash_map<Halfedge_handle,bool> visited;. If the class HalfEdge had a member variable calledvisitedthis could be used instead to indicate whether the edge had been visited (although it would have to be reset afterwards) However this would mean adding lots of extraneous data to the classes depending on the method or algorithm that is processing the list of objects.There is a generalised
infocontainer on all the classes which could be used. However, a mechanism is needed to make sure that the existing info isn't overwritten, and is restored to whatever it was before the processing was done.Release Management