SPENCER: Self-Adaptive Model Distillation for Efficient Code Retrieval