When performance is insufficient, it discards some P-frames, but the discarded frames are referenced by other frames, leading to abnormalities in subsequent video images. I confirmed this issue by printing libva_trace and observing CurrPic.frame_idx and ReferenceFrames.