CHICAGO (Reuters) - Illinois’ already low credit rating could be downgraded if the state does not end its record-breaking budget impasse over the next two months, Moody’s Investors Service said on Thursday.

The credit rating agency said the state is at a “critical juncture,” and failure to reach a budget consensus by the May 31 end of the legislative session would “signal deepening political paralysis, heightening the risk of creditor-adverse actions.”

“This is sort of a do-or-die moment here with respect to the leaders in state government,” Moody’s analyst Ted Hampton said.

Moody’s rates Illinois Baa2, which is just two steps above the junk level and is the lowest rating among the 50 states. Illinois also pays a bigger penalty than other states in the U.S. municipal bond market after six credit downgrades since 2015 by the three major rating agencies.

A 21-month standoff between Illinois’ Republican governor and Democrats who control the legislature has left the state operating on continuing appropriations and court-ordered spending.

As a result, the state’s pile of unpaid bills, a barometer of its deep financial woes, has tripled since 2015, hitting a record-high $13 billion last week.

If Illinois begins a third straight fiscal year without a complete budget, money set aside for payments on its $26 billion of outstanding general obligation bonds could be at risk of being borrowed to cover operational expenses, Moody’s said in a report.

Another possibility could be that core operational needs would be prioritized over debt service, it added.

With a budget deal, Illinois would be able to stabilize its financial position, the report said, noting that political gridlock, not fundamental economic factors, are largely driving the state’s financial pressures.

Asked about Moody’s report by a reporter in the state capitol, Governor Bruce Rauner said he continues to push for a budget that includes structural changes to spur economic growth.

Moody’s said a bipartisan bill package that surfaced in the Senate in January but has since stalled could improve the state’s financial prospects.

The package includes legislation to complete the fiscal 2017 budget, which expired on Dec. 31, as well as to hike taxes, cut pension costs by about $1 billion annually, authorize borrowing to pay down the bill pile, expand casino gaming and freeze local property taxes.

“We continue to work toward compromise but aren’t there yet,” said John Patterson, a spokesman for Democratic Senate President John Cullerton.

Illinois’ fiscal year begins July 1.