We were using an OpaqueValueExpr allocated on the stack to store the size of a VLA. Because the VLASizeMap in CodegenFunction uses the address of the expression to avoid recomputing VLAs, we were accidentally reusing an earlier llvm::Value. This led to invalid LLVM IR.
After this change, we allocate the OpaqueValueExpr in ASTContext rather than in the stack. This is a temporary solution until VLASizeMap can be pushed and popped based on the context.