gold ends at another multimonth high, but u.s. stock market rally limits the metal’s rise