Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More contains_vertex_of optimization #2957

Merged
merged 2 commits into from
Jul 2, 2021

Conversation

roystgnr
Copy link
Member

@roystgnr roystgnr commented Jun 28, 2021

I came up with this in a conversation with @jbadger95 a week ago, when he was asking about contains_edge_of. Sadly I haven't yet actually improved the case he cared about (and probably won't soon; yes I'm still on vacation), but the question of "how much would this improve our point neighbor ghosting" kept nagging at me.

Turns out the answer is: our LIBMESH_BENCHMARK with --enable-parmesh gets 5% faster, and 3D refinement-heavy cases (like the uniform refinement tests @fdkong pointed me to) can get over 50% faster; all this is on top of the previous optimization in #2942, so that's something like a 5x speedup overall for distributed 3D mesh refinement. I cannot fully express my embarrassment that we had performance that horrible in a common use case. (We actually still have bad performance here, since delete_remote_elements() is half the cost of the solve in my test case, but it's no longer a dozen times the cost, so yay?)

@roystgnr
Copy link
Member Author

Added a couple distributed CI sweeps; if those pass this should be good to merge.

@roystgnr
Copy link
Member Author

refinement_type=p fe_family=L2_HIERARCHIC failure - not sure if that's from this PR or from #2952.

@roystgnr
Copy link
Member Author

It's not from this PR. Same failure with master.

@fdkong
Copy link
Contributor

fdkong commented Jun 29, 2021

Thanks for working on this. For uniform refinement, we often do not need original coarse meshes. In other words, parents can be deleted after children's creations. I think this can reduce the cost of finding neighbors. We might consider that as a valuable option when a general solution is impossible.

We have to default this to false to avoid breaking users who are testing
intersections between elements of different meshes (or of different
overlapping manifolds on the same Mesh), but when *we* use this function
we can generally take advantage of the fact that both elements are
coming from the same Mesh with a conforming coarse mesh.
@roystgnr roystgnr merged commit 724422d into libMesh:master Jul 2, 2021
@roystgnr roystgnr deleted the contains_vertex_connected branch July 2, 2021 15:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants