I'm not sure you are considering how effective such a treatment might be. If the tech existed to create that full experience in the prisoner's head, meaning they experienced the full 20 years in their mind, it'd hardly amount to "a few frowny faced hours"
As far as the prisoner would be concerned, they'd be suffering the full sentence with plenty of time to consider their actions and be re-educated and reformed. Assuming this worked and the brain could even handle experiencing 20 years in the span of a few hours, he or she could potentially be rehabilitated and reintroduced as a healthy citizen without becoming an unwanted ward of the state draining money from tax coffers for decades. Boom, bam, 8 hours done, ready to reenter society and play by the rules.
And if it's someone we just plain don't want around for a long time, or who can't be rehabilitated, we can still send the worst offenders to a secluded prison or island and let them fend for themselves against the other unwanted convicts--John Carpenter style.
Come on, guys, don't be so boring.