Hang When Encoding Certain Clips with --enable-overlays 1

On Master af222120, we are getting hangs when trying to encoder certain clips with --enable-overlays 1.

Tested on presets [1 - 12] with QP [20,32,47,55,63].

The encoding hangs while still maintaining 100% CPU utilization.

Sample Command

./SvtAv1EncApp --preset 9 -q 32 --enable-overlays 1 --lp 1 -i TelevisionClip_1080P-401e_horizontal_clip_2_k_8.y4m