NEW YORK (Reuters) - Wall Street’s main indexes rose sharply on Thursday boosted by earnings-related gains in Wal-Mart and Cisco, while a tax bill expected to boost corporate earnings passed its first, if smallest, hurdle.

Wal-Mart WMT.N surged as much as 11 percent to a record high of $99.68 after reporting its strongest U.S. revenue growth since 2009 and soaring online sales. It ended up 10.9 percent at $99.62.

Cisco CSCO.O touched $36.67, its highest since February 2001, a day after quarterly profit beat expectations driven by gains from its newer businesses such as security, which more than offset declines in its traditional switches and routers. Its profit forecast also came in above estimates.

Cisco shares closed up 5.2 percent at $35.88.

“There was good news on old line companies Cisco and Walmart adapting to the new economy,” said Brian Battle, director of trading at Performance Trust Capital Partners in Chicago, citing reasons for the market’s advance.

The U.S. House of Representatives voted largely along party lines to pass a tax overhaul expected to be a boost to stock prices if it becomes law, but the legislative battle now shifts to the Senate, where the Republican majority is much slimmer.

Republicans can lose no more than two Senate votes and at least two GOP senators have already spoken against the Senate version of the bill.

Traders work on the floor of the New York Stock Exchange shortly after the opening bell in New York, U.S., November 15, 2017. REUTERS/Lucas Jackson

“The tax plan isn’t a foregone conclusion but it passed the lowest hurdle in the House,” Battle said, adding that the Senate vote will be a higher bar and “the reconciliation will be the real measure, if it happens.”

The Dow Jones Industrial Average .DJI rose 187.08 points, or 0.8 percent, to 23,458.36, the S&P 500 .SPX gained 21.02 points, or 0.82 percent, to 2,585.64 and the Nasdaq Composite .IXIC added 87.08 points, or 1.3 percent, to 6,793.29.

The S&P and the Dow posted their largest daily percentage gains in more than two months.

The CBOE Volatility index .VIX, the cost of protection against a sudden drop on the S&P 500, posted its first decline in six days. It dropped 1.4 points to end at 11.76.

Barnes & Noble BKS.N shares jumped 7.6 percent to $7.10 even after the book seller said a deal proposed by an activist investor to take it private was not "bona fide" and doubted the required funds could be raised.

Folgers coffee maker J M Smucker SJM.N rose 9.5 percent to $116.65 as its sales and profit topped analysts' forecasts.

Viacom VIAB.O shares fell 3.7 percent to end at $23.69 after the MTV owner said it expected high single-digit declines in revenue from U.S. cable TV operators and online distributors in the first half of 2018.

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

The S&P 500 posted 42 new 52-week highs and four new lows; the Nasdaq Composite recorded 115 new highs and 36 new lows.

About 6.31 billion shares changed hands in U.S. exchanges, compared with the 6.81 billion daily average over the last 20 sessions. It was among the weakest volume sessions in the past three weeks.