TORONTO - The Toronto stock market closed sharply higher as gold stocks benefited from another day of record high gold prices while investors were encouraged by strong Chinese economic data.

The TSX S&P/TSX composite index ran up 90.86 points to 13,324.94, finding additional lift from a comment by U.S. Federal Reserve chairman Ben Bernanke that the central bank will supply more stimulus to the U.S. economy if needed.

The TSX Venture Exchange was ahead 37.24 points to 1,989.13.

The Canadian dollar was up 0.7 of a cent to 104.2 cents US.

China's economy expanded by 9.5 per cent in the second quarter from a year earlier, down slightly from the 9.7 per cent pace seen in the first quarter. That was above the 9.4 per cent anticipated by economists and alleviated concerns of an abrupt slowdown.

Strong Chinese demand has also driven prices higher for commodities such as oil and copper, which in turn have supported the resource-heavy TSX.

"The worry was China is going to have a hard landing and, if anything, it seems like good times are here to stay," said John Stephenson, vice-president and portfolio manager at First Asset Funds.

The Chinese government has been trying to cool the world's second-biggest economy in order to bring down high inflation, which hit a three-year high in June.

Markets initially spiked following Bernanke's comment during his twice-a-year economic report to Congress. But indexes in Toronto and New York moved well off session highs as investors realized that the U.S. economy would have to deteriorate substantially for the Fed to step in.

However, Stephenson pointed out that really, the Fed has no choice but to act.

"If you look at the U.S. data in the last week, it has come off a cliff. I mean 18,000 jobs created in June? That's nothing, that's zero when it comes down to it," he said.

"The only thing that is helping the U.S. out right now is the fact that the European Union is in even more screwed up than the U.S."

Meanwhile, Italy's finance minister sought to reassure nervous markets, saying the government's package of austerity measures will be strengthened and passed by Friday.

The European government debt crisis has been a focus of investors amid ongoing worries about whether Greece will have to default on its massive debt. But worries about the crisis grew this week as markets demanded higher interest rates for the debt of Italy and Spain.

Oil prices headed higher in the wake of Bernanke's comments, reversing earlier declines resulting from a report that showed U.S. crude supplies unexpectedly rose last week, suggesting demand is weak.

The August contract on the New York Mercantile Exchange gained 62 cents to US$98.05 a barrel while the energy sector gained 0.6 per cent. Canadian Natural Resources (TSX:CNQ) climbed 26 cents to C$39.58 and Imperial Oil (TSX:SU) rose 46 cents to $44.59.

Metal prices advanced while the September copper contract on the Nymex headed one cent higher at US$4.40 a pound. The base metals sector gained 1.5 per cent while Teck Resources (TSX:TCK.B) advanced 52 cents to C$49.73 and Quadra FNX Mining gained 43 cents to $14.37.

Bullion prices added to Tuesday's latest record high close, up $23.20 to US$1,585.50 an ounce as talk of more American stimulus raised inflation concerns, which left gold stocks higher. Barrick Gold Corp. (TSX:ABX) improved by $1.16 to C$46.62 while Goldcorp Inc. (TSX:G) was ahead $1.29 to $52.12.

All sectors were higher with the financial component ahead 0.2 per cent as Bank of Montreal (TSX:BMO) advanced 49 cents to $61.41.

New York's Dow Jones industrial average was ahead 44.73 points to 12,491.61.

The Nasdaq composite index gained 15.01 points to 2,796.92 while the S&P 500 index was up 4.08 points to 1,317.72.

On the corporate front, Rupert Murdoch's News Corp. has given up on making an offer to take full control of British Sky Broadcasting amid the rising fallout from a phone hacking scandal. News Corp. deputy chairman and president Chase Carey said "it has become clear that it is too difficult to progress in this climate." News Corp. shares gained 58 cents to US$15.93 in New York.

Investors also took in some major acquisition activity.

The Canada Pension Plan Investment Board is teaming with a consortium of other investors to buy Kinetic Concepts Inc., (NYSE:KCI) a producer of wound care products, for US$6.3 billion, including debt. San Antonio, Texas-based Kinetic said the transaction is being made for $68.50 per share, which values the company at $4.98 billion. Kinetic shares rose $3.74 to US$68.23.

Northgate Minerals Corp. (TSX:NGX) will acquire Primero Mining Corp. (TSX:P) in a US$409 million deal that includes the San Dimas mine in Mexico. Northgate shares added a penny to $2.82 while Primero shares rose 46 cents to $4.16.

And OpenText Corp. (TSX:OTC) shares were up $3.07 to $66.37 as it announced it has acquired Global 360 Holding Corp., a leading provider of process and case management solutions, for about $260 million.

Shares in Research In Motion Ltd. (TSX:RIM) were down 52 cents to $27 after co-chief executive Jim Balsillie told the company's annual meeting Tuesday that the BlackBerry maker's foundation is strong. He highlighted the company's plan to launch a new slate of smartphones that will secure the company's future success.

Opti Canada Inc. (TSX:OPC) has filed for CCAA creditor protection as its creditors agreed on a $375 million equity investment in the oilsands developer, which is undergoing a restructuring process. The TSX said Wednesday it is reviewing Opti's common shares with respect to meeting listing requirements and said that the shares were suspended from trading immediately. Its shares last traded at 11.5 cents.