4.77 MHz

The IBM PC XT ran at 4.77 MHz. This describes how to run DOSBox at XT-like speeds for programs that do not perform their own timing. Keep in mind that DOSBox cannot run at exactly 4.77 MHz. At least, not exactly the way an IBM PC XT did. You can, however, get pretty darn close by testing with some benchmark tools.

As you will see in the testing below, various types of computer instructions run at widely various speeds on the different types of computer chips out there. The most striking example is perhaps math instructions that involve real numbers such as: 1.1 x 2.2 = 2.42. This is called floating-point math. Floating-point instructions were extremely slow on the 8086 CPU unless you installed the optional 8087 co-processor. It wasn't until the Pentium age that floating-point hardware was built into all PC CPU's. Anyway, the point is that DOSBox has only one speed control, and it slows down all computer instructions by the same percentage (more or less). It is therefore not possible to tell DOSBox to slow integer math by X%, floating-point math by Y%, and non-math by Z%, etc. Near-perfect 4.77 MHz speed will not be possible until someone builds an XT emulator specifically for this purpose. This is not likely to happen because close enough will always be, quite frankly, good enough.

Your goal is to get the Performance Rating in the IBM/XT column to equal 1.00. To do this, press Ctrl-F11 (slow down) or Ctrl-F12 (speed up) several times while watching the CPU Cycles in DOXBox’s title bar change from 300 to your next test value.

Run MIPS again. Repeat steps 4 and 5 until you get a Performance Rating of 1.00

Make a note of your final CPU Cycles value and set "cycles=xxx" to this value in your dosbox.conf whenever you need 4.77-MHz-like speed.

Notes

Some users may prefer a speed at which General Instructions equals 1.00 (instead of Performance Rating). This depends entirely upon what kinds of instructions you feel affect the program’s speed the most. 2D games should not be using any floating-point math so no worries there. But predicting whether a program is integer heavy, memory heavy, or whatever heavy, would be pure sorcery. [Anyone care to modify a debugger to analyze this? Didn’t think so.] Really, just choose what feels best to you (actually, I can hardly tell the difference between cycles=245 and cycles=290).

My current DOSBox speed on a 1.3 GHz Athlon is cycles=245. At such low DOSBox speeds I am finding about a 1% difference between Normal CPU Mode and Dynamic CPU Mode. Therefore, you shouldn’t need to worry about benchmarking that setting. Interestingly, with dynamic mode versus normal mode, the Integer Instructions benchmark ~3% slower and Register to Register benchmarks ~10% faster (the other benchmarks are proportionately 1% faster). Dynamic mode plays a larger role at higher speeds.

Other benchmarks:

Speed Test 1.14 - CPU benchmark with data from XT to Pentium 200 MHz. Results are close to MIPS general instructions.

COMPTEST 2.60 - close to MIPS general instructions rating and offers floating-point benchmarks. Not dynamic mode compatible. Speed is determined by executing a block of FSQRT instructions.

SLOWDOWN 2.00 - tends to agree with the MIPS performance rating but varies a bit depending on what speed you are slowing down from. Not dynamic mode compatible. Usage: slowdown /xt