Optimized valid length for ASDecoder