<pre style='margin:0'>
Mohamed Akram (mohd-akram) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/7ca8b137879ed3c5019b916b60d44ea4d375eff0">https://github.com/macports/macports-ports/commit/7ca8b137879ed3c5019b916b60d44ea4d375eff0</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'> new 7ca8b137879 onetbb: update to 2021.12.0
</span>7ca8b137879 is described below
<span style='display:block; white-space:pre;color:#808000;'>commit 7ca8b137879ed3c5019b916b60d44ea4d375eff0
</span>Author: Sergey Fedorov <vital.had@gmail.com>
AuthorDate: Sat Apr 20 19:58:17 2024 +0800
<span style='display:block; white-space:pre;color:#404040;'> onetbb: update to 2021.12.0
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> - use libatomic only when required
</span><span style='display:block; white-space:pre;color:#404040;'> - improve tests variant
</span><span style='display:block; white-space:pre;color:#404040;'> - improve libdispatch patch and add variant for ppc
</span>---
devel/onetbb/Portfile | 45 ++++++++--
.../files/patch-onetbb-dispatch-fallback.diff | 100 +++++++++++++++++++++
.../onetbb/files/patch-onetbb-older-platforms.diff | 100 ---------------------
3 files changed, 136 insertions(+), 109 deletions(-)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/onetbb/Portfile b/devel/onetbb/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index c43032d1ddd..1e8f0d25d92 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/devel/onetbb/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/onetbb/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -5,13 +5,12 @@ PortGroup github 1.0
</span> PortGroup cmake 1.1
PortGroup compiler_blacklist_versions 1.0
<span style='display:block; white-space:pre;background:#ffe0e0;'>-github.setup oneapi-src oneTBB 2021.11.0 v
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+github.setup oneapi-src oneTBB 2021.12.0 v
</span> github.tarball_from archive
name onetbb
<span style='display:block; white-space:pre;background:#ffe0e0;'>-revision 1
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+revision 0
</span> categories devel parallel
<span style='display:block; white-space:pre;background:#ffe0e0;'>-platforms darwin
</span> license Apache-2
maintainers {outlook.com:mohd.akram @mohd-akram} openmaintainer
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -21,11 +20,12 @@ long_description oneTBB is a flexible C++ library that simplifies the work \
</span> of adding parallelism to complex applications, even if you \
are not a threading expert.
<span style='display:block; white-space:pre;background:#ffe0e0;'>-checksums rmd160 77f55c6fa2e790021572d3d1187fdc8453b8b3de \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- sha256 782ce0cab62df9ea125cdea253a50534862b563f1d85d4cda7ad4e77550ac363 \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- size 2613493
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+checksums rmd160 673fd51e1454dc783473ecf3a70824e263f104f5 \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ sha256 c7bb7aa69c254d91b8f0041a71c5bcc3936acb64408a1719aec0b2b7639dd84f \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ size 2617255
</span>
<span style='display:block; white-space:pre;background:#ffe0e0;'>-patchfiles patch-onetbb-older-platforms.diff
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+patchfiles patch-onetbb-older-platforms.diff \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ patch-onetbb-dispatch-fallback.diff
</span>
compiler.blacklist-append {clang < 700}
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -33,7 +33,7 @@ depends_build-append port:pkgconfig
</span>
depends_lib-append port:hwloc
<span style='display:block; white-space:pre;background:#ffe0e0;'>-compiler.cxx_standard 2011
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+compiler.cxx_standard 2011
</span>
# Temporary fix for a linking failure. To be dropped upon the next gcc12 update.
# Related info: https://github.com/iains/darwin-toolchains-start-here/discussions/41
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -79,12 +79,39 @@ platform powerpc {
</span>
# ___atomic_fetch_add_8, ___atomic_load_8, ___atomic_fetch_sub_8
# Drop once this is merged: https://github.com/oneapi-src/oneTBB/pull/987
<span style='display:block; white-space:pre;background:#ffe0e0;'>-if {[string match *gcc* ${configure.compiler}]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+if {[string match *gcc* ${configure.compiler}] && ${configure.build_arch} in [list i386 ppc]} {
</span> configure.ldflags-append \
-latomic
}
variant tests description {Enable tests} {
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Ensure test binaries can find dylibs:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.pre_args-replace \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -DCMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=ON \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -DCMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=OFF
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> configure.args-delete -DTBB_TEST=OFF
<span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${configure.cxx_stdlib} ne "libc++"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # To mitigate malloc errors with libstdc++:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ test.env-append DYLD_LIBRARY_PATH=${prefix}/lib/libgcc
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span> test.run yes
}
<span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# This variant is aimed at supported legacy powerpc systems.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# It works on some at the moment, but is not ready to be the default.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# Old Intel systems can be added later upon testing.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+if {${os.platform} eq "darwin" && ${configure.build_arch} in [list ppc ppc64]} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ variant legacy_dispatch description "Enable dispatch via libdispatch-legacy port" {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Drop fallback code:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ patchfiles-delete patch-onetbb-dispatch-fallback.diff
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ depends_lib-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ port:libdispatch-legacy
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.cppflags-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ -I${prefix}/libexec/dispatch/usr/include
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ configure.ldflags-append \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ ${prefix}/libexec/dispatch/usr/lib/libdispatch.a
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/onetbb/files/patch-onetbb-dispatch-fallback.diff b/devel/onetbb/files/patch-onetbb-dispatch-fallback.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 00000000000..c623d2317ac
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/onetbb/files/patch-onetbb-dispatch-fallback.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,100 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+diff --git src/tbb/semaphore.h src/tbb/semaphore.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+index 9d27f3ac..b8942329 100644
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- src/tbb/semaphore.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ src/tbb/semaphore.h
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -22,8 +22,16 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #if _WIN32||_WIN64
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include <windows.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #elif __APPLE__
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#include <AvailabilityMacros.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#if MAC_OS_X_VERSION_MIN_REQUIRED > 1050 && !defined(__ppc__)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include <dispatch/dispatch.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #else
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#include <mach/semaphore.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#include <mach/task.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#include <mach/mach_init.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#include <mach/error.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#else
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include <semaphore.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #ifdef TBB_USE_DEBUG
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include <cerrno>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -144,6 +152,7 @@ private:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ };
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #elif __APPLE__
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ //! Edsger Dijkstra's counting semaphore
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#if MAC_OS_X_VERSION_MIN_REQUIRED > 1050 && !defined(__ppc__)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ class semaphore : no_copy {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ public:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ //! ctor
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -160,6 +169,34 @@ public:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ private:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ dispatch_semaphore_t my_sem;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ };
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#else
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++class semaphore : no_copy {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++public:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ //! ctor
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ semaphore(int start_cnt_ = 0) : sem(start_cnt_) { init_semaphore(start_cnt_); }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ //! dtor
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ ~semaphore() {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ kern_return_t ret = semaphore_destroy( mach_task_self(), sem );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ __TBB_ASSERT_EX( ret==err_none, nullptr);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ //! wait/acquire
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ void P() {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ int ret;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ do {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ ret = semaphore_wait( sem );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ } while( ret==KERN_ABORTED );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ __TBB_ASSERT( ret==KERN_SUCCESS, "semaphore_wait() failed" );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ //! post/release
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ void V() { semaphore_signal( sem ); }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++private:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ semaphore_t sem;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ void init_semaphore(int start_cnt_) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ kern_return_t ret = semaphore_create( mach_task_self(), &sem, SYNC_POLICY_FIFO, start_cnt_ );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ __TBB_ASSERT_EX( ret==err_none, "failed to create a semaphore" );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++};
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif /* __APPLE__ */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #else /* Linux/Unix */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ typedef uint32_t sem_count_t;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ //! Edsger Dijkstra's counting semaphore
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -231,7 +268,35 @@ private:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #endif /* !__TBB_USE_SRWLOCK */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #elif __APPLE__
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ //! binary_semaphore for concurrent monitor
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#if MAC_OS_X_VERSION_MIN_REQUIRED > 1050 && !defined(__ppc__)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ using binary_semaphore = semaphore;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#else
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++class binary_semaphore : no_copy {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++public:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ //! ctor
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ binary_semaphore() : my_sem(0) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ kern_return_t ret = semaphore_create( mach_task_self(), &my_sem, SYNC_POLICY_FIFO, 0 );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ __TBB_ASSERT_EX( ret==err_none, "failed to create a semaphore" );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ //! dtor
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ ~binary_semaphore() {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ kern_return_t ret = semaphore_destroy( mach_task_self(), my_sem );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ __TBB_ASSERT_EX( ret==err_none, nullptr);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ //! wait/acquire
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ void P() {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ int ret;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ do {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ ret = semaphore_wait( my_sem );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ } while( ret==KERN_ABORTED );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ __TBB_ASSERT( ret==KERN_SUCCESS, "semaphore_wait() failed" );
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ //! post/release
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ void V() { semaphore_signal( my_sem ); }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++private:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ semaphore_t my_sem;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++};
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif /* __APPLE__ */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #else /* Linux/Unix */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #if __TBB_USE_FUTEX
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/devel/onetbb/files/patch-onetbb-older-platforms.diff b/devel/onetbb/files/patch-onetbb-older-platforms.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index 6a1b6487fa0..27cf60c1bee 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/devel/onetbb/files/patch-onetbb-older-platforms.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/devel/onetbb/files/patch-onetbb-older-platforms.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -244,106 +244,6 @@ index 00000000..10eedc3c
</span> +_TBB_runtime_interface_version
+_TBB_runtime_version
+
<span style='display:block; white-space:pre;background:#ffe0e0;'>-diff --git src/tbb/semaphore.h src/tbb/semaphore.h
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-index 9d27f3ac..b8942329 100644
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>---- src/tbb/semaphore.h
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+++ src/tbb/semaphore.h
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -22,8 +22,16 @@
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #if _WIN32||_WIN64
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #include <windows.h>
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #elif __APPLE__
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#include <AvailabilityMacros.h>
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#if MAC_OS_X_VERSION_MIN_REQUIRED > 1060
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #include <dispatch/dispatch.h>
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #else
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#include <mach/semaphore.h>
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#include <mach/task.h>
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#include <mach/mach_init.h>
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#include <mach/error.h>
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#endif
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#else
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #include <semaphore.h>
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #ifdef TBB_USE_DEBUG
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #include <cerrno>
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -144,6 +152,7 @@ private:
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- };
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #elif __APPLE__
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- //! Edsger Dijkstra's counting semaphore
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#if MAC_OS_X_VERSION_MIN_REQUIRED > 1060
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- class semaphore : no_copy {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- public:
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- //! ctor
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -160,6 +169,34 @@ public:
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- private:
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- dispatch_semaphore_t my_sem;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- };
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#else
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+class semaphore : no_copy {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+public:
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ //! ctor
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ semaphore(int start_cnt_ = 0) : sem(start_cnt_) { init_semaphore(start_cnt_); }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ //! dtor
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ ~semaphore() {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ kern_return_t ret = semaphore_destroy( mach_task_self(), sem );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ __TBB_ASSERT_EX( ret==err_none, nullptr);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ //! wait/acquire
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ void P() {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ int ret;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ do {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ ret = semaphore_wait( sem );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ } while( ret==KERN_ABORTED );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ __TBB_ASSERT( ret==KERN_SUCCESS, "semaphore_wait() failed" );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ //! post/release
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ void V() { semaphore_signal( sem ); }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+private:
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ semaphore_t sem;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ void init_semaphore(int start_cnt_) {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ kern_return_t ret = semaphore_create( mach_task_self(), &sem, SYNC_POLICY_FIFO, start_cnt_ );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ __TBB_ASSERT_EX( ret==err_none, "failed to create a semaphore" );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+};
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#endif /* __APPLE__ */
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #else /* Linux/Unix */
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- typedef uint32_t sem_count_t;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- //! Edsger Dijkstra's counting semaphore
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -231,7 +268,35 @@ private:
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #endif /* !__TBB_USE_SRWLOCK */
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #elif __APPLE__
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- //! binary_semaphore for concurrent monitor
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#if MAC_OS_X_VERSION_MIN_REQUIRED > 1060
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- using binary_semaphore = semaphore;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#else
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+class binary_semaphore : no_copy {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+public:
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ //! ctor
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ binary_semaphore() : my_sem(0) {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ kern_return_t ret = semaphore_create( mach_task_self(), &my_sem, SYNC_POLICY_FIFO, 0 );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ __TBB_ASSERT_EX( ret==err_none, "failed to create a semaphore" );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ //! dtor
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ ~binary_semaphore() {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ kern_return_t ret = semaphore_destroy( mach_task_self(), my_sem );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ __TBB_ASSERT_EX( ret==err_none, nullptr);
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ //! wait/acquire
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ void P() {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ int ret;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ do {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ ret = semaphore_wait( my_sem );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ } while( ret==KERN_ABORTED );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ __TBB_ASSERT( ret==KERN_SUCCESS, "semaphore_wait() failed" );
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ //! post/release
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ void V() { semaphore_signal( my_sem ); }
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+private:
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+ semaphore_t my_sem;
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+};
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#endif /* __APPLE__ */
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #else /* Linux/Unix */
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #if __TBB_USE_FUTEX
</span> diff --git src/tbb/tools_api/ittnotify_config.h src/tbb/tools_api/ittnotify_config.h
index 0f5d80f6..60cde151 100644
--- src/tbb/tools_api/ittnotify_config.h
</pre><pre style='margin:0'>
</pre>