[coreboot] [PATCH] v3: correct K8 stack preservation asm
c-d.hailfinger.devel.2006 at gmx.net
Fri Sep 5 04:12:08 CEST 2008
On 05.09.2008 03:49, Carl-Daniel Hailfinger wrote:
> The current K8 stack preservation code in disable_car() works by chance,
> but that's not something we should rely on.
> The new code is entirely rewritten, fixes a few missing constraints in
> the asm and should be a lot more readable. However, the generated code
> should be mostly identical.
I hate to say it, but the generated code is NOT identical. The old code
was broken because of the missing ecx clobber constraint and it did not
copy the stack back (ecx was zero at the beginning of the copy-back loop
and so the loop executed exactly zero times).
So this is a genuine bug fix. v2 may be affected as well.
> Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006 at gmx.net>
More information about the coreboot