Microsoft was expected to announce a big layoff as a result of its big acquisition of Nokia. What wasn't expected was the enormous number of employees that Microsoft would cut: 18,000 total over six months with 13,000 let go today.

When you do the math, you see that not all of the layoffs are coming from Nokia. Far from it.

CEO Satya Nadella said he is slashing 12,500 people from Nokia (half the Nokia workforce it acquired). That means Nadella has weaved in a 5,500 layoff of Microsoft employees. That's almost as big as the 5,800-employee layoff in 2009, previously the company's biggest.

Nadella will cut a lot of testing engineers, Foley reports, adding the role of testing to that of product manager. On Tuesday, at the Fortune Brainstorm conference, Nadella said that the product manager-engineering role would be changed.

According to Bishop and ZDNet's Mary Jo Foley, the biggest area being hit today is the Windows group: Microsoft’s Operating Systems division.

This unit was still using the "Functional Organization" structure put in place by former Windows boss Steven Sinofsky, Foley reports, in which top managers have a lot of control. Blogger Richard Veryard, described it as, "Soviet central-planning, where tight control from the top squeezes out innovative thinking from below."

Nadella obviously also needs to fix Windows 8 in a hurry and roll out a version of Windows that people love.

Microsoft sales and marketing teams are also being hit. This also shouldn't be a huge surprise. When Ballmer structured the Nokia deal, Microsoft said there would be "marketing/services consolidation."

But it appears that cuts in this unit go beyond Nokia. COO Kevin Turner told his sales team that there would be cuts of sales, marketing and services folks, Foley reports, though sources tell us that the ax might fall more heavily on contractors than full-time employees. As we previously reported, insiders told us shortly after Nadella took the CEO job that the sales team at Microsoft needed an overhaul.

Less hard hit: the company’s cloud and enterprise and the online services divisions, Nadella's baby. He ran these teams before he was promoted to CEO and consequently, those units had already started to reorg their engineering processes, Bishop reports. They also the key to his "productivity and platforms" vision of where to take the company.