Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -325,8 +325,8 @@ if(USE_ROCM)
endif()

if(ENABLE_ASAN)
if (CMAKE_CXX_COMPILER_ID MATCHES Intel)
message(FATAL_ERROR "Address Sanitizer is not supported on Intel compiler.")
if (CMAKE_CXX_COMPILER_ID STREQUAL "Intel")
message(FATAL_ERROR "Address Sanitizer is not supported on Intel Classic compiler. Use Intel oneAPI compiler (icpx) instead.")
endif()
add_compile_options(
-fsanitize=address
Expand Down Expand Up @@ -662,4 +662,4 @@ install(PROGRAMS ${ABACUS_BIN_PATH}

if(ENABLE_COVERAGE)
coverage_evaluate()
endif()
endif()
2 changes: 1 addition & 1 deletion docs/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ For the unexpected results when developing ABACUS, [GDB](https://www.sourceware.

4. For debugging ABACUS in multiprocessing situation, `mpirun -n 1 gdb abacus : -n 3 abacus` will attach GDB to the master process, and launch 3 other MPI processes.

For segmentation faults, ABACUS can be built with [Address Sanitizer](https://github.com/google/sanitizers/wiki/AddressSanitizer) to locate the bugs. This feature requires a GCC or Clang compiler, and does not support Intel compiler.
For segmentation faults, ABACUS can be built with [Address Sanitizer](https://github.com/google/sanitizers/wiki/AddressSanitizer) to locate the bugs.

```bash
cmake -B build -DENABLE_ASAN=1
Expand Down
2 changes: 1 addition & 1 deletion docs/quick_start/easy_install.md
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ Here, 'build' is the path for building ABACUS; and '-D' is used for setting up s
- `BUILD_TESTING=OFF`: [Build unit tests](../advanced/install.md#build-unit-tests).
- `ENABLE_MPI=ON`: Enable MPI parallel compilation. If set to `OFF`, a serial version of ABACUS with PW basis only will be compiled. Currently serial version of ABACUS with LCAO basis is not supported yet, so `ENABLE_LCAO` will be automatically set to `OFF`.
- `ENABLE_COVERAGE=OFF`: Build ABACUS executable supporting [coverage analysis](../CONTRIBUTING.md#generating-code-coverage-report). This feature has a drastic impact on performance.
- `ENABLE_ASAN=OFF`: Build with Address Sanitizer. This feature would help detecting memory problems. Only supports GCC.
- `ENABLE_ASAN=OFF`: Build with Address Sanitizer. This feature would help detecting memory problems.
- `USE_ELPA=ON`: Use ELPA library in LCAO calculations. If this value is set to OFF, ABACUS can be compiled without ELPA library.

Here is an example:
Expand Down