  To operate the ALICE Time Projection Chamber in continuous mode during the
Run~3 and Run~4 data-taking periods of the Large Hadron Collider, the
multi-wire proportional chamber-based readout was replaced with gas-electron
multipliers. As expected, the detector performance is affected by the so-called
common-mode effect, which leads to significant baseline fluctuations. A
detailed study of the pulse shape with the new readout has revealed that it is
also affected by ion tails. Since reconstruction and data compression are
performed fully online, these effects must be corrected at the hardware level
in the FPGA-based common readout units. The characteristics of the common-mode
effect and of the ion tail, as well as the algorithms developed for their
online correction, are described in this paper. The common-mode dependencies
are studied using machine-learning techniques. Toy Monte Carlo simulations are
performed to illustrate the importance of online corrections and to investigate
the performance of the developed algorithms.
