🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.os.msdos.programmer
Article #249

Re: Paging large data files

#249
From: Ping Huang
Date: Thu, 06 Aug 1992 01:02
32 lines
2476 bytes
In article <1992Aug5.193559.19274@infonode.ingr.com> fisherm@infonode.ingr.com (Matthew Fisher) writes:

 >    I'm dealing with a table the is larger than 640k.  I need some code or
 > ideas on how to do effcient page swapping.  Access of the table is in no
 > particular order.  One access my be in the first 20k and the next access may
 > be up past 2mg.  The data cannot be sorted to make the access any better.

It sounds like what you really want to do is use a DOS extender and a
32-bit C compiler instead of writing a Windows program. The 32-bit C
compiler part allows you to write programs which can malloc a two
megabyte array, for instance, and crunch data objects larger than 64Kb
without giving it a second thought. You get full access to the amount of
extended memory in your PC, rather than the 1Mb you get under normal DOS
programs. The DOS extender part allows your 32-bit program code to do
I/O and otherwise call upon DOS services, because it translates your
requests into 16-bit requests that DOS can understand. Some DOS
extenders can provide virtual memory, as Windows can in 386 enhanced
mode, but the DOS extender can do so with less speed overhead and takes
up less of your memory than Windows does.

Or you could write your program for OS/2 2.0. :) You would need a 32-bit
C compiler (no DOS extender necessary, and OS/2 itself is quite capable
of providing virtual memory). GNU's C/C++ compiler has been ported and
works quite well for data crunching.

Followups either to comp.os.msdos.programmer (for DOS extender
discussions) or comp.os.os2.programmer for OS/2 2.0 discussions.

--
| Ping Huang (INTERNET: pshuang@martigny.ai.mit.edu) speaking for himself.
| "One Thing to name them all, One Thing to define them,
|  One Thing to place them in environments and bind them..."
Technical Details
Message-ID: <PSHUANG.92Aug5210204@freeside.ai.mit.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!snorkelwacker.mit.edu!ai-lab!zurich.ai.mit.edu!pshuang
References: <1992Aug5.193559.19274@infonode.ingr.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!stanford.edu!snorkelwacker.mit.edu!ai-lab!zurich.ai.mit.edu!pshuang
From: pshuang@zurich.ai.mit.edu (Ping Huang)
Newsgroups: comp.os.msdos.programmer,comp.sys.ibm.pc.programmer,comp.windows.ms.programmer,comp.os.ms-windows.programmer.misc
Subject: Re: Paging large data files
Message-ID: <PSHUANG.92Aug5210204@freeside.ai.mit.edu>
Date: 6 Aug 92 01:02:04 GMT
References: <1992Aug5.193559.19274@infonode.ingr.com>
Sender: news@ai.mit.edu
Followup-To: pshuang@athena.mit.edu
Organization: M.I.T. Artificial Intelligence Lab.
Lines: 33
In-reply-to: fisherm@infonode.ingr.com's message of 5 Aug 92 19:35:59 GMT