Apple has typically supported Mac hardware for about 7 years from introduction for a while now. That is provided you're updating to the last supported version of macOS for it and then all security updates. I'd be surprised if they changed this much either way for Apple Silicon.
One issue is that Apple never tells you when they end of life a given version of macOS officially, so you're left guessing a bit.
One issue is that Apple never tells you when they end of life a given version of macOS officially, so you're left guessing a bit.