As the Supreme Court weighs the constitutionality of the Patient Protection and Affordable Care Act’s “Individual Mandate”—and maybe the law itself —a pretty sweet deal for the drug industry hangs in the balance.

“The potential complete demise of Obamacare as written is, as the saying goes, throwing the baby out with the bathwater,” said Peter Pitts of the Center for Medicine in the Public Interest, a caustic critic of some parts of the law. “For pharma, the ACA is a gift, bringing in anywhere between 30-40 million people who could not previously afford pharmaceuticals.”

That’s a huge boon at a time when new drugs are few and far between.

The pharma industry was bitterly divided over the law when it passed two years ago after months of acrimonious debate. Billy Tauzin, the longtime Congressional committee baron and fixer extraordinaire, resigned abruptly from his post as head of PhRMA during one rough patch in the legislative process. A number of leading pharmas were unhappy with the deal Tauzin negotiated with the White House, for which the industry had agreed to shell out nearly $100 billion in drug discounts for federal health programs in exchange for a seat at the table, and now it looked like Tauzin had given away the store for nothing.

But in the end, the industry was able to use its leverage to fend off provisions that would have allowed direct price controls and restricted drug marketing. The macro-level tradeoff was this: Smaller profit margins, thanks to those up-front rebates and other cost-control measures built into the law, in exchange for greater volume in the years to come as tens of millions of Americans are insured. Tauzin’s pricey gambit bought the industry a law it could live with, for the most part, though PhRMA continues to fight the PCORI and IPAB provisions, which the trade group fears could bring about price controls on prescription drugs and lay the foundations for comparative effectiveness testing, among others. Those parts of the law, in particular, have inspired apocalyptic talk.

“It was the same thing with the Medicare Part D [prescription drug benefit], and you can go all the way back to the ‘90s, with managed care,” said J. D. Kleinke, a medical economist and resident fellow at the American Enterprise Institute. “People said it was going to be the end of pharma, and instead, there was a huge volume increase and it wound up being a good thing.” Kleinke thinks IPAB would focus on surgical interventions in the elderly, and not, with exception to last-dash, long-odds and high cost oncology treatments, on drugs and biologics.

“They’ve got bigger fish to fry,” said Kleinke.

Few legal observers think the Court would throw out the law altogether. However, the question of whether the Court’s conservative/libertarian majority might throw out the Individual Mandate, which requires almost every American to buy health insurance, is anyone’s guess. The Obama Administration has asserted that the unpopular provision is not “severable” from the larger law, though this seems more a political position than a legal one. Still, should the Court find the Individual Mandate unconstitutional, many would opt out and the cost of insurance would spike sharply as a result, limiting the volume gains that made the deal a winner for the industry.

“If the insurance mandate is nullified, the impact would be indirect but real,” said John Kamp, executive director of the Coalition for Healthcare Communication (and a former Constitutional law professor). “The insurance mandate provides important financing support for the extension of insurance to the currently uninsured. In short, the ACA needs young, light users of insurance to subsidize the older, heavy users. Without the youth subsidy, the cost pressures on the entire plan are even more immense than already recognized.”

Moreover, while the insurance expansion aspect of the law has gotten most of the attention, much of the ACA consists of various efforts to “bend the curve” of spiraling healthcare costs that threaten to bankrupt federal health programs, including the popular Medicare.

“So if the subsidy dies, policymakers will be looking elsewhere to reduce costs,” said Kamp. “Every cost center—especially hospitals, providers and medicine companies—will be pressured to reduce costs. That will lead to ever more pressure on marketing costs, as well as all other costs faced by medicine companies.”