Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ MT-multithreading and servers » AsyncWork, IsFinished() may not be working properly
Re: AsyncWork, IsFinished() may not be working properly [message #54430 is a reply to message #54429] Sat, 18 July 2020 14:21 Go to previous messageGo to previous message
JeyCi is currently offline  JeyCi
Messages: 50
Registered: July 2020
Member
Oblivion , thank yoy very much - you have got together some pieces of information I know but still lack experience in its use - you have pointed the sides of its practical application...
1. I already used the idea about .Remove(i) - thanks to U++ examples. But thanks for your explanation, why I was getting zeros in mirek'code - I didn't noticed this easy reason
2. you are right - it was really NOT a race condition yet
3. now I see that really my code is blocking, & mirek's non-blocking, and your example is blocking as well...

... Yet I'm a beginner at parallel programming - I considered non-blocking algorithm to be better than blocking... but now I understood - they are simply for different purposes... and if I need to return value to the main thread - of course I need blocking as synchronization should be done - I think so now...
I'm just having the hope - if there is a way to return from mirek's non-blocking example value e.g. with lock-free mechanism of atomic?... or in any case we will need synchronization (blocking) here to return value from each thread?..
P.S.
I think now - it was just a hope...
in any case thank you for increasing my practical understanding such fresh knowledge for me Smile
Best regards,

[Updated on: Sat, 18 July 2020 14:28]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Skylark session verification
Next Topic: How do I create a loop for a window to react to volatile changes to a global variable?
Goto Forum:
  


Current Time: Sun Apr 28 09:06:06 CEST 2024

Total time taken to generate the page: 0.04693 seconds