I just went through this same thing. I had a bad vacuum leak in the intake manifold. The only way it would idle was to advance the timing the way you are describing.