From 801bdd07f0e2714ff7f41fc6edec28b791060cd9 Mon Sep 17 00:00:00 2001 From: Valery Matskevich Date: Sat, 8 Jun 2024 20:29:09 +0300 Subject: [PATCH 1/2] remove aligned_storage from tbb includes Signed-off-by: Valery Matskevich --- include/oneapi/tbb/detail/_concurrent_unordered_base.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/include/oneapi/tbb/detail/_concurrent_unordered_base.h b/include/oneapi/tbb/detail/_concurrent_unordered_base.h index 408292086a..51c334d31b 100644 --- a/include/oneapi/tbb/detail/_concurrent_unordered_base.h +++ b/include/oneapi/tbb/detail/_concurrent_unordered_base.h @@ -1,5 +1,5 @@ /* - Copyright (c) 2005-2023 Intel Corporation + Copyright (c) 2005-2024 Intel Corporation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -179,8 +179,7 @@ class value_node : public list_node } private: - using aligned_storage_type = typename std::aligned_storage::type; - aligned_storage_type my_value; + alignas(value_type) char my_value[sizeof(value_type)]; }; // class value_node template From 0de66b1bf8519a3bd10debdf6017c9be8ee775a7 Mon Sep 17 00:00:00 2001 From: Valery Matskevich Date: Mon, 22 Jul 2024 15:29:16 +0300 Subject: [PATCH 2/2] added cacheline alignment to value node Signed-off-by: Valery Matskevich --- include/oneapi/tbb/detail/_concurrent_unordered_base.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/oneapi/tbb/detail/_concurrent_unordered_base.h b/include/oneapi/tbb/detail/_concurrent_unordered_base.h index 9266f0b6dc..5903e81e49 100644 --- a/include/oneapi/tbb/detail/_concurrent_unordered_base.h +++ b/include/oneapi/tbb/detail/_concurrent_unordered_base.h @@ -179,7 +179,7 @@ class value_node : public list_node } private: - alignas(value_type) char my_value[sizeof(value_type)]; + alignas(value_type) alignas(max_nfs_size) char my_value[sizeof(value_type)]; }; // class value_node template