So let's just assume that this works properly

You know what? I tested this code a millions of times now and there was no flaw after another little flaw in the ressource manager. It was almost in the same place as the segfault reason and I haven't yet encountered the freeze problem again. I did a more difficult test scenario: 100 threads parallely accessing three different ressources with a three-step phase for each ressource and also some recursive ressource acquisition calls as well as ones that should be could by the functions. And you know what? It worked. It worked so damn fine that synchronizing and resuming 100 of threads that often in a sequence only costs a few milliseconds executing the program. I'm quite surprised - haven't seen such a good performance coming. However, I noticed that sometimes the release functions will be called one time too often, maybe more. And I do definitely need to check this out. But I'm glad that the rest seems to work. I'll just assume it does, if not. I mean I tinkered with all time. Stuff has to go on.

No comments: