b to eliminate the deadlock initaliaize the binary

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: ER data[1] OPER data[2] OPER data[3] OPER data[4] OPER data[5] OPER data[6] OPER data[7]; data += 8; } /* Finish any remaining elements */ for (; i < length; i++) { x = x OPER data[0]; data++; } *dest = x; } Our handwritten pointer code is able to eliminate loop variable i by computing an ending value for the pointer. This is another example of where a human can often see transformations that are overlooked by the compiler. Problem 5.4 Solution: [Pg. 246] Spilled values are generally stored in the local stack frame. They therefore have a negative offset relative to %ebp. We can see such a reference at line 12 in the assembly code. A. Variable limit has been spilled to the stack. B. It is at offset relative to %ebp. C. This value is only required to determine whether the jl instruction closing the loop should be taken. If the branch prediction logic predicts the branch as taken, then the next iteration can proceed before the loop test has completed. Therefore, the comparison instruction is not part of the critical path determining the loop performance. Furtherm...
View Full Document

Ask a homework question - tutors are online