[llvm] [RISCV] Recognize VLA shift pairs from shuffle masks (PR #127710)

Philip Reames via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 20 08:12:59 PST 2025


preames wrote:

There's been three buildbot failures on this so far, but the error being reported doesn't seem to make sense.  Anyone have a clue what's wrong here?
```
/home/worker/2.0.1/lldb-x86_64-debian/llvm-project/llvm/lib/Target/RISCV/RISCVISelLowering.cpp:5723:24: error: reference to local binding 'TrueMask' declared in enclosing function 'lowerVECTOR_SHUFFLE'
        assert(Mask == TrueMask);
                       ^
/home/worker/2.0.1/lldb-x86_64-debian/llvm-project/llvm/lib/Target/RISCV/RISCVISelLowering.cpp:5476:9: note: 'TrueMask' declared here
  auto [TrueMask, VL] = getDefaultVLOps(VT, ContainerVT, DL, DAG, Subtarget);

```
Yes, these are references to variables defined in the outer scope, but the lambda explicit captures everything, so this is exactly the intent?  The variables being flagged come from a structural binding, is there some special C++ case on that I'm unaware of?  I'll note that this definitely builds cleanly for me locally using "gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0"

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


More information about the llvm-commits mailing list