The artificial intelligence (AI) boom is altering the financial landscape of America's largest tech companies.