TOKYO, Oct 21 (Reuters) - Japanese shares on Wednesday recovered from losses in the previous session as optimism that U.S. lawmakers could reach an agreement on a pre-election stimulus package lifted riskier assets.

The benchmark Nikkei share average rose 0.47% to 23,676.90 by the midday break, erasing all of Tuesday's losses with 197 advancers on the index against 23 decliners. The broader Topix gained 0.89% to 1,640.16.

Highly cyclical miners, shippers and iron and steel were the three top performers on the main bourse.

With just two weeks until the U.S. presidential election, lawmakers moved closer to agreement on a new coronavirus relief package as President Donald Trump said he was willing to accept a large aid bill despite opposition from his own Republican Party.

The news helped Wall Street finish higher overnight and buoyed sentiment in Asia.

Among the top gainers in Japan, Shimachu soared around 13% after furniture retailer Nitori Holdings said it may bid for the home improvement retailer, threatening a tender offer for the company by its bigger rival DCM Holdings Co .

Nitori and DCM were down 0.18% and 6.54%, respectively.

Shares of ANA Holdings reversed course to trade down 0.13% after Kyodo News reported the coronavirus-battered airline operator is expected to suffer a net loss of 530 billion yen ($5 billion) for the fiscal year ending in March.

Takara Bio Inc jumped 6.51% after the Japanese biotechnology company lifted its net profit forecast for the six months ended Sept. 30.

Nojima Corp gained 6.49% after upgrading its net profit outlook for the fiscal year ending in March.

The Mothers Index of start-up firm shares gained 1.25%. (Reporting by Eimi Yamamitsu; Editing by Aditya Soni)