HIV medication in the 'states apparently falls under medicaid coverage, so most people who couldn't afford them would have gotten them provided by medicaid funding, but medicaid funding was very narrow and a lot of people didn't qualify for it and were still unable to afford medication. There's a bunch of charitable groups who help people with HIV as well who would probably help people afford meds.
If you fell into the bracket where you didn't qualify for medicaid nor had the money to afford the meds yourself, you probably basically just died, not getting much medical help apart from palliative care as you were actually dying.
The medicaid expansion Obama instituted did increase the number of HIV sufferers claiming medicaid support, in addition to them having an easier time in general getting insurance.
Again, it is a bit more complicated.
Under Medicaid pre-ACA expansion, being low income wasn't enough to qualify you. You had to be low income as well as being a parent or having a disability.
HIV wasn't counted as a disability for the purposes of Medicaid, but AIDS was. So unless you qualified under another criteria you didn't qualify for Medicaid funding until your HIV progressed to AIDS, at which point a lot of the damage has been done and life expectancy plummets, even with treatment.
The Medicaid expansion - for the states that opted in - took away this extra requirement. So all low income adults were covered, regardless of health status.
At the same time the ACA required that preventative measures, including HIV screening, be covered by all insurance policies.
It also made it so that pre-existing conditions (such as HIV) couldn't disqualify someone for getting insurance.
Those are the big three that resulted in a lot more people with HIV being covered either by Medicaid or private insurance, while getting the treatments they needed funded.
Having said all that, there is a separate federal program that funds HIV/AIDS treatment;
the Ryan White program. This is a pool of federal money given as grants to pay for HIV/AIDS treatment, insurance, research and infrastructure. They estimate this 'reaches' 52% of those diagnosed, although what percentage of the medical costs are covered are less clear, and in the past at least there have been waiting lists for the grants.
So it isn't entirely that the government was just ignoring people and letting them die, at least after 1990 or so.
Even for those covered by separate funding though, if the pre-existing conditions clause is removed they will have trouble getting insurance to cover other medical costs. Remember that HIV can be a risk factor for other diseases, so having insurance for those costs is important even if HIV drugs are paid for elsewhere.