delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/03/18/12:20:57

Message-Id: <199703181644.RAA19866@math.amu.edu.pl>
Comments: Authenticated sender is <grendel AT hoth DOT amu DOT edu DOT pl>
From: "Mark Habersack" <grendel AT hoth DOT amu DOT edu DOT pl>
Organization: PPP (Pesticide Powered Pumpkins)
To: "Michael D. McDonnell" <tics AT concentric DOT net>, djgpp AT delorie DOT com
Date: Tue, 18 Mar 1997 17:38:28 +0100
MIME-Version: 1.0
Subject: Re: Stack Switching in Isr's
Reply-to: grendel AT hoth DOT amu DOT edu DOT pl
In-reply-to: <332DC64B.7232@concentric.net>

On 17 Mar 97 (at 14:31) Michael D. McDonnell became famous by saying:

> In a real-time multi-threaded system it is sometimes desirable to 
> to switch stacks from within an isr so that the
> the "iret" instruction will return to a higher priority
> thread. This is a simple matter under DOS, but DPMI seems
> to pose various obstacles. Is there a clean solution?
Actually, there is. I'm attaching the code which does just that - it switches 
stacks (and more). The code was written with something different in mind but 
you (and others, of course) may find it useful. To compile the code and a 
test application, you must have installed the following DJGPP components 
(from v2.01):

  make 3.75+
  objdump 2.7+
  gas 2.7+
  sed 1.18+
  and of course DJGPP itself ;-))

make the project with TEST=1 to create a test app. Good luck!

****************************************************************
You ask for my love on a strength of a kiss,
But can't you just play for experience?
I'm a poet, I'm a minstral, I don't need your chains
Romance lies in ruin, let debauch you bewail, let it rain...

- Raw text -


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