Thursday was a very bad day for China's economy, the world's second-largest and a crucial pillar of the global economy, with credit markets freezing up in an unnerving parallel to the first days of the U.S. financial collapse. The question of how bad depends on whom you talk to, how much faith you have in Chinese leaders and, unfortunately, several factors that are largely unknowable. But we do know two things. First, Chinese leaders appear to be causing this problem deliberately, likely to try to avert a much worse problem. And, second, if this continues and even it works, it could see China's economy finally cool after years of breakneck growth, with serious repercussions for the rest of us.

Things got so bad that the Bank of China has been fighting rumors all day that it defaulted on its loans; if true, this would risk bank runs and more defaults, not unlike the first days of the U.S. financial collapse. There's no indication that the rumors are true, and no one is running on China's banks. But the fact that the trouble has even gotten to this point is a sign of how potentially serious this could be.

Here's what has happened: China's credit market has been in a bubble for years, with too much lending and borrowing, similar to what happened in the United States during the financial crisis. All that lending helps grow the economy until, one day, the bubble bursts, and it all comes crashing down, as happened the United States. China's economic growth has been slowing, making a similar a crisis more likely. Chinese leaders seem to be trying to prevent a disaster by basically popping the bubble, a kind of controlled mini-collapse meant to avoid The Big One.

In a real, uncontrolled credit crisis like the U.S. financial meltdown, credit suddenly freezes up, particularly between banks, meaning that the daily loans banks were relying on to do business are suddenly no longer affordable. Banks with too many unsafe loans suddenly owe more money than they can get their hands on, sometimes leading them to default or even collapse. And that means that it suddenly becomes much tougher for everyone else – companies that want to build new factories, families that went to buy a home – to borrow money. That's an uncontrolled credit crisis, and a number of China-watchers have been worried that China, in its pursuit of constant breakneck growth, could be headed for one.

China's central bank, which is likely to tamp down all that unsafe lending and over-borrowing before it leads to a crash, appears to have forced an artificial credit crisis. (It tested a more modest version just two weeks ago.) It looks like the People's Bank of China has already tightened credit considerably, making it suddenly very difficult for banks to borrow money. Something called the seven-day bond repurchase rate, which indicates "liquidity" or the ease of borrowing money, shot way up to triple what it was two weeks ago.

This pair of charts, from the economics site Zero Hedge, shows the eerie parallels between today's freeze-up in the Chinese interbank lending market and what happened in the United States when Lehman Brothers collapsed, setting off a global crisis that we're still recovering from:

That second chart shows something called the TED spread, a key indicator of credit risk and how easy it is for U.S. banks to lend to one another.

Money markets in China have also skyrocketed to what the Financial Times' David Keohane called "silly levels." This chart, via Keohane and Reuters' Jamie McGeever, shows the money market rates way, way, way beyond any high of the last five years:

Here's where things get a little confusing. Bloomberg News reported Thursday evening Beijing time that, as panic moved through the Chinese financial system, the country's central bank stepped in and offered $8.2 billion in "relief" to the Industrial and Commercial Bank of China, which just happens to be both state-owned and the largest bank in the world. What does this mean? Maybe that Chinese leaders got cold feet and are trying to walk back the self-imposed crunch, maybe that China's largest bank managed to negotiate some preferential treatment, maybe that leaders are worried their most important bank might actually be less healthy than they thought and want to protect it from default. Or maybe this is just part of the process of easing down the markets. But then the Chinese Web portal Sina announced that the reports were false (thanks to Bill Bishop for this link), adding some unnecessary confusion and uncertainty to an already volatile situation.

So what happens next? There are four categories of outcome. The first is that Chinese leaders back off on the credit crunch and nothing happens, in which case they'll probably just try the strategy again later. The second is that they press on and it works miraculously, cleaning out the financial system without causing too much pain. The third is that this spirals out of control, maybe because Beijing underestimated the risk or acted too late, potentially sending the global economy lurching once more. The fourth, and probably most likely, is that this works but is painful, averting catastrophe but slowing the Chinese economy after 20 years of miraculous growth.

China-watchers, who tend to vary widely in their assessments of the country's economic health, seem to be converging on that fourth scenario, of a painful but necessary slowdown. Nomura, a Japanese investment bank, recently issued a note (via the Financial Times) addressing fears that China could face a financial collapse. Their less-than-comforting caveat: "This is a tricky issue, as the definition of 'financial crisis' can differ among investors." The bank predict that China will not slip into a full-on crisis, citing Beijing's control over the financial system and unwillingness to let it go under. But the Japanese bank warned: "Nonetheless, we expect a painful deleveraging process in the next few months. Some defaults will likely occur in the manufacturing industry and in non-bank financial institutions."

If that happens, China's growth would slow even more. HSBC just cut their prediction for Chinese GDP growth rate from 8.4 percent in 2014 to 7.4 percent, still high but a major drop that could plunge farther. This would be difficult for China, which has built its economy – and political stability – on keeping high economic growth. Recall that the U.S. financial collapse was disastrous for America's already unhealthy economic sectors: city budgets, real estate, news media. Something similar could happen in China, which is also facing a massive property bubble. All of this could also be dire for the rest of the world, which is heavily linked to China's economy and is still struggling to recover from the U.S. and European crises. Japan could be particularly vulnerable.

But believe it or not, if all of this occurs, it might actually be good news. It could well avert a much more serious, uncontrolled Chinese financial collapse. The nation's central bank has been successful in controlling market shocks like this, throwing around lots of money when it needs to. Officials seem to know what they're doing; an experienced China-watcher I talked to called it "one step back, two steps forward."

Still, we've got to step back before we can step forward, and the time between steps could be tough on a global economy that doesn't need any more strain.