(Reuters) - Wall Street’s major indexes extended the New Year rally to close at record levels on Tuesday on investor optimism ahead of quarterly earnings reports and hopes for easing tensions with North Korea.

Defensive S&P sectors - utilities, real estate and telecommunications - were out of favor, while bank stocks were boosted by rising U.S. 10-year Treasury yields. Healthcare stocks rose with the sector in focus on the second day of an industry conference.

The S&P 500 and Nasdaq registered their sixth closing record highs in a row. The Dow also ended at record levels after it had snapped a 3-day run of closing highs in Monday’s session.

Some investors were reassured that North and South Korea held their first talks in more than two years, which Washington described as a good first step in solving the North’s nuclear missile program crisis. Pyongyang said it would not discuss weapons that were aimed only at the United States.

“The diplomacy taking place between North Korea and South Korea might circumvent some type of military action. Anything that would de-risk the peninsula would be viewed favorably by investors,” said Mark Luschini, chief investment strategist at Janney Montgomery Scott in Philadelphia.

The Dow Jones Industrial Average rose 102.8 points, or 0.41 percent, to 25,385.8, the S&P 500 gained 3.58 points, or 0.13 percent, to 2,751.29 and the Nasdaq Composite added 6.19 points, or 0.09 percent, to 7,163.58.

Profits for S&P 500 companies are expected to rise 11.8 percent in the fourth quarter, compared with an 8-percent increase a year earlier, according to Thomson Reuters I/B/E/S.

Traders work on the floor of the New York Stock Exchange, (NYSE) in New York, U.S., January 8, 2018. REUTERS/Brendan McDermid

“There will be some noise there with tax adjustments, but the forward-looking comments ought to be pretty positive. Investors are buying into that,” said Bucky Hellwig, senior vice president at BB&T Wealth Management in Birmingham, Alabama.

The S&P financial sector ended 0.8 percent higher after yields on the 10-year U.S. Treasury note hit a 10-month high after the Bank of Japan said it will trim its purchases of Japanese government bonds.

Interest-rate sensitive utilities and real estate sectors ended 1 percent lower while the telecommunications sector fell 1.8 percent.

While investors are hopeful about global economic growth and tax-cut led gains for corporate earnings, they are anxious about whether the tax-overhaul could overheat inflation and lead to a sharper than expected rise in interest rates.

After a lukewarm December jobs report, signs of a pickup in inflation could come in the monthly consumer price report due on Friday, on the same day that big U.S. banks are set to kick off the fourth-quarter earnings season.

The S&P healthcare sector closed 1 percent higher, boosted by a 1.6-percent rise in Johnson & Johnson, a 5-percent gain in Gilead and a 8.3-percent jump in Boston Scientific shares.

Chip stocks dragged on the technology sector, which fell 0.3 percent. Intel fell 2.5 percent after Microsoft Corp said computers with older Intel chips slowed noticeably after it released security patches.

Declining issues outnumbered advancing ones on the NYSE by a 1.41-to-1 ratio; on Nasdaq, a 1.19-to-1 ratio favored decliners.

The S&P 500 posted 124 new 52-week highs and 3 new lows; the Nasdaq Composite recorded 131 new highs and 24 new lows.

Volume on U.S. exchanges was 6.77 billion shares, above the 6.3 billion average for the full session over the last 20 trading days.