Fourth-quarter earnings surged for US, Canadian firms