Hi Zhongyao, > + /* Scale integer vector body costs by the scalar/vector unit ratio. */ > + if (!costing_for_scalar () > + && loop_vinfo > + && where == vect_body > + && kind == vector_stmt > + && !is_reduction (stmt_info, node) > + && !(stmt_info && STMT_VINFO_GATHER_SCATTER_P (stmt_info)) > + && !(node && mat_gather_scatter_p (SLP_TREE_MEMORY_ACCESS_TYPE (node))) > + && vectype > + && VECTOR_INTEGER_TYPE_P (vectype) > + && scalar_units != 0 && vector_units != 0) > + stmt_cost = CEIL (stmt_cost * scalar_units, vector_units);
I guess this was meant to be something like stmt_cost * scalar_units / vector_units? Also, if we only use the ratio I guess we can expose the ratio itself as the tune parameter? Regards, Bohan
