Strinx vs STL

Strinx is hosted by Get The Strinx Library at SourceForge.net. Fast, secure and Free Open Source software downloads

Performance Benchmarks

The table below shows the results of performance benchmarks of Strinx vs STD-STL (GNU libstdc++), for common insert-find-remove operations on corresponding containers. The last column represent run-time ratio between STD-STL and Strinx (the higher the ration, the better Strinx performs). The code of the performance test program is in performance.cpp, which is executed by the benchmark.py Python script.

The benchmarks where taken on Dell Poweredge Dual Quad with Intel(R) Xeon(R) CPUs (8cores, 2992.536MHz, 6144KB cache size), running GNU/Linux (Kernel 2.6.18-53). The code has been compiled with GCC 4.1.2 using -O3 optimization flag. Please note that due to Strinx extensive usage of templates and inlining, its performance may vary dramatically in different optimization levels.

CONTAINER    SUBTYPE      MAX-SIZE     THREADS       STD-STL/STRINX
buffer       bounded      200000       4             1.23
list         normal       500000       4             1.59
list         bounded      500000       4             1.56
set          normal       100000       4             2.63
set          bounded      100000       4             3.08
map          normal       100000       4             2.46
map          bounded      100000       4             3.82
multiset     normal       100000       4             2.48
multiset     bounded      100000       4             2.66
multimap     normal       200000       4             1.39
multimap     bounded      200000       4             2.22
stack        bounded      100000       4             1.75

The above table clearly shows that Strinx outperformed STD-STL, in some cases more then three time faster!. However, it should be noted that Strinx strategy of using memory-pools per-object improves has its trade-off in terms of software design and resource allocations, as explained below.

Naturally, in the modern world of programming, as CPU speed and memory size are constantly increasing, performance improvements and heap-fragmentation reduction are often neglected in favor of fast development. Nevertheless, performance matters; the Strinx library provides the extra tools required to improve it in a simple and elegant way.

Home