An explanation given in the notes section of the book*:
How it was that he came by the name of Sweeney . . . there to look for it: the name is indeed an unusual one. The surname Todd or 'tod'
[sic], a northern word of unknown origin from Middle English, means,
literally, 'fox'; metaphorically it was used to refer to 'a person
likened to a fox; a crafty person' (OED). Sweeney or 'sweeny' [sic],
although referring literally to atrophy in the shoulder-muscles of a
horse, was also more commonly and figuratively used to connote 'the
stiffness of "pride" or self-conceit' (OED). Alternatively, Sweeney's
name may have recalled for some readers the Irish name and figure of
the mad king 'Sweeney' of the Buile Suibhne of Celtic legend. Louis
James, in his Fiction for the Working Man (Oxford, 1963), first noted
with reference to the story's original title that an interesting
process of association of ideas is suggested by the fact that the
London Directories record an "S. Todd, pearl-stringer", who lived at
Clerkenwell at this time' (191). Finally, the name may simply be an
unconsciously reversed recollection and slightly jumbled
reformulation, in its assonance, of the character of 'Poll
Sweedlepipe' in Dickens's Martin Chuzzlewit (see Introduction, xvii).
Sweedlepipe, whose services as 'an easy shaver ... and a fashionable
hairdresser, also' were advertised to his clients in his shop-window
at Kingsgate Street, High Holborn, would still have been fresh in the
public's imagination.
(*Sweeney Todd: The Demon Barber of Fleet Street, US & Canada Edition)