Is your feature request related to a problem? Please describe.
I'm always frustrated when debugging subtle and hard-to-diagnose issues in Nix due to undefined behavior and memory errors in the C++ codebase. These errors can cause unpredictable behavior and are difficult to trace and fix.
Describe the solution you'd like
I would like the Nix build process to include C++ sanitizers such as AddressSanitizer, UndefinedBehaviorSanitizer, and ThreadSanitizer. Enabling these sanitizers during the build can help detect and report errors related to memory usage, undefined behavior, and threading issues, making the code more robust and easier to maintain.
Describe alternatives you've considered
- Running sanitizers manually on specific tests and components, but this is not as thorough or automated as including them in the build process.
- Relying on static analysis tools, which are helpful but do not catch all runtime issues that sanitizers can detect.
- Incorporating sanitizers only in a separate debugging build configuration, but this would still require additional maintenance and might be overlooked.
Additional context
Including sanitizers in the build process can be controlled via build options or environment variables, ensuring they are only enabled during development and testing phases, not in production builds. This would allow developers to benefit from the enhanced error detection without affecting production performance.
Priorities
Add 👍 to issues you find important.
Is your feature request related to a problem? Please describe.
I'm always frustrated when debugging subtle and hard-to-diagnose issues in Nix due to undefined behavior and memory errors in the C++ codebase. These errors can cause unpredictable behavior and are difficult to trace and fix.
Describe the solution you'd like
I would like the Nix build process to include C++ sanitizers such as AddressSanitizer, UndefinedBehaviorSanitizer, and ThreadSanitizer. Enabling these sanitizers during the build can help detect and report errors related to memory usage, undefined behavior, and threading issues, making the code more robust and easier to maintain.
Describe alternatives you've considered
Additional context
Including sanitizers in the build process can be controlled via build options or environment variables, ensuring they are only enabled during development and testing phases, not in production builds. This would allow developers to benefit from the enhanced error detection without affecting production performance.
Priorities
Add 👍 to issues you find important.