Hello everyone,
I am trying to profile the examples provided in the openFHE repository, using the gprof progiler. I am adding in the CMakeList.txt file the following:
set( CMAKE_CXX_FLAGS “${CMAKE_CXX_FLAGS} -pg”)
set( CMAKE_EXE_LINKER_FLAGS “${CMAKE_EXE_LINKER_FLAGS} -pg”)
set( CMAKE_SHARED_LINKER_FLAGS “${CMAKE_SHARED_LINKER_FLAGS} -pg”)’
Then, the process I would follow would be:
- Create a build directory and cd build
- cmake …
- make -j 8
- run an example as ./bin/examples/pke/simple-integers
- gprof ./bin/examples/pke/simple-integers
However, at step 3, I am getting the following errors (output of terminal provided):
– demoData folder already exists
[ 0%] Built target third-party
[ 7%] Built target benchmark
[ 25%] Built target coreobj
[ 25%] Linking CXX shared library …/…/lib/libOPENFHEcore.so
clang: error: argument unused during compilation: ‘-pg’ [-Werror,-Wunused-command-line-argument]
clang: error: argument unused during compilation: ‘-pg’ [-Werror,-Wunused-command-line-argument]
make[2]: *** [src/core/CMakeFiles/OPENFHEcore.dir/build.make:179: lib/libOPENFHEcore.so.1.0.2] Error 1
make[1]: *** [CMakeFiles/Makefile2:634: src/core/CMakeFiles/OPENFHEcore.dir/all] Error 2
make: *** [Makefile:130: all] Error 2
Could anyone help me with that?
The goal of this would be to get a better understanding of the call graph for high level FHE functions such as EvalAdd, EvalMult, MakePackedPlaintext etc.
Thank you in advance