The problem is you're not thinking of externalities of homelessness, much like a functioning health system w/ insurance.
Ultimately, saying neither of these is worth spending communal government revenues on collapses down to "I'm okay with people dying on the street."
Which is not offered as a straw man, but because that's a very possible outcome. And given that, if we're not okay with that, then we're going to spend significant resources to keep that from happening (ER care, homeless programs).
Social security attempts to invest that earlier in a person's life, so that the money treating more dire circumstances can be saved.
... And also allows for some measure of human dignity for those who might not have been taught about compound interest at age 6.
It seems valuable to society to not have old, homeless people causing trouble. But that's just me.