-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Major Features + This version supports being compiled with a C++11 compiler. Pass `-DLIBPRESSIO_CXX_VERSION=11` to cmake to use this version. Added backwards compatibility headers for a variety of newer c++ features. For systems without c++17, Boost is required. + BREAKING CHANGE Refactored constexpr inline variables to constexpr functions to allow them to be compiled in c++11. Minor Features + Added additional version variables to inspect the configured options
- Loading branch information
Showing
33 changed files
with
534 additions
and
244 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#include <type_traits> | ||
int main(int argc, char *argv[]) | ||
{ | ||
|
||
return std::conjunction<std::is_same<int,int>, std::is_same<float,float>>::value; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#include <utility> | ||
int main() { | ||
int i = 1; | ||
int j = 2; | ||
j = std::exchange(i,0); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#include <memory> | ||
int main(int argc, char *argv[]) | ||
{ | ||
auto i = std::make_unique<int>(3); | ||
return *i; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
#include <functional> | ||
|
||
int main(int argc, char *argv[]) | ||
{ | ||
return std::multiplies<>{}(1, 2); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
#include <optional> | ||
|
||
int main(int argc, char *argv[]) | ||
{ | ||
std::optional<int> o = 3; | ||
return *o; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#include <vector> | ||
#include <iterator> | ||
|
||
int main(int argc, char *argv[]) | ||
{ | ||
int sum; | ||
std::vector<int> foo{1,2,2}; | ||
for (auto it = std::rbegin(foo); it != std::rend(foo); ++it) { | ||
sum+=*it; | ||
} | ||
return sum; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#include <variant> | ||
|
||
int main(int argc, char *argv[]) | ||
{ | ||
std::variant<std::monostate, int, float> v; | ||
v = 1.2f; | ||
v = 1; | ||
return std::get<int>(v); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
FROM centos:7 as builder | ||
RUN yum install -y epel-release && \ | ||
yum install -y git swig3 cmake3 gcc-c++ zlib-devel libzstd-devel ninja-build hdf5-devel python3-devel python3-numpy blosc-devel boost-devel && \ | ||
yum clean all | ||
RUN git clone https://github.com/LLNL/zfp /src/zfp && \ | ||
git clone https://github.com/disheng222/sz /src/sz && \ | ||
git clone https://github.com/CODARcode/MGARD /src/mgard && \ | ||
git clone https://github.com/CODARcode/libpressio /src/libpressio && \ | ||
mkdir -p /src/autotuning && \ | ||
cd /src/sz && \ | ||
mkdir build && \ | ||
cd build && \ | ||
cmake3 .. -DCMAKE_INSTALL_PREFIX=/usr -G Ninja && \ | ||
cmake3 --build . && \ | ||
ninja-build install && \ | ||
cd /src/zfp && \ | ||
mkdir build && \ | ||
cd build && \ | ||
cmake3 .. -DCMAKE_INSTALL_PREFIX=/usr -DBUILD_TESTING=OFF -G Ninja && \ | ||
cmake3 --build . && \ | ||
ninja-build install && \ | ||
cd /src/mgard && \ | ||
mkdir build && \ | ||
cd build && \ | ||
cmake3 .. -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_INSTALL_LIBDIR=lib64 -DBUILD_TESTING=OFF -G Ninja && \ | ||
cmake3 --build . && \ | ||
ninja-build install && \ | ||
cd /src/libpressio && \ | ||
rm -rf build && \ | ||
mkdir build && \ | ||
cd build && \ | ||
cmake3 .. -DCMAKE_INSTALL_PREFIX=/usr -DBUILD_TESTS=ON -DLIBPRESSIO_HAS_MAGICK=OFF -DLIBPRESSIO_HAS_MGARD=ON -DBUILD_PYTHON_WRAPPER=ON -G Ninja && \ | ||
cmake3 --build . && \ | ||
CTEST_OUTPUT_ON_FAILURE=1 ctest3 . && \ | ||
ninja-build install | ||
|
||
FROM centos:7 | ||
RUN yum install -y epel-release && \ | ||
yum install -y zlib hdf5 libzstd fftw python3-numpy blosc boost\ | ||
&& \ | ||
yum clean all | ||
COPY --from=builder /usr/lib64/libSZ.so* \ | ||
/usr/lib64/liblibpressio.so* \ | ||
/usr/lib64/libzfp.so* \ | ||
/usr/lib64/libmgard.so* \ | ||
/usr/lib64/ | ||
COPY --from=builder /usr/include/libpressio \ | ||
/usr/include/sz \ | ||
/usr/include/zfp* \ | ||
/usr/include/mgard* \ | ||
/usr/include/ | ||
COPY --from=builder /usr/bin/sz /usr/bin/ | ||
COPY --from=builder /usr/lib/python3.6/site-packages/*pressio* /usr/lib64/python3.6/site-packages/ | ||
|
Oops, something went wrong.