This paper studies a new switch QR decomposition adaptive filtering algorithm for acoustic echo cancellation (AEC). Based on the flexible p-TA-QR-LS algorithm, the proposed algorithm employs an efficient switching scheme based on voice activity detection and linear prediction, which enables it to distinguish the significant and insignificant input speech periods. The resultant variable mode p-TA-QR-LS algorithm can work with two switching modes (p=1 and N) and is thus suitable for AEC problem where the needs for convergence enhancement and for computational complexity reduction can be balanced.