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
id_type local reference counting is wrong #1032
Comments
I just want to note that the reason why this->get_gid() returns an uncounted GID is |
Why should a component hold a reference count to itself? Having unmanaged GIDs around makes it hard to reason about the correctness of a HPX program. IMHO, all id_types should be managed. Make unmanaged GIDS the rare exception. Just as a side note, the id_type returned from this->get_gid() in a component is never stored anywhere by default in the components. |
What Bryce meant is that every component stores its own gid internally. This gid shouldn't be managed as otherwise the component would keep itself alive. Meanwhile, I think I have a solution to this which I will commit shortly. |
Please see my comment regarding this commit. I think this is the wrong way to |
What alternative do you propose to fix #1032? |
How does this involve network overhead? The AGAS server is on the locality. No overhead here. |
Ah, okay, the point about the AGAS server being on the locality is valid |
Reopening because it was only fixed for simple components. |
Looks like it is (mostly) fixed. The only error the testcase is still reporting is that components don't get destroyed. |
The testcase fails to build with GCC4.4, it should be disabled for that compiler. |
Well, managed components have not been fixed yet which might be the reason for the leak you're reporting. |
https://github.com/STEllAR-GROUP/hpx/blob/master/tests/regressions/id_type_ref_counting.cpp
triggers a failure in the current local refcounting scheme of id types. That is that it is possible to have different "families" of id types which have different reference counts. If one of those reference counts goes to zero and the GID was never split, the component is released to early.
During analysis of this test this happens in at least one place. Namely, the id_type returned from hpx::new_ has a distinct reference count to the id_type returned from this->get_gid() in a component.
The text was updated successfully, but these errors were encountered: