TORONTO -- The Toronto stock market registered a modest gain Tuesday amid hopes that the European Central Bank will ease the financial crisis by taking steps to reduce the borrowing costs of deeply indebted countries such as Spain and, to a lesser extent, Italy.

But enthusiasm faded late in the session and the S&P/TSX composite index closed well off early triple digit highs, up 40.89 points to 12,116.92. The TSX Venture Exchange was ahead 9.98 points at 1,239.32.

The Canadian dollar was also well off session highs, moving down 0.13 of a cent to 101.04 cents after earlier hitting a fresh 3 1/2-month high of 101.6 cents US amid rising commodity prices.

U.S. markets also gave up early gains as the Dow Jones industrials fell 68.06 points to 13,203.58, the Nasdaq composite index was down 8.95 points at 3,067.26 and the S&P 500 index slipped 4.96 points to 1,413.17.

The hope is that the ECB will buy government bonds as a way to reduce borrowing costs for highly indebted countries, which had spiked earlier this year to unsustainable levels. The German central bank, the Bundesbank, is alone in opposing such a move and some traders are betting that a compromise will be reached.

Still, stocks retreated from session highs amid plenty of skepticism about this latest round of speculation about what ECB might do.

"There is still a lot of open-ended questions here about the process, what type of money is involved," said Gareth Watson, vice-president investment management and research, Richardson GMP Ltd.

"And I think the market would probably take even more confidence if they said we're doing this at all costs to get to a certain yield, no matter how much money (it takes). The market would love to hear that. But realistically, if the Bundesbank gets on side I don't think they're going to write this completely blank cheque."

Stocks have rallied strongly during August on hopes that central banks will do what's needed to keep the economic recovery alive and in the case of the ECB, protect the euro currency union.

But Watson thinks markets are expecting follow through quickly.

"There's all these expectations but we're currently in a waiting period until these events happen, to see if these expectations become reality, he said, adding that "if nothing happens in the next three weeks . . . this market could easily turn the other way very quickly."

The energy sector rose 0.32 per cent as the September crude contract on the New York Mercantile Exchange gained 71 cents to US$96.68 a barrel. Cenovus Energy (TSX:CVE) rose 44 cents to C$33.31.

The September copper contract on the Nymex reversed Monday's five-cent loss, climbing eight cents to US$3.45 a pound and the base metals sector gained two per cent. Teck Resources (TSX:TCK.B) advanced 59 cents to C$29.92 while First Quantum Minerals (TSX:FM) added 24 cents to $19.61.

The gold sector ran up about 1.75 per cent as December bullion rose $19.90 to US$1,642.90 an ounce. Goldcorp Inc. (TSX:G) improved by 95 cents to C$38.88, while Barrick Gold Corp. (TSX:ABX) was 47 cents higher at $36.48.

The financials sector climbed 0.35 per cent with Royal Bank (TSX:RY) ahead 53 cents at $54.05.

Tech stocks also provided lift as CGI Group (TSX:GIB.A) moved up 91 cents to $25.10.

The telecom sector lost 0.8 per cent with Telus Corp. (TSX:T) down 77 cents to $63.50.

The drop came as U.S. hedge fund Mason Capital, which owns almost 20 per cent of the Vancouver-based telecom's voting stock, said Telus has until Thursday to send notice of a special meeting for its voting shareholders.

They are being asked to approve a minimum acceptable premium for their support of one class of common shares. Mason is in a fight with Telus over its plan to convert its non-voting shares on a one-to-one basis to a common class of shares.

After markets closed, Telus said it would put a new proposal to convert shares on a one-for-one basis to a vote at a meeting of shareholders planned for Oct. 17.

But it rejected Mason's calls for a vote on a minimum acceptable premium.

In corporate news, Chinese state-owned oil company CNOOC Ltd., which plans to buy Canada's Nexen Inc. in a $15.1-billion deal, said Tuesday that first-half profit fell 19 per cent as costs rose and a big oil spill in China's Bohai Bay cut production.

The company also cut its dividend by 40 per cent to 15 Hong Kong cents a share to save up cash needed for the Nexen deal.

Facebook stock was down 4.26 per cent to US$19.16 following news that Peter Thiel, one of Facebook's earliest investors and a board member, was among the insiders selling stock in the social network after a lockup expired last week. A regulatory filing says that Thiel sold about 20 million shares of Facebook last Thursday and Friday, about 80 per cent of his stake.

The social networking company's shares fell below the US$19 level at one point Monday, half the price of the stock when it embarked on its initial public offering in May.

Apple Inc. stock was down 1.37 per cent to US$656.06 after Oracle Investment in the U.S. downgraded the stock to "hold" from "buy."