Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove UNI_OMP guards surrounding #pragma omp... #526

Merged
merged 4 commits into from
Dec 2, 2024

Commits on Dec 2, 2024

  1. Get number of CPU cores with std::thread

    Get the correct number of CPU cores when OpenMP is not used.
    IvanaGyro committed Dec 2, 2024
    Configuration menu
    Copy the full SHA
    7fbd8db View commit details
    Browse the repository at this point in the history
  2. Remove UNI_OMP guards surrounding #pragma omp...

    The compilers don't stop compiling if they cannot find the token
    following `#pragma`, so we don't have to use the compile definition to
    guard `#pragma omp...` statements.
    
    Remove `find_package(GTest)` from the root CMake file becuase we have
    used `include(GoogleTest)`, which is the new mechanism, to discover the
    tests.
    IvanaGyro committed Dec 2, 2024
    Configuration menu
    Copy the full SHA
    4e814d1 View commit details
    Browse the repository at this point in the history
  3. Remove -fopenmp flag when only enabling MKL

    We don't guard `#pragam omp...` statements now, so they take effects
    when `-fopenmp` compiler flag is set. `set()` function only affect the
    targets defined in the same scope (the same directory) and the
    subdirectories after the line of `set()`. Setting `-fopenmp` flag when
    the user only enable `USE_MKL` but not enable `USE_OMP` makes the user
    suprised.
    
    By default, MKL links to their own openmp (not gomp) for threading. The
    build process has no problem with no setting `-fopenmp` compiler flag
    when using MKL as the provider of BLAS and LAPACK. The above claim is
    true for the MKL version later then 2023.2.0. I am not sure if it is
    also true for the older version of MKL.
    IvanaGyro committed Dec 2, 2024
    Configuration menu
    Copy the full SHA
    9c0843b View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    672b7e9 View commit details
    Browse the repository at this point in the history