Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Memory Conservation
#21
Overlays are more problem then it's worth.

The OBJ files can never exceed 64kb.
The same goes for any overlay (combination of OBJ's)

There's also a speedhit if you cross call subs and functionsbetveen overlays. (Not too serious, 1000 calls was about 1sec slower then not using overlays, but it seems that windows doesent buffer, so the overlays is needed to be loaded from disk each time, stupid)


But, with some smart coding it can be solved. And with 16MB EXE you should be fine.


If you don't want to use overlays, then external files, or compression is the only way I can think of.
Reply
#22
Quote:Overlays are more problem then it's worth.

What a problem? To have to compile manually? Tongue We must be used to that. We all end doing it sooner or later. The IDE takes too much mem.

Quote:The OBJ files can never exceed 64kb.
The same goes for any overlay (combination of OBJ's)

An overlay can be up to 256 Kb. I bet that almost none of you have ever got a 256 Kb EXE, so I can guarantee that 256 Kb per overlay is plenty of room. Plus not having all the code on mem gives you more mem on the far heap to play with. I mean, more room for dynamic data.

Quote:There's also a speedhit if you cross call subs and functionsbetveen overlays. (Not too serious, 1000 calls was about 1sec slower then not using overlays, but it seems that windows doesent buffer, so the overlays is needed to be loaded from disk each time, stupid)

No if you organize stuff properly. I wrote an article on that next to the tut.
You don't need all your code on memory at the same time. Plus, the controller works very efficiently and if EMS is present it uses it to store the overlays automaticly (no user interaction needed), so de load is even faster. Besides, our windows computers are cached and most likely when loading an overlay it will lay somewhere in memory.
Quote:But, with some smart coding it can be solved. And with 16MB EXE you should be fine.

Exactly Smile
SCUMM (the band) on Myspace!
ComputerEmuzone Games Studio
underBASIC, homegrown musicians
[img]http://www.ojodepez-fanzine.net/almacen/yoghourtslover.png[/i
Reply
#23
Nathan, test it, each overlay cannot be more then 64kb, it has to fit into a segment.

Ask jonathan about it, we had a long talk, and did lot's of testing, as I couldn't get my code to work, turned out, it was the 64kb limit.


About the call to a sub in an overlay, it was slower, don't ask me why, but I tested it, lot's of times. On windows 98, with EMS activated.

But 0.001 seconds slower... I can live with that for huge EXE files...



But the 256kb is wrong, try it. If you get it to work tell me how, cause I never got it to work on anything above 64kb.

I'm using PDS 7.1
Reply
#24
Odd, 'cause the documentation tells 256 Kb... The 64 Kb limitation doesn't make sense as PDS uses the medium memory model which has 1 segment for DATA and several for code.
SCUMM (the band) on Myspace!
ComputerEmuzone Games Studio
underBASIC, homegrown musicians
[img]http://www.ojodepez-fanzine.net/almacen/yoghourtslover.png[/i
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)