The Senate broke a week-long deadlock over a new farm bill yesterday by adopting an unusual something-for-everyone Republican compromise plan to cut the measure's costs.

Adopted 56 to 41, the compromise left the Senate in the curious and contradictory position of having passed both a one-year freeze on income supports for farmers and a more costly four-year freeze.

The Senate then locked its contradiction deeper into the bill by voting, 55 to 42, to table a motion by Sen. Tom Harkin (D-Iowa) to strike the one-year freeze provision from the package.

Approval of the package cleared the way for other amending efforts, but the first of them, a proposal by Sen. John Melcher (D-Mont.) to cut an additional $3.1 billion from the bill, lost on a 50-to-46 vote.

The compromise put together by Majority Leader Robert J. Dole (R-Kan.) during hours of back room negotiations sailed to victory when Democrats, lured by special blandishments for home-state farmers, voted with Republicans.

Democrats who held out for the four-year freeze complained about the contradictory provisions, but Dole justified his move as a way to push the bill quickly through the Senate and leave the major decisions to House-Senate conferees who must work out a compromise.

"This is a peculiar way of making progress," said Melcher, leader of the four-year freeze coalition.

"There's no law against passing legislation that is confusing and impossible to interpret. This accomplishes nothing in resolving the issue and determining what the will of the Senate is," he said.

"I can't believe they put the contradictory language in the same-sized print," said Sen. David L. Boren (D-Okla.). "Usually they put it in fine print. That's bound to be precedent-making, even in this institution."

Agriculture Committee Chairman Jesse Helms (R-N.C.), who backed the one-year freeze, said he didn't like the compromise, although he helped Dole put it together.

"I've been a party to the development of this modification, but I had to swallow hard and hold my nose," he said. "Neither the committee bill nor the modification meets our obligation under the budget resolution. Both repeat the failed farm policies of the past." But Dole argued that his package would cut about $12 billion from the three-year cost of the measure, bringing it near the $50 billion the administration has indicated it would accept. The budget resolution puts a $35 billion cost cap on the bill; the pre-Dole version of the bill was estimated at $65 billion by the administration.

Helms later charged privately that "control of the Senate in 1986 is the real issue in this farm bill. The money issue is way down in second place."

It seemed that raw politics, in the form of special favors for different regions, carried the day for Dole. His approach effectively broke up a seemingly solid farm-state front of senators holding out for general improvements in the bill.

Rice-state senators were drawn over by a provision increasing program benefits for rice farmers. Southern sugar and soybean-area senators climbed on board when Dole offered retroactive disaster loans to farmers devastated by recent hurricanes and floods.

A new program to pay sunflower farmers a direct subsidy of $35 for every acre they plant attracted Sen. Mark Andrews (R) of North Dakota, a major sunflower state. Andrews had lined up for months with Democrats who insisted on more generous programs for economically troubled farm areas.

"This is a package that may save us from bankruptcy," said Sen. J. Bennett Johnston (D-La.), whose state is a major sugar producer. "I simply can't vote against a package that helps my farmers."