Shall We Pretrain Autoregressive Language Models with Retrieval? A Comprehensive Study