Manoj Rao bio photo

Manoj Rao

Your Average Common Man

Email Twitter Github

In earlier posts, I mentioned about that I was looking for a library implemented in Modern C++ that allowed me to compose parallel tasks and help with scheduling them efficiently.

Finally, I was able to play with one such project which looks promising called C++ TaskFlow. You can find it on GitHub. A good thing about this project is it’s well documented and is under active development.

It is loosely modeled after Intel TBB but aims to provide much simpler APIs. I think the clear advantages of using Taskflow are its features like task graph visualization. I test drove the kmeans example I was able to look at the task graph pretty easily.

Task Graph Visualization

I tried out one of the examples and ran it on NVidia’s Jetson Xavier AGX SDK that I recently unpacked.

TaskFlow Profiler

Multiplying Matrices on NVidia Jetson Xavier AGX

Because why not?

Shapes (100x100) * (100x100)

matrix A: 100x100
matrix B: 100x100
matrix C: 100x100

CPU took 2ms GPU took 114ms

Shapes (100x500) * (500x500)

matrix A: 100x500
matrix B: 500x500
matrix C: 100x500

CPU took 27ms GPU took 115ms

Shapes (1000x2000) * (2000x3000)

matrix A: 1000x2000
matrix B: 2000x3000
matrix C: 1000x3000

CPU took 4372ms GPU took 396ms

Shapes (10000x20000) * (20000x30000)

matrix A: 10000x20000
matrix B: 20000x30000
matrix C: 10000x30000

CPU took 4372ms GPU took 396ms


Bring Your Own Cause

If you think any info here has remotely helped you consider dropping a penny for this cause, just click me . You can visit https://www.bbc.com/news/world-asia-india-52672764 Unfortunately, there are plenty of sad things happening all over the world, if you have a different cause or charity you'd rather support please do. And if you did make a donation, please drop a note to me (annotated) or leave a comment here (anonymous is OK!) and I will use that as motivation to write more useful content here.

If you like topics such as this then please consider subscribing to my podcast. I talk to some of the stalwarts in tech and ask them what their favorite productivity hacks are:

Available on iTunes Podcast

Visit Void Star Podcast’s page on iTunes Podcast Portal. Please Click ‘Subscribe’, leave a comment.

Get it iTunes