Some artificial intelligence (AI) stocks inspire tons of headlines. You probably know exactly what Nvidia (NVDA 1.28%) and Microsoft (MSFT 1.58%) are doing in the AI space, whether their stocks are doing well or not.
And then there's the quiet bunch. I can assure you that IBM (IBM 1.39%) and Micron Technology (MU 0.26%) do plenty of AI-related business, and that they stand to benefit from this ongoing boom in generative AI. Their stocks have been outperforming the S&P 500 (^GSPC 0.83%) in 2025, apart from a couple of short-lived glitches.
But how often do you see them mentioned among the top AI stocks to own for the long haul? Not a whole lot, I bet.
So let me tell you what these tech veterans are doing to earn consistently market-beating performance this year -- without dominating the press.
How Micron is stealing the AI spotlight
Micron is not the largest memory-chip maker in the world, but it has an advantage over sector leaders SK Hynix and Samsung (SSNL.F 9.01%) right now. The Idaho-based chip maker is first to market with the fourth generation of high bandwidth memory (HBM) -- a key component in the latest and greatest AI accelerator platforms.
Samsung and Hynix have their own HBM4 solutions, but Micron is already shipping these chips to its most important customers. AI hardware leader Nvidia (NVDA 1.28%) includes Micron's HBM4 memory on its Blackwell family of AI accelerators. Runner-up AMD (AMD -0.45%) also selected Micron's top-of-the-line memory for its next two generations of Instinct accelerators.
As a result, Micron's market share is growing while Samsung is sliding back. Now, Micron's sales are limited by the company's in-house production capacity, as the HBM chips are sold out for the rest of 2025. That's why Micron has invested $10.2 billion in capital expenses over the last three quarters, up from $5.3 billion in the same year-ago period. These costly chip-factory upgrades will be the foundation of Micron's long-term growth opportunity.
So Micron is a leading supplier of AI-grade memory solutions. The stock has gained a market-beating 47% in the first half of 2025. Now you know why.
IBM's not so secret weapon: Consulting services
Do you still see IBM as a one-stop shop for corporate computing needs? That would be a mistake. The company refocused on AI, cloud computing, and consulting services long before it was cool. The strategy shift led to many years of disappointing shareholder returns, but the big payoff is finally coming in. And of course, Big Blue's fortunes are built around AI.
In the recent first-quarter update, IBM posted an order book of more than $6 billion in the WatsonX generative AI service. That's up from roughly $1 billion in the year-ago quarter. That's a big jump. And here's the fun part -- only 20% of this incoming contract portfolio comes from software licenses. The rest springs from consulting services.

Image source: Getty Images.
This is a unique business advantage. IBM's technical expertise goes far beyond its own software tools. When your company's employees need training on a new technology, or hands-on expertise from IT consultants, you're likely to look at IBM's consulting services. Yes, other tech giants can support their in-house software and services, but they're less likely to offer broad technology support.
This isn't a new trend. Before the Fool, two different employers sent me to IBM's training centers around the country to keep me up to date with networking standards and programming tools. That was 20 years ago and nothing has changed -- except IBM's heavier focus on high-value topics such as AI systems and cloud computing.
IBM's stock has gained 33% in 2025, and the underlying business results were largely based on consulting services in the AI market. If you knew that five minutes ago, you were already ahead of the game. If not, you just earned an edge on most AI investors.