[clang] [llvm] [Clang] Add `-fsanitize-compilation-dir=` for reproducible sanitizer builds (PR #201803)

Vitaly Buka via cfe-commits cfe-commits at lists.llvm.org
Sun Jun 7 22:06:14 PDT 2026


================
@@ -408,6 +413,30 @@ run-time performance, which leads to increased binary size. Using the
 flag forces all code instrumentation to be outlined, which reduces the size
 of the generated code, but also reduces the run-time performance.
 
+Remapping source paths
+----------------------
+
+AddressSanitizer embeds the source file path in global metadata. For
+reproducible builds, the option ``-fsanitize-compilation-dir=<dir>`` can be
----------------
vitalybuka wrote:

why can't we rely on existing -ffile-compilation-dir= ?

https://github.com/llvm/llvm-project/pull/201803


More information about the cfe-commits mailing list