<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-17691667</id><updated>2011-12-14T19:01:37.337-08:00</updated><title type='text'>Gimme Hardware/Software Interface.</title><subtitle type='html'>Computers, often from a low-level systems perspective. Note that I speak for myself, not my employer.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>63</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-17691667.post-3493566549289682902</id><published>2009-07-14T10:13:00.001-07:00</published><updated>2009-07-14T10:29:37.106-07:00</updated><title type='text'>Ch-ch-changes.</title><content type='html'>As some of you know, I'm no longer at &lt;a href="http://www.vmware.com"&gt;VMware&lt;/a&gt;. It feels a bit like leaving home. VMware took a chance on me as a new college grad way back in 2000, and taught me a lot along the way. I will miss my colleagues, many of whom are excellent, and will always be proud of what we accomplished together. I expect VMware will continue to be successful both technically and as a business, and they treated me very well. I did not leave due to a long list of complaints; it simply had been nine years, and I had decided it was time to try something different.&lt;br /&gt;&lt;br /&gt;I've been waiting to update this blog until I had a clear idea of what that "something different" was. My long fast in the woods is over: I'm working in the search team at &lt;a href="http://www.facebook.com"&gt;facebook&lt;/a&gt;, trying to make a whole lot of data available to a whole lot of users. You might think that the title of this blog is less relevant than it once was; search sounds, initially, like an application, pretty high up the abstraction stack from the hardware. This is true, but search is also a special application, enormously demanding in computational resources. We're pushing the hardware close to its limits in several dimensions simultaneously, and some knotty systems issues arise. I'm not ready to talk about them in any depth yet, not  out of secrecy, but ignorance. I'm still learning the ropes here, and any attempt to drop science at this point would just be silly.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-3493566549289682902?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/3493566549289682902/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=3493566549289682902' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/3493566549289682902'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/3493566549289682902'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2009/07/ch-ch-changes.html' title='Ch-ch-changes.'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-1038816735911281666</id><published>2009-02-13T09:16:00.000-08:00</published><updated>2009-02-13T09:21:26.216-08:00</updated><title type='text'>Irfan's blogging.</title><content type='html'>My colleague over in VMkernel Irfan Ahmad has &lt;a href="http://virtualscoop.org/"&gt;a blog&lt;/a&gt;. Irfan often has good ideas, and is a clear and effective writer; if you find the content here interesting, you might enjoy him. I've added a link to this blog's marginalia.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-1038816735911281666?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/1038816735911281666/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=1038816735911281666' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/1038816735911281666'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/1038816735911281666'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2009/02/irfans-blogging.html' title='Irfan&apos;s blogging.'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-4445790218354302927</id><published>2009-02-10T13:57:00.000-08:00</published><updated>2009-02-10T13:59:42.185-08:00</updated><title type='text'>VProbes community forum</title><content type='html'>VMware is now hosting a &lt;a href="http://communities.vmware.com/community/developer/vprobes"&gt;community forum for VProbes&lt;/a&gt;. Come party with us.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-4445790218354302927?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/4445790218354302927/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=4445790218354302927' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/4445790218354302927'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/4445790218354302927'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2009/02/vprobes-community-forum.html' title='VProbes community forum'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-3888005347097237298</id><published>2008-11-04T15:32:00.000-08:00</published><updated>2008-11-04T17:08:47.462-08:00</updated><title type='text'>Cantrill and Bonwick get all concurrent-y up in there...</title><content type='html'>&lt;a href="http://blogs.sun.com/bmc"&gt;Bryan Cantrill&lt;/a&gt; and &lt;a href="http://blogs.sun.com/bonwick"&gt;Jeff Bonwick&lt;/a&gt; of Sun Microsystems co-authored an excellent &lt;a href="http://doi2.acm.org/1454456.1454462"&gt;position piece on concurrency&lt;/a&gt; in the ACM Queue. It's about time someone stood up to those short-selling concurrency bears. Take heart, young coders! Correct concurrent software does appear out there from time to time, no matter what your grad TA tells you!&lt;br /&gt;&lt;br /&gt;The section on hard-won lessons from developing concurrent software warmed my heart; VMware's virtual machine monitor team has learned the same lessons, and I for one can endorse their list wholeheartedly.&lt;br /&gt;&lt;br /&gt;With any legit publication like this, the authors struggle to balance completeness and concision, and some things did not make the cut. So, don't take it as criticism that I would add just one item to their list, that has powerfully increased our ability to ship concurrent code (drumroll): &lt;b&gt;lock ranks&lt;/b&gt;. Huh? Lock ranks! We have imposed an explicit, compiled-in partial order on the locks in our system. Acquiring locks out of order causes a runtime failure in debug builds. I've seen some engineers regard this discipline as a sort of "training wheels" for concurrency, but it has benefits even for seasoned vets.&lt;br /&gt;&lt;ol&gt;&lt;br /&gt;&lt;li&gt;Ranks force developers to think about layering &lt;i&gt;before&lt;/i&gt; writing synchronization code. Will this subsystem be touching guest memory? Will it require synchronous remote execution on other CPUs? Will the user-level portion of our software ever need to acquire this lock? Etc.&lt;br /&gt;&lt;li&gt;This has strangled many a rare deadlock in the crib. I agree with Bryan and Jeff that, in practice, a deadlock is not too hard to debug post-mortem; however, post-mortem is too late if the core comes from a customer site. A rank violation is much, &lt;i&gt;much&lt;/i&gt; easier to catch in testing than a deadlock, since it only depends on the single-threaded path leading an order violation, as opposed to a concurrent race. This performs the magic trick of reducing a concurrent QA problem (exercise every lock interleaving) to a serial QA problem (cover every path that acquires a lock).&lt;br /&gt;&lt;li&gt;The same discipline can be applied to other synchronous services in the system. For instance, like many other concurrent systems, our VMM has a "crosscall" primitive, which lets a caller synchronously run code in a remote VCPU. This can lead to lock-like dependency cycles, where, e.g., VCPU 0 holds lock A and crosscalls VCPU 1 which is blocked waiting for A. To prevent this, we encorce the rank metaphor for crosscalls, too; a crosscall while holding dangerous locks fails just as a misorder lock acquisition would.&lt;br /&gt;&lt;/ol&gt;&lt;br /&gt;&lt;br /&gt;While the rank discipline was initially adopted for deadlock avoidance, the structure it imposes on the system is even more valuable. The lock ranks, in isolation, provide a succinct description of the system's organization. If you take the partial order of the lock ranks, associate them with their controlling subsystems, you can construct a "wedding cake" chart of the system automatically. I.e., if subsystem A relies on subsystem B, then locks protecting A's data will always have lower rank than B's. The top of the cake are "pure" clients, which are never entered from other subsystems; the tippy-top layer of frosting are the handful of points that we enter the VMM from the guest, where we always know that no VMM locks are held. The bottom of the cake, corresponding to the highest ranked, "leaf" locks, from which no other code is reachable, correspond to the most basic, omnipresent life-support facilities: logging, deferring work to a less pressing time, panic'ing, etc.&lt;br /&gt;&lt;br /&gt;Bryan advertised the article in an excellent (though more in-character) &lt;a href="http://blogs.sun.com/bmc/entry/concurrency_s_shysters"&gt;blog post&lt;/a&gt;. Out here in the wild wild web, Bryan lets the invective against transactional memory advocates ("shysters", in his estimation) flow a bit more freely. I am not sure the hype surrounding TM is malicious; I suspect it is your garden-variety, low-grade academic over-enthusiasm, born partly from needing to exaggerate in grant proposals and paper abstracts, and partly from honest optimism. Think "microkernels," not "&lt;a href="http://www.quackwatch.org/01QuackeryRelatedTopics/Cancer/laetrile.html"&gt;laetril&lt;/a&gt;."&lt;br /&gt;&lt;br /&gt;Hey, remember microkernels? For about a decade, systems journals were dominated by papers that &lt;i&gt;took for granted&lt;/i&gt; that microkernels would dominate general purpose OS'es. This religious belief that running parts of the operating system in separate address spaces would make everything easier and better begat all sorts of meaty sub-problems, like doing fast synchronous cross-address-space RPC, and building little IDL compilers that provide binary compatibility for clients when driver binaries change and ... so on. I suspect TM will take a similar course, dying not with a bang, but a whimper, and ten years hence.&lt;br /&gt;&lt;br /&gt;It's interesting to me that, as with microkernels, one of the principle reasons TM will fail is the messy, messy reality of peripheral devices. One of the claims made by microkernel proponents is that, since microkernel drivers are "just user-level processes", they'll survive driver failures. And this is almost true, for some definition of "survive." Suppose you're a microkernel, and you restart a failed user-level driver; the new driver instance has no way of knowing what state the borked-out driver left the actual, physical hardware in. Sometimes, a blind reset procedure can safely be carried out, but sometimes it can't. Also, the devices being driven are DMA masters, so they might very well have done something horrible to the kernel even though the buggy driver was "just a user-level app." And if there were I/Os in flight at failure time, have they happened, or not? Remember, they might not be idempotent... I'm not saying that some best-effort way of dealing with many of these problems is impossible, just that it's unclear that moving the driver into userspace has helped the situation at all.&lt;br /&gt;&lt;br /&gt;Similarly, peripherals are a gotcha for TM, because, as Bryan and Jeff point out, they're &lt;i&gt;not memory&lt;/i&gt;. There will never be a way to make TM transactions persist across system calls, unless you find a way to &lt;i&gt;un&lt;/i&gt;transmit network packets. That means that TM is now &lt;i&gt;and always will be&lt;/i&gt;* useful only for raw computation: AVL trees, mp3 encoding, sort, and whatnot. Those are important facilities, but they're also the sort of thing that are coded once, by an expert, and used forever thence from a library, so "ease of programming" is not the highest priority. Even if "ease of programming mp3 encoders" is your metric, it's unclear that TM is an across-the-board win. What happens when you set a debug watchpoint on memory that's accessed transactionally? Oh, sorry! Didn't mean to spoil the punchline from someone's PhD thesis...&lt;br /&gt;&lt;br /&gt;Not so simple anymore, eh?. If you can remember way back to your undergrad days, locks probably seemed easy at first, too.&lt;br /&gt;&lt;br /&gt;* I'm exhausted with that weasel phrase "current TM implementations"; transactions will never, &lt;i&gt;bloody ever&lt;/i&gt; span I/Os, and that's the relevant limitation.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-3888005347097237298?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/3888005347097237298/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=3888005347097237298' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/3888005347097237298'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/3888005347097237298'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2008/11/cantrill-and-bonwick-get-all-concurrent.html' title='Cantrill and Bonwick get all concurrent-y up in there...'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-1368987416246617601</id><published>2008-10-08T10:00:00.000-07:00</published><updated>2008-11-04T15:29:04.888-08:00</updated><title type='text'>Done projecting. Time to reflect?</title><content type='html'>Well, I've been back from U of I for over a month, so it's more than about time I got to writing it up. Interacting with people who are just as passionate about computing, but looking at it from completely different perspectives, is a soothing tonic for a systems person. It reminds me that these systems we build don't just blink in datacenters anonymously; when they function right, they do real, useful things that &lt;i&gt;matter&lt;/i&gt; deeply to others.&lt;br /&gt;&lt;br /&gt;I think my talk went fine, as things go. If I'd had one thing to do over, I would probably not have pounced so furiously on Crispin Cowan's Q&amp;A flamebait about how everybody knows VMs are slow; Crispin, that's one for you, there.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-1368987416246617601?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/1368987416246617601/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=1368987416246617601' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/1368987416246617601'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/1368987416246617601'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2008/10/done-projecting-time-to-reflect.html' title='Done projecting. Time to reflect?'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-4723298583327586877</id><published>2008-10-03T07:56:00.000-07:00</published><updated>2008-10-03T08:00:17.541-07:00</updated><title type='text'>Reflections|Projections 2008</title><content type='html'>I'm going to be at &lt;a href="http://www.acm.uiuc.edu/conference/2008/speakers"&gt;Reflections|Projections&lt;/a&gt; 2008 this weekend. I'll be talking about the role virtual machine monitors can play in systems research, using VProbes as both an example and exploratory tool. It's an honor to have my name on the same web page as some of my fellow speakers. Curious parties should swing on by UIUC's1404 Siebel at 4pm Saturday.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-4723298583327586877?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/4723298583327586877/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=4723298583327586877' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/4723298583327586877'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/4723298583327586877'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2008/10/reflectionsprojections-2008.html' title='Reflections|Projections 2008'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-6422477314233675202</id><published>2008-08-01T15:55:00.000-07:00</published><updated>2008-08-01T16:42:47.257-07:00</updated><title type='text'>Why I am not a C++ programmer: ten years on.</title><content type='html'>As a far-too-full-of-myself CS undergrad, I wrote, &lt;a href="http://web.archive.org/web/20010122104900/www.cs.brown.edu/~kma/cplusplus.html"&gt;"Many C++ critiques are available online, but none of them address what I regard as C++'s fundamental failure..."&lt;/a&gt; Man, it's painful linking the above. I wrote it ten years ago, as a &lt;a href="http://www.cs.brown.edu/courses/cs169/asgn.shtml"&gt;TA&lt;/a&gt; for a course that had previously been taught in C++. Despite trying &lt;i&gt;way&lt;/i&gt; too hard to project an unearned air of worldly cool, in most ways I stand by my claims. C++ is a broken notation: its attempts at being high level make it inappropriate for serious systems work, and its attempts at being low level make it even worse for applications. Incidentally, it has a truly unfortunate culture attached to it, rife with books, tutorials, even conferences which purport to be about "design," but are in fact about about "delegation," "factories," etc., and Cartesian products thereof. None for me, thanks.&lt;br /&gt;&lt;br /&gt;Why the stroll down memory lane? Because today a coworker introduced me to &lt;a href="http://yosefk.com"&gt;Yossi Kreinin's&lt;/a&gt; &lt;a href="http://yosefk.com/c++fqa/defective.html"&gt;C++ Frequently Questioned Answers&lt;/a&gt;. I can no longer claim that "none of [the C++ critiques online] address ... C++'s fundamental failure," as Yossi's kills them all.  Folks, we are in the presence of greatness. I feel as Salieri must have upon first encountering the works of Mozart.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-6422477314233675202?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/6422477314233675202/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=6422477314233675202' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/6422477314233675202'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/6422477314233675202'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2008/08/why-i-am-not-c-programmer-ten-years-on.html' title='Why I am not a C++ programmer: ten years on.'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-6246352723830907032</id><published>2008-07-24T12:45:00.000-07:00</published><updated>2008-07-24T13:46:51.047-07:00</updated><title type='text'>What is  VProbes' relationship to DTrace?</title><content type='html'>&lt;a href="http://x86vmm.blogspot.com/2008/06/vprobe-demo.html"&gt;VProbes&lt;/a&gt; has a similar set of design goals to &lt;a href="http://www.sun.com/bigadmin/content/dtrace/"&gt;DTrace&lt;/a&gt;: to be safe-yet-programmable, and be of global scope. DTrace is permissively licensed open source, that pre-dates the existence of VProbes, so why in heaven's name &lt;i&gt;don't&lt;/i&gt; they share code?&lt;br /&gt;&lt;br /&gt;The short version: virtual machine monitors aren't kernels, even though they run at CPL 0. Those curious about the hair, though, please read on...&lt;br /&gt;&lt;br /&gt;Before breaking ground on what would eventually become VProbes, I investigated a straight port of DTrace. I went so far as meeting with VMware legal to figure out whether the CDDL said what it appeared to say ("steal this code and make a fortune selling it for all we care, as long as you're not Linux"). However, there are some daunting impedance mismatches between DTrace as it exists today and the world in which our VMM must live. An incomplete list of gotchas includes:&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Our VMM needs to fit in 4MB of virtual address space, about 3 of which are needed for the translation cache. So, we care passionately about code and data size in ways that would be simply moronic for any other software project. Our internal mailing list regularly has knock-down, drag-out arguments about changes that bloat the monitor by 700 bytes; unless you're developing firmware, you should not even waste the time worrying about anything that impacts real-world memory usage by less than a MB or so.&lt;br /&gt;&lt;br /&gt;VProbes' current runtime impact is around 50KB, and we frankly consider it slightly overweight. Perhaps DTrace's data structures could be trimmed to fit in this environment, but text is more challenging. That's not to imply that DTrace should be tinier; DTrace is bigger &lt;i&gt;for all the right reasons&lt;/i&gt;, mostly that it does &lt;i&gt;more&lt;/i&gt; than VProbes does.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Our VMM does not provide any dynamic allocation facilities. This is one of the major reasons that efforts to port third-party software, even kernel software, to the VMM fails. Reading the BigAdmin discussion, DTrace appears to self-tune many of its buffers' capacities automagically, which is &lt;i&gt;great&lt;/i&gt;, and makes DTrace better for its users; however, it's just not feasible for our constrained environment.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;We care about applications where probes are &lt;i&gt;always enabled&lt;/i&gt;. VMware's VMM doesn't have any third-party extension mechanism, safe or otherwise, at present. VProbes provides a few toeholds for programmatic extension. This "extension" use of VProbes is different from the "monitoring" use that it shares with DTrace. It drives performance trade-offs that would simply be inappropriate for DTrace. E.g., rather than interpret bytecodes, VProbes compiles user probes to x86-64 machine code. Assuming you're on an x86 makes perfect sense for VMware, and would be completely insane for a system that also needs to work on sparc.&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;Of course, DTrace, being software, is infintely malleable, and you could probably start with a tarball extracted from the OpenSolaris project and eventually end up with something that satisfies all of the constraints our VMM imposes. But the result would be ... un-DTrace-like. Suppose you contort DTrace so that it doesn't care whether interrupts are enabled, sacrifices some speed, flexibility and features so that it fits in less than 100KB of virtual address space, and picks (tiny) static buffer sizes. How interested would the upstream DTrace developers, and ports of DTrace to other kernels, be in integrating my diffs? How hard would it be to integrate the stream of bug-fixes from DTrace-at-large into our heavily hacked code base? Would DTrace's owners even consider bugs that only arose in my insanely contorted set-up to be "bugs"? It seemed we'd be a dead-end fork of DTrace, neither able to help the parent project, nor selfishly benefit from its further development.&lt;br /&gt;&lt;br /&gt;Some have said that rolling our own runtime is an instance of not-invented-here syndrome; I take the charge seriously, and can see how it would seem that way from the outside. I strongly disagree. I realize that good work happens outside VMware, and consider DTrace shining example of such. I agonized over this decision, not least because I respect Bryan, Mike and Adam both as engineers and human beings. &lt;a href="http://slashdot.org/~kma/journal/"&gt;I am no Torvalds-esque DTrace hater&lt;/a&gt;. There are things that DTrace will continue to be hugely superior at. Then again, not having to wait for Microsoft to port DTrace to Windows is pretty neat too...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-6246352723830907032?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/6246352723830907032/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=6246352723830907032' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/6246352723830907032'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/6246352723830907032'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2008/07/what-is-vprobes-relationship-to-dtrace.html' title='What is  VProbes&apos; relationship to DTrace?'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-8532379130711380711</id><published>2008-06-13T15:27:00.000-07:00</published><updated>2008-06-13T15:33:50.213-07:00</updated><title type='text'>VProbe demo</title><content type='html'>&lt;a href="http://blip.tv/file/950760"&gt;Can you tell I'm not used to giving talks sitting down&lt;/a&gt;? Sorry about the continual side-to-side oscillation; I promise to insist on standing up in the future.&lt;br /&gt;&lt;br /&gt;If this VProbe stuff looks fun to you, perhaps it's time&lt;a href="http://www.vmware.com/communities/content/beta/ws65/registration.html"&gt;you got beta'ed up&lt;/a&gt;?&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-8532379130711380711?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/8532379130711380711/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=8532379130711380711' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/8532379130711380711'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/8532379130711380711'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2008/06/vprobe-demo.html' title='VProbe demo'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-6878663076479808</id><published>2008-06-13T10:04:00.000-07:00</published><updated>2008-06-13T11:30:30.378-07:00</updated><title type='text'>Windows Host Quoting Gotcha, and the VProbe Toolkit</title><content type='html'>Workstation 6.5 is now in &lt;a href="http://www.vmware.com/communities/content/beta/ws65/registration.html"&gt;public beta&lt;/a&gt;. It includes experimental support for VProbes in the guest, virtual machine monitor, and a few spots in the virtual hardware. We'd like to invite anybody curious about vprobes to give it a whirl.&lt;br /&gt;&lt;br /&gt;A common problem came up on the &lt;a href="http://communities.vmware.com/message/971080#971080"&gt;forums&lt;/a&gt; yesterday: if you're using VProbes from Windows' native command-line, you'll soon notice that the following:&lt;br /&gt;&lt;pre&gt;C:\&gt; vmrun vprobeLoad foo.vmx '(vprobe VMM1Hz (printf "greetings windows\n"))'&lt;/pre&gt;produces the cryptic error message:&lt;br /&gt;&lt;pre&gt;vprobeLoad: error: unknown ident windows\n&lt;br /&gt;vprobeLoad: 0 warnings, 1 errors&lt;/pre&gt;What gives? In short, cmd's weird quoting. As far as I can tell, single quotes are basically the same as double-quotes, except cmd will only nest like-with like, so cmd ends up passing along the string '(vprobe VMM1Hz (printf greetings windows\n))'. Check the forum post for the band-aid solution for cmd; I predict you'll only be able to tolerate the syntax for cmd one-liners so long before you give up and install cygwin.&lt;br /&gt;&lt;br /&gt;Once you embrace cygwin,  you might as well go whole-hog and &lt;a href="http://sourceforge.net/svn/?group_id=224179"&gt;get the vprobe-toolkit&lt;/a&gt;. The abstraction level of vp is very low; while the parentheses might remind you of scheme for a while, pretty soon the semantics will remind you of assembly language. This was an intentional choice: since bugs in the vp compiler can nuke your system, we're motivated to keep it as simple as possible. While it's possible to use vp directly for machine-level things (e.g., instruction or stack profilers), for more complex tasks automatic code generation is more appropriate.&lt;br /&gt;&lt;span style="font-size:130%;"&gt;&lt;br /&gt;Introducing Emmett&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Emmett is a small language that provides C-like type, expression, and conditional operators, some syntactic sugar for aggregation, and automatic inference of type for undeclared variables. The vprobe-toolkit provides a wrapper script, named "vprobe", that invokes the Emmett compiler on your input, loads the resulting VP into the target VM, and runs user-specified pretty-printers on your output. E.g., "vprobe -a" pretty-prints sorted aggregates, and "vprobe -s" pretty-prints stacks.&lt;br /&gt;&lt;br /&gt;Where in VP, you'd have to write:&lt;br /&gt;&lt;pre&gt;(defaggr a 1 1)&lt;br /&gt;(vprobe USEC:1001&lt;br /&gt; (do&lt;br /&gt;  (aggr a (VCPUID) ((curprocname)) 1)&lt;br /&gt;  (logaggr a )))&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Emmett produces the more readable:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;USEC:1001&lt;br /&gt;{&lt;br /&gt;  a[VCPUID, curprocname()]++;&lt;br /&gt;  logaggr(a);      # OK, this is a lot of output.&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;There are a bunch of examples in the cookbook subdirectory.&lt;br /&gt;&lt;br /&gt;I want to emphasize that Emmett is a replaceable component. If you're a python programmer, and curly braces make your shoulder blades clench with rage, feel free to write your own little language...&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:130%;"&gt;Pragmatics&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;vprobe-toolkit is open source. We've licensed it with a variant of the BSD license, which VMware's lawyers assure me means you can basically do whatever you want with it; if you're feeling paranoid, though, &lt;span style="font-style: italic;"&gt;please&lt;/span&gt; run the license file past your local lawfolk rather than taking my word for it. You'll notice the link above is to a subversion repository, not a download page. In its current state, it would be inappropriate to expose it to those unwilling to hack a bit; if ws 6.5 is currently in "beta", this is probably somewhere past "prototype" but not really "alpha" yet. Join us!&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-6878663076479808?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/6878663076479808/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=6878663076479808' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/6878663076479808'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/6878663076479808'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2008/06/windows-host-quoting-gotcha-and-vprobe.html' title='Windows Host Quoting Gotcha, and the VProbe Toolkit'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-3045703273994601451</id><published>2008-04-05T10:25:00.000-07:00</published><updated>2008-04-05T15:03:20.328-07:00</updated><title type='text'>Herlihy &amp; Shavit: The Art of Multiprocessor Programming</title><content type='html'>(Disclaimer: I've taken courses from Maurice Herlihy at Brown.)&lt;br /&gt;&lt;br /&gt;So! Concurrency's the hot thing. &lt;a href="http://blogs.intel.com/research/2007/06/multicore_processors_an_inflec.php"&gt;Intel&lt;/a&gt; says so. The technical bookshelves are groaning with books about concurrent programming. Most of these books are occult thread package tutorials; they walk you through using Java's monitors, or pthreads' conditions and mutexes, or Windows' Events or what have you, often with the same shopworn collection of toy problems: philosophers producing elves who dine on ... eh.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.amazon.com/Art-Multiprocessor-Programming-Maurice-Herlihy/dp/0123705916"&gt;The Art of Multiprocessor Programming&lt;/a&gt; is different. It is, in part, a theory book. Don't panic! The use of formal reasoning is tasteful; a teaspoon or so of actual math is necessary when designing concurrent programs, because our intuitions can fool us. However, the authors don't overwhelm the reader; an undergraduate level background in CS theory is not necessary to appreciate the book. If you can read the word "tuple" without giggling, you'll be fine.&lt;br /&gt;&lt;br /&gt;More importantly, though, the actual data structures and algorithms that are highlighted in this book are not the same-old. Sure, mutual exclusion is discussed, but it's with a focus on &lt;i&gt;implementing&lt;/i&gt; mutual exclusion, which is a topic &lt;a href="http://www1.uspto.gov/web/patents/patog/week40-old/OG/html/1311-1/US07117481-20061003.html"&gt;dear to me&lt;/a&gt;. Most strikingly, the majority of the examples in the book are of lock-free data structures. You'll find lock-free linked lists, hash tables, trees, etc.&lt;br /&gt;&lt;br /&gt;In my day job, I treat lock-free concurrent data structures as, well, not &lt;i&gt;quite&lt;/i&gt; black magic, but certainly Powerful Medicine. They take a lot of thought, bugs can hide in them for years, reasoning about their performance is non-trivial, even compared to locking, and frankly, not every programmer is up to maintaining such code; but when you need them, you need them. If the multi-core popular press is to be believed, more and more of us will be needing them in the near future.  In as much as this is the first off-the-shelf collection of useful, debugged lock-free data structures, it's an invaluable contribution. Go buy it. Even if you never use a counting network, it will make you a better programmer. It's also the most writerly book about programming you'll read all year; Herlihy's deadpan humor is a welcome break from the super-serious tone programming books usual adopt.&lt;br /&gt;&lt;br /&gt;However. ...&lt;br /&gt;&lt;br /&gt;Reading between the lines a bit, I see this book as part of a larger project, which I refer to as "pop concurrency*". "PC" is a loose confederation of researchers in programming languages, compilers, architecture and operating systems whose implicit goal is to make concurrent programming, well, "easy." Much, much easier, anyway. Of course, sequential programming isn't all that easy. Before the current fashion in concurrency, the "software engineering" community was haranguing us about the expense, difficulty, and intractability of programming. We've made only incremental progress in making sequential programming easier; garbage collectors and safe languages are probably the most important contributions so far, ad they are not order-of-magnitude revolutions over traditional tools.&lt;br /&gt;&lt;br /&gt;It's cheap and easy to make negative predictions about ambitious research agendas. E.g., making fun of &lt;a href="http://singinst.org/"&gt;strong AI people&lt;/a&gt; stopped being fun for me about 10 years ago. But at the risk of seeming to make a cheap shot, I am really, really skeptical about how easy we can make concurrent programming. Even if the thicket of hardware and software problems around &lt;a href="http://www.cs.wisc.edu/trans-memory/"&gt;transactional memory&lt;/a&gt;** resolve, I suspect TM only &lt;i&gt;seems&lt;/i&gt; easy because it's the devil we don't know. After all, locks sound easy too: just identify the shared data and wrap mutexes around it! Sounds simple enough, doesn't it? It took years, and lots of big systems being constructed this way before problems like priority inversion were framed, and many years thereafter before they were solved. Paraphrasing Fred Brooks, there's no silver bullet; concurrency is hard not because we're Western linear Cartesian dualist squares, or because of bad notation, but because it's &lt;i&gt;actually hard&lt;/i&gt;. Like all software, the easy parts are quickly discovered and factored, and the code that's left to be written represents real problems to solve.&lt;br /&gt;&lt;br /&gt;* Warning: I made this term up. Do not use it when trying to sound intelligent.&lt;br /&gt;** E.g.: how do you debug a TM program? When you're stepping through a transaction, won't it basically always fail? System calls during transactions? I/O? What if you've DMA'ed into or out of a piece of physical memory that's being transacted-upon? Smarter people than me are thinking about these problems, but man. They are non-trivial.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-3045703273994601451?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/3045703273994601451/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=3045703273994601451' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/3045703273994601451'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/3045703273994601451'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2008/04/herlihy-shavit-art-of-multiprocessor.html' title='Herlihy &amp; Shavit: The Art of Multiprocessor Programming'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-7681218571809465502</id><published>2008-03-15T04:47:00.000-07:00</published><updated>2008-03-15T06:06:24.661-07:00</updated><title type='text'>dtrace.conf(08)</title><content type='html'>DTrace's (first?) unconference in San Francisco yesterday was a blast. I attempted a &lt;a href="http://www.vmware.com/products/beta/ws/vprobes_reference.pdf"&gt;VProbes&lt;/a&gt; demo with Thursday morning's Fusion bits from our development branch, which I would rate a qualified success. The VMware Fusion UI crashed right after plugging into the projector, but the VProbe stuff worked. In case it was unclear to anybody in attendance, yes, there really was a Windows VM struggling on in the background; sorry you couldn't see its screen. I'm told video will be up shortly, so stay tuned. In the meantime, I let slip that we're attempting to ship VProbes in Workstation 6.5; all of you ESX users who asked me about VProbes on ESX, I have no official news for you, but yes, we feel your pain.&lt;br /&gt;&lt;br /&gt;I enjoyed meeting like-minded folks, putting faces to names, and getting a glimpse of the DTrace community's roadmap. Having slept on it a bit, both of &lt;a href="http://blogs.sun.com/bmc"&gt;Bryan's&lt;/a&gt; demos stand out. &lt;br /&gt;&lt;br /&gt;As Bryan admits, distributed DTrace as implemented thus far is nothing that you couldn't do with ssh and a lot of elbow grease. But I'm excited about the implications of this project. A wire format for generalized aggregation could provide a &lt;i&gt;lingua franca&lt;/i&gt; between DTrace and other sources of aggregation data (*cough* VProbes). You can actually imagine "aggregation" in this VProbes/DTrace sense overlapping with "aggregation" in the RSS sense: administrators "publish" streams of worthwhile data from individual systems, and trees of aggregators pool together broader and broader summaries of these aggregations by talking the same protocol upstream.&lt;br /&gt;&lt;br /&gt;Which brings me to dtrace.conf's well-planned climax, Bryan's  graphical DTrace demo.&lt;br /&gt;&lt;br /&gt;VProbes' textual UI feels like a throwback to me; when showing it to a skeptic, you can almost read the thought balloon floating over his head: "OK, you just typed something weird into an xterm, and it spit something out. It's 2008. I wonder why he expects me to care. Actually, I wonder what the stock market's doing. Oh, wait, this VProbe guy is still talking." But what can I do? I'm a programmer, it's a programming language; how else do I demonstrate its power and more importantly, its flexibility? But people (quite correctly) expect data to be presented visually, because our visual systems are the most reliable, highest bandwidth way of getting quantitative data our brains.&lt;br /&gt;&lt;br /&gt;Most graphical tools, though, have only one trick: plotting some scalar data against time. It's amazing how little we've really improved past xload in this regard. Bryan's demo was the first graphical tool I've seen that captures some of the &lt;i&gt;combinatorial&lt;/i&gt; and &lt;i&gt;iterative&lt;/i&gt;power of a dynamic instrumentation system: finding an anomaly, then breaking it down by &lt;i&gt;foo&lt;/i&gt;, then by &lt;i&gt;bar&lt;/i&gt;, backtracking a bit because &lt;i&gt;foo&lt;/i&gt; isn't as important as you initially thought, then keeping only the purple &lt;i&gt;bar&lt;/i&gt;s, etc. Sure, there will always have to be something like a programming language underneath for full generality, but a tool like this has the potential to capture much of the benefit with much less investment of intellectual energy. We professional programmers tend to, err, overestimate others' passions for learning new languages.&lt;br /&gt;&lt;br /&gt;It took courage and generosity of spirit on the part of my hosts to provide a platform for what &lt;i&gt;could be&lt;/i&gt; viewed as a competing technology at their conference. So, thanks guys. I would (and did) argue that VProbes and DTrace are complements. Users need visibility into the virtualization stack, and we're going to try to give them as much insight into that layer as possible with VProbes, but we're happy to cede higher levels to OS tools, including DTrace. Consider for example TCP. In the grand scheme of a real application, TCP is a very low layer, but from the virtual hardware's point of view, TCP is a modestly high-level protocol to reconstruct from what's sitting on the wire and in guest memory. DTrace will always provide superior visibility into what is really an OS level of abstraction. In my mind, the interesting question is how to weave together these different instrumentation engines for different levels in the stack. Hopefully we'll have something to show for our efforts at dtrace.conf(09).&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-7681218571809465502?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/7681218571809465502/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=7681218571809465502' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/7681218571809465502'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/7681218571809465502'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2008/03/dtraceconf08.html' title='dtrace.conf(08)'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-3377809086156147283</id><published>2008-01-23T09:00:00.000-08:00</published><updated>2008-01-23T09:15:24.463-08:00</updated><title type='text'>MacOS X/DTrace tryst ends in tears.</title><content type='html'>See &lt;a href="http://blogs.sun.com/ahl/entry/mac_os_x_and_the"&gt;Adam's break-up note&lt;/a&gt;. This also got picked up on slashdot.&lt;br /&gt;&lt;br /&gt;My thoughts, in no particular order:&lt;br /&gt;&lt;ol&gt;&lt;br /&gt;&lt;li&gt;Shame on Apple. What is the point of building system-wide infrastructure that any random process can opt out of? Forget about DRM; what about legitimate uses of DTrace for system health monitoring? Won't all malware be sure to set the "don't dtrace me" bit now?&lt;br /&gt;&lt;li&gt;This highlights the value of having system-wide instrumentation at the &lt;i&gt;hardware&lt;/i&gt; level. Systems like &lt;a href="http://x86vmm.blogspot.com/2007/09/presenting-vprobes.html"&gt;VProbes&lt;/a&gt; do not allow a process, or indeed even a kernel, to "opt out." If the VM's user wants something traced, he gets it traced, by golly.&lt;br /&gt;&lt;li&gt;On the other hand: if code &lt;i&gt;really&lt;/i&gt; wants to evade VProbes, DTrace, debuggers, etc., the arms race is heavily stacked in favor of the sneaky code. E.g., suppose you've got some super-s3kr3t, double-plus DRM code that you absolutely don't want instrumented with DTrace's pid provider; on x86's, you could easily checksum the text to find smashed-in &lt;a href="http://faydoc.tripod.com/cpu/int3.htm"&gt;int3&lt;/a&gt;'s. More elaborate evasion/detection schemes are possible too, similar in spirit to the VMM detection techniques summarized in &lt;a href="http://www.vmware.com/files/pdf/vmm-detection-hotos07.pdf"&gt;our HOTOS paper&lt;/a&gt; about VMM detectors from last year. We concluded that creating a &lt;i&gt;completely&lt;/i&gt; invisible VMM is an ill-posed problem, and trying too hard is a waste of time. I believe a similar dynamic is at work with dynamic tracing systems.&lt;br /&gt;&lt;/ol&gt;&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-3377809086156147283?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/3377809086156147283/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=3377809086156147283' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/3377809086156147283'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/3377809086156147283'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2008/01/macos-xdtrace-tryst-ends-in-tears.html' title='MacOS X/DTrace tryst ends in tears.'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-4183351200760683107</id><published>2007-10-25T15:02:00.000-07:00</published><updated>2007-10-25T15:16:58.401-07:00</updated><title type='text'>Ouch, Theo!</title><content type='html'>Slashdot, by way of kerneltrap, picked up a &lt;a href="http://kerneltrap.org/OpenBSD/Virtualization_Security"&gt;hilarious&lt;/a&gt; flamewar over on the OpenBSD mailing list. The short version is that some guy thinks virtualization involves code, and code has bugs, and therefore virtualization is only ever bad. Or something. I'll leave the histrionics to those who think there's a substantial argument lurking in there somewhere, but I just couldn't help myself when I saw the following appeal to authority:&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;While x86 hardware has the same page-protection hardware that an IBM 390 architecture machine has, modern PC machines are a mess.  They are architecturally so dirty, that parts of the video, keyboard, and other IO devices are interfaced with even to do simple things like context switching processes and handling interrupts.  Those of us who have experience with the gory bits of the x86 architecture can clearly say that we know what would be involved in virtualizing it, and if it was so simple, we would not still be fixing bugs in the exact same area in our operating system going on 12 years.&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;&lt;br /&gt;I'd like to call "BS" on the above claim of inscrutability. No, you do not dork around with, e.g., the video card, to switch contexts. You may indeed mess about with an I/O device in "handling interrupts," but only because, gee, there's an interrupt to handle. In my seven years of debugging every goofball OS written for the PC on our VMM, I haven't encountered a single task switch that wasn't basically some variation of disabling interrupts, taking a couple spin locks, switching stacks, and changing the page table pointer. You know, kind of like it is on every architecture on the planet.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-4183351200760683107?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/4183351200760683107/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=4183351200760683107' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/4183351200760683107'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/4183351200760683107'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2007/10/ouch-theo.html' title='Ouch, Theo!'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-8819054153046973500</id><published>2007-09-05T07:44:00.001-07:00</published><updated>2007-09-05T08:13:56.870-07:00</updated><title type='text'>Denier's Dilemma</title><content type='html'>Shankar Vendatam at the &lt;a href="http://www.washingtonpost.com/"&gt;&lt;span style="font-style: italic;"&gt;Washington Post&lt;/span&gt;&lt;/a&gt; writes:&lt;br /&gt;&lt;blockquote&gt;&lt;p&gt; The federal &lt;a href="http://www.washingtonpost.com/ac2/related/topic/Centers+for+Disease+Control+and+Prevention?tid=informline" target=""&gt;Centers for Disease Control and Prevention&lt;/a&gt; recently issued a flier to combat myths about the flu vaccine. It recited various commonly held views and labeled them either "true" or "false." Among those identified as false were statements such as "The side effects are worse than the flu" and "Only older people need flu vaccine."&lt;/p&gt; &lt;a href="http://www.washingtonpost.com/ac2/related/topic/University+of+Michigan?tid=informline" target=""&gt;When University of Michigan&lt;/a&gt; social psychologist Norbert Schwarz had volunteers read the CDC flier, however, he found that within 30 minutes, older people misremembered 28 percent of the false statements as true. Three days later, they remembered 40 percent of the myths as factual.&lt;br /&gt;&lt;br /&gt;...&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;(By way of the often excellent, and often nutty, &lt;a href="http://www.overcomingbias.com/"&gt;Overcoming Bias&lt;/a&gt;.) I'm reminded of the &lt;a href="http://x86vmm.blogspot.com/2007/08/hmm-thats-not-what-i-think-i-wrote.html"&gt;difficulty&lt;/a&gt; I've had explaining that VMs and security don't really have much to do with one another. Is it possible that, in attempting to explain something really convoluted to a crowd that barely cares, we sometimes do more harm than good? If you find yourself in a situation where you're in possession of a counter-intuitive result, that's really hard to explain, but important none the less, what's the ethical thing to do, given that saying "X" will register in a lot of folks' minds as "not X"?&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-8819054153046973500?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/8819054153046973500/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=8819054153046973500' title='6 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/8819054153046973500'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/8819054153046973500'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2007/09/deniers-dilemma.html' title='Denier&apos;s Dilemma'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>6</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-5378312576872656212</id><published>2007-09-01T11:35:00.000-07:00</published><updated>2007-09-02T09:17:19.567-07:00</updated><title type='text'>Presenting VProbes</title><content type='html'>VMworld 2007 is coming up, and I'm more excited than usual this time around. Alex Mirgorodskiy, Robert Benson and I will be demonstrating a piece of technology called VProbes.&lt;br /&gt;&lt;br /&gt;VProbes was born from an experience that many of you have probably shared: I was wondering why my computer was so slow. I have whiled away many hours over the years investigating this question, and I have rarely gotten a solid answer. Sometimes the slowness is intermittent, and by the time I've developed a theory, it has already disappeared.  Other times, the diagnostic tool I want to run (top, or strace, or ltrace, or what have you) isn't installed in the VM, because it's a purpose-built VM with a constrained set of user-land tools. Or, the tools are there, but the system is not in a state to allow me to use them; e.g., it's hung early in boot, and I can't log in to the system. Still other times, I never really scratch the surface of the problem because it's Windows and I don't know my way around.&lt;br /&gt;&lt;br /&gt;VProbes attempts to provide a set of tools for answering the question, "What the heck is this computer doing?" It's an open-ended question, so vprobes is accordingly open-ended, as well. In its current form, it provides an interactive, safe way of instrumenting a running VM at any level: from user-level processes down to the kernel, and even into VMware's VMM and hypervisor, if need be.&lt;br /&gt;&lt;br /&gt;We also attempt to solve the "unfamiliar tools" problem, by papering over (to the degree possible) the differences among operating systems. There is a broad consensus among Windows and the UNIX flavors about the abstractions that operating systems provide: all major operating systems provide threads, a tree of named processes, named files in a hierarchical namespace with byte contents, sockets, etc.  VProbes tries to get by on enough guest-specific knowledge to "wrap" those differences. Thus, for Windows, Linux, and any other operating system that VProbes can be "taught" to understand, the following vprobe script provides a rough and ready approximation of the top UNIX utility:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;   Guest_TimerIRQ&lt;/span&gt;&lt;span style="font-family:courier new;"&gt; ticks[curprocname()] &lt;- 1;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-family:courier new;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;"Big deal," you might be thinking. "I had top already." Well, you didn't have top on Windows. And you didn't have it while the machine was booting, or shutting down. And you certainly didn't have it if the machine in question was a virtual appliance that doesn't even allow logins.&lt;br /&gt;&lt;br /&gt;Anyway, if this sounds interesting to you, please consider attending our VMworld breakout session on the 13th, from 3:30 to 4:30, numbered&lt;span style="text-decoration: underline;"&gt;&lt;/span&gt; TA70. I should warn that this is basically a research prototype: we haven't committed to putting VProbes in any upcoming VMware product, and indeed, might never ship it at all. We're putting what we've got in front of the public now because we are at the point where we need feedback from real users to improve VProbes.&lt;br /&gt;&lt;br /&gt;In the "credit where it's due" department: we owe an enormous debt in our thinking about this problem to our &lt;a href="http://blogs.sun.com/bmc/"&gt;colleagues&lt;/a&gt; &lt;a href="http://blogs.sun.com/mws/"&gt;at&lt;/a&gt; &lt;a href="http://blogs.sun.com/ahl/"&gt;Sun&lt;/a&gt;. I've never hidden my admiration for &lt;a href="https://www.sun.com/bigadmin/content/dtrace/"&gt;DTrace&lt;/a&gt;. We hope to improve on it. First, we are aiming to provide a Dtrace-like tool for other commercially important operating systems than Solaris. Second, VProbes can combine with other virtualization-based techniques in powerful ways. For example, VProbes and &lt;a href="http://www.arctic.umn.edu/%7Ejjyi/MoBS/2007/program/01C-Xu.pdf"&gt;deterministic replay&lt;/a&gt; combine to make the most potent tool that I'm aware of for debugging intermittent performance anomalies. I'll leave applications to VMotion, snapshots, etc., as tantalizing hints...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-5378312576872656212?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/5378312576872656212/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=5378312576872656212' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/5378312576872656212'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/5378312576872656212'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2007/09/presenting-vprobes.html' title='Presenting VProbes'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-2723453386027678946</id><published>2007-08-01T09:14:00.000-07:00</published><updated>2007-08-01T09:37:08.860-07:00</updated><title type='text'>Hmm. That's not what I think I wrote...</title><content type='html'>I'm perplexed by this peculiar &lt;a href="http://www.techworld.com/security/news/index.cfm?newsID=9653&amp;pagtype=all"&gt;interpretation&lt;/a&gt; of our HotOS paper:&lt;br /&gt;&lt;blockquote&gt;&lt;br /&gt;Security has been touted as one of the benign by-products of virtualisation – but according to a recent study, that’s no longer the case.&lt;br /&gt;&lt;/blockquote&gt;&lt;br /&gt;Huh? "Security" is a big concept, covering many possible applications. Our paper is just a tiny footnote in a complicated discusssion about the role of VMMs in providing security; in fact, to the extent we challenge conventional wisdom at all, we suggest that the purported security &lt;a href="http://www.eweek.com/article2/0,1895,2152137,00.asp"&gt;threat&lt;/a&gt; posed by VMM-based rootkits is non-existent. To get out the sock puppets: VMMs are always detectable, which is a &lt;span style="font-style:italic;"&gt;good&lt;/span&gt; thing.&lt;br /&gt;&lt;br /&gt;I think I see where the author got a bit tripped up reading our paper, though. Currently, there is a trend for malware to disable itself in the presence of VMMs. We argue that this trend cannot continue, not because VMMs are becoming undetectable, but because VMMs are becoming too ubiquitous for malware authors to ignore. Note that this current fad among malware authors of refusing to do dirty business in a VM is &lt;i&gt;not&lt;/i&gt; an inherent security benefit of VMs!&lt;br /&gt;&lt;br /&gt;A nice thought experiment when thinking about security applications of virtual machines is to replace "VM" with "laptop." Suppose, for the sake of argument, security researchers started building honeynets out of laptops, because it was more economical to do so. For a while, malware authors might decide to detect that they're running on a laptop, and refuse to do so, in order to thwart the security researchers. (Note, of course, that it's completely trivial for user-level software to figure out what sort of hardware platform it's running on; this information is intentionally, usefully exposed by, e.g., /proc nodes in Linux, or the \Device directory on NT, etc.). The answer to this situation is not to attempt to cloak the laptop-iness of the hardware platform, though; attempting to do so is a bottomless pit of wasted effort. Instead, we simply observe that there are a lot of laptops out there, and figure that, in the long run, malware that refuses to run on laptops will be giving up too many targets to represent a &lt;a href="http://en.wikipedia.org/wiki/Nash_equilibrium"&gt;Nash equilibrium&lt;/a&gt; for the black hats.&lt;br /&gt;&lt;br /&gt;Honestly, though, I'm not that happy with the paper. We're telling a complicated story, and I'm not sure we tell it clearly enough. Even if Manek Dubash's misinterpretation were intentional*, the fact that it the paper can even be plausibly distorted to read the way he suggests means that, at some basic level, we've failed. Good technical writing is hard.&lt;br /&gt;&lt;br /&gt;* Purely speculating, here. I'm not casting aspersions on anyone's intentions; an honest misunderstanding is, sadly, possible.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-2723453386027678946?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/2723453386027678946/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=2723453386027678946' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/2723453386027678946'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/2723453386027678946'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2007/08/hmm-thats-not-what-i-think-i-wrote.html' title='Hmm. That&apos;s not what I &lt;i&gt;think&lt;/i&gt; I wrote...'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-834726242512622160</id><published>2007-07-12T08:15:00.000-07:00</published><updated>2007-07-12T08:53:17.927-07:00</updated><title type='text'>Overcoming bias</title><content type='html'>Not strictly virtualization-related, but &lt;a href="http://www.overcomingbias.com/"&gt;overcoming bias&lt;/a&gt; is one of the more consistently interesting cross-disciplinary blogs I've come across. The same sorts of cognitive biases that cause people to make bad decisions about their happiness, finances, political preferences, etc., often cause errors in software engineering. Pawing through &lt;a href="http://en.wikipedia.org/wiki/List_of_cognitive_biases"&gt;Wikipedia's list of cognitive biases&lt;/a&gt;, I can associate almost every single bias with one (or more) mistakes I've made in my professional life. &lt;a href="http://en.wikipedia.org/wiki/Optimism_bias"&gt;Optimism bias&lt;/a&gt;? Zounds, what engineer isn't guilty of it on a daily bias? &lt;a href="http://en.wikipedia.org/wiki/Information_bias"&gt;Information bias&lt;/a&gt; has often led me to waste hours in debugging collecting useless trivia. Some have even entered the lore of computing; &lt;a href="http://en.wikipedia.org/wiki/Ingroup_bias"&gt;ingroup bias&lt;/a&gt; is nothing but "NIH syndrome."&lt;br /&gt;&lt;br /&gt;While "overcoming bias" is certainly a laudable goal in many professional fields, I wonder about its tractability. These biases are clearly hardwired, and I suspect no amount of mindfulness will prevent us from committing them. Getting rid of one of these well-attested biases would probably require the neurological equivalent of, e.g., making humans able to digest grass, or giving a human the &lt;a href="http://www.tufts.edu/vet/sports/oxygen.html"&gt;VO2Max&lt;/a&gt; of a horse. Oh well; if nothing else, at least being aware of our limitations as thinking machines might prevent us from trying anything too impossibly stupid...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-834726242512622160?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/834726242512622160/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=834726242512622160' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/834726242512622160'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/834726242512622160'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2007/07/overcoming-bias.html' title='Overcoming bias'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-6985537920508944522</id><published>2007-07-02T11:09:00.000-07:00</published><updated>2007-07-02T12:19:22.977-07:00</updated><title type='text'>BluePill detection in two easy steps.</title><content type='html'>In &lt;a href="http://www.usenix.org/events/hotos07/tech/full_papers/garfinkel/garfinkel.pdf"&gt;our HotOS submission&lt;/a&gt;, we alluded to a large number of theoretically possible methods of detecting the presence of a hypervisor. I'm not sure which of these many ways the well-publicised &lt;a href="http://rdist.root.org/2007/06/28/undetectable-hypervisor-rootkit-challenge/"&gt; BluePill challengers&lt;/a&gt; have chosen, but I thought I'd make things a bit more concrete.&lt;br /&gt;&lt;br /&gt;In our paper, we outline family of detection methods based on resource consumption. In short, the hypervisor must use cache, memory bandwidth, TLB entries, etc., in the course of multiplexing the CPU. A guest can be made intentionally sensitive to these resources in order to detect a hypervisor. For instance, you can obtain a good estimate of the effective size of the hardware TLB with psuedo-code like the following:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;PPN oldPhysPage, newPhysPage = Alloc...();&lt;br /&gt;VA oldVirtAddr = MapSomewhere(oldPhysPage);&lt;br /&gt;VA newVirtAddr = MapSomewhere(newPhysPage);&lt;br /&gt;memset(oldVirtAddr, 0x11, PAGE_SIZE);&lt;br /&gt;memset(newVirtAddr, 0x22, PAGE_SIZE);&lt;br /&gt;PTE=base of hardware page table;&lt;br /&gt;for (i = 0; i &lt; BIGNUM; i++) {&lt;br /&gt;   PTE[i] = MAKE_PTE(oldPhysPage);  // map old page&lt;br /&gt;   (void)*(volatile char*)(i * PAGE_SIZE); // bring it into the TLB&lt;br /&gt;}&lt;br /&gt;/*&lt;br /&gt;* TLB now contains between 0 and BIGNUM old mappings.&lt;br /&gt;* Now modify the PTEs *without* flushing the TLB,&lt;br /&gt;* and wait for the hardware to leak an entry&lt;br /&gt;*/&lt;br /&gt;for (i = 0; i &lt; BIGNUM; i++) {&lt;br /&gt;   PTE[i] = MAKE_PTE(newPhysPage);  // map old page&lt;br /&gt;   if ((*(volatile char*)(i * PAGE_SIZE)) == 0x22) {&lt;br /&gt;      printf("apparent tlb size: %d\n", i);&lt;br /&gt;      break;&lt;br /&gt;   }&lt;br /&gt;}&lt;/pre&gt;&lt;br /&gt;OK, so you can size the TLB. So what? Well, just run the above loop twice, but the second time, stick an instruction that's guaranteed to trap out to the hypervisor (e.g., &lt;span face="courier new"&gt;CPUID&lt;/span&gt;) before the loop. On bare hardware, this inocuous instruction will have no impact on the TLBs. In the presence of a hypervisor, the instruction will either flush the TLB entirely (on current Intel VT implementations), or, if you're on a clever SVM hypervisor that uses the ASID facility to avoid TLB flushes on every hypervisor invocation, at least 1 fewer TLB entry. (&lt;span style="font-size:85%;"&gt;Every hypervisor must at least read the VMCB's exit code, requiring 1 data TLB entry. For increased sensitivity, you could also detect the VMM's code footprint by rejiggering the above to measure ITLB entries, an exercise left to the reader. Hint: the return instruction is a single byte on x86&lt;/span&gt;.)&lt;br /&gt;&lt;br /&gt;This detection technique uses only TLB capacity, but a more sophisticated approach could easily include the hardware eviction policy. We could also apply these same technique to instruction and data caches. (&lt;span style="font-size:85%;"&gt;Even the x86's coherent data caches can be sized using the &lt;span style="font-family:courier new;"&gt;INVD&lt;/span&gt; instruction, which discards cache contents without writing back dirty data.&lt;/span&gt;) A less naive approach that uses the hardware's event-based performance monitoring support (RDPMC and friends) would have an even richer menu of options for noticing virtualization-induced perturbations.&lt;br /&gt;&lt;br /&gt;I've seen zero evidence that Rutkowska has pondered resource-based detection attempts like this, or indeed, any attacks more sophisticated than a "go-slow" loop between reads of the PIT. It is hard for me to imagine a "hypervisor" worthy of the name that doesn't leave noticable traces in resource usage. In fact, to the degree that a hypervisor goes to heroic lengths to prevent such a detection technique, e.g., by running a hardware-accurate cache simulator on every guest memory access, it will only open up wider timing discrepancies for the guest's HV-detector to exploit.&lt;br /&gt;&lt;br /&gt;I can only conclude that in 2006 Rutkowska was either naive about the possibilities of such attacks, or that she consciously chose to make an  outrageous and indefensible claim ("undetectable malware!!!!111") in order to draw attention to herself and her company. Given the peripheral evidence of Rutkowska's competence, I think the evidence favors the latter, but I'd simply love to hear from her on the subject...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-6985537920508944522?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/6985537920508944522/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=6985537920508944522' title='12 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/6985537920508944522'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/6985537920508944522'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2007/07/bluepill-detection-in-two-easy-steps.html' title='BluePill detection in two easy steps.'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>12</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-5969306497323344499</id><published>2007-06-29T06:00:00.000-07:00</published><updated>2007-06-29T06:08:51.108-07:00</updated><title type='text'>BluePill hype going the way of all flesh</title><content type='html'>I'm &lt;a href="http://rdist.root.org/2007/06/28/undetectable-hypervisor-rootkit-challenge/"&gt; not alone&lt;/a&gt; in &lt;a href="http://www.usenix.org/events/hotos07/tech/full_papers/garfinkel/garfinkel.pdf"&gt;my skepticism&lt;/a&gt; about BluePill's claims of undetectability. Let's pop some popcorn, folks! This could get good...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-5969306497323344499?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/5969306497323344499/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=5969306497323344499' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/5969306497323344499'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/5969306497323344499'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2007/06/bluepill-hype-going-way-of-all-flesh.html' title='BluePill hype going the way of all flesh'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-9063111044414593842</id><published>2007-02-27T16:39:00.000-08:00</published><updated>2007-03-23T09:25:18.383-07:00</updated><title type='text'>Please indulge me...</title><content type='html'>I've tried to be fairly disciplined about keeping this blog technical. Never the less, I would ask for your indulgence to announce the birth of Emmett Joseph Adams on February 27th, 2007 at 11:48am.&lt;br /&gt;&lt;br /&gt;The little dude is three amazing weeks old now. Everybody is as healthy and happy as can be expected. A few observations from very, &lt;span style="font-style: italic;"&gt;very &lt;/span&gt;early parenthood:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;I'm amazed in the photo below how bloody &lt;span style="font-style: italic;"&gt;peppy&lt;/span&gt; I look. And that was after being awake all night! I've already come to regard bloodshot eyes, 5 o'clock shadow, and coffee stains on clothes I've slept in as the norm. When I ask other parents when I can expect that to change, they invariably say something smarmy, like, "oh, in about eighteen years."&lt;br /&gt;&lt;/li&gt;&lt;li&gt;When I play guitar and sing for him, he kind of zones out for a while and then starts bouncing his legs and arms in time while making these little happy grunts.&lt;/li&gt;&lt;li&gt;Emmett's mother, Jean, is the most amazing person in the world.&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_tYRrPJ_bslg/ReTPzjoWTZI/AAAAAAAAAAM/FwDuMa7dQPg/s1600-h/Emmett+064.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://3.bp.blogspot.com/_tYRrPJ_bslg/ReTPzjoWTZI/AAAAAAAAAAM/FwDuMa7dQPg/s320/Emmett+064.jpg" alt="" id="BLOGGER_PHOTO_ID_5036378767951809938" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_tYRrPJ_bslg/ReTPzzoWTaI/AAAAAAAAAAU/jEDTcTDU98k/s1600-h/Emmett+047.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://4.bp.blogspot.com/_tYRrPJ_bslg/ReTPzzoWTaI/AAAAAAAAAAU/jEDTcTDU98k/s320/Emmett+047.jpg" alt="" id="BLOGGER_PHOTO_ID_5036378772246777250" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;OK, back to our regularly scheduled computer stuff!&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-9063111044414593842?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/9063111044414593842/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=9063111044414593842' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/9063111044414593842'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/9063111044414593842'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2007/02/please-indulge-me.html' title='Please indulge me...'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_tYRrPJ_bslg/ReTPzjoWTZI/AAAAAAAAAAM/FwDuMa7dQPg/s72-c/Emmett+064.jpg' height='72' width='72'/><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-117216714748557486</id><published>2007-02-22T09:16:00.000-08:00</published><updated>2007-02-22T09:59:07.503-08:00</updated><title type='text'>Microsoft swallows the BluePill</title><content type='html'>Why doesn't Microsoft want users to run Vista in a VM? Why, because t&lt;a href="http://biz.yahoo.com/ap/070222/microsoft_virtual_vista.html?.v=2"&gt;he presence of a VMM could mean someone has l33tly r00t3d your b0x0r&lt;/a&gt;! So nice of Microsoft to protect us shivering, ignorant, childlike customers from choosing how we'd like to run Windows. Ahh, the bliss of having all my decisions made for me. Thank you. I wonder if I should be just as worried about the inherent insecurity of running on a hypervisor once Longhorn ships? Oops, I almost forgot: best not to think of these things! Better to let Microsoft do the worrying for me.&lt;br /&gt;&lt;br /&gt;Now that the BluePill pseudo-sploit has been widely publicized for over a year now, I'm still aware of no actual attacks. This, despite the fact that SVM and VT hardware are now extremely common, and getting more so by the day. Why would that be?&lt;br /&gt;&lt;br /&gt;Well, first of all, SVM and VT make possible nothing that was not already possible before; VMware's software-only products are an existence proof. The BluePill-istas don't claim that SVM/VT make new exploits possible &lt;span style="font-style:italic;"&gt;per se&lt;/span&gt;; rather, the claim is that SVM/VT make it possible to &lt;span style="font-style:italic;"&gt;cloak&lt;/span&gt; the presence of a VMM rootkit completely.&lt;br /&gt;&lt;br /&gt;Allow me to go on record: this claim is pure fantasy. In practice, it is &lt;span style="font-style:italic;"&gt;always&lt;/span&gt; possible to detect the presence of a VMM, via timing attacks. "Aha!", my hand-wringing BluePill interlocutor exclaims: "But the VMM lets us hook RDTSC and the PIT and the APIC timer, etc., so we can show the VM whatever time we want! Or whatever!" The details of getting such an approach right in practice are tough beyond belief. Once you start thinking it through, you quickly realize the deck is stacked in favor of the would-be VMM detector. As a practical example, VMware's software goes to extremely clever lengths in coordinating and manipulating the various virtual time sources &lt;a href="http://lkml.org/lkml/2006/11/16/259"&gt;just to get certain versions of the linux kernel to boot&lt;/a&gt;. It took some smart people &lt;span style="font-style:italic;"&gt;years&lt;/span&gt; to really drive a stake through the heart of the "pester mingo" boot-time failure in SMP VMs. This was the result of a real, naturally occurring guest code that had nothing to do with VM detection; you can imagine that a dedicated attack on the VMM's virtual time sources could be many orders of magnitude more effective.&lt;br /&gt;&lt;br /&gt;So, I'm claiming you can always find out that there's a VMM underneath you. Should that worry us, too?  Since some members of the security community are using VMs to study malware, the arms race between malware creators and investigators has temporarily taken a turn wherein some malware refuses to run in a VM. This has led some to think of the &lt;span style="font-style:italic;"&gt;detectability&lt;/span&gt; of a VMM as a deficiency in the virtualization layer.&lt;br /&gt;&lt;br /&gt;I don't see it that way. As VMs become more commonplace, malware that refuses to run in VMs will be naturally selected out. We don't expect, e.g., a Dell laptop to cloak the version of Windows it's running, or which chipset or video card is present, or for that matter which version of Windows is running. It's perfectly legit for software to query these aspects of its execution environment, having an orderly way to enumerate and version them is a valuable thing. As VM proliferation progresses, I suspect that we will come to think of VMMs in the same way: as another facet of the stack of hardware and software on which you happen to be running, whose presence is neither surprising nor secret.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-117216714748557486?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/117216714748557486/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=117216714748557486' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/117216714748557486'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/117216714748557486'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2007/02/microsoft-swallows-bluepill.html' title='Microsoft swallows the BluePill'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-116187799956029532</id><published>2006-10-26T08:46:00.000-07:00</published><updated>2006-10-26T09:23:41.806-07:00</updated><title type='text'>Survived ASPLOS XII!</title><content type='html'>Well, I got to present my first &lt;a href="http://www.princeton.edu/~asplos06/"&gt;conference&lt;/a&gt; &lt;a href="http://www.vmware.com/pdf/asplos235_adams.pdf "&gt;paper&lt;/a&gt;, and lived to tell the tale. Getting to take a question from Dave &lt;a href="http://www.amazon.com/Computer-Architecture-Fourth-Quantitative-Approach/dp/0123704901/ref=pd_lpo_k2_dp_k2a_1_txt/104-0235784-6125539"&gt;"AQA" &lt;/a&gt;Patterson gave me goosebumps. On Tuesday, a grad student whose name escapes me (sorry!) asked Ole and me, "So, the two of you did all this work yourselves?" Of course not! I'm ashamed to have left that impression on anybody. The VMware VMM group has around 100 alumni at this point; our results, at least as regards the software VMM, stand on the shoulders of many giants. The hardware VMM has also had significant contributions from Jim Mattson, Meenali Rungta, and Michael Ho.&lt;br /&gt;&lt;br /&gt;ASPLOS was biking distance from my home this year, so perhaps I'll present a receipt for some chain lube as a travel expense or something. It's amazing how hard it is to get motivated for the "extra-curriculars" at a conference when you can just go home any time you like; instead of going to the welcome reception, I stayed home and made meatloaf. Whatcha gonna do...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-116187799956029532?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/116187799956029532/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=116187799956029532' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/116187799956029532'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/116187799956029532'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/10/survived-asplos-xii.html' title='Survived ASPLOS XII!'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-115937039670686442</id><published>2006-09-27T08:08:00.000-07:00</published><updated>2006-09-27T09:43:28.316-07:00</updated><title type='text'>Going back to Rhody... Rhody... Rhody...</title><content type='html'>&lt;a href="http://en.wikipedia.org/wiki/Ll_cool_j"&gt;I don't think so.&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;I'm going back to my &lt;a href="http://www.cs.brown.edu/"&gt;alma mater&lt;/a&gt; to give &lt;a href="http://www.cs.brown.edu/events/talks/adams.html"&gt;a talk&lt;/a&gt;. I figure I might as well do what little I can to boost attendance, so pretty please, New England virtualizanti, do what you can to make it.&lt;br /&gt;&lt;br /&gt;While I'm waxing nostalgic/faux hip-hop about my misspent college youth, it has been pointed out to me that a shout-out is due to my erstwhile &lt;a href="http://www.cs.brown.edu/courses/cs169"&gt;CS 169 TA&lt;/a&gt; and all-around &lt;a href="http://cryptnet.net/mirrors/texts/kissedagirl.html"&gt;bad-boy&lt;/a&gt; of the hardware/software interface, Bryan Cantrill. &lt;a href="http://online.wsj.com/public/article/SB115755300770755096-Puh3Kr2L9dGEhvkWyO94UivIRwA_20070910.html"&gt;&lt;i&gt;Chapeau&lt;/i&gt;&lt;/a&gt;, Bryan, Adam, and Mike.&lt;br /&gt;&lt;br /&gt;As I've pointed out again and again, to the point of eye-rolling boredom on the part of my colleagues, DTrace really is outrageously cool. The improvement in leverage that DTrace yields feels comparable to the improvement going from debugging with printf to a source-level interactive debugger. Those who haven't tried it yet, run, do not walk, to download &lt;a href="http://www.opensolaris.org"&gt;recent build of OpenSolaris&lt;/a&gt;, &lt;a href="http://www.vmware.com/products/player"&gt;install it in a VM&lt;/a&gt;, and start working your way through the &lt;a href="http://developers.sun.com/solaris/articles/dtrace_for_dev.html"&gt;numerous tutorials&lt;/a&gt;. You'll be glad you did.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-115937039670686442?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/115937039670686442/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=115937039670686442' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115937039670686442'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115937039670686442'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/09/going-back-to-rhody-rhody-rhody.html' title='Going back to Rhody... Rhody... Rhody...'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-115878631931000267</id><published>2006-09-20T13:52:00.000-07:00</published><updated>2006-09-20T14:18:28.760-07:00</updated><title type='text'>Yes, Virginia. We deliver GP's on control flow transfers at the wrong EIP.</title><content type='html'>&lt;a href="http://eeyeresearch.typepad.com/blog/2006/09/another_vmware_.html"&gt;Busted!&lt;/a&gt; This is just one of those tough situations where "perfect" software and "useful" software are in unresolvable conflict. While we could, in theory, get this corner case completely right, no customer would want us to. To patch up this hole we'd have to make &lt;i&gt;all&lt;/i&gt; indirect kernel control flow transfers slower. Since literally &lt;span style="font-style:italic;"&gt;nothing&lt;/span&gt; we've ever run into in the wild cares, we just get this wrong. C'est la vie. Though, interestingly enough, the one piece of software out there that we know relies on this behavior: the VMware VMM itself.&lt;br /&gt;&lt;br /&gt;Since there are both architected (&lt;a href="http://chitchat.at.infoseek.co.jp/vmware/vmtools.html"&gt;the backdoor port&lt;/a&gt;) and unarchitected (i.e., the s[gi]dt/lsl instructions) ways of discovering you're in a VM, this isn't really "news," per se, but interesting x86 trivia none the less. If it makes you upset, you have a few options to make the behavior in a VM more like that of real hardware. As Derek discovered, you can tick the "disable acceleration" checkbox in your VM. You can also buy a shiny, new Intel processor and drop "monitor_control.vt32=TRUE" into your config file, but &lt;a href="http://www.vmware.com/community/message.jspa?messageID=376400"&gt;expect lousy performance&lt;/a&gt;. (VT32 really only exists as a check on the correctness of our VT implementation; all the VT performance work has been sunk into running 64-bit guests.)&lt;br /&gt;&lt;br /&gt;At the end of the day, discovering you're in a VM, in general, is always likely to be easy, just because of timing attacks. These pieces of code that folks write to detect that you're in a VM are sort of modern-day equivalents of the little assembly programs that were used for CPU identification before the CPUID instruction came along; these terribly clever little DOS programs would try to infer the size of the write buffer, time a few instructions, etc., and come up with a "fingerprint" of the CPU. These programs are serious fun to write, and have some educational value. I haven't seen any legitimate, practical uses of the VM detection programs thus far, though. I.e., congratulations, you now know you're on a VMware Workstation 4.5 VM. What are you going to do about it?&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-115878631931000267?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/115878631931000267/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=115878631931000267' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115878631931000267'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115878631931000267'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/09/yes-virginia-we-deliver-gps-on-control.html' title='Yes, Virginia. We deliver GP&apos;s on control flow transfers at the wrong EIP.'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-115755579537689158</id><published>2006-09-06T08:12:00.000-07:00</published><updated>2006-09-06T10:50:04.053-07:00</updated><title type='text'>Pining for microcode...</title><content type='html'>Some synchronization arguments we've been having at work led me to read &lt;a href="http://citeseer.ist.psu.edu/lampson80experience.html"&gt;Lampson and Redell's classic synchronization paper&lt;/a&gt;. It's rightly famous for providing the first clear exposition of the &lt;a href="http://www.netrino.com/Publications/Glossary/PriorityInversion.html"&gt;priority inversion problem&lt;/a&gt;. There's also a good deal of implementation detail about Mesa and Pilot, which were a programming language and operating system, respectively, for PARC's famed Alto workstation.&lt;br /&gt;&lt;br /&gt;Most &lt;a href="http://www.cs.wisc.edu/~sschang/OS-Qual/process/Mesa_monitor.htm"&gt;modern readers&lt;/a&gt; gloss over this implementation section, since the system described is trivial by modern standards (the OS kernel is 24KLOC) and obsolete in many ways. However, the extremely tight coupling between the OS and the hardware ISA is fascinating to me. The hardware directly supports the kernel's run queue, providing a context switch in a single, one-byte instruction! Faults move the current process straight from the run queue to a hardware-supported "fault queue" and reschedule in hardware. Stacks consist of discontiguous, linked frames allocated and deallocated from a variable-sized "frame heap" maintained in, you guessed it, hardware. When the frame heap is exhausted, a "frame fault" sticks the current process on the fault queue. Not quite as trippy as the StackFrame-as-firstclass Object supported by the SmallTalk system running on the same hardware, but still pretty darned far from the post-RISC, all-C-code-all-the-time machines we're accustomed to.&lt;br /&gt;&lt;br /&gt;This tight coupling of ISA to OS was made possible by a writable microcode store, whose internals were exposed to system software. Before I get all starry-eyed about how wonderful a microcode revival would be, I will admit up front that it's 2006. Even if it somehow were practical to expose the microcode stores of modern processors, no sane system software vendor would take advantage. Modern machines' microarchitectures are too complicated to be programmable by non-specialists, and it would be painful beyond belief trying to maintain correct implementations of the same ISA on different microarchitectures. Besides, the whole idea of adapting the ISA to a particular OS seems like a quaint holdover from the CISC days; the Alto folks were working in an environment where the hardware could execute a sequence of microcode instructions much faster than the equivalent sequence of macro-instructions, and that just isn't the world we live in anymore.&lt;br /&gt;&lt;br /&gt;So, while writable microcode is probably a stupid thing to wish for if you're writing your own OS, it might still be useful, say, to change the behavior of already existing instructions... It's obvious Intel and AMD are relying on some microcode changes to provide the first generation of VT and SVM in minor revisions of their processors. &lt;a href="http://www.vmware.com/pdf/asplos235_adams.pdf"&gt;I've complained&lt;/a&gt; that VT/SVM only allow software intervention on the far side of a heavyweight hardware context. Wouldn't it be lovely if, instead of software trap handlers for virtualization-sensitive events, the VMM provided "microcode" handlers for such events? Obviously, it wouldn't really be "microcode" proper; the ISA would have to be "architected", perhaps as a subset of the x86, and run with some vaguely SMM-esque constraints on its behavior. But, if it were possible to arrive at this "pseudo-microcode" in a more expeditious manner than the full context switch out to the VMM, it might provide an opportunity to handle some of the more frivolous exits much more efficiently.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-115755579537689158?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/115755579537689158/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=115755579537689158' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115755579537689158'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115755579537689158'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/09/pining-for-microcode.html' title='Pining for microcode...'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-115557314541216195</id><published>2006-08-14T09:32:00.000-07:00</published><updated>2006-08-14T09:42:20.820-07:00</updated><title type='text'>Hi, slashdot!</title><content type='html'>Dude. &lt;a href="http://developers.slashdot.org/article.pl?sid=06/08/12/2028223"&gt;We're famous!&lt;/a&gt; Too bad the article write-up calls our paper a "white paper," a term which, for me, carries strong connotations of gradient-bordered, visio-encrusted pdfs in sans serif fonts that use the word "enterprise" more than "and" or "the." For the record, the string "enterprise" appears in our paper only as part of the names of &lt;span style="font-style:italic;"&gt;Windows .Net Enterprise&lt;/span&gt; and &lt;span style="font-style:italic;"&gt;RedHat Enterprise Linux&lt;/span&gt;.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-115557314541216195?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/115557314541216195/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=115557314541216195' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115557314541216195'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115557314541216195'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/08/hi-slashdot.html' title='Hi, slashdot!'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-115514886130861670</id><published>2006-08-09T11:26:00.000-07:00</published><updated>2006-08-09T11:41:12.663-07:00</updated><title type='text'>"Blue Pill" is quasi-illiterate gibberish.</title><content type='html'>I'm surprised at the &lt;a href="http://www.eweek.com/article2/0,1895,1983037,00.asp"&gt;hullaballoo&lt;/a&gt; surrounding the so-called "blue pill" pseudo-exploit. The non-exploit consists of a boot-loaded VT/SVM hypervisor that "undetectably" compromises your chain-loaded host. Recall with me the fundamental theorem of VT/SVM: "VT and SVM make nothing possible that was not possible before." VMware's pre-VT/SVM products are an existence proof.&lt;br /&gt;&lt;br /&gt;This case is particularly hilarious, because "cloaking" a rootkit is actually &lt;span style="font-style:italic;"&gt;harder&lt;/span&gt; to do with VT/SVM than with plain-jane, pre-virtualization x86 technology. Without getting into all the gory details here, malicious code that runs at CPL 0 (a pre-requisite, remember, for the ostensible "attack") can simply map itself in a convenient portion of the kernel address space (say, the top megabyte), modify the limit fields in the running kernel's code and data descriptor table entries, &lt;span style="font-style:italic;"&gt;et voila&lt;/span&gt;: it's "undetectable", at least in the limited sense in which the blue pill hypervisor was undetectable. Yeah, there are some dots to connect; you have to point the IDT at the rootkit, and you may even ultimately need an x86 emulator if the kernel tries &lt;span style="font-style:italic;"&gt;really&lt;/span&gt; hard to detect you. But x86 emulators aren't exactly the stuff of science fiction; they're pretty much &lt;a href="http://bochs.sourceforge.net/"&gt;commodities&lt;/a&gt;, which is a handy thing, since you need one in VT/SVM hypervisors, too.&lt;br /&gt;&lt;br /&gt;The funny thing is that setting up an IDT and smashing a few GDT entries is actually a good deal simpler than setting up a full-fledged hypervisor, which needs a richer set of trap handlers, its own address space, probably needs to set up a shadow CR3 to protect itself from the guest, certainly needs a GDT and IDT, and so on. Most of that "life support" code can simply be stolen from the exploited host if you take the simpler approach outlined above. I'll go so far as to say that this "blue pill" hype is straightforward attention-whoring; virtualization is hot, and finding some sense in which it might be "bad" seems contrarian and interesting, so people's ears prick up. There's really nothing to see here, though.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-115514886130861670?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/115514886130861670/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=115514886130861670' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115514886130861670'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115514886130861670'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/08/blue-pill-is-quasi-illiterate.html' title='&quot;Blue Pill&quot; is quasi-illiterate gibberish.'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-115506013248682462</id><published>2006-08-08T10:55:00.000-07:00</published><updated>2006-08-10T08:22:55.246-07:00</updated><title type='text'>DTrace:MacOS X::Chocolate:Peanut Butter</title><content type='html'>&lt;a href="http://blogs.sun.com/roller/page/ahl?entry=dtrace_on_mac_os_x"&gt;Whoah.&lt;/a&gt; Between this, and the &lt;a href="http://www.apple.com/macpro"&gt;VT-enabled 64-bit Macs&lt;/a&gt;, I think Apple just sold me a computer.&lt;br /&gt;&lt;br /&gt;(The careful reader might be wondering why the author of &lt;a href="http://www.vmware.com/pdf/asplos235_adams.pdf"&gt;a paper that's somewhat critical of VT&lt;/a&gt; would be stoked about using VT for virtualization. The answer is: I spent a lot of time on that code, and even if it isn't quite the right approach, running my own code gives me the fun-sies. Plus, those new processors are just outrageously nice pieces of hardware all-around.)&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-115506013248682462?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/115506013248682462/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=115506013248682462' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115506013248682462'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115506013248682462'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/08/dtracemacos-xchocolatepeanut-butter.html' title='DTrace:MacOS X::Chocolate:Peanut Butter'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-115497261542823437</id><published>2006-08-07T10:41:00.000-07:00</published><updated>2006-08-07T10:43:35.440-07:00</updated><title type='text'>A Comparison of Software and Hardware Techniques for x86 Virtualization</title><content type='html'>Our (very early) experiences with VT/SVM, contrasted with VMware's classic VMM. &lt;a href="http://www.vmware.com/pdf/asplos235_adams.pdf"&gt;Enjoy&lt;/a&gt;. Also linked from the &lt;a href="http://www.vmware.com/academic/resources.html"&gt;academic program&lt;/a&gt; page referenced below.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-115497261542823437?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/115497261542823437/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=115497261542823437' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115497261542823437'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115497261542823437'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/08/comparison-of-software-and-hardware.html' title='A Comparison of Software and Hardware Techniques for x86 Virtualization'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-115455210414494291</id><published>2006-08-02T13:50:00.000-07:00</published><updated>2006-08-02T13:55:04.183-07:00</updated><title type='text'>Secret stash of VMware academic publications</title><content type='html'>&lt;a href="http://www.vmware.com/academic/resources.html"&gt;This page&lt;/a&gt;, carefully hidden under the link "Program resources" under the &lt;a href="http://www.vmware.com/academic"&gt;VMware academic program page&lt;/a&gt;, contains some published papers that VMware folks have put out over the years. Don't worry about the misleading title "Academic White Papers"; these are no-fooling, intellectually rigorous attempts at sharing knowledge at &lt;a href="http://www.usenix.org"&gt;legit&lt;/a&gt; &lt;a href="http://www.princeton.edu/~asplos06/"&gt;conferences&lt;/a&gt;. The odds of you finding this by just clicking around are near nil; I knew it existed, and couldn't figure it out without email from our webmaster. Enjoy!&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-115455210414494291?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/115455210414494291/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=115455210414494291' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115455210414494291'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/115455210414494291'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/08/secret-stash-of-vmware-academic.html' title='Secret stash of VMware academic publications'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-114771838104692039</id><published>2006-05-15T11:28:00.000-07:00</published><updated>2006-05-15T11:50:52.906-07:00</updated><title type='text'>Microkernel fracas drones on</title><content type='html'>I had the pleasure of meeting Andrew Tannenbaum at SOSP 2005. He's a smart man, and anybody who &lt;a href="http://www.minix3.org/vmware.html"&gt;distributes their OS as a VMware VM&lt;/a&gt; gets props on that account alone. He's also a refreshingly &lt;a href="http://www.cs.vu.nl/~ast/reliable-os/"&gt;unreconstructed microkernelist&lt;/a&gt;. To hear Andy tell it, the advantages of microkernels in 2006 are a lot like their supposed advantages in 1994: stability, minimality, easy to reason about code, user-level drivers that automagically survive nuclear armageddon, etc. For the most part, I'm willing to stand on the sidelines on the microkernel/megakernel holy war. However, since none of the actual principals of this debate will pay any attention to anything I say, I can attempt the following drive-by cheapshots:&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Dr. Tannenbaum is fond of mentioning "self-healing" as a goal of Minix 3. I understand this to mean that, since microkernels enable user-level drivers, failures in hardware and software can be routed around with the same sorts of logging, checkpoint-restore facilities, etc., used for enabling high-availability in other user-level applications.&lt;br /&gt;&lt;br /&gt;This has always struck me as a bit too far-fetched to be a short-term goal of a research project. E.g., if your graphics card driver just went down in flames, there's no way in hell a reinstantiated graphics card driver will be able to recover your system seamlessly, because the hardware is in an unknown and, more importantly, unknowable state. When I asked one of Andy's grad students about Minix 3's plans for tackling this problem, I got the cryptic admission that "that's a hard problem." "That's a hard problem" can very occasionally mean, "We have a solution that's entirely too clever to share before I cash some checks from VCs," but it usually means, "We have no freaking clue on earth." Regardless, if you do solve this "incoherent hardware after driver crash" problem, your solution is likely to be just as applicable to a monolithic kernel as to Minix 3, since the problem isn't inherently related to software structure.&lt;br /&gt;&lt;br /&gt;If you don't solve this problem, I don't see in what sense your system is self-healing. While a box might continue to "run" with a crashed display driver (or filesystem, storage, your networking driver, etc.), the system is "running" in name only; i.e., it's unlikely to usable for non-trivial work until it's power-cycled. If we're counting that as "self-healing," then all the Linux crashes where I'm still able to ping the machine should be counted, too.&lt;br /&gt;&lt;br /&gt;&lt;li&gt;Xen has been carefully, and somewhat silently transmogrifying itself into a microkernel. At some level, this is inherent to the paravirtualization project. Once you liberate the interface between the hypervisor and a "guest" from hardware constraints, you might as well call the "hypervisor" a microkernel and the "guest" a process and be done with it. After all, what is UNIX but a very high-level virtual machine definition, consisting of a set of system calls?&lt;br /&gt;&lt;br /&gt;Xen 3.0 is drinking another serving of the microkernel kool-aid by moving all of its drivers into user-level processes (oops, I mean "guests"). I predict that they'll hit the same bumps in the road as the microkernel folks did, and have just as much trouble reaping the supposed benefits. &lt;br /&gt;&lt;br /&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-114771838104692039?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/114771838104692039/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=114771838104692039' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/114771838104692039'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/114771838104692039'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/05/microkernel-fracas-drones-on.html' title='Microkernel fracas drones on'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-114624522979654771</id><published>2006-04-28T10:24:00.000-07:00</published><updated>2006-04-28T10:27:09.810-07:00</updated><title type='text'>Treasure trove of hoary Sun OS research</title><content type='html'>I ran across &lt;a href="http://www.opensolaris.org/os/project/muskoka/doc_attic/"&gt;this&lt;/a&gt; while poking around the opensolaris site yesterday. While I've read some of these papers in the past, seeing them collected together makes you realize just how differently OS'es could have turned out. In 1988, for example, most people were implementing shared libraries (if they were implemented at all) in the kernel, rather than as applications utilizing general facilities like mmap. It makes you wonder what we're doing now that will seem completely archaic and backwards in twenty years.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-114624522979654771?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/114624522979654771/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=114624522979654771' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/114624522979654771'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/114624522979654771'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/04/treasure-trove-of-hoary-sun-os.html' title='Treasure trove of hoary Sun OS research'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-114484799751672096</id><published>2006-04-12T06:16:00.000-07:00</published><updated>2006-04-12T06:20:13.003-07:00</updated><title type='text'>Intel quietly backing away from VT performance claims</title><content type='html'>Intel seems to be &lt;a href="http://techplanetasia.com/bcm/index.php/article/582"&gt;resetting expectations&lt;/a&gt; about VT performance now that the &lt;a href="http://www.vmware.com/community/message.jspa?messageID=376400"&gt;genie's out of the bottle&lt;/a&gt;. I get a lot of questions about VT performance, and the questions usually end with, "How much faster is it?" The answer, of course, is "it depends," and just what it depends on turns out to be the more interesting question. I'm preparing something more satisfying than the usual teases I've been dropping in this blog so far; stay tuned!&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-114484799751672096?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/114484799751672096/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=114484799751672096' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/114484799751672096'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/114484799751672096'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/04/intel-quietly-backing-away-from-vt.html' title='Intel quietly backing away from VT performance claims'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-114298545005846718</id><published>2006-03-21T15:40:00.000-08:00</published><updated>2006-03-22T08:02:28.613-08:00</updated><title type='text'>Why settle for "privilege" when you can have "hyperprivilege"!</title><content type='html'>This "hypervisor" talk has always kind of rubbed me the wrong way. What happens when we want another level of indirection? Do I get a "megavisor"? A "superdupervisor"? I'm rooting for the "ubervisor." IBM actually found it necessary to construct such an ubervisor, to aid hypervisor development, and explicitly supported it in their hardware virtualization extensions to the s/370. I know it sounds like I'm making this up, &lt;a href="http://www.findarticles.com/p/articles/mi_m0ISJ/is_n1_v30/ai_10540516"&gt;but I'm not.&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Anyway. Sun has released a draft of the hardware and software specs for their virtualization extensions. &lt;a href="http://opensparc-t1.sunsource.net/index.html"&gt;Check it out&lt;/a&gt;. From a technical point of view, it's interesting that they're treating the representation of guest privileged state as a collection of "hyperprivileged" registers, rather than fields in an in-memory, hardware-walked struct, as the x86 hardware assistance initiatives have done. The privileged register approach has the nice property of making nesting work somewhat more cleanly, but also has the unfortunate property of making accesses to guest state slower. (Assuming, of course, that getting at these "hyperprivileged" registers is slower than, say, a load or a store. Take anything I claim about sparc with a big grain of salt, because I, like everyone else, have not done real work on them since college.)&lt;br /&gt;&lt;br /&gt;They seem to be taking an IBM-esque approach of viewing the hypervisor as a firmware extension, rather than a shrink-wrapped set of software. This was how virtualization worked back in the &lt;a href="http://citeseer.ist.psu.edu/context/1063894/0"&gt;Popek and Goldberg&lt;/a&gt; era; vendors controlled the entire vertical stack from hardware up to the application. Since all layers of the hardware/software stack were fungible, changes in both hardware and software could be made to accomodate virtualization. Virtualization-motivated changes to the hardware (via &lt;a href="http://www.hpcwire.com/hpc/584864.html"&gt;VT&lt;/a&gt; and &lt;a href=""&gt;SVM&lt;/a&gt;) and software (the kids call it &lt;a href="http://csdl2.computer.org/persagen/DLAbsToc.jsp?resourcePath=/dl/mags/co/&amp;toc=comp/mags/co/2005/05/r5toc.xml&amp;DOI=10.1109/MC.2005.169"&gt;paravirtualization&lt;/a&gt; these days) are both back with a vengeance, though not because any one company controls the hardware software stack anymore. The hardware changes have been motivated by the popularity of &lt;a href="http://www.vmware.com"&gt;third-party virtualization software&lt;/a&gt;, while the software changes have been made possible by the availability of freely modifiable, high quality operating systems like Linux. As with all things virtualization, everything old is new again, but for different reasons.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-114298545005846718?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/114298545005846718/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=114298545005846718' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/114298545005846718'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/114298545005846718'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/03/why-settle-for-privilege-when-you-can.html' title='Why settle for &quot;privilege&quot; when you can have &quot;hyperprivilege&quot;!'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-114105766801131283</id><published>2006-02-27T08:19:00.000-08:00</published><updated>2006-02-27T08:31:20.393-08:00</updated><title type='text'>Did somebody ask for a CHALLENGE????</title><content type='html'>No iPods, or free licenses, or t-shirts, or whatever, folks. Make a super-neat virtual machine to run in &lt;a href="http://www.vmware.com/products/player"&gt;VMware Player&lt;/a&gt; and win &lt;a href="http://www.vmware.com/challenge"&gt;stacks and stacks of cold, hard cash&lt;/a&gt;. Use your imagination here: what does the world need? What problems have you encountered that could have been better solved with the use of a pre-fabricated VM? Maybe you want to use &lt;a href="http://www.joelonsoftware.com/items/2005/05/02.html"&gt;multiple snapshots&lt;/a&gt; to cheat at &lt;a href="http://www.csd.uwo.ca/Infocom/zork1.html"&gt;Zork&lt;/a&gt;? The sky's the limit.&lt;br /&gt;&lt;br /&gt;I'm kind of blown away at the &lt;a href="http://www.vmware.com/vmtn/appliances/challenge/prizes.html"&gt;generosity&lt;/a&gt; of the terms of this contest. First prize is $100k! Those are US dollars, folks. &lt;a href="http://finance.yahoo.com/q/is?s=emc&amp;partner=mf"&gt;We're good for it.&lt;/a&gt; There are also various category prizes (e.g., best consumer VM, best developer VM, best VM submitted by a full-time student, etc.) If VMware employees weren't inelligible, I'd totally be taking a few days "sick" to make the ultimate multi-boot &lt;a href="http://www.atheos.cx"&gt;AtheOS&lt;/a&gt;/&lt;a href="http://www.moldus.org/~laurent/GNUstep/OS42_Install.html"&gt;OpenStep&lt;/a&gt; VM extravaganza...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-114105766801131283?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/114105766801131283/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=114105766801131283' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/114105766801131283'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/114105766801131283'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/02/did-somebody-ask-for-challenge.html' title='Did somebody ask for a &lt;i&gt;CHALLENGE&lt;/i&gt;????'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113981246545019540</id><published>2006-02-12T22:27:00.000-08:00</published><updated>2006-02-21T07:13:41.966-08:00</updated><title type='text'>Microsoft behind the 64-bit virtualization 8-ball</title><content type='html'>When my "vmware VT" google alert fired for &lt;a href="http://tinyurl.com/dddrl"&gt;this story&lt;/a&gt;, I exercised a rare bit of journalistic skepticism and didn't post right away. After all, it's basically &lt;i&gt;some guy&lt;/i&gt; claiming he spoke to &lt;i&gt;some unnamed guy&lt;/i&gt; at &lt;a href="http://www.microsoft.com"&gt;our esteemed competitor&lt;/a&gt;. This seems a somewhat flimsy basis for concluding that the coming version of Microsoft Virtual Server won't be supporting 64-bit guests. Especially given that English is obviously not the author's first language, the potential for misunderstanding was just too great for any premature showboating. The truth will out itself in time; better for now to maintain a calm, statesmanlike reserve.&lt;br /&gt;&lt;br /&gt;Well, after picking through &lt;a href="http://download.microsoft.com/download/9/8/f/98f3fe47-dfc3-4e74-92a3-088782200fe7/TWSE05008_WinHEC05.ppt"&gt;some WinHEC slides&lt;/a&gt;, all I've got to say is nyah nyah nyah!!!! It looks as though the MS Virtual Server folks haven't quite managed to &lt;a href="http://www.vmware.com/vmworld/2005/pac346.pdf"&gt;square the 64-bit virtualization circle&lt;/a&gt; in time for the next release of Virtual Server. Let's see: we have a NaN% price disadvantage when compared with &lt;a href="http://www.vmware.com/products/server"&gt;VMware Server&lt;/a&gt;, no SMP, and no 64-bit guests. All that leaves Microsoft with is the ability to vaguely hint at the coming hypervisor-based nirvana of Vista &lt;i&gt;nee&lt;/i&gt; Longhorn. But in the meantime, why not use VMware VMs? Even if every syllable MS utters about its coming hypervisor is an understatement, common sense suggests they'll try to make it easy to move VMware VMs into the new environment, so what's the risk in choosing a solution that is cheaper, better, and existent?&lt;br /&gt;&lt;br /&gt;For extra added irony, check out Microsoft &lt;a href="http://channel9.msdn.com/Showpost.aspx?postid=163022"&gt;trying real, real hard&lt;/a&gt; to make it sound like they're leading the way with all this Buck Rogers Virtumization Technology! OK, OK, in fairness, this is actually a pretty good whiteboard talk. Much of what my Microsoft colleague says is applicable to VMware's VMM as well; it's a good introduction for those curious about the nitty gritty details of running unmodified x86 operating systems. We don't binary patch the windows kernel, though.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113981246545019540?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113981246545019540/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113981246545019540' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113981246545019540'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113981246545019540'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/02/microsoft-behind-64-bit-virtualization.html' title='Microsoft behind the 64-bit virtualization 8-ball'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113933676689797090</id><published>2006-02-07T10:14:00.000-08:00</published><updated>2006-02-07T10:27:08.123-08:00</updated><title type='text'>VMware Server beans spilled</title><content type='html'>We're going to be &lt;a href="http://www.vmware.com/news/releases/server_beta.html"&gt;giving away a server product&lt;/a&gt;, to help keep our &lt;a href="http://www.vmware.com/products/player"&gt;free desktop product company&lt;/a&gt;. This has been covered and talked to death &lt;a href="http://it.slashdot.org/it/06/02/03/1320216.shtml"&gt;elsewhere&lt;/a&gt;; I could blather on about the business strategy behind it, but it's mostly self-explanatory. VMware is still selling &lt;a href="http://www.vmware.com/products/esx"&gt;ESX Server&lt;/a&gt;, and we're betting that the free taste of virtualization goodness will get customers excited enough to start signing POs for our pricier offerings. We'll be selling support for the free products, too.&lt;br /&gt;&lt;br /&gt;Perhaps the only widespread misconception I've seen so far is that the existence of both Player and Server as free products means that Workstation is doomed as a for-pay product. It's not necessarily so. While it was true for some earlier releases that Workstation was a strict subset of the GSX product (which is now the free "Server" product), Workstation 5 introduced some features that were not available with GSX. E.g., Workstation lets you organize groups of related VMs into &lt;a href="http://www.google.com/url?sa=t&amp;ct=res&amp;cd=2&amp;url=http%3A//www.vmware.com/pdf/ws5_teams_technote.pdf&amp;ei=w-ToQ5WPEo-kYOPH-fEP&amp;sig2=lyoECGIQJnHg1VGdZE6gMQ"&gt;"teams" &lt;/a&gt;that power on and off together, share network segments with loss rate and bandwidth properties, etc. There's also a more rich set of abilities for making &lt;a href="http://www.vmware.com/support/ws5/doc/releasenotes_ws5.html"&gt;clones&lt;/a&gt;, i.e., copies of the VM, in either a heavyweight ("full clones") or lightweight ("linked clones") mode. So, it's not an absurdity to continue charging for Workstation, even given the sudden availability of other hosted VMware products for free. I'm not saying that we certainly &lt;span style="font-style:italic;"&gt;will&lt;/span&gt; continue charging for WS, nor that we necessarily &lt;span style="font-style:italic;"&gt;won't&lt;/span&gt;, don't believe everything you read, there's no Easter Bunny, I don't speak for VMware, and consult a physician before starting any exercise program.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113933676689797090?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113933676689797090/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113933676689797090' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113933676689797090'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113933676689797090'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/02/vmware-server-beans-spilled.html' title='VMware Server beans spilled'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113872104252460929</id><published>2006-01-31T07:18:00.000-08:00</published><updated>2006-01-31T11:52:33.783-08:00</updated><title type='text'>OpenSparc Hypervisor Specification</title><content type='html'>As I mentioned here below, Sun is adding hardware virtualization assistance to future Sparc processors. This is deeply weird, because the only two sparc operating systems anybody cares about (Solaris and Linux) are already open source, and hence amenable to paravirt techniques. Given &lt;a href="http://www.opensolaris.org/os/community/xen/"&gt;Sun's apparent commitment to Xen&lt;/a&gt;, I continue to regard the use of hardware virtualization assistance as a head-scratcher.&lt;br /&gt;&lt;br /&gt;Well, now Sun has &lt;a href="http://opensparc.sunsource.net/nonav/opensparct1.html"&gt;their own hypervisor API spec&lt;/a&gt;, not obviously related to the Xen API. Does this make for yet another competing hypervisor API in the just-getting-started &lt;a href="http://lists.xensource.com/archives/html/xen-merge/2005-08/msg00076.html"&gt;Xen vs. VMware's VMIM&lt;/a&gt; fracas? Some sort of hedge on the part of Sun, just in case the Xen romance doesn't pan out? I wonder.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Edit:&lt;/b&gt; John Johnson very nicely points out that I'm being an idiot in the comments. Thanks!&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113872104252460929?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113872104252460929/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113872104252460929' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113872104252460929'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113872104252460929'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/01/opensparc-hypervisor-specification.html' title='OpenSparc Hypervisor Specification'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113830152737656365</id><published>2006-01-26T10:48:00.000-08:00</published><updated>2006-01-26T11:24:27.003-08:00</updated><title type='text'>Hola amigos!</title><content type='html'>&lt;a href="http://www.theonion.com/content/columnists/view/anchower"&gt;I know it's been a long time since I rapped at ya'.&lt;/a&gt; Here we are, in '06, more than half-way through the "oughts." How will our decade be remembered? I &lt;a href="http://www.slate.com/id/2134845/nav/tap1/"&gt;shudder to think&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;It looks like Sun is going to &lt;a href="http://news.com.com/Sun+servers+to+get+new+multi-OS+abilities/2100-1016_3-6031125.html?tag=nefd.top"&gt;build hardware virtualization support into the newer niagara parts&lt;/a&gt;. I must confess that this one is a bit of a head-scratcher for yours truly. The only OS'es of significance that run on sparc are Solaris and Linux. Persons running Linux on sparc hardware for anything other than software development or entertainment purposes are, not to put too fine a point on it, probably out of their cotton-picking minds. So, why does Sun think this will enable them to sell more servers, especially given that their (oh, so horrendously named) &lt;a href="http://www.opensolaris.org/os/community/brandz/"&gt;BrandZ&lt;/a&gt; magic sauce lets most Linux applications run on top of Solaris? Beats me. Perhaps they felt they had to be able to counter Intel's substantial VT hype?&lt;br /&gt;&lt;br /&gt;Speaking of which ... Simon Crosby was at &lt;a href="http://www.stanford.edu/class/ee380/Abstracts/060125.html"&gt;Stanford flogging Xen yesterday&lt;/a&gt;. While I was unfortunately not able to make it, I perused &lt;a href="http://www.stanford.edu/class/ee380/Abstracts/060125-stanford0601.pdf"&gt;the slides&lt;/a&gt; a tad. With foil titles like "XenSource Delivers Virtualization Value", there isn't much academic veneer on this very business-oriented talk, so, as a non-expert, I can do little to address the projections, pie charts, etc. However, I notice from slide 27 that they're relying on page-table switching to protect virtual kernels from virtual applications on 64-bit architectures. The slide is oddly silent on what a flaming performance disaster this approach constitutes. As if turning every virtual system call into two hardware system calls weren't enough, we're now piling a TLB flush on top of that cost, too.  I'll be interested to see how their 64-bit performance fares compared to &lt;a href="http://www.vmware.com/products/player/"&gt;our offerings&lt;/a&gt;. But hey! Who cares about performance when you're "&lt;em&gt;the&lt;/em&gt; Open Industry Standard," "Unlocking Platform Innovation"! I'm also tickled at the extended treatment of Xen's newfound live migration capabilities, as if &lt;a href="http://www.vmware.com/products/vc/vmotion.html"&gt;we hadn't shipped the very feature they're aping in 2002&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;I know, I know, it's a low blow. VMware has some pretty goofy marketing material out there, too. We're not presenting it in front of the Stanford CS department, though. For the most part. I think.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113830152737656365?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113830152737656365/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113830152737656365' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113830152737656365'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113830152737656365'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2006/01/hola-amigos.html' title='Hola amigos!'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113476012214680030</id><published>2005-12-16T10:50:00.000-08:00</published><updated>2005-12-18T19:30:21.536-08:00</updated><title type='text'>Graphics and I/O virtualization</title><content type='html'>A colleague of mine just pointed out &lt;a href="http://www.diku.dk/~jacobg/gfx/"&gt;a neat screenshot&lt;/a&gt; from &lt;a href="http://www.diku.dk/~jacobg/"&gt;Jacob Hansen&lt;/a&gt;, whom I had the pleasure of meeting at SOSP. Rich virtualization of I/O in general, and graphics in particular, remains a pretty wide open area. While &lt;a href="http://www.vmware.com/support/ws5/doc/ws_vidsound_d3d_enabling.html"&gt;Workstation 5.5&lt;/a&gt; includes some basic support for passing the host's video hardware through to the guest, the user experience is still recognizably VMware-esqe; i.e., the guest runs in a big opaque rectangle inside a GUI, or in full-screen mode, but the 'in between' possibilities are largely unexplored.&lt;br /&gt;&lt;br /&gt;There's also an &lt;a href="http://lists.xensource.com/archives/html/xen-devel/2005-12/msg00178.html"&gt;instructive discussion&lt;/a&gt; taking place over on Xen-devel. One of the interesting things about graphics cards is that they present a relatively natural place to exploit paravirtualization techniques; since all OS'es have well-defined graphics driver APIs, and graphics performance has a huge impact on the user experience, the risk/reward of "true virtualization" (e.g., deciding to precisely emulate a Matrox Flibbertigibbet 2000) vs. pseudo-virtualization (emulating some made-up device that makes getting bits out of the guest and onto the host display hardware easy and fast) strongly favors the latter. The same is true, albeit to a lesser extent, with storage controllers and networking adapters.&lt;br /&gt;&lt;br /&gt;The downside of making up your own hardware is that guest OS installers can't find a driver for your pseudo-device; since running an installer is often the first experience a user has with VMware, we want to get that guest installed, on the web, and generally looking smooth as quickly as possible. For that reason, we have a "morphing" network card. The network card initially looks like an AMD Lance, and can be driven by the stock Lance drivers available with everything after &lt;a href="http://support.microsoft.com/kb/q126746/"&gt;Windows for Workgroups&lt;/a&gt; or so. However, once you install the VMware tools in the guest, we install a driver that colludes with the Lance, to use a more streamlined, paravirt style I/O path.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113476012214680030?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113476012214680030/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113476012214680030' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113476012214680030'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113476012214680030'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/12/graphics-and-io-virtualization.html' title='Graphics and I/O virtualization'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113475070213179154</id><published>2005-12-16T08:09:00.000-08:00</published><updated>2005-12-18T19:30:45.893-08:00</updated><title type='text'>DTrace for Linux! Sort of!</title><content type='html'>My homey/colleague at Sun &lt;a href="http://blogs.sun.com/roller/page/ahl/20051213"&gt;Adam Leventhal&lt;/a&gt; has posted a barn-stormer of an article about the multiplicative power of DTrace and Solaris' new Linux binary compatibility layer (somewhat unfortunately termed &lt;a href="http://www.opensolaris.org/os/community/brandz/"&gt;"BrandZ"&lt;/a&gt;). Adam's post follows the usual script for DTrace demos:&lt;ol&gt;&lt;li&gt;Take some innocent user-level application that mostly performs ok.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Demonstrate a head-scratching anomoly in this mostly-ok performance.&lt;/li&gt;&lt;br /&gt;&lt;li&gt;Make the developers look like total idiots.&lt;/li&gt;&lt;/ol&gt;This last item is a natural consequence of being able to see more deeply into the dynamic behavior of a software system than its creators.  Similarly, working on a virtual machine monitor one sees a good deal of &lt;a href="http://x86vmm.blogspot.com/2005/10/linux-nmis-on-intel-64-bit-hardware.html"&gt;unintentional behavior with serious performance consequences&lt;/a&gt;. This is not because the people working on top, or glibc, or the Linux kernel for that matter, are idiots. Far from it. (Mostly.) They're just working with inferior tools, like biologists before the invention of the microscope. Creating quality software is one of the most serious untackled technical challenges out there; to the extent that DTrace makes this more possible, it's a real reason to use Solaris.&lt;br /&gt;&lt;br /&gt;I've got to hand it to Sun; circa 2000, I thought OS'es were a solved problem. Yeah, we &lt;a href="http://www.osnews.com"&gt;beat our chests&lt;/a&gt; over Solaris or Linux or Windows or AIX or whatever, but they're all basically the same junk: processes, users, threads, networking, multiprocessors, filesystems, virtual memory, linkers, etc. While all that stuff is blindingly hard to get right, impelementing it is, at some level, a simple matter of programming. So, props to the boffins at Sun for actively fighting commodification: ZFS and DTrace are real reasons to favor Solaris over other OS'es! For the first time since Mac OS X shipped, there are legitimate, technical reasons for an OS to claim fundamental superiority. Now BrandZ helps overcome excuses for not using Solaris. Of course, Solaris is free, so how they &lt;a href="http://finance.yahoo.com/q/cf?s=SUNW&amp;annual"&gt;turn this into cash flow&lt;/a&gt; is another question.&lt;br /&gt;&lt;br /&gt;(And no, smart-alecks, I don't own any SUNW stock or derivatives. Err, I guess I probably do through some index fund somewhere. But you get the point; I'm not randomly text-messaging strangers that "SUNW is gng to $25+++++!!!!!111".)&lt;br /&gt;&lt;br /&gt;Lest I get too overheated here, &lt;a href="http://www.vmware.com/products/player"&gt;my favorite Linux application&lt;/a&gt; won't run under BrandZ, presently. The kernel-level portion of VMware hasn't been ported to Solaris. However, there's at least conceptual hope. We ship the source to vmmon along with the Linux hosted products-- we have to, because there's no such thing as a Linux kernel ABI. Back in the workstation 2.0 days, &lt;a href="http://www.mindspring.com/~vsilyaev/vmware/"&gt;some intrepid FreeBSD folks&lt;/a&gt; took it upon themselves to port vmmon to FreeBSD, and were able to use FreeBSD's linux compatibility layer to run the VMware binary. Perhaps some similarly motivated &lt;a href="http://www.opensolaris.org"&gt;OpenSolaris&lt;/a&gt; folks will get around to doing something similar?&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113475070213179154?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113475070213179154/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113475070213179154' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113475070213179154'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113475070213179154'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/12/dtrace-for-linux-sort-of.html' title='DTrace for Linux! Sort of!'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113355061128113840</id><published>2005-12-02T10:37:00.000-08:00</published><updated>2005-12-14T08:12:13.686-08:00</updated><title type='text'>Standing on the shoulders of giants.</title><content type='html'>Most folks realize that IBM, DEC, and several other old-school computer manufacturers were thoroughly exploring virtualization around the time my generation was thoroughly exploring our mothers' wombs. Working at VMware for the last six years, I've been constantly aware that much of the ground we're covering was well-worn decades ago. Still, at times, the fidelity of the echos through the generations amazes me.&lt;br /&gt;&lt;br /&gt;I've written a lot here about &lt;a href="ftp://download.intel.com/technology/computing/vptech/C97063-002.pdf"&gt;VT&lt;/a&gt;, Intel's recently shipped CPU virtualization hardware. I'm pretty intimately familiar with VT's gory guts, as well as those of &lt;a href="http://enterprise.amd.com/downloadables/Pacifica_Spec.pdf"&gt;AMD's Pacifica&lt;/a&gt;, after spending a good chunk of my career at &lt;a href="http://www.vmware.com/"&gt;VMware&lt;/a&gt; extending our VMM to support them. (Sorry to disappoint, &lt;a href="http://slashdot.org/"&gt;AMD&lt;/a&gt;/&lt;a href="http://www.realworldtech.com/"&gt;Intel&lt;/a&gt; fanboys: the two specifications are pretty much exactly the same, with different instructions and in-memory layouts, etc.)&lt;br /&gt;&lt;br /&gt;I was also faintly aware that IBM had done some work to accelerate virtualization "back in the day." But, I was utterly shocked at the familiarity of &lt;a href="http://www.findarticles.com/p/articles/mi_m0ISJ/is_n1_v30/ai_10540516"&gt;this paper&lt;/a&gt; (Osisek, Jackson, Gum, in &lt;span style="font-style: italic;"&gt;IBM Systems Journal&lt;/span&gt;, March, 1991). It describes &lt;i&gt;interpretive execution&lt;/i&gt;, which is IBM's name for the S/390 virtualization acceleration hardware. What's fascinating is that "interpretive execution" so closely resembles Pacifica, and in turn VT, that you can mechanically translate among them.&lt;br /&gt;&lt;br /&gt;What VT calls "non-root mode", and Pacifica calls "guest mode", is known as "interpretive execution" (which, by the way, joins a long list of nuttily technical-sounding, yet completely non-descriptive terms that I associate with IBM; it's right up there with "translation lookaside buffer"). VT's "vmlaunch" instruction is Pacifica's "vmrun" is s/390's Germanic-flavored "sie"; Intel's "VMCS" is AMD's "VMCB" is IBM's "state description" (another hilarious IBM-ism).&lt;br /&gt;&lt;br /&gt;The paper also provides something of a crystal ball, describing some interesting extensions that haven't made their way into the x86 vendors' hardware just yet: hardware support for a second level of address translation to support the paged MMU within the guest (which is described, albeit briefly, in the Pacifica spec), hardware SMP guest support (though this might be IBM-specific; it seems to be oriented towards implementing a semi-magical "tlb shootdown" instruction that has no analog on the x86); and I/O acceleration (though again, who knows how applicable this will be to the modern world; the described facilities seem oriented entirely towards pass-through of physical devices, and then only for a single, blessed guest on a given host, which, as Xen demonstrates, can already be implemented today). Everything old is new again...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113355061128113840?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113355061128113840/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113355061128113840' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113355061128113840'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113355061128113840'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/12/standing-on-shoulders-of-giants.html' title='Standing on the shoulders of giants.'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113341279650979276</id><published>2005-11-30T20:46:00.000-08:00</published><updated>2005-11-30T20:53:17.116-08:00</updated><title type='text'>Workstation 5.5 out the door</title><content type='html'>Well, I can stop directing VT experimenters at the Workstation 5.5 beta, now that &lt;a href="http://www.vmware.com/products/ws/"&gt;Workstation 5.5 has shipped&lt;/a&gt;. &lt;a href="http://www.redmondmag.com/news/article.asp?EditorialsID=7067"&gt;link&lt;/a&gt; &lt;a href="http://www.techworld.com/opsys/news/index.cfm?NewsID=4893&amp;Page=1&amp;pagePos=11&amp;inkc=0"&gt;link&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113341279650979276?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113341279650979276/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113341279650979276' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113341279650979276'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113341279650979276'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/11/workstation-55-out-door.html' title='Workstation 5.5 out the door'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113263072930666189</id><published>2005-11-21T19:37:00.000-08:00</published><updated>2005-11-22T11:50:10.243-08:00</updated><title type='text'>ZFS emerges from the vapor</title><content type='html'>The last few stragglers of Solaris 10 are finally making their way out the door, and look none the worse for their lateness. &lt;a href="http://blogs.sun.com/roller/page/bmc?entry=welcome_to_zfs"&gt;ZFS &lt;/a&gt;seems extremely promising from an administrability point of view; getting rid of LVMs, if it accomplished nothing else, would be a huge usability win, and greatly increase the appeal of pooled storage systems. Clicking around the links Bryan has posted above, I saw some promising things, but a few things struck me as odd.&lt;br /&gt;&lt;br /&gt;For instance, &lt;a href="http://blogs.sun.com/roller/page/bill"&gt;Bill Moore&lt;/a&gt; shares an anecdote about &lt;a href="http://blogs.sun.com/roller/page/bill#zfs_vs_the_benchmark"&gt;a large performance win over UFS&lt;/a&gt;. The artificial benchmark in question flooded the system's block I/O layer with write requests, so the handfuls of reads lying around to, e.g., page in the root shell so the sysadmin can figure out what the hell just happened take seconds and minutes to complete, and the system is generally ground to dust. How does "ZFS" improve on this? Well, it observes that writes are bufferable, while reads are blocking, and so prioritizes reads over writes. It is therefore much more able to survive storms of write requests. Nice.&lt;br /&gt;&lt;br /&gt;So, why am I putting "ZFS" in quotes above? Because it seems to me that any block I/O layer could perform the same optimization. Why is this, as Bryan claims, "a consequence of the end-to-end principle"? Couldn't I do the same thing with extfs in &lt;a href="http://www.minix.org"&gt;Minix&lt;/a&gt;?&lt;br /&gt;&lt;br /&gt;Another entry that my virtualization-oriented bias leads me to see differently was some of &lt;a href="http://blogs.sun.com/barts"&gt;Bart Smaalders'&lt;/a&gt; &lt;a href="http://blogs.sun.com/roller/page/barts?entry=some_thoughts_on_zfs_s"&gt;musings on the consequences of ZFS&lt;/a&gt; for the future of Solaris. One of the pieces of extremely clever engineering in ZFS surrounds its treatment of snapshots; they're easy to make, lightweight, first-class, not necessarily read-only, etc., so Bart envisions all sorts of consequences for system upgrades, partitioning, etc. What's interesting to me, as a virtualization dork, is that virtualization (v12n?) makes all of this possible for any file system, under any operating system, with a minuscule fraction of the five-year engineering effort required to create a marvel like ZFS. So, if you find yourself fantasizing about using these snaphost features of ZFS under Windows, consider running that Windows machine in a &lt;a href="http://www.vmware.com/products/ws/"&gt;VMware virtual machine&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;But, while it is perhaps lightly overhyped, I truly think ZFS rocks, and wish I could use it on my host &lt;i&gt;right now&lt;/i&gt;. Maybe if &lt;a href="http://www.infoworld.com/article/04/08/04/HNsunlinux_1.html"&gt;Janus&lt;/a&gt; can follow ZFS out of the vapory mists, I'll make that threat a reality...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113263072930666189?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113263072930666189/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113263072930666189' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113263072930666189'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113263072930666189'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/11/zfs-emerges-from-vapor.html' title='ZFS emerges from the vapor'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113261476940627235</id><published>2005-11-21T14:48:00.000-08:00</published><updated>2005-11-21T15:25:25.553-08:00</updated><title type='text'>VT Coverage: Predictable and Complete Confusion.</title><content type='html'>Tragically, &lt;a href="http://www.computerweekly.com/Articles/2005/11/22/213059/Hardware-basedvirtualisationheraldsmajorrevampforPCs.htm"&gt;this article&lt;/a&gt; has been typical of the coverage of Intel's VT release. Put-near all of these articles take the reader on the same wild ride of falsehood and sheer conjecture:&lt;ol&gt;&lt;li&gt;&lt;b&gt;A new era of virtualization has dawned!&lt;/b&gt; In short, no. Virtualization is exciting and important, but the era dawned in 1998, and it's now some time in the era's early afternoon. Every single one of the features that these articles describes as gauzy science fiction that Intel's boffins are struggling to bring to life is available right now, today, a phone call away, in a fully supported commercial offering from VMware. VT is nothing but an alternative technique for some of the very low-level parts of VMware's software. It makes possible exactly nothing that was not possible before.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;&lt;b&gt;Err. Ok. But, like, hardware is fast and software is slow, so a new era of &lt;em&gt;performant&lt;/em&gt; virtualization has dawned! Or something!&lt;/b&gt; As episodes like &lt;a href="http://en.wikipedia.org/wiki/CISC"&gt;the VAX Call instruction&lt;/a&gt; illustrate, attempts to solve complex problems entirely with one, super-general purpose chunk of hardware are not always performance wins; software's flexibility, intelligence, and adaptability often means that it can exploit opportunities that hardware, whose development pipeline is almost an order of magnitude longer than that of software, cannot. Whether VT falls into this category remains to be seen, and we have to cut early implementations some slack, since this is, after all, first generation hardware and software, whereas VMware has been tuning its virtual machine monitor for seven years. But, simply assuming that "hardware is fast" can be ... misleading.&lt;/li&gt;&lt;li&gt;&lt;b&gt;Well. At least a new era of, maybe, more correct virtualization? Or, more simple virtualization? Throw us a bone, here.&lt;/b&gt; Maybe, maybe, maybe. But it will take some time to see whether these claims materialize or not.&lt;/li&gt;&lt;/ol&gt;&lt;br /&gt;Flame off. Deep breaths. Now seriously: is it really too much to ask that supposedly technical publications obtain some &lt;a href="http://www.nordichardware.com/news,2253.html"&gt;available hardware&lt;/a&gt;, and run some of the &lt;a href="http://www.vmware.com/support/ws55/doc/releasenotes_ws55.html"&gt;available software&lt;/a&gt; before breathlessly copying and pasting the Intel press release? Would any other piece of hardware get comparable coverage without the author ever having seen a single physical manifestation of the artifact, let alone run a real application on top of it? Can you imagine a 3D card review like this?&lt;br /&gt;&lt;blockquote&gt;NVidia's new gForce 68802xLxXx has ushered in a shining new era of accelerated gaming. Imagine blowing some stuff up in Doom 7, and it looking really, really, REALLY REAL!!!! And fast. We're hoping to get our hands on one in Q106. Hopefully someone will have written a driver by then.&lt;/blockquote&gt;&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113261476940627235?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113261476940627235/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113261476940627235' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113261476940627235'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113261476940627235'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/11/vt-coverage-predictable-and-complete_21.html' title='VT Coverage: Predictable and Complete Confusion.'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113200759615561233</id><published>2005-11-14T14:19:00.000-08:00</published><updated>2005-11-14T14:45:42.806-08:00</updated><title type='text'>VT hits the streets</title><content type='html'>Intel's Virtualization Technology (VT) has &lt;a href="http://news.zdnet.co.uk/hardware/chips/0,39020354,39237022,00.htm"&gt;hit the streets&lt;/a&gt;. For those just tuning in, VT, like AMD's competing initiative &lt;a href="http://www.amd.com/us-en/assets/content_type/white_papers_and_tech_docs/33047.pdf"&gt;SVM&lt;/a&gt;, &lt;i&gt;nee&lt;/i&gt; Pacifica, provides hardware support for CPU virtualization in the x86. I've spent a good deal of the last year working on supporting VT in VMware's VMM; this work is currently available in the &lt;a href="http://www.vmware.com/products/beta/ws/"&gt;public beta of VMware Workstation 5.5&lt;/a&gt;, so, if you have a really, &lt;i&gt;really&lt;/i&gt; new Intel CPU and are curious about how this VT stuff works, please give our code (and Intel's new hardware) a try.&lt;br /&gt;&lt;br /&gt;What does this all mean for VMware? &lt;a href="http://www.itarchitectmag.com/shared/article/showArticle.jhtml?articleId=172302134"&gt;Opinions vary&lt;/a&gt;, of course. When VT and Pacifica were first announced, there was a lot of &lt;a href="http://it.slashdot.org/comments.pl?sid=158519&amp;cid=13281362"&gt;knee-jerk slashdot triumphalism&lt;/a&gt; of the form, "Ha! We don't need VMware anymore because it will all be in hardware!!!" Of course, there's a lot more to VMware's software than just multiplexing CPUs. There's memory, a chipset, peripherals, undoable disks, virtual networks hooked up in complicated topologies with configurable bitrates and lossiness, and &lt;a href="http://www.vmware.com/pdf/ws5_teams_technote.pdf"&gt;all sorts of other stuff&lt;/a&gt; that's hard to imagine doing in hardware.&lt;br /&gt;&lt;br /&gt;It is true that Pacifica and VT sidestep the classical &lt;a href="http://encyclopedia.thefreedictionary.com/Popek%20and%20Goldberg%20virtualization%20requirements"&gt;impossibility result&lt;/a&gt; about x86 virtualization. On the one hand, if VMware hadn't figured out how to square that circle in 1998, I don't think we'd be where we are as a company today. But, on the other hand, we're far past the point where VMware lives and dies by a single systems programming parlor trick. Raw technology solutions for multiplexing an x86 CPU are already freely available. See, for example, &lt;a href="http://fabrice.bellard.free.fr/qemu/"&gt;QEMU&lt;/a&gt;. But, as cool as QEMU is, it doesn't really directly compete with VMware Workstation, because, e.g., you can't sync your ipod with a multiprocessor windows guest running inside of QEMU.&lt;br /&gt;&lt;br /&gt;In 1998, VMware Workstation 1.0 was a singing dog: the miracle wasn't that it sang well, but that it sang at all. However, in the intervening seven years, our software has become more than a curiosity. Stretching the analogy far past where wisdom suggests, we've taught that dog to be a colorful, original interpreter of Western music's canon, and we expect that dog to soon shock the world by crafting original, poignant compositions. Who cares if the landscape is cluttered with other mutts practicing their scales?&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113200759615561233?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113200759615561233/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113200759615561233' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113200759615561233'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113200759615561233'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/11/vt-hits-streets.html' title='VT hits the streets'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113095705450404760</id><published>2005-11-02T10:40:00.000-08:00</published><updated>2005-11-02T11:10:27.583-08:00</updated><title type='text'>SGI Prepares to Shuffle Off...</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://photos1.blogger.com/blogger/3746/1710/1600/sgi.png"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://photos1.blogger.com/blogger/3746/1710/320/sgi.png" alt="" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;I interned at &lt;a href="http://www.sgi.com/"&gt;SGI&lt;/a&gt;, then "Silicon Graphics, Inc.", during a wonderful summer of 1998. &lt;a href="http://www.sgi.com/products/software/irix/"&gt;IRIX 6.5&lt;/a&gt; was shipping. Linux was still &lt;a href="http://www.ussg.iu.edu/hypermail/linux/kernel/9811.1/0352.html"&gt;a joke&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;I met some amazing engineers, whose influence has continued to guide me. I learned a lot about UNIX internals, big NUMA systems, and how software really works in the process of trying to prove myself to Jeff Heller's real-time/pthreads group. I also began dating the lovely woman who is now Mrs. Adams that summer. So, I'll be spilling a bit of this coming beerbash's NorCal yuppie ale du jour &lt;i&gt;&lt;a href="http://www.sgi.com/company_info/newsroom/press_releases/2005/november/nyse.html"&gt;in memoriam&lt;/a&gt;&lt;/i&gt;. Good bye, SGI. Thanks for all the cool cases.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113095705450404760?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113095705450404760/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113095705450404760' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113095705450404760'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113095705450404760'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/11/sgi-prepares-to-shuffle-off.html' title='SGI Prepares to Shuffle Off...'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113086461331986544</id><published>2005-11-01T08:24:00.000-08:00</published><updated>2005-11-01T14:50:13.173-08:00</updated><title type='text'>Xen and RedHat</title><content type='html'>These days, when fellow techy sorts find out I work for VMware, they often want to know what I think about &lt;a href="http://citeseer.ist.psu.edu/dragovic03xen.html"&gt;Xen&lt;/a&gt;. With yesterday's RedHat PR event containing &lt;a href="http://news.zdnet.com/2100-3513_22-5924754.html?tag=zdfd.newsfeed"&gt;a protracted mash note&lt;/a&gt; to Xen, and Slashdot &lt;a href="http://linux.slashdot.org/article.pl?sid=05/11/01/0444221&amp;tid=163&amp;amp;tid=190"&gt;boiling over&lt;/a&gt; with the usual speculation, it seems particularly topical today to answer this FAQ. I'd like to especially, super-duper emphasize that this is just me babbling, and has nothing to do with anything officially believed, encouraged, advoctated, etc., by my employer.&lt;br /&gt;&lt;br /&gt;For those just tuning in, Xen technically differentiates itself from VMware by the somewhat lugubriously named technique of "paravirtualization." This term refers to co-designing a guest OS along with the virtual machine monitor, to optimize the fit between them. Obviously, this isn't always possible. If you intend to run an OS whose source code is inaccessible, or perhaps doesn't even exist in electronically readable form anymore, paravirtualization is not an option. Paravirtualization constrasts with the "black-box" virtualization practiced by classical VMMs, wherein the OS is carefully kept unaware that the VMM exists, and the VMM in turn has little semantic knowledge about the OS.&lt;br /&gt;&lt;br /&gt;Having worked at VMware for a while when I first heard the term, paravirtualization initially struck me as a bit of a hack; i.e., it looks like a way to get some of the advantages of virtual machines, without having to solve some of the &lt;a href="http://www.hotchips.org/archives/hc11/3_Tue/hc99.s6.1.Rosenblum.pdf"&gt;ludicrous problems&lt;/a&gt; that the x86 presents for classical VMMs. However, after talking to the L4 team a couple years ago, I have been won over, with some qualifications, to the view that paravirtualization can be a legitimate result of conscious system design. In some ways, paravirtualization shows the way towards a unifying scheme for CPU architectures, OS interfaces, "artificial" virtual machines like Java, etc. After all, what is a UNIX process if not a "virtual machine" with some convenient extra capabilities for writing performant applications?&lt;br /&gt;&lt;br /&gt;We can classify any software system that wraps underlying hardware along a continuum of levels of abstraction. A purist black-box VMM, which exports a software interface identical to underlying hardware, ala the golden-age IBM VM/360 systems, sits at the lowest level of edge of the universe, while something like a JVM, which exposes no details at all of the underlying hardware, sits at the top.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://photos1.blogger.com/blogger/3746/1710/1600/abstraction.0.png"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://photos1.blogger.com/blogger/3746/1710/400/abstraction.0.png" alt="" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="font-style: italic;"&gt;(Trivia: Note that VMware's ESX Server doesn't quite sit as far near the bottom as the VM/360 machines, because some aspects of the underlying hardware are mutated by the VMware virtualization layer. For instance, the vast diversity of hardware on current PCs are normalized to a basis set of hardware we're comfortable emulating. When easy opportunities to "lightly paravirtualize" the guest, e.g., by using an abstraction of a video or SCSI card, rather than a real hardware model, have arisen, VMware has taken those opportunities. Still, the interface exported by ESX Server is about as close as is practical to that exposed by bare metal.)&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Populating the middle ground between JVMs and bare metal, we find a bunch of familiar system-construction paradigms: traditional OS'es, which provide a virtual machine that has high-level semantics (such as files, processes, threads, etc.), but is still machine-language programmable; and microkernels, which provide a slightly less high-level abstraction out of the box. A paravirtualized VMM is simply a different point on this continuum, somewhere between the bare-metal VMM provided by something like &lt;a href="http://www.blogger.com/www.vmware.com/products/server/esx_features.html"&gt;VMware ESX Server&lt;/a&gt;, and the higher-level (though still pretty low-level) interface provided by an exokernel.&lt;br /&gt;&lt;br /&gt;So, that's Xen in a nutshell. It sits at a different space in the continuum of system design than current VMware products do. It offers some of the advantages of VMware products (unmodified application binaries) without offering others (unmodified system-level binaries). The Xen guys are fond of implying that they'll get around to offering those other advantages, perhaps with some coy references to &lt;a href="http://www.intel.com/technology/computing/vptech/"&gt;VT&lt;/a&gt; and &lt;a href="http://www.blogger.com/www.amd.com/us-en/assets/content_type/white_papers_and_tech_docs/33047.pdf"&gt;SVM&lt;/a&gt;. For various reasons, I think the technical obstacles to achieving parity with VMware's offerings are greater than they realize. Then again, maybe they've started to realize it in the process of slipping Xen 3.0 from August to December. (Not to be too smug; we've slipped releases, too. So has everybody.)&lt;br /&gt;&lt;br /&gt;On a personal note, I've had the pleasure of hanging out with various Xen movers and shakers. They're smart people interested in solving problems, and, fairly enough, would like to make a few pounds sterling doing it. They can also really hold their liquor. So, I wish them luck. I've got no problem at all with a little competition. It's good for our customers, good for virtualization as a whole, and keeps my job more interesting. So, bring it on, Xennies! I dare you to make Xen 3.0 as good as you know how.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113086461331986544?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113086461331986544/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113086461331986544' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113086461331986544'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113086461331986544'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/11/xen-and-redhat.html' title='Xen and RedHat'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113068525866672906</id><published>2005-10-30T06:56:00.000-08:00</published><updated>2005-11-01T17:57:23.443-08:00</updated><title type='text'>Gems of SOSP</title><content type='html'>Well, it was certainly a stimulating conference. There was a wealth of interesting and well-presented research. Here are some of the papers that interested me most. Insert disclaimer here: I'm just some guy who writes code for a living, what do I know, I'm sure I missed the point of your amazing paper, etc.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://research.microsoft.com/research/pubs/view.aspx?type=Publication&amp;id=1483"&gt;Vigilante&lt;/a&gt; (Costa et al., Microsoft Research) is a system for automatically detecting internet worms and stopping their spread. While network security is not a field in which I can even attempt to sound intelligent, the paper and talk were very convincing; "OK," I thought at the talk's conclusion, "go ahead and implement this and fix the internet." See an intriguing &lt;a href="http://www.wormblog.com/2005/03/can_we_contain_.html"&gt;blog post&lt;/a&gt; from someone who might know what they're talking about...&lt;br /&gt;&lt;br /&gt;&lt;a href="http://portal.acm.org/citation.cfm?id=1095810.1095820"&gt;IntroVirt&lt;/a&gt; (Joshi, King, Dunlap, and Chen, University of Michigan) is &lt;a href="http://www.eecs.umich.edu/CoVirt/papers/dunlap02.pdf"&gt;another&lt;/a&gt; clever application of virtualization from Peter Chen's group at University of Michigan. They've instrumented user-mode linux so that user-level processes within the UML guest can be instrumented with arbitrary code injected by the administrator of the VM. They present this system in a very narrow light: they use it to detect intrusions in known-vulnerable, but as-yet-unpatched software. It seems to me that the ability to run arbitrary code on arbitrary events in the guest is more generally powerful than this; I suspect the '*Virt*' crowd at Michigan has realized this, too.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.cs.ucsd.edu/%7Esavage/papers/Sosp05.pdf"&gt;Honeyfarm&lt;/a&gt; (Vrable et al., UCSD) is another intriguing application of virtualization. The described system uses a virtual machine "fork" primitive to create the external appearance of a very large network of vulnerable "honeypot" machines. Like the UNIX system call, this fork primitive returns twice, once in the calling virtual machine, and once in a newborne virtual machine that is in most respects a copy of its parent. Exploiting copy-on-write techniques and the fact that very few IP addresses are usually active at any given time allows them to achieve a very high virtual-to-physical resource ratio.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.cs.cornell.edu/People/egs/syslunch-fall05/rx.pdf"&gt;Rx&lt;/a&gt; (Qin, Tucek, Sundaresen, Zhou, UCSD) is a slightly quirky take on recovering from software failures. They observe that many software failures are easy to observe after the fact (e.g., they cause a SEGV), and that they are frequently caused by a small set of programmer errors (buffer overflows, timing assumptions, uninitialized variables, etc.). Rx does a process-level checkpoint of a server at connection establishment time, and, in the case of failure, reverts to the checkpoint, randomly perturbing the execution environment in the hopes of perturbing away the failure. (A proxy intermediates between client and server to provide the illusion of seamlessness.) According to the paper, this works much better than intuition suggests is possible. It's sort of like &lt;a href="http://www.cag.lcs.mit.edu/%7Erinard/paper/osdi04.pdf"&gt;failure-oblivious computing&lt;/a&gt;, but without the, err, obliviousness.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113068525866672906?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113068525866672906/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113068525866672906' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113068525866672906'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113068525866672906'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/gems-of-sosp.html' title='Gems of SOSP'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113022398083896930</id><published>2005-10-25T00:01:00.000-07:00</published><updated>2005-10-25T10:09:31.676-07:00</updated><title type='text'>House -- The Haskell OS</title><content type='html'>I'm a systems guy. In my professional life, as per this blog's title, I necessarily am writing software at a pretty grubby level of abstraction, typically in C and assembly. So, it often surprises folks that I carry a torch for functional languages in general, and &lt;a href="http://www.haskell.org/"&gt;Haskell&lt;/a&gt; in particular. It all dates back to my wasted youth at &lt;a href="http://www.cse.ogi.edu/"&gt;OGI&lt;/a&gt;. I was porting &lt;a href="http://www.uclinux.org/ports/"&gt;Linux to the i960&lt;/a&gt; on behalf of an active networking project that, to the best of my knowledge, never really got off the ground. My cube was adjacent to the warrens of OGI's fanatical Haskell lovers. While I was too preoccupied with my work at the time, the sheer wild-eyed passion these folks felt about Haskell made a strong impression on me.&lt;br /&gt;&lt;br /&gt;Then, they got &lt;a href="http://home.uchicago.edu/~mcc/"&gt;one of my friends&lt;/a&gt;. Michael did a substantial programming project in Haskell, and came away convinced that &lt;i&gt;this was how software ought to be&lt;/i&gt;. While I've never created real software in Haskell, I've taken great pleasure in, e.g., fooling around with &lt;a href="http://haskell.org/haskore/"&gt;Haskore&lt;/a&gt;. I've often idly wondered whether it made sense to contemplate doing systems programming in Haskell; well, those crazy folks across the way at OGI &lt;a href="http://www.cse.ogi.edu/~hallgren/House/"&gt;have beaten me to it&lt;/a&gt;. The House poster at SOSP was one of the more popular exhibits, and I for one spent a good twenty minutes or so sputtering half-formed questions such as, "so, like, you can use like, eval in your network drivers!", after which my head exploded.&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://photos1.blogger.com/blogger/3746/1710/1600/house.jpg"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://photos1.blogger.com/blogger/3746/1710/320/house.jpg" border="0" alt="" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Update:&lt;/span&gt; well, I got the &lt;a href="http://www.cse.ogi.edu/~hallgren/House/hOp-0.5.flp"&gt;boot floppy image&lt;/a&gt; going inside &lt;a href="http://www.vmware.com/products/player/"&gt;a VM&lt;/a&gt;, albeit briefly before the guest hung. So there are some bugs to work out; big freaking deal. Seeing page-table manipulation code as gorgeous as &lt;a href="http://www.cse.ogi.edu/~hallgren/House/kernel/pfe.cgi?H.VirtualMemory"&gt;this&lt;/a&gt; looks like a cold beer on a hot summer's day to me; and having the OS at large interact with it through &lt;a href="http://www.cse.ogi.edu/~hallgren/House/kernel/hi/iface/H.VirtualMemory.hs"&gt;this interface&lt;/a&gt; makes my heart sing. These guys badly need a &lt;a href="http://sourceforge.net/projects/e1000"&gt;e1000&lt;/a&gt; or vmnet ethernet driver; any takers?&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113022398083896930?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113022398083896930/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113022398083896930' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113022398083896930'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113022398083896930'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/house-haskell-os.html' title='House -- The Haskell OS'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113021184264832455</id><published>2005-10-24T20:35:00.000-07:00</published><updated>2005-10-24T22:18:00.753-07:00</updated><title type='text'>Minix3 Available as VM Image</title><content type='html'>Andy Tannenbaum's keynote at SOSP was more of the same, "Software is garbage! We should all be &lt;span style="font-style:italic;"&gt;ashamed!&lt;/span&gt;" hand-wringing that's become fashionable of late. A good chunk of his speech was concerned with plugging &lt;a href="http://www.minix3.org"&gt;the new version of Minix&lt;/a&gt;. You might be wondering what's changed with Minix. I am too. T'baum's speech was an unreconstructed rehash of the arguments on behalf of microkernels straight out of 1993: the system will survive driver crashes, &lt;span style="font-style:italic;"&gt;because the drivers are just user-level processes!&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;One of the formats in which minix 3 can be downloaded is as a &lt;a href="http://cd.minix3.org/download/minix3_1_1_small_vmware.zip"&gt;VMware VM&lt;/a&gt; ready to run in the &lt;a href="http://www.vmware.com/products/player/"&gt;VMware player&lt;/a&gt;. I downloaded it to my laptop, and was absolutely gobsmacked by how fast this thing boots. Linux and Windows have conditioned me to think of a reboot as &lt;span style="font-style:italic;"&gt;serious computation&lt;/span&gt;. It is also neat to see how understandable and clean the system's source is, and how rapidly it is possible to build the entire system from scratch. If you're an OS enthusiast, you owe it to yourself to fool around with this.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113021184264832455?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113021184264832455/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113021184264832455' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113021184264832455'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113021184264832455'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/minix3-available-as-vm-image.html' title='Minix3 Available as VM Image'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113012098434760250</id><published>2005-10-23T19:26:00.000-07:00</published><updated>2005-10-23T20:51:21.806-07:00</updated><title type='text'>Pioneer and Virtualization</title><content type='html'>The &lt;a href="http://www.google.com/url?sa=t&amp;ct=res&amp;amp;cd=1&amp;url=http%3A//www.cs.cornell.edu/People/egs/syslunch-fall05/pioneer.pdf&amp;amp;ei=nkZcQ8KBMIi4wgHWl9m1CQ&amp;sig2=t0UeuCY-hph8jCfQ1ZkkWg"&gt;very first paper in SOSP '05&lt;/a&gt; is a fine example of why a deep understanding of virtualization is now a necessity for doing systems work. A number of folks from CMU (Seshadri, Luk, Shi, Perrig, and Khosla) and one from IBM (van Doorn) describe an enterprising system they name "Pioneer." Pioneer aims to do what &lt;a href="http://www.amd.com/us-en/assets/content_type/white_papers_and_tech_docs/33047.pdf"&gt;AMD's SVM&lt;/a&gt; and &lt;a href="http://www.intel.com/technology/security/"&gt;Intel's LT&lt;/a&gt; presume is impossible: reliably measure and attest modern, mostly unmodified kernels. It's a really tough problem, and their approach is novel. However, on reading their paper, I'm convinced VMware's virtual machine monitor is an existence proof of the system's vulnerability. The paper considers this possibility, and rejects it, based on some unfounded assumptions about modern VMMs.&lt;br /&gt;&lt;br /&gt;Pioneer's central code-tampering prevention technique is external performance measurement: an external entity challenges the checksum code to attest to the state of the kernel. The external entity not only issues the challenge, but, using very nitty-gritty knowledge about the speed and microimplementation of the challenged host, issues the challenge with a time limit. Executing for longer than the time limit constitutes evidence of tampering, leading the external entity to consider the machine compromised. A corollary of this design is that the checksum function must be micro-architecturally optimal for the hardware on which it is run. If it leaves any spare execution resources unutilized, an attacker might use those parallel execution resources to paper over the holes that he has punched.&lt;br /&gt;&lt;br /&gt;The paper goes into much greater detail, but here are some of their responses, paraphrased, to obvious objections:&lt;br /&gt;&lt;br /&gt;1. &lt;i&gt;How do you know that the checksum code is checksumming the data it ought to be checksumming?&lt;/i&gt; The data is checksummed in a pseudo-random order, and the data pointers themselves are inputs to the checksum. If the kernel is attacked, and the attacker wishes to continue answering challenges, it will have to store the "old code" somewhere to be checked. To manipuate the data pointers within the checksumming code will cause a decrease in performance, which can be detected by the external measuring agent.&lt;br /&gt;&lt;br /&gt;Sounds good enough, but I disagree with the assumption that the "old data" and "new data" need to live at different virtual addresses. Why not create a different address space in which to keep the "old kernel" for measurement purposes, while keeping around a primary execution address space containing a compromised kernel? An attacker taking this strategy would intercept (using some memory-invisible technique, like the hardware breakpoint facility) the measurement code to change the pagetable pointer to the innocent-seeming address space on entry and exit. Since the address space switch is outside of the main loop of the checksum code, the odds that the external verifier will notice the performance difference are slim, as page table assignments are lost in the noise when compared to a network I/O. I will be curious to hear the authors' thoughts on this apparent hole in their system. The objection seems so simple and straightforward that I suspect there's something I'm just not getting.&lt;br /&gt;&lt;br /&gt;2. &lt;i&gt;What about VMMs?&lt;/i&gt; Here's where things get more interesting. Why doesn't running the guest kernel within a hostile VMM constitute a fool-proof attack method? The Pioneer folks consider this prospect in their paper:&lt;br /&gt;&lt;br /&gt;"Since we assume a legacy computer system where the CPU does not have support for virtualization, the VM must be created using a software-based virtual machine monitor (VMM) such as VMware*. .... If the adversary tries to cheat by using a software VMM, then each read of the flags register will trap into the VMM or execute dynamically generated code, thereby increasing the adversary's checksum computation time."&lt;br /&gt;&lt;br /&gt;...And since the system is very sensitve to changes in checksum execution time, the thinking goes, this attack will fail. They're assuming that writes to eflags.IF will "trap out" or "execute dynamically generated code", and that these will, without further argument, be slower than the native CLI/STI instructions. While this seems intuitively plausible, it's wrong, and I think it's wrong for interesting reasons.&lt;br /&gt;&lt;br /&gt;The CLI and STI instructions on modern processors are quite slow, because they have very complex effects on the following instruction stream. For instance, there are &lt;a href="http://tronweb.super-nova.co.jp/microbtron.html"&gt;OS'es&lt;/a&gt; whose idle loop only enables interrupts for a single instruction! All this interrupt stuff in general is exactly the sort of thing that gives today's deep and wide architectures fits, and STI and CLI times of more than 100 cycles are not unheard of on popular x86 implementations.&lt;br /&gt;&lt;br /&gt;VMware uses multiple techniques for making forward progress in guest execution. When executing kernels, VMware often runs guest code via a purpose-built binary translator. It's an unusual binary translator, because, rather than translating between &lt;a href="http://www.transmeta.com"&gt;two&lt;/a&gt; &lt;a href="http://java.sun.com"&gt;unrelated&lt;/a&gt; &lt;a href="http://www.research.ibm.com/vliw/layering.html"&gt;architectures&lt;/a&gt;, it translates supervisor-mode x86 programs to user-mode x86 programs. This means that a whole lot of the dynamic runtime of our translator is spent in memcpy; after all, the vast majority of kernel instructions are the innocent loads, stores, branches, and ALU ops that don't require heavy intervention on the part of a VMM.&lt;br /&gt;&lt;br /&gt;The Pioneer folks are right to guess that CLI and STI are not among those innocent instructions: we translate both of them into a small user-level program fragments. These translations basically load the software flags register, perform a single ALU operation on it, clearing or setting the interrupt flag, and then stores it back to memory. The interesting part of this all is that, since the translated code produced by VMware's VMM consists entirely of the bread-and-butter instructions that Intel and AMD go to great lengths to make fast, CLI and STI operations are much, much faster when executing in a VMware VM than on native hardware.&lt;br /&gt;&lt;br /&gt;No. Really. Seriously.&lt;br /&gt;&lt;br /&gt;Don't believe me? Try it yourself. Here's a kernel module that executes a simple STI benchmark:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;#include &lt;linux/module.h&gt;&lt;br /&gt;#include &lt;linux/kernel.h&gt;&lt;br /&gt;&lt;br /&gt;int&lt;br /&gt;init_module(void)&lt;br /&gt;{&lt;br /&gt;        int i;&lt;br /&gt;        unsigned oldjif = jiffies;&lt;br /&gt;&lt;br /&gt;        while (oldjif == jiffies)&lt;br /&gt;                ; /* wait for start of new timer epoch */&lt;br /&gt;&lt;br /&gt;        for  (oldjif = jiffies, i = 0; jiffies == oldjif; i++) {&lt;br /&gt;                __asm__ ("sti" : :);&lt;br /&gt;        }&lt;br /&gt;        printk(KERN_ALERT "bogosti: %d hz %d\n", i, HZ);&lt;br /&gt;        return 0;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;void&lt;br /&gt;cleanup_module(void)&lt;br /&gt;{&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;On my 1.8Ghz pentium M laptop, running the &lt;a href="http://www.vmware.com/products/beta/ws/"&gt;VMware Workstation 5.5 release candidate&lt;/a&gt; under a &lt;a href="http://fedora.redhat.com/"&gt;Fedora Core 4&lt;/a&gt; guest, our VMM executes about 200000 iterations in a single millisecond. That works out to around 200 million STIs per second, or something like 9 cycles per iteration. When you look at the code that GCC generated**, you realize that the VMware VMM is executing a STI, two ALU ops, a load, and a predictable branch in about 9 cycles. While I don't have a Linux host on which to test***, I'll go out on a limb and claim we're probably beating hardware by something like 5-10x on this microbenchmark.&lt;br /&gt;&lt;br /&gt;Of course, this is a special case. Virtualization can't make all guest kernel code faster, by the old "you can't fit a gallon of milk in a pint bottle" counting argument. But, it's an interesting real-world demonstration of the dangers of making plausible assumptions about performance, especially when it comes to virtualization. Be careful! And if you're resting your security arguments on performance properties of a virtual machine, measure, rather than assert.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;* &lt;span style="font-style: italic;"&gt;Sic&lt;/span&gt;. The first sentence is probably referring to VT and Pacifica, the coming hardware virtualization technologies from Intel and AMD respectively. However, note that in both of those systems, VMs are still "created using a software-based VMM"; VT and Pacifica don't get rid of your software VMM, folks. If they work as planned, they make your VMM radically more simple than VMware's. But the VMM is still sitting there, a big chunk of software that can deceive the guest into thinking almost anything it wants. Note that I take no responsibility for this abuse of our trademark. VMware is a company that makes a VMM among many other things; VMware is not a VMM.&lt;br /&gt;&lt;br /&gt;**&lt;pre&gt;&lt;br /&gt;  41:   fb                      sti&lt;br /&gt;  42:   83 c1 01                add    $0x1,%ecx&lt;br /&gt;  45:   a1 00 00 00 00          mov    0x0,%eax&lt;br /&gt;  4a:   39 d0                   cmp    %edx,%eax&lt;br /&gt;  4c:   74 f3                   je     41 &lt;init_module+0x41&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;*** Man, there goes all my UNIX street cred! It's true, it's true; I don't have enough free time to keep WIFI under Linux working. I'll repent, I swear it.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113012098434760250?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113012098434760250/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113012098434760250' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113012098434760250'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113012098434760250'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/pioneer-and-virtualization.html' title='Pioneer and Virtualization'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-113006617588164738</id><published>2005-10-23T03:58:00.000-07:00</published><updated>2005-10-23T04:35:55.190-07:00</updated><title type='text'>The Inimitable Stimulation of the Foreign</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://photos1.blogger.com/blogger/3746/1710/1600/brighton-sunday-am%20019.jpg"&gt;&lt;img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer;" src="http://photos1.blogger.com/blogger/3746/1710/320/brighton-sunday-am%20019.jpg" alt="" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://photos1.blogger.com/blogger/3746/1710/1600/brighton-sunday-am%20035.jpg"&gt;&lt;img style="margin: 0pt 10px 10px 0pt; float: left; cursor: pointer;" src="http://photos1.blogger.com/blogger/3746/1710/320/brighton-sunday-am%20035.jpg" alt="" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;There's nothing quite as exciting as being in a foreign country. A thousand quotidian details of ones life (how showers work; the &lt;a href="http://www.sumankumar.com/usability/2002_07_01_usablityrules_archive.html"&gt;direction doorknobs turn&lt;/a&gt;; the side of the street on which one drives; the convention about which &lt;a href="http://lnux.blogspot.com/2005/08/asidelight-switches.html"&gt;direction light switches flip&lt;/a&gt;) suddenly require conscious effort. The sharp relief thrown on all these details makes one realize just how peculiar any one place's customs are, and fills the mind with the possibilities of the ways things &lt;i&gt;could&lt;/i&gt; be, but perhaps just haven't gotten around to being so yet. There's nothing like it.&lt;br /&gt;&lt;br /&gt;Being in a foreign country where I actually speak the language is completely new to me. I must have almost killed myself five times this morning stepping off the curb after looking the wrong way. And yet, I can somewhat effortlessly communicate complex, even technical thoughts to the locals, albeit not without betraying my identity as a yank tourist (as if pulling out my camera every 30 seonds to shoot nothing in particular hadn't already given me away).&lt;br /&gt;&lt;br /&gt;This morning was a beautifully crisp, see-your-breath-but-still-sweater-without-a-jacket autumn morning, which I whiled away taking in the sights, sounds, and smells of &lt;a href="http://www.brighton.co.uk/"&gt;Brighton&lt;/a&gt;, the gorgeous seaside vacation destination for wealthy Londoners which is hosting &lt;a href="http://sosp.org/"&gt;SOSP&lt;/a&gt; 2005. My incredibly shallow research, and the incredibly tacky website linked above, had led me to expect a somewhat small town, but my morning walk around revealed a profoundly cosmopolitan retail economy, to the point of mild yuppification. Lots of world food restaurants, continental-style cafes, &lt;a href="http://www.frenchconnection.com/"&gt;FCUK&lt;/a&gt; storefronts, etc. Before I really knew what had happened, I'd walked for about three hours in this beautiful burg.&lt;br /&gt;&lt;br /&gt;I could complain about the usual travel headaches, (e.g., the Brit who got off our plane after getting on in SFO, leading to a typically post-9/11 security freakout that saw us departing an hour late) etc., but what's the point? I'm here now. So far, copious amounts of the delicious espresso is keeping jet lag, and what ought to be a substantial &lt;a href="http://www.oldspeckledhen.co.uk/"&gt;Old Speckled Hen&lt;/a&gt; hangover, at bay. We'll see how long that lasts.&lt;br /&gt;&lt;br /&gt;I'm off to wander the streets some more. I could do that whole "blogger" thing and tote this poor laptop to a coffee shop, but it seems like it just isn't &lt;i&gt;done&lt;/i&gt; here. We'll see if I can scare up the courage to break this convention...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-113006617588164738?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/113006617588164738/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=113006617588164738' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113006617588164738'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/113006617588164738'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/inimitable-stimulation-of-foreign.html' title='The Inimitable Stimulation of the Foreign'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-112993074482923195</id><published>2005-10-21T14:37:00.000-07:00</published><updated>2005-10-21T14:39:04.836-07:00</updated><title type='text'>Cor Blimey, Guv!</title><content type='html'>I'm going to &lt;a href="http://www.sosp-20.com/"&gt;SOSP&lt;/a&gt;. I plan to be blogging the ever-living heck out of that mutha. I've never been to the UK before, so expect some amount of touristic, bewildered-Yank-abroad prose to boot.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-112993074482923195?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/112993074482923195/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=112993074482923195' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112993074482923195'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112993074482923195'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/cor-blimey-guv.html' title='Cor Blimey, Guv!'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-112991257350096824</id><published>2005-10-21T09:24:00.000-07:00</published><updated>2005-10-21T09:36:13.506-07:00</updated><title type='text'>VMware Makes VM "Player" App Free</title><content type='html'>My employer is going to give away a &lt;a href="http://www.vmware.com/"&gt;free application for running VMware virtual machines&lt;/a&gt;. &lt;a href="http://it.slashdot.org/article.pl?sid=05/10/20/2227225&amp;tid=126&amp;amp;tid=185&amp;amp;tid=218"&gt;Here's&lt;/a&gt; Slashdot's reaction, which seems broadly positive. I think if you're a user or developer of a minority OS, this has to be an exciting turn of events. VMware virtual machines are a much, much more attractive delivery vehicle for new OS'es than ISO images. If I'm some Swedish grad student with a hobby OS, I probably am hosting a web page with instructions like:&lt;ol&gt;&lt;li&gt;Download this ISO image.&lt;/li&gt;&lt;li&gt;Burn it to CD-ROM.&lt;/li&gt;&lt;li&gt;Blow the mind of some poor computer sitting in the corner.&lt;/li&gt;&lt;li&gt;Don't forget to back up! Oh, wait, is it too late for that?&lt;/li&gt;&lt;/ol&gt; Users are much more likely to give it a shot if you just download and double-click a VM image: no rebooting, no burning, no fuss, no muss. I certainly would never have tried &lt;a href="http://www.ubuntulinux.org/"&gt;Ubuntu&lt;/a&gt;, or &lt;a href="http://www.sun.com"&gt;Solaris 10&lt;/a&gt; were it not for the hygienic nature of VM-based installs.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-112991257350096824?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/112991257350096824/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=112991257350096824' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112991257350096824'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112991257350096824'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/vmware-makes-vm-player-app-free.html' title='VMware Makes VM &quot;Player&quot; App Free'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-112958810672036379</id><published>2005-10-17T14:29:00.000-07:00</published><updated>2005-10-17T15:30:39.800-07:00</updated><title type='text'>UPenn Course on Virtualization</title><content type='html'>Zachary Ives, E Christopher Lewis, and Milo Martin are teaching a survey &lt;a href="http://www.cis.upenn.edu/%7Ecis700-6/04f/"&gt;course on machine virtualization&lt;/a&gt;. The paper collection works its way up from a worthwhile &lt;a href="http://www.cis.upenn.edu/%7Ecis700-6/04f/papers/smith-vm-overview.pdf"&gt;introductory material&lt;/a&gt; ( J. E. Smith and Ravi Nair) all the way up to some &lt;a href="http://www.cis.upenn.edu/%7Ecis700-6/04f/papers/levis-mate.pdf"&gt;true exotica&lt;/a&gt; (Phil Levis and  David Culler: hi, Phil!).&lt;br /&gt;&lt;br /&gt;When I started working at VMware in 2000, I was coming straight from &lt;a href="http://www.cs.brown.edu"&gt;undergraduate education&lt;/a&gt; and a brief stint as a &lt;a href="http://www.cse.ogi.edu"&gt;research assistant&lt;/a&gt;. At that time, virtual machines were very much at the fringes of academic interest. Each year, with every passing conference, virtualization has become hotter and hotter. I admit, at this point, that virtualization has probably become a bit of a fad; people apply the term "virtualization," or "virtual machine," to software constructs that could more easily be construed as &lt;a href="http://www.cbbrowne.com/info/microkernel.html"&gt;microkernels&lt;/a&gt;, or APIs, or libraries, or &lt;a href="http://gd.tuwien.ac.at/study/foldoc/foldoc.cgi?P-code"&gt;P-code&lt;/a&gt;, or what have you, because those ideas seem old and busted, while "virtualization" is the new hotness. Our time in the sun will pass, and some of those papers will, in time, look just as head-scratchingly weird as some of the farther-out exokernel papers from the late '90's. Still, it's been really gratifying to see the level of mainstream interest in an idea that's always fascinated me. I'd like to think that &lt;a href="http://www.vmware.com"&gt;my work&lt;/a&gt; has, in some small way, contributed to this upswell in interest in virtualization. By showing that full-system virtualization could be practical and efficient, even in a &lt;a href="http://www.usenix.org/publications/library/proceedings/sec2000/full_papers/robin/robin_html/"&gt;hostile environment&lt;/a&gt;, I think VMware helped point the way to this floodgate of interesting ideas.&lt;br /&gt;&lt;br /&gt;Lest I let my head get too big: &lt;a href="http://www.beagle-ears.com/lars/engineer/comphist/ibm360.htm"&gt;IBM pretty much did all this while my generation was but a gleam in our fathers' eyes&lt;/a&gt;. Credit where it's due...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-112958810672036379?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/112958810672036379/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=112958810672036379' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112958810672036379'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112958810672036379'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/upenn-course-on-virtualization.html' title='UPenn Course on Virtualization'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-112924127782270207</id><published>2005-10-13T15:03:00.000-07:00</published><updated>2005-10-19T10:46:33.760-07:00</updated><title type='text'>Linux NMIs on Intel 64-bit Hardware</title><content type='html'>&lt;span style="font-size:130%;"&gt;Why are NMIs cool?&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;If you are running x86_64 Linux 2.6.x, grep for "NMI" in /proc/interrupts. This line exports a running tally of &lt;a href="http://www.sandpile.org/ia32/inter.htm"&gt;"non-maskable interrupts"&lt;/a&gt; on each CPU since system boot. Just what are these NMI thingies? What is Linux doing with them?&lt;br /&gt;&lt;br /&gt;In the x86, "non-maskable interrupts" differ from regular old IRQs not so much in their maskability (they're pretty much maskable, just not by the same methods typically used for IRQs), but in their source (they are signalled to the CPU via a different line than IRQs) and semantics.&lt;br /&gt;&lt;br /&gt;The architectural purpose for NMIs is to serve as a sort of "meta-interrupt;" they're interrupts that can interrupt interrupt handlers. This may sound ridiculous initially, but for a kernel developer, judicious use of NMIs makes it possible to port some of the luxuries of user-level development to the kernel. Consider, e.g., profiling. User-level apps typically use SIGPROF, which in turn is driven by the kernel's timer interrupt handler. But what if you're a kernel developer concerned with the performance of the &lt;a href="http://cvs.opensolaris.org/source/search?q=&amp;defs=clock&amp;amp;refs=&amp;path=&amp;amp;hist="&gt;timer&lt;/a&gt; &lt;a href="http://lxr.linux.no/ident?a=x86_64&amp;i=do_timer"&gt;interrupt&lt;/a&gt; &lt;a href="http://fxr.watson.org/fxr/ident?i=hardclock"&gt;handler&lt;/a&gt; itself?&lt;br /&gt;&lt;br /&gt;NMIs provide one solution; by setting up periodic NMIs, and gathering execution samples in the NMI handler, you can peer into the performance of kernel critical sections that run with disabled interrupts. We've used this technique to good effect to study the performance of VMware's virtual machine monitor. The &lt;a href="http://oprofile.sourceforge.net/news/"&gt;oprofile&lt;/a&gt; system-wide profiler on Linux leverages the same technique.&lt;br /&gt;&lt;br /&gt;Another important application for NMIs is best-effort deadlock detection; an NMI "watchdog" runs perioically and looks for signs of forward progress (e.g., those counts of interrupts in /proc/interrupts rolling forward) has a decent chance of detecting most "hard" kernel hangs. 9 times out of 10, an NMI handler that detects a wedged system can't do much of use for the user. The system will crash, and often do so just as hard as if there were no NMI handler present; however, perhaps it will dump &lt;a href="http://slacksite.com/solaris/crashdump.html"&gt;some sort of kernel &lt;/a&gt;&lt;a href="http://labmice.techtarget.com/troubleshooting/memorydumps.htm"&gt;core file&lt;/a&gt; that can be recovered after the inevitable reboot to aid kernel engineers in diagnosing the problem post-mortem. Even something as simple as &lt;a href="http://kerneltrap.org/node/3648"&gt;pretty-printing a register dump and stack-trace&lt;/a&gt; to the system console provides a world of improvement in debuggability over a mute, locked-up box.&lt;br /&gt;&lt;br /&gt;It's this last application that gets Linux excited. On x86_64, the Linux kernel defaults to building with an NMI watchdog enabled. If you cat /proc/interrupts on a 32-bit x86 system, you'll see the NMI line with a total of zero (unless you've compiled your own kernel with NMIs enabled). So, if NMIs are so nifty, why do we use them for x86_64, and not plain old i386? Good question. I'm not sure why the two architectures are treated differently. Perhaps because x86_64 is a bit more young, and the Linux kernel folks are more concerned with being able to debug hangs? Or perhaps there are architecture-specific differences in other parts of the kernel that make the watchdog less appealing for i386. I don't know.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-size:130%;"&gt;Too much of a good thing?&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;So, let's get back to that NMI line in your /proc/interrupts file. If you tap your fingers for a few seconds between inspections of this file, you'll notice the NMI total increasing. However, the rate at which it increases will be dependent on your underlying hardware. If you're running linux-x86_64 on AMD hardware, you'll notice those NMIs ticking up at about 1Hz. This is convenient for the intended purpose; once a second is plenty frequent to check for something as (hopefully) rare as a hard system lock-up.&lt;br /&gt;&lt;br /&gt;Now, try the same experiment with an Intel EM64T machine. You'll notice that the NMI interrupts are coming in much, much faster. If you do the math, you'll find they're coming in at 1000Hz, exactly the same rate as the timer interrupts. What gives? And why does Linux want 1000 times more of them on EM64T hardware than on AMD64 hardware?&lt;br /&gt;&lt;br /&gt;The answers are buried in &lt;a href="http://lxr.linux.no/ident?a=x86_64;i=nmi_watchdog_default"&gt;nmi.c:nmi_watchdog_default&lt;/a&gt;; for AMD64, the kernel uses on-chip performance counters as a source of NMIs, while for all other CPUs (namely, EM64T parts), it uses the timer interrupt. After an initial calibration phase, Linux throttles back the AMD NMIs to a rate of 1Hz. However, on Intel hardware, however, some unusual jiggery-pokey takes place in the legacy PIC and local APICs, so that the very same timer interrupt signal trickles into the kernel via two different routes: once as a normal interrupt, via the IOAPIC and the local APIC's intr pin, and again via the LINT0 line into each local APIC as an NMI. Since the signal generating the NMI is the timer signal, there's little Linux can do but run the NMI interrupt at the same frequency as the timer interrupt.&lt;br /&gt;&lt;br /&gt;This arrangement presents a couple of problems. From the point of view of NMI consumers like the aforementioned oprofile, this partially subverts the purpose of NMIs in the first place; by heavily correlating the NMI handler with the running of a particular chunk of kernel code (namely, the plain-jane timer interrupt handler), the distribution of kernel samples can be skewed. This could badly impact the effectiveness of profiling applications (the profile samples would tend to hit near the same place).&lt;br /&gt;&lt;br /&gt;There are also performance consequences to this use of the hardware. 64-bit Linux on Intel hardware performs worse than it has to. How much worse? Let's assume a typical P4 needs 1000 cycles at minimum to take an NMI, and execute an IRET instruction to return from it. Then, of course, the software presumably has some work to do, taking at least another 2000 cycles. (Yes, I'm pulling these figures from thin air, but I consider them lower bounds, given that the data and code for the NMI handler are most likely cool in the cache.) So, we've used up 3000 cycles 1000 times every second; on your 3GHz modern processor, that's about 0.1% of the processor's performance dedicated to checking for deadlocks. That figure might not sound damning, but when you consider the blood that kernel folks sweat trying to wring fractional percentages out of a single path, 0.1% shaved right off the top, independent of &lt;a href="http://home.wlu.edu/%7Ewhaleyt/classes/parallel/topics/amdahl.html"&gt;Amdahl's Law&lt;/a&gt; for just the price of a recompile is an absolute dream.&lt;br /&gt;&lt;br /&gt;Where do I come in? Well, this NMI overhead is even more pronounced when running atop VMware's virtual machine monitor. The probe effect of NMIs is magnified inside a virtual machine, since we typically must emulate the vectoring of the NMI through the virtual &lt;a href="http://ocw.mit.edu/OcwWeb/Electrical-Engineering-and-Computer-Science/6-828Fall2003/LectureNotes/detail/lec8.htm"&gt;IDT&lt;/a&gt; in software. But, what's worse, in &lt;a href="http://www.vmware.com/products/esx/vsmp.html"&gt;SMP VMs&lt;/a&gt;, the hardware path Linux is using to deliver NMIs introduces bottlenecks. The PIC and LINT0 line, which Linux uses to deliver NMIs on Intel hardware are (and are constrained by the architecture to be) system-wide global entities, shared by all virtual CPUs in the VM; to manipulate them 1000 times a second induces lots of synchronization-related overheads. (And no, armchair lock granularity second-guessers, there's not just a big "LINT0 lock" we're taking over and over again; it's a cute little lock-free algorithm, but at the end of the day, you can only get so cute before you do &lt;a href="http://www.seas.upenn.edu/%7Ecse371/ProcessorInfo/P4Architecture.pdf"&gt;more harm than good&lt;/a&gt;&lt;a&gt;.)&lt;br /&gt;&lt;br /&gt;You multiply these effects together (too many NMIs * NMI overheads in a VM * overheads of delivering NMIs via cross-VCPU hardware in a VM) and you end up with a trivially measurable effect on performance when running Linux in a &lt;/a&gt;&lt;a href="http://www.vmware.com/news/releases/64bit.html"&gt;64-bit VM&lt;/a&gt;. Unfortunately, those second two factors aren't going anywhere; NMIs will have a higher impact in a VM for the foreseeable future, as will using global interrupt hardware like the PIC and LINT0 line. In the long term, the only real improvements are Linux's to make. Linux could either make do with fewer NMIs, as it manages to do on AMD hardware, or use the NMIs via some processor-local hardware, (again, like the performance-counter-based AMD implementation). Luckily, these changes will have real benefits for physical machines, too. It's just the Right Thing (TM). Too bad I don't have enough copious spare time to send Linus a patch; perhaps some of those oft-cited &lt;a href="http://www.catb.org/%7Eesr/writings/cathedral-bazaar/cathedral-bazaar/ar01s04.html"&gt;eyeballs&lt;/a&gt; have pairs of hands to go with them?&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Update&lt;/b&gt;: Linux 2.6.12 fixed the NMI-storm-on-EM64T misbehavior chronicled here. Unfortunately, few distributions have picked up such a shiny, new kernel, so the weirdness documented above still affects the majority of users.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-112924127782270207?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/112924127782270207/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=112924127782270207' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112924127782270207'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112924127782270207'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/linux-nmis-on-intel-64-bit-hardware.html' title='Linux NMIs on Intel 64-bit Hardware'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-112914808577426676</id><published>2005-10-12T13:01:00.000-07:00</published><updated>2005-10-13T09:18:08.406-07:00</updated><title type='text'>The Surprising Endurance of Self-Modifying Code</title><content type='html'>I recently had the pleasure of meeting a &lt;a href="http://www.catb.org/retro/"&gt;retrocomputing enthusiast&lt;/a&gt;, who has asked me to respect his anonymity. For personal amusement, I'm going to call him "Phil." Phil has done some work on software systems that run old video games -- Ms. PacMan, Asteroids, that sort of thing. While these software systems are often called &lt;a href="http://www.emulator-zone.com/"&gt;"emulators"&lt;/a&gt;, most of the good ones are a fair bit more sophisticated than the simple pseudocode that comes to mind when the term "emulator" is thrown around:&lt;br /&gt;&lt;pre&gt;for (;;) {&lt;br /&gt;unsigned char opcode = memory[CPU-&gt;programConter];&lt;br /&gt;switch(opcode) {&lt;br /&gt;...&lt;br /&gt;}&lt;br /&gt;}&lt;/pre&gt;Many of these systems are binary translators of one form or another. They take your Ms. PacMan ROM image, and produce a translation of Ms. PacMan retargeted to run natively on your machine. Phil had designed and built such a system, and we talked about its internals at some length. After a while, it dawned on me that his system would not be able to handle &lt;a href="http://en.wikipedia.org/wiki/Self-modifying_code"&gt;self-modifying code&lt;/a&gt;, and I became convinced I was missing something. Surely, if you're running these incredibly hairy machine-language programs that rely on such intimate machine details as the &lt;a href="http://dr.ea.ms/c128hardwarebug.html"&gt;exact cycle counts of individual instructions&lt;/a&gt;, you'd run into lots of self-modifying code. If any emulator in the world has to get self-modifying code right, it would be an emulator for old video games, right? Right??!?&lt;br /&gt;&lt;br /&gt;But no, Phil confirmed that the system was completely broken in dealing with self-modifying code. Yet, his system had no problem running all sorts of old games.&lt;br /&gt;&lt;br /&gt;Why? In the &lt;a href="http://yarchive.net/comp/self_modify.html"&gt;lore of systems&lt;/a&gt;, self-modifying code is exactly the sort of bizaare space- and time-optimization that only makes sense in the semi-mythologically constrained environments of old computers. These games were extremely performance-critical, written in assembly language, under harrowing space constraints, often on 8-bit computers with a single general-purpose register. Yet they apparently didn't mutilate their program text by even a single byte.&lt;br /&gt;&lt;br /&gt;After watching me squirm for a while, Phil let me off the hook. These are console games; since these systems would only ever run a single game, the code lived in ROM. It would have been prohibitively expensive to provide enough RAM to copy the code out of ROM, so self-modifying code was, ironically, a luxury unavailable to many old-time assembly language video game hackers, the very group with which most people associate self-modifying code.&lt;br /&gt;&lt;br /&gt;Today, most developers regard self-modifying code as an occasionally interesting, but thankfully obsolete curiosity. After all, very little significant software is written in assembly anymore; even when it is, space-constraints are rarely what they used to be, and the performance argument would now go against self-modifying code, since it interferes with the instruction cache and pipeline on modern processors. Yet, if you peak under the hood of your running PC, today, in the year 2005, you'll find gobs of self-modifying code looking up at you. From &lt;a href="http://docs.sun.com/source/819-0489/dyn_link.html"&gt;dynamic linkers&lt;/a&gt; to &lt;a href="http://www.program-transformation.org/Transform/BinaryTranslationResearch"&gt;JVM/CLRs&lt;/a&gt;, to &lt;a href="http://packages.debian.org/unstable/utils/ltrace.html"&gt;various&lt;/a&gt; &lt;a href="http://http//sourceware.org/systemtap/kprobes/"&gt;system instrumentation frameworks&lt;/a&gt;, to debuggers, to profilers, on and on &lt;i&gt;ad infinitum&lt;/i&gt;, there's a whole heck of a lot of code getting rewritten in dribs and drabs on a modern system. So, whole-system monitors, like &lt;a href="http://www.vmware.com/"&gt;the one I work on&lt;/a&gt;, need to deal with self-modifying code correctly. In fact, code modification is so prevalent now that monitor engineers must worry not only about its correctness when running in a VM, but also its performance!&lt;br /&gt;&lt;br /&gt;So, the next time you're bored around the coffee machine, bend some of your colleagues' minds by asking them which system is running more self-modifying code: a Z80 running Ms. PacMan, or their Windows XP laptop. As a rule of thumb, the more modern the system, the more self-modifying code you'll find.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-112914808577426676?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/112914808577426676/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=112914808577426676' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112914808577426676'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112914808577426676'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/surprising-endurance-of-self-modifying.html' title='The Surprising Endurance of Self-Modifying Code'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-112901480207676372</id><published>2005-10-11T00:11:00.000-07:00</published><updated>2005-10-13T15:08:09.903-07:00</updated><title type='text'>Microsoft Changes Server Licensing in VMs</title><content type='html'>Microsoft plans to license windows on a &lt;a href="http://www.microsoft.com/presspass/features/2005/oct05/10-10virtualizationlicensing.mspx"&gt;per-running VM basis&lt;/a&gt;, rather than an absolute per-VM basis. On writing this, I'm not even sure what the latter means. When Callinicos contrasts the new licensing policy with the old, he says, "Instead of licensing every inactive or stored virtual instance of a Windows Server System product, customers can now create and store an unlimited number of instances, including those for back-up and recovery, and only pay for the maximum number of running instances at any given time." So, the old policy appears to be total madness: copy a virtual machine's disk file to a tape drive for backup, even if it happens automatically? Whoah, that's a brand new Windows installation! Better have a license for it!&lt;br /&gt;&lt;br /&gt;While this change is probably for the better, not all Windows-in-a-VM customers will be dancing for joy. In the same way virtualization was inflating Windows licensing costs for some folks, for others it was depressing those costs. E.g., if you have a single read-only disk file, shared via a network mount and simultaneously running on N physical machines, my (completely ignorant, so don't take this to the bank or anything) understanding is that under the old licensing rules, you would have needed only a single license. Now, you'll be ponying up for N licenses. I'm not saying this to make Microsoft seem like bad guys; it's perfectly fair for them to expect N licenses, since the customer in this case is essentially getting N installations of Windows. But, most press coverage of this announcement seems to be assuming it's a godsend for customers running Windows in VMs; like so many other things in life, the answer to the question, "Is this a good thing?", is, "It depends."&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-112901480207676372?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/112901480207676372/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=112901480207676372' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112901480207676372'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112901480207676372'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/microsoft-changes-server-licensing-in.html' title='Microsoft Changes Server Licensing in VMs'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-112900671342946879</id><published>2005-10-10T21:50:00.000-07:00</published><updated>2005-10-14T14:04:03.950-07:00</updated><title type='text'>More SystemTap Thoughts</title><content type='html'>I've read the &lt;a href="http://sourceware.org/systemtap/archpaper-0505.pdf"&gt;SystemTap architecture paper&lt;/a&gt;. My initial reactions, which might be muddied by misunderstandings, misreadings, general ignorance, etc.:&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Every script execution invokes the GCC toolchain to produce a kernel module, then loads that module, executes for a time, and unloads the module. This makes implementation more tractable, because the SystemTap folks don't have to write a different back-end for every CPU, nor do they have to define a little bytecode VM for user-level to communicate with the kernel, as DTrace did. However, this compile-link-load cycle may take a user-perceptible chunk of time, especially if a script is invoked repeatedly from some other script. Worrying about this sort of incremental friction might seem like premature optimization, but when you rely for runtime performance on a &lt;span style="font-style: italic;"&gt;big&lt;/span&gt; piece of software that is not optimized for runtime performance, such as the GCC compile/link cycle (which, after all, is optimized to produce fast binaries, not to produce binaries fast), you're throwing away a lot of flexibility right out of the gate.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;I'm not in love with the language. Like &lt;a href="http://docs.sun.com/app/docs/doc/817-6223"&gt;D&lt;/a&gt;, it uses C's expression syntax. However, unlike D, it doesn't use C's type syntax. This isn't just an inconvenience. D scripts can #include header files right out of a source tree, or the kernel, or wherever, and can use those types in a natural way. This can be very helpful when instrumenting a C application.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;On the other hand, when not instrumenting a C application, the architecture doesn't seem to anticipate external sources of probe points. They discuss being able to probe user-level applications, but only in terms of tracing specific program counters. This doesn't always make sense. If, e.g., the target application is a scheme interpreter, the programmer will want to interact with his program's control flow in terms of source-level function entry/exit, rather than random program counters within the interpreter. While the core functionality of SystemTap can be extended via "TapSets," it sounds like these tapsets are stuck on the wrong side of the application being probed to do this sort of thing well. (I.e., instead of the scheme interpreter publishing a semantic interface to its internals, the TapSet has to contain enough knowledge about the scheme interpreter to reverse engineer its current state.)&lt;br /&gt;&lt;/li&gt;&lt;/ol&gt;This last point, if I understand it right, is really unfortunate. It basically limits SystemTap's full powers to the kernel; applications can only be instrumented at the machine-language level. Some of the more powerfully convincing DTrace demos involve following an execution path all the way from &lt;a href="http://blogs.sun.com/roller/page/bmc/20050821"&gt;application-level&lt;/a&gt; into the nittiest-grittiest kernel guts. The ability to telescope from the ethereally high level of a scripted language all the way down to the kernel grovelling around in the APIC and back again is one of the more exciting things about DTrace. I hope the SystemTap folks haven't given up on achieving this for Linux.&lt;br /&gt;&lt;br /&gt;Or, of course, maybe I'm just not getting it. Perhaps some SystemTappers out there can set me straight?&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-112900671342946879?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/112900671342946879/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=112900671342946879' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112900671342946879'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112900671342946879'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/more-systemtap-thoughts.html' title='More SystemTap Thoughts'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-112899198853303946</id><published>2005-10-10T17:46:00.000-07:00</published><updated>2005-10-14T15:15:08.206-07:00</updated><title type='text'>SystemTap -- DTrace for Linux?</title><content type='html'>&lt;a href="http://www.sun.com/bigadmin/content/dtrace/"&gt;DTrace&lt;/a&gt; absolutely rocks. It is easily the most powerful general-purpose facility to come along in a long, long while. Skeptical? Give &lt;a href="http://blogs.sun.com/roller/resources/ahl/dtrace_course.2005.8.18.pdf"&gt;Adam's DTrace Bootcamp&lt;/a&gt; a quick glance. It's worth your time.&lt;br /&gt;&lt;br /&gt;To badly summarize, DTrace makes it painless and safe to carry out surprisingly deep and wide experiments on a running system, from TLB miss code all the way up to Java method invocations. The improvement in system visibility that DTrace represents is comparable to the improvement of a source-level debugger over printf. I'm serious. If you don't believe me, &lt;a href="http://www.opensolaris.org/"&gt;give it a try&lt;/a&gt;. (Full disclosure: I went to school with &lt;a href="http://blogs.sun.com/bmc"&gt;DTrace's&lt;/a&gt; &lt;a href="http://blogs.sun.com/mws"&gt;founding&lt;/a&gt; &lt;a href="http://blogs.sun.com/ahl"&gt;trio&lt;/a&gt;, but believe me, DTrace is so wig-flippingly great that I'd be just as effusive if I didn't know &lt;a href="http://blogs.sun.com/ahl"&gt;Adam&lt;/a&gt; from &lt;a href="http://www.creationism.org/"&gt;Adam&lt;/a&gt;).&lt;br /&gt;&lt;br /&gt;The only unfortunate thing about DTrace is that it is part of &lt;a href="http://www.sun.com/software/solaris/"&gt;Solaris&lt;/a&gt;. Nothing against Solaris, mind you. Most of my colleagues regard me as a Solaris zealot, in fact. It's where I came of age as a programmer, and when I have the all too rare pleasure of using it, Solaris still feels like home (/usr/proc/bin!), even after five years of continuous Linux usage.&lt;br /&gt;&lt;br /&gt;But let's not kid ourselves. Solaris is in trouble. Not technically; I still believe it's the gold standard for UNIX excellence in design and implementation, and I'll take the bait from any Linux zealot who'd like to argue this. No, Solaris is troubled because it has been losing users. In spite of its recent &lt;a href="http://www.opensolaris.org/"&gt;reincarnation&lt;/a&gt; as opensource software, people still perceive Solaris as Sun's house UNIX. And, for those who've been in North Korea for the last five years, Sun is &lt;a href="http://quotes.fool.com/custom/fool/html-financials.asp?currticker=sunw&amp;symbols=sunw"&gt;not a fiscally healthy organism&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;So, I was pleased today to learn that RedHat, IBM and Intel are doing the only sensible thing,  namely &lt;a href="http://sourceware.org/systemtap/"&gt;ripping off DTrace with total abandon&lt;/a&gt;. More power to them; reimplementing good ideas from industry has a long tradition in OSS and Linux in particular. There are, of course, some differences between DTrace and SystemTap; I haven't gotten deeply enough into the &lt;a href="http://sourceware.org/systemtap/archpaper-0505.pdf"&gt;available SystemTap documentation&lt;/a&gt; to say just what they are.&lt;br /&gt;&lt;br /&gt;Godspeed you, SystemTap! I hope to be using something with all the convenience and power of DTrace on a viable operating system sooner rather than later! In the meantime, I'll fire up my gentoo VM, pull down the CVS sources, and cross my fingers that I can get this all to work...&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-112899198853303946?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/112899198853303946/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=112899198853303946' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112899198853303946'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112899198853303946'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/systemtap-dtrace-for-linux.html' title='SystemTap -- DTrace for Linux?'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-17691667.post-112897137745851911</id><published>2005-10-10T11:59:00.000-07:00</published><updated>2005-10-13T08:31:39.963-07:00</updated><title type='text'>Salutations</title><content type='html'>Greetings, imaginary audience! My name is Keith Adams. I'm an engineer in &lt;a href="http://www.vmware.com/"&gt;VMware's&lt;/a&gt; Virtual Machine Monitor group. I'll be writing here about the x86, operating systems, the hardware/software interface, virtualization, software development in general, etc.&lt;br /&gt;&lt;br /&gt;I've been at VMware since 2000, when I graduated from &lt;a href="http://www.cs.brown.edu/"&gt;Brown University's CS Department&lt;/a&gt;. Lately, I've been preoccupied with the long list of monitor features in &lt;a href="http://www.vmware.com/products/beta/ws/"&gt;VMware Workstation 5.5&lt;/a&gt;: 64-bit, support for &lt;a href="http://www.intel.com/technology/computing/vptech/"&gt;Intel's VT&lt;/a&gt;, hosted SMP support, etc.&lt;div class="blogger-post-footer"&gt;Keith Adams slings code for a living. This "blog" thing is a sideline, not some sort of officially sanctioned PR stunt. So, please don't mistake his opinions, biases,
ignorance, or taste in clothing with those of Facebook.&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/17691667-112897137745851911?l=x86vmm.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://x86vmm.blogspot.com/feeds/112897137745851911/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=17691667&amp;postID=112897137745851911' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112897137745851911'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/17691667/posts/default/112897137745851911'/><link rel='alternate' type='text/html' href='http://x86vmm.blogspot.com/2005/10/salutations.html' title='Salutations'/><author><name>Keith Adams</name><uri>http://www.blogger.com/profile/11187291538765358570</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='24' src='http://1.bp.blogspot.com/_tYRrPJ_bslg/SlzAweExb1I/AAAAAAAAABU/gfvM60mEz8o/S220/Photo+1.jpg'/></author><thr:total>0</thr:total></entry></feed>
