1
1
mirror of https://github.com/henrydcase/pqc.git synced 2024-11-22 15:39:07 +00:00
Commit Graph

6 Commits

Author SHA1 Message Date
5911a1ee30 sphincs benches 2022-02-10 11:20:34 -08:00
bb3fe16bd5 Memory Sanitizer build 2021-06-23 07:12:29 +01:00
2ce8a28e41 fix build 2021-06-22 01:14:17 +01:00
d9344d6956 improves makefile 2021-06-22 01:10:08 +01:00
77ca982b4c Redesign CMakeLists.txt for MemorySanitizer
The test programs use googletest and google-benchmark
libraries in order to ensure right level of optimizations
and proper unit testing.
Those two libraries are written in C++ and they
use C++ standard library.

If you want MemorySanitizer to work properly and not
produce any false positives, you must ensure that all
the code in your program and in libraries it uses is
instrumented. That includes C++ standard library.

(see here: https://github.com/google/sanitizers/wiki/MemorySanitizerLibcxxHowTo)

With this change, the Memory Sanitizer build (enabled
by -DMEMSAN=1) will also build MSan-instrumented libc++
from LLVM and will use it as a standard C++ library
when building unit tests and benchmarks.

In particular what I do is this:
1. Clone LLVM project and build libcxx and libcxxabi with
   MSan enabled
2. Build GTEST and GBENCH with -fsanitize=memory and -stdlib=libc++.
   Additionally link against -lc++abi
3. Then use this special version of libc++ and GTEST/GBENCH
   in order to build final binaries containing unit/benchmark tests

The actuall tests with memory sanitizer are disabled, as
I'm getting some errors which need to be investigated first.

Additionally I've splitted single build into multiple, for
release,debug,clang,gcc and AddressSanitizer.

On unrelated note, I've also added flags to ignore some errors
which I'm getting when using newer GCC (see GH#10 GH#11).
2021-06-20 21:34:58 +01:00
56629c53f9 add benchmarking framework 2021-04-22 21:41:46 +01:00