One who enjoys pain.
Could be used to describe a sadist, masochist or sado-masochist. The word "sadist" itself derives from the Marquis de Sade, a french writer of sadistic novels. Therefore "algophilist" could be used as a synonym by a writer who did not wish to reference a word based on a historical figure.
Possibly coined by Gene Wolfe in his "Book of the New Sun" series, set on Urth.
"She had boasted that she had made tribadists of women. She came near to making an algophilist of me" - Severian