We study the subpicosecond gain dynamics in a high-finesse semiconductor microcavity containing quantum wells by means of degenerate pump-probe spectroscopy. Tuning the optical excitation in resonance with both the exciton and the cavity modes, at high pump fields the probe pulses are strongly amplified near the energy of the empty-cavity mode. At zero probe delay, integration of the probe spectrum yields a net gain of several percents. The coherent nature of the gain is demonstrated by its oscillatory behavior versus probe delay. A dynamical Maxwell-Bloch model for semiconductors reproduce well the experimental findings and gives insight into the microscopic origin of the coherent gain.