VOGONS


First post, by Lope

User metadata
Rank Newbie
Rank
Newbie

Hello! Firstly I want to say that Dosbox is great! I felt the urge to play some ultima 8. After struggling for hours with virtual PC, VMware, and even some windowx9x patch for ultima. I tried Dosbox and it worked really well and effortlessly. Well done, great idea etc etc.

The main reason I'm posting is because Dosbox is slow.

I understand and respect your goals for focusing on compatability, and not wanting to get tied down with platform specific code with regards to virtualisation, platform specific and configuration specific optimisations.

I gave it all some thought and there are two things I want to say.

I read another thread where someone said DosBox emulated CPU speed = 1/40th of host CPU speed, therefore to have the equiv of a P200 you need 8ghz. Others responded by saying "yeah, that'll be here quick quick"

I dont believe 8ghz processors will be available before at least 2011 (not electronic CPUs anyway) and if they do become available, they probably wont be affordable for another year after that at least.

The area which CPUs are currently improving in mainly is paralell processing, and from my 'laymans' perspective in this area, paralell processing would be pretty hard to take advantage of with a project like this. So basically waiting for CPU technology to improve to the point where Dosbox runs fast is going to take many years IMHO.

***

I had an idea which could solve the speed problem and not interfere with this project's goals and aspirations. I dont know how feasable it is and I'm not an expert in this field.
Here were my thoughts.
* Dos game executables are pretty small
* Platform independant, high level, unoptimised code, filled with debugging information etc (slow code) could be used to translate old dos games into new, platform dependant (or possibly independant) optimised code. The software would just translate a game once and then speed wouldnt be of the slightest concern at that point.

Essentially, Dosbox would become a code generator.
Why translate each instruction in real time, over and over again, when you could just translate them all once, and run the output at high speed?

PS: I'm sure I've heard of some language(s) being developed for game developers where they can develop a game once, and the compiler would compile the (one) source into optimised, platform specific code.
If this imaginery new Dosbox could generate code for a language such as this, it would be first prize.

Reply 1 of 7, by DosFreak

User metadata
Rank l33t++
Rank
l33t++

There really are no major speed issues with DosBox if you have at least a 2ghz Athlon. Since a 2ghz is about 4 years old and Core 2 Duo's (which pretty much eliminate DosBox speed problems) are pretty much taking over the world and the fact that wd is working on some major speed improvements for DosBox (from 15fps @640x480 to 35fps on my XP 2800+ in Duke3D) then there are really no reasons to complain.

As for your "solution" it sounds overly complicated. How could producing platform dependant code possibly be a good thing if we are talking thousands of DOS games? Do you know how many "platforms" there are out there and will be there in the future? It just doesn't make any sense to reduce the high level of compatibility that DosBox offers for the sake of a supposed speed increase.

How To Ask Questions The Smart Way
Make your games work offline

Reply 2 of 7, by collector

User metadata
Rank l33t
Rank
l33t

It sounds like you are talking about something more along the lines of ScummVM. Such a thing requires a lot of work for even just one game. The games supported by ScummVM have been RE'ed or have had the source given to them by the original developers. While what you propose would be nifty, it sounds rather fanciful.

Reply 3 of 7, by vasyl

User metadata
Rank Oldbie
Rank
Oldbie

I think he is talking about static recompilation. It is possible in theory, as long as there is no self-modifying code around, but it is quite a lot of work in case of x86 architecture. It may actually work for some games. Overall, the technique is practically unrelated to DOSBox -- there may be some code in dynamic core that may help but the goals are too different.
BTW, I've seen this approach on other platforms. There are about a dozen MSX games recompiled to PC. AFAIK, that recompilation required a lot of manual intervention, and the result was not portable.

Reply 4 of 7, by Freddo

User metadata
Rank Oldbie
Rank
Oldbie
DosFreak wrote:

wd is working on some major speed improvements for DosBox (from 15fps @640x480 to 35fps on my XP 2800+ in Duke3D)

Whoa 😳

That sounds awesome 😀 Is that something that will affect all cores?

Yay for wd! 😁

Reply 7 of 7, by dasen

User metadata
Rank Newbie
Rank
Newbie

I use dosbox in linux and I'm amazed at the speed of it. I have a laptop with amd sempron (1.8 GHZ) and 1GB ram, and crapy SIS gfxcard. To get the best visuals and speed I use dynamic core, plus auto cycles, original resolution, output to surface and normal3x because otherwise my crap laptop blurs the pixels. It runs fantastic! Just have left is a subsitute for the crap that arts is and artsdsp is, to be able to get general midi (use timidity) and sound effects (normal sb16 emulation) at the same time. I'm gonna try esd.