[clang] [clang][OpenMP] `masked` and `master` are not capturing (PR #106787)

Krzysztof Parzyszek via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 2 06:18:23 PDT 2024


https://github.com/kparzysz updated https://github.com/llvm/llvm-project/pull/106787

>From 053374ee88af47515a54e5c5ba3b680e252862bf Mon Sep 17 00:00:00 2001
From: Krzysztof Parzyszek <Krzysztof.Parzyszek at amd.com>
Date: Tue, 30 Jul 2024 15:02:38 -0500
Subject: [PATCH] [clang][OpenMP] `masked` and `master` are not capturing

---
 clang/lib/Basic/OpenMPKinds.cpp | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/clang/lib/Basic/OpenMPKinds.cpp b/clang/lib/Basic/OpenMPKinds.cpp
index 2910f4ed642d16..630a8898aa2293 100644
--- a/clang/lib/Basic/OpenMPKinds.cpp
+++ b/clang/lib/Basic/OpenMPKinds.cpp
@@ -799,8 +799,6 @@ void clang::getOpenMPCaptureRegions(
     case OMPD_dispatch:
     case OMPD_distribute:
     case OMPD_for:
-    case OMPD_masked:
-    case OMPD_master:
     case OMPD_ordered:
     case OMPD_scope:
     case OMPD_sections:
@@ -813,6 +811,9 @@ void clang::getOpenMPCaptureRegions(
       // leafs from that directive have specific regions, then these directives
       // add no additional regions.
       return true;
+    case OMPD_masked:
+    case OMPD_master:
+      return false;
     default:
       llvm::errs() << getOpenMPDirectiveName(LKind) << '\n';
       llvm_unreachable("Unexpected directive");



More information about the cfe-commits mailing list