<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"><channel><title>NSBlog</title><link>http://www.mikeash.com/pyblog/</link><description>Mac OS X and Cocoa programming</description><lastBuildDate>Wed, 16 May 2012 14:05:50 GMT</lastBuildDate><generator>PyRSS2Gen-1.0.0</generator><docs>http://blogs.law.harvard.edu/tech/rss</docs><item><title>Solving Simulator Bootstrap Errors
</title><link>http://www.mikeash.com/pyblog/solving-simulator-bootstrap-errors.html</link><description>I'm sure every iOS developer has seen the dreaded bootstrap error. "Couldn't register com.yourcompany.yourapp with the bootstrap server. Error: unknown error code. This generally means that another instance of this process was already running or is hung in the debugger." After nearly throwing my Mac out the window for the Nth time today, I finally managed to come up with a simple fix. Run this in the shell: &lt;code&gt;launchctl list|grep UIKitApplication|awk '{print $3}'|xargs launchctl remove&lt;/code&gt;. And your bootstrap errors magically melt away.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/solving-simulator-bootstrap-errors.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/solving-simulator-bootstrap-errors.html</guid><pubDate>Mon, 07 May 2012 20:06:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2012-05-04: PLCrashReporter and Unwinding the Stack With DWARF, Part 2
</title><link>http://www.mikeash.com/pyblog/friday-qa-2012-05-04-plcrashreporter-and-unwinding-the-stack-with-dwarf-part-2.html</link><description>Here I am, yet again! This week, I'm continuing where my last article left off, regarding PLCrashReporter and unwinding stack frames on x86_64. In particular, I go into how I got at and used all the various data I &lt;a href="friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html"&gt;discussed in last week's article&lt;/a&gt;, and why some of the existing solutions in the wild weren't suited for our use.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2012-05-04-plcrashreporter-and-unwinding-the-stack-with-dwarf-part-2.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2012-05-04-plcrashreporter-and-unwinding-the-stack-with-dwarf-part-2.html</guid><pubDate>Fri, 04 May 2012 18:44:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2012-04-27: PLCrashReporter and Unwinding the Stack With DWARF
</title><link>http://www.mikeash.com/pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html</link><description>I'm back once again for Friday Q&amp;amp;A. Today I'm going to talk about some work I recently did on &lt;a href="http://plcrashreporter.googlecode.com/"&gt;PLCrashReporter&lt;/a&gt;, adding support for unwinding stack frames on x86_64. PLCrashReporter was originally targeted solely at iOS, where both ARM and x86-32 (the simulator) make crash reporting relatively straight-forward; we can simply walk the stack via the preserved frame pointer. On x86-64, matters are different, leading to the need to implement support for alternative methods for stack unwinding. This work was sponsored by &lt;a href="http://www.hockeyapp.net"&gt;HockeyApp&lt;/a&gt;, to support their &lt;a href="http://www.hockeyapp.net/blog/2012/4/27/mac-os-x-sandbox-support-is-coming.html"&gt;upcoming release&lt;/a&gt; of Mac OS X sandbox-compatible crash reporting. I'll talk about DWARF debugging information, the compact unwind encoding, and stack scanners. I assume at least some knowledge of x86_64 architecture, for simplicity's sake.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2012-04-27-plcrashreporter-and-unwinding-the-stack-with-dwarf.html</guid><pubDate>Fri, 27 Apr 2012 14:11:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2012-04-13: Nib Memory Management
</title><link>http://www.mikeash.com/pyblog/friday-qa-2012-04-13-nib-memory-management.html</link><description>I'm back from my hiatus and ready with a fresh journey into the netherworld of Apple's platforms. Today's subject comes from several readers who suggested that I discuss the subtleties of dealing with memory management and nibs, and particularly the differences between the Mac and iOS.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2012-04-13-nib-memory-management.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2012-04-13-nib-memory-management.html</guid><pubDate>Fri, 13 Apr 2012 14:14:00 GMT</pubDate></item><item><title>Introducing PLWeakCompatibility
</title><link>http://www.mikeash.com/pyblog/introducing-plweakcompatibility.html</link><description>As a way of atoning for the lack of a Friday Q&amp;amp;A today, I'm pleased to introduce &lt;a href="https://github.com/plausiblelabs/PLWeakCompatibility"&gt;PLWeakCompatibility&lt;/a&gt;. Do you like ARC? Do you need to support older OS releases? Do you wish you could use &lt;code&gt;__weak&lt;/code&gt; variables on those older OSes? If so, then I have good news for you! PLWeakCompatibility is the solution you've been looking for.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/introducing-plweakcompatibility.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/introducing-plweakcompatibility.html</guid><pubDate>Sat, 31 Mar 2012 03:09:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2012-03-16: Let's Build NSMutableDictionary
</title><link>http://www.mikeash.com/pyblog/friday-qa-2012-03-16-lets-build-nsmutabledictionary.html</link><description>&lt;a href="friday-qa-2012-03-09-lets-build-nsmutablearray.html"&gt;Last time on Friday Q&amp;amp;A&lt;/a&gt;, we discussed how to implement &lt;code&gt;NSMutableArray&lt;/code&gt;. Today, I'll repeat the same exercise with &lt;code&gt;NSMutableDictionary&lt;/code&gt; and build an implementation of it from scratch.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2012-03-16-lets-build-nsmutabledictionary.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2012-03-16-lets-build-nsmutabledictionary.html</guid><pubDate>Fri, 16 Mar 2012 14:55:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2012-03-09: Let's Build NSMutableArray
</title><link>http://www.mikeash.com/pyblog/friday-qa-2012-03-09-lets-build-nsmutablearray.html</link><description>Collection classes are ubiquitous in Cocoa apps, but also fairly opaque. Today, at the suggestion of Matthew Elton, I'm going to take a look at how &lt;code&gt;NSMutableArray&lt;/code&gt; works behind the scenes by building a replacement for it from scratch.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2012-03-09-lets-build-nsmutablearray.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2012-03-09-lets-build-nsmutablearray.html</guid><pubDate>Fri, 09 Mar 2012 13:44:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2012-03-02: Key-Value Observing Done Right: Take 2
</title><link>http://www.mikeash.com/pyblog/friday-qa-2012-03-02-key-value-observing-done-right-take-2.html</link><description>I'm back again for Friday Q&amp;amp;A, and this week I'm going to follow up on Mike's 2008 article, &lt;a href="key-value-observing-done-right.html"&gt;Key-Value Observing Done Right&lt;/a&gt;, where he debuted a replacement for KVO, &lt;code&gt;MAKVONotificationCenter&lt;/code&gt;. It's been a long time since then, and it was high time such a useful piece of code got an update, which I gave it. With the help of Mike and &lt;a href="http://about.me/tonyxiao"&gt;Tony Xiao&lt;/a&gt;, it's gotten a full overhaul and is now a modern code library with some fun features. In this article, I'm going to go through the new stuff and how it was done.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2012-03-02-key-value-observing-done-right-take-2.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2012-03-02-key-value-observing-done-right-take-2.html</guid><pubDate>Fri, 02 Mar 2012 14:09:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2012-02-17: Ring Buffers and Mirrored Memory: Part II
</title><link>http://www.mikeash.com/pyblog/friday-qa-2012-02-17-ring-buffers-and-mirrored-memory-part-ii.html</link><description>&lt;a href="friday-qa-2012-02-03-ring-buffers-and-mirrored-memory-part-i.html"&gt;Last time on Friday Q&amp;amp;A&lt;/a&gt;, I started talking about implementing a ring buffer using virtual memory tricks to mirror memory. The first article concentrated on those virtual memory tricks. Today, I'm going to fill out the second half of the puzzle and show how to implement the ring buffer on top of the mirrored memory allocator we developed. If you haven't read &lt;a href="friday-qa-2012-02-03-ring-buffers-and-mirrored-memory-part-i.html"&gt;the previous article&lt;/a&gt; yet, I strongly recommend you so so, otherwise the memory mirroring is likely to be confusing.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2012-02-17-ring-buffers-and-mirrored-memory-part-ii.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2012-02-17-ring-buffers-and-mirrored-memory-part-ii.html</guid><pubDate>Fri, 17 Feb 2012 12:50:00 GMT</pubDate></item><item><title>Deadlocks and Lock Ordering: a Vignette
</title><link>http://www.mikeash.com/pyblog/deadlocks-and-lock-ordering-a-vignette.html</link><description>Every once in a while, when writing threaded code, you may find yourself wanting to acquire two different locks in a critical section. Normally one should resist such perversions, but sometimes they just end up being necessary, or too tempting. Holding multiple locks at the same time immediately raises the specter of deadlock: if two threads acquire the same locks in a different order, they can end up waiting on each other forever.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/deadlocks-and-lock-ordering-a-vignette.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/deadlocks-and-lock-ordering-a-vignette.html</guid><pubDate>Mon, 13 Feb 2012 04:26:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2012-02-03: Ring Buffers and Mirrored Memory: Part I
</title><link>http://www.mikeash.com/pyblog/friday-qa-2012-02-03-ring-buffers-and-mirrored-memory-part-i.html</link><description>Playing with virtual memory is always fun, and one place where it can be put to good use is in building a ring buffer. A ring buffer is a way to implement a FIFO queue of data, and using virtual memory tricks to mirror multiple copies of the same data can make the implementation simpler and better by virtually concatenating noncontiguous data. Readers Jose Vazquez and Dylan Lukes suggested that I explore the building of such a construct. Today I will talk about how to implement the virtual memory tricks, and then in part II I will show how to implement the ring buffer on top of them.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2012-02-03-ring-buffers-and-mirrored-memory-part-i.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2012-02-03-ring-buffers-and-mirrored-memory-part-i.html</guid><pubDate>Fri, 03 Feb 2012 16:37:00 GMT</pubDate></item><item><title>The Mac Toolbox: Followup
</title><link>http://www.mikeash.com/pyblog/the-mac-toolbox-followup.html</link><description>Welcome back to Friday, NSBlog readers. Here's the promised followup to my article last week about the Mac Toolbox, where I do a line-by-line analysis of the code from the original article, alongside Mike's Friday Q&amp;amp;A for this week.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/the-mac-toolbox-followup.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/the-mac-toolbox-followup.html</guid><pubDate>Fri, 20 Jan 2012 16:14:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2012-01-20: Fork Safety
</title><link>http://www.mikeash.com/pyblog/friday-qa-2012-01-20-fork-safety.html</link><description>It's once again time to dive into bizarre programming arcana. In today's article, I want to look at the details of fork-safe code, why the restrictions are present, and why you might care, a topic suggested by Ben Mitchell.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2012-01-20-fork-safety.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2012-01-20-fork-safety.html</guid><pubDate>Fri, 20 Jan 2012 14:07:00 GMT</pubDate></item><item><title>Plausible Labs is Hiring
</title><link>http://www.mikeash.com/pyblog/plausible-labs-is-hiring.html</link><description>Plausible Labs, creators of fine software and employer of me, is looking for a software engineer in New York City or San Francisco. Do you like to create fine software? Do you want to join a worker-owned cooperative filled with great people? Do you want to work with a guy who writes a blog? If so, &lt;a href="http://www.plausible.coop/blog/?p=35"&gt;check out our announcement&lt;/a&gt;.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/plausible-labs-is-hiring.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/plausible-labs-is-hiring.html</guid><pubDate>Wed, 18 Jan 2012 15:38:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2012-01-13: The Mac Toolbox
</title><link>http://www.mikeash.com/pyblog/friday-qa-2012-01-13-the-mac-toolbox.html</link><description>Hi again, readers of NSBlog! This is my first guest post of 2012, and also my first one writing the introduction myself. I plan to do posts every two weeks, alternating with Mike's to bring back the once-a-week format. This week, at my own suggestion, I'm doing a historical piece on the original programming environment for Macs: The Mac Toolbox. Time for a trip down memory lane!&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2012-01-13-the-mac-toolbox.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2012-01-13-the-mac-toolbox.html</guid><pubDate>Fri, 13 Jan 2012 19:28:00 GMT</pubDate></item><item><title>Buy Videos of My VTM Presentations
</title><link>http://www.mikeash.com/pyblog/buy-videos-of-my-vtm-presentations.html</link><description>I gave two presentations at the Voices That Matter conference in Boston in November. Both presentations were recorded and the videos are now available for purchase. And as a special present for my readers, you can get 35% off!&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/buy-videos-of-my-vtm-presentations.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/buy-videos-of-my-vtm-presentations.html</guid><pubDate>Mon, 09 Jan 2012 16:52:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2012-01-06: The Hopper Disassembler
</title><link>http://www.mikeash.com/pyblog/friday-qa-2012-01-06-the-hopper-disassembler.html</link><description>We've spent the last few weeks talking about disassembling executables and how to read the result. Today, I want to wrap up that discussion with a look at a powerful third-party disassembly tool called Hopper.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2012-01-06-the-hopper-disassembler.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2012-01-06-the-hopper-disassembler.html</guid><pubDate>Fri, 06 Jan 2012 15:48:00 GMT</pubDate></item><item><title>Avoid Apress
</title><link>http://www.mikeash.com/pyblog/avoid-apress.html</link><description>Nearly three years ago, I got involved with Apress to contribute to two books. The experience went disastrously wrong. It was a profoundly unpleasant experience and I want to warn any other prospective authors to avoid this publisher, and encourage readers to buy from other publishers. &lt;i&gt;Warning: this post is non-technical and something of a rant. If that's not your thing, please skip it and come back in a week when technical goodies shall resume their normal course.&lt;/i&gt;&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/avoid-apress.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/avoid-apress.html</guid><pubDate>Sun, 01 Jan 2012 03:27:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2011-12-30: Disassembling the Assembly, Part 3: ARM edition
</title><link>http://www.mikeash.com/pyblog/friday-qa-2011-12-30-disassembling-the-assembly-part-3-arm-edition.html</link><description>Gwynne finishes off her series on analyzing assembly code with a look at ARM assembly, for all of your iOS needs. Gwynne will be contributing the occasional article in the future as well as a guest author, without my introductions. Watch the Author field at the top of the post to see who's writing what. Without further ado, let's take a look at ARM.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2011-12-30-disassembling-the-assembly-part-3-arm-edition.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2011-12-30-disassembling-the-assembly-part-3-arm-edition.html</guid><pubDate>Fri, 30 Dec 2011 21:44:00 GMT</pubDate></item><item><title>Friday Q&amp;amp;A 2011-12-23: Disassembling the Assembly, Part 2
</title><link>http://www.mikeash.com/pyblog/friday-qa-2011-12-23-disassembling-the-assembly-part-2.html</link><description>Today I have the pleasure to present the followup to last week's guest post. &lt;a href="http://blog.darkrainfall.org/"&gt;Gwynne Raskind&lt;/a&gt; returns to complete her in-depth analysis of the assembly code generated by a small sample program.&lt;br&gt;&lt;a href="http://www.mikeash.com/pyblog/friday-qa-2011-12-23-disassembling-the-assembly-part-2.html"&gt;(Read More)&lt;/a&gt;</description><guid isPermaLink="true">http://www.mikeash.com/?page=pyblog/friday-qa-2011-12-23-disassembling-the-assembly-part-2.html</guid><pubDate>Fri, 23 Dec 2011 20:48:00 GMT</pubDate></item></channel></rss>

