Skip to content

Commit

Permalink
more updates to build on ginsburg.
Browse files Browse the repository at this point in the history
  • Loading branch information
ejpaul committed Jan 24, 2025
1 parent fd1d779 commit 5e7221e
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 140 deletions.
13 changes: 10 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,13 @@ configure_file(config.h.in config.h)
include_directories(${CMAKE_CURRENT_BINARY_DIR})

include(CheckCXXCompilerFlag)
if(DEFINED ENV{CI})
message(STATUS "CI environment detected. Set compilation flags targetting Westmere microarch.")
set(CMAKE_CXX_FLAGS "-O3 -march=znver3")
IF(DEFINED ENV{CI})
if (APPLE)
set(CMAKE_CXX_FLAGS "-O3")
else()
message(STATUS "CI environment detected. Set compilation flags targetting Westmere microarch.")
set(CMAKE_CXX_FLAGS "-O3 -march=westmere")
endif()
elseif(DEFINED ENV{CONDA_BUILD})
message(STATUS "conda build environment detected. Let conda set compilation flags accordingly.")
# set(CMAKE_CXX_FLAGS "-O3 -march=ivybridge -mfma -ffp-contract=fast")
Expand All @@ -64,6 +68,9 @@ else()
set(CMAKE_CXX_FLAGS "-O3 -ffp-contract=fast")
endif()
endif()
# Ensure all code used from Eigen does not have LGPL license:
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DEIGEN_MPL2_ONLY")
message(STATUS "CMAKE_CXX_FLAGS are ${CMAKE_CXX_FLAGS}")

if(DEFINED ENV{CONDA_PREFIX})
include_directories($ENV{CONDA_PREFIX}/include)
Expand Down
136 changes: 0 additions & 136 deletions src/simsoptpp/tracing_helpers.cpp

This file was deleted.

4 changes: 3 additions & 1 deletion src/simsoptpp/tracing_helpers.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
#include <array>
#include <vector>
#include <tuple>
#include <memory>
#include <functional>

using std::array;
using std::shared_ptr;
Expand Down Expand Up @@ -229,4 +231,4 @@ bool check_stopping_criteria(RHS rhs, typename RHS::State y, int iter, vector<ar
}
}
return stop;
}
}

0 comments on commit 5e7221e

Please sign in to comment.