Smithfield Foods Inc posted a smaller-than-expected quarterly loss on Tuesday on better-than-anticipated margins in its hog and pork businesses, but high feed costs weighed on results.

Profits on pork sales were down due to the recession, but the packaged meats segment of that unit had record earnings.

Influenza A H1N1, commonly called swine flu, did not affect the quarter, which ran through May 3, but did hurt business later in May. The flu's impact on domestic sales is lessening, but continues to restrict exports, specifically to China, the company said.

While feed costs should moderate going forward, Smithfield said it would reduce its sow herd an additional 3 percent following a previous 10 percent reduction.

I am pleased to report that we are continuing discussions regarding refinancing with various lenders, well in advance of current maturities, Chief Executive C. Larry Pope said in a statement.

The company's financials and debt have been a concern of analysts and on Tuesday it reported more than $1.1 billion in liquidity at the end of the fiscal year and had pared debt by more than $890 million.

Both the hog production and pork processing businesses posted better margins than we anticipated, Ken Goldman, J.P. Morgan analyst, said in a note.

The Smithfield, Virginia-based company reported a loss of $78.8 million, or 55 cents per share, for the fourth quarter that ended May 3, compared with a year-ago profit of $2.4 million, or 2 cents per share

Revenue was $2.85 billion, compared with the year ago's $2.87 billion.

This year's quarterly results include a one-time gain of $13.1 million for foreign tax credits.

Wall Street analysts on average expected a 62-cent-per-share loss, according to Reuters estimates.

For the fiscal year, the company lost $190.3 million, or $1.35 per share, its first yearly loss since 1975.

To cope with recent losses, the company reduced its sow herd, closed plants, restructured operations, and negotiated new debt agreements.

The hog unit, the largest in the United States, had an operating loss of nearly $171 million, compared with a year ago loss of $129 million. The pork unit, also the nation's largest, earned $110.7 million, down from $138.5 million a year ago.

Smithfield has warned that its hog unit would likely lose money for much of the current fiscal year, which began in May.

Smithfield, on average, lost $20 per hundredweight on hogs during the quarter, largely due to high feed prices and expensive grain hedges.

Fearing a spike in corn prices, the company last year hedged corn purchases at about $6 per bushel through the quarter. However, corn prices later fell and traded at about $4 or less during the quarter.

(Reporting by Bob Burgdorfer, editing by Dave Zimmerman)