U.S. stocks rose on Wednesday as investors positioned themselves for the quarter's end and the S&P 500 attempted to hold above a key technical level.

Stocks advanced as money managers re-allocated positions for the end of the quarter, with the S&P 500 up 5.9 percent.

The S&P broke through 1,330, which was noted as a resistance point for stocks. The benchmark was unable to hold gains above that mark in its three previous attempts.

They are selling commodities, they are moving back into industrials. You've got a mini-market rotation coming into your final couple of days of the quarter, and that is the way the window dressing takes place, said Paul Mendelsohn, chief investment strategist at Windham Financial Services in Charlotte, Vermont.

The Dow Jones industrial average <.DJI> gained 100.06 points, or 0.81 percent, to 12,379.07. The Standard & Poor's 500 Index <.SPX> gained 11.85 points, or 0.90 percent, to 1,331.29. The Nasdaq Composite Index <.IXIC> gained 21.46 points, or 0.78 percent, to 2,778.35.

The U.S. labor market showed further recovery in March as private-sector employers added jobs while planned layoffs fell, according to separate reports on Wednesday.

The ADP report on private-sector jobs, which may not be a dependable indicator of the government's broader jobs report due on Friday, showed 201,000 jobs being created. That kept expectations intact for the Labor Department's report.

At 200,000 or so, that number is not enough to excite the market one way or the other -- if it indeed happens to be the number for payrolls on Friday, said John Canally, and economist for LPL Financial in Boston.

You need well below that to get people worried about a double-dip (recession) and well above that to get people too worried that the Fed is going to tighten.

In the latest deal news, Canadian drugmaker Valeant Pharmaceuticals International made an unsolicited bid to buy Cephalon Inc for $5.7 billion, driving Cephalon's stock up 28.1 percent to $75.25 while Valeant's U.S.-listed shares shot up 10.4 percent to $49.

The deal pushed the NYSEArca biotech index <.BTK> up 3 percent.

(Reporting by Chuck Mikolajczak; Editing by Kenneth Barry)