Wall Street's main indexes closed higher on Tuesday, with the Nasdaq leading gains as a steep rally in semiconductor shares helped shift the focus away from the latest Middle East hostilities and tariff battles, while investors looked ahead to major technology earnings reports.
A rebound in recently battered semiconductor stocks provided huge support for the main U.S. stock indexes and the Philadelphia SE Semiconductor Index .SOX finished with a 5.2% rally in its second consecutive advance after ending Friday more than 20% below its late-June record high.
"Investors are really buying back in to the semis ahead of earnings because they have fear of missing out (FOMO), that these companies could report outsized earnings beats and increase their outlooks and they don't own as much as they did before the most recent pullback," said Lindsey Bell, chief investment strategist at 248 Ventures in Charlotte, North Carolina.
But Bell cautioned that when stocks rally sharply ahead of earnings, "it makes it more difficult for them to run in response to earnings."
"The numbers are going to be really good, but the stocks are also priced for perfection," she said.
The chip index dipped last week as investors grew concerned about high valuations and hefty investments on artificial intelligence. But even after that drop, it is still up nearly 75% year-to-date.
The Dow Jones Industrial Average .DJI rose 385.38 points, or 0.74%, to 52,224.64, the S&P 500 .SPX gained 65.92 points, or 0.89%, to 7,509.20 and the Nasdaq Composite .IXIC gained 329.13 points, or 1.29%, to 25,837.21.
Among the benchmark's 11 major industry sectors, nine advanced, with a 2.35% rally in information technology .SPLRCT leading the pack. The consumer staples index .SPLRCS was the biggest loser, finishing down 1%, followed by communications services .SPLRCL, which lost 0.85%.
Leading the S&P 500 were Sandisk SNDK.O, up 14.3%, Western Digital WDC.O, which rose 12.5%, and Micron Technology MU.O, with a 12.2% advance.
Equity investors appeared to shrug off President Donald Trump's unveiling of 50% tariffs on a wide range of imports from Canada on Monday.
They also looked past geopolitics even as oil prices settled up 2% after hitting five-week highs. This was after two oil tankers carrying Saudi crude to Asia reversed course in the Red Sea after Yemen's Iran-aligned Houthis threatened to impose a blockade on commercial shipping there. Trump said the United States would respond if the Houthis followed through.
"Investors see (the war) as transitory because we know two things — that $100 oil is a pressure point for Trump, and we also know that midterm elections are coming up," Bell said.
Meanwhile, their focus this week will turn to results from Alphabet GOOGL.O and chipmakers Intel INTC.O and Texas Instruments TXN.O.
Among individual stocks, 3M MMM.N shares rallied 7.3% after the industrial giant lifted its full-year profit forecast. Hasbro HAS.O stock jumped 8.8% after it raised annual revenue and profit forecasts, betting on demand for its digital gaming and "Magic: The Gathering" products.
Danaher DHR.N shares sank 11% and were the biggest loser in the S&P 500, after the life sciences firm trimmed its core revenue growth outlook and reported weaker-than-expected revenue in its biotechnology business.
Shares of MSCI MSCI.N, the benchmark's second-biggest loser, tumbled 10% after the index provider raised its full-year operating expense forecast despite better-than-expected quarterly revenue. And Genuine Parts GPC.N shares dropped 2.7% after the auto parts distributor lowered its full-year profit outlook.
Advancing issues outnumbered decliners by a 1.44-to-1 ratio on the New York Stock Exchange, where there were 113 new highs and 116 new lows. On the Nasdaq, 2,995 stocks rose and 1,814 fell as advancing issues outnumbered decliners by a 1.65-to-1 ratio. The S&P 500 posted 10 new 52-week highs and 7 new lows.
On U.S. exchanges, volume was light, with 16.14 billion shares changing hands compared with the 19.56 billion moving average for the last 20 sessions.
Reuters