Earnings beat expectations following turnarounds in investment banking and wealth management divisions