Date: Fri, 1 Aug 1997 10:25:18 -0700 (PDT) Message-Id: <199708011725.KAA16373@adit.ap.net> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" To: djgpp AT delorie DOT com From: Nate Eldredge Subject: Re: djgpp & asm obj & registers Precedence: bulk Jason Meehan wrote: >I'm trying to interface to an asm obj that uses the stack to pass >variables. So what I need to know is how do I tell Djgpp not to mess >with certain registers(ebx,ecx,edx,esi,edi,es) so that my program wont >crash. >thanks. You could use the switch -ffixed-* (see the GCC docs), but I'd guess GCC will have an awfully hard time generating code using only one register. Your best bet might be to put an asm wrapper around the function that saves the registers and restores them later. Nate Eldredge eldredge AT ap DOT net