There's always a few things to try, but here's two to start with.
1. Use a fine point Sharpie pen to put a witness mark on the cutter shank where it enters the router collet and try a cut again. When it finishes look at the reference mark to see if the cutter has slid upwards into the router collet. If the collet isn't gripping the shank tight enough it may be pushing the cutter upwards during plunges into the wood. Is the cutter center cutting? If not, it will need to be set up in software to ramp the cutter into the wood. Especially if it is a hard wood like oak and some dense tropical woods.
2. There may be binding in the Z axis in the downward direction, but not the upward direction. You can check for this by running the gcode in air without the router running, and listen to the sound of the Z axis while it is moving. If it has a very different sound in the downward direction that is a clue. After the run is completed, the tool should be the same distance from the table top as it was when it was started. If not, there is probably a mechanical alignment issue.
It is possible that there is a software issue that is causing the lost steps and more needs to be known about your setup before anyone here can help with that.
CarveOne
http://www.carveonecncwoodcraft.com