Is it possible to programmatically determine which will be faster; using remainder operator or a conditional?
<pre><code>wraparound_counter &amp; operator ++() {
    m_count = (m_count + 1) % upper_limit;
    /*if (upper == m_count)
        m_count = lower;
    ++m_count;*/
    return *this;
}
</code></pre>

<p>It is my understanding that on some systems using the remainder operator trick will be faster, but on others the conditional will be faster. Is there any way to figure out which will be faster at compile-time (or run-time)?</p>
