I think you need to go further than looking at the total misery, although that is definitely an important first step in preventing false accounting. You need to account for some basic “game theory / behavioral economics / control system”-type stuff: when you decrease or increase one variable, what happens to the other variables?
Applied at a crude level, this tells you that removing punishment misery will cause addiction misery to rise (which is an important refinement - a “total misery accounting” perspective that doesn’t have this included will believe that removing punishment misery would leave addiction misery unchanged, thus improving total misery).
Applied at a more sophisticated level, this gets you analyzing incremental changes in punishment or addiction policy: e.g. this new law adds x punishment misery, how much does it reduce addiction misery by? If the answer is “less than x”, you now have some objective basis for concluding this policy is “needlessly cruel”.
Applied at a crude level, this tells you that removing punishment misery will cause addiction misery to rise (which is an important refinement - a “total misery accounting” perspective that doesn’t have this included will believe that removing punishment misery would leave addiction misery unchanged, thus improving total misery).
Applied at a more sophisticated level, this gets you analyzing incremental changes in punishment or addiction policy: e.g. this new law adds x punishment misery, how much does it reduce addiction misery by? If the answer is “less than x”, you now have some objective basis for concluding this policy is “needlessly cruel”.