cv::drawContours performs slower and slower

Hi,

I’m running an image processing algorithm on Windows 10. There is a hot path that leverages cv::findContours and then cv::drawContours.
While the former method remains stable in terms of performance, the latter method performs progressively worse.
The output of cv::findContours does not vary much, hence the input to the cv::drawContours does not vary much as well.
Any clues on why cv::drawContours performs worse and worse?

Thanks in advance

MRE required. you provided nothing that can be debugged.