[SPIR-V] Regression - Internal Compiler error: llvm::cast<X>() argument of incompatible type!
I have a shader that was working on commit 71f2766 which would be DXC commit 0beaa76
It's no longer working after merging DXC d64d34c. It now throws the error in the title when trying to compile, so whatever broke it is somewhere inbetween.
Here's the Godbolt with a repro: https://godbolt.org/z/oKfvE9Mrj
This was somehow caused by https://github.com/microsoft/DirectXShaderCompiler/pull/7353. @danbrown-amd Do you have any time to look into this?
It comes from an assumption in CapabilityVisitor that if a SpirvInstruction has a barrier opcode, it must be a SpirvBarrier. In this case it is a SpirvIntrinsicInstruction. Working on a fix.
Thank you both 🙏