HP (HPQ -0.46%) and Hewlett Packard Enterprise split into two separate companies on Nov. 1, 2015. HP retained the company's PC and printing businesses, while HPE took over its enterprise hardware and software businesses.

If you had invested $2,000 in HP when the two stocks started trading separately on Nov. 2, your investment would be worth about $3,711 -- or $4,791 after factoring in its reinvested dividends. By comparison, a $2,000 investment in an S&P 500 index fund (with reinvested dividends) would have grown to roughly $4,721.

Let's see why HP generated a bigger total return than the broader market -- and if it can continue to grow in this challenging market for PC makers.

A gamer plays a video game on a high-end gaming PC.

Image source: Getty Images.

HP's growth has been choppy since its split from HPE

Between fiscal 2016 and fiscal 2022 (which ended last October), HP's annual revenue grew at a compound annual growth rate (CAGR) of 5%. However, its adjusted earnings per share rose at a CAGR of 17% as it bought back over 40% of its diluted shares.

HP's revenue rose 8% in fiscal 2017 and 12% in fiscal 2018 even as the broader PC market suffered year-over-year declines in total shipments. HP's PC business remained resilient for two reasons: It grew its market share at the expense of its smaller competitors, and companies continued to upgrade their PCs even as consumers stuck with their aging PCs or spent more time on mobile and hybrid devices. Its printing business also continued to grow at a steady rate.

HPQ Revenue (TTM) Chart

Data source: YCharts

HP's revenue grew less than 1% in fiscal 2019 as it lapped those gains, then dipped 4% in fiscal 2020 as the pandemic disrupted supply chains and prevented its commercial customers from buying new PCs and printers. But in fiscal 2021, its revenue rose 12% as more consumers upgraded their home printers and bought new PCs for remote work, online classes, and high-end gaming. Its commercial business also slowly recovered as companies upgraded their aging systems again.

HP's cyclical slowdown isn't over yet

At the end of fiscal 2021, the bulls likely expected the post-pandemic recovery of HP's commercial businesses to offset the tough year-over-year comparisons for its consumer businesses. Unfortunately, inflation, rising interest rates, and other macro headwinds simultaneously throttled the growth of both its commercial and consumer businesses.

As a result, HP's revenue dipped nearly 1% in fiscal 2022, and analysts expect another 15% drop in fiscal 2023. According to IDC, global PC shipments could decline 14% in calendar 2023 before finally rising 4% in calendar 2024.

That longer-than-expected slowdown seemingly drove Warren Buffett's Berkshire Hathaway -- which became HP's largest single shareholder over the past year -- to sell more than 12% of its stake over the past month. That's worrisome since Buffett generally loves value plays and HP looks dirt cheap at 7 times forward earnings. It also pays a hefty forward dividend yield of 4.1%.

HP also doesn't expect its cyclical slowdown to end anytime soon. Instead, it's cutting costs and streamlining its business through its "Future Ready Transformation Plan," which it unveiled last November. That plan calls for HP to lay off 7% to 10% of its workforce by the end of fiscal 2025; reduce its total number of unique PC models; launch new products for the higher-growth hybrid work, gaming, industrial graphics, and 3D printing markets; and boost its gross margin with more subscription-based services.

HP could struggle to outperform the market over the next few years

HP narrowly outperformed the S&P 500 in terms of total returns since its separation from HPE, but it could struggle to maintain that lead over the next few years. Lengthy PC upgrade cycles, the rise of paperless workplaces, competition in the printing supplies market from generic suppliers, and high interest rates could all make it difficult for the company to stabilize the growth of its PC and printing businesses.

HP's low valuation and high yield might limit its downside potential, but its lack of near-term and long-term catalysts could hold it back once a new bull market starts. That's probably why Berkshire Hathaway is reducing its exposure to HP -- and why you might actually be better off sticking with an S&P 500 index fund over the next few years.