[PATCH] [PATCH] OpenMP firstprivate clause
Wei Pan
wei.pan at intel.com
Thu Sep 26 07:23:49 PDT 2013
================
Comment at: lib/Sema/SemaOpenMP.cpp:667
@@ +666,3 @@
+ bool ErrorFound = false;
+ if (DSAChecker.getImplicitFirstprivate().size() > 0) {
+ if (OMPClause *Implicit =
----------------
! get...().empty()
================
Comment at: lib/Sema/SemaOpenMP.cpp:692
@@ -646,1 +691,3 @@
+
+ if (ErrorFound) return StmtError();
return Res;
----------------
The logic could be improved. Program could exit early if it only returns StmtError in the end.
================
Comment at: lib/Sema/SemaOpenMP.cpp:1055
@@ +1054,3 @@
+ }
+ if (DVar.CKind != OMPC_unknown && DVar.CKind != OMPC_firstprivate &&
+ !(DVar.CKind == OMPC_shared && !DVar.RefExpr &&
----------------
Seem difficult to read what it is checking. In particular, DVar.RefExpr is also checked inside if-then.
http://llvm-reviews.chandlerc.com/D1694
More information about the cfe-commits
mailing list