Welcome to the Monastery | |
PerlMonks |
Re^4: XS module in ithreads Perl much slower in threads::join after adding SvOBJECT_offby marioroy (Prior) |
on Feb 28, 2022 at 23:18 UTC ( [id://11141717]=note: print w/replies, xml ) | Need Help?? |
Hi, etj There is awesomeness with PDL 2.076 in better utilization of the L1/L2/L3 cache. That is something to be proud of and a moment of celebration. Unfortunately, 2.076 introduces an anomaly. IMHO try storing the $$.$tid somewhere. For PDL to be thread-safety friendly, it is important for cleanup to occur by the originating thread which instantiated the object. I will update the MCE demonstrations with a user_begin block to work around the issue. This I can do safely, because the piddles are instantiated by the main thread; i.e. $$.tid == $$.0 Update: Looking at the code, MCE workers also form piddles for the Strassen demonstrations. So I cannot do this unless I save/check the thread ID.
Not able to do the above, I want to mention that the strassen_07_t.pl example works fine as is in the repo by removing the line introduced in PDL 2.076.
In Section
Seekers of Perl Wisdom
|
|