Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Open
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
1 change: 1 addition & 0 deletions .github/workflows/Dockerfile.archlinux
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ RUN cmake -DCMAKE_BUILD_TYPE=$build_type \
-DSTORM_DEVELOPER=$developer \
-DSTORM_USE_CLN_EA=$cln_exact \
-DSTORM_USE_CLN_RF=$cln_ratfunc \
-DSTORM_COMPILE_WITH_ALL_SANITIZERS=$all_sanitizers \
$cmake_args ..

# Build Storm
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/Dockerfile.release
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ RUN mkdir -p /opt/storm/build \
-DSTORM_DEVELOPER=$developer \
-DSTORM_USE_CLN_EA=$cln_exact \
-DSTORM_USE_CLN_RF=$cln_ratfunc \
-DSTORM_COMPILE_WITH_ALL_SANITIZERS=$all_sanitizers \
$cmake_args .. \
&& make -j $no_threads \
&& make install -j $no_threads \
Expand Down
50 changes: 30 additions & 20 deletions .github/workflows/buildtest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ jobs:
name: Indepth Tests (${{ matrix.config.name }}, ${{ matrix.config.buildType }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
config:
- {name: "GMP exact; GMP rational functions; All dependencies",
Expand All @@ -36,8 +37,8 @@ jobs:
Developer: "ON",
ClnExact: "OFF",
ClnRatfunc: "OFF",
AllSanitizers: "ON",
cmakeArgs: ""
AllSanitizers: "OFF",
cmakeArgs: "-DSTORM_WARNING_AS_ERROR=ON"
}
- {name: "CLN exact; GMP rational functions; All dependencies",
baseImg: "storm-dependencies:latest",
Expand All @@ -53,8 +54,8 @@ jobs:
Developer: "ON",
ClnExact: "ON",
ClnRatfunc: "OFF",
AllSanitizers: "ON",
cmakeArgs: ""
AllSanitizers: "OFF",
cmakeArgs: "-DSTORM_WARNING_AS_ERROR=ON"
}
- {name: "CLN exact; CLN rational functions; All dependencies",
baseImg: "storm-dependencies:latest",
Expand All @@ -70,8 +71,8 @@ jobs:
Developer: "ON",
ClnExact: "ON",
ClnRatfunc: "ON",
AllSanitizers: "ON",
cmakeArgs: ""
AllSanitizers: "OFF",
cmakeArgs: "-DSTORM_WARNING_AS_ERROR=ON"
}
- {name: "GMP exact; CLN rational functions; No dependencies",
baseImg: "storm-dependencies:latest",
Expand All @@ -87,8 +88,8 @@ jobs:
Developer: "ON",
ClnExact: "OFF",
ClnRatfunc: "ON",
AllSanitizers: "ON",
cmakeArgs: ""
AllSanitizers: "OFF",
cmakeArgs: "-DSTORM_WARNING_AS_ERROR=ON"
}
- {name: "Minimal dependencies (without CLN)",
baseImg: "storm-basesystem:minimal_dependencies",
Expand All @@ -104,8 +105,8 @@ jobs:
Developer: "ON",
ClnExact: "OFF",
ClnRatfunc: "OFF",
AllSanitizers: "ON",
cmakeArgs: ""
AllSanitizers: "OFF",
cmakeArgs: "-DSTORM_WARNING_AS_ERROR=ON"
}
steps:
- name: Git clone
Expand Down Expand Up @@ -140,7 +141,9 @@ jobs:
buildType: ${{ matrix.config.buildType }}
docker: true
- name: Run tests
run: docker exec ci bash -c "cd /opt/storm/build; ASAN_OPTIONS=detect_leaks=0,detect_odr_violation=0 ctest test --output-on-failure"
# Disabled sanitizer checks for now
#run: docker exec ci bash -c "cd /opt/storm/build; ASAN_OPTIONS=detect_leaks=0,detect_odr_violation=0 ctest test --output-on-failure"
run: docker exec ci bash -c "cd /opt/storm/build; ctest test --output-on-failure"
- name: Build starter-project
uses: ./.github/actions/starter-project-action
with:
Expand Down Expand Up @@ -168,29 +171,30 @@ jobs:
name: Compiler Tests (${{ matrix.config.name }} on ${{ matrix.config.distro }}, ${{ matrix.config.buildType }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
config:
- {name: "GCC",
buildType: "Debug",
disable_gmm: "ON", # TOOD: enable again if GMM was fixed
Developer: "ON",
cmakeArgs: "-DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++",
cmakeArgs: "-DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DSTORM_WARNING_AS_ERROR=ON",
packages: "",
distro: "archlinux"
}
- {name: "Clang",
buildType: "Debug",
disable_gmm: "ON", # TOOD: enable again if GMM was fixed
Developer: "ON",
cmakeArgs: "-DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++",
cmakeArgs: "-DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DSTORM_WARNING_AS_ERROR=ON",
packages: "clang",
distro: "archlinux"
}
- { name: "musl",
buildType: "Debug",
disable_gmm: "ON", # TOOD: enable again if GMM was fixed
Developer: "ON",
cmakeArgs: "-DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++",
cmakeArgs: "-DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DSTORM_WARNING_AS_ERROR=ON",
packages: "",
distro: "alpine"
}
Expand Down Expand Up @@ -246,8 +250,9 @@ jobs:
name: Linux Tests (${{ matrix.distro }}, ${{ matrix.buildType }}) on ${{ matrix.runner }}
runs-on: ${{ matrix.runner }}
strategy:
fail-fast: false
matrix:
distro: ["debian-12", "ubuntu-24.04"]
distro: ["debian-12", "ubuntu-24.04", "debian-13"]
buildType: ["Release"]
runner: [ubuntu-latest, ubuntu-24.04-arm]
steps:
Expand All @@ -259,8 +264,9 @@ jobs:
--build-arg BASE_IMAGE=movesrwth/storm-basesystem:${{ matrix.distro }} \
--build-arg build_type="${{ matrix.buildType }}" \
--build-arg carl_tag="master" \
--build-arg no_threads=${NR_JOBS}
# Omitting arguments developer, disable_*, cln_exact, cln_ratfunc, all_sanitizers, cmake_args
--build-arg no_threads=${NR_JOBS} \
--build-arg cmake_args="-DSTORM_WARNING_AS_ERROR=ON"
# Omitting arguments developer, disable_*, cln_exact, cln_ratfunc, all_sanitizers
- name: Run Docker
run: docker run -d -it --name ci movesrwth/storm:ci
- name: Run storm
Expand Down Expand Up @@ -296,6 +302,7 @@ jobs:
macTests:
name: macOS Tests (${{ matrix.config.name }}, ${{ matrix.config.buildType }})
strategy:
fail-fast: false
matrix:
config:

Expand Down Expand Up @@ -330,7 +337,7 @@ jobs:
run: |
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE="${{ matrix.config.buildType }}" -DSTORM_CARL_GIT_TAG="master"
cmake .. -DCMAKE_BUILD_TYPE="${{ matrix.config.buildType }}" -DSTORM_CARL_GIT_TAG="master" -DSTORM_WARNING_AS_ERROR=ON
- name: Build storm
working-directory: ./build
run: make -j ${NR_JOBS}
Expand Down Expand Up @@ -371,17 +378,20 @@ jobs:
name: Test and Deploy (${{ matrix.buildType.name }})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
buildType:
- {name: "Debug",
dockerTag: "ci-debug",
baseImg: "storm-dependencies:latest",
Developer: "ON"
Developer: "ON",
cmakeArgs: "-DSTORM_WARNING_AS_ERROR=ON"
}
- {name: "Release",
dockerTag: "ci",
baseImg: "storm-dependencies:latest",
Developer: "OFF"
Developer: "OFF",
cmakeArgs: "-DSTORM_WARNING_AS_ERROR=ON"
}
steps:
- name: Git clone
Expand Down
4 changes: 4 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ set(CMAKE_CXX_STANDARD 20)
## Compilation options.
option(STORM_DEVELOPER "Sets whether the development mode is used." OFF)
option(STORM_ALLWARNINGS "Compile with even more warnings" OFF)
option(STORM_WARNING_AS_ERROR "Sets whether compile warnings are treated as errors." OFF)
MARK_AS_ADVANCED(STORM_WARNING_AS_ERROR)
option(STORM_USE_LTO "Sets whether link-time optimizations are enabled." ON)
MARK_AS_ADVANCED(STORM_USE_LTO)
option(STORM_USE_THIN_LTO "Sets whether thin link-time optimizations are enabled (faster compile times than normal LTO)." OFF)
Expand Down Expand Up @@ -145,12 +147,14 @@ if (STORM_DEVELOPER)
set(STORM_DEBUG_CUDD ON)
set(STORM_DEBUG_SPOT ON)
set(STORM_DEBUG_SYLVAN ON)
set(STORM_WARNING_AS_ERROR ON)
else()
set(STORM_LOG_DISABLE_DEBUG ON)
if (NOT CMAKE_BUILD_TYPE)
set(CMAKE_BUILD_TYPE "RELEASE")
endif()
endif()
set(CMAKE_COMPILE_WARNING_AS_ERROR ${STORM_WARNING_AS_ERROR})

message(STATUS "Storm - Building ${CMAKE_BUILD_TYPE} version.")

Expand Down
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ RUN cmake -DCMAKE_BUILD_TYPE=$build_type \
-DSTORM_DEVELOPER=$developer \
-DSTORM_USE_CLN_EA=$cln_exact \
-DSTORM_USE_CLN_RF=$cln_ratfunc \
-DSTORM_COMPILE_WITH_ALL_SANITIZERS=$all_sanitizers \
$cmake_args ..

# Build Storm
Expand Down
14 changes: 13 additions & 1 deletion resources/3rdparty/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,10 @@ ExternalProject_Add(
)
add_library(eigen3storm INTERFACE) # Not imported, we are in control of the sources.
add_dependencies(eigen3storm eigen_src)
if(STORM_WARNING_AS_ERROR AND STORM_COMPILER_GCC)
# Ignore warning in Eigen
target_compile_options(eigen3storm INTERFACE -Wno-class-memaccess)
endif()
# note that we include without StormEigen
target_include_directories(eigen3storm INTERFACE
$<BUILD_INTERFACE:${STORM_3RDPARTY_BINARY_DIR}>
Expand Down Expand Up @@ -553,7 +557,11 @@ SET(CMAKE_POSITION_INDEPENDENT_CODE ON) # Likely only necessary on linux
SET(STORM_SOURCE_DIR "${PROJECT_SOURCE_DIR}/src/") # TODO this is ugly.
SET(STORM_BINARY_INCLUDE_DIR "${PROJECT_BINARY_DIR}/include/") #TODO this is ugly.
FETCHCONTENT_MAKEAVAILABLE(sylvanfetch)

if(STORM_WARNING_AS_ERROR)
# Ignore explicit warning in storm_wrapper.cpp
target_compile_options(sylvan PRIVATE -Wno-cpp)
endif()
add_dependencies(sylvan lib_carl)
add_dependencies(storm_resources sylvan)
list(APPEND STORM_FETCHED_TARGETS sylvan)

Expand All @@ -565,6 +573,10 @@ list(APPEND STORM_FETCHED_TARGETS sylvan)

if(STORM_BUILD_TESTS)
set(GTEST_VERSION "1.17.0")
# Workaround for googletest bug with char conversions, see https://github.com/google/googletest/issues/4762
if (STORM_COMPILER_CLANG AND CMAKE_CXX_COMPILER_VERSION VERSION_GREATER_EQUAL 21.0)
add_compile_options(-Wno-character-conversion)
endif()
FETCHCONTENT_DECLARE(
googletest
URL https://github.com/google/googletest/archive/refs/tags/v${GTEST_VERSION}.zip
Expand Down
5 changes: 5 additions & 0 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,11 @@ else()
add_compile_options($<$<CONFIG:RELEASE>:-fomit-frame-pointer>)
endif()

if(STORM_WARNING_AS_ERROR)
# Reenable soon
add_compile_options(-Wno-unused-parameter)
endif()


add_custom_target(binaries)

Expand Down
5 changes: 2 additions & 3 deletions src/storm/adapters/ExprttkAdapter.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,12 @@

#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wunused-variable"

#pragma GCC diagnostic push
#pragma clang diagnostic ignored "-Wunknown-warning-option"
#pragma clang diagnostic ignored "-Wunnecessary-virtual-specifier"

// exprtk should be case sensitive in our case.
#define exprtk_disable_caseinsensitivity

#include "exprtk.hpp"

#pragma GCC diagnostic pop
#pragma clang diagnostic pop
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ struct product_state_hash {
return spot::wang32_hash(s.first ^ spot::wang32_hash(s.second));
}
#else
size_t operator()(product_state s) const {
size_t operator()(product_state) const {
STORM_LOG_THROW(false, storm::exceptions::NotSupportedException, "Storm is compiled without Spot support.");
}
#endif
Expand Down
12 changes: 3 additions & 9 deletions src/storm/storage/dd/DdManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -180,19 +180,13 @@ Bdd<LibraryType> DdManager<LibraryType>::getIdentity(storm::expressions::Variabl
return result;
}

#if defined(__clang__)
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Winfinite-recursion"
#endif

#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Winfinite-recursion"
template<DdType LibraryType>
Bdd<LibraryType> DdManager<LibraryType>::getCube(storm::expressions::Variable const& variable) const {
return getCube({variable});
}

#if defined(__clang__)
#pragma clang diagnostic pop
#endif
#pragma GCC diagnostic pop

template<DdType LibraryType>
Bdd<LibraryType> DdManager<LibraryType>::getCube(std::set<storm::expressions::Variable> const& variables) const {
Expand Down
Loading