The software megacap has ramped up spending on AI in recent years to compete with its peers.