Skip to content

Commit

Permalink
Committing TBB 2019 Update 1 source code
Browse files Browse the repository at this point in the history
  • Loading branch information
tbbdev committed Oct 4, 2018
1 parent ab775e4 commit 4cebdd9
Show file tree
Hide file tree
Showing 73 changed files with 714 additions and 305 deletions.
27 changes: 27 additions & 0 deletions CHANGES
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,33 @@
The list of most significant changes made over time in
Intel(R) Threading Building Blocks (Intel(R) TBB).

Intel TBB 2019 Update 1
TBB_INTERFACE_VERSION == 11001

Changes (w.r.t. Intel TBB 2019):

- Doxygen documentation could be built with 'make doxygen' command now.

Changes affecting backward compatibility:

- Enforced 8 byte alignment for tbb::atomic<long long> and
tbb::atomic<double>. On IA-32 architecture it may cause layout
changes in structures that use these types.

Bugs fixed:

- Fixed an issue with dynamic memory allocation replacement on Windows*
occurred for some versions of ucrtbase.dll.
- Fixed possible deadlock in tbbmalloc cleanup procedure during process
shutdown.
- Fixed usage of std::uncaught_exception() deprecated in C++17
(https://github.com/01org/tbb/issues/67).
- Fixed a crash when a local observer is activated after an arena
observer.
- Fixed compilation of task_group.h by Visual C++* 15.7 with
/permissive- option (https://github.com/01org/tbb/issues/53).

------------------------------------------------------------------------
Intel TBB 2019
TBB_INTERFACE_VERSION == 11000

Expand Down
Empty file modified Doxyfile
100755 → 100644
Empty file.
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,9 @@ examples: tbb tbbmalloc
python: tbb
$(MAKE) -C "$(work_dir)_release" -rf $(tbb_root)/python/Makefile install

doxygen:
doxygen Doxyfile

.PHONY: clean clean_examples mkdir info

clean: clean_examples
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# Intel(R) Threading Building Blocks 2019
[![Stable release](https://img.shields.io/badge/version-2019-green.svg)](https://github.com/01org/tbb/releases/tag/2019)
# Threading Building Blocks 2019 Update 1
[![Stable release](https://img.shields.io/badge/version-2019_U1-green.svg)](https://github.com/01org/tbb/releases/tag/2019_U1)
[![Apache License Version 2.0](https://img.shields.io/badge/license-Apache_2.0-green.svg)](LICENSE)

Intel(R) Threading Building Blocks (Intel(R) TBB) lets you easily write parallel C++ programs that take
Threading Building Blocks (TBB) lets you easily write parallel C++ programs that take
full advantage of multicore performance, that are portable, composable and have future-proof scalability.

## Release Information
Expand All @@ -11,17 +11,17 @@ Here are the latest [Changes](CHANGES) and [Release Notes](doc/Release_Notes.txt
Since [2018 U5](https://github.com/01org/tbb/releases/tag/2018_U5) TBB binary packages include [Parallel STL](https://github.com/intel/parallelstl) as a high-level component.

## Documentation
* Intel(R) TBB [tutorial](https://software.intel.com/en-us/tbb-tutorial)
* Intel(R) TBB general documentation: [stable](https://software.intel.com/en-us/tbb-documentation)
* TBB [tutorial](https://software.intel.com/en-us/tbb-tutorial)
* TBB general documentation: [stable](https://software.intel.com/en-us/tbb-documentation)
and [latest](https://www.threadingbuildingblocks.org/docs/help/index.htm)

## Support
Please report issues and suggestions via
[GitHub issues](https://github.com/01org/tbb/issues) or start a topic on the
[Intel(R) TBB forum](http://software.intel.com/en-us/forums/intel-threading-building-blocks/).
[TBB forum](http://software.intel.com/en-us/forums/intel-threading-building-blocks/).

## How to Contribute
Please, read the instructions on the official [Intel(R) TBB open source site](https://www.threadingbuildingblocks.org/submit-contribution).
Please, read the instructions on the official [TBB open source site](https://www.threadingbuildingblocks.org/submit-contribution).

## Engineering team contacts
* [E-mail us.](mailto:inteltbbdevelopers@intel.com)
Expand Down
15 changes: 14 additions & 1 deletion build/Makefile.tbbmalloc
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,8 @@ MALLOC_TESTS = test_ScalableAllocator.$(TEST_EXT) \
test_malloc_pure_c.$(TEST_EXT) \
test_malloc_whitebox.$(TEST_EXT) \
test_malloc_used_by_lib.$(TEST_EXT) \
test_malloc_lib_unload.$(TEST_EXT)
test_malloc_lib_unload.$(TEST_EXT) \
test_malloc_shutdown_hang.$(TEST_EXT)
ifneq (,$(MALLOCPROXY.DLL))
MALLOC_TESTS += test_malloc_overload.$(TEST_EXT) \
test_malloc_overload_proxy.$(TEST_EXT) \
Expand Down Expand Up @@ -212,6 +213,17 @@ test_malloc_lib_unload_dll.$(DLL): INCLUDES=$(ORIG_INCLUDES) $(INCLUDE_TEST_HEAD
test_malloc_used_by_lib_dll.$(DLL): CPLUS_FLAGS:=$(subst /MT,/LD,$(M_CPLUS_FLAGS))
test_malloc_used_by_lib_dll.$(DLL): LINK_FILES+=$(ORIG_LINK_MALLOC.LIB)
test_malloc_used_by_lib_dll.$(DLL): LIBDL=

# The test needs both tbb and tbbmalloc.
# For static build LINK_TBB.LIB is resolved in tbb.a static lib name (Linux), which cannot be found (dynamic tbb is used only).
# In order to link properly, have to define LINK_TBB.LIB ourselves except for Windows where linkage with *.lib file expected.
ifdef extra_inc
ifneq ($(tbb_os),windows)
DYNAMIC_TBB_LIB=$(LIBPREF)tbb$(CPF_SUFFIX)$(DEBUG_SUFFIX).$(DLL)
endif
endif
test_malloc_shutdown_hang.$(TEST_EXT): LINK_FILES += $(if $(DYNAMIC_TBB_LIB), $(DYNAMIC_TBB_LIB), $(LINK_TBB.LIB))

# -----------------------------------------------------

# ---- The list of TBBMalloc test running commands ----
Expand All @@ -235,6 +247,7 @@ endif
$(run_cmd) ./test_malloc_regression.$(TEST_EXT) $(args)
$(run_cmd) ./test_malloc_init_shutdown.$(TEST_EXT) $(args)
$(run_cmd) ./test_malloc_pure_c.$(TEST_EXT) $(args)
$(run_cmd) ./test_malloc_shutdown_hang.$(TEST_EXT)
# -----------------------------------------------------

#------------------------------------------------------
Expand Down
4 changes: 2 additions & 2 deletions build/android.clang.inc
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,9 @@ ifeq (0, $(dynamic_load))
endif

# Paths to the NDK prebuilt tools and libraries
ifneq (,$(findstring $(ndk_version),r16 r16b))
ifeq (,$(findstring $(ndk_version), $(foreach v, 7 8 9 10 11 12 13 14 15,r$(v) r$(v)b r$(v)c r$(v)d r$(v)e)))
# Since Android* NDK r16 another sysroot and isystem paths have to be specified
CPLUS_FLAGS += --sysroot=$(NDK_ROOT)/sysroot -isystem $(NDK_ROOT)/sysroot/usr/include/$(TRIPLE)
CPLUS_FLAGS += --sysroot=$(NDK_ROOT)/sysroot -isystem $(NDK_ROOT)/sysroot/usr/include/$(TRIPLE)
# Android* version flag required since r16
CPLUS_FLAGS += -D__ANDROID_API__=$(API_LEVEL)
else
Expand Down
14 changes: 9 additions & 5 deletions build/build.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,10 +93,14 @@ def custom_cp(src, dst):

##############################################################

def system(arg):
print('$ ', arg)
return os.system(arg)

def run_make(arg):
if os.system('%s -j %s'% (args.make_tool, arg)) != 0:
if system('%s -j %s'% (args.make_tool, arg)) != 0:
print("\nBummer. Running serial build in order to recover the log and have a chance to fix the build")
assert os.system('%s %s'% (args.make_tool, arg)) == 0
assert system('%s %s'% (args.make_tool, arg)) == 0

os.chdir(args.tbbroot)
if args.prebuilt:
Expand Down Expand Up @@ -180,10 +184,10 @@ def append_files(names, dst, paths=release_dirs):
install_cp(f, dest)

if args.install_python: # Python part
paths = [os.path.abspath(d) for d in (args.prefix, irml_dir, lib_dir, inc_dir)]
paths = [os.path.abspath(d) for d in [args.prefix, inc_dir, irml_dir, lib_dir]+release_dirs]
os.environ["TBBROOT"] = paths[0]
# all the paths must be relative to python/ directory or be absolute
assert os.system('python python/setup.py build -b%s build_ext -L%s:%s -I%s install -f'% \
(paths[1], paths[2], paths[1], paths[3])) == 0 # add install location? windows needs pythnon/Library location separation
assert system('python python/setup.py build -b%s build_ext -I%s -L%s install -f'% \
(paths[2], paths[1], ':'.join(paths[2:]))) == 0

print("done")
8 changes: 8 additions & 0 deletions build/common.inc
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,14 @@ ifdef cpp0x
override cpp0x=
endif

# Define C & C++ compilers according to platform defaults or CXX & CC environment variables
ifneq (,$(findstring environment, $(origin CXX)))
CPLUS = $(CXX)
endif
ifneq (,$(findstring environment, $(origin CC)))
CONLY = $(CC)
endif

ifneq (,$(stdver))
ifeq (,$(findstring ++, $(stdver)))
$(warning "Warning: unexpected stdver=$(stdver) is used.")
Expand Down
8 changes: 1 addition & 7 deletions build/common_rules.inc
Original file line number Diff line number Diff line change
Expand Up @@ -63,14 +63,8 @@ ifeq ($(origin LIB_LINK_LIBS), undefined)
LIB_LINK_LIBS = $(LIBDL) $(LIBS)
endif

# Define C & C++ compilers according to platform defaults or CXX & CC environment variables
ifneq (,$(findstring environment, $(origin CXX)))
CPLUS = $(CXX)
endif
# some platforms do not provide separate C-only compiler
CONLY ?= $(CPLUS)
ifneq (,$(findstring environment, $(origin CC)))
CONLY = $(CC)
endif

# The most generic rules
#$(1) - is the target pattern
Expand Down
4 changes: 2 additions & 2 deletions build/linux.clang.inc
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
#
#

CPLUS ?= clang++
CONLY ?= clang
COMPILE_ONLY = -c -MMD
PREPROC_ONLY = -E -x c++
INCLUDE_KEY = -I
Expand All @@ -31,8 +33,6 @@ DYLIB_KEY = -shared
EXPORT_KEY = -Wl,--version-script,
LIBDL = -ldl

CPLUS = clang++
CONLY = clang
LIB_LINK_FLAGS = $(DYLIB_KEY) -Wl,-soname=$(BUILDING_LIBRARY)
LIBS += -lpthread -lrt
LINK_FLAGS = -Wl,-rpath-link=. -rdynamic
Expand Down
14 changes: 7 additions & 7 deletions build/linux.gcc.inc
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
#
#

CPLUS ?= g++
CONLY ?= gcc
COMPILE_ONLY = -c -MMD
PREPROC_ONLY = -E -x c++
INCLUDE_KEY = -I
Expand All @@ -32,38 +34,36 @@ DYLIB_KEY = -shared
EXPORT_KEY = -Wl,--version-script,
LIBDL = -ldl

CPLUS = g++
CONLY = gcc
LIB_LINK_FLAGS = $(DYLIB_KEY) -Wl,-soname=$(BUILDING_LIBRARY)
LIBS += -lpthread -lrt
LINK_FLAGS = -Wl,-rpath-link=. -rdynamic
C_FLAGS = $(CPLUS_FLAGS)

# gcc 4.2 and higher support OpenMP
ifneq (,$(shell gcc -dumpversion | egrep "^(4\.[2-9]|[5-9])"))
ifneq (,$(shell $(CONLY) -dumpversion | egrep "^(4\.[2-9]|[5-9])"))
OPENMP_FLAG = -fopenmp
endif

# gcc 4.8 and later support RTM intrinsics, but require command line switch to enable them
ifneq (,$(shell gcc -dumpversion | egrep "^(4\.[8-9]|[5-9])"))
ifneq (,$(shell $(CONLY) -dumpversion | egrep "^(4\.[8-9]|[5-9])"))
RTM_KEY = -mrtm
endif

# gcc 4.0 and later have -Wextra that is used by some our customers.
ifneq (,$(shell gcc -dumpversion | egrep "^([4-9])"))
ifneq (,$(shell $(CONLY) -dumpversion | egrep "^([4-9])"))
WARNING_KEY += -Wextra
endif

# gcc 5.0 and later have -Wsuggest-override and -Wno-sized-deallocation options
ifneq (,$(shell gcc -dumpversion | egrep "^([5-9])"))
ifneq (,$(shell $(CONLY) -dumpversion | egrep "^([5-9])"))
# enable -Wsuggest-override via a pre-included header in order to limit to C++11 and above
INCLUDE_TEST_HEADERS = -include $(tbb_root)/src/test/harness_preload.h
WARNING_SUPPRESS += -Wno-sized-deallocation
endif

# gcc 6.0 and later have -flifetime-dse option that controls
# elimination of stores done outside the object lifetime
ifneq (,$(shell gcc -dumpversion | egrep "^([6-9])"))
ifneq (,$(shell $(CONLY) -dumpversion | egrep "^([6-9])"))
# keep pre-contruction stores for zero initialization
DSE_KEY = -flifetime-dse=1
endif
Expand Down
5 changes: 2 additions & 3 deletions build/linux.icc.inc
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
#
#

CPLUS ?= icpc
CONLY ?= icc
COMPILE_ONLY = -c -MMD
PREPROC_ONLY = -E -x c++
INCLUDE_KEY = -I
Expand All @@ -33,9 +35,6 @@ ifneq (,$(shell icc -dumpversion | egrep "1[2-9]\."))
SDL_FLAGS = -fstack-protector -Wformat -Wformat-security
endif

CPLUS = icpc
CONLY = icc

ITT_NOTIFY = -DDO_ITT_NOTIFY
ifeq (release,$(cfg))
SDL_FLAGS += -D_FORTIFY_SOURCE=2
Expand Down
4 changes: 2 additions & 2 deletions build/linux.pathcc.inc
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
#
#

CPLUS ?= pathCC
CONLY ?= pathcc
COMPILE_ONLY = -c -MMD
PREPROC_ONLY = -E -x c++
INCLUDE_KEY = -I
Expand All @@ -32,8 +34,6 @@ DYLIB_KEY = -shared
EXPORT_KEY = -Wl,--version-script,
LIBDL = -ldl

CPLUS = pathCC
CONLY = pathcc
LIB_LINK_FLAGS = $(DYLIB_KEY) -Wl,-soname=$(BUILDING_LIBRARY)
LIBS += -lstl -lpthread -lrt
LINK_FLAGS = -Wl,-rpath-link=. -rdynamic
Expand Down
4 changes: 2 additions & 2 deletions build/linux.xl.inc
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@

####### Detections and Commands ###############################################

CPLUS ?= xlc++_r
CONLY ?= xlc_r
COMPILE_ONLY = -c
PREPROC_ONLY = -E -qsourcetype=c
INCLUDE_KEY = -I
Expand All @@ -34,8 +36,6 @@ DYLIB_KEY = -qmkshrobj
EXPORT_KEY = -Wl,--version-script,
LIBDL = -ldl

CPLUS = xlc++_r
CONLY = xlc_r
LIB_LINK_FLAGS = $(DYLIB_KEY) -Wl,-soname=$(BUILDING_LIBRARY)
LIBS = -lpthread -lrt
C_FLAGS = $(CPLUS_FLAGS)
Expand Down
6 changes: 3 additions & 3 deletions build/macos.clang.inc
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
#
#

CPLUS = clang++
CONLY = clang
CPLUS ?= clang++
CONLY ?= clang
COMPILE_ONLY = -c -MMD
PREPROC_ONLY = -E -x c++
INCLUDE_KEY = -I
Expand Down Expand Up @@ -47,7 +47,7 @@ endif
CPLUS_FLAGS += -DUSE_PTHREAD $(ITT_NOTIFY)

# For Clang, we add the option to support RTM intrinsics *iff* xtest is found in <immintrin.h>
ifneq (,$(shell grep xtest `echo "\#include<immintrin.h>" | clang -E -M - 2>&1 | grep immintrin.h` 2>/dev/null))
ifneq (,$(shell grep xtest `echo "\#include<immintrin.h>" | $(CONLY) -E -M - 2>&1 | grep immintrin.h` 2>/dev/null))
RTM_KEY = -mrtm
endif

Expand Down
10 changes: 5 additions & 5 deletions build/macos.gcc.inc
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
#
#

CPLUS = g++
CONLY = gcc
CPLUS ?= g++
CONLY ?= gcc
COMPILE_ONLY = -c -MMD
PREPROC_ONLY = -E -x c++
INCLUDE_KEY = -I
Expand All @@ -39,19 +39,19 @@ LIB_LINK_FLAGS = -dynamiclib -install_name @rpath/$(BUILDING_LIBRARY)
C_FLAGS = $(CPLUS_FLAGS)

# gcc 4.8 and later support RTM intrinsics, but require command line switch to enable them
ifneq (,$(shell gcc -dumpversion | egrep "^(4\.[8-9]|[5-9])"))
ifneq (,$(shell $(CONLY) -dumpversion | egrep "^(4\.[8-9]|[5-9])"))
RTM_KEY = -mrtm
endif

# gcc 5.0 and later have -Wsuggest-override option
# enable it via a pre-included header in order to limit to C++11 and above
ifneq (,$(shell gcc -dumpversion | egrep "^([5-9])"))
ifneq (,$(shell $(CONLY) -dumpversion | egrep "^([5-9])"))
INCLUDE_TEST_HEADERS = -include $(tbb_root)/src/test/harness_preload.h
endif

# gcc 6.0 and later have -flifetime-dse option that controls
# elimination of stores done outside the object lifetime
ifneq (,$(shell gcc -dumpversion | egrep "^([6-9])"))
ifneq (,$(shell $(CONLY) -dumpversion | egrep "^([6-9])"))
# keep pre-contruction stores for zero initialization
DSE_KEY = -flifetime-dse=1
endif
Expand Down
4 changes: 2 additions & 2 deletions build/macos.icc.inc
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
#
#

CPLUS = icpc
CONLY = icc
CPLUS ?= icpc
CONLY ?= icc
COMPILE_ONLY = -c -MMD
PREPROC_ONLY = -E -x c++
INCLUDE_KEY = -I
Expand Down
4 changes: 2 additions & 2 deletions build/mic.icc.inc
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
#
#

CPLUS ?= icpc
CONLY ?= icc
COMPILE_ONLY = -c -MMD
PREPROC_ONLY = -E -x c++
INCLUDE_KEY = -I
Expand All @@ -30,8 +32,6 @@ EXPORT_KEY = -Wl,--version-script,
NOINTRINSIC_KEY = -fno-builtin
LIBDL = -ldl
SDL_FLAGS = -fstack-protector -Wformat -Wformat-security
CPLUS = icpc
CONLY = icc

ifeq (release,$(cfg))
SDL_FLAGS += -D_FORTIFY_SOURCE=2
Expand Down
Loading

0 comments on commit 4cebdd9

Please sign in to comment.