Intel® oneAPI Threading Building Blocks
Ask questions and share information about adding parallelism to your applications when using this threading library.

Benchmark written in TBB

irisshinra308
Beginner
488 Views

Hi~

I am new to Intel TBB and trying to make some modification to it.

However, I am wondering if there are some benchmarks or applications which are written in TBB.

Any help would be grateful

Thanks for reading

Dennis

0 Kudos
6 Replies
Dmitry_Vyukov
Valued Contributor I
488 Views
Quoting - irisshinra308

Hi~

I am new to Intel TBB and trying to make some modification to it.

However, I am wondering if there are some benchmarks or applications which are written in TBB.

Any help would be grateful

Thanks for reading

Dennis

In open-source source distribution you can find some benchmarks and tests in folders:

src/test/

src/perf/

Although, they are synthetic tests, not full-fledged applications.

0 Kudos
IKlm
Beginner
488 Views
Quoting - Dmitriy Vyukov

In open-source source distribution you can find some benchmarks and tests in folders:

src/test/

src/perf/

Although, they are synthetic tests, not full-fledged applications.

Hi,

Can you explain, please, how I can compile and run src/perf content?

And do you know, if is some there standard benchmark, which test ability of processor to run different number of threads? I need some kind of time = time(NumberOfThreads) distribution.

Thanks in advice,

Igor.

0 Kudos
Anton_M_Intel
Employee
488 Views
Quoting - IKlm
Can you explain, please, how I can compile and run src/perf content?

Please try gmake time_{testname} [args={test arguments}] from src/ directory. E.g. "gmake time_hash_map_fill args=1:16"
Each test has its own command line specifics and usage model but number of threads usually passed in "min:max" form.
0 Kudos
Prasun_Gera__Intel_
488 Views
Also, you can try the PARSEC benchmark suite for your analysis. You can run the serial/pthreads/openmp versions of the packages as well to compare your results.

0 Kudos
softarts
Beginner
488 Views

Please try gmake time_{testname} [args={test arguments}] from src/ directory. E.g. "gmake time_hash_map_fill args=1:16"
Each test has its own command line specifics and usage model but number of threads usually passed in "min:max" form.

could you check this:
linaspl27:/tbb/src # gmake time_hash_map_fill args=1:8
gmake -C "../build/linux_intel64_gcc_cc4.1.2_libc2.4_kernel2.6.16.60_release" -r -f ../../build/Makefile.test cfg=release run_cmd="" tbb_root=../.. time_hash_map_fill
gmake[1]: Entering directory `/home/misc.prj/tbb22_20091101oss/build/linux_intel64_gcc_cc4.1.2_libc2.4_kernel2.6.16.60_release'
g++ -c -MMD -DDO_ITT_NOTIFY -O2 -DUSE_PTHREAD -m64 -Wall -I../../src -I../../src/rml/include -I../../include ../../src/perf/time_hash_map_fill.cpp
In file included from ../../src/perf/time_hash_map_fill.cpp:123:
../../src/perf/time_sandbox.h:46:23: error: tbb/concurrent_hash_map-5468.h: No such file or directory
../../src/perf/time_sandbox.h:48: error: concurrent_hash_map is not a member of sandbox2::tbb
../../src/perf/time_sandbox.h:48: error: concurrent_hash_map is not a member of sandbox2::tbb
../../src/perf/time_sandbox.h:48: error: template argument 1 is invalid
../../src/perf/time_sandbox.h:48: error: template argument 1 is invalid
../../src/perf/time_sandbox.h:48: error: expected unqualified-id before , token
../../src/perf/time_sandbox.h:48: error: expected unqualified-id before numeric constant
../../src/perf/time_sandbox.h: In member function void test_sandbox::factory(arg_t, int):
../../src/perf/time_sandbox.h:140: error: expected type-specifier
../../src/perf/time_sandbox.h:140: error: expected `)'
../../src/perf/time_framework.h: In constructor TestRunner::TestRunner(const char*, Test*) [with Test = int]:
../../src/perf/time_framework.h:292: instantiated from TestRunner* TestProcessor::run(const char*, Test*) [with Test = int]
../../src/perf/time_sandbox.h:140: instantiated from here
../../src/perf/time_framework.h:179: error: invalid static_cast from type int* to type TesterBase*
gmake[1]: *** [time_hash_map_fill.o] Error 1
gmake[1]: Leaving directory `/home/misc.prj/tbb22_20091101oss/build/linux_intel64_gcc_cc4.1.2_libc2.4_kernel2.6.16.60_release'
gmake: *** [time_hash_map_fill] Error 2
0 Kudos
Anton_M_Intel
Employee
488 Views
Quoting - softarts
../../src/perf/time_sandbox.h:46:23: error: tbb/concurrent_hash_map-5468.h: No such file or directory

The benchmark is supposed to compare two or more implementstions on the same dataset and operations. But TBB comes with only one implementation of the hash table (still). Check the configuration in the first lines of the time_hash_map_fill.cpp, BOX2 defines the second implementation which is not available by default. E.g. you could use concurrent_hash_map from TBB 2.1 to check the performance difference with new algorithm in 2.2.

0 Kudos
Reply