www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1993/04/19/13:25:31

Date: Mon, 19 Apr 93 13:09:50 EDT
From: DJ Delorie <dj AT ctron DOT com>
To: erik AT microware DOT com
Cc: djgpp AT sun DOT soe DOT clarkson DOT edu
Subject: Re: Registers in GAS

>   1  Which registers must be preserved in C/C++/Assembly routines

bx, si, di must be preserved.

>   2  Can I use segment pointers %es %fs & %gs (I could use a few address regs)

In general, there should be no reason to use segment registers.  go32
sets up the registers to the linear mapping segments it uses and there
is no part of memory you can't access with these segments.  Also, you
can't use them as general-purpose registers since the 80386 may fault
if you load them with an invalid value.

DJ

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019