{"id":9952,"date":"2006-03-06T18:00:23","date_gmt":"2006-03-06T15:00:23","guid":{"rendered":"https:\/\/mamchenkov.net\/wordpress\/?p=9952"},"modified":"2006-03-09T09:40:48","modified_gmt":"2006-03-09T06:40:48","slug":"threaded-dreams","status":"publish","type":"post","link":"https:\/\/mamchenkov.net\/wordpress\/2006\/03\/06\/threaded-dreams\/","title":{"rendered":"Threaded dreams"},"content":{"rendered":"<!-- google_ad_section_start -->\n<p>There is an urban legend that drinking tequilla before going to sleep will guarantee you some really cool colorful dreams.  Unfortunately, that&#8217;s more than an urban legend.  I&#8217;ve tried it myself several times and it never worked out.<\/p>\n<p>But another thing that I&#8217;ve tried myself and that worked out just fine, but which I haven&#8217;t heard anyone talking about, is threaded dreams.<\/p>\n<p>What are threaded dreams?  Well, threaded dreams are those that you (or should I say &#8211; I) have after programming threads or forks too much.  I&#8217;ve always had a suspecion about the existance of threaded dreams, but I never had to program threads often enough to notice the trend.<\/p>\n<p>This month though confirmed my suspecions a few times in a row.  Two of these dreams were particularly interesting.<\/p>\n<p><!--more--><\/p>\n<p>First dream I had after programming straight for about 10 hours.  I was tired and my brain was steaming.  The last couple of hours were spent on solving the problem of slow forks and loosing control over fork counts (fork bombs).  When I wen to bed, I had a dream that I was inside my own computer program.  It wasn&#8217;t anything like The Matrix I should say.  It was more like a huge stone cave with very heigh ceilings.  I was walking around, studing it, but somehow I managed to upset the program and it got angry with me.  Huge stone chunks of code were falling from the top all over the place, trying to kill me.  Gladly I managed to make my way somehow towards a debugger.  A debugger was this strange virtual thingy which allowed me to pause the falling blocks of code and change the program in a such a way that they would either disappear or drop somewhere nearby, missing me safely.  It was  a tedious task, but I managed to survive.<\/p>\n<p>Another dream happenned few days later when I was working with native POSIX threads in Python.  I had more difficult problems than the first time around, but I spent less hours solving them.  When I went to bed, I had a dream that I am one of the threads inside my own program.  And, as any other thread, I had some job to do.  Somehow I managed to finish the job very fast, and the program was trying to kill me, as I was not needed anymore.  Needless to say, I wanted to stay alive.  I was trying to find something else to do.  I was cleaning memory with the broom, polishing the CPU with washclothes, running back and forward delivering all sorts of resources between other threads, and performing many other low-skill tasks that a respected thread shouldn&#8217;t be performing.  Gladly I woke up before the program managed to kill me.<\/p>\n<p>I still have a few more tasks, involving threads, to work on.  I&#8217;ll see if those will result in any weird dreams.  But so far, so good &#8211; threaded dreams is my own urban legend.<\/p>\n<!-- google_ad_section_end -->\n","protected":false},"excerpt":{"rendered":"<!-- google_ad_section_start -->\n<p>There is an urban legend that drinking tequilla before going to sleep will guarantee you some really cool colorful dreams. Unfortunately, that&#8217;s more than an urban legend. I&#8217;ve tried it myself several times and it never worked out. But another thing that I&#8217;ve tried myself and that worked out just fine, but which I haven&#8217;t &hellip; <a href=\"https:\/\/mamchenkov.net\/wordpress\/2006\/03\/06\/threaded-dreams\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Threaded dreams<\/span><\/a><\/p>\n<!-- google_ad_section_end -->\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":false,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"_links_to":"","_links_to_target":""},"categories":[1,18],"tags":[482,17],"keyring_services":[],"class_list":["post-9952","post","type-post","status-publish","format-standard","hentry","category-general","category-programming","tag-dreams","tag-work"],"aioseo_notices":[],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack-related-posts":[{"id":24469,"url":"https:\/\/mamchenkov.net\/wordpress\/2015\/07\/13\/duck-dreams\/","url_meta":{"origin":9952,"position":0},"title":"Duck dreams","author":"Leonid Mamchenkov","date":"July 13, 2015","format":"image","excerpt":"Duck dreams","rel":"","context":"In &quot;Instagram&quot;","block_context":{"text":"Instagram","link":"https:\/\/mamchenkov.net\/wordpress\/category\/photography\/instagram\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/mamchenkov.net\/wordpress\/wp-content\/uploads\/2015\/07\/10725169_607764765993799_1354230783_n.jpg?fit=640%2C640&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/mamchenkov.net\/wordpress\/wp-content\/uploads\/2015\/07\/10725169_607764765993799_1354230783_n.jpg?fit=640%2C640&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/mamchenkov.net\/wordpress\/wp-content\/uploads\/2015\/07\/10725169_607764765993799_1354230783_n.jpg?fit=640%2C640&ssl=1&resize=525%2C300 1.5x"},"classes":[]},{"id":10381,"url":"https:\/\/mamchenkov.net\/wordpress\/2006\/08\/19\/follow-your-dreams-now\/","url_meta":{"origin":9952,"position":1},"title":"Follow Your Dreams NOW","author":"Leonid Mamchenkov","date":"August 19, 2006","format":false,"excerpt":"Here's a nice piece of motivation - Follow Your Dreams NOW: The Time Will NEVER Be Just Right. There are plenty like this, but this one is good. The best time to follow your dreams is NOW You\u00e2\u20ac\u2122ll never have enough money in the bank. Your business plan will never\u2026","rel":"","context":"In &quot;All&quot;","block_context":{"text":"All","link":"https:\/\/mamchenkov.net\/wordpress\/category\/general\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":7944,"url":"https:\/\/mamchenkov.net\/wordpress\/2004\/09\/23\/infrared-dreams\/","url_meta":{"origin":9952,"position":2},"title":"Infrared Dreams","author":"Leonid Mamchenkov","date":"September 23, 2004","format":false,"excerpt":"Yet another excellent photography site at InfraredDreams.com. As the domain suggests, images are done in the infrared light scope. Most of the infrared photographs that I have seen were dedicated to subjects like landscapes, forests, marines, etc. This site, on the other hand, presents people from the point of view\u2026","rel":"","context":"In &quot;All&quot;","block_context":{"text":"All","link":"https:\/\/mamchenkov.net\/wordpress\/category\/general\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":11181,"url":"https:\/\/mamchenkov.net\/wordpress\/2008\/04\/28\/googley-design-principles\/","url_meta":{"origin":9952,"position":3},"title":"Googley Design Principles","author":"Leonid Mamchenkov","date":"April 28, 2008","format":false,"excerpt":"Very much in line with the image explaining simplicity of user interfaces, comes the list of Googley Design Principles: 1. Focus on people\u2014their lives, their work, their dreams. 2. Every millisecond counts. 3. Simplicity is powerful. 4. Engage beginners and attract experts. 5. Dare to innovate. 6. Design for the\u2026","rel":"","context":"In &quot;All&quot;","block_context":{"text":"All","link":"https:\/\/mamchenkov.net\/wordpress\/category\/general\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":10705,"url":"https:\/\/mamchenkov.net\/wordpress\/2007\/05\/27\/daily-tweets\/","url_meta":{"origin":9952,"position":4},"title":"Daily tweets","author":"Leonid Mamchenkov","date":"May 27, 2007","format":false,"excerpt":"I had a full 9 hour sleep. Wow. It's the first or the second time this year... # My Gmail space usage indicator stays firmly on 50%. 1433 MB out of 2857 MB. # I love Gmail's idea of growing space.If it was unlimited from the beginning, it wouldn't be\u2026","rel":"","context":"In &quot;All&quot;","block_context":{"text":"All","link":"https:\/\/mamchenkov.net\/wordpress\/category\/general\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":8781,"url":"https:\/\/mamchenkov.net\/wordpress\/2005\/04\/06\/dream\/","url_meta":{"origin":9952,"position":5},"title":"Dream","author":"Leonid Mamchenkov","date":"April 6, 2005","format":false,"excerpt":"Today I had the best sleep since Maxim was born. I slept for about 8 hours or even more. Olga was taking care of Maxim and I didn't even heard them. Ok, maybe once or twice, but that doesn't count really. Usually, I don't have dreams in those two or\u2026","rel":"","context":"In &quot;All&quot;","block_context":{"text":"All","link":"https:\/\/mamchenkov.net\/wordpress\/category\/general\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"jetpack_sharing_enabled":true,"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/posts\/9952","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/comments?post=9952"}],"version-history":[{"count":0,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/posts\/9952\/revisions"}],"wp:attachment":[{"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/media?parent=9952"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/categories?post=9952"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/tags?post=9952"},{"taxonomy":"keyring_services","embeddable":true,"href":"https:\/\/mamchenkov.net\/wordpress\/wp-json\/wp\/v2\/keyring_services?post=9952"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}