Error compiling parsec 2.1 benchmark on Debian 9

1,421 views
Skip to first unread message

Quintin Fettes

unread,
Oct 1, 2018, 7:53:29 PM10/1/18
to Sniper simulator
I'm getting the following error when attempting to make the benchmarks

In file included from /home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/WorkerGroup.h:20:0,
                 
from /home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/WorkerGroup.cpp:17:
/home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/Mutex.h:86:5: error: looser throw specifier for 'virtual threads::Mutex::~Mutex() throw (threads::MutexException)'
     
~Mutex() throw(MutexException);
     
^
In file included from /home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/Mutex.h:29:0,
                 
from /home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/WorkerGroup.h:20,
                 
from /home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/WorkerGroup.cpp:17:
/home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/LockTypes.h:22:13: error:   overriding 'virtual threads::LockType::~LockType() noexcept'
     
virtual ~LockType() {};
             
^
In file included from /home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/WorkerGroup.cpp:17:0:
/home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/WorkerGroup.h:88:5: error: looser throw specifier for 'virtual threads::WorkerGroup::~WorkerGroup() throw (threads::CondException, threads::MutexException)'
     
~WorkerGroup();
     
^
In file included from /home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/WorkerGroup.h:18:0,
                 
from /home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/WorkerGroup.cpp:17:
/home/qfettes/benchmarks/parsec/parsec-2.1/./pkgs/apps/bodytrack/src/TrackingBenchmark/threads/Thread.h:31:13: error:   overriding 'virtual threads::Runnable::~Runnable() noexcept'
     
virtual ~Runnable() {};

make[5]: *** [WorkerGroup.lo] Error 1
Makefile:277: recipe for target 'WorkerGroup.lo' failed
make
[5]: Leaving directory '/home/qfettes/benchmarks/parsec/parsec-2.1/pkgs/apps/bodytrack/obj/amd64-linux.gcc-sniper/TrackingBenchmark/threads'
make
[4]: *** [all-recursive] Error 1
Makefile:371: recipe for target 'all-recursive' failed
make
[4]: Leaving directory '/home/qfettes/benchmarks/parsec/parsec-2.1/pkgs/apps/bodytrack/obj/amd64-linux.gcc-sniper/TrackingBenchmark'
make
[3]: *** [all-recursive] Error 1
Makefile:253: recipe for target 'all-recursive' failed
make
[3]: Leaving directory '/home/qfettes/benchmarks/parsec/parsec-2.1/pkgs/apps/bodytrack/obj/amd64-linux.gcc-sniper'
make
[2]: *** [all] Error 2
Makefile:182: recipe for target 'all' failed
make
[2]: Leaving directory '/home/qfettes/benchmarks/parsec/parsec-2.1/pkgs/apps/bodytrack/obj/amd64-linux.gcc-sniper'
[PARSEC] Error: 'env CXXFLAGS=-O3 -funroll-loops -fprefetch-loop-arrays -fpermissive -fno-exceptions -static-libgcc -Wl,--hash-style=both,--as-needed -DPARSEC_VERSION=2.1 -DENABLE_PARSEC_HOOKS -I/home/qfettes/benchmarks/parsec/parsec-2.1/pkgs/libs/hooks/inst/amd64-linux.gcc-sniper/include -I/home/qfettes/benchmarks/tools/hooks -I/home/qfettes/sniper-7.0/include -fexceptions /usr/bin/make' failed.
Makefile:30: recipe for target 'parsec-build' failed
make
[1]: *** [parsec-build] Error 1
make
[1]: Leaving directory '/home/qfettes/benchmarks/parsec'
Makefile:12: recipe for target 'all' failed
make
: *** [all] Error 2


Quintin Fettes

unread,
Oct 1, 2018, 9:53:30 PM10/1/18
to Sniper simulator
I was able to fix the issue by adding the flag -std=gnu++98 to the CXX variable in benchmarks/parsec/parsec-2.1/config/gcc-sniper.bldconf

-CXX="${HOOKS_CXX}"
+CXX="${HOOKS_CXX} -std=gnu++98"

Debian 9 comes with gcc 6.3 by default, which uses c++14 (201402) as its standard by default according to my test and breaks the compilation. Hope this helps someone in the future!

ahmad sedigh

unread,
Oct 23, 2019, 9:47:10 AM10/23/19
to Sniper simulator
Hi Quintin,
That is brilliant... 
Thank you very much.
 Also after this error i got multiple errors with "HUGE" and i replaced it with HUGE_VAL 
BUT now i get this error:
/home/ahmad/sniper-latest/sniper-7.2/benchmarks/parsec/parsec-2.1/pkgs/apps/raytrace/obj/amd64-linux.gcc-sniper/RTTL/test/TestRTVec/TestRTVec.cxx:121:24: error: ‘int pow(double, int)’ conflicts with a previous declaration int pow(double a, int n) {
/home/ahmad/sniper-latest/sniper-7.2/benchmarks/parsec/parsec-2.1/pkgs/apps/raytrace/obj/amd64-linux.gcc-sniper/RTTL/test/TestRTVec/TestRTVec.cxx:143:39: error: call of overloaded ‘pow(double, int)’ is ambiguous   if (v.minIndex() != 1 || dv != pow(convert<DataType>(11), N)) {

What is your recommendation??
Thanks in advance.

.

ahmad sedigh

unread,
Oct 24, 2019, 8:25:31 PM10/24/19
to Sniper simulator
I solved that by changing -std=gnu++98 to 17 and it went well until again i got another error about "throw" again and i again changed it back and it went well again.
I think because of declaration support of pow() function we should use gnu17 or gnu11 but they dont support "throw" so we should swing back and forth between 98 and 11 or 98 and 17 . 

Quintin Fettes

unread,
Oct 25, 2019, 10:34:54 AM10/25/19
to Sniper simulator
Ahmad, 

I'm unable to offer very specific help because I didn't run into errors with pow() myself. It's likely that you have a different version of gcc than I did. 

One possible solution is using a find function to find all calls to pow(double, int), and cast the second argument as a double. 
Another solution could be to simply comment out that function at benchmarks/parsec/parsec-2.1/pkgs/apps/raytrace/obj/amd64-linux.gcc-sniper/RTTL/test/TestRTVec/TestRTVec.cxx:121 and casting the second argument of all calls to pow as double.

I'd see if you can get it working like this; I think parsec 2.1 predates c++17 and c++11, so while they could solve some problems, it's likely a coincidence that using those versions of the compiler help. Of course, this advice is pure speculation; I do not have the same issues you have.

ahmad sedigh

unread,
Oct 26, 2019, 4:18:44 AM10/26/19
to Sniper simulator
Hi Quintin
Thank you very much.
Your posts in this group have been a great help for me...
Regards

ahmad sedigh

unread,
Oct 26, 2019, 8:32:35 AM10/26/19
to Sniper simulator
Hi Quintin
Would please give me your opinion about this ERROR in running this command in benchmarks root
./run-sniper -p splash2-fft -i test -n 4 -c gainestown
E: Unable to load /home/ahmad/sniper-latest/sniper-7.2/sift/recorder/obj-intel64/sift_recorder: dlopen failed: cannot locate symbol "_ZnwmSt11align_val_t" referenced by "/home/ahmad/sniper-latest/sniper-7.2/sift/recorder/obj-intel64/sift_recorder"...
[SNIPER] WARNING: No SIFT connections made yet. Waiting...
[SNIPER] ERROR: Could not establish SIFT connection, aborting! Check benchmark-app*.log for errors.
also i have reported this issue in verifying sniper first compilation by running test/fft here:
https://groups.google.com/d/msg/snipersim/xdN4-CNWrnk/bZjpeM0DDAAJ
Message has been deleted

Zilmarij Iqbal

unread,
Jun 20, 2021, 12:52:00 AM6/20/21
to Sniper simulator
Hi,

I am also running into the same error, and modifying the corresponding file by replacing HUGE by HUGE_VAL does not seem to help. In fact, the file is being reset to its original contents after doing a make (HUGE_VAL is reset to HUGE). I am using Ubuntu 18.04, gcc 7.5.0.

Any help would be appreciated.



Regards,
Zilmarij Iqbal
MS(R) Scholar
IIT Delhi

Shubhang Pandey ee19s057

unread,
Jun 20, 2021, 1:25:39 AM6/20/21
to Sniper simulator
Hey Iqbal 

I hope it helps.

Zilmarij Iqbal

unread,
Jun 20, 2021, 3:39:30 AM6/20/21
to Sniper simulator

Hi Shubhang,

Thank you for your response. I followed the steps till Step5, then did make and encountered the following error (couple of these):

benchmarks/parsec/parsec-2.1/./pkgs/apps/vips/src/libsrcCC/vipsc++.cc:5483:37: error: ISO C++1z does not allow dynamic exception specifications
 VImage VImage::notequal( double c ) throw( VError )


I also tried using gnu++11/17/14, all showed the same error.
Any help forward would be appreciated.

Regards,
Zilmarij Iqbal
MS(R) Scholar
IIT Delhi

Reply all
Reply to author
Forward
0 new messages