You will dont lose any of your files, they're not saved on CPU, but in your HDD or SDD, as others said above.
Now, i have to say, never let you battery/laptop run out power, when the battery level is low, plug him in the outlet, this will save your battery life.
And about the CPU, like all other computer, laptops generate heat, and heat damage computers, they are enemies.
When using the laptop, always let the air vents free, blocking the vents will overheat the internal components, damaging CPU and other parts.
Your CPU could be overheated, and died.
If the only problem is your cpu who died, and your laptop is not so old, you can replace your cpu.