AttentionPredictor: Temporal Pattern Matters for Efficient LLM Inference