Elon Musk says the companies are exploring a potential merger, a preliminary step toward what would rank as the largest corporate tie-up of all time.