NEW YORK (Reuters) - U.S. stocks climbed on Thursday as top technology names hit record highs and industrials rebounded from losses driven by trade worries the day before.

Helping the move in tech, CA Inc jumped 18.7 percent and was the biggest percentage gainer in the S&P 500 after chipmaker Broadcom announced a surprise $18.9-billion deal to buy the business software company. Broadcom slumped 13.7 percent.

Facebook, Microsoft and Amazon hit all-time highs and, along with Apple and Alphabet, drove gains in the S&P 500 and Nasdaq.

The technology index rose 1.8 percent, the day’s best-performing sector, and the group is now leading year-to-date gains among sectors. The S&P industrials index rose 1.1 percent. Health care also gained about 1.1 percent.

Helping the tech sector is the view that those companies may be more immune to problems in the trade dispute, said Quincy Krosby, chief market strategist at Prudential Financial in Newark, New Jersey.

But also, she said, “The consensus is that negotiations will resume and there will be some sort of agreement between the U.S. and China. It could be naive, but that seems to be an emerging consensus within the market.”

The United States late Tuesday threatened to impose tariffs on $200 billion worth of Chinese goods. China said on Thursday the two countries have not been in touch about restarting talks and while it does not want a trade war, it would fight if necessary.

FILE PHOTO: Traders work on the floor of the New York Stock Exchange (NYSE) in New York, U.S., July 11, 2018. REUTERS/Brendan McDermid

Boeing and Caterpillar, among the hardest hit by the trade dispute, rose more than 1 percent each on Thursday, boosting the Dow.

The Dow Jones Industrial Average rose 224.44 points, or 0.91 percent, to 24,924.89, the S&P 500 gained 24.27 points, or 0.87 percent, to 2,798.29 and the Nasdaq Composite added 107.31 points, or 1.39 percent, to 7,823.92.

The stock market value of Microsoft, which jumped 2.2 percent to $104.19, also rose above $800 billion for the first time, joining Apple, Amazon and Alphabet in that $800 billion club and putting it in line as a contender to be the first U.S. company to reach a $1 trillion market cap.

Earnings will take center stage Friday, when some big Wall Street banks, including JPMorgan Chase, report results. S&P 500 companies overall are expected to post second-quarter profit growth of around 21 percent, according to Thomson Reuters data.

Delta Air Lines rose 1.8 percent, and lifted other airline stocks, after the carrier’s quarterly profit topped estimates on higher average fares.

In a sign that labor market conditions remained robust in early July, weekly jobless claims hit a two-month low last week, the Labor Department said.

The consumer price index barely rose in June, but the underlying trend continued to point to a steady buildup of inflation pressure that could keep the Federal Reserve on a path of gradual interest rate increases.

Advancing issues outnumbered declining ones on the NYSE by a 1.75-to-1 ratio; on Nasdaq, a 1.44-to-1 ratio favored advancers.

The S&P 500 posted 36 new 52-week highs and three new lows; the Nasdaq Composite recorded 101 new highs and 43 new lows.

About 5.8 billion shares changed hands on U.S. exchanges. That compares with the 6.9 billion daily average for the past 20 trading days, according to Thomson Reuters data.