Ideally, you don't.

"This has never really worked for me" - yeah, exactly! Unless you have absolutely brilliant skills where you can a vista the thing quite flawlessly, it'll need at least a few nights of sleep to settle.
The fastest I have crammed is probably the Bach Prelude & Fugue in F major from WTC Book 1 in 1-2 days before a lesson. I have also crammed a rough version of the first movement of the Mendlessohn D minor trio for a rehearsal in a week.
What's worked for me is to practice one small fragment at a time multiple times until I can play that particular fragment in tempo, then linking together fragments. I would practice each joined combination of fragments multiple times, making sure to play at a speed where I don't stumble until I can play the joined fragments, and so on. Once the entire piece was worked through, I would do the whole process again, identifying what spots needed more work to iron out compared to others and focusing on those fragments and/or seams between fragments.
Practically, in the Bach Fugue, many fragments were maybe 1-2 bars at the most. I would work on one bar until it felt reasonably "settled", then practiced the next bar until it settled. Then I practiced joining bar 1-2 together and playing both bars until the "seam" between the two was ironed out. Then I practiced bar 3, and then the seam between bar 2 and 3, and so on.
This can be quite tedious and requires discipline and honesty with yourself, are you rushing and making mistakes, or are you truly, carefully practicing everything correctly and slowly? One thing that's helped me is to start from the end of the peice and work backwards to the start, it makes it harder to fall for the temptation to continue playing through the piece.