Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Intel_C_17
Beginner
103 Views

Can compile on CENTOS 7 but not on Fedora 22

 

Hello,

Hello,

I have a code that I can compile and run under Centos 7 (parallel studio XE 2016 with odeint-v2 from boost 1.59.0). However, the same code gives me tons of error messages under fedora 22.

void GABAB::compCumSum(double* out,double T_in,double dur)
{
    double dt=0.01;
    int NStep=(int) floor(dur/dt);

    int tmpstartInd=startInd;

    startInd=0;

    StateVector x(2 * NState);

    compInitState(x, 0.0, 0.0);

    for (int ii = 0; ii < NState; ii++)
        x[ ii + NState ] = 0.0;

    for (int ii = 0; ii < NState; ii++)
        out[ii] = x[ii];

    setInput(T_in, T_in);

    cumsum_GABAB tmp(*this);

    size_t steps = integrate_adaptive( tmp , x , 0.0 , dur , dt );

    for (int ii = 0; ii < NState; ii++)
        out[ii] = x[ii + NState];

    startInd=tmpstartInd;
}

StateVector is defined in a separate header as:

typedef boost::numeric::ublas::vector< double > StateVector;


When I compile this code under fedora 22, I have the following errors:

icpc -DMKL_ILP64 -il64 -qopenmp -restrict -O2 -std=c++11 -D__TBB_MIC_OFFLOAD=0 -I/opt/intel/mkl/include -I/opt/applications/boost/include  -D__ONLYONMIC=0  -DCType=1 -w -c GABAB.cpp -o ../bin/obj/GABAB.o
/usr/include/c++/5.1.1/functional(78): error: class "boost::numeric::odeint::controlled_runge_kutta<boost::numeric::odeint::runge_kutta_dopri5<StateVector, double, StateVector, double, boost::numeric::odeint::vector_space_algebra, boost::numeric::odeint::default_operations, boost::numeric::odeint::initially_resizer>, boost::numeric::odeint::default_error_checker<double, boost::numeric::odeint::vector_space_algebra, boost::numeric::odeint::default_operations>,
          boost::numeric::odeint::initially_resizer, boost::numeric::odeint::explicit_error_stepper_fsal_tag>" has no member "result_type"
      { typedef typename _Functor::result_type result_type; };
                                   ^
          detected during:
           

(I cut the output of the compilation to have a "short" topic. If needed, I can provide the full output)

Again, the same code, with the same installation process (of boost and intel cluster studio) works fine under centos 7. Finally, if I remove the -std=c++11 flag, I do not have any error. This is an OK workaround for now but I would like to go back to c++11. I first posted a message on the ODEINT GitHub forum and apparently this could be related to the compiler.

Any clue to what could generate these errors?

Thank you very much,

Pierre

0 Kudos
2 Replies
Intel_C_17
Beginner
103 Views

I realized that this is a known issue with c++11 headers.

I'll update the post when the fix will be available...

Thanks,

 

Pierre

Kittur_G_Intel
Employee
103 Views

Yes, thanks Pierre for the update. -Kittur

Reply