The objective of this work is to study how active galactic nuclei ( AGN ) influence star formation in host galaxies . We present a detailed investigation of the star-formation history and conditions of a z = 2.57 massive radio galaxy based on VLT/X-SHOOTER and ALMA observations . The deep rest-frame ultraviolet spectrum contains photospheric absorption lines and wind features indicating the presence of OB-type stars . The most significantly detected photospheric features are used to characterize the recent star formation : neither instantaneous nor continuous star-formation history is consistent with the relative strength of the Si II \lambda 1485 and S V \lambda 1502 absorption . Rather , at least two bursts of star formation took place in the recent past , at 6 ^ { +1 } _ { -2 } Myr and \gtrsim 20 Myr ago , respectively . We deduce a molecular H _ { 2 } gas mass of ( 3.9 \pm 1.0 ) \times 10 ^ { 10 } M _ { \odot } based on ALMA observations of the [ C i ] ^ { 3 } P _ { 2 } - ^ { 3 } P _ { 1 } emission . The molecular gas mass is only 13 % of its stellar mass . Combined with its high star-formation rate of ( 1020 ^ { +190 } _ { -170 } ) M _ { \sun } yr ^ { -1 } , this implies a high star-formation efficiency of ( 26 \pm 8 ) Gyr ^ { -1 } and a short depletion time of ( 38 \pm 12 ) Myr . We attribute the efficient star formation to compressive gas motions in order to explain the modest velocity dispersions ( \leqslant 55 km s ^ { -1 } ) of the photospheric lines and of the star-forming gas traced by [ C i ] . Because of the likely very young age of the radio source , our findings suggest that vigorous star formation consumes much of the gas and works in concert with the AGN to remove any residual molecular gas , and eventually quenching star formation in massive galaxies .