GPU621/Fighting Mongooses

From CDOT Wiki
Revision as of 21:58, 30 November 2016 by Kyle Klerks (talk | contribs) (Group Members)
Jump to: navigation, search

Fighting Mongooses

Group Members

  1. Mike Doherty, Everything.
  2. Kyle Klerks, Everything.

Entry on: October 31st 2016

Group page (Fighting Mongooses) has been created suggested project topic is being considered

  1. - C++11 STL Comparison to TBB

Once project topic is confirmed by Professor Chris Szalwinski), I will be able to proceed with topic research.

Entry on: November 30th 2016

Comparing STL/PPL to TBB: Sorting Algorithm

Let’s compare a simple sorting algorithm between TBB and STL/PPL.

Serial

TBB

STL

Results

The clear differentiation in the code is that TBB does not have to operate using random access iterators, while STL’s parallel solution to sorting (and serial solution) does. If TBB sort is run using a vector instead of a simple array, you will see more even times.

Conclusion; STL does not currently handle parallelization of simple tasks well, as evidenced by this sort function. Even with this code snippet to lower the workload;

if (i % 3 == 0) { backwardsList.push_back(N - i); } else { backwardsList.push_back(i); }

The times are largely the same for STL sorting.