I'm looking at some code (v15) that writes logs on the server. It's a delay
loop with a short period - 15 ticks. Within that loop a semaphore gets set,
the code runs and then the semaphore gets cleared.

I seem to recall hearing talk about not using semaphores in cases like this
- inside really tight loops. The line of thought was that the overhead for
setting/clearing the semaphore was large enough to be noticed. Especially
in this case where the db runs uncompiled.

This is an obvious case for moving to a worker process once we get off v15
but for the moment this method is causing me problems.

Any thoughts?
Thanks

-- 
Kirk Brooks
San Francisco, CA
=======================

*We go vote - they go home*
**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**********************************************************************

Reply via email to