A lot of money is being spent on artificial intelligence (AI) hardware and software now as organizations and governments across the globe look to benefit from the efficiency and productivity gains that this technology can deliver.
Market research firm Gartner expects spending on generative AI will jump by 76% in 2025 to a whopping $644 billion. That's why it is a good time to take a closer look at two names that are benefiting from the rapid growth in AI spending in different areas. These companies are already delivering healthy growth and are trading at attractive valuations, so buying them right now could be a smart move.

Image source: Getty Images
1. Taiwan Semiconductor Manufacturing
Taiwan Semiconductor Manufacturing (TSM -0.73%) is right in the middle of the AI revolution as it fabricates the high-end chips that go into devices ranging from data centers to smartphones to personal computers to cars. It's the largest third-party chip foundry in the world by far. Gartner points out that 80% of generative AI spending this year will be on hardware products, including both devices and servers.
TSMC is already benefiting from this opportunity. The foundry giant's revenue in the first seven months of 2025 increased by 38% year over year. That impressive growth can be attributed to robust chip demand from top customers such as Nvidia, Apple, AMD, and Broadcom.
The strong end-market demand led TSMC to increase its 2025 revenue growth guidance to 30% from its earlier expectation of growth in the mid-20% range. However, don't be surprised to see the Taiwan-based company exceeding even that upgraded target thanks to its AI-related catalysts.
For instance, Counterpoint Research is expecting a 68% spike in sales of generative AI-capable smartphones in 2025. Apple, which is one of TSMC's largest customers, reported a 13.5% jump in its iPhone revenue in its most recently reported fiscal quarter. Importantly, Apple is expecting sales growth in the mid to high single-digit percentages in the current quarter, suggesting that it could witness another period of robust iPhone sales ahead of the holiday season.
Moreover, TSMC's relationship with smartphone processor giant Qualcomm should pave the way for the company to grow its footprint in the smartphone market. On the other hand, TSMC's relationships with the leading AI chip designers and its focus on expanding its manufacturing capacity to serve this fast-growing market will set the stage for further healthy sales growth.
The diversity of its customer base helps explain why the foundry's revenue is anticipated to increase at healthy double-digit percentages over the next couple of years as well.
TSM Revenue Estimates for Current Fiscal Year data by YCharts.
However, TSMC could end up doing better than that over the long run thanks to its improving share of the Foundry 2.0 market, which is expected to generate $298 billion in revenue this year. IDC expects Foundry 2.0 to grow at an annualized rate of 10% through 2029, and TSMC has been able to expand its market share in the space thanks to its focus on advanced chip packaging.
As such, TSMC seems capable of outperforming expectations in the long run, and that's why buying the stock while it is trading at an attractive 24 times forward earnings (a discount to the tech-laden Nasdaq-100 index's multiple of 30) looks like the right thing to do.
2. Twilio
Spending on generative AI services and software is also taking off as organizations and people adopt more applications to automate processes and increase productivity. According to estimates from Gartner, in 2025, total spending on AI services and software could jump by 119% to almost $65 billion. Twilio (TWLO 5.22%), a cloud communications specialist, is witnessing a healthy acceleration in growth thanks to the adoption of AI tools in its industry.
Twilio's application programming interfaces (APIs) enable its clients to stay in touch with their customers through multiple channels such as text, voice, email, chat, and video. The company offers AI tools that allow its clients to build voice AI solutions such as AI agents to elevate the customer service experience, along with AI-powered marketing tools to improve conversion.
The company's AI tools are helping it close bigger deals with customers. Twilio says that it saw a 57% year-over-year increase in the number of communications deals valued at $500,000 or more in the second quarter of 2025. The company's active customer accounts increased by 10% from the year-ago period, compared to a 4% increase in the same period last year.
Spending by Twilio's established customers improved as well. This is evident from an increase of 5 percentage points in its dollar-based net expansion rate to 108%. (That metric compares the spending of active customers in a quarter to the same cohort's spending in the year-ago period.) Not surprisingly, Twilio has increased its organic revenue growth estimate for 2025 by 1.5 percentage points.
It could, however, end up doing better than that thanks to its accelerating customer base growth as well as the cross-selling opportunities that its AI solutions are creating. Analysts covering the company are encouraged by its improving growth profile, and have raised their expectations for it.
TWLO Revenue Estimates for Current Fiscal Year data by YCharts.
Finally, this cloud stock is trading at just 3 times sales, a slight discount to the S&P 500's sales multiple. Investors, therefore, can get a good deal on an AI stock that seems capable of flying higher in the long run.