cvs commit: src/lib/libc/amd64/gen makecontext.c

Daniel Eischen eischen at vigrid.com
Thu Dec 4 17:46:06 PST 2003


On Thu, 4 Dec 2003, Peter Wemm wrote:

> peter       2003/12/04 17:36:44 PST
> 
>   FreeBSD src repository
> 
>   Modified files:
>     lib/libc/amd64/gen   makecontext.c 
>   Log:
>   "Fix" makecontext() so that the C code begins execution with its
>   ABI-required stack alignment.  C code expects that the push of the
>   return address disturbed the 16 byte alignment and it will take corrective
>   measures to fix it before making another call.  Of course, if its wrong
>   to start with, then all hell breaks loose.  Essentially we "fix" this
>   by making the stack alignment odd to start with.

Hey, you didn't include this little bit of knowledge in your amd64 "notes"
that you sent me ;-)

>   This was one of the things that broke on libkse with apps that use
>   floating point/varargs/etc.

I guess we never hit this problem with the tests (ACE) that we ran
on sledge...





More information about the cvs-src mailing list