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

Build issues #507

Open
wants to merge 46 commits into
base: development
Choose a base branch
from
Open

Build issues #507

wants to merge 46 commits into from

Conversation

LSchwiebert
Copy link
Collaborator

@LSchwiebert LSchwiebert commented Aug 14, 2023

This is a major reworking of the build process and some related changes to the core non-functional parts of the GOMC repository. The changes include:

  1. A major edit of the Readme file, including adding the DOI to each of the two references. And clarification of some of the text.
  2. Adding missing copyright notices or correcting ones that were outdated.
  3. Removal of a file that is no longer used (Endian.h) and removed the corresponding google test files.
  4. Changes to the build process to add flags to make it easier to customize the build and avoid conflicts among flags. For instance, you now use -t to run clang-tidy and use -a to build with address sanitizer. Also adds support for the Intel LLVM and Clang compilers.
  5. Major rewrite of the CMake process to include link-time optimization for builds and setting other optimization flags. Should result in better performance. These optimizations can be skipped by using the -n flag with metamake.sh. (Removed the link-time optimization flags because CMake doesn't seem to play well with the GPU LTO flags.)
  6. Cleaned up the headers to use consistent naming and end with an appropriate comment. Some retained information from other header files.

This is a necessary step before our next release, so please test the new build process carefully with available compilers.

Copy link
Collaborator

@GregorySchwing GregorySchwing left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Still need to clone and try, but why are you removing openMP flags? Is this no longer necessary, or did you move it?

find OpenMP and set it up

find_package(OpenMP)
if (OPENMP_FOUND)
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS}")
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${OpenMP_CXX_FLAGS}")
endif()

@LSchwiebert
Copy link
Collaborator Author

Thanks for taking a look. It's still there. I just needed to move it earlier in the CMakeLists.txt file so it was defined before I set the compiler flags. It looks like it was removed, but it's there starting on line 56.

I did turn off building with OpenMP if Address Sanitizer is being used, because they aren't compatible, but no one should be building with address sanitizer except to debug code or out of curiosity.

@LSchwiebert
Copy link
Collaborator Author

I've completed the patch, so it's ready for testing. I don't have access to a newer Intel compiler, so would like to know what happens when building the GPU code with the new ipcx compiler.

@LSchwiebert
Copy link
Collaborator Author

I removed the use of the new Intel LLVM compiler until CUDA supports it. This patch should be ready for testing and merging.

Most of the changes are cosmetic -- general code cleanup. For example, I updated the README file, added missing copyright notices to 3rd party software that we are using, standardized the #define for including header files, including fixing some that didn't match the filename, improve the build process, especially for the code, and removed unused files.

Once this is approved, we can proceed with the next GOMC release.

@LSchwiebert LSchwiebert linked an issue Aug 13, 2024 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve GOMC Build Process and Related Documentation
3 participants