This is something I do in my presentations. I have speaker notes scattered throughout the slide deck with the “beats” of the talk—10 minutes, 20 minutes, etc.
If I hit one of those slides and I’m ahead of schedule, I can go on a few more tangents. If I hit one of those slides and I’m behind schedule, I can cut to the chase. Either way, having those decision points spread throughout the talk really helps to keep things smooth.
One thing that can really help in the delivery is knowing if you’re running fast or slow before you crash into the end of your talk. That way you can make adjustments as you go along by glossing over smaller points to speed up or expanding more on your ideas to slow down.