Although, we certainly do spend irrational amounts on healthcare, partly because consumers don't bear consequences for going with the pricey procedures.
There's also numerous layers of regulatory capture, artificial scarcity, and rent-seeking in order to protect various industry-wide or regional cartels. The combination of that with consumers who have no reason to care about price is a potent recipe for price gouging.
The AMA is one of those. Hospital associations, medical device associations, phamaceutical associations, electronic medical record companies, and so on all take their cut.
I think public investment in educating medical providers is too small (it shouldn't be profitable to wrap a provider in like 5 people...), but doctors that aren't total fuck-ups are doing great by the time they are 45. We are likely in a supply constrained situation right now, prices would be nicer if there was excess supply.
The problem is not that the AMA was able to attack socialized healthcare, but that the AMA was able to dictate who would be able to practice medicine, what their education should be, how much they should charge and how they would organize.
Any american could go abroad to a country like say, Argentina, get free medical education and come back and treat patients without half a million dollars debt. But its illegal.