clover/queue: Flush automatically if applications do not flush themselves
With the image_read_write OpenCL CTS we can get a stack overflow handling
all the events as the application itself never flushes.
We need to address this in two ways:
1. flush the queue once an abritary amoung of events piled up.
2. Drop event deps once they get a fence assigned.
Signed-off-by: Karol Herbst <kherbst@redhat.com>
Reviewed-by: Francisco Jerez <currojerez@riseup.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7460>