================ @@ -336,13 +337,15 @@ class CheckVarsEscapingDeclContext final return; if (!D->hasAssociatedStmt()) return; + if (const auto *S = dyn_cast_or_null<CapturedStmt>(D->getAssociatedStmt())) { // Do not analyze directives that do not actually require capturing, // like `omp for` or `omp simd` directives. llvm::SmallVector<OpenMPDirectiveKind, 4> CaptureRegions; getOpenMPCaptureRegions(CaptureRegions, D->getDirectiveKind()); - if (CaptureRegions.size() == 1 && CaptureRegions.back() == OMPD_unknown) { + if (CaptureRegions.size() == 1 && CaptureRegions.back() == OMPD_unknown && + D->getDirectiveKind() != OMPD_simd) { ---------------- jdoerfert wrote:
Why is simd special here and needs to be checked? https://github.com/llvm/llvm-project/pull/91261 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits