Am I the only programmer in the world that uses always wait conditions and never uses semaphores? @nothings @cmuratori
-
-
Replying to @sssmcgrath
@sssmcgrath@nothings@cmuratori I prefer semaphores over monitors.2 replies 0 retweets 0 likes -
Replying to @rygorous
@rygorous@sssmcgrath@nothings@cmuratori Everybody prefers semaphores and events. Monitors are more expensive and stupider!1 reply 0 retweets 0 likes -
Replying to @jwatte
@jwatte@rygorous@nothings@cmuratori I don't understand how a mutex lock and a signal could be more expensive... I don't know how...2 replies 0 retweets 0 likes -
Replying to @sssmcgrath
@jwatte@rygorous@nothings@cmuratori semaphores are implemented, but I wouldn't be surprised if they were wrappers around a cond & mutex2 replies 0 retweets 0 likes -
Replying to @sssmcgrath
@sssmcgrath@jwatte@rygorous@nothings I don't see why they would do that - wouldn't it just be a compare-exchange?1 reply 0 retweets 0 likes -
Replying to @cmuratori
@sssmcgrath@jwatte@rygorous@nothings I mean you _already have to have_ an integer value that you interlock-compare-exchange, right?8 replies 0 retweets 0 likes -
Replying to @cmuratori
@sssmcgrath@jwatte@rygorous@nothings So a semaphore just makes _actual use of the value_ rather than just seeing if it's not zero.1 reply 0 retweets 0 likes -
Replying to @cmuratori
@sssmcgrath@jwatte@rygorous@nothings Maybe that's a naive view, but it seems like getting more leverage out of your sync primitive to me.1 reply 0 retweets 0 likes
@sssmcgrath @jwatte @rygorous @nothings A mutex does the exact same stuff, but throws away the data and just bakes it to a bool.
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.