[clang] 115b6a3 - [Sanitizer][Docs] Improve docs on building Asan (#68636)

via cfe-commits cfe-commits at lists.llvm.org
Mon Oct 9 15:14:00 PDT 2023


Author: Aiden Grossman
Date: 2023-10-09T15:13:56-07:00
New Revision: 115b6a3b17a2068a45075f6c4f3256e84305bc6c

URL: https://github.com/llvm/llvm-project/commit/115b6a3b17a2068a45075f6c4f3256e84305bc6c
DIFF: https://github.com/llvm/llvm-project/commit/115b6a3b17a2068a45075f6c4f3256e84305bc6c.diff

LOG: [Sanitizer][Docs] Improve docs on building Asan (#68636)

Added: 
    

Modified: 
    clang/docs/AddressSanitizer.rst

Removed: 
    


################################################################################
diff  --git a/clang/docs/AddressSanitizer.rst b/clang/docs/AddressSanitizer.rst
index 37f34cb0cc9936d..94ff3404cba6024 100644
--- a/clang/docs/AddressSanitizer.rst
+++ b/clang/docs/AddressSanitizer.rst
@@ -26,7 +26,16 @@ Typical slowdown introduced by AddressSanitizer is **2x**.
 How to build
 ============
 
-Build LLVM/Clang with `CMake <https://llvm.org/docs/CMake.html>`_.
+Build LLVM/Clang with `CMake <https://llvm.org/docs/CMake.html>` and enable
+the ``compiler-rt`` runtime. An example CMake configuration that will allow
+for the use/testing of AddressSanitizer:
+
+.. code-block:: console
+
+   cmake -DCMAKE_BUILD_TYPE=Release \
+     -DLLVM_ENABLE_PROJECTS="clang" \
+     -DLLVM_ENABLE_RUNTIMES="compiler-rt" \
+     ../llvm
 
 Usage
 =====


        


More information about the cfe-commits mailing list