Running heavy multitasking workloads on advanced multicore hardware, Windows 7 finally surpasses leaner Windows XP Credit: Wachiwit / Shutterstock Back in January 2009, I published the first half of my groundbreaking study on multicore support under Microsoft Windows. The article featured an in-depth look at multicore/multiprocessor performance under Windows 7, Vista, and XP, including extensive benchmark data for each platform. At the time, I concluded that Windows 7 — and to a lesser degree, Vista — delivered better scalability moving from single-core to dual- and quad-core architectures. However, I also noted that this advantage was not yet sufficient to allow Windows 7 to overtake the leaner, more efficient XP under heavy workloads. What a difference a year makes! After revisiting my earlier test scenarios using a newer, Nehalem-based workstation (the HP Z800 with dual quad-core Xeon 5500-series CPUs), I’m pleased to report that Windows 7 not only closes the gap with Windows XP, but blows right past it, delivering results that are 47 to 178 percent faster overall. Moreover, Windows 7 shows far superior scalability — by a factor of more than 3.5 — when moving from a single quad-core CPU (Core 2 Duo Extreme QX9300) to the dual quad-core, Hyper-Threading Xeons in our newer Z800 test bed. In my earlier article, I posited that, as multicore PCs evolve and the number of cores increases, the superior scalability of the Windows 7 kernel would eventually overcome Windows XP in terms of raw application throughput. But I had figured this inflection point to be well into the many-core future and suggested we would be lucky to see Windows 7 overtaking XP before 16- or 32-core CPUs were commonplace. It’s now clear that my prediction was off by a factor of 3 or 4, and that the point where a combination of multicore hardware and kernel tuning wins out over the simpler, brute-force approach of the XP kernel has already been reached. Simply put, Windows 7 is significantly faster than Windows XP when running heavy, multitasking workloads on advanced, multicore hardware. And when considered in light of current trends in PC hardware design and multicore road maps, this advantage should be enough to sway even the most ardent fence sitters to finally jump on the Windows 7 bandwagon. Factor this Several factors conspire to give Windows 7 the edge on multicore. For example, the introduction of Non-Uniform Memory Access (NUMA)-based multiprocessor systems — like the HP Z800 — are allowing for greater compute engine density in a commodity form factor. By combining multiple cores per CPU with multiple CPU sockets, PC vendors can deliver levels of scalability previously reserved for high-end servers, and they can do so at price points that would have been impossible to achieve using traditional, discrete processors. Another factor is the transition away from the Front Side Bus architecture that has been a staple of Intel-based PC and workstation designs for years. In its place, Quick Path Interconnect (QPI) — Intel’s answer to AMD’s HyperTransport — places a memory controller on the same die as the CPU, allowing the latter to directly access physical memory. The net result is much faster access to memory that is local to a particular CPU core and, when combined with a Level 3 cache, improved performance for juggling workloads across multiple CPUs. Together, the NUMA and QPI advancements have served to drive the Intel architecture forward. However, they would both be for naught without support from the OS. Which is why the extensive multicore tuning that went into the Windows 7 kernel is so important — without it, Windows users would be unable to leverage the performance-enhancing features of the latest Intel (and AMD) CPUs. In other words, to make the most of today’s smarter CPUs, you need a smarter OS. (See also: “How Intel Nehalem processors and Windows 7 work together.”) Get smart Windows XP is a great operating system. It has proven itself over nearly a decade of continuous use. However, when compared against Windows 7’s sophisticated multicore support, XP is a bit of a dim bulb. The XP kernel still adheres to the Symmetric Multiprocessing (SMP) worldview of pre-millennial Windows NT, and this hamstrings the OS when dealing with modern, NUMA-based hardware. It’s like the old joke about the man with only a hammer on his tool belt: To XP, every multiprocessing problem looks like a nail. Windows 7, by contrast, has a more nuanced worldview. For example, it understands the difference between a discrete CPU and multiple cores within a single CPU. Windows 7 also has a basic grasp of NUMA design principles — specifically, how groups of cores within a single processor should be treated as a functional node and how processor affinity can directly affect application performance in a multiprocessor environment. Together, these newfound processor smarts allow the Windows 7 kernel to better manage the underlying hardware fabric, taking into account logical and physical CPU layout as it schedules threads and allocates memory. Windows on multicore: OfficeBench results (dual core) Database Messaging workflow Windows XP 1.57 seconds 5.94 seconds Windows Vista 3.02 seconds 11.77 seconds Windows 7 3.42 seconds 8.18 seconds Windows on multicore: OfficeBench results (quad core) Database Messaging workflow Windows XP 0.43 second 4.49 seconds Windows Vista 0.51 second 7.45 seconds Windows 7 0.51 second 7.14 seconds Windows on multicore: OfficeBench results (eight cores) Database Messaging workflow Windows XP 0.25 second 4.33 seconds Windows Vista 0.21 second 2.03 seconds Windows 7 0.17 second 1.56 seconds Of course, the proof, as they say, is in the pudding. And while Microsoft stated from the beginning that Windows 7 would be better able to leverage the new generation of multicore systems than Windows XP, validating this claim has proven to be easier said than done. For starters, few current-generation PCs sport the necessary combination of cores and NUMA-like processor interconnects that allow Windows 7 to strut its multicore stuff. In fact, the benchmarks I ran in support of my previous article on the subject showed Windows 7 falling well behind XP on everything from a dual-core desktop PC to a quad-core mobile workstation — hence, my conclusion that Windows 7’s advantages on multicore wouldn’t be a factor until 16- or 32-core systems became commonplace. Fortunately, I now know better. Not only is Windows 7 well positioned to leverage the coming generation of many-core PCs, it’s capable of delivering tangible advantages today, using current-generation mainstream (though expensive) hardware. My revised benchmark tests, which include data from the aforementioned 8-core (16-thread) Z800 workstation, show Windows 7 blowing past XP on a mixed, multiprocess workload consisting of a SQL database (47 percent faster), MAPI workflow (178 percent faster), and multimedia playback tasks. (See “How I tested” for details.) [ See “Windows 7 on multicore: How much faster?” ] When viewed in terms of percentage scalability, moving from 4 cores on a single CPU to 8 cores spread across two CPUs yielded a much greater improvement under Windows 7 than Windows XP. The SQL database task showed an overall improvement of 72 percent under XP versus a 200 percent boost under Windows 7. Likewise, the MAPI workflow task, which showed negligible (4 percent) improvement under XP, jumped by nearly 360 percent when moving from 4 to 8 cores. All in all, it’s a significant victory for Windows 7, one I attribute to the newer OS’ more refined support for multicore CPUs, simultaneous multithreading (SMT, aka Hyper-Threading), and NUMA. That Windows 7 was able to accomplish this much at the 8-core level — overtaking XP, then pulling away by a wide margin — came as a pleasant surprise, one that deepened my respect for the Windows kernel development team. These guys really know how to wring the most of the underlying hardware platform. Windows on multicore: Scalability (2 to 4 cores) Database Messaging workflow Windows XP 265 percent 32 percent Windows Vista 492 percent 58 percent Windows 7 571 percent 15 percent Windows on multicore: Scalability (4 to 8 cores) Database Messaging workflow Windows XP 72 percent 4 percent Windows Vista 143 percent 267 percent Windows 7 200 percent 358 percent The future Clearly, power users who rely on multiprocessor workstations can reap immediate benefits from migrating to Windows 7. However, the list of potential beneficiaries doesn’t necessarily stop there. Current-generation Core i7-based PCs and laptops will also reap benefits from Windows 7’s more intelligent management of code/cache boundary alignment and similar multicore-specific tweaks. And while the scalability advantages of Windows 7 may not yet allow it to overtake the lighter, simpler Windows XP on dual- or quad-core PCs, it does help to mitigate the significantly higher demands that the new OS places on PC hardware. All of those advantages that make Windows 7 so compelling — the improved security, manageability, and usability features — come at a cost in terms of additional CPU cycles consumed by their respective background services. Thus, making the most of what processor bandwidth is available takes on a new urgency as the layers of software separating hardware from operator continue to accumulate. But no matter how you slice the results, Windows 7 — or at least its underlying kernel architecture — is clearly the future of Intel-based PC computing. This will remain true even if Microsoft decides to gut Windows and do away with all the layers above the NT Executive (MinWin taken to the extreme). The fact is that Microsoft has built a robust, highly scalable, multicore-aware OS foundation with Windows 7, and it should continue to serve Redmond well as it maps out future versions of the OS. Related articles Windows 7’s real killer feature Windows 7 on multicore: How much faster? How Intel Nehalem processors and Windows 7 work together The generation gap: Windows on multicore Windows 7 RTM: The revenge of Windows Vista PC vs. Mac deathmatch: Snow Leopard beats Windows 7 This story, “Windows 7’s killer feature: Windows on multicore, redux,” was originally published at InfoWorld.com. Software DevelopmentTechnology IndustrySmall and Medium Business