Quoted word for word, in order of authority: the Church's councils, popes and catechisms first, then the Fathers, then later saints and Doctors, then Catholic commentators.
“The pains of hell compassed Me about” (ver. 5). Among those that compassed Me about to destroy Me, were pains of envy, which work death, and lead on to the hell of sin. “The snares of death prevented Me.” They prevented Me, so that they wished to hurt Me first, which shall afterwards be recompensed unto them. Now they seize unto destruction such men as they have evilly persuaded by the boast of righteousness: in the name but not in the reality of which they glory against the Gentiles.
Reply to Objection 2: Sorrow is twofold: one is the suffering of pain which men endure for actual sin, according to Ps. 17:6: "The sorrows of hell encompassed me." Another sorrow comes of hoped-for glory being deferred, according to Prov. 13:12: "Hope that is deferred afflicteth the soul": and such was the sorrow which the holy Fathers suffered in hell, and Augustine refers to it in a sermon on the Passion, saying that "they besought Christ with tearful entreaty." Now by descending into hell Christ took away both sorrows, yet in different ways: for He did away with the sorrows of pains by preserving souls from them, just as a physician is said to free a man from sickness by warding it off by means of physic. Likewise He removed the sorrows caused by glory deferred, by bestowing glory.
Summa Theologiae III, q. 52, a. 2: Whether Christ went down into the hell of the lost? Reply to Objection 2 (tr. Fathers of the English Dominican Province)
To cite this page: The Summa, “Psalm 17:6”, https://thesumma.org/read/bible/ot/psalms/17/6. Every quotation names its source; where each text comes from is listed on Sources and corrections.