Mail Archives: djgpp/1996/12/27/19:43:48
Once upon a time (on 27 Dec 96 at 14:36) Salvador Eduardo Tropea
(SET) said:
> > When I do an asm statement, does djgpp care if I change ES, FS, or
> > GS? can I mutilate them all I want without the worry that djgpp
> > will crash?
As long as you save them and restore when done, it's OK to mess up
with them.
FS is being used whenever you take advantage of any far* functions
(the ones used to emulate FAR pointers with DJGPP).
Also you have to remember that segment registers in PM contain
SELECTORS (which are offsets to LDT or GDT) and NOT real segment
offsets as in RM.
> > also, does DS ALWAYS hold the data selector for all my variables I
> > ever declare in a program? Or does it just hold the global
> > variable selector?
> You are in a flat memory model DS=CS=ES(=SS? I guess), so DS is
CS is not always equal to the rest, but the others are the same most
of the time.
- Raw text -