Pushing a persona multiple times
The following contrived example pushes a persona a second time on the same persona stack:
#include <upcxx/upcxx.hpp>
int main() {
upcxx::init();
{
upcxx::persona_scope s(upcxx::default_persona());
}
upcxx::finalize();
return 0;
}
This is permitted by the wording in the current spec, but fails at runtime in the current implementation, both seq and par backends:
UPC++ assertion failure on rank 0 [/home/pcp1/bonachea/UPC/inst-upcxx/upcxx.debug.gasnet1_seq.smp/include/upcxx/persona.hpp:188]: Persona already in some thread's stack.
The example above is obviously silly, but there may be more complex progress-thread codes that may want to do this (using non-default personas), without having to check if the persona in question is already pushed on the stack (especially since we don't provide a means to query the current stack contents).
We need to either fix the implementation to support this, or change the spec to prohibit it.
Comments (8)
-
Account Deleted -
reporter - changed milestone to 2018.03.31 release
-
reporter - changed milestone to 2017.12.31 release
-
reporter - changed milestone to 2018.03.31 release
This issue was discussed in the 1/10/18 meeting, and John agreed to investigate for the March release.
See related issue
#64 -
-
assigned issue to
-
assigned issue to
-
reporter - changed milestone to 2018.09.30 release
Mass roll-over of unresolved issues to the next milestone.
-
reporter This issue was triaged at the 2018-06-13 Pagoda meeting.
John noted he thinks the issue may be fixed and wants to re-evaluate.
-
- changed status to resolved
Confirmed fixed.
- Log in to comment
I think the implementation should support this.