If llvm.assume expression contains side effect, Clang doesn't codegen such llvm.assume. Otherwise, if the expr is "pure/const", it may survive the whole middlend pipeline.
The problem: AFAIK llvm.assume calls are not propagated to backend. This means the backend just drops it, but fails to eliminate dead instructions related to llvm.assumes.
Should fix PR43010.