The brutal sell-off in technology stocks last week has undoubtedly led to some big bargains. But how can investors figure out which stocks are currently on sale, and which highfliers have been rightly discounted to fair value?

One particular sector worth exploring is the semiconductor industry. That sector is in a big shortage right now, with the CEOs of several major tech companies, such as Dell Technologies and Intel , saying they believe the shortage should last a couple of years at least. That's because after several years of underinvestment, the pandemic-fueled digitization of the economy has led to a surge in demand for chips. Meanwhile, supply is short, and new fabrication plants can take two or three years to fully ramp up.

Against this backdrop, semiconductor companies that can either raise prices or the equipment companies that help produce more chips are in for a strong two years. Many such companies are earning good profits and paying dividends today, meaning they should be somewhat insulated from fears over higher interest rates. Yet semiconductor stocks have strangely sold off with the rest of the technology sector, probably in a case of guilt by association. That could open up a big opportunity.

Scanning the sector today, I have equipment supplier Lam Research (NASDAQ:LRCX) at the top of my list, and it sure looks like a bargain after the difficult past month.

LRCX Chart

LRCX data by YCharts

Booming results, but down 10% on the month

Even after Friday's big bounce, Lam Research is down about 10% from its all-time highs, despite recently reporting terrific earnings and providing excellent forward guidance. Lam Research is a leader in etch and deposition tools, which are especially useful for stacking 3D NAND flash modules. However, Lam's machines are also important for logic, especially at advanced nodes.

But Lam Research also stands out in other ways, even among semi equipment peers. For one, it has the highest percentage of revenue coming from recurring services. Despite booming equipment sales that surged more than 10% quarter over quarter, services still accounted for 34% of total revenue in the March-ending quarter. That's the highest among all semiconductor equipment companies, which usually have service revenue in the low 20% range, showing that Lam's service offerings are adding a lot of value. After-sale services include spare parts, maintenance that increases uptime and extends the life of machines, and artificial intelligence-enabled data services that help customers eliminate defects and improve yields.

Good industry news just keeps on coming

Meanwhile, the world's top semiconductor manufacturers have all announced ambitious production and spending plans over the next few years. That means great visibility on orders for equipment suppliers like Lam.

South Korean companies including Samsung and SK Hynix recently announced an ambitious $450 billion in spending over the next 10 years to boost production of logic chips. South Korea makes a majority of the world's memory chips, but given the race to shore up advanced logic capabilities worldwide, the country is now doubling down to compete in that segment as well.

A silicon wafer emerges from a pile of black sand.

Semiconductors are emerging as strategically important national resources. Image source: Getty Images.

Meanwhile, current semiconductor manufacturing leader Taiwan Semiconductor Manufacturing recently unveiled a $100 billion three-year plan to solidify its leading-edge expertise and help ease the global shortage. That may even increase, as Reuters just reported that TSMC is mulling over a much bigger investment in the U.S. than the $10 billion to $12 billion announced last year. Company officials are now debating whether to build an advanced 3-nanometer facility in Arizona, which would cost another $20 billion to $23 billion.

And let's not forget Intel, which has a new strategy to become a foundry for third parties under new CEO Pat Gelsinger. In a recent presentation, Intel forecast spending at least $20 billion in Arizona as part of its new strategy. Meanwhile, a bipartisan group of four U.S. senators is set to unveil a $52 billion, four-year proposal to help subsidize U.S. chip production and counter the rising threat from China.

This global race to produce more quantities of more advanced chips should only spell more and more sales and profits for Lam, which has not only been riding a strong industry wave but is also taking share from its rivals.

Now a relative bargain

After the recent sell-off, Lam trades at only 18.7 times next year's earnings estimates (its fiscal year ends in June 2022). That's much cheaper than the 22.5 forward P/E for the S&P 500 and the 27.5 forward P/E ratio for the Nasdaq.

However, I think Lam can beat the average analyst 2022 earnings estimate of $32.22. The company just recorded $7.49 in adjusted (non-GAAP) earnings per share last quarter and guided to strong sequential growth. Given that the current level of earnings is already at a $30 run rate, the chip industry is going to spend lots of money for the next few years to ease the shortage, and Lam continues to repurchase shares at a healthy clip, I think Lam's earnings per share could easily be closer to $35 or even $40 in 2022.

Lam's earnings can be a touch more cyclical than a typical tech stock, but its long-term trajectory is clearly up and to the right. Zooming out, revenue and earnings shouldn't look too different from a software or FAANG type stock. Yet Lam trades at a much cheaper multiple. Given the growing strategic importance of semiconductors in the 2020s, Lam's stock sure looks like a bargain after the tough sell-off over the past month.

This article represents the opinion of the writer, who may disagree with the “official” recommendation position of a Motley Fool premium advisory service. We’re motley! Questioning an investing thesis -- even one of our own -- helps us all think critically about investing and make decisions that help us become smarter, happier, and richer.