delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2012/05/28/18:30:08

X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f
From: Rugxulo <rugxulo AT gmail DOT com>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: gprof output
Date: Mon, 28 May 2012 15:01:26 -0700 (PDT)
Organization: http://groups.google.com
Lines: 46
Message-ID: <2e7c9b7d-4a75-4435-8e85-0f8db5933349@f14g2000yqe.googlegroups.com>
References: <7822bb4a-1059-491a-8489-e1d9f3dbc501 AT l17g2000vbj DOT googlegroups DOT com>
<a2en0pFpq6U1 AT mid DOT dfncis DOT de> <e9a9d1fc-4410-425e-9b22-74529940d0b8 AT eh4g2000vbb DOT googlegroups DOT com>
<83aa0s114h DOT fsf AT gnu DOT org>
NNTP-Posting-Host: 65.13.115.246
Mime-Version: 1.0
X-Trace: posting.google.com 1338243548 28524 127.0.0.1 (28 May 2012 22:19:08 GMT)
X-Complaints-To: groups-abuse AT google DOT com
NNTP-Posting-Date: Mon, 28 May 2012 22:19:08 +0000 (UTC)
Complaints-To: groups-abuse AT google DOT com
Injection-Info: f14g2000yqe.googlegroups.com; posting-host=65.13.115.246; posting-account=p5rsXQoAAAB8KPnVlgg9E_vlm2dvVhfO
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (X11; U; Linux i686; en-US) AppleWebKit/534.16
(KHTML, like Gecko) Chrome/10.0.630.0 Safari/534.16,gzip(gfe)
X-Received-Bytes: 2873
Bytes: 2973
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id q4SMU2Tl018787
Reply-To: djgpp AT delorie DOT com

Hi,

On May 28, 3:50 pm, Eli Zaretskii <e DOT  DOT  DOT  AT gnu DOT org> wrote:
> > From: Georg <dos DOT  DOT  DOT  AT googlemail DOT com>
> > Date: Mon, 28 May 2012 13:37:54 -0700 (PDT)
>
> > I now removed my _dpmi_int calls from my program but still 80-90% of
> > the processing time is done for _dpmi_int. Does djgpp call this
> > internally?
>
> Yes.

It shouldn't be "slow" just because it uses __dpmi_int. Don't worry
about it unless you're sure that something isn't nearly fast enough.
(I'm not sure what you're trying to do here.)

> > I use int86() to query the mouse and getch() plus bioskey() to query
> > the keyboard. Could these functions cause this?
>
> Of course!  Any real-mode interrupt call goes through __dpmi_int,
> because that's the _only_ way to invoke real-mode DOS/BIOS services
> from protected mode.

Couldn't he bypass DOS and go directly to keyboard himself? (naive)
Would that speed things up, or do you run into a billion problems like
EMM386 and IOPL or whatever-the-heck?

http://wiki.osdev.org/Interrupts

> push eax    ;; make sure you don't damage current state
> in al,60h   ;; read information from the keyboard
>
> mov al,20h
> out 20h,al  ;; acknowledge the interrupt to the PIC
> pop eax     ;; restore state
> iret        ;; return to code executed before.

Hmmm, I vaguely remember the UPX dude writing his own keyboard
library, and (IIRC) it works with DJGPP.

http://www.ibiblio.org/pub/Linux/libs/ui/libkb-1.01.tar.gz

P.S. Just as I thought (doh), DJGPP's mirror, /current/ only, has
older 1.00:

ftp://ftp.delorie.com/pub/djgpp/current/v2tk/libkb100.zip

- Raw text -


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