delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/03/07/15:50:59

From: "Campbell, Rolf [SKY:1U32:EXCH]" <moscoop AT americasm01 DOT nt DOT com>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Inline asm
Date: Tue, 07 Mar 2000 12:54:11 -0500
Organization: Nortel Networks
Lines: 22
Message-ID: <38C54243.DB343A69@americasm01.nt.com>
References: <Pine DOT SUN DOT 3 DOT 91 DOT 1000307101530 DOT 21628D-100000 AT is>
NNTP-Posting-Host: wmerh0tk.ca.nortel.com
Mime-Version: 1.0
X-Mailer: Mozilla 4.72 [en] (X11; I; HP-UX B.10.20 9000/785)
X-Accept-Language: en
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Eli Zaretskii wrote:

> On Mon, 6 Mar 2000, Campbell, Rolf [SKY:1U32:EXCH] wrote:
>
> > __dpmi_regs regs;
> > memset(&regs, 0, sizeof(regs));  //I think this is optional for this
> > specific example
> > regs.x.ax = 0x13;
> > __dmpi_int(0x10, &regs);
>
> It is not necessary to zero-out regs when using __dpmi_int, since
> __dpmi_int zeroes out the parts that need that.

    Yes, but I think it is a good practise in general because some
interrupts act differently when other registers contain random values,
but maybe I'm over-reacting..

--
(\/) Rolf Campbell (\/)



- Raw text -


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