Commit Graph

3219 Commits

Author SHA1 Message Date
Stanislav Shwartsman
f76b972fed bugfix in call gate handling from call far instruction - found with rdos 2015-09-02 19:14:47 +00:00
Stanislav Shwartsman
250cf02981 x86-64: Fixed bug in OR_EqGqM handler used with FS or GS segment 2015-07-26 19:20:21 +00:00
Stanislav Shwartsman
f6af0443bb small optimization and elimination of several defines from cpu.h - replace by inline functions and const variables 2015-07-13 20:24:14 +00:00
Stanislav Shwartsman
ea255b5bf7 fixed VMCS memory type calculation 2015-07-12 20:10:43 +00:00
Stanislav Shwartsman
129db3bfaf fixed typo in the list of the vmcs exits 2015-07-12 15:26:34 +00:00
Stanislav Shwartsman
9315742f3d cleanups of vmcs mapping related stuff 2015-07-07 21:06:56 +00:00
Stanislav Shwartsman
e9f9f824be return value from clear/set_mapping functions 2015-07-06 20:16:34 +00:00
Stanislav Shwartsman
28c19ecec7 more interfaces to VMCS Mapping class 2015-07-06 20:14:56 +00:00
Stanislav Shwartsman
5fe1423ab6 introducr new class for VMCS mapping so it can be customized per cpuid 2015-07-06 18:46:57 +00:00
Stanislav Shwartsman
b86f01d410 update TODO 2015-06-29 19:57:04 +00:00
Stanislav Shwartsman
3fef7f32f6 added new bits definitions recently published 2015-06-29 19:53:56 +00:00
Stanislav Shwartsman
bc25883087 add new definitions from most recent AMD Software Developers Manual update. TODO: implement new AMD's MONITORX/MWAITX extensions 2015-06-22 21:46:50 +00:00
Stanislav Shwartsman
91086d0627 remove not relevant comments 2015-06-14 20:36:16 +00:00
Stanislav Shwartsman
3a0dff9b36 fixed Bochs compiled for 386 with FPU enabled 2015-06-10 20:36:46 +00:00
Stanislav Shwartsman
c43ea147bf ~1% emulation speedup by skipping pageWriteStamp check for stack writes.
For now the optimization is supported only when no SMP is compiled in because it doesn't handle cross-modifying code.

The current stack page will cache also current pageWriteStamp for that page and could skip pageWriteStamp access if possible.
Any code fetch access missing trace cache will invalidate current stack page.
Code fetch accesses from another SMP threads should do the same to support SMP.

Next step:
 - support SMP
 - support pageWriteStamp access skipping for all other memory writes from all segments
2015-05-23 19:34:59 +00:00
Stanislav Shwartsman
745d843c88 change BX_INFO message to BX_DEBUG because it floods log 2015-05-19 20:21:17 +00:00
Stanislav Shwartsman
280a773323 fix vmexit qualification for some instructions after previous code reorg and inlining of resolve_modrm methods 2015-05-16 21:25:43 +00:00
Stanislav Shwartsman
b468316250 re-style old resolve macros after resolve function inlining 2015-05-16 21:06:59 +00:00
Stanislav Shwartsman
29585cae72 delete resolver.cc 2015-05-16 20:30:26 +00:00
Stanislav Shwartsman
f0d7379908 remove BxResolveModrm member in BxInstruction_c class and inline resolve functions into instruction handlers instead. helps to remove indirect branch mispredictions (suggested by Vtune). measured speedup on Win7-64 boot is 5%, on other guests it might vary between 1% and 5% 2015-05-16 20:29:49 +00:00
Stanislav Shwartsman
cf4b3f2542 optimize code duplication 2015-05-12 21:33:06 +00:00
Stanislav Shwartsman
9f18573740 Rename BX_CPU_CALL_METHODR to BX_CPU_RESOLVE_ADDR and introduce special cases BX_CPU_RESOLVE_ADDR_64 (for 64-bit mode only) and BX_CPU_RESOLVE_ADDR_32 (for 32-bit mode only) 2015-05-11 19:23:09 +00:00
Stanislav Shwartsman
b9b45f0d0d convert some defines to typed consts 2015-05-10 19:54:57 +00:00
Stanislav Shwartsman
0d79c5f986 Implemented Page Modification Logging VMX feature 2015-05-06 19:55:44 +00:00
Stanislav Shwartsman
2185d21eb7 fixed comments for PML acronym 2015-05-05 19:52:05 +00:00
Stanislav Shwartsman
a197977682 fixed typo 2015-05-05 19:37:01 +00:00
Stanislav Shwartsman
c9fba73a69 added defines about new VMX bits and controls related to Page Miss Logging (PML) EPT feature 2015-05-05 19:35:39 +00:00
Stanislav Shwartsman
16ab385e1d added cpuid/creg bits definition announced in recent 054 update of Intel SDM 2015-05-05 19:28:25 +00:00
Stanislav Shwartsman
5edd53186e optimize for target with no x86-64 support 2015-05-04 19:58:01 +00:00
Stanislav Shwartsman
28fc5083af remove the victim cache code to resolve assert in proc_ctrl.cc 2015-05-04 19:47:52 +00:00
Stanislav Shwartsman
4c34b97db1 fixed comment 2015-05-03 19:44:24 +00:00
Stanislav Shwartsman
5ef56d6d79 rename fpu function 2015-05-02 20:08:36 +00:00
Stanislav Shwartsman
4c7a05621c reorg of code managing MXCSR to softfloat status conversion 2015-05-02 19:54:48 +00:00
Stanislav Shwartsman
9be2f07d54 fix compilation err when SVM is enabled 2015-04-21 08:20:28 +00:00
Stanislav Shwartsman
e72f66ce49 added BX_CPP_AttrRegparmN to xmm/ymmz/zmm read methods matching cpu.h 2015-04-19 20:47:55 +00:00
Stanislav Shwartsman
239b1ae684 added missed vmexit reason to debug print 2015-04-18 19:25:58 +00:00
Stanislav Shwartsman
080ceb8293 don't crash when running on 386 with no FPU model 2015-03-27 21:39:24 +00:00
Stanislav Shwartsman
c360ddf60c correctly report memory type for EPT page table accesses
TODO: support memory type for guest physical access under EPT
TODO: support memory type for SVM nested paging 
TODO: check what happens when PAT is not enabled in CPU configuration
2015-03-23 20:27:36 +00:00
Stanislav Shwartsman
05635a9534 call correctly resolve_memtype function 2015-03-21 20:28:22 +00:00
Stanislav Shwartsman
56323b2806 bugfixes 2015-03-21 20:15:57 +00:00
Stanislav Shwartsman
a55c5e4eb8 correctly report memory type for page table accesses in x86 mode (not in EPT or SVM nested paging yet)
TODO: support memory type with EPT / nested paging
TODO: check what happens when PAT is not enabled in CPU configuration
2015-03-21 20:08:58 +00:00
Stanislav Shwartsman
e79185b0a0 refactor memtype methods 2015-03-02 20:51:59 +00:00
Stanislav Shwartsman
36f7bf0ba6 fixed ept memtype printout 2015-03-01 21:04:34 +00:00
Stanislav Shwartsman
8134dc67af supporting memory type provided by page tables with PCD,PWT and PAT bits
TODO: support memory type with EPT
TODO: support memory type for intermediate page table accesses
TODO: check what happens when PAT is not enabled in CPU configuration
2015-03-01 20:55:23 +00:00
Stanislav Shwartsman
9932384df3 fixed visual studio warning 2015-03-01 19:44:06 +00:00
Stanislav Shwartsman
53041981f7 supply PAT required memory type bits through new combined access interface 2015-02-28 14:06:04 +00:00
Stanislav Shwartsman
25b02dac4b code reorg before PAT memory type support 2015-02-28 14:01:11 +00:00
Stanislav Shwartsman
b74036d2d8 another try to fix the weird compilation error 2015-02-26 20:34:24 +00:00
Stanislav Shwartsman
4e859202a1 attemp to fix compilation issue 2015-02-25 19:43:47 +00:00
Stanislav Shwartsman
1e1c893041 introduce new 64bit packed register type and implement pat/mtrr and mmx registers through it 2015-02-23 21:17:33 +00:00