flat assembler
Message board for the users of flat assembler.

Index > Compiler Internals > Bochs & fasm for dos problem

Goto page 1, 2  Next
Author
Thread Post new topic Reply to topic
keyoke



Joined: 18 Jun 2003
Posts: 56
Location: London
keyoke 22 Jun 2004, 12:53
Hi,
I am using bochs 2.1.1 to run msdos 6.22 and within this i wanna run the dos fasm 1.52 compiler to compile some code....but fasm crashes bochs, here is the output in the bochs log file could any1 tell me how i can fix this!
thanks

Quote:

00006570613i[BIOS ] int15: Func 24h, subfunc 03h, A20 gate control not supported
00006743974i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006748394i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006752814i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006757234i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006761654i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006766074i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006770494i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006774914i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006779334i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006783754i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006788174i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006792594i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006797014i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006801434i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006805854i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00006810274i[BIOS ] *** int 15h function AX=D800, BX=B3D2 not yet supported!
00529751805p[CPU ] >>PANIC<< prefetch: getHostMemAddr vetoed direct read, pAddr=0xac0ec.
Post 22 Jun 2004, 12:53
View user's profile Send private message Visit poster's website Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid 22 Jun 2004, 18:23
fasm uses flat real mode, while you are running in protected mode i quess.
Post 22 Jun 2004, 18:23
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
keyoke



Joined: 18 Jun 2003
Posts: 56
Location: London
keyoke 22 Jun 2004, 18:41
thanks for the reply vid, could you please explain to me exactly what u mean. how can i do it? I just assume that the dos version of fasm would work in dos????
Post 22 Jun 2004, 18:41
View user's profile Send private message Visit poster's website Reply with quote
JohnFound



Joined: 16 Jun 2003
Posts: 3499
Location: Bulgaria
JohnFound 22 Jun 2004, 19:40
Visibly, Bosch BIOS does not have some of the functions of int 15h that FASM uses.
Post 22 Jun 2004, 19:40
View user's profile Send private message Visit poster's website ICQ Number Reply with quote
keyoke



Joined: 18 Jun 2003
Posts: 56
Location: London
keyoke 22 Jun 2004, 19:48
this is what i thought aswell from the log but i admit i have not test fasm for dos 1.52 with vmware but i did test 1.49 with vmware some while ago and it also crashed the whole virtual machine, spose will have to test with vmware but i dont really like using it Sad
Post 22 Jun 2004, 19:48
View user's profile Send private message Visit poster's website Reply with quote
keyoke



Joined: 18 Jun 2003
Posts: 56
Location: London
keyoke 22 Jun 2004, 20:29
ok tried 1.52 with vmware 4.0.1 a error occurs.

from the log!
Quote:

Jun 22 22:22:50: vcpu-0| MONITOR PANIC: NOT IMPLEMENTED F(104):1696 bugNr=12504
Jun 22 22:22:50: vcpu-0| Core dump with build build-5289
Jun 22 22:22:50: vcpu-0| Writing monitor corefile "C:\Documents and Settings\keyoke\My Documents\My Virtual Machines\MS-DOS\vmware-core.gz"
Jun 22 22:22:50: vcpu-0| Setting vaddr to 0
Jun 22 22:22:51: vcpu-0| Writing anonymous pages at pos: 401000
Jun 22 22:22:51: vcpu-0| Msg_Post: Error
Jun 22 22:22:51: vcpu-0| [msg.log.monpanic] *** VMware Workstation internal monitor error ***
Jun 22 22:22:51: vcpu-0| NOT IMPLEMENTED F(104):1696 bugNr=12504
Jun 22 22:22:51: vcpu-0|
Jun 22 22:22:51: vcpu-0| Please report this problem by selecting menu item Help > VMware on the Web > Request Support, or by going to the Web page "http://www.vmware.com/info?id=8&sn=T8T05%2dE6M66%2dF8HFL%2d4KHV0&logFile=C%3a%5cDocuments%20and%20Settings%5ckeyoke%5cMy%20Documents%5cMy%20Virtual%20Machines%5cMS%2dDOS%5cvmware%2elog&coreLocation=C%3a%5cDocuments%20and%20Settings%5ckeyoke%5cMy%20Documents%5cMy%20Virtual%20Machines%5cMS%2dDOS%5cvmware%2dcore%2egz". Please provide us with the log file (C:\Documents and Settings\keyoke\My Documents\My Virtual Machines\MS-DOS\vmware.log) and the core file (C:\Documents and Settings\keyoke\My Documents\My Virtual Machines\MS-DOS\vmware-core.gz).
Jun 22 22:22:51: vcpu-0| [msg.log.monpanic.win32debug] If the problem is repeatable, please select 'Run with debugging information' in the Options panel of the configuration editor. Then reproduce the incident and file it according to the instructions.
Jun 22 22:22:51: vcpu-0| [msg.log.monpanic.finish] We will respond on the basis of your support entitlement.
Jun 22 22:22:51: vcpu-0| We appreciate your feedback,
Jun 22 22:22:51: vcpu-0| -- the VMware Workstation team.
Jun 22 22:22:51: vcpu-0| ----------------------------------------
Jun 22 22:22:51: mks| VTHREAD destroy thread 4 "kbh"
Jun 22 22:24:30: kbh| VTHREAD thread 4 "kbh" host id 1928 started
Jun 22 22:24:30: mks| VTHREAD create thread 4 "kbh"
Jun 22 22:24:30: vcpu-0| Ignoring broadcast request
Jun 22 22:24:30: vcpu-0| VTHREAD thread 4 start exiting
Jun 22 22:24:30: vcpu-0| VTHREAD thread 4 exiting, 6 left
Jun 22 22:24:31: vmx| VTHREAD watched thread 4 "vcpu-0" died
Jun 22 22:24:31: vmx| VTHREAD thread 0 start exiting
Jun 22 22:24:31: vmx| VTHREAD thread 0 exiting, 5 left
Jun 22 22:24:31: mks| VTHREAD watched thread 0 "vmx" died
Jun 22 22:24:31: mks| VTHREAD thread 1 start exiting
Jun 22 22:24:31: mks| VTHREAD destroy thread 4 "kbh"
Jun 22 22:24:31: mks| VTHREAD thread 1 exiting, 0 left

Am i wrong in thinking that the DOS version of fasm 1.52 should run in pure dos mode......or am i right? if not why oh why???? will try it in vmware 4.5.0 see what happens!
Post 22 Jun 2004, 20:29
View user's profile Send private message Visit poster's website Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid 22 Jun 2004, 20:36
i still think you won't run it under some DOS emulator. FASM must be run in REAL MODE (mode in which computer is when turned on), but all newer OSes use PROTECTED MODE. Protected mode tries to emulate real mode for programs that use it, but some things are not possible (this "thing" is called "flat real mode"). And this is used by FASM. By the way, with using EMM386 driver under DOS, your computer is switched to protected mode and FASM won't run too.

I heard some programs even emulate flat real mode, but they are very rare.
Post 22 Jun 2004, 20:36
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
keyoke



Joined: 18 Jun 2003
Posts: 56
Location: London
keyoke 22 Jun 2004, 20:47
Hi vid,
If wat u say is true then it should still work, here is a paragraph from article on vmware
Quote:

Exactly how VMware's VMM is able to handle Real Mode software is a part of the technology they won't discuss publicly. You are probably aware that DOS was a Real Mode OS and Windows 9x/Me was comprised of 16- and 32-bit code that ran mostly in Protected Mode, but also had some Real Mode functionality. Windows 2000 and XP are 32-bit OSs that pretty much run in Protected Mode, and Unix and Linux are Protected Mode OSs. Virtual-86 mode is typically used to run a DOS shell from within Windows. Virtual-86 mode can only support running Real Mode environments and is not related to how VMware VMMs operate. Real, Protected, and Virtual-86 mode software can all run transparently within a VMware Workstation VMM.


Well i spose this is unfortunate for me then Sad would have liked to muck around in old dos 6.22
Post 22 Jun 2004, 20:47
View user's profile Send private message Visit poster's website Reply with quote
pelaillo
Missing in inaction


Joined: 19 Jun 2003
Posts: 878
Location: Colombia
pelaillo 22 Jun 2004, 21:34
Have you tried with com version of fasm?


Description:
Download
Filename: fasm_com.zip
Filesize: 5.56 KB
Downloaded: 1226 Time(s)

Post 22 Jun 2004, 21:34
View user's profile Send private message Yahoo Messenger Reply with quote
keyoke



Joined: 18 Jun 2003
Posts: 56
Location: London
keyoke 22 Jun 2004, 21:49
thnx will try it and see what happens
Post 22 Jun 2004, 21:49
View user's profile Send private message Visit poster's website Reply with quote
f0dder



Joined: 19 Feb 2004
Posts: 3175
Location: Denmark
f0dder 22 Jun 2004, 22:58
Get the Win32 PE console version of fasm, and use stubit.exe from the wdosx extender on it - there's a good chance this will work under bochs and vmware. WDOSX supports a lot of different modes, include raw ring0 pmode, himem.sys mode, emm386 (VCPI) mode, DPMI mode (even under windows), etc...
Post 22 Jun 2004, 22:58
View user's profile Send private message Visit poster's website Reply with quote
keyoke



Joined: 18 Jun 2003
Posts: 56
Location: London
keyoke 23 Jun 2004, 18:44
Thanks f0dder your solution works perfectly
Post 23 Jun 2004, 18:44
View user's profile Send private message Visit poster's website Reply with quote
Tomasz Grysztar



Joined: 16 Jun 2003
Posts: 8357
Location: Kraków, Poland
Tomasz Grysztar 23 Jun 2004, 20:55
The whole problem is because bochs seemingly doesn't emulate 32-bit unREAL mode correctly (this is not the same as flat real mode, and is much more tricky, but works on all Intel and AMD processors, look here for details). You also deal with this problem by disabling use of the unREAL mode in DOS version, so it will always use DPMI if available. But you would still need some DPMI server (I recommend the cwsdpmi) to run it.
Post 23 Jun 2004, 20:55
View user's profile Send private message Visit poster's website Reply with quote
f0dder



Joined: 19 Feb 2004
Posts: 3175
Location: Denmark
f0dder 23 Jun 2004, 22:17
bochs has a lot of bugs (try saying that out loud Wink) - and it's BIOS emulation is lacking. It's doing well for an x86 emulator, and even more well for a GPL project, but it's still lacking. Perhaps CWSDPMI is a better solution than wdosx, but wdosx is useful for a lot of stuff - it was very useful for running NASM/w32 back in the dos days, since the native dos version was 16bit suckyness Smile
Post 23 Jun 2004, 22:17
View user's profile Send private message Visit poster's website Reply with quote
keyoke



Joined: 18 Jun 2003
Posts: 56
Location: London
keyoke 24 Jun 2004, 20:09
thanks guys, I was just confused as to why it was not working. am using vmware now instead of bochs Smile will look into the stuff u mentioned privalov
for the moment it is working tho.
Post 24 Jun 2004, 20:09
View user's profile Send private message Visit poster's website Reply with quote
keyoke



Joined: 18 Jun 2003
Posts: 56
Location: London
keyoke 25 Jun 2004, 08:12
Privalov I have downlowded that dpmi server now but how do i disable unreal mode?
Post 25 Jun 2004, 08:12
View user's profile Send private message Visit poster's website Reply with quote
keyoke



Joined: 18 Jun 2003
Posts: 56
Location: London
keyoke 25 Jun 2004, 08:45
No worries,
i just changed the system.inc line
call modes:real32 to call modes:dpmi and recompiled it works but wont compile anything. was this what u were suggesting.
thanks for the help
Post 25 Jun 2004, 08:45
View user's profile Send private message Visit poster's website Reply with quote
fasm9



Joined: 19 Jun 2003
Posts: 439
fasm9 17 Jul 2004, 10:57
Hi, Have you tried dosemu?
dosemu (stable:1.2.2, devel:1.3.1) supports dpmi, AFAIR. ;)

http://dosemu.sf.net
Post 17 Jul 2004, 10:57
View user's profile Send private message Reply with quote
f0dder



Joined: 19 Feb 2004
Posts: 3175
Location: Denmark
f0dder 17 Jul 2004, 14:12
iirc it's possible to run DOOM in dosemu, so it most likely does support DPMI
Post 17 Jul 2004, 14:12
View user's profile Send private message Visit poster's website Reply with quote
keyoke



Joined: 18 Jun 2003
Posts: 56
Location: London
keyoke 19 Jul 2004, 08:24
Hey guys i Have tried nearly all emulators possible Sad still not working it sucks
Post 19 Jul 2004, 08:24
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  
Goto page 1, 2  Next

< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.