delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/10/25/21:37:51

From: "Michael Åström" <denatus AT geocities DOT com>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Are DPMI functions reenterent?
Date: 20 Oct 1996 23:50:50 GMT
Organization: Rigor Mortis
Lines: 28
Message-ID: <01bbbee9$9981d220$0271f482@s-17373>
References: <3265DD58 DOT 3721 AT rangenet DOT com>
NNTP-Posting-Host: dialup113-1-2.swipnet.se
NNTP-Posting-User: s-17373
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

Dan Hedlund <markiv AT rangenet DOT com> wrote in article
<3265DD58 DOT 3721 AT rangenet DOT com>...
> I've been using a dynamic stack instead of a static stack in my
> interrupt routines.  Is it SAFE to call DPMI functions (501 and 502)
> while servicing an interupt.  My program used to lock up when I used a
> static stack.

Well, I think this will answer your question... I found it in Tran's PMode
2.51 docs:
--[cut here]--
3.1 - DPMI, and the stack:
--------------------------
  The one anomaly to PMODEs stack with IRQs is DPMI. It sees fit to switch
onto its own stack whenever an IRQ goes off. And if you try to switch off
that
stack, you will be severely punished by DPMI. For this reason, calls to
real
mode (INT 32h, 33h) from IRQs under DPMI may or may not work depending on
what
DPMI you're running under and how buggy it is. I have had no problems with
Windows DPMI driver in these situations, but you have been warned. Because
DPMI switches onto its own stack, you can not assume anything about SS in
IRQ
handlers, and should definately not mess with it.
--[cut here]--
You might have been "severely punished by DPMI"... =)

// Denatus / Rigor Mortis

- Raw text -


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