The Dow Jones Industrial Average and the S&P 500 index fell modestly on Monday, ending well off session lows, as gains in energy shares helped curb declines stemming from trade war concerns after China’s retaliation to U.S. tariffs.

Trump said last week he was pushing ahead with tariffs on $50 billion of Chinese imports, prompting a quick response from Beijing, which said it would put duties on several American commodities.

Boeing, which has acted as a proxy for trade war tensions with China as it is the single largest U.S. exporter to the country, fell 0.9 percent making it the largest drag on the Dow. Construction equipment maker Caterpillar declined 0.9 percent.

Chipmakers, which rely on China for a large portion of their revenue, also lost ground. The PHLX semiconductor index lost 0.99 percent, its worst daily performance in a month. Intel, off 3.4 percent, was the largest drag on the S&P 500 and Nasdaq on tariff concerns and a downgrade by Northland Securities.

Oil prices advanced in volatile trade as market participants lowered their expectations for how much OPEC might increase production. Even with the anticipated increase, Goldman Sachs maintained its bullish outlook on the oil market.

The S&P energy index rose 1.1 percent for its first gain in five sessions. The index was aided by gains in Chevron, up 1.6 percent, and ConocoPhillips, up 1.9 percent.

The consumer staples index fell 1.5 percent, with tobacco major Philip Morris down 2.3 percent. Tobacco is among the 545 goods that China plans to impose tariffs on as of July 6.

Among other stocks, Valeant Pharmaceuticals’ fell 12.3 percent after the government declined approval of the company’s plaque psoriasis treatment lotion.

Biotechnology firm China Biologic rose 21.1 percent after Chinese investment company CITIC Capital Holdings offered to buy it in a deal valuing the company at $3.65 billion.