Guru Meditation while running a Turbo Pascal 6 program in PC DOS 2000

Discussions about using non Windows and Linux guests such as FreeBSD, DOS, OS/2, OpenBSD, etc.
Post Reply
cloggie
Posts: 4
Joined: 7. Feb 2012, 18:44
Primary OS: MS Windows 7
VBox Version: PUEL
Guest OSses: Windows XP, PC DOS
Location: Vilnius, Lithuania
Contact:

Guru Meditation while running a Turbo Pascal 6 program in PC DOS 2000

Post by cloggie »

The title says it all. Attached is a zipped log/png.

Essential(?) info:

Code: Select all

00:00:10.908573 VMMDev: Guest Log: BIOS: KBD: unsupported int 16h function 6f
00:00:10.908812 VMMDev: Guest Log: BIOS: AX=6f00 BX=0000 CX=0000 DX=0021 
00:04:35.083019 Changing the VM state from 'RUNNING' to 'GURU_MEDITATION'
00:04:35.083037 Console: Machine state changed to 'GuruMeditation'
I will investigate further, but size-wise program doesn't run within the TP6 IDE, and right now I cannot find my copy of TD286, Borland's protected mode debugger, which may help me further.
Attachments
VBox.zip
Zipped up log+png
(51.38 KiB) Downloaded 16 times
Robert AH Prins
robert.ah.prins @ the.17+Gb.Google thingy
fth0
Volunteer
Posts: 5661
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: Guru Meditation while running a Turbo Pascal 6 program in PC DOS 2000

Post by fth0 »

VBox.log file wrote:
00:04:35.083389 Guest CPUM (VCPU 0) state: 
00:04:35.083393 eax=38310000 ebx=00000fd4 ecx=07cb0000 edx=000001f7 esi=000026e0 edi=0000005e
00:04:35.083395 eip=00000d43 esp=0000fff8 ebp=00000004 iopl=3      rf nv up di pl zr ac pe nc
00:04:35.083397 cs={0048 base=0000000000146400 limit=0000ffff flags=0000009b} dr0=00000000 dr1=00000000
00:04:35.083399 ds={0080 base=0000000000000000 limit=ffffffff flags=0000c093} dr2=00000000 dr3=00000000
00:04:35.083400 es={0050 base=000000000014cfe0 limit=0000ffff flags=00000093} dr4=00000000 dr5=00000000
00:04:35.083402 fs={0000 base=0000000000000000 limit=ffffffff flags=0001c000} dr6=ffff0ff0 dr7=00000400
00:04:35.083404 gs={0000 base=0000000000000000 limit=ffffffff flags=0001c000} cr0=80000011 cr2=00000000
00:04:35.083405 ss={0058 base=000000000014fd80 limit=00000fff flags=00000093} cr3=00118000 cr4=00000000
[...]
00:04:35.083540 CPUM0: 0048:00000d43 66 50                   push eax
[...]
00:04:35.086195 Guest GDT (GCAddr=0000000000151580 limit=177):
00:04:35.086214 0058 - fd800fff 00009314 - base=0014fd80 limit=00000fff dpl=0 DataRW Accessed Present 16-bit
There seems to be a disagreement about the current stack size. ;)
mpack
Site Moderator
Posts: 39156
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: Guru Meditation while running a Turbo Pascal 6 program in PC DOS 2000

Post by mpack »

Addressing beyond the limit for SS:SP would cause a guest crash, but I don't know why it would cause a host triple fault guru meditation, especially when VT-x is in use.

That said, the configured limit for SS seems a bit weird to me, so it could just be because somebody did something unexpected. I would have expected the limit on the stack segment to be 0xFFFF. Side note: it's a long time since I programmed for DOS, but I don't remember there being any limit except what you could hold in the 16 bit offset register. I assume the limits I'm seeing only exist in the memory management portions of later processors.
fth0
Volunteer
Posts: 5661
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: Guru Meditation while running a Turbo Pascal 6 program in PC DOS 2000

Post by fth0 »

mpack wrote:Addressing beyond the limit for SS:SP would cause a guest crash, but I don't know why it would cause a host triple fault guru meditation, especially when VT-x is in use.
I can only make an educated guess about that: The push to the offset just below 64k (presumably onto an empty 64k stack) will generate a GPF (General Protection Fault) inside the guest because of the 4k segment limit. Additionally, the guest IDT (Interrupt Descriptor Table) is located right behind the 4k stack segment. I don't see a clean way for a GPF exception handler to solve this, except for an emergency stop. Note that a triple fault guru meditation does not necessarily mean that there has been a triple fault inside the guest.
mpack wrote:Side note: it's a long time since I programmed for DOS, but I don't remember there being any limit except what you could hold in the 16 bit offset register. I assume the limits I'm seeing only exist in the memory management portions of later processors.
Depends on what you call "later". :) The GDT (Global Descriptor Table) is a central structure of the 16-bit and 32-bit Protected Mode (see the Segment addressing section of this Wikipedia page for details), starting from the Intel 80286 CPU.
Post Reply