Taiwan, which makes most of the world’s advanced computer chips, relies almost entirely on imported energy.