FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

updated docs · PentaBug/taskflow@907f3ac · GitHub

Repository navigation

Commit 907f3ac

Browse files
twhuang
committed
updated docs
1 parent 296de26 commit 907f3ac

56 files changed

Lines changed: 3184 additions & 157 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎benchmarks/scan/omp.cpp‎

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -34,25 +34,31 @@ void omp_scan(int n, const T* in, T* out, Op op, unsigned nthreads) {
3434
operation = op(operation, in[i]);
3535
}
3636
}
37-
/* For region ends */
38-
last_value_chunk_array[idthread+1] = operation; // Assigning sums of all chunks in last_chunk_value array
3937

40-
#pragma omp barrier // Syncing all the threads
38+
// Assigning sums of all chunks in last_chunk_value array
39+
last_value_chunk_array[idthread+1] = operation;
4140

42-
int balance = last_value_chunk_array[1]; // Initialising with index 1 value as for thread 0, result has already been calculated
41+
// synchronize all threads
42+
#pragma omp barrier
43+
44+
// Initialising with index 1 value as for thread 0
45+
// result has already been calculated
46+
int balance = last_value_chunk_array[1];
4347
if(idthread == 1)
4448
{
45-
balance = last_value_chunk_array[1]; // For thread ID 1
49+
balance = last_value_chunk_array[1]; // For thread ID 1
4650
}
4751

52+
// Creating balance for every thread
4853
for(int i=2; i<(idthread+1); i++)
49-
balance = op(balance,last_value_chunk_array[i]); // Creating balance for every thread
54+
balance = op(balance,last_value_chunk_array[i]);
5055

51-
#pragma omp for schedule(static, chunk) // To calculate the sum of all chunks
56+
// To calculate the sum of all chunks
57+
#pragma omp for schedule(static, chunk)
5258
for(int i=0; i<n; i++) {
5359
if(idthread != 0)
5460
{
55-
out[i] = op(out[i], balance); // For thread IDs other than 0
61+
out[i] = op(out[i], balance);
5662
}
5763
}
5864
}
@@ -62,7 +68,7 @@ void omp_scan(int n, const T* in, T* out, Op op, unsigned nthreads) {
6268

6369
// scan_omp
6470
void scan_omp(size_t nthreads) {
65-
omp_scan(input.size(), input.data(), output.data(), std::plus<int>{}, nthreads);
71+
omp_scan(input.size(), input.data(), output.data(), std::multiplies<int>{}, nthreads);
6672
}
6773

6874
std::chrono::microseconds measure_time_omp(size_t num_threads) {

‎benchmarks/scan/taskflow.cpp‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ void scan_taskflow(size_t num_threads) {
88
tf::Taskflow taskflow;
99

1010
taskflow.inclusive_scan(
11-
input.begin(), input.end(), output.begin(), std::plus<int>{}
11+
input.begin(), input.end(), output.begin(), std::multiplies<int>{}
1212
);
1313

1414
executor.run(taskflow).get();

‎benchmarks/scan/tbb.cpp‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ void scan_tbb(size_t num_threads) {
5151
tbb::global_control c(
5252
tbb::global_control::max_allowed_parallelism, num_threads
5353
);
54-
inclusive_scan(input, 0, output, std::plus<int>{});
54+
inclusive_scan(input, 0, output, std::multiplies<int>{});
5555
}
5656

5757
std::chrono::microseconds measure_time_tbb(size_t num_threads) {

‎docs/Algorithms.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848
<h1>
4949
Taskflow Algorithms
5050
</h1>
51-
<p>Taskflow defines a set of algorithm primitives to perform common parallel algorithms:</p><ul><li><a href="PartitioningAlgorithm.html" class="m-doc">Partitioning Algorithm</a></li><li><a href="ParallelIterations.html" class="m-doc">Parallel Iterations</a></li><li><a href="ParallelTransforms.html" class="m-doc">Parallel Transforms</a></li><li><a href="ParallelReduction.html" class="m-doc">Parallel Reduction</a></li><li><a href="ParallelSort.html" class="m-doc">Parallel Sort</a></li><li><a href="TaskParallelPipeline.html" class="m-doc">Task-parallel Pipeline</a></li><li><a href="TaskParallelScalablePipeline.html" class="m-doc">Task-parallel Scalable Pipeline</a></li><li><a href="TaskParallelPipelineWithTokenDependencies.html" class="m-doc">Task-parallel Pipeline with Token Dependencies</a></li><li><a href="DataParallelPipeline.html" class="m-doc">Data-parallel Pipeline</a></li></ul>
51+
<p>Taskflow defines a set of algorithm primitives to perform common parallel algorithms:</p><ul><li><a href="PartitioningAlgorithm.html" class="m-doc">Partitioning Algorithm</a></li><li><a href="ParallelIterations.html" class="m-doc">Parallel Iterations</a></li><li><a href="ParallelTransforms.html" class="m-doc">Parallel Transforms</a></li><li><a href="ParallelReduction.html" class="m-doc">Parallel Reduction</a></li><li><a href="ParallelSort.html" class="m-doc">Parallel Sort</a></li><li><a href="ParallelScan.html" class="m-doc">Parallel Scan</a></li><li><a href="TaskParallelPipeline.html" class="m-doc">Task-parallel Pipeline</a></li><li><a href="TaskParallelScalablePipeline.html" class="m-doc">Task-parallel Scalable Pipeline</a></li><li><a href="TaskParallelPipelineWithTokenDependencies.html" class="m-doc">Task-parallel Pipeline with Token Dependencies</a></li><li><a href="DataParallelPipeline.html" class="m-doc">Data-parallel Pipeline</a></li></ul>
5252
</div>
5353
</div>
5454
</div>

‎docs/ParallelScan.html‎

Lines changed: 169 additions & 0 deletions
Large diffs are not rendered by default.

‎docs/classtf_1_1FlowBuilder.html‎

Lines changed: 454 additions & 4 deletions
Large diffs are not rendered by default.

‎docs/index.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -552,7 +552,7 @@ <h3>Contents</h3>
552552
</g>
553553
</g>
554554
</svg>
555-
</div></section><section id="SupportedCompilers"><h2><a href="#SupportedCompilers">Supported Compilers</a></h2><p>To use Taskflow, you only need a compiler that supports C++17:</p><ul><li>GNU C++ Compiler at least v8.4 with -std=c++17</li><li>Clang C++ Compiler at least v6.0 with -std=c++17</li><li>Microsoft Visual Studio at least v19.27 with /std:c++17</li><li>AppleClang Xode Version at least v12.0 with -std=c++17</li><li>Nvidia CUDA Toolkit and Compiler (nvcc) at least v11.1 with -std=c++17</li><li>Intel C++ Compiler at least v19.0.1 with -std=c++17</li><li>Intel DPC++ Clang Compiler at least v13.0.0 with -std=c++17 and SYCL20</li></ul><p>Taskflow works on Linux, Windows, and Mac OS X.</p></section><section id="QuickStartGetInvolved"><h2><a href="#QuickStartGetInvolved">Get Involved</a></h2><p>Visit our <a href="https://taskflow.github.io/">Project Website</a> and <a href="https://taskflow.github.io/showcase/index.html">showcase presentation</a> to learn more about Taskflow. To get involved:</p><ul><li>See release notes at <a href="Releases.html" class="m-doc">Release Notes</a></li><li>Read the step-by-step tutorial at <a href="Cookbook.html" class="m-doc">Cookbook</a></li><li>Submit an issue at <a href="https://github.com/taskflow/taskflow/issues">issue tracker</a></li><li>Learn more about our technical details at <a href="References.html" class="m-doc">References</a></li><li>Watch our <a href="https://www.youtube.com/watch?v=MX15huP5DsM">2020 CppCon Taskflow Talk</a> and <a href="https://www.youtube.com/watch?v=u8Mc_WgGwVY">2020 MUC++ Taskflow Talk</a></li></ul><p>We are committed to support trustworthy developments for both academic and industrial research projects in parallel and heterogeneous computing. If you are using Taskflow, please cite the following paper we publised at 2022 IEEE TPDS:</p><ul><li>Tsung-Wei Huang, Dian-Lun Lin, Chun-Xun Lin, and Yibo Lin, &quot;<a href="https://tsung-wei-huang.github.io/papers/tpds21-taskflow.pdf">Taskflow: A Lightweight Parallel and Heterogeneous Task Graph Computing System</a>,&quot; <em>IEEE Transactions on Parallel and Distributed Systems (TPDS)</em>, vol. 33, no. 6, pp. 1303-1320, June 2022</li></ul><p>More importantly, we appreciate all Taskflow <a href="contributors.html" class="m-doc">Contributors</a> and the following organizations for sponsoring the Taskflow project!</p><table class="m-table"><thead><tr><th></th><th></th><th></th><th></th></tr></thead><tbody><tr><td><img class="m-image" src="utah-ece-logo.png" alt="Image" /></td><td><img class="m-image" src="nsf.png" alt="Image" /></td><td><img class="m-image" src="darpa.png" alt="Image" /></td><td><img class="m-image" src="NumFocus.png" alt="Image" /></td></tr><tr><td><img class="m-image" src="nvidia-logo.png" alt="Image" /></td><td></td><td></td><td></td></tr></tbody></table></section><section id="License"><h2><a href="#License">License</a></h2><p>Taskflow is open-source under permissive MIT license. You are completely free to use, modify, and redistribute any work on top of Taskflow. The source code is available in <a href="https://github.com/taskflow/">Project GitHub</a> and is actively maintained by <a href="https://tsung-wei-huang.github.io/">Dr. Tsung-Wei Huang</a> and his research group at the University of Utah.</p></section>
555+
</div></section><section id="SupportedCompilers"><h2><a href="#SupportedCompilers">Supported Compilers</a></h2><p>To use Taskflow, you only need a compiler that supports C++17:</p><ul><li>GNU C++ Compiler at least v8.4 with -std=c++17</li><li>Clang C++ Compiler at least v6.0 with -std=c++17</li><li>Microsoft Visual Studio at least v19.27 with /std:c++17</li><li>AppleClang Xcode Version at least v12.0 with -std=c++17</li><li>Nvidia CUDA Toolkit and Compiler (nvcc) at least v11.1 with -std=c++17</li><li>Intel C++ Compiler at least v19.0.1 with -std=c++17</li><li>Intel DPC++ Clang Compiler at least v13.0.0 with -std=c++17 and SYCL20</li></ul><p>Taskflow works on Linux, Windows, and Mac OS X.</p></section><section id="QuickStartGetInvolved"><h2><a href="#QuickStartGetInvolved">Get Involved</a></h2><p>Visit our <a href="https://taskflow.github.io/">Project Website</a> and <a href="https://taskflow.github.io/showcase/index.html">showcase presentation</a> to learn more about Taskflow. To get involved:</p><ul><li>See release notes at <a href="Releases.html" class="m-doc">Release Notes</a></li><li>Read the step-by-step tutorial at <a href="Cookbook.html" class="m-doc">Cookbook</a></li><li>Submit an issue at <a href="https://github.com/taskflow/taskflow/issues">issue tracker</a></li><li>Learn more about our technical details at <a href="References.html" class="m-doc">References</a></li><li>Watch our <a href="https://www.youtube.com/watch?v=MX15huP5DsM">2020 CppCon Taskflow Talk</a> and <a href="https://www.youtube.com/watch?v=u8Mc_WgGwVY">2020 MUC++ Taskflow Talk</a></li></ul><p>We are committed to support trustworthy developments for both academic and industrial research projects in parallel and heterogeneous computing. If you are using Taskflow, please cite the following paper we publised at 2022 IEEE TPDS:</p><ul><li>Tsung-Wei Huang, Dian-Lun Lin, Chun-Xun Lin, and Yibo Lin, &quot;<a href="https://tsung-wei-huang.github.io/papers/tpds21-taskflow.pdf">Taskflow: A Lightweight Parallel and Heterogeneous Task Graph Computing System</a>,&quot; <em>IEEE Transactions on Parallel and Distributed Systems (TPDS)</em>, vol. 33, no. 6, pp. 1303-1320, June 2022</li></ul><p>More importantly, we appreciate all Taskflow <a href="contributors.html" class="m-doc">Contributors</a> and the following organizations for sponsoring the Taskflow project!</p><table class="m-table"><thead><tr><th></th><th></th><th></th><th></th></tr></thead><tbody><tr><td><img class="m-image" src="utah-ece-logo.png" alt="Image" /></td><td><img class="m-image" src="nsf.png" alt="Image" /></td><td><img class="m-image" src="darpa.png" alt="Image" /></td><td><img class="m-image" src="NumFocus.png" alt="Image" /></td></tr><tr><td><img class="m-image" src="nvidia-logo.png" alt="Image" /></td><td></td><td></td><td></td></tr></tbody></table></section><section id="License"><h2><a href="#License">License</a></h2><p>Taskflow is open-source under permissive MIT license. You are completely free to use, modify, and redistribute any work on top of Taskflow. The source code is available in <a href="https://github.com/taskflow/">Project GitHub</a> and is actively maintained by <a href="https://tsung-wei-huang.github.io/">Dr. Tsung-Wei Huang</a> and his research group at the University of Utah.</p></section>
556556
</div>
557557
</div>
558558
</div>

‎docs/install.html‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ <h3>Contents</h3>
6060
<li><a href="#BAIBuildDocumentation">Build Documentation</a></li>
6161
</ul>
6262
</nav>
63-
<p>This page describes how to set up Taskflow in your project. We will also go through the building process of unit tests and examples.</p><section id="BAISupportedCompilers"><h2><a href="#BAISupportedCompilers">Supported Compilers</a></h2><p>To use Taskflow, you only need a compiler that supports C++17:</p><ul><li>GNU C++ Compiler at least v8.4 with -std=c++17</li><li>Clang C++ Compiler at least v6.0 with -std=c++17</li><li>Microsoft Visual Studio at least v15.7 (MSVC++ 19.14)</li><li>AppleClang Xode Version at least v12.0 with -std=c++17</li><li>Nvidia CUDA Toolkit and Compiler (nvcc) at least v11.1 with -std=c++17</li><li>Intel C++ Compiler (nvcc) at least v19.0.1 with -std=c++17</li><li>Intel DPC++ Clang Compiler at least v13.0.0 with -std=c++17 and SYCL20</li></ul><p>Taskflow works on Linux, Windows, and Mac OS X.</p></section><section id="BAIIntegrateTaskflowToYourProject"><h2><a href="#BAIIntegrateTaskflowToYourProject">Integrate Taskflow to Your Project</a></h2><p>Taskflow is <em>header-only</em> and there is no need for installation. Simply download the source and copy the headers under the directory <code>taskflow/</code> to your project.</p><pre class="m-console"><span class="go">~$ git clone https://github.com/taskflow/taskflow.git</span>
63+
<p>This page describes how to set up Taskflow in your project. We will also go through the building process of unit tests and examples.</p><section id="BAISupportedCompilers"><h2><a href="#BAISupportedCompilers">Supported Compilers</a></h2><p>To use Taskflow, you only need a compiler that supports C++17:</p><ul><li>GNU C++ Compiler at least v8.4 with -std=c++17</li><li>Clang C++ Compiler at least v6.0 with -std=c++17</li><li>Microsoft Visual Studio at least v15.7 (MSVC++ 19.14)</li><li>AppleClang Xcode Version at least v12.0 with -std=c++17</li><li>Nvidia CUDA Toolkit and Compiler (nvcc) at least v11.1 with -std=c++17</li><li>Intel C++ Compiler (nvcc) at least v19.0.1 with -std=c++17</li><li>Intel DPC++ Clang Compiler at least v13.0.0 with -std=c++17 and SYCL20</li></ul><p>Taskflow works on Linux, Windows, and Mac OS X.</p></section><section id="BAIIntegrateTaskflowToYourProject"><h2><a href="#BAIIntegrateTaskflowToYourProject">Integrate Taskflow to Your Project</a></h2><p>Taskflow is <em>header-only</em> and there is no need for installation. Simply download the source and copy the headers under the directory <code>taskflow/</code> to your project.</p><pre class="m-console"><span class="go">~$ git clone https://github.com/taskflow/taskflow.git</span>
6464
<span class="go">~$ cd taskflow/</span>
6565
<span class="go">~$ cp -r taskflow myproject/include/</span></pre><p>Taskflow is written in C++17 and is built on top of C++ standardized threading libraries to improve portability. To compile a Taskflow program, say <code>simple.cpp</code>, you need to tell the compiler where to find the Taskflow header files and link it through the system thread library (usually <a href="http://man7.org/linux/man-pages/man7/pthreads.7.html">POSIX threads</a> in Linux-like systems). Take gcc for an example:</p><pre class="m-console"><span class="go">~$ g++ simple.cpp -std=c++17 -I myproject/include/ -O2 -pthread -o simple</span></pre></section><section id="BAIBuildExamplesAndUnitTests"><h2><a href="#BAIBuildExamplesAndUnitTests">Build Examples and Unit Tests</a></h2><p>Taskflow uses CMake to build examples and unit tests. We recommend using out-of-source build.</p><pre class="m-console"><span class="go">~$ cd path/to/taskflow</span>
6666
<span class="go">~$ mkdir build</span>

‎docs/pages.html‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,7 @@ <h1>Pages</h1>
104104
<li><a href="ParallelTransforms.html" class="m-doc">Parallel Transforms</a> <span class="m-doc"></span></li>
105105
<li><a href="ParallelReduction.html" class="m-doc">Parallel Reduction</a> <span class="m-doc"></span></li>
106106
<li><a href="ParallelSort.html" class="m-doc">Parallel Sort</a> <span class="m-doc"></span></li>
107+
<li><a href="ParallelScan.html" class="m-doc">Parallel Scan</a> <span class="m-doc"></span></li>
107108
<li><a href="TaskParallelPipeline.html" class="m-doc">Task-parallel Pipeline</a> <span class="m-doc"></span></li>
108109
<li><a href="TaskParallelScalablePipeline.html" class="m-doc">Task-parallel Scalable Pipeline</a> <span class="m-doc"></span></li>
109110
<li><a href="TaskParallelPipelineWithTokenDependencies.html" class="m-doc">Task-parallel Pipeline with Token Dependencies</a> <span class="m-doc"></span></li>

0 commit comments

Comments
 (0)

Back | FazBrowse Home | New Git URL