Commit Graph

11660 Commits

Author SHA1 Message Date
Volker Ruppert
1b8c58ed58 Some work on the Voodoo Banshee emulation.
- tile-based VBE graphics updates implemented
- "half mode" support added (line doubling for low resultions)
- change screen resolution only after re-enabling the video processor
2017-10-22 12:16:20 +00:00
Volker Ruppert
26c6c3bfca Moved macros SET_TILE_UPDATED and GET_TILE_UPDATED to vgacore.h to reduce code
duplication.
2017-10-22 10:09:32 +00:00
Stanislav Shwartsman
8261a91ce9 implemented GFNI instructions 2017-10-21 19:57:12 +00:00
Volker Ruppert
35684fa0f5 Started implementing the Voodoo Banshee display adapter based on the existing
"Voodoo VGA" framework. Most of the work is still to do.
- Added Banshee specific PCI write handler and related stuff. The device is
  initialzed properly by the Bochs BIOS (mem, lfb, rom and i/o).
- With Banshee specific VGA BIOS it passes the init stage and boots properly
  to DOS. Parts of the init code coming from file "voodoo.h.txt" (part of the
  original patch).
- Standard VGA modes are all usable (using the Bochs VGA core).
- VBE graphics modes with 8, 16, 24 and 32 BPP are usable (VBE drawing code is
  mostly copy&paste from the Bochs VBE code. DAC 6/8 bit switch is present.
- TODO list:
  - Voodoo Banshee memory layout (registers, 2D, 3D, LFB, textures)
  - 2D graphics engine must be written from scratch
  - interaction between new device and existing 3D core
  - non-VGA mode (Voodoo model "banshee" without VGA extension "voodoo")
  - save/restore support, move Banshee stuff to separate file, ...
2017-10-21 12:46:17 +00:00
Stanislav Shwartsman
e426970f15 updating CHANGES 2017-10-20 19:55:24 +00:00
Stanislav Shwartsman
b7f62a291c fixed compressed displ form for more avx512 instructions 2017-10-20 19:41:32 +00:00
Stanislav Shwartsman
da8d6e793f fixed compilation issues 2017-10-20 19:24:10 +00:00
Stanislav Shwartsman
bca076889b decode all the vbmi2 opcodes, fix vpcompress/vpexpand instruction handler names (affects disasm) 2017-10-20 18:50:10 +00:00
Stanislav Shwartsman
77a62a4dcd implemented (experimental, still untested) AVX512 VBMI2 extensions 2017-10-20 18:38:15 +00:00
Stanislav Shwartsman
0afbb6cd3d fixed compilation when AVX is not configured in 2017-10-20 12:27:42 +00:00
Stanislav Shwartsman
5439647254 small change to extract ia_opcodes.h from instr.h to dedicated file. this would remove compilation dep of all files on ia_opcodes.h (now called ia_opcdes.def). regenerating dep ober all files in Makefiles.in 2017-10-19 21:27:25 +00:00
Stanislav Shwartsman
ba1e5bbffa fixed accidentially broken XMM versions of AES instrructions 2017-10-19 20:25:05 +00:00
Stanislav Shwartsman
15ba88c195 implemented VAES/VPCLMULDQ instructions - VEX/EVEX extensions of AES/PCLMULQDQ 2017-10-19 19:12:55 +00:00
Stanislav Shwartsman
ac442009aa lazy flags code small refactoring 2017-10-15 22:01:32 +00:00
Stanislav Shwartsman
6daa1ba9ba fixed compilation issue with EVEX enabled 2017-10-15 20:40:56 +00:00
Stanislav Shwartsman
944f37b1f2 implemented AVX-512 BITALG instructions/bugfix for VPOPCNT instructions 2017-10-15 20:33:19 +00:00
Stanislav Shwartsman
0d190eec8e implemented AVX-512 VNNI instructions 2017-10-15 19:17:07 +00:00
Stanislav Shwartsman
4179e6f939 add some const 2017-10-14 18:42:12 +00:00
Volker Ruppert
184324c8e8 Some small fixes in the display adapters code.
- Fixed missing bx_gui->flush() call after non-VGA update().
- Fixed a BX_DEBUG message in the Voodoo code.
- Re-define LOG_THIS for messages in the "Voodoo VGA" code.
2017-10-14 11:15:00 +00:00
Stanislav Shwartsman
69f27439db added new cpuid flags mentioned in new Intel SDM future extensions rev030 doc 2017-10-13 20:27:52 +00:00
Volker Ruppert
2b91dabfe5 Added new VGA extension choice "voodoo" to test the new VGA extension code. It
currently only implements an ISA standard VGA adapter with the selected Voodoo
model as it's extension. The methods of the "Voodoo VGA" device only call the
required methods of the Voodoo or VGA core.
TODO: Start implementing the Voodoo Banshee chipset based on this code.
2017-10-12 19:34:58 +00:00
Volker Ruppert
5ec78eaae2 Modified VGA extension init method. Now it returns 1 if the extension code has
initialized the VGA compatible video memory. If it has returned 0 the VGA core
code sets up the default VGA memory (256k).
2017-10-12 19:18:23 +00:00
Volker Ruppert
d25e85c21a Preparing improved VGA extension support and some VGA / Cirrus cleanups.
- Treat VGA extension name other than "none", "vbe" or "cirrus" as a VGA
  compatible device plugin and try to load it.
- Added new plugin type PLUGTYPE_VGA for such a plugins (interally handled like
  a core plugin).
- Added panic in devices init for the case no VGA compatible plugin is present.
- Added new method vga_redraw_area() that handles the non-VGA and null size
  case. The specific method redraw_area() is called otherwise.
- Moved init_systemtimer() call from extension code to init_standard_vga().
- TODO: Implement VGA subsystem in the Voodoo code to test the new feature.
  Voodoo Banshee 2D accelerator code needs to be written to make this really
  useful.
2017-10-10 18:06:16 +00:00
Volker Ruppert
6dba96d10a Some changes related to the PCI ROM handling.
- Added support for setting memory write handler to NULL (ROM case).
- Added new PCI device method after_restore_pci_state(). It currently handles
  the PCI ROM case only (could be extended).
2017-10-08 15:54:21 +00:00
Volker Ruppert
610cec209d Rewrite of the VGA/Cirrus code to reduce code duplication.
- Moved VGA timer handler to the VGA core and handle the non-VGA case there.
  It calls the specific update() code and finally bx_gui->flush().
- Moved the VGA update frequency parameter handler and the refresh_disply()
  method to the VGA core.
- Store the VGA extension parameter in the VGA core.
- Voodoo: Fixed graphics snapshot.
2017-10-08 07:55:04 +00:00
Volker Ruppert
ebbd952d3b Code cleananup: Since the Cirrus plugin device is only loaded in case the
VGA extension "cirrus" is selected, there is no need to check this parameter.
TODO: Implement new VGA extensions (e.g. Voodoo Banshee, Voodoo3).
2017-10-07 08:49:05 +00:00
Volker Ruppert
f31d062854 Added SDL / SDL2 specific multi-threading support. If one of these guis is
enabled, the portable code is used instead of the pthread or win32 one.
2017-09-16 22:01:49 +00:00
Volker Ruppert
0311f47bc3 Moved all Bochs event / wait functions required for multi-threading to a new
file called "bxthread.cc".
2017-09-14 16:18:12 +00:00
Volker Ruppert
2a47615bb6 Started updating changes after release 2.6.9. 2017-09-12 17:48:43 +00:00
Volker Ruppert
c889fcae87 Some improvements in the Voodoo2 CMDFIFO code.
TODO: Check whether or not there are still simulation freezes caused by CMDFIFO.
2017-09-12 16:29:02 +00:00
Volker Ruppert
245ccf1037 Added symbols to fix MSVC plugins compilation. 2017-09-10 19:16:02 +00:00
Volker Ruppert
b61b9d255a Moved all Bochs multi-threading definitions from bochs.h and osdep.h to a new
file called "bxthread.h".
2017-09-10 15:55:13 +00:00
Volker Ruppert
ad9f1c3417 Moved event / wait stuff from the Voodoo code to osdep.cc fot the usage in
other parts of Bochs.
2017-09-10 06:50:07 +00:00
Volker Ruppert
da48346f9d Implemented combined PCI / memory FIFO. This is required for running Voodoo1
games / demos correctly on the Voodoo2 model. I noticed a small slowdown
(2 or 3 percent) on the Voodoo1.
2017-09-08 16:17:20 +00:00
Volker Ruppert
c1d5947a80 Memory FIFO fix: 16-bit write support for the FBI video memory was missing. 2017-09-03 20:51:37 +00:00
Volker Ruppert
e063d282ac Voodoo2 CMDFIFO fix and cleanup.
- Fixed probing the CMDFIFO with Voodoo output disabled (send FIFO wakeup
  directly, otherwise driven by vertical retrace).
- Use the CMDFIFO member 'enabled' instead of reading the fbiInit7 register bit.
- TODO: The Voodoo2 freeze when testing a Voodoo1 demo is still not fixed.
2017-09-03 17:32:49 +00:00
Stanislav Shwartsman
ec6281a828 remove include which is not needed 2017-09-03 11:43:30 +00:00
Stanislav Shwartsman
3148cdd683 fixed compilation under VS2013 2017-09-03 11:42:27 +00:00
Volker Ruppert
7c3dafc7f5 Some Voodoo emulation fixes.
- voodoo_init() must be called after initializing FIFO mutex.
- The 'op_pending' counter must be reset after resetting FIFOs.
- Fixed an MSVC warning and removed obsolete comment.
- FIXME: There are still some conditions that can freeze the Voodoo display.
2017-09-03 08:28:16 +00:00
Volker Ruppert
1f85292418 Implemented memory FIFO to speed up the Voodoo1 emulation. The PCI FIFO with
it's 64 entries is still not present, since it makes the emulation a few
percent slower due to the overhead of the FIFO code. The memory FIFO has 64k
entries and makes a speedup of around 75 % possible.
2017-09-01 17:30:49 +00:00
Volker Ruppert
ea8bfca53f Two USB modifications requested by Ben Lunt.
- usb_msd.cc: The Device Qualifier is valid for high speed devices only.
- uhci_core.cc: Don't report BX_DEBUG message if the current TD belongs to an
  async operation that is still not complete.
2017-08-26 08:10:21 +00:00
Volker Ruppert
bd40347963 Store FIFO presence in variable "enabled" and report the state change of the
currently unimplemented FIFOs.
2017-08-24 21:08:21 +00:00
Stanislav Shwartsman
2d3d62db5f cleaned cr2 print in 32-bit mode 2017-08-22 21:14:39 +00:00
Stanislav Shwartsman
2a55ba0a39 Merge set of debugger improvements by Doug Gale <doug16k>
Here is his original comment:

I have made several improvements in the debugger.
I have fixed several issues with proper handling of 64-bit addresses, and added support for 64 bit symbols.
I also have added several symbol lookups.
2017-08-22 21:03:58 +00:00
Stanislav Shwartsman
f490b00beb added support for conditional breakpoints in Bochs debugger 2017-08-22 18:47:18 +00:00
Volker Ruppert
680189a548 Fixed Voodoo pixel clock calculation.
- Now using float type for the 'clk0_freq' variable.
- DAC register 6 can switch to half pixel clock (ported from PCem).
- Writing value 0xf8 to PLL register 0x0e completes clock #0 setup.
2017-08-21 19:33:29 +00:00
Volker Ruppert
4e80e2fbfc Started preparing the Voodoo code for the PCI FIFO / memory FIFO implementation.
- Initialize the thread and event stuff for both Voodoo models.
- Rewrite of the event handling code to manage different events.
2017-08-20 20:25:45 +00:00
Volker Ruppert
e187f3907a Removed Voodoo realtime option. Since the gui screen update timing is now
controlled by the 'vga' option and Voodoo2 CMDFIFO thread has the best
performance with realtime mode disabled, this option is now obsolete.
2017-08-18 15:19:30 +00:00
Volker Ruppert
9a1668ac36 First version of the Voodoo2 CMDFIFO thread using "pthread cond" code on
non-WIN32 platforms instead of BX_MSLEEP(). The donut demo is once again a
little bit slower, but on other tests the IPS values are still okay. Cleaned
up the code a little bit and added save/restore stuff for the new code.
2017-08-17 19:15:02 +00:00
Volker Ruppert
6361386e8b Reverted BX_LOCK/BX_UNLOCK changes from previous commit (don't lock CMDFIFO
completely while running cmdfifo_process()). The donut demo is now a little bit
slower on Linux host, but other test cases are faster again.
2017-08-17 17:15:12 +00:00