I'm no expert but i had my Phenom fan spin really fast and kept shuttung down. I was told to make sure that the heatsink was free of fluff because it makes the fan spin fast and the CPU running hot, hence the shut down. It was full of fluff and now i check and clean it out regulaly.
Then you should run a malware/mining scan, and probably uninstall all old 3rd party apps.
Check all your privacy/access settings in every installed app.