Remove typeinfo from Vulkan exported symbols
Exporting all typeinfo was copied over from the GLES version scripts
which addressed crbug.com/737384. However, this can lead to ODR
violations, and we have several other solutions in place for avoiding
UBSan failures.
Remove it entirely for now. If this causes a regression and we still
have to export some typeinfo, we should do so selectively. For example
to only export typeinfo for objects in the vk namespace:
_ZTS*vk*;
_ZTI*vk*;
Alternatively, or in addition, we can try using
'-mllvm -asan-use-private-alias=1'.
Bug: b/155441530
Change-Id: I07303ac01b05d02b879fff829b6a9945c16fdf82
Reviewed-on: https://swiftshader-review.googlesource.com/c/SwiftShader/+/44689
Presubmit-Ready: Nicolas Capens <nicolascapens@google.com>
Kokoro-Result: kokoro <noreply+kokoro@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Tested-by: Nicolas Capens <nicolascapens@google.com>
diff --git a/src/Vulkan/android_vk_swiftshader.lds b/src/Vulkan/android_vk_swiftshader.lds
index 36d8f75..7ee098c 100644
--- a/src/Vulkan/android_vk_swiftshader.lds
+++ b/src/Vulkan/android_vk_swiftshader.lds
@@ -7,10 +7,6 @@
vk_icdGetInstanceProcAddr;
vk_icdNegotiateLoaderICDInterfaceVersion;
- # Type-strings and type-infos required by sanitizers
- _ZTS*;
- _ZTI*;
-
# Android HAL module info object
HMI;
diff --git a/src/Vulkan/fuchsia_vk_swiftshader.lds b/src/Vulkan/fuchsia_vk_swiftshader.lds
index b235a69..919fceb 100644
--- a/src/Vulkan/fuchsia_vk_swiftshader.lds
+++ b/src/Vulkan/fuchsia_vk_swiftshader.lds
@@ -10,10 +10,6 @@
vk_icdNegotiateLoaderICDInterfaceVersion;
vk_icdInitializeConnectToServiceCallback;
- # Type-strings and type-infos required by sanitizers
- _ZTS*;
- _ZTI*;
-
local:
*;
};
diff --git a/src/Vulkan/vk_swiftshader.lds b/src/Vulkan/vk_swiftshader.lds
index ae3c49f..fedd8c7 100644
--- a/src/Vulkan/vk_swiftshader.lds
+++ b/src/Vulkan/vk_swiftshader.lds
@@ -215,10 +215,6 @@
vkGetPhysicalDeviceSurfaceFormatsKHR;
vkGetPhysicalDeviceSurfacePresentModesKHR;
- # Type-strings and type-infos required by sanitizers
- _ZTS*;
- _ZTI*;
-
# Android HAL module info object
HMI;