Brazil’s state-controlled oil producer Petrobras surpassed profit expectations after robust oil production and record exports helped cushion the impact of weaker crude prices.