You know you’ve been spending way too much time programming when you suddenly see the people making sandwiches at the deli counter as a thread pool, and the single slicer as a synchronization object.
- View a Random Post
- Follow on Twitter
-
Contents
-
Meta
-
Categories
- Alison
- Apophthegmata
- Art
- Books
- Cape Cod
- Chess
- Curiosities
- Darwin and Biology
- Dualism vs. Materialism
- Foreign Affairs
- Free Will
- General
- Global Warming
- Haiku
- Immigration
- Inner Work
- Jihad
- Language
- Marginalia
- Martial Arts
- Military
- Mind and Brain
- Music and Recording
- Politics
- Pretty Good Posts
- Reason and Philosophy
- Religion
- Rubbish
- Science
- Shameless Filler
- Society and Culture
- Sport
- Technology
- The Economy
- Tomfoolery
- Uncategorized
-
Archives
- May 2012
- April 2012
- March 2012
- February 2012
- January 2012
- December 2011
- November 2011
- October 2011
- September 2011
- August 2011
- July 2011
- June 2011
- May 2011
- April 2011
- March 2011
- February 2011
- January 2011
- December 2010
- November 2010
- October 2010
- September 2010
- August 2010
- July 2010
- June 2010
- May 2010
- April 2010
- March 2010
- February 2010
- January 2010
- December 2009
- November 2009
- October 2009
- September 2009
- August 2009
- July 2009
- June 2009
- May 2009
- April 2009
- March 2009
- February 2009
- January 2009
- December 2008
- November 2008
- October 2008
- September 2008
- August 2008
- July 2008
- June 2008
- May 2008
- April 2008
- March 2008
- February 2008
- January 2008
- December 2007
- November 2007
- October 2007
- September 2007
- August 2007
- July 2007
- June 2007
- May 2007
- April 2007
- March 2007
- February 2007
- January 2007
- December 2006
- November 2006
- October 2006
- September 2006
- August 2006
- July 2006
- June 2006
- May 2006
- April 2006
- March 2006
- February 2006
- January 2006
- December 2005
- November 2005
- October 2005
- September 2005
- July 2005
- May 2005
- April 2005
8 Comments
It’s worse than bad; the slicer might be a resource protected by a synchronization object, but it is not one itself.
But we get the idea; sounds like you need a vacation. :-)
- M
Well, I thought about this before posting: the slicer is actually both synchronization object and resource, as only one person can acquire/use it at a time. But I didn’t want to overburden the readers…
You could even say the slicer is the synchronization object that must be acquired in order to use the resource, which is the spinning blade, which might in turn be thought of a parser that takes as its input a slab of meat that it renders as thin slices… aaarrrggghhh…
Just shoot me now.
I think that unless fist fights amongst potential owners are a frequent occurrence at the deli (maybe I should visit the deli in question), I contend there is something else at work performing the role of the synchronization object (like the demand for civility in the thread pool by the deli owner). I think confusing ownership with a convention used to acquire ownership might be the problem, which I think stands out as something distinct in instances of high contention. In the software world, I don’t think I would derive a slicer from mutex. Would you? I have missed the point of how to apply mutex in the OO world?
- M
Hey! You snuck in an additional paragraph while I was working on my follow up. You may need more than a vacation. :-) A vacation with liberal amounts of gin, for example.
- M
Yeah, uploading to the server is just the beginning of editing a post or a comment.
You make a fair point. The real synchronization object doesn’t exist in the deli at all; it is simply that the waiting threads observe the resource, and pause civilly while somebody’s got the slicer.
Gin, please.
See… I can do more than “Yikes!” :-) You just have to give me the right topics to get me motivated.
- M
In hindsight I probably should have started with ‘Yikes! It’s worse than bad!”
- M
It’s been a long time since I’ve done that much programming to have delusions like that. I do remember, though, after a particularly long bout of Photoshop, putting on my sunglasses and thinking of them as my own personal gamma correction device.