JOSHUA FREED AP Business Writer

Stocks raced higher after two down weeks, as investors warmed up to the idea that the economy is getting better.

Stocks have fallen lately after good economic news as investors worried that the Federal Reserve would think its stimulus was no longer needed. But Monday’s gains, driven by two corporate deals and a strong report on manufacturing, suggested that investors are focused more on growth and less on the central bank’s actions.

For a while, investors felt, "’Oh my goodness, we won’t be able to survive without Fed support.’ But people are actually seeing that things really are getting better," said Brad McMillan, chief investment officer for Commonwealth Financial.

The Fed meets for two days beginning Tuesday, and officials could signal when the Fed will dial back the stimulus that has helped boost the stock market this year.

The Dow Jones industrial average rose 129 points, or 0.8 percent, to close at 15,884.57, after rising almost 175 points in the morning. The Standard & Poor’s 500 index rose 11 points, or 0.6 percent, to 1,786.54. The Nasdaq composite was higher by 28 points, or 0.7 percent, at 4,029.52.

The gains ended what had been a four-day losing streak for the S&P 500 index, beginning the week on the upbeat note after two down weeks.

Two major deals caught investors’ attention: Chipmaker Avago Technologies is buying LSI Corp. for $6.6 billion. Avago rose $4.45, or 10 percent, to $50.10, while LSI rose $3.05, or 39 percent, to $10.96.

AIG is selling its aircraft leasing business for about $5.4 billion to Dutch leasing company AerCap. AIG has been selling major assets after getting a bailout during the financial crisis. Its shares rose 55 cents, or 1 percent, to $50.28.

The Avago-LSI deal helped make tech stocks the biggest gainers among the 10 industries in the S&P 500. Others winners included computer hard drive makers Western Digital and Seagate, which benefited from analyst upgrades.

Of those 10 industries, only consumer staples fell.

Also Monday, the Federal Reserve said factory production accelerated in November as auto production surged. The gains in manufacturing could help boost economic growth.

Just last week, such positive reports made investors nervous. They feared the Fed would think the economy was doing so well that its $85 billion in monthly bond-buying was no longer needed.