summaryrefslogtreecommitdiffstats
path: root/build/build-clang/llvmorg-17-init-237-g1b9fbc81ff15.patch
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 19:33:14 +0000
commit36d22d82aa202bb199967e9512281e9a53db42c9 (patch)
tree105e8c98ddea1c1e4784a60a5a6410fa416be2de /build/build-clang/llvmorg-17-init-237-g1b9fbc81ff15.patch
parentInitial commit. (diff)
downloadfirefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.tar.xz
firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.zip
Adding upstream version 115.7.0esr.upstream/115.7.0esrupstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'build/build-clang/llvmorg-17-init-237-g1b9fbc81ff15.patch')
-rw-r--r--build/build-clang/llvmorg-17-init-237-g1b9fbc81ff15.patch45
1 files changed, 45 insertions, 0 deletions
diff --git a/build/build-clang/llvmorg-17-init-237-g1b9fbc81ff15.patch b/build/build-clang/llvmorg-17-init-237-g1b9fbc81ff15.patch
new file mode 100644
index 0000000000..4283a1f17a
--- /dev/null
+++ b/build/build-clang/llvmorg-17-init-237-g1b9fbc81ff15.patch
@@ -0,0 +1,45 @@
+From 1b9fbc81ff15f6ad5a0e7f29c486c6edd0bce94c Mon Sep 17 00:00:00 2001
+From: Mike Hommey <mh@glandium.org>
+Date: Thu, 26 Jan 2023 21:28:09 +0100
+Subject: [PATCH] [extract_symbols.py] Filter out more symbols for MSVC
+
+This strips out about 5k symbols.
+
+Fixes https://github.com/llvm/llvm-project/issues/60109
+
+Reviewed By: john.brawn
+
+Differential Revision: https://reviews.llvm.org/D142431
+---
+ llvm/utils/extract_symbols.py | 8 +++++++-
+ 1 file changed, 7 insertions(+), 1 deletion(-)
+
+diff --git a/llvm/utils/extract_symbols.py b/llvm/utils/extract_symbols.py
+index 0f8e8ba64c80..298ee6ba4eeb 100755
+--- a/llvm/utils/extract_symbols.py
++++ b/llvm/utils/extract_symbols.py
+@@ -141,7 +141,10 @@ def should_keep_microsoft_symbol(symbol, calling_convention_decoration):
+ # Remove calling convention decoration from names
+ match = re.match('[_@]([^@]+)', symbol)
+ if match:
+- return match.group(1)
++ symbol = match.group(1)
++ # Discard floating point/SIMD constants.
++ if symbol.startswith(("__xmm@", "__ymm@", "__real@")):
++ return None
+ return symbol
+ # Function template instantiations start with ?$; keep the instantiations of
+ # clang::Type::getAs, as some of them are explipict specializations that are
+@@ -165,6 +168,9 @@ def should_keep_microsoft_symbol(symbol, calling_convention_decoration):
+ # namespace doesn't exist outside of that translation unit.
+ elif re.search('\?A(0x\w+)?@', symbol):
+ return None
++ # Skip X86GenMnemonicTables functions, they are not exposed from llvm/include/.
++ elif re.match('\?is[A-Z0-9]*@X86@llvm', symbol):
++ return None
+ # Keep mangled llvm:: and clang:: function symbols. How we detect these is a
+ # bit of a mess and imprecise, but that avoids having to completely demangle
+ # the symbol name. The outermost namespace is at the end of the identifier
+--
+2.39.0.1.g6739ec1790
+