TIP: Click on subject to list as thread! ANSI
echo: os2
to: All
from: Leonard Erickson
date: 1999-09-09 01:04:02
subject: DOS program `fix`

I've got a DOS program that I need to run that hogs the CPU. Setting
idle sensitivity to 1 improves things greatly. 

But I've got the source, and I'd like to make it more multi-tassking
friendly. It looks like it's in a polling loop when it's hogging the
CPU (basicly it's waiting for me to hit a key). 

I seem to recall that there's a DOS INT I can call that'll free up the
rest of the timeslice. IE. change the code like this:


Old:

  Repeat
    ...
    X := keypressed;
    ...
  until keypressed or ....

New:

  Repeat
    ...
    X := keypressed;
    ...
    INT XX;
  until keypressed or ....


But I don't recall what the Int is.

--- Blue Wave/DOS v2.30
* Origin: Shadowshack (1:105/51)

SOURCE: echoes via The OS/2 BBS

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.