Biomass as an energy source: thermodynamic constraints on the performance of the conversion process