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: Libffi: closures for x86_64


Jakub Jelinek writes:
 > On Mon, Jan 27, 2003 at 05:45:23PM +0000, Andrew Haley wrote:
 > > +   tramp = (unsigned short *) &closure->tramp[0];
 > > +   tramp[0] = 0xbb49;		/* mov <code>, %r11d	*/
 > 
 > 							^^^ comment typo
 > The instruction is mov <code>, %r11, not mov <code>, %r11d.

OK.

 > > +   tramp[5] = 0xba49;		/* mov <data>, %r10	*/
 > > +   tramp[10] = 0xff49;		/* jmp *%r11	*/
 > > +   tramp[11] = 0x00e3;
 > > +   *(void **) &tramp[1] = ffi_closure_UNIX64;
 > > +   *(void **) &tramp[6] = closure;
 > 
 > And this is aliasing bug.

It certainly is.  Thanks.

Andrew.


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