Article View: comp.os.msdos.programmer
Article #1697Re: Virtual Memory for the Heap
From: Walter Bright
Date: Fri, 27 Jul 1990 21:22
Date: Fri, 27 Jul 1990 21:22
21 lines
1474 bytes
1474 bytes
In article <2628@mindlink.UUCP> a35@mindlink.UUCP (Bruce Atherton) writes: <I'm looking for the best method of implementing virtual memory on 80x86 <machines under MSDOS. Specifically, it has to allow swapping of the <heap, rather than code. The method that is the simplest to implement <and least buggy would be preferable. < <What about using _handle in Zortech C++? It sounds like it would be <easy for bugs to creep in, from the description I read. I've used _handles quite a bit in my code. The reason they were implemented is that the code looked so *ugly* when explicit function calls had to be done to dereference a handle. Thus, making a handle a special pointer type, and having the compiler call the function for you, cleaned up the code a lot. I'd say that the _handles are certainly the easiest to convert your code into using. The thing to watch out for is inadvertently converting a handle to a far pointer, as in stuff like: char _handle *h; h = (char *) handle_malloc(10); /* error! */ h = (char _handle *) handle_malloc(10); /* correct way */
Technical Details
Message-ID:
<2595@dataio.Data-IO.COM>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!mailrus!cornell!uw-beaver!entropy!dataio!brightReferences:
<2628@mindlink.UUCP>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!mailrus!cornell!uw-beaver!entropy!dataio!bright From: bright@Data-IO.COM (Walter Bright) Newsgroups: comp.os.msdos.programmer Subject: Re: Virtual Memory for the Heap Message-ID: <2595@dataio.Data-IO.COM> Date: 27 Jul 90 21:22:41 GMT References: <2628@mindlink.UUCP> Organization: Data I/O Corporation; Redmond, WA Lines: 21