Sanderson Farms (NYSE: SAFM) reported fourth-quarter and full-year earnings last week that were best described as ironic. The company reported record sales, but also record losses, which were almost as high as profits were last year. The key here is a total collapse in gross margin.

Because chickens are essentially just a commodity, profit margins for chicken companies can be highly volatile, even in normal times. Sanderson's gross margin can be 23% one year and -5% in the next year, depending on cost pressures, chicken supplies, and even the price of other meats. From 2001 to 2007, the price of corn for feed was at least pretty predictable, staying between $2 and $3 per bushel. Since then, corn hasn't fallen below $3, and more recently it's reached nearly $7.

The sudden spike in costs has put pressure on poultry producers, who, due to supply and demand factors, are unable to raise prices enough to compensate. Typically, companies in the industry respond by producing less, which has the benefit of keeping losses down and also raises prices by lowering supply. This year was different, with all of the major producers trying to outdo each other to steal market share. This just ended up hurting everyone's margins, as you can see below.

Company Year-Ago Gross Margin Current Gross Margin
Sanderson Farms 18.6% (0.4%)
Pilgrim's Pride 9.1% (3.3%)
Cal-Main Foods (Nasdaq: CALM) 19.2% 21.1%
Tyson Foods 5.4% (2.9%)

Source: Company filings.

The price of corn has fallen from its high earlier this year, but it's still substantially higher than its 10-year average and likely to remain so, while chicken prices have only risen very modestly. Cal-Maine, which sells eggs but not meat, illustrates how costs can be managed if only selling prices can be raised. Eggs have their own supply and demand characteristics, and so Cal-Maine isn't as affected as other chicken raisers.

Similarly, better-diversified companies like Tyson Foods and Brasil Foods (NYSE: BRSF) can lean on other segments for the time being, but chicken-only Sanderson and Pilgrim's Pride are having to take more extreme measures. Pilgrim's is raising cash with a rights offering to cushion its declining balance sheet, while Sanderson is extending its two-month production cutback all the way until October 2012. Until chicken producers can fix their gross margins, they're dead in the water.