"Mature" tech stocks often outperform their higher-growth peers during market downturns, since they generally have wider moats, lower valuations, and reward patient investors with buybacks and dividends. Yet some mature tech stocks are clearly better picks than others.

For example, IBM (NYSE:IBM) looks like a cheap mature tech stock at just nine times forward earnings with a forward dividend yield of 5.3%. However, Big Blue is also struggling to grow its revenue as the weakness of its legacy businesses overwhelm its higher-growth ones. That's why Warren Buffett's Berkshire Hathaway, once a top IBM investor, sold all its shares earlier this year.

Bull and bear figurines.

Image source: Getty Images.

Meanwhile, Microsoft (NASDAQ:MSFT) initially looks pricier than IBM, with a higher forward P/E of 22 and a lower forward yield of 1.8%. Yet that premium is largely justified, since Microsoft executed a remarkable turnaround under CEO Satya Nadella, who pivoted the tech giant away from its legacy businesses toward higher-growth cloud services. Today, we'll examine why Microsoft is a much better all-around investment than IBM.

Superior revenue growth

IBM CEO Ginni Rometty, who took the helm in 2012, aggressively expanded Big Blue's higher-growth "strategic imperatives" (cloud, analytics, mobile, security, and social services) to offset its dependence on its slower-growth business hardware, software, and IT services units. That strategy helped IBM grow its revenue for the first time in 23 quarters earlier this year, but the comeback was short-lived:

 

Q4 2017

Q1 2018

Q2 2018

Q3 2018

Revenue

$22.5 billion

$19.1 billion

$20.0 billion

$18.8 billion

YOY growth (decline)

4%

5%

4%

(2%)

IBM's sales growth. Source: IBM quarterly reports. YOY = year over year.

The growth of IBM's closely watched strategic imperatives decelerated last quarter. Revenue from cognitive solutions (which comes from next-gen platforms like Watson) fell annually on a constant-currency basis, and its technology services & cloud services revenue stayed flat.

Those ugly numbers can be attributed to tough competition in the cloud and AI services from Amazon.com and Microsoft, which currently lead the public cloud-services market. IBM recently decided to acquire enterprise software provider Red Hat (NYSE:RHT) to get its growth back on track, but the jury's still out on that massive deal.

An IT professional checks a tablet.

Image source: Getty Images.

Microsoft doesn't face the same top-line challenges as IBM does. Under Nadella, Microsoft transformed Windows and Office into cloud-based services, and leveraged its enterprise presence to expand its cloud platform Azure and its customer-relationship management platform Dynamics.

To stay relevant in the mobile market, Microsoft launched its mobile apps for iOS and Android, and pivoted its hardware unit away from first-party smartphones to focus on the production of Xbox consoles and Surface devices.

Those bold moves enabled Microsoft to offset the slower growth of its older businesses with the stronger growth of its newer ones -- the same goal that IBM failed to accomplish. That's why Microsoft's sales growth accelerated as IBM's growth decelerated:

 

Q2 2018

Q3 2018

Q4 2018

Q1 2019

Revenue

$28.9 billion

$26.8 billion

$30.1 billion

$29.1 billion

YOY growth

12%

16%

17%

19%

Microsoft's sales growth. Source: Microsoft quarterly reports.

Analysts currently expect IBM's revenue growth to stay roughly flat for the next two years, but that figure will likely be updated after the Red Hat acquisition closes. Microsoft's revenue is expected to rise 13% this year and 11% next year.

Superior margins and earnings growth

IBM has more lower-margin hardware divisions (like mainframes) than Microsoft, which generates most of its revenue from software. That's why IBM's gross margin is consistently lower than Microsoft's.

IBM Gross Profit Margin (TTM) Chart

IBM Gross Profit Margin (TTM) data by YCharts. TTM = trailing 12 months.

Microsoft also reports higher operating margins, since it doesn't acquire, divest, and shuffle around as many business units as IBM does.

IBM Operating Margin (TTM) Chart

IBM Operating Margin (TTM) data by YCharts.

As a result, analysts expect IBM's earnings to rise just 1% this year and next year. Microsoft's earnings are expected to rise 14% this year (excluding the tax reform and restructuring charges from last year) and another 13% next year.

You get what you pay for...

Based on those estimates, Microsoft's stock deserves a higher valuation than IBM's, and it looks like the more promising investment. IBM's stock certainly looks cheaper, but that discount is also justified since its growth engines are running out of gas and it's relying heavily on big purchases like Red Hat to remain relevant.

 

John Mackey, CEO of Whole Foods Market, an Amazon subsidiary, is a member of The Motley Fool's board of directors. Teresa Kersten, an employee of LinkedIn, a Microsoft subsidiary, is a member of The Motley Fool's board of directors. Leo Sun owns shares of Amazon. The Motley Fool owns shares of and recommends Amazon and Berkshire Hathaway (B shares). The Motley Fool owns shares of Microsoft. The Motley Fool has a disclosure policy.