From 65eb1fd3c0b5df9d24873258d7e26b3d15301b6c Mon Sep 17 00:00:00 2001 From: Alexander Shaposhnikov Date: Thu, 30 Apr 2026 13:25:27 -0700 Subject: [PATCH] Add PTHREADPOOL_NO_SANITIZE_FUNCTION macro. PiperOrigin-RevId: 908344162 --- .github/workflows/build.yml | 32 +++---- MODULE.bazel | 8 +- WORKSPACE | 7 -- include/pthreadpool.h | 10 ++ src/fastpath.c | 66 ++++++------- src/portable-api.c | 180 ++++++++++++++++++------------------ test/pthreadpool_v2.cc | 3 +- 7 files changed, 150 insertions(+), 156 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 7aec7f0..ef1250f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -34,7 +34,7 @@ jobs: - name: Setup ccache uses: hendrikmuhs/ccache-action@v1.2 with: - key: ${{ github.job }} + key: v2-${{ github.job }} max-size: "500M" save: ${{ inputs.update-caches }} - name: Create output directory @@ -65,7 +65,7 @@ jobs: - name: Setup ccache uses: hendrikmuhs/ccache-action@v1.2 with: - key: ${{ github.job }} + key: v2-${{ github.job }} max-size: "500M" save: ${{ inputs.update-caches }} - name: Create output directory @@ -90,7 +90,7 @@ jobs: - name: Setup ccache uses: hendrikmuhs/ccache-action@v1.2 with: - key: ${{ github.job }} + key: v2-${{ github.job }} max-size: "500M" save: ${{ inputs.update-caches }} - name: Install Ninja @@ -115,7 +115,7 @@ jobs: - name: Setup ccache uses: hendrikmuhs/ccache-action@v1.2 with: - key: ${{ github.job }} + key: v2-${{ github.job }} max-size: "500M" save: ${{ inputs.update-caches }} - name: Install Ninja @@ -144,7 +144,7 @@ jobs: - name: Setup ccache uses: hendrikmuhs/ccache-action@v1.2 with: - key: ${{ github.job }} + key: v2-${{ github.job }} max-size: "500M" save: ${{ inputs.update-caches }} - name: Install Ninja @@ -175,7 +175,7 @@ jobs: - name: Setup ccache uses: hendrikmuhs/ccache-action@v1.2 with: - key: ${{ github.job }} + key: v2-${{ github.job }} max-size: "500M" save: ${{ inputs.update-caches }} - name: Create output directory @@ -221,7 +221,7 @@ jobs: - name: Setup ccache uses: hendrikmuhs/ccache-action@v1.2 with: - key: ${{ github.job }}-${{ matrix.arch }} + key: v2-${{ github.job }}-${{ matrix.arch }} max-size: "500M" save: ${{ inputs.update-caches }} - name: Force compiler binary mtime @@ -303,9 +303,9 @@ jobs: uses: actions/cache/restore@v4 with: path: "/home/runner/.cache/bazel" - key: ${{ github.job }} + key: v2-${{ github.job }} restore-keys: | - ${{ github.job }}- + v2-${{ github.job }}- - name: Build and run tests if: ${{ inputs.run-tests }} env: @@ -324,7 +324,7 @@ jobs: uses: actions/cache/save@v4 with: path: "/home/runner/.cache/bazel" - key: ${{ github.job }}-${{ github.sha }} + key: v2-${{ github.job }}-${{ github.sha }} bazel-linux-aarch64-clang18: runs-on: arm-ubuntu-arm-22.04-4core @@ -346,9 +346,9 @@ jobs: uses: actions/cache/restore@v4 with: path: "/home/runner/.cache/bazel" - key: ${{ github.job }} + key: v2-${{ github.job }} restore-keys: | - ${{ github.job }}- + v2-${{ github.job }}- - name: Build and run tests if: ${{ inputs.run-tests }} env: @@ -367,7 +367,7 @@ jobs: uses: actions/cache/save@v4 with: path: "/home/runner/.cache/bazel" - key: ${{ github.job }}-${{ github.sha }} + key: v2-${{ github.job }}-${{ github.sha }} bazel-linux-x86_64-gcc-9: runs-on: ubuntu-22.04-8core @@ -390,9 +390,9 @@ jobs: uses: actions/cache/restore@v4 with: path: "/home/runner/.cache/bazel" - key: ${{ github.job }} + key: v2-${{ github.job }} restore-keys: | - ${{ github.job }}- + v2-${{ github.job }}- - name: Build tests run: | bazel build ${BAZEL_DEFINES} :pthreadpool_test :pthreadpool_cxx_test @@ -412,4 +412,4 @@ jobs: uses: actions/cache/save@v4 with: path: "/home/runner/.cache/bazel" - key: ${{ github.job }}-${{ github.sha }} + key: v2-${{ github.job }}-${{ github.sha }} diff --git a/MODULE.bazel b/MODULE.bazel index 17fc9d0..a6ee5a7 100644 --- a/MODULE.bazel +++ b/MODULE.bazel @@ -4,9 +4,9 @@ module( ) # Bazel rule definitions -bazel_dep(name = "rules_cc", version = "0.1.1") +bazel_dep(name = "rules_cc", version = "0.2.17") bazel_dep(name = "rules_license", version = "1.0.0") -bazel_dep(name = "rules_python", version = "1.0.0") +bazel_dep(name = "rules_python", version = "1.7.0") pip = use_extension("@rules_python//python/extensions:pip.bzl", "pip") pip.parse( @@ -17,10 +17,10 @@ pip.parse( use_repo(pip, "pip") # Bazel Skylib. -bazel_dep(name = "bazel_skylib", version = "1.7.1") +bazel_dep(name = "bazel_skylib", version = "1.8.2") # Bazel Platforms -bazel_dep(name = "platforms", version = "0.0.10") +bazel_dep(name = "platforms", version = "1.0.0") # TODO: some (most? all?) of the http_archive() calls below could become bazel_dep() calls, # but it would require verifying that the semver provided by the Bazel registry matches the hash diff --git a/WORKSPACE b/WORKSPACE index 2f2b175..13c5dbb 100644 --- a/WORKSPACE +++ b/WORKSPACE @@ -2,13 +2,6 @@ workspace(name = "pthreadpool") load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive") -# Bazel rule definitions -http_archive( - name = "rules_cc", - strip_prefix = "rules_cc-main", - urls = ["https://github.com/bazelbuild/rules_cc/archive/master.zip"], -) - # LINT.IfChange(googletest) # Google Test framework, used by most unit-tests. http_archive( diff --git a/include/pthreadpool.h b/include/pthreadpool.h index 07817c7..bc05b81 100644 --- a/include/pthreadpool.h +++ b/include/pthreadpool.h @@ -148,6 +148,16 @@ typedef void (*pthreadpool_task_3d_tile_1d_dynamic_with_id_with_thread_t)( */ #define PTHREADPOOL_FLAG_DONT_SPIN_WORKERS 0x00000004 +// Disable function sanitization here. The thread pool calls these functions +// via function pointers with void* contexts, which triggers false positives in +// the function sanitizer when casting and calling the actual context type. +#if defined(__clang__) && __has_attribute(no_sanitize) +#define PTHREADPOOL_NO_SANITIZE_FUNCTION \ + __attribute__((no_sanitize("function"))) +#else +#define PTHREADPOOL_NO_SANITIZE_FUNCTION +#endif + #ifdef __cplusplus extern "C" { #endif diff --git a/src/fastpath.c b/src/fastpath.c index 693f74c..f9ad595 100644 --- a/src/fastpath.c +++ b/src/fastpath.c @@ -31,7 +31,7 @@ #include "threadpool-object.h" #include "threadpool-utils.h" -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_1d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_1d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -68,8 +68,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_1d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void -pthreadpool_thread_parallelize_1d_with_thread_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_1d_with_thread_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -107,7 +106,7 @@ pthreadpool_thread_parallelize_1d_with_thread_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_1d_with_uarch_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_1d_with_uarch_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -157,7 +156,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_1d_with_uarch_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_1d_tile_1d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_1d_tile_1d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -202,7 +201,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_1d_tile_1d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_2d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_2d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -253,8 +252,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_2d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void -pthreadpool_thread_parallelize_2d_with_thread_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_2d_with_thread_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -306,7 +304,7 @@ pthreadpool_thread_parallelize_2d_with_thread_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_2d_tile_1d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_2d_tile_1d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -363,8 +361,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_2d_tile_1d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void -pthreadpool_thread_parallelize_2d_tile_1d_with_uarch_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_2d_tile_1d_with_uarch_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -435,8 +432,7 @@ pthreadpool_thread_parallelize_2d_tile_1d_with_uarch_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void -pthreadpool_thread_parallelize_2d_tile_1d_with_uarch_with_thread_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_2d_tile_1d_with_uarch_with_thread_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -508,7 +504,7 @@ pthreadpool_thread_parallelize_2d_tile_1d_with_uarch_with_thread_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_2d_tile_2d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_2d_tile_2d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -569,8 +565,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_2d_tile_2d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void -pthreadpool_thread_parallelize_2d_tile_2d_with_uarch_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_2d_tile_2d_with_uarch_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -647,7 +642,7 @@ pthreadpool_thread_parallelize_2d_tile_2d_with_uarch_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_3d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_3d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -709,7 +704,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_3d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_3d_tile_1d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_3d_tile_1d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -776,8 +771,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_3d_tile_1d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void -pthreadpool_thread_parallelize_3d_tile_1d_with_thread_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_3d_tile_1d_with_thread_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -845,8 +839,7 @@ pthreadpool_thread_parallelize_3d_tile_1d_with_thread_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void -pthreadpool_thread_parallelize_3d_tile_1d_with_uarch_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_3d_tile_1d_with_uarch_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -927,8 +920,7 @@ pthreadpool_thread_parallelize_3d_tile_1d_with_uarch_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void -pthreadpool_thread_parallelize_3d_tile_1d_with_uarch_with_thread_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_3d_tile_1d_with_uarch_with_thread_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1010,7 +1002,7 @@ pthreadpool_thread_parallelize_3d_tile_1d_with_uarch_with_thread_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_3d_tile_2d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_3d_tile_2d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1082,8 +1074,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_3d_tile_2d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void -pthreadpool_thread_parallelize_3d_tile_2d_with_uarch_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_3d_tile_2d_with_uarch_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1171,7 +1162,7 @@ pthreadpool_thread_parallelize_3d_tile_2d_with_uarch_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_4d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_4d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1244,7 +1235,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_4d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_4d_tile_1d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_4d_tile_1d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1322,7 +1313,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_4d_tile_1d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_4d_tile_2d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_4d_tile_2d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1404,8 +1395,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_4d_tile_2d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void -pthreadpool_thread_parallelize_4d_tile_2d_with_uarch_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_4d_tile_2d_with_uarch_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1504,7 +1494,7 @@ pthreadpool_thread_parallelize_4d_tile_2d_with_uarch_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_5d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_5d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1587,7 +1577,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_5d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_5d_tile_1d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_5d_tile_1d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1676,7 +1666,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_5d_tile_1d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_5d_tile_2d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_5d_tile_2d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1769,7 +1759,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_5d_tile_2d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_6d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_6d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1863,7 +1853,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_6d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_6d_tile_1d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_6d_tile_1d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1962,7 +1952,7 @@ PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_6d_tile_1d_fastpath( pthreadpool_fence_release(); } -PTHREADPOOL_INTERNAL void pthreadpool_thread_parallelize_6d_tile_2d_fastpath( +PTHREADPOOL_INTERNAL PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_thread_parallelize_6d_tile_2d_fastpath( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); diff --git a/src/portable-api.c b/src/portable-api.c index 5bfcf8e..b136ac7 100644 --- a/src/portable-api.c +++ b/src/portable-api.c @@ -71,7 +71,7 @@ size_t pthreadpool_get_threads_count(struct pthreadpool* threadpool) { return threadpool->threads_count; } -static void thread_parallelize_1d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_1d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -105,7 +105,7 @@ static void thread_parallelize_1d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_1d_with_thread(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_1d_with_thread(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -140,7 +140,7 @@ static void thread_parallelize_1d_with_thread(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_1d_with_uarch(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_1d_with_uarch(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -187,7 +187,7 @@ static void thread_parallelize_1d_with_uarch(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_1d_tile_1d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_1d_tile_1d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -229,7 +229,7 @@ static void thread_parallelize_1d_tile_1d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_1d_tile_1d_dynamic( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_1d_tile_1d_dynamic( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -285,7 +285,7 @@ static void thread_parallelize_1d_tile_1d_dynamic( pthreadpool_fence_release(); } -static void thread_parallelize_1d_tile_1d_dynamic_with_thread( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_1d_tile_1d_dynamic_with_thread( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -341,7 +341,7 @@ static void thread_parallelize_1d_tile_1d_dynamic_with_thread( pthreadpool_fence_release(); } -static void thread_parallelize_1d_tile_1d_dynamic_with_uarch_with_thread( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_1d_tile_1d_dynamic_with_uarch_with_thread( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -407,7 +407,7 @@ static void thread_parallelize_1d_tile_1d_dynamic_with_uarch_with_thread( pthreadpool_fence_release(); } -static void thread_parallelize_2d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -455,7 +455,7 @@ static void thread_parallelize_2d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_2d_with_thread(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_with_thread(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -504,7 +504,7 @@ static void thread_parallelize_2d_with_thread(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_2d_tile_1d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_tile_1d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -558,7 +558,7 @@ static void thread_parallelize_2d_tile_1d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_2d_tile_1d_with_uarch( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_tile_1d_with_uarch( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -626,7 +626,7 @@ static void thread_parallelize_2d_tile_1d_with_uarch( pthreadpool_fence_release(); } -static void thread_parallelize_2d_tile_1d_with_uarch_with_thread( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_tile_1d_with_uarch_with_thread( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -695,7 +695,7 @@ static void thread_parallelize_2d_tile_1d_with_uarch_with_thread( pthreadpool_fence_release(); } -static void thread_parallelize_2d_tile_1d_dynamic( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_tile_1d_dynamic( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -765,7 +765,7 @@ static void thread_parallelize_2d_tile_1d_dynamic( pthreadpool_fence_release(); } -static void thread_parallelize_2d_tile_1d_dynamic_with_thread( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_tile_1d_dynamic_with_thread( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -835,7 +835,7 @@ static void thread_parallelize_2d_tile_1d_dynamic_with_thread( pthreadpool_fence_release(); } -static void thread_parallelize_2d_tile_1d_dynamic_with_uarch_with_thread( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_tile_1d_dynamic_with_uarch_with_thread( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -915,7 +915,7 @@ static void thread_parallelize_2d_tile_1d_dynamic_with_uarch_with_thread( pthreadpool_fence_release(); } -static void thread_parallelize_2d_tile_2d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_tile_2d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -973,7 +973,7 @@ static void thread_parallelize_2d_tile_2d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_2d_tile_2d_with_uarch( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_tile_2d_with_uarch( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1047,7 +1047,7 @@ static void thread_parallelize_2d_tile_2d_with_uarch( pthreadpool_fence_release(); } -static void thread_parallelize_2d_tile_2d_dynamic( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_tile_2d_dynamic( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1135,7 +1135,7 @@ static void thread_parallelize_2d_tile_2d_dynamic( pthreadpool_fence_release(); } -static void thread_parallelize_2d_tile_2d_dynamic_with_uarch( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_tile_2d_dynamic_with_uarch( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1237,7 +1237,7 @@ static void thread_parallelize_2d_tile_2d_dynamic_with_uarch( pthreadpool_fence_release(); } -static void thread_parallelize_2d_tile_2d_dynamic_with_thread( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_2d_tile_2d_dynamic_with_thread( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1325,7 +1325,7 @@ static void thread_parallelize_2d_tile_2d_dynamic_with_thread( pthreadpool_fence_release(); } -static void thread_parallelize_3d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1384,7 +1384,7 @@ static void thread_parallelize_3d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_1d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_1d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1448,7 +1448,7 @@ static void thread_parallelize_3d_tile_1d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_1d_with_thread( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_1d_with_thread( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1513,7 +1513,7 @@ static void thread_parallelize_3d_tile_1d_with_thread( pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_1d_with_uarch( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_1d_with_uarch( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1591,7 +1591,7 @@ static void thread_parallelize_3d_tile_1d_with_uarch( pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_1d_with_uarch_with_thread( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_1d_with_uarch_with_thread( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1670,7 +1670,7 @@ static void thread_parallelize_3d_tile_1d_with_uarch_with_thread( pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_1d_dynamic( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_1d_dynamic( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1745,7 +1745,7 @@ static void thread_parallelize_3d_tile_1d_dynamic( pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_1d_dynamic_with_thread( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_1d_dynamic_with_thread( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1820,7 +1820,7 @@ static void thread_parallelize_3d_tile_1d_dynamic_with_thread( pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_1d_dynamic_with_uarch_with_thread( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_1d_dynamic_with_uarch_with_thread( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1909,7 +1909,7 @@ static void thread_parallelize_3d_tile_1d_dynamic_with_uarch_with_thread( pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_2d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_2d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -1978,7 +1978,7 @@ static void thread_parallelize_3d_tile_2d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_2d_with_uarch( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_2d_with_uarch( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -2063,7 +2063,7 @@ static void thread_parallelize_3d_tile_2d_with_uarch( pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_2d_dynamic( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_2d_dynamic( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -2164,7 +2164,7 @@ static void thread_parallelize_3d_tile_2d_dynamic( pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_2d_dynamic_with_uarch( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_2d_dynamic_with_uarch( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -2281,7 +2281,7 @@ static void thread_parallelize_3d_tile_2d_dynamic_with_uarch( pthreadpool_fence_release(); } -static void thread_parallelize_3d_tile_2d_dynamic_with_thread( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_3d_tile_2d_dynamic_with_thread( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -2384,7 +2384,7 @@ static void thread_parallelize_3d_tile_2d_dynamic_with_thread( pthreadpool_fence_release(); } -static void thread_parallelize_4d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_4d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -2454,7 +2454,7 @@ static void thread_parallelize_4d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_4d_tile_1d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_4d_tile_1d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -2529,7 +2529,7 @@ static void thread_parallelize_4d_tile_1d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_4d_tile_2d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_4d_tile_2d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -2608,7 +2608,7 @@ static void thread_parallelize_4d_tile_2d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_4d_tile_2d_with_uarch( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_4d_tile_2d_with_uarch( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -2704,7 +2704,7 @@ static void thread_parallelize_4d_tile_2d_with_uarch( pthreadpool_fence_release(); } -static void thread_parallelize_4d_tile_2d_dynamic( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_4d_tile_2d_dynamic( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -2816,7 +2816,7 @@ static void thread_parallelize_4d_tile_2d_dynamic( pthreadpool_fence_release(); } -static void thread_parallelize_4d_tile_2d_dynamic_with_uarch( +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_4d_tile_2d_dynamic_with_uarch( struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -2943,7 +2943,7 @@ static void thread_parallelize_4d_tile_2d_dynamic_with_uarch( pthreadpool_fence_release(); } -static void thread_parallelize_5d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_5d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -3023,7 +3023,7 @@ static void thread_parallelize_5d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_5d_tile_1d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_5d_tile_1d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -3109,7 +3109,7 @@ static void thread_parallelize_5d_tile_1d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_5d_tile_2d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_5d_tile_2d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -3199,7 +3199,7 @@ static void thread_parallelize_5d_tile_2d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_6d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_6d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -3290,7 +3290,7 @@ static void thread_parallelize_6d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_6d_tile_1d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_6d_tile_1d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -3386,7 +3386,7 @@ static void thread_parallelize_6d_tile_1d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -static void thread_parallelize_6d_tile_2d(struct pthreadpool* threadpool, +static PTHREADPOOL_NO_SANITIZE_FUNCTION void thread_parallelize_6d_tile_2d(struct pthreadpool* threadpool, struct thread_info* thread) { assert(threadpool != NULL); assert(thread != NULL); @@ -3487,7 +3487,7 @@ static void thread_parallelize_6d_tile_2d(struct pthreadpool* threadpool, pthreadpool_fence_release(); } -void pthreadpool_parallelize_1d(struct pthreadpool* threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_1d(struct pthreadpool* threadpool, pthreadpool_task_1d_t function, void* context, size_t range, uint32_t flags) { size_t threads_count; @@ -3518,7 +3518,7 @@ void pthreadpool_parallelize_1d(struct pthreadpool* threadpool, } } -void pthreadpool_parallelize_1d_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_1d_with_thread( struct pthreadpool* threadpool, pthreadpool_task_1d_with_thread_t function, void* context, size_t range, uint32_t flags) { size_t threads_count; @@ -3551,7 +3551,7 @@ void pthreadpool_parallelize_1d_with_thread( } } -void pthreadpool_parallelize_1d_with_uarch( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_1d_with_uarch( pthreadpool_t threadpool, pthreadpool_task_1d_with_id_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, size_t range, uint32_t flags) { @@ -3599,7 +3599,7 @@ void pthreadpool_parallelize_1d_with_uarch( } } -void pthreadpool_parallelize_1d_tile_1d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_1d_tile_1d(pthreadpool_t threadpool, pthreadpool_task_1d_tile_1d_t function, void* context, size_t range, size_t tile, uint32_t flags) { @@ -3638,7 +3638,7 @@ void pthreadpool_parallelize_1d_tile_1d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_1d_tile_1d_dynamic( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_1d_tile_1d_dynamic( pthreadpool_t threadpool, pthreadpool_task_1d_tile_1d_dynamic_t function, void* context, size_t range, size_t tile, uint32_t flags) { size_t threads_count; @@ -3666,7 +3666,7 @@ void pthreadpool_parallelize_1d_tile_1d_dynamic( } } -void pthreadpool_parallelize_1d_tile_1d_dynamic_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_1d_tile_1d_dynamic_with_thread( pthreadpool_t threadpool, pthreadpool_task_1d_tile_1d_dynamic_with_id_t function, void* context, size_t range, size_t tile, uint32_t flags) { @@ -3695,7 +3695,7 @@ void pthreadpool_parallelize_1d_tile_1d_dynamic_with_thread( } } -void pthreadpool_parallelize_1d_tile_1d_dynamic_with_uarch_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_1d_tile_1d_dynamic_with_uarch_with_thread( pthreadpool_t threadpool, pthreadpool_task_1d_tile_1d_dynamic_with_id_with_thread_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, @@ -3737,7 +3737,7 @@ void pthreadpool_parallelize_1d_tile_1d_dynamic_with_uarch_with_thread( } } -void pthreadpool_parallelize_2d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d(pthreadpool_t threadpool, pthreadpool_task_2d_t function, void* context, size_t range_i, size_t range_j, uint32_t flags) { @@ -3775,7 +3775,7 @@ void pthreadpool_parallelize_2d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_2d_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_with_thread( pthreadpool_t threadpool, pthreadpool_task_2d_with_thread_t function, void* context, size_t range_i, size_t range_j, uint32_t flags) { size_t threads_count; @@ -3814,7 +3814,7 @@ void pthreadpool_parallelize_2d_with_thread( } } -void pthreadpool_parallelize_2d_tile_1d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_tile_1d(pthreadpool_t threadpool, pthreadpool_task_2d_tile_1d_t function, void* context, size_t range_i, size_t range_j, size_t tile_j, @@ -3858,7 +3858,7 @@ void pthreadpool_parallelize_2d_tile_1d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_2d_tile_1d_with_uarch( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_tile_1d_with_uarch( pthreadpool_t threadpool, pthreadpool_task_2d_tile_1d_with_id_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, size_t range_i, size_t range_j, size_t tile_j, uint32_t flags) { @@ -3914,7 +3914,7 @@ void pthreadpool_parallelize_2d_tile_1d_with_uarch( } } -void pthreadpool_parallelize_2d_tile_1d_with_uarch_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_tile_1d_with_uarch_with_thread( pthreadpool_t threadpool, pthreadpool_task_2d_tile_1d_with_id_with_thread_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, size_t range_i, @@ -3971,7 +3971,7 @@ void pthreadpool_parallelize_2d_tile_1d_with_uarch_with_thread( } } -void pthreadpool_parallelize_2d_tile_1d_dynamic( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_tile_1d_dynamic( pthreadpool_t threadpool, pthreadpool_task_2d_tile_1d_dynamic_t function, void* context, size_t range_i, size_t range_j, size_t tile_j, uint32_t flags) { @@ -4003,7 +4003,7 @@ void pthreadpool_parallelize_2d_tile_1d_dynamic( } } -void pthreadpool_parallelize_2d_tile_1d_dynamic_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_tile_1d_dynamic_with_thread( pthreadpool_t threadpool, pthreadpool_task_2d_tile_1d_dynamic_with_id_t function, void* context, size_t range_i, size_t range_j, size_t tile_j, uint32_t flags) { @@ -4035,7 +4035,7 @@ void pthreadpool_parallelize_2d_tile_1d_dynamic_with_thread( } } -void pthreadpool_parallelize_2d_tile_1d_dynamic_with_uarch_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_tile_1d_dynamic_with_uarch_with_thread( pthreadpool_t threadpool, pthreadpool_task_2d_tile_1d_dynamic_with_id_with_thread_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, @@ -4081,7 +4081,7 @@ void pthreadpool_parallelize_2d_tile_1d_dynamic_with_uarch_with_thread( } } -void pthreadpool_parallelize_2d_tile_2d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_tile_2d(pthreadpool_t threadpool, pthreadpool_task_2d_tile_2d_t function, void* context, size_t range_i, size_t range_j, size_t tile_i, @@ -4129,7 +4129,7 @@ void pthreadpool_parallelize_2d_tile_2d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_2d_tile_2d_dynamic( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_tile_2d_dynamic( pthreadpool_t threadpool, pthreadpool_task_2d_tile_2d_dynamic_t function, void* context, size_t range_i, size_t range_j, size_t tile_i, size_t tile_j, uint32_t flags) { @@ -4168,7 +4168,7 @@ void pthreadpool_parallelize_2d_tile_2d_dynamic( } } -void pthreadpool_parallelize_2d_tile_2d_dynamic_with_uarch( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_tile_2d_dynamic_with_uarch( pthreadpool_t threadpool, pthreadpool_task_2d_tile_2d_dynamic_with_id_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, size_t range_i, @@ -4220,7 +4220,7 @@ void pthreadpool_parallelize_2d_tile_2d_dynamic_with_uarch( } } -void pthreadpool_parallelize_2d_tile_2d_dynamic_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_tile_2d_dynamic_with_thread( pthreadpool_t threadpool, pthreadpool_task_2d_tile_2d_dynamic_with_id_t function, void* context, size_t range_i, size_t range_j, size_t tile_i, size_t tile_j, @@ -4261,7 +4261,7 @@ void pthreadpool_parallelize_2d_tile_2d_dynamic_with_thread( } } -void pthreadpool_parallelize_2d_tile_2d_with_uarch( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_2d_tile_2d_with_uarch( pthreadpool_t threadpool, pthreadpool_task_2d_tile_2d_with_id_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, size_t range_i, size_t range_j, size_t tile_i, size_t tile_j, @@ -4322,7 +4322,7 @@ void pthreadpool_parallelize_2d_tile_2d_with_uarch( } } -void pthreadpool_parallelize_3d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d(pthreadpool_t threadpool, pthreadpool_task_3d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, uint32_t flags) { @@ -4363,7 +4363,7 @@ void pthreadpool_parallelize_3d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_3d_tile_1d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_1d(pthreadpool_t threadpool, pthreadpool_task_3d_tile_1d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, @@ -4410,7 +4410,7 @@ void pthreadpool_parallelize_3d_tile_1d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_3d_tile_1d_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_1d_with_thread( pthreadpool_t threadpool, pthreadpool_task_3d_tile_1d_with_thread_t function, void* context, size_t range_i, size_t range_j, size_t range_k, size_t tile_k, @@ -4458,7 +4458,7 @@ void pthreadpool_parallelize_3d_tile_1d_with_thread( } } -void pthreadpool_parallelize_3d_tile_1d_with_uarch( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_1d_with_uarch( pthreadpool_t threadpool, pthreadpool_task_3d_tile_1d_with_id_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, size_t range_i, size_t range_j, size_t range_k, size_t tile_k, @@ -4518,7 +4518,7 @@ void pthreadpool_parallelize_3d_tile_1d_with_uarch( } } -void pthreadpool_parallelize_3d_tile_1d_with_uarch_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_1d_with_uarch_with_thread( pthreadpool_t threadpool, pthreadpool_task_3d_tile_1d_with_id_with_thread_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, size_t range_i, @@ -4578,7 +4578,7 @@ void pthreadpool_parallelize_3d_tile_1d_with_uarch_with_thread( } } -void pthreadpool_parallelize_3d_tile_1d_dynamic( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_1d_dynamic( pthreadpool_t threadpool, pthreadpool_task_3d_tile_1d_dynamic_t function, void* context, size_t range_i, size_t range_j, size_t range_k, size_t tile_k, uint32_t flags) { @@ -4613,7 +4613,7 @@ void pthreadpool_parallelize_3d_tile_1d_dynamic( } } -void pthreadpool_parallelize_3d_tile_1d_dynamic_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_1d_dynamic_with_thread( pthreadpool_t threadpool, pthreadpool_task_3d_tile_1d_dynamic_with_id_t function, void* context, size_t range_i, size_t range_j, size_t range_k, size_t tile_k, @@ -4650,7 +4650,7 @@ void pthreadpool_parallelize_3d_tile_1d_dynamic_with_thread( } } -void pthreadpool_parallelize_3d_tile_1d_dynamic_with_uarch_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_1d_dynamic_with_uarch_with_thread( pthreadpool_t threadpool, pthreadpool_task_3d_tile_1d_dynamic_with_id_with_thread_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, @@ -4700,7 +4700,7 @@ void pthreadpool_parallelize_3d_tile_1d_dynamic_with_uarch_with_thread( } } -void pthreadpool_parallelize_3d_tile_2d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_2d(pthreadpool_t threadpool, pthreadpool_task_3d_tile_2d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, @@ -4752,7 +4752,7 @@ void pthreadpool_parallelize_3d_tile_2d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_3d_tile_2d_dynamic( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_2d_dynamic( pthreadpool_t threadpool, pthreadpool_task_3d_tile_2d_dynamic_t function, void* context, size_t range_i, size_t range_j, size_t range_k, size_t tile_j, size_t tile_k, uint32_t flags) { @@ -4797,7 +4797,7 @@ void pthreadpool_parallelize_3d_tile_2d_dynamic( } } -void pthreadpool_parallelize_3d_tile_2d_dynamic_with_uarch( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_2d_dynamic_with_uarch( pthreadpool_t threadpool, pthreadpool_task_3d_tile_2d_dynamic_with_id_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, size_t range_i, @@ -4855,7 +4855,7 @@ void pthreadpool_parallelize_3d_tile_2d_dynamic_with_uarch( } } -void pthreadpool_parallelize_3d_tile_2d_dynamic_with_thread( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_2d_dynamic_with_thread( pthreadpool_t threadpool, pthreadpool_task_3d_tile_2d_dynamic_with_id_t function, void* context, size_t range_i, size_t range_j, size_t range_k, size_t tile_j, @@ -4901,7 +4901,7 @@ void pthreadpool_parallelize_3d_tile_2d_dynamic_with_thread( } } -void pthreadpool_parallelize_3d_tile_2d_with_uarch( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_3d_tile_2d_with_uarch( pthreadpool_t threadpool, pthreadpool_task_3d_tile_2d_with_id_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, size_t range_i, size_t range_j, size_t range_k, size_t tile_j, @@ -4965,7 +4965,7 @@ void pthreadpool_parallelize_3d_tile_2d_with_uarch( } } -void pthreadpool_parallelize_4d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_4d(pthreadpool_t threadpool, pthreadpool_task_4d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, size_t range_l, uint32_t flags) { @@ -5011,7 +5011,7 @@ void pthreadpool_parallelize_4d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_4d_tile_1d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_4d_tile_1d(pthreadpool_t threadpool, pthreadpool_task_4d_tile_1d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, @@ -5064,7 +5064,7 @@ void pthreadpool_parallelize_4d_tile_1d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_4d_tile_2d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_4d_tile_2d(pthreadpool_t threadpool, pthreadpool_task_4d_tile_2d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, @@ -5120,7 +5120,7 @@ void pthreadpool_parallelize_4d_tile_2d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_4d_tile_2d_with_uarch( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_4d_tile_2d_with_uarch( pthreadpool_t threadpool, pthreadpool_task_4d_tile_2d_with_id_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, size_t range_i, size_t range_j, size_t range_k, size_t range_l, @@ -5188,7 +5188,7 @@ void pthreadpool_parallelize_4d_tile_2d_with_uarch( } } -void pthreadpool_parallelize_4d_tile_2d_dynamic( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_4d_tile_2d_dynamic( pthreadpool_t threadpool, pthreadpool_task_4d_tile_2d_dynamic_t function, void* context, size_t range_i, size_t range_j, size_t range_k, size_t range_l, size_t tile_k, size_t tile_l, uint32_t flags) { @@ -5239,7 +5239,7 @@ void pthreadpool_parallelize_4d_tile_2d_dynamic( } } -void pthreadpool_parallelize_4d_tile_2d_dynamic_with_uarch( +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_4d_tile_2d_dynamic_with_uarch( pthreadpool_t threadpool, pthreadpool_task_4d_tile_2d_dynamic_with_id_t function, void* context, uint32_t default_uarch_index, uint32_t max_uarch_index, size_t range_i, @@ -5303,7 +5303,7 @@ void pthreadpool_parallelize_4d_tile_2d_dynamic_with_uarch( } } -void pthreadpool_parallelize_5d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_5d(pthreadpool_t threadpool, pthreadpool_task_5d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, size_t range_l, size_t range_m, @@ -5353,7 +5353,7 @@ void pthreadpool_parallelize_5d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_5d_tile_1d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_5d_tile_1d(pthreadpool_t threadpool, pthreadpool_task_5d_tile_1d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, @@ -5409,7 +5409,7 @@ void pthreadpool_parallelize_5d_tile_1d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_5d_tile_2d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_5d_tile_2d(pthreadpool_t threadpool, pthreadpool_task_5d_tile_2d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, @@ -5470,7 +5470,7 @@ void pthreadpool_parallelize_5d_tile_2d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_6d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_6d(pthreadpool_t threadpool, pthreadpool_task_6d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, size_t range_l, size_t range_m, size_t range_n, @@ -5523,7 +5523,7 @@ void pthreadpool_parallelize_6d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_6d_tile_1d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_6d_tile_1d(pthreadpool_t threadpool, pthreadpool_task_6d_tile_1d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, @@ -5584,7 +5584,7 @@ void pthreadpool_parallelize_6d_tile_1d(pthreadpool_t threadpool, } } -void pthreadpool_parallelize_6d_tile_2d(pthreadpool_t threadpool, +PTHREADPOOL_NO_SANITIZE_FUNCTION void pthreadpool_parallelize_6d_tile_2d(pthreadpool_t threadpool, pthreadpool_task_6d_tile_2d_t function, void* context, size_t range_i, size_t range_j, size_t range_k, diff --git a/test/pthreadpool_v2.cc b/test/pthreadpool_v2.cc index 227f3d0..72ca4bc 100644 --- a/test/pthreadpool_v2.cc +++ b/test/pthreadpool_v2.cc @@ -146,7 +146,8 @@ class SimpleThreadPoolExecutor : public PthreadpoolExecutor { } private: - static void ThreadMain(SimpleThreadPoolExecutor* executor) { + static PTHREADPOOL_NO_SANITIZE_FUNCTION void ThreadMain( + SimpleThreadPoolExecutor* executor) { Task task; while (true) { {