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

Add word size to help screen #2354

Merged
merged 5 commits into from
Nov 14, 2022
Merged

Add word size to help screen #2354

merged 5 commits into from
Nov 14, 2022

Conversation

mingodad
Copy link
Contributor

@mingodad mingodad commented Nov 3, 2022

No description provided.

@mingodad
Copy link
Contributor Author

mingodad commented Nov 3, 2022

Would be nice to also add the version of the build like souffle -h does:

----------------------------------------------------------------------------
Version: 2.3-137-gf2f974194
Word size: 32 bits
----------------------------------------------------------------------------

@quentin
Copy link
Member

quentin commented Nov 4, 2022

Yes, would also be nice to know the status of enabled/disabled features like sqlite, openmp:

souffle/CMakeLists.txt

Lines 77 to 87 in f2f9741

# --------------------------------------------------
# User options available from the command line/cache
# --------------------------------------------------
option(SOUFFLE_DOMAIN_64BIT "Enable/Disable 64-bit number values in Datalog tuples" OFF)
option(SOUFFLE_USE_CURSES "Enable/Disable ncurses-based provenance display" ON)
option(SOUFFLE_SWIG "Enable/Disable all SWIG builds" OFF)
option(SOUFFLE_SWIG_PYTHON "Enable/Disable Python SWIG" OFF)
option(SOUFFLE_SWIG_JAVA "Enable/Disable Java SWIG" OFF)
option(SOUFFLE_USE_ZLIB "Enable/Disable use of libz file compression" ON)
option(SOUFFLE_USE_SQLITE "Enable/Disable use sqlite IO" ON)
option(SOUFFLE_USE_OPENMP "Enable/Disable use of openmp if available" ON)

They end-up as C macros (target_compile_definitions of libsouffle):

souffle/src/CMakeLists.txt

Lines 255 to 305 in f2f9741

if (SOUFFLE_DOMAIN_64BIT)
target_compile_definitions(libsouffle PUBLIC RAM_DOMAIN_SIZE=64)
target_compile_definitions(compiled PUBLIC RAM_DOMAIN_SIZE=64)
endif()
if (SOUFFLE_USE_LIBFFI)
if (libffi_FOUND)
target_link_libraries(libsouffle PUBLIC libffi)
else ()
target_link_libraries(libsouffle PUBLIC LibFFI::LibFFI)
endif ()
endif ()
if (OPENMP_FOUND)
target_link_libraries(libsouffle PUBLIC OpenMP::OpenMP_CXX)
target_link_libraries(compiled PUBLIC OpenMP::OpenMP_CXX)
endif()
if (SOUFFLE_CUSTOM_GETOPTLONG)
target_compile_definitions(libsouffle
PUBLIC USE_CUSTOM_GETOPTLONG)
target_compile_definitions(compiled
PUBLIC USE_CUSTOM_GETOPTLONG)
endif()
if (SOUFFLE_USE_CURSES)
target_compile_definitions(libsouffle PUBLIC USE_NCURSES)
target_compile_definitions(compiled PUBLIC USE_NCURSES)
target_link_libraries(libsouffle PUBLIC Curses::NCurses)
target_link_libraries(compiled PUBLIC Curses::NCurses)
endif()
if (SOUFFLE_USE_ZLIB)
target_compile_definitions(libsouffle PUBLIC USE_LIBZ)
target_compile_definitions(compiled PUBLIC USE_LIBZ)
target_link_libraries(libsouffle PUBLIC ZLIB::ZLIB)
target_link_libraries(compiled PUBLIC ZLIB::ZLIB)
endif()
if (SOUFFLE_USE_SQLITE)
target_compile_definitions(libsouffle PUBLIC USE_SQLITE)
target_compile_definitions(compiled PUBLIC USE_SQLITE)
target_link_libraries(libsouffle PUBLIC SQLite::SQLite3)
target_link_libraries(compiled PUBLIC SQLite::SQLite3)
target_include_directories(compiled PUBLIC ${SQLite3_INCLUDE_DIRS})
endif()
if (SOUFFLE_USE_LIBFFI)
target_compile_definitions(libsouffle
PUBLIC USE_LIBFFI)
endif()

@codecov
Copy link

codecov bot commented Nov 4, 2022

Codecov Report

Merging #2354 (448f52f) into master (9abb420) will increase coverage by 0.01%.
The diff coverage is 68.50%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2354      +/-   ##
==========================================
+ Coverage   77.43%   77.45%   +0.01%     
==========================================
  Files         468      470       +2     
  Lines       29178    29335     +157     
==========================================
+ Hits        22594    22721     +127     
- Misses       6584     6614      +30     
Impacted Files Coverage Δ
src/include/souffle/SouffleInterface.h 88.99% <ø> (ø)
src/interpreter/Engine.h 100.00% <ø> (ø)
src/parser/ParserDriver.h 100.00% <ø> (ø)
src/synthesiser/Synthesiser.h 100.00% <ø> (ø)
src/reports/ErrorReport.cpp 12.50% <12.50%> (ø)
...ouffle/datastructure/ConcurrentInsertOnlyHashMap.h 88.80% <60.00%> (+5.87%) ⬆️
src/main.cpp 69.21% <60.00%> (-0.51%) ⬇️
src/interpreter/Engine.cpp 84.58% <72.00%> (+0.51%) ⬆️
src/synthesiser/Synthesiser.cpp 84.94% <82.75%> (+0.26%) ⬆️
...rc/include/souffle/datastructure/ConcurrentCache.h 92.85% <92.85%> (ø)
... and 14 more

@mingodad
Copy link
Contributor Author

mingodad commented Nov 4, 2022

Hello @quentin I just added the version to the help string, and also added some of the compiled options enabled in the souffle help screen see here #2353

Copy link
Member

@b-scholz b-scholz left a comment

Choose a reason for hiding this comment

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

Thanks for adding the feature!

@b-scholz b-scholz merged commit b8b1d69 into souffle-lang:master Nov 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants