MINNEAPOLIS — While General Mills, Inc. has seen some modest improvement to its operating environment in recent months, inflation and supply constraints continued to pressure the company’s margins.

During a Dec. 20 conference call with analysts to discuss second-quarter results, Kofi Bruce, chief financial officer, said the company is working to return its attention to holistic margin management practices.

“So structurally, we view our job to kind of claw back about 150 basis points of margin versus our sort of pre-pandemic level,” Bruce said. “I think the stable environment from a supply chain standpoint, will be one of the first and the most important things.

“And then second, it will be probably a return to more historic levels of inflation, moderation of inflation, which — who knows when that’s coming. But we’re certainly positioning our business to make sure that we’re taking the cost out as we have the opportunity to do so.”

As some logistics challenges have eased, General Mills has been able to improve customer service levels, said Jeff Harmening, chief executive officer, in prepared remarks accompanying release of second-quarter results. By the close of the second quarter, which ended Nov. 27, service levels in US retail had reached the high-80% range, which was up from the mid-80% range in the first quarter, though still below the normal range of 98% to 99%, the company said.

“Despite these improvements, supply disruptions remain well above historical averages, and we aren’t forecasting a return to pre-pandemic levels of supply disruptions or customer service during this fiscal year,” Mr. Harmening said.

General Mills’ net income for the second quarter ended Nov. 27 was $606 million, equal to $1.01 per share on the common stock, an increase of 1% from the prior-year quarter when the company earned $597 million, or 98¢ per share.

Sales were $5.22 billion, up 4% from $5.02 billion in the same period a year ago.

The North America Retail segment posted second-quarter net sales of $3.37 billion, an increase of 11% from $3.04 billion in the year-ago quarter. General Mills said the increase was driven by favorable net price realization and mix, partially offset by lower pound volume and a 2-point headwind from the Helper and Suddenly Salad divestiture.

Net sales rose 18% in US Snacks, 10% in US Meals & Baking Solutions, and 10% in US Morning Foods. Segment volume was down 8 basis points in the quarter.

Retail sales in the US cereal business were up 20% compared to 2018, Mr. Harmening said.

“We’ve gained two-and-a-half share points over that time and solidified our No. 1 position in the category,” he said.

General Mills has grown retail sales in the Pillsbury US Refrigerated Dough business by nearly 50% over the past five years, to nearly $2 billion, Mr. Harmening said.

“Our most recent messaging with consumers highlights the many ways to conveniently ‘make homemade’ using Pillsbury dough products outside the oven,” he said. “And we are leveraging our data and connected commerce capabilities to personalize our messages. For example, by targeting our ‘make homemade’ messaging to consumers who recently purchased an air fryer, we were able to drive lower cost-per-click and convert a higher share of our new Pillsbury consumers, further building confidence in the value of our first-party data.”

Retail sales in US fruit snacks were up nearly 70% since fiscal 2018 to more than $800 million dollars. The company’s market share of fruit snacks reached 54% of the category.

“We accomplished these results despite being capacity constrained for much of that time,” Mr. Harmening said. “But we completed a $100 million capacity expansion on fruit snacks in Q1, which has allowed us to execute new channel expansion plans for e-commerce and convenience stores.”

Second-quarter net sales for the Pet segment essentially matched year-ago levels at $593 million, with favorable net price realization and mix offset by lower pound volume. Organic net sales were flat. Net sales performance was negatively impacted by a reduction in retailer inventory, with all-channel retail sales up high single digits in the quarter.

Pet segment operating profit dropped 34% to $87 million compared with $132 million a year ago. The decrease was driven primarily by high-teens input cost inflation, a significant increase in costs related to capacity expansion and supply chain disruptions, and lower volume, including the impact of the retailer inventory reduction, according to General Mills. These headwinds were partially offset by favorable net price realization and mix.

“On the cost side, we continue to forecast total input cost inflation of approximately 14% to 15% for the full year, including double-digit inflation in the second half,” Mr. Harmening said. “Volume elasticities continued to remain below historical levels in the first half, particularly in North America Retail. We are watching these trends closely, but we do not expect a return to pre-pandemic elasticity levels during fiscal 2023.”

General Mills’ operating profit margin of 15.3% in the second quarter was down 60 basis points from the year-ago quarter. Adjusted operating profit margin was 16.9%, up 60 basis points. Items affecting comparability included mark-to-market effects of $25.1 million, Investment activity of $35.7 million, product recall of $2.9 million, restructuring charges of $11.6 million, acquisition integration costs of $2.8 million and transaction costs of $1.8 million.