Cooling Codes: Thermal-Management Coding for High-Performance Interconnects