That Benedict IX had sexual relationships with men seems to be beyond reasonable doubt. In his diatribe against "sodomy" among the Catholic clergy (Liber Gomorrhianus), St. Peter Damian described him as "feasting on immorality" and "a demon from hell in the disguise of a priest". The modern researcher Lynne Yamaguchi Fletcher, in "The First Gay Pope and Other Records", rightly called Benedict IX (r. 1033-1045; 1047-1048) “the first pope known to be primarily homosexual.” Benedict’s pontificate, which was known for homosexual orgies in the Lateran Palace, “turned the Vatican into a male brothel” and was so scandalous that he was deposed, not once but twice.
Benedict IX (1021--ca. 1052) was the son of the count of Tusculum. He imitated John XII in staging licentious orgies. These and other excesses caused such indignation that Benedict was deposed in 1045, but then reinstated, only to be deposed again. He disappeared into such deep obscurity that his actual date of death is unknown.
Matt & Andrej in their Biographies of LGBT people, quote this description (original source not stated):
At the death of John XIX, his brother Alberic decided to keep the papacy in the family by having his young son Theophylactus elected (October, 1032). Theophylactus, a young man probably about twenty years old, was a cleric. That was about his only qualification for the papacy. Unqualified by his youth, his bringing up, his depravity, Benedict IX became one of the very few really disreputable popes. He was known for homosexual orgies, at the Lateran Palace. The story of Benedict's pontificate is as unsatisfactory as his life. The Romans rose against him probably about 1036 and drove him from the city. Benedict proceeded to Cremona, where he met Emperor Conrad II and received a promise of protection. By imperial influence Benedict returned to Rome, only to be driven out again in 1044.
This time there was a fight, and Benedict's supporters grimly clung to a foothold in the Trastevere district. Inside the city, John, bishop of Sabina, was set up as Pope Sylvester III, but Benedict was not idle. He had fled for help to his family's base at Tusculum and within two months his tough Tusculans fought their way into the city, sent Sylvester III back to his diocese of Sabina, and restored Benedict IX.
Once restored, Benedict did not feel at ease on the papal throne. For some reason, in 1045 he decided to abdicate. As Desiderius, the abbot of Monte Cassino (later Pope Victor III), put it, "Devoted to pleasure, he preferred to live like Epicurus rather than like a pope." Consequently, he handed over the papacy to the worthy archpriest, John Gratian. Benedict did not go empty-handed. Gratian paid a large sum to get rid of this offensive character. The charms of retirement soon wore thin for Benedict, and a short time after his abdication he was once more claiming to be pope. With Sylvester III and Benedict IX fighting Gregory for the control of Rome, things were in a frightful muddle. This was ended by Henry III, who had succeeded his father Conrad II in 1039. Henry came down into Italy, cooperated with Gregory to get rid of the pretensions of Sylvester and Benedict, and then had a council demand and receive Gregory's abdication. Henry then put in a German pope--Clement II. Benedict made one more comeback. After the death of Clement II, he once again entered Rome and held sway at the Lateran, but only from November 8, 1047 to July 17, 1048. Henry III insisted on his removal and brusquely ordered Boniface, marquis of Tuscany, to expel Benedict.
What happened to Benedict after this is obscure. According to one report, which it may be hoped is true, Benedict retired to the abbey of Grottaferrata, resigned all claim to the papacy, and spent his last years as a penitent. Scandalous as Benedict had been, he carried on the routine business of the papacy. And like the few other bad men who were popes, Benedict taught nothing but the pure doctrine of Christ, though by so doing he condemned and did not excuse his own disordered life.