diff options
| -rw-r--r-- | compiler-rt/lib/msan/CMakeLists.txt | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/compiler-rt/lib/msan/CMakeLists.txt b/compiler-rt/lib/msan/CMakeLists.txt index 15cc513c20e..1fd0be1ae86 100644 --- a/compiler-rt/lib/msan/CMakeLists.txt +++ b/compiler-rt/lib/msan/CMakeLists.txt @@ -38,6 +38,11 @@ endif() # Prevent clang from generating libc calls. append_list_if(COMPILER_RT_HAS_FFREESTANDING_FLAG -ffreestanding MSAN_RTL_CFLAGS) +# Tracking down https://bugs.llvm.org/show_bug.cgi?id=40162 +if(CMAKE_SYSTEM_NAME MATCHES "Linux") + list(APPEND MSAN_RTL_CFLAGS -fno-optimize-sibling-calls) +endif() + set(MSAN_RUNTIME_LIBRARIES) # Static runtime library. |

