I have a question that could seem very basic, but it is in a context where \"every CPU tick counts\" (this is a part of a larger algorithm that will be used on supercomputers).<
struct SomeValue { unsigned long long val; size_t index; bool operator<(const SomeValue& rhs)const { return val < rhs.val; } } #include std::vector somevec; //fill it... std::sort(somevec.begin(),somevec.end());