Interrelation between high-order harmonic generation and above-threshold ionization