Oftentimes, shoulder pain with overhead pressing is due to limited thoracic extension and improper scapular mechanics. If the thoracic spine doesn't extend enough and the shoulder blades don't rotate efficiently, this can be a recipe for a shoulder injury.
To perform the slide, stand at a wall with your arms on the foam roller. Brace your core to prevent spinal extension, then lean into the roller as you slowly slide it up the wall. At the top, while keeping your chin tucked, slowly press your head underneath the roller to achieve maximal thoracic extension and shoulder flexion.
By pushing your arms into the wall, you can really light up your scapular muscles and groove pain-free overhead motion. Do this for 10 reps, prior to your overhead pressing.
Remember, safe overhead pressing requires the coordinated action of three scapular muscles – the lower trapezius, the upper trapezius, and the serratus anterior. Fortunately, the foam roller wall slide nails all three.