A number of U.S. stocks rose on Wednesday, bringing the S&P 500 and Dow industrial indexes to new record highs, largely due to gains in the technology sector. The rise of tech stocks offset the floundering energy market, with crude oil floundering at multi-year lows.

Apple Inc. (NASDAQ:AAPL) and Hewlett-Packard Co. (NYSE:HP) were some of the biggest gainers, while Apple rose 1.2 percent to $119 per share. HP rose 4.1 percent to $39.16 the day after reporting fourth-quarter earnings. Out of the top 10 biggest gainers on the S&P 500, seven were tech stocks.

It was a light trading day: Only 4.8 billion shares were traded, compared to a 6.3 billion daily average, Reuters reports. The market will be closed all day Thursday and will return for a half-day session on Friday, closing at 1 p.m. EST.

Despite a weakening global demand and slow increases in U.S. consumer spending last month, consumer confidence was near a 7.5-year high. One expert suggests that the market’s optimism for the holiday season lifted chip makers’ stocks.

"On balance, data was still supportive of reasonable strength in the economy," Peter Jankovskis, co-chief investment officer at OakBrook Investments, told Reuters. "PC sales have been a drag and there may be some hope we see a pick-up."

The S&P 500 index rose 0.28 percent to 2,072.83, the Dow Jones industrial average gained 0.07 percent to 17,827.75 and the Nasdaq was up 0.61 percent to 4,787.32. The S&P’s energy sector fell 1.1 percent, as OPEC signaled that it would now slow production this week, causing crude oil prices to drop.