Page 1 of 1

Which is faster?

Posted: Thu Aug 11, 2005 11:24 pm
by Zamaster
Which type of memory is faster: XMS or EMS?

Posted: Fri Aug 12, 2005 6:23 am
by Nodtveidt
I think you're gonna have to have someone like Plasma verify this, but to my knoweldge, EMS is typically faster because it stays in v86 mode whereas XMS has to switch to protected mode to be used. But since EMS on modern computers is emulated through XMS...I'm not sure if it's really faster or not. In any event, XMS is more widely supported than EMS nowadays, so XMS is generally better to use even if it may be slightly slower.

Posted: Fri Aug 12, 2005 6:37 am
by Antoni
If you are in QB, add to what Nek said:
In EMS you can peek/poke/put/get directly the EMS window.
XMS is unreachable from QB, you must copy the data to normal memory with the XMS functions before accessing it.

Posted: Fri Aug 12, 2005 6:49 am
by Z!re
Actually, using XMS isnt that slow..

I used it wthout problem for the QB version of FieldView (MOoRPG)

Loaded large parts of the world (which was 64mb total) until the mem was filled, keep the parts closest to the player.

Dump parts from XMS to conventional when they're in use..

A part was 320x200x2 bytes, where each 2byte block represented a tile
Each part was additionally divided up into two parts, to fit in a 64kb segment


MOoRPG ran at 60FPS (Which is what I locked it at) without problems, without the block people reported as high as 500'000FPS



I used RelLIB's XMS routines for copying conventional mem to XMS, and retreive from XMS back to conventional



But generally, EMS is faster, but the speed difference is neglectable with some creative coding..
The benefits of being able to run on 30% of the worlds computers, as opposed to 10% weights up any dissadvantage, if any, XMS would have compared to EMS