File tree Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Expand file tree Collapse file tree 1 file changed +14
-1
lines changed Original file line number Diff line number Diff line change @@ -8227,11 +8227,24 @@ class NoLoopChecker final : public ConstStmtVisitor<NoLoopChecker> {
8227
8227
8228
8228
// Reject if there is a nested OpenMP parallel directive
8229
8229
void VisitOMPExecutableDirective (const OMPExecutableDirective *D) {
8230
- if (D->getDirectiveKind () == llvm::omp::Directive::OMPD_parallel) {
8230
+ switch (D->getDirectiveKind ()) {
8231
+ case llvm::omp::Directive::OMPD_parallel:
8232
+ case llvm::omp::Directive::OMPD_parallel_do:
8233
+ case llvm::omp::Directive::OMPD_parallel_do_simd:
8234
+ case llvm::omp::Directive::OMPD_parallel_for:
8235
+ case llvm::omp::Directive::OMPD_parallel_for_simd:
8236
+ case llvm::omp::Directive::OMPD_parallel_master:
8237
+ case llvm::omp::Directive::OMPD_parallel_master_taskloop:
8238
+ case llvm::omp::Directive::OMPD_parallel_master_taskloop_simd:
8239
+ case llvm::omp::Directive::OMPD_parallel_sections:
8240
+ case llvm::omp::Directive::OMPD_parallel_workshare: {
8231
8241
NoLoopCheckStatus = CodeGenModule::NxNestedOmpParallelDirective;
8232
8242
// No need to continue visiting any more
8233
8243
return ;
8234
8244
}
8245
+ default :
8246
+ break ;
8247
+ }
8235
8248
for (const Stmt *Child : D->children ())
8236
8249
if (Child)
8237
8250
Visit (Child);
You can’t perform that action at this time.
0 commit comments