How AI Could Give Google a Boost, as Worries About Costs Drive Stock Lower