The same way it is now. Although some might lean toward more leniency than others I'm not advocating letting murderers and rapists run wild -- or bankers either, for that matter.
Since you brought it up, however, I have given considerable thought to matter. The death penalty, for example. As an AP correspondent in Jacksonville, Florida, years ago I did extensive coverage of executions and death penalty appeals involving inmates at Florida State Prison. My inclination prior to this experience was that it was wrong for the state to take a life, but after observing and sometimes interviewing family members of murder victims I came to the conclusion that the use of capital punishment was intrinsic to our sense of justice.
If someone takes a life, then the loved ones of the person who was killed naturally want to avenge that death. The state cannot allow that, however. If A kills B and then a member of B kills A there could be a continuous stream of slaughter. So, the state says: We will do it for you. With reasonable exceptions, in the state of Florida and many other states the authorities take the life of the killer.
When the death sentence is delayed, or perhaps overturned, then the loved ones of the murder victim feel that justice is thwarted. I'm not saying this is right, just that it is a natural human reaction. Nor am I defending capital punishment.
In most countries there is no capital punishment. But in places where the political force is skewed strongly toward retribution and punishment for justice there often are death penalty laws. I believe there is a natural progression in civilized societies against such punishment, for a variety of reasons, just as corporal punishment is no longer used in public schools; whereas when I was in school the paddle was freely applied to errant youngsters. (Some people still think this is a good idea.)
Overall, though, society tends to evolve away from harsh reactions to behavior, toward more leniency and -- yes -- compassion. Recently, attention has been focused on the issue of providing college courses to prison inmates in New York State. Some are opposed to this on grounds that many people on the outside can't afford a college degree so why should taxpayers pay for felons to get one. Others argue that education can only help the inmates once their sentence is finished and therefore recidivism will decline to the point that it's actually more cost-effective to pay for the book learning. We'll see how that debate works out.
I think humans are already basically compassionate souls and will continue to become even more so, adapting our sense of justice as we go.