LoopGenerators: Expose some parts of the parallel loop generator
authorTobias Grosser <tobias@grosser.es>
Sat, 27 Feb 2016 06:24:58 +0000 (06:24 +0000)
committerTobias Grosser <tobias@grosser.es>
Sat, 27 Feb 2016 06:24:58 +0000 (06:24 +0000)
Some of this functionality is useful beyond the generation of a normal OpenMP
loop.

llvm-svn: 262114

polly/include/polly/CodeGen/LoopGenerators.h

index 10e9590..6e2dd4f 100644 (file)
@@ -106,8 +106,10 @@ public:
             Type::getIntNTy(Builder.getContext(), DL.getPointerSizeInBits())),
         M(Builder.GetInsertBlock()->getParent()->getParent()) {}
 
-  /// @brief Create a parallel loop
+  /// @brief Create a parallel loop.
   ///
+  /// This function is the main function to automatically generate a parallel
+  /// loop with all its components.
   ///
   /// @param LB        The lower bound for the loop we parallelize.
   /// @param UB        The upper bound for the loop we parallelize.
@@ -147,6 +149,11 @@ private:
   /// @brief The current module
   Module *M;
 
+public:
+  /// The functions below can be used if one does not want to generate a
+  /// specific OpenMP parallel loop, but generate individual parts of it
+  /// (e.g., the subfunction definition).
+
   /// @brief Create a runtime library call to spawn the worker threads.
   ///
   /// @param SubFn      The subfunction which holds the loop body.