U.S. stocks slumped Thursday, with key indexes notching a second day of 1 percent declines as Middle East violence pushed oil to a record and drove investors to safe-haven assets, such as bonds and gold.

The Dow Jones industrial average fell 166.89 points, or 1.52 percent, to end at 10,846.29, while the Standard & Poor's 500 Index slid 16.31 points, or 1.30 percent, to finish at 1,242.29. The Nasdaq Composite Index was down 36.13 points, or 1.73 percent, at 2,054.11.

Click here to visit FOXBusiness.com's Investing Center.

Concerns about the prospects for corporate profits also persisted after newspaper publisher Tribune Co. (TRB) posted a drop in quarterly earnings and snowmobile and motorcycle maker Polaris Industries Inc. (PII ) said earnings fell and showed further evidence that U.S. consumers are pulling back on discretionary spending.

A brokerage downgrade of retailer Wal-Mart Stores Inc. (WMT ), caused in part by steep energy prices, sent retail sector stocks lower.

"Everybody's just running for safety," said Paul Mendelsohn, chief investment strategist at Windham Financial Services in Charlotte, Vermont.

"It's a combination of geopolitical events pushing oil almost to $77," Mendelsohn added. "That, on top of what we've seen with earnings so far, the market's not impressed."

The Israeli army said a rocket fired by Lebanese armed group Hezbollah hit Haifa, Israel's third-largest city. Hezbollah denied firing a rocket at Haifa.

The Dow was down a total of about 250 points over two days.

All but three of the 30 Dow components were lower and the Nasdaq closed at its lowest level since October. The S&P 500 is also now negative on the year.

Stocks found little support from higher-than-expected profit reports from PepsiCo Inc. (PEP), the world's No. 2 soft drink company.

One of the bigger drags on the Dow and the S&P 500 was Wal-Mart, which slid 2.2 percent, or 99 cents, to close at $44.16 on the New York Stock Exchange after Merrill Lynch (MER) lowered its rating to "neutral" from "buy." Merrill said Wal-Mart's customers were grappling with steep energy prices, rising interest rates and stricter credit-card payment terms.

The Wal-Mart news hurt other retailers, sending the S&P retailing index down nearly 1 percent.

Crude oil for August delivery surged to a record $76.85 a barrel, the highest for a front-month contract since the New York Mercantile Exchange started trading oil futures in 1983. The NYMEX August crude contract ended the session up $1.75 at $76.70, a record settlement price.

Oil prices had already reached record highs earlier in the day as supply worries were aggravated by a host of geopolitical concerns, including Iran's nuclear standoff with the West and damage to a Nigerian pipeline caused by explosions.

Gold futures, seen as a hedge against global risk, soared on the COMEX division of the New York Mercantile Exchange, with the August gold contract climbing $3.20 to settle at $654.40 an ounce.

U.S. Treasury debt prices rose, with the benchmark 10-year Treasury note 7/32 higher and the yield slipping to 5.08 percent from 5.11 percent on Wednesday.

PepsiCo said quarterly earnings rose and beat Wall Street estimates, pushing shares up 1.6 percent, or 97 cents, to $62.07 after hitting a record high of $62.33.

Trading was active on the New York Stock Exchange, where about 1.78 billion shares changed hands, above last year's daily average of 1.61 billion. On Nasdaq, about 2.07 billion shares traded, above last year's daily average of 1.80 billion.

On the NYSE, decliners beat advancers by a ratio of about 7 to 2. On Nasdaq, about four stocks fell for every one that rose.

Click here to visit FOXBusiness.com's Investing Center.