jelle i think you waste time with try use with tool table
dont forget you have many other cycle to run ,not only move axis
run the motor,drill head down,bit drill down(in many case need more then 1 )
if horizontal need also add more
so i think you batter think about M function with G52 inside
similier as Garham suggest
yaakov