AutoChunk: Automated Activation Chunk for Memory-Efficient Long Sequence Inference