[PATCH] D87250: [OpenMP] Fix typo in CodeGenFunction::EmitOMPWorksharingLoop (PR46412)

Simon Pilgrim via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Sep 7 11:14:15 PDT 2020


RKSimon created this revision.
RKSimon added reviewers: ABataev, doctorpangloss.
Herald added subscribers: guansong, yaxunl.
Herald added a project: clang.
RKSimon requested review of this revision.
Herald added a reviewer: jdoerfert.
Herald added a subscriber: sstefan1.

Fixes issue noticed by static analysis where we appear to have a copy+paste typo, testing ScheduleKind.M1 <https://reviews.llvm.org/M1> twice instead of ScheduleKind.M2 <https://reviews.llvm.org/M2>.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D87250

Files:
  clang/lib/CodeGen/CGStmtOpenMP.cpp


Index: clang/lib/CodeGen/CGStmtOpenMP.cpp
===================================================================
--- clang/lib/CodeGen/CGStmtOpenMP.cpp
+++ clang/lib/CodeGen/CGStmtOpenMP.cpp
@@ -2982,7 +2982,7 @@
           ((ScheduleKind.Schedule == OMPC_SCHEDULE_static ||
             ScheduleKind.Schedule == OMPC_SCHEDULE_unknown) &&
            !(ScheduleKind.M1 == OMPC_SCHEDULE_MODIFIER_nonmonotonic ||
-             ScheduleKind.M1 == OMPC_SCHEDULE_MODIFIER_nonmonotonic)) ||
+             ScheduleKind.M2 == OMPC_SCHEDULE_MODIFIER_nonmonotonic)) ||
           ScheduleKind.M1 == OMPC_SCHEDULE_MODIFIER_monotonic ||
           ScheduleKind.M2 == OMPC_SCHEDULE_MODIFIER_monotonic;
       if ((RT.isStaticNonchunked(ScheduleKind.Schedule,


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D87250.290329.patch
Type: text/x-patch
Size: 743 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20200907/9cf935d0/attachment.bin>


More information about the cfe-commits mailing list