Advertisement
Advertisement

新足迹

 找回密码
 注册
新足迹 门户 IT专业论坛 查看内容

巨作:Windows 是怎样开发出来的

2011-2-28 22:50| 发布者: dalaohu | 查看: 1657| 原文链接

Microsoft worker Richard G Russell has revealed exactly how the company builds Windows and what it’s like to work at the software giant.

Russell penned a blog post on Sunday entitled “Working at Microsoft – Day to Day Coding“. The post details developer life at Microsoft, right down to the fact that developers use quad core 64-bit systems with 8GB RAM, fast hard drives, gaming quality graphics adapter and at least two large monitors. “Many people have three monitors, some have four. We’re moving to SSD’s,” writes Russell.

Russell also details how Windows team members code at Microsoft. “Teams are free to code in their own style. By style here I mean typographic style – where curly braces go, tab indent size, where spaces go, comment format: things that have no semantic impact. There is no draconian common coding style mindlessly forced on everyone,” he reveals.

Perhaps the most interesting part of Russell’s post is the thorough detail of Microsoft’s build process for Windows. Russell says that most Windows workers run a current Windows build. “Daily builds are almost always very stable and useable,” according to Russell. “Builds usually start about 5:00pm though teams can set their own defaults, or change it for a day. This means that a fully installable version of Windows is built from source every single night – though we pause for holidays, and sometimes if there are snow days. Builds are ready for use when we arrive for work the next day. We build four ‘flavors’ of each branch every night; x86-optimized, x64-optimized, x86-debug, x64-debug.”

Russell also details the three levels of Windows builds. “The entire build environment is checked into source depot – not just the source code. This includes the compiler, linker and other build tools. We can re-build any version of any Windows product going back to XP SP1 very easily.” Russell also shares a diagram of how code is compiled and checked into the source depot:




There are many ways to use branching, we mange them as a tree.   The WinMAIN branch is at the top.  “Official” builds of Windows are built from WinMAIN. This includes the RTM, CTP and BETA versions.

Underneath WinMAIN are aggregation branches. These correspond to large team’s of developers.    We call these L1 branches.

L2 branches corresponds to teams – generally 60 to 90 people including developers, testers and program managers.

L3 branches correspond to feature crews.  A crew is usually 3 to 10 people that collectively own a feature, or set of features. My team of six developers, four testers and three PM’s  (in addtion to our three leads, development, PM and test) has its own L3 branch.

WinMAIN, L1, L2 and L3 branches are all managed by a central build team.  There are dedicated build servers for each branch.  Crews can create L4 (or even L5) branches, but they must mange these themselves (its not difficult or time consuming).

Russell is a self described hiring manager at Microsoft, in the Windows organization, having worked at the company for over seven years
Advertisement
Advertisement


Advertisement
Advertisement
返回顶部