Patrick Williams | b58112e | 2024-03-07 11:16:36 -0600 | [diff] [blame] | 1 | From a9c874f7418cefbe78f7cd26505ae495cb59bbcf Mon Sep 17 00:00:00 2001 |
| 2 | From: Khem Raj <raj.khem@gmail.com> |
| 3 | Date: Fri, 12 Jan 2024 09:21:39 -0800 |
| 4 | Subject: [PATCH] clang/arm: Do not use MUST_TAIL_CALL |
Patrick Williams | 56b44a9 | 2024-01-19 08:49:29 -0600 | [diff] [blame] | 5 | |
| 6 | This causes clang-17 to crash see [1] |
| 7 | this code is new in webkit 2.42[2] thats why we do not see the crash in older webkit |
| 8 | |
| 9 | [1] https://github.com/llvm/llvm-project/issues/67767 |
| 10 | [2] https://github.com/WebKit/WebKit/commit/4d816460b765acd8aef90ab474615850b91ecc35 |
| 11 | |
| 12 | Upstream-Status: Inappropriate [work around to avoid clang compiler crash] |
| 13 | Signed-off-by: Khem Raj <raj.khem@gmail.com> |
Patrick Williams | b58112e | 2024-03-07 11:16:36 -0600 | [diff] [blame] | 14 | --- |
| 15 | Source/WTF/wtf/Compiler.h | 2 +- |
| 16 | 1 file changed, 1 insertion(+), 1 deletion(-) |
| 17 | |
| 18 | diff --git a/Source/WTF/wtf/Compiler.h b/Source/WTF/wtf/Compiler.h |
| 19 | index 0ea5cb76..c5480dbc 100644 |
Patrick Williams | 56b44a9 | 2024-01-19 08:49:29 -0600 | [diff] [blame] | 20 | --- a/Source/WTF/wtf/Compiler.h |
| 21 | +++ b/Source/WTF/wtf/Compiler.h |
| 22 | @@ -284,7 +284,7 @@ |
| 23 | /* MUST_TAIL_CALL */ |
| 24 | |
| 25 | #if !defined(MUST_TAIL_CALL) && defined(__cplusplus) && defined(__has_cpp_attribute) |
| 26 | -#if __has_cpp_attribute(clang::musttail) |
| 27 | +#if __has_cpp_attribute(clang::musttail) && !defined(__arm__) |
| 28 | #define MUST_TAIL_CALL [[clang::musttail]] |
| 29 | #endif |
| 30 | #endif |