(AP) -- Stocks reversed an early slide on Wall Street and finished broadly higher Wednesday, giving the market its second straight gain in a week of bumpy trading.
Big technology and communications companies, including Microsoft, Apple and Google parent Alphabet, led the rally as the market shrugged off an initial stumble. Banks took heavy losses following a sharp drop in bond yields.
Investors got in a buying mood after Treasury Secretary Steven Mnuchin gave a Senate subcommittee a promising update on the Trump administration's efforts to reach a trade deal with Canada and Mexico. Markets also got a boost from reports that the White House plans to delay new tariffs on car and auto parts imports from Europe by up to six months.
"The market does not believe that the trade discord will be protracted or widen, nor lead to a worldwide economic slowdown, or worse yet, a global recession," said Sam Stovall, chief investment strategist at CFRA.
The S&P 500 index gained 16.55 points, or 0.6%, to 2,850.96. The Dow Jones Industrial Average rose 115.97 points, or 0.5%, to 25,648.02. The index had briefly fallen 190 points.
The Nasdaq, which is heavily weighted with technology stocks, added 87.65 points, or 1.1%, to 7,822.15.
Small-company stocks lagged the market. The Russell 2000 index picked up 5.21 points, or 0.3%, to 1,548.27.
Major indexes in Europe closed higher.
Stocks have been whipsawed this week by worries over the worsening trade relationship between China and the U.S. and the fallout it may have on the broader global economy. The market plunged Monday, bounced back Tuesday and see-sawed Wednesday.
On Wednesday, Mnuchin told a Senate subcommittee that the U.S. is making progress on lifting tariffs imposed on steel and aluminum from Canada and Mexico, potentially overcoming a key hurdle toward approval of a trade agreement between the three countries.
Addressing another contentious trade issue, Mnuchin also said he expects to soon travel to Beijing with U.S. Trade Representative Robert Lighthizer to resume negotiations on the trade dispute between the U.S. and China. President Donald Trump has said that he expects to meet Xi in late June at the G-20 summit in Osaka, Japan.
Tensions between the world's two biggest economies intensified over the last week. The Trump administration more than doubled tariffs on $200 billion in Chinese imports and spelled out plans to target the $300 billion worth that aren't already facing 25% taxes. The escalation covers everything from sneakers to toasters to billiard balls. The Chinese have retaliated by hiking tariffs on $60 billion in U.S. imports.
The escalation in trade tensions surprised investors who had been expecting a resolution. That confidence was a key component of the stock market's sharp gains so far this year. Analysts have been warning that the stock market will remain volatile as long as the U.S. and China remain locked in their latest spat.
Major carmakers turned higher Wednesday following media reports that the U.S. is planning to delay new tariffs on car and auto part imports from Europe. The proposed tariffs would add another front to U.S. trade disputes and increase investors' anxiety.
Both European and U.S. automakers stand to suffer from retaliatory tariff increases that would cut into international sales. Ford rose 1.2%, Fiat Chrysler added 1.5% and General Motors gained 0.9%.
Wednesday's rally could be a case of investors reading too much into what is otherwise good news on the trade front. In this case, the potential delay in tariff increases for European cars could signal something more worrisome.
"The market is having an overly optimistic reaction to the small kernels of positive news flow that have come out today," said Kristina Hooper, chief global market strategist at Invesco. "I would argue the developments we heard today only underscore the precarious situation the U.S. is in with China."
Banks lagged the broader market as bond yields slumped. Bond prices rose sharply, sending yields lower, after some surprisingly disappointing economic data in the U.S. including weak figures on retail sales and industrial production.
The yield on the 10-year Treasury note, which is used to set rates on many kinds of loans including mortgages, fell to 2.37% from 2.42% late Tuesday, a large move.
That decline in yields hurts banks because it cuts into profit from interest on loans. Bank of America fell 1.2% and Citigroup slid 0.6%.
Technology and communications stocks accounted for much of the market's rally. Microsoft rose 1.4%, Apple gained 1.2% and Alphabet climbed 4.1%. Video game publisher Activision Blizzard also rose, adding 3.5%.
Not all technology stocks did well, however. Chipmakers, which are heavily dependent on China for sales, remained weak. Nvidia skidded 1.5%.
Progressive rose 5.2% after it gave investors a solid first quarter earnings report and renewed its stock buyback plan. The insurance company reported a sharp rise in written premiums.
Agilent plunged 11% after cutting its revenue forecast for the year following a disappointing first quarter. The scientific instruments maker reported first quarter profit and revenue that fell short of Wall Street forecasts.
Alibaba climbed 1.6% after the online retailer blew past Wall Street forecasts for first quarter profit. The Hong Kong-based company also beat revenue forecasts for the quarter.
Energy futures finished mostly higher. Benchmark U.S. crude rose 0.4% to settle at $62.02 per barrel. Brent crude, the international standard, closed 0.7% higher at $71.77 per barrel.
Wholesale gasoline climbed 1.8% to $2.01 per gallon. Heating oil gained 1.3% to $2.09 per gallon. Natural gas fell 2.2% to $2.60 per 1,000 cubic feet.
Gold inched 0.1% higher to $1,297.80 per ounce, silver held steady at $14.81 per ounce and copper gained 0.7% to $2.74 per pound.
The dollar fell to 109.54 Japanese yen from 109.64 yen on Tuesday. The euro weakened to $1.1204 from $1.1207.