Hello, I recently realized that I should be using "-march=native" flag for optimal performance of matrix-free codes. The application that I've been using works fine with just SSE2, but with AVX enabled I'm getting a segfault. Step-48 works fine, so I don't think it is an installation issue.
The function where it occurs is similar to the "local_apply" function in step 48: template <int dim> void getRHS(const MatrixFree<dim,double> &data, std::vector<dealii::parallel::distributed::Vector<double>*> &dst, const std::vector<dealii::parallel::distributed::Vector<double>*> & src, const std::pair<unsigned int,unsigned int> &cell_range) const{ //initialize FEEvaulation objects std::vector<typeScalar> scalar_vars; for (unsigned int i=0; i<num_var; i++){ typeScalar var(data, i); scalar_vars.push_back(var); } //loop over cells for (unsigned int cell=cell_range.first; cell<cell_range.second; ++cell){ // Initialize, read DOFs, and set evaulation flags scalar_vars[varInfoListRHS[i].index].reinit(cell); scalar_vars[varInfoListRHS[i].index].read_dof_values_plain(*src[ varInfoListRHS[i].global_var_index]); scalar_vars[varInfoListRHS[i].index].evaluate(need_value[i], need_gradient[i], need_hessian[i]); // <--- segfault happens here! } unsigned int num_q_points; num_q_points = scalar_vars[0].n_q_points; //loop over quadrature points for (unsigned int q=0; q<num_q_points; ++q){ (etc.) The segfault happens during the "evaluate" call. GDB tells me that it happens on line 5478 of /include/deal.II/matrix_free/fe_evaluation.h, in EvaluatorTensorProduct::apply: xp[i] = in[stride*i] - in[stride*(mm-1-i)]; Using the debugger to step through EvaluatorTensorProduct::apply, nothing seems obviously wrong. As expected, all of the vectorized arrays are four doubles long. The line above evaluates to xp[0]=in[0]-in[1]. Has anyone else had this issue? Does anyone have ideas what the problem could be, or what I should be looking for? Thanks! Steve System: Cluster running CentOS 7, with Intel Xeon E5-2670 processors, GCC v5.4.0 -- The deal.II project is located at http://www.dealii.org/ For mailing list/forum options, see https://groups.google.com/d/forum/dealii?hl=en --- You received this message because you are subscribed to the Google Groups "deal.II User Group" group. To unsubscribe from this group and stop receiving emails from it, send an email to dealii+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.