Your computer is overheating. You didn't say, but I'll assume this is a desktop computer?
Clean out all dust from inside the case and blow out all fans with a can of Compressed Air. Restart the computer and make sure all fans are spinning freely, not trapped by wires etc. You may need to re-apply thermal paste between the Heat Sync and the processor. Boot into Setup (Bios) and go to PC Health, look at the temperatures.
If the fans are spinning normally but your computer is hesitating, then try a Clean Boot.