Re: VGA emulation in BOCHS
Volker Ruppert <[email protected]>
| Newsgroups | gmane.comp.emulators.bochs.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi! > I am looking at how BOCHS emulates VGA. it seems to be that VGA memory > is within a fixed memory range and different processors can write to > the memory using PIO or MMIO. when the countDownEvent is called. The > current states in the VGA buffer is updated to the X window through > xcblib APIs. I have 2 questions. > 1. what sets up the fixed memory region for VGA ? The BIOS ? The VGA memory regions are defined in the PC standard and the VGA init code registers the memory handlers for it. That's all in the ISA case and with no extension enabled. In the PCI case and with Bochs VBE or Cirrus extension the PCI BIOS initializes the bases address regions for RAM and ROM. In this case these PC standard compatible regions are also present: A0000 - AFFFF EGA/VGA graphics window B0000 - B7FFF Monochrome text mode B8000 - BFFFF CGA graphics and color text mode C0000 Start address of the VGA BIOS ROM > 2. Is the update to x windows only invoked from the vga update > function which is called by countDownEvent ? The display adapter code registers a virtual timer und the timer function executes the update code for the display library (gui). In earlier versions of Bochs there was a parameter 'vga_update_interval' and a standard timer (in pc_system.cc) was initialized with it's value. Now we are using the bochsrc option 'vga: update_freq' to set up the screen update timing and the timer value is calculated internally. In addition to this we are using a virtual timer that calls the screen updates with realtime frequency if the option 'clock: sync=realtime' is used. I'd like to use always realtime for the VGA screen updates, but I haven't managed to rewrite the virtual timer code yet. -- Volker ------------------------------------------------------------------------------ Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_sfd2d_oct