DS and ES matching (Developers)
I would like my MSDOS executables to be able to accept an
override of callback functions to use instead of executing
an INT 21H.
So I need a way of detecting that I am in a non-MSDOS
environment that provides a callback facility on the stack
(or possibly in a pair of registers - I'm open to opinions).
One way I could do that is by making ES different from DS,
instead of having both of them pointing to the PSP.
I could make ES equal to FFFF, which is an indicator that
this is a PDOS-generic environment, so look on the stack etc.
I believe MSDOS 4 multitasking already changes either DS
or ES or both on entry, perhaps to support DLLs or something.
So that's why I would have the further ES setting, to distinguish
from that.
Since we have the normal non-MT source code, I was just
wondering how definite it is that DS and ES match. ie will
they always be set the same, or are there some special
conditions? Is there a deliberate attempt to make them
the same (seems a bit odd actually, but that's ok).
Thanks. Paul.
Complete thread:
- DS and ES matching - kerravon, 18.10.2025, 11:29 (Developers)
![Open in board view [Board]](img/board_d.gif)
![Open in mix view [Mix]](img/mix_d.gif)
- DS and ES matching - ecm, 18.10.2025, 12:48
- DS and ES matching - kerravon, 18.10.2025, 14:43
- DS and ES matching - PDB meaning - ecm, 18.10.2025, 18:32
- DS and ES matching - PDB meaning - kerravon, 18.10.2025, 19:04
- DS and ES matching - PDB meaning - ecm, 18.10.2025, 19:41
- DS and ES matching - PDB meaning - kerravon, 18.10.2025, 19:59
- DS and ES matching - PDB meaning - kerravon, 18.10.2025, 20:01
- DS and ES matching - PDB meaning - kerravon, 18.10.2025, 19:04
- DS and ES matching - PDB meaning - ecm, 18.10.2025, 18:32
- DS and ES matching - kerravon, 18.10.2025, 14:43
- DS and ES matching - kerravon, 19.10.2025, 10:32
- DS and ES matching - ecm, 18.10.2025, 12:48
Mix view