1. A method for removing a bubble from a pipeline, wherein the pipeline includes a first register and a second register, the method comprising: detecting a stall in the pipeline; determining whether the first register contains invalid data, and is consequently associated with a bubble; determining whether the second register contains valid data, wherein the second register is adjacent to and upstream from the first register; and if the first register contains invalid data and the second register contains valid data, replacing the invalid data of the first register with valid data based on the valid data in the second register without propagating the invalid data in the first register to a downstream register, thereby removing the invalid data from the pipeline.