In recent years, semiconductor giant Broadcom (AVGO 3.84%) has delivered market-crushing returns. With a market cap north of $250 billion, it is the 30th-largest stock on the U.S. market today.

Broadcom's massive gains have made millionaires out of some early investors, but many others fear that they have missed the boat already. Is it too late to take advantage of Broadcom's winning ways?

Let's have a look.

Looking back at earlier gains

First, let's imagine taking a look at Broadcom at the start of 2018. The stock had gained a thrilling 712% in five years, sporting a $100 billion market cap. Shares were changing hands at a lofty 49 times adjusted earnings, and many investors were wondering if the rocket ship had any fuel left in its tanks. Three months later, Broadcom's $117 billion buyout of rival chip designer Qualcomm (QCOM 1.45%) was canceled by executive order.

Many investors took a look at this high-flying market darling and decided that it wasn't a good investment after these huge gains:

AVGO Chart

AVGO data by YCharts

Fast-forward to 2022

Broadcom proved the bears wrong over the last four years, too.

In spite of sky-high valuations and the canceled Qualcomm merger, the stock performed in line with the S&P 500 market index until the summer of 2020 -- and then Broadcom took off again:

AVGO Chart

AVGO data by YCharts

Investors who picked up shares at that impossible peak in early 2018 have seen their returns more than doubling the broader market's gains. The company's leading role in the global rollout of 5G wireless networks kept the good times rolling. Broadcom's annual revenues increased by 75% in five years while free cash flows more than tripled.

And the cash machine is only running faster and smoother over time. A decade ago, Broadcom used to convert about 20% of its annual revenue into free cash flows. Today, the cash profit margin has doubled to 48%.

Winners keep winning

The stock may not look cheap after gaining 1,500% in 10 years and trading at 36 times trailing earnings, but not much has changed from that potential peak in 2018.

Don't forget that the current 5G revolution will be followed by a wave of 6G upgrades in the next decade, and that Broadcom hasn't stopped bolstering its business with smaller (but still massive) buyouts like the $19 billion CA Technologies deal in 2018 and the $11 billion Symantec merger in 2019.

So it's not too late to invest in Broadcom today. In fact, this stock looks like a fantastic buy right now.