[Mlir-commits] [mlir] [mlir][spirv] Fix UpdateVCEPass to deduce the correct set of capabilities (PR #151108)

Davide Grohmann llvmlistbot at llvm.org
Wed Jul 30 08:52:39 PDT 2025


davidegrohmann wrote:

> I cannot quickly run asan on my machine, but as a proxy I ran Valgrind and it highlights some invalid reads in the new function, so this may be causing builbot issues.
> 
> ```
> ...
> ==1419720== Thread 4 llvm-worker-2:
> ==1419720== Invalid read of size 4
> ==1419720==    at 0x5272660: addAllImpliedCapabilities(llvm::SetVector<mlir::spirv::Capability, llvm::SmallVector<mlir::spirv::Capability, 0u>, llvm::DenseSet<mlir::spirv::Capability, llvm::DenseMapInfo<mlir::spirv::Capability, void> >, 0u>&) (llvm-project/mlir/lib/Dialect/SPIRV/Transforms/UpdateVCEPass.cpp:99)
> ...
> ```

Could this be related to the fact that we iterate and modify the set at the same time?
I can revert the code to the version before that change if that helps fixing the issue.

https://github.com/llvm/llvm-project/pull/151108


More information about the Mlir-commits mailing list