Skip to content

huxia1124/ParallelContainers

Repository files navigation

ParallelContainers

Parallel high performance C++ containers, including a set class and a map class.

These containers distribute the inserting, finding and erasing operations to multiple containers to decrease the chance of waiting. This makes better use of multi-core CPU power.

Sample performance test results, using OpenMP for multi-threading.

CPU: Intel Core i7 3740QM
1600000 integer items were inserted, searched and erased
8 parallel threads

---------- STL set (std::set) ----------
Insertion:              1600000 items!
Insertion:       681ms elapsed.
Found:                  1600000 items.
Searching:       1710ms elapsed.
Erasing:         637ms elapsed.
Now:                    0 items!

---------- Concurrent set (Concurrency::concurrent_unordered_set) ----------
Insertion:              1600000 items!
Insertion:       133ms elapsed.
Found:                  1600000 items.
Searching:       117ms elapsed.
Erasing:         2065ms elapsed.
Now:                    0 items!

---------- High Performance set ----------
Insertion:              1600000 items!
Insertion:       136ms elapsed.
Found:                  1600000 items.
Searching:       268ms elapsed.
Erasing:         164ms elapsed.
Now:                    0 items!

STL set (std::set)

STL set

Concurrent set (Concurrency::concurrent_unordered_set)

Concurrent set

High Performance set (CSTXHashSet)

High Performance set

The above results were measured under the following configuration:

CPU: Intel Core i7 3740QM
12800000 integer items were inserted, searched and erased
8 parallel threads

About

Parallel high performance C++ containers (set and map)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published