How can a const expr be evaluated so fast : <p>I have been trying out const expressions which are evaluated at compile time. 
But I played with an example that seems incredibly fast when executed at compile time.</p>

<pre><code>#include&lt;iostream&gt; 

constexpr long int fib(int n) { 
    return (n &lt;= 1)? n : fib(n-1) + fib(n-2); 
} 

int main () {  
    long int res = fib(45); 
    std::cout &lt;&lt; res; 
    return 0; 
} 
</code></pre>

<p>When I run this code it takes about 7 seconds to run. So far so good. But when I change <code>long int res = fib(45)</code> to <code>const long int res = fib(45)</code> it takes not even a second.
To my understanding it is evaluated at compile time. 
<strong>But the compilation takes about 0.3 seconds</strong></p>

<p>How can the compiler evaluate this so quickly, but at runtime it takes so much more time?
I'm using gcc 5.4.0.</p>
