Commit Graph

53 Commits

Author SHA1 Message Date
Jonathan Campbell
c487bdd002 cleanup 2025-01-23 17:20:00 -08:00
Jonathan Campbell
4e21a21b39 Paging cleanup 2025-01-22 12:04:20 -08:00
Jonathan Campbell
2296d2f4fc Paging cleanup 2025-01-22 11:39:38 -08:00
Jonathan Campbell
4c0f6171c0 Paging define TLB entry data type and bit masks as bit positions for future cleanup. Some of the paging fields do not need to be Bitu, they only need 32 bits 2025-01-22 00:16:12 -08:00
Jonathan Campbell
1bf0296976 Paging: HostRead/HostWrite method parameter should be 32-bit page frame number, not Bitu 2025-01-18 13:28:45 -08:00
Jonathan Campbell
588f195328 PAGING: Cleanup, remove non-USE_FULL_TLB code 2025-01-18 13:07:31 -08:00
Jonathan Campbell
40bf81d6b9 Begin SVGA vmemdelay 2024-12-29 09:57:22 -08:00
Jonathan Campbell
a8a2d648ea Expand paging to the logical maximum, 40-bit PSE. That is as far as we will go. Any further expansion would require Paging TLBs to become 64-bit entries and by that point you should probably use VirtualBox or QEMU to run your mega-gigabyte possibly terabyte VM anyway. 2024-12-24 22:55:00 -08:00
Jonathan Campbell
fcd3d77e6a Begin some conversion of the code to clarify which memory addresses are linear, and which are physical, and add some explanation 2024-12-24 22:47:28 -08:00
Jonathan Campbell
dfcdf78581 Paging: constant move to header, describe functions a bit 2024-12-24 21:12:54 -08:00
Jonathan Campbell
946dc5c97c If debug mode is going to complain about "Illegal read/write" outside the bounds of system memory, at least show the physical memory address alongside the linear address to make the debug message more useful 2024-12-16 07:36:05 -08:00
Jonathan Campbell
887d29ac4a Paging: Define struct for 4MB PSE PDT page 2024-12-15 09:56:53 -08:00
Jonathan Campbell
dcdbbefa35 PDE code in paging.cpp should use dirblock, not block 2024-12-15 09:41:43 -08:00
Jonathan Campbell
cd46a30edf Some code cleanup in paging.cpp. Add separate struct definition for PDE vs PTE. Add notes regarding D (Dirty) bit in PDEs on Pentium and higher CPUs. It seems while 386/486 defined a D bit for PTE and PDE, the Pentium gave up on the D bit for PDE, though for PSE 4MB pages the PDE still has a D bit. 2024-12-15 09:38:06 -08:00
Jonathan Campbell
a3d5073a2b Begin work on PSE (Page Size Extension) emulation. Limit the enable only to Pentium or higher. Reportedly Intel added it to the original Pentium but did not document it until the Pentium Pro or Pentium II 2024-12-15 08:51:31 -08:00
Jaak Ristioja
39906a9399 Add override keyword, clean up virtual keyword
Also removed virtual and override keywords from destructors which already
override.
2024-03-21 21:45:16 +02:00
RainRat
902ce67fad fix typos 2024-02-28 19:08:20 -08:00
Allofich
1e28b87fa8 Put #include statements before any code
Untangle the output .h file #include statements from sdlmain.h
2023-04-05 21:10:33 +09:00
Allofich
9970fbb1be Use class initialization and initialization lists 2023-04-05 15:10:00 +09:00
Allofich
4d7be1c15b Remove redundant #ifndef conditionals for includes 2021-08-22 15:13:27 +09:00
Allofich
fea9f20adf Remove unneeded includes 2021-06-09 11:11:04 +09:00
Allofich
67ebe980a7 Remove unneeded includes 2021-06-06 04:39:54 +09:00
Jonathan Campbell
39a31f2ba7 CPU normal core: Add segment limit check exception handling to MOVSB, MOVSW, MOVSD, and make it throw a C++ exception while restoring CPU state properly. This should fix any glitches the previous hackery caused and help resolve crashes. It should also resolve any rendering errors in Windows 3.1 if using the S3 86C928 driver, which uses segment limit exceptions to fake a linear framebuffer from hardware that can only bank switch 2021-04-14 16:41:44 -07:00
Allofich
9294d450ec SVN r4412
Update copyright.
2021-03-06 21:18:08 +09:00
Wengier
39cea90974 re-add dynamic x86 core 2020-10-12 02:17:44 -04:00
Emmanuel Gil Peyrot
c0a106535e Replace Bit32u with uint32_t 2020-09-28 17:14:35 +02:00
Emmanuel Gil Peyrot
a431d81213 Replace Bit16u with uint16_t 2020-09-28 17:14:35 +02:00
Emmanuel Gil Peyrot
35f38f3ebe Replace Bit8u with uint8_t 2020-09-28 17:14:35 +02:00
rderooy
608a657b50 Update copyright year for dosbox and dosbox-x assets and update FSF address 2020-06-25 08:42:32 +02:00
Allofich
038566362e Fix Cppcheck funcArgNamesDifferent warnings 2019-10-21 22:08:39 +09:00
Jonathan Campbell
1972872e82 GCC -Wsign-conversion fixes 2019-07-20 01:46:30 -07:00
Allofich
1870426f8b Revert SVN r4206 2019-06-18 22:21:38 +09:00
Jonathan Campbell
13646fc615 Merge pull request #1141 from Allofich/warnings3
Cleanup
2019-06-15 08:53:57 -07:00
Allofich
8598f90386 Remove undefined function declarations 2019-06-15 20:13:21 +09:00
Allofich
62fed560b4 Fix uninitialized variable warnings
Also fix a NULL dereference warning
2019-06-14 22:40:22 +09:00
Allofich
15338b598d SVN r4206
Store whether generated code is 16- or 32-bit, so this information can be
used when checking for self-modifying code. Some code is identical
except for being 32- or 16-bit. Fixes some hard to reproduce problems
with small codeblocks.
2019-06-08 18:12:09 +09:00
Allofich
d4f43f6e1b SVN r4185
Make WORDS_BIGENDIAN check consistent, include right header for memset,
correct one-off error in paging table size compare for when not using
USE_FULL_TLB
2019-06-03 23:50:45 +09:00
Allofich
d84a812743 SVN r4183 (second half)
Update year
2019-06-03 23:01:41 +09:00
Allofich
05619dd023 SVN r4183 (first half)
Update address of FSF
2019-06-03 22:54:46 +09:00
Jonathan Campbell
83607f52fd #if 0 out the deprecation hack, in case VS2017 or CLANG/LLVM does not like it. It can be reenabled if needed. GCC likes it anyway. 2019-06-02 18:53:26 -07:00
Jonathan Campbell
33329bb414 Resolve any function prototype failure to update by changing the page handler class so the older function prototype causes a compiler error 2019-06-02 18:49:47 -07:00
Jonathan Campbell
de8f8a17b0 Reapply Allofich page handler typecast change, the problem was that the S3 MMIO page handler had not been updated with the new virtual method function prototype 2019-06-02 18:41:15 -07:00
Jonathan Campbell
9d1c3d2c33 Revert part of Allofich's typecast fixes concerning memory handling because for yet unknown reasons it breaks the Windows 3.1 S3 SVGA driver and S3 emulation. Reverted changes are preserved as a patch file 2019-06-02 09:50:27 -07:00
Allofich
402a9f4af7 Fix value conversion warnings 2019-06-02 11:08:33 +09:00
Jonathan Campbell
fa96598cf2 more 2018-05-25 08:54:15 -07:00
Jonathan Campbell
e9046eb2f5 more cleanup 2018-05-25 08:42:08 -07:00
Jonathan Campbell
781d5d50cc cleanup: ignored const type qualifier 2018-05-21 11:37:48 -07:00
Jonathan Campbell
96e0652c80 Remove enable flag entirely 2018-03-02 15:18:57 -08:00
Jonathan Campbell
36f127d4a0 mem page callback, start the code 2017-05-06 14:41:43 -07:00
Jonathan Campbell
ffbad0b2b3 svn mainline r3878:
Year update.
2015-01-25 21:13:25 -08:00