Re: [PATCH ftrace.git] Immedate Values Optimized Jump Fix

From: H. Peter Anvin
Date: Fri Jul 18 2008 - 19:37:42 EST


Mathieu Desnoyers wrote:

Hrm, I thought that by following the execution flow to both branches and
by looking at the code pattern found (load immediate, test, branch) and
by placing a constraint on the eax register to detect the liveliness
region of that variable we would be guaranteed that the compiler could
not re-use this variable outside of the pattern scope.


Nope, and you *cannot* allow such registers to be live *anywhere* the C compiler is generating code, even between two asm() statements with nothing in between.

-hpa
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/