Date: Fri, 24 Mar 1995 18:03:02 -0500 From: dj (DJ Delorie) To: A DOT APPLEYARD AT fs2 DOT mt DOT umist DOT ac DOT uk Cc: DJGPP AT SUN DOT SOE DOT CLARKSON DOT EDU Subject: Re: copying n bytes > That is why I preserved and restored ESI and EDI, and in other asm() > programming I try to use registers AX and BX only. In gcc, you have to preserve ALL registers with inline assembler, or tell gcc that you are using them. Otherwise, gcc may assume that the registers' values are preserved. Read the info files on gcc (C Extensions, Extended ASM) for details on filling in the asm() templates.