PKE unit test killed

I am not sure whether it is something worth to report or I am missing something. My machine is
“Linux ubuntu-ThinkPad-T490 5.15.0-78-generic #85-Ubuntu SMP x86_64 x86_64 x86_64 GNU/Linux”

By running “make testall”, the PKE unit test is killed as shown below.
Screenshot testall

Upon further investigation, I run ./pke_tests in the unitest directory and got the following output

I tried this more than once and even removed the build directory to recreate it. Moreover, I also performed “make clean” but the problem persist. Please excuse me if I missed something obvious.

Should I fix this pke unit test killing on my machine before playing with the pke code?

It could be an out-of-memory issue. How much RAM do you have on your machine?

@s_ali I agree with @Caesar that it might be a memory issue. Recreating the build directory and rebuilding the library is a start. If you are interested in the pke tests only, you can link the library like this:

$ make pke_tests
And only the pke tests will be built. Nothing else gets built: no unit tests for binfhe and core, no examples or extras.

After your build succeeds, you can run either all pke tests:

$ ./unitest/pke_tests

or one selected test (SCHEME_SWITCH_ARGMIN_01):

$ ./unitest/pke_tests --gtest_filter=“*UTCKKSRNS_SCHEMESWITCH.CKKSRNS/SCHEME_SWITCH_ARGMIN_01*”

or a number of tests (lets take all unit tests for scheme switching):

$ ./unitest/pke_tests --gtest_filter=“*UTCKKSRNS_SCHEMESWITCH*”

Some additional information could help us investigate this:

  • environment used: WSL, MinGW, Ubuntu
  • ubuntu version (if not MinGW) or MinGW revision
  • compiler and its version
  • how much RAM the laptop has and the processor

My machine is showing 8GiB.

Thanks for the detailed response! I haven’t attempted your suggestion and hopefully will try soon.

For g++ on my machine, I have
g++ (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0

For clang, I have
Ubuntu clang version 14.0.0-1ubuntu1.1

The processor I have
Intel® Core™ i5-8265U CPU @ 1.60GHz × 8

Please let me know if I missed something that you have asked for. Thanks!

Yes, the reason for the crash must be lack of memory. I also occasionally got crashes running tests on my laptop with 16GB of RAM.
So, the best would be to upgrade your computer’s RAM to 16GB or more, as the more is the better.
For now you can try to run smaller sets of unit tests.

This is to confirm that ./unittest/pke_tests --gtest_filter=“Name of Scheme” is working. Thanks to @Caesar and @dsuponitskiy-duality.