3 ms·
Turbo Pascal had a system like that called "Overlays" back in the 640 kB memory days. If you had multiple code modules of which just one was in place at a time,
by Erwin 6y ago
Turbo Pascal had a system like that called "Overlays" back in the 640 kB memory days. If you had multiple code modules of which just one was in place at a time, you could overlay them so just one got loaded at a time.
While that's before my time (Turbo Vision in 6.0 was when I started), TP 2 and 3 supported only COM files which could have only 64 kilobytes of code, making overlay extra important.
- lispm 6y agoThe original MacOS from 1984 (?) also had such a feature, IIRC: the segment loader.
- p_l 6y agoBefore demand paging or any other virtual memory it was very common technique. Lots of use on PDP-11 or IBM S/360.
- Roboprog 6y agoOverlays were common on MS-DOS in the 80s. A typical scheme was to have a configuration file / script for the linker. You would list one or more blocks, each of which had a list of mutually exclusive .obj files to be swapped in and out as needed. It could be challenging to track dependencies between objects to make sure you never called between modules which were supposed to be mutually exclusive, which was why you sometimes had multiple swap buffers. Later linkers, or proprietary schemes like in Turbo Pascal version 5, would swap things per subroutine, rather than per compilation unit (.obj file), which was much easier to use. (I did once see some people make a C function that was literally over 50 printed pages long, and the overlay manager didn’t help them much with OOM, among other problems that thing had)