This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch libffi]: Add thiscall-closure support for fixing regression PR/51500


On Tue, Jan 31, 2012 at 10:51 AM, Kai Tietz <ktietz70@googlemail.com> wrote:
> Ok, this variant keeps 16-byte alignment for thiscall-closure.

It doesn't. You have to account for the fact that caller pushed return
address to the stack, so %esp was already decreased by 4 behind your
back. To maintain alignment, you have to decrease %esp by $12, not by
$16.

Uros.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]