It is technically possible by the strict definition of CPU, - and indeed this is what happens on smartphones and systems like the Raspberry Pi- but not practically viable, nor applicable to a desktop or laptop - ie in practice you can do this on a low powered device running an Arm chipset, but not on a typical (X86 compatible) computer.
USB is 5 volts - the USB2 spec defined a maximum power of 500 watts = 2.5 watts of power - even USB3 is limited to 7.5 watts of power when in charge mode. A typical laptop hard drive requires this much current by itself. A typical intel Atom (low power) CPU requires between 6.5 watt and 12 watts - and this excludes the chipsets required to drive them - this means its impractical to create a proper "x86" PC which can be powered from USB - and this ignores the requirement to power the USB ports or screen on it.
Interestingly the Dell Venue 11 Pro - which is an 11.5" laptop/tablet type device has a USB connector for power - but the kicker is it uses a much higher voltage - 19.5 volts at 1.2 amps - which is not USB standard.
As far as protecting your gear, you may have recourse against your UPS company - the better UPS's have insurance for equipment damaged which was plugged into the UPS. Alternatively, in future, you could run it through a "Zap catcher" - which is designed to filter out power spikes, or, if money is not an issue, an "Online Inverter" UPS - cheap UPS's use "buck and boost" which - after filtering - connect the mails directly to the computer - Online inverters invert all power to a DC voltage, then back to 240 volts AC. This would prevent a surge from taking out the device on the line. Of-course, you need to ensure all devices are protected, or protect them as well - for example, you need to protect your monitor as well, and your network (use Wifi instead of Ethernet)
1This is a CPU, the thing you're talking about is called a computer. – gronostaj – 2016-08-27T06:46:18.927