Found via that invaluable historian and documenter of LGBT history and its sources, Rictor Norton, a useful little page from the Wiltshire and Swindon History Centre on sources for LGBT history in local record offices.
I am particularly interested to note that they recommend caution in assumptions that lunatic asylum records will be a fruitful source - my own impression from the records of private lunatic asylums held in the Wellcome Library is that any such cases were few and far between, and such instances as I've come across of individuals incarcerated where there appeared to be some same-sex component to their behaviour manifested other issues which must have contributed probably even more strongly.
The sexual practice that crops up most frequently in records of C19th asylums is (as one might predict) self-abuse, mostly in terms of the strategies for its prevention.
One of the reasons why I would not expect men who had been engaging in same-sex activity to be found in poor law and voluntary asylums would be that non-elite men would have been primarily subjected to the various criminal and vagrancy penalties and thus be dealt with within the judicial system rather than the emergent discipline of psychiatry.
The situation is somewhat fuzzier if one considers the class which could have afforded to keep family members perceived as deviant in a private institution. Nonetheless, as already mentioned, these constitute a statistically meaningless number of cases (this is borne out by Charlotte Mackenzie's meticulously detailed analysis of the copious surviving records of Ticehurst House in the Wellcome Library, published as Psychiatry for the Rich). Perhaps the disgrace of having a certified lunatic in the family, and its impact on, for example, the matrimonial prospects of other family members, led those who could afford it to seek other expedients to contain potentially scandalous relatives, for example sending them to live abroad as 'remittance men'.