This should fix issue #56383 (at least when compiled with -O3 because this pass is only run at -O3 currently).