(Reuters) -- U.S. stocks gave up gains on Wednesday as the S&P 500 hit a technical barrier near a nine-month high and Apple shares erased a 3 percent advance.

Apple Inc shares turned negative, weighing on the Nasdaq and reversing the overall market's advance. Doreen Mogavero, chief executive of trading firm Mogavero, Lee & Co, said from the floor of the New York Stock Exchange investors were concerned about a report that Apple had asked Amazon to halt sales of its iPad in China.

Apple was not immediately available for comment, and an Amazon spokeswoman declined to comment.

Volume on the iPhone maker's shares was more than twice its average in the last 10 days. Shares were last down 0.4 percent at $507.35 after climbing as high as $526.29.

Industrial stocks led declines on the S&P 500, with Deere & Co down 3.6 percent at $85.85 after investors expected the farm equipment company to give a stronger full-year forecast.

U.S. manufacturing output rose solidly in January and a gauge of factory activity in New York state hit a 1-1/2-year high in February, adding to a run of fairly upbeat data, even though overall industrial production was flat last month.

The S&P hit a peak of 1,355.87, just shy of its July 2010 high. A break above that level would take the benchmark to its strongest since at least May of last year.

Right now we're bouncing off 1,355. It's probably a little consolidation what we're having right now, said Randy Frederick, managing director of active trading and derivatives at Charles Schwab.

The Dow Jones industrial average <.DJI> dropped 105.58 points, or 0.82 percent, to 12,772.70. The S&P 500 Index <.SPX> fell 6.32 points, or 0.47 percent, to 1,344.18. The Nasdaq Composite <.IXIC> lost 8.04 points, or 0.27 percent, to 2,923.79.

Decliners on the Dow, which underperformed the broader market, included industrial and material stocks like Caterpillar Inc , down 0.7 percent at $113.66.

Earlier the Dow industrials were trading near a 3 1/2 high and the Nasdaq was at a more than 11-year high.

Also weighing on the market, European Union sources said finance officials were examining ways of delaying parts or even all of a second bailout for Greece, while still avoiding a disorderly default. That rekindled fears about the region's debt crisis.

A debt-laden Chinese technology firm seeking to ban all iPad shipments in and out of the country has been told that China's customs authorities are unlikely to intervene in the trademark battle.

(Reporting by Rodrigo Campos; Editing by Kenneth Barry)