Canada's main stock index dipped on Thursday as a plunge in oil prices weighed on energy shares, offsetting gains for industrials and financials after quarterly earnings from some major banks impressed investors.

U.S. crude prices settled US$2.46 lower at US$48.90 a barrel after the Organization of the Petroleum Exporting Countries' decision to extend production curbs fell short of expectations of deeper or longer cuts.

"Regardless of what OPEC does, U.S. shale producers can produce at these prices or lower, so that is going to continue to put an upward cap on the energy price," said Mike Archibald, associate portfolio manager at AGF Investments.

Canadian Natural Resources Ltd fell 2.0 per cent to $40.21, while the overall energy group tumbled 2.5 per cent. The group has lost nearly 18 per cent since posting a 19-month high in December.

The sector is cheap but needs a more sustainable upswing in the price of oil to attract investors, particularly U.S. money managers, Archibald said.

The Toronto Stock Exchange's S&P/TSX composite index closed down 8.76 points, or 0.06 per cent, at 15,410.73. Just three of the index's 10 main groups ended lower.

Industrials rose 1.2 per cent as railroad stocks climbed, while the financials group, which accounts for a third of the index's weight, gained 0.3 per cent.

The country's biggest bank, Royal Bank of Canada, rose 0.8 per cent to $93.74 after reporting an 11-per-cent profit increase, beating market forecasts, on strong performances in its capital markets and wealth management businesses.

Canada's second-largest lender, Toronto-Dominion Bank, was up 1.5 per cent at $64.01. Its earnings also exceeded expectations, helped by a strong performance at its retail and investment banking businesses.

But No. 5 bank Canadian Imperial Bank of Commerce fell 1.0 per cent to $105.24 after reporting a softer beat than its two larger peers.

"What you are seeing out of the broader bank reports in the last couple of days is that loan loss provisions continue to be in a solid position," said Archibald.

Manulife Financial Corp, Canada's biggest life insurer, was up 0.6 per cent at $23.69 after it named Roy Gori, an executive from its Asia division, to replace the retiring Donald Guloien as chief executive officer.

Forestry products company Tembec Inc jumped 41.4 per cent to $4.17 after accepting a buyout offer from Rayonier Advanced Materials Inc for $4.05 a share.

U.S. MARKETS

The S&P 500 and Nasdaq hit record closing highs on Thursday, with the market propped up by gains in the consumer discretionary sector after strong reports from Best Buy and other retailers.

The discretionary index gained 0.9 per cent, while the S&P 500 retail index was up 1.6 per cent, its best day since Dec. 7.

Best Buy jumped 21.5 per cent, hitting a record high and making it the top gainer on the S&P, after its comparable sales unexpectedly rose last quarter.

Tommy Hilfiger owner PVH was the second-biggest S&P gainer with a 4.8-per-cent jump to a near 6-month high on strong results. Sears was up 13.5 per cent after posting its first quarterly profit in nearly two years.

The reports follow mixed results this reporting period from other retailers, some of which continue to be hurt by competition from Amazon.com.

But they helped to give major indexes a sixth straight day of gains, more than making up for last week's selloff.

"There's no clear and present danger on the horizon," said Jimmy Chang, chief investment strategist at Rockefeller & Co in New York. "The lack of fear, the complacency is supporting the market."

The CBOE Volatility Index, the most widely followed barometer of expected near-term stock market volatility, fell to a two-week low of 9.72 during the session.

The Dow Jones Industrial Average was up 70.53 points, or 0.34 percent, to 21,082.95, the S&P 500 gained 10.68 points, or 0.44 per cent, to 2,415.07 and the Nasdaq Composite added 42.23 points, or 0.69 per cent, to 6,205.26.

Given relatively high valuations, further upside may be difficult for the market without progress on tax reform in Washington, Chang said.

He and other analysts also said the S&P 500's ability to remain above 2,400, after closing above it on Wednesday, also provided technical support.

Minutes from the Federal Reserve's May 2-3 meeting, released Wednesday, continued to bolster sentiment. They showed policymakers view an interest rate hike coming soon, but that they agreed to hold off until it was clear a recent slowdown in the economy was temporary.

Fed officials also proposed a plan to wind down its US$4.5 trillion of debt securities, including a limit on how much would be allowed to fall off the balance sheet each month.

Limiting gains, the S&P energy index was down 1.8 per cent following a nearly five-per-cent drop in crude oil prices. OPEC agreed to extend output cuts, but not by as much as investors had hoped for.

Also losing ground were shares of General Motors, down 1.8 per cent to US$32.60. GM was accused in a lawsuit of rigging hundreds of thousands of diesel trucks with devices, similar to those used by Volkswagen AG, to ensure they pass emissions tests.

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

The S&P 500 posted 92 new 52-week highs and 12 new lows; the Nasdaq Composite recorded 141 new highs and 66 new lows.

About 6.4 billion shares changed hands on U.S. exchanges, below the 6.8 billion daily average for the past 20 trading days, according to Thomson Reuters data.