Stock exchange merger could end San Francisco stock trading