Login  Register

when safe to set maxExternalSemaphores:? What value?

Posted by Chris Muller-4 on May 21, 2021; 3:46am
URL: https://forum.world.st/when-safe-to-set-maxExternalSemaphores-What-value-tp5129904.html

Hi, the comment in maxExternalSemaphores: says:
_____
"Setting this at any time other than start-up can potentially lose requests.
i.e. during the realloc new storage is allocated,
the old contents are copied and then pointers are switched.
Requests occurring during copying won't be seen if they occur to indices already copied.
The intended use is to set the table to some adequate maximum at start-up"
_____

I could use some help in translating this to my limited user-level comprehension.  Does "start-up" here refer to the #startUp: hook?

Could "requests won't be seen" result in an image crash, or simply a few lost InputEvents?  If a crash is possible, I might be nervous to risk messing with it at all even in #startUp: in case it happened to be too low in the list, for example, and my image became unstartable..

Any guidance on what these external semaphores are for (at a high level) and a good suggested value for a chatty TCP/IP server would be greatly appreciated.

Thanks,
  Chris