Mail Archives: djgpp/1997/08/01/13:26:09
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
- Raw text -