Updated

With just hours to spare, Congress stepped Monday to finalize legislation to prevent doctors who treat Medicare patients from being hit with a 24 percent cut in their payments from the government.

The Senate's 64-35 vote sends a measure to delay the cuts for a year to President Barack Obama, who's expected to quickly sign it. The House passed the measure last week.

The $21 billion measure would stave off a 24 percent cut in Medicare reimbursements to doctors for a year and extend dozens of other expiring health care provisions such as higher payment rates for rural hospitals. The legislation is paid for by cuts to health care providers, but fully half of the cuts won't kick in for 10 years.

It's the seventeenth temporary "patch" to a broken payment formula that dates to 1997 and comes after lawmakers failed to reach a deal on financing a permanent fix.

The measure passed the House on Thursday, but only after top leaders in both parties engineered a voice vote when it became clear they were having difficulty mustering the two-thirds vote required to advance it under expedited procedures. Several top Democrats opposed the bill, saying it would take momentum away from the drive to permanently solve the payment formula problem.

There's widespread agreement on bipartisan legislation to redesign the payment formula that would doctors 0.5 percent annual fee increases and implement reforms aimed at giving doctors incentives to provide less costly care. But there's no agreement on how to pay the approximately $140 billion cost of scrapping the old formula.

Senate Finance Committee Chairman Ron Wyden, D-Ore., promised to keep pressing ahead with a long-term solution, proposing to use savings from the troop drawdown in Afghanistan to pay the cost. Republicans and most budget experts say such savings are phony and are demanding at least some of the money to come from cuts to Obama's Affordable Care Act.

"Paying for this through (war savings) is the mother of all gimmicks," said Sen. Jeff Sessions, R-Ala.

Groups representing doctors, including the powerful American Medical Association, opposed the legislation because it sets back the effort for a permanent solution.

Six Democrats opposed the measure, including Wyden, while 16 Republicans voted in favor of it.

"We just don't have the votes right now to fix this problem for good," said Majority leader Harry Reid, D-Nev., who negotiated the measure with House Speaker John Boehner, R-Ohio. "For the millions of elderly Americans and their doctors this fix is good news. It means the promise of accessible, quality health care to our nation's seniors is being honored for another year."

The heavily lobbied measure blends $16 billion to address Medicare physicians' payments with about $5 billion more for a variety of other expiring health care provisions, like higher Medicare payments to rural hospitals and for ambulance rides in rural areas. Manufacturers of certain drugs to treat kidney disease catch a break, as do dialysis providers and the state of California, which receives increases in Medicare physician fees in 14 counties such as San Diego and Sacramento that are designated as rural and whose doctors therefore receive lower payments than their urban counterparts.

The bill increases spending by $17 billion over the next three years, offsetting the cost with cuts to health care providers. The authors of the bill employed considerable gimmickry to amass the cuts, however, and fully half of them don't appear for 10 years. For instance, the bill claims $5 billion in savings through a timing shift in Medicare cuts in 2024.

Sen. Tom Coburn, R-Okla., cited the gimmicks as he criticized the legislation in a lacerating floor speech. He said the so-called offsets were phony and that the measure delays a long-sought overhaul of Medicare's fee-for-service system, which pays doctors according to the number of tests and treatments they perform.

"We are going to put off until tomorrow what we should be doing today," Coburn said. "It's a sham. ... It's nothing but gimmicks."

Other savings come from curbs on payments to hospitals that care for a large share of indigent patients. But those hospitals first get a one-year reprieve from cuts scheduled in 2016.

The measure would give Medicare doctors a 0.5 percent fee increase through the end of the year. It also creates two new mental health grant programs, including $1.1 billion over four years for improvements to community health centers and $60 million over four years for outpatient treatment for people with serious mental illness.

The measure solves the fee schedule problem through next March.

Because of a flawed formula dating to 1997, Medicare doctors are threatened with big fee cuts almost every year. After allowing a 4.8 percent Medicare fee cut to take effect in 2002, Congress has since stepped in 16 times to prevent the cuts.