1 while (t < threshold) { 2 t = 0; 3 for(i = 0; i < N; i++) 4 t += A[i] + B[i] * delta; 5 delta -= 0.1 * t; 6 } 1 for (i = 0; i < N; i++) 2 a += A[i]; b += B[i]; 3 while (t < threshold) { 4 t = a + b * delta; 5 delta -= 0.1 * t; 6 } Listing 1: An example code (on the left) with temporal inefficiencies that cannot be identified by existing fine-grained profilers. Because arrays A and B are immutable in the loop nest, computing on these loop invariants introduces many redundancies. One can hoist the redundant computation outside of the loop (on the right) for optimization. 1 int A[N] = {1, 1, 1, 15}; 2 for(i = 0; i < N; i++) 3 { 4 t += func(A[i]); 5 } 1 int A[N] = {1, 1, 1, 15}; 2 a = func(A[0]); 3 for(i = 0; i < N; i++) { 4 if (A[i] != A[i-1]) 5 a = func(A[i]); 6 t += a; }