Stanislav Shwartsman
cb43e52240
asize mask
2010-12-25 19:46:07 +00:00
Stanislav Shwartsman
f705cbbc63
rename functions
2010-12-25 19:34:43 +00:00
Stanislav Shwartsman
1bd512e98d
split more SSE ops, optimizations in MMX code
2010-12-25 17:04:36 +00:00
Stanislav Shwartsman
d0ee1c1b80
Fixed for compilation with cpu-level=3
2010-12-25 15:00:20 +00:00
Stanislav Shwartsman
c005444d5b
split more SSE opcodes
2010-12-25 07:59:15 +00:00
Stanislav Shwartsman
fee7a91d86
Fixed compilation with cpu-level=3
2010-12-24 16:34:55 +00:00
Stanislav Shwartsman
040a8e1a3a
split bunch of SSE opcodes
2010-12-24 08:35:00 +00:00
Stanislav Shwartsman
709059ddcc
integrate misaligned SSE into code
2010-12-22 21:24:19 +00:00
Stanislav Shwartsman
43600f3756
complete rework of SSE code
...
next step - split all SSE opcodes by ModC0
2010-12-22 21:16:02 +00:00
Stanislav Shwartsman
a63b9900a7
optimization
2010-12-19 22:50:28 +00:00
Stanislav Shwartsman
29a674e520
split rd/wr CR opcodes for simplicity
2010-12-19 22:36:19 +00:00
Stanislav Shwartsman
c7017b1c05
simplification
2010-12-19 21:41:15 +00:00
Stanislav Shwartsman
f2355a8249
Fixed FXSAVE/FXRSTOR exceptions order
2010-12-19 21:07:46 +00:00
Stanislav Shwartsman
4a85a8680e
SSE optimization
2010-12-19 07:06:40 +00:00
Stanislav Shwartsman
48d94d6dc3
optimization
2010-12-18 11:58:16 +00:00
Stanislav Shwartsman
1047acb2cc
rename SSE register param - prepare for wide SSE register (AVX)
2010-12-06 21:52:41 +00:00
Stanislav Shwartsman
d60b7c0919
rename accessor for opcodeReg() in instruction
2010-12-06 21:45:56 +00:00
Stanislav Shwartsman
dab658f136
update with AMD CPUID spec from sep2010
2010-11-27 20:20:32 +00:00
Stanislav Shwartsman
4a8d69caf6
bugfix for x86-64 mode
2010-11-23 15:42:26 +00:00
Stanislav Shwartsman
9aa503cb9d
fixed warnings for win64 compilation
2010-11-23 14:59:36 +00:00
Stanislav Shwartsman
d011594114
Added option to disable MWAIT using .bochsrc
2010-11-21 12:02:12 +00:00
Stanislav Shwartsman
4feda0c3fe
compilation fix w/o vmx
2010-11-19 08:39:52 +00:00
Stanislav Shwartsman
8c45aa2454
fixed buffer overflow in perv commit
2010-11-13 09:18:16 +00:00
Stanislav Shwartsman
36291b0b1d
accessor to upper part of 64-bit reg
2010-11-12 20:46:59 +00:00
Stanislav Shwartsman
c676875421
vmcs read/write check
2010-11-12 20:26:01 +00:00
Stanislav Shwartsman
e6981218dc
next step for fully configurable CPU + more optimal VMX execution
...
- check at startup time which VMX fields are accessible
- next step: simplify VMREAD and VMWRITE instructions - eliminate switch statements
2010-11-11 21:41:03 +00:00
Stanislav Shwartsman
a6d2047f4d
dos2unix
2010-11-11 17:09:13 +00:00
Stanislav Shwartsman
93cc615a40
moved vmcs stuff to separate file
2010-11-11 16:25:45 +00:00
Stanislav Shwartsman
49c85b07f6
Fixed address size wrap
2010-10-18 22:19:45 +00:00
Stanislav Shwartsman
5ea2591cd9
fixes
2010-10-07 20:40:01 +00:00
Stanislav Shwartsman
13e2b6eba1
added new file
2010-10-07 16:40:00 +00:00
Stanislav Shwartsman
6d089dd238
changed CPUID constants to defines
2010-10-07 16:39:31 +00:00
Stanislav Shwartsman
e3431a98e6
Bugfix for 32-bit shift/rotate in 64-bit mode
2010-10-01 09:13:21 +00:00
Stanislav Shwartsman
dcc11e1b85
naming change
2010-09-28 14:18:58 +00:00
Stanislav Shwartsman
f2a87171c1
Fixed BX_INSTR_OPCODE callback, now its implementation closer to original definition.
...
New, updated definition of the callback:
void bx_instr_opcode(unsigned cpu, const Bit8u *opcode, unsigned len, bx_bool is32, bx_bool is64);
The callback is called each time, when Bochs completes to decode a new
instruction. Through this callback function Bochs could provide an opcode of
the instruction, opcode length and an execution mode (16/32/64).
Please note, that Bochs uses translation caches so each simulated instruction
might be executed multiple times but decoded only once.
2010-09-27 15:29:36 +00:00
Stanislav Shwartsman
9ed116ada7
avoid similar issues (like it was in mmx.cc) in future
2010-09-26 20:35:24 +00:00
Stanislav Shwartsman
471d33fc1d
fix BE issue
2010-09-26 20:20:27 +00:00
Stanislav Shwartsman
f655e33779
imm mode2 could be only with imm_mode1
2010-09-25 10:17:04 +00:00
Stanislav Shwartsman
75f2ae9c18
fetchdecode simplification rework
2010-09-25 09:55:40 +00:00
Stanislav Shwartsman
8308a47168
trying to get rid of b1() in instruction class
2010-09-24 21:15:16 +00:00
Stanislav Shwartsman
369aba757d
style change
2010-09-23 20:38:02 +00:00
Stanislav Shwartsman
e0fcc80ec3
introduce bswap functions, big endian fix for CPUID
2010-09-20 20:43:16 +00:00
Stanislav Shwartsman
a0705392d3
Fixed failure on BE hosts
2010-09-12 17:33:34 +00:00
Stanislav Shwartsman
1107ce138e
small fetchdecode optimization
2010-09-07 19:54:50 +00:00
Stanislav Shwartsman
31e8bfc5a7
Fixed fsgsbase cpuid bit
2010-07-22 20:19:00 +00:00
Stanislav Shwartsman
55cb12badf
fixed missed canonical failure on system access
2010-07-22 20:12:25 +00:00
Stanislav Shwartsman
91ac0df65c
implemented GS/FS BASE access instructions published in _319433-007.pdf document
2010-07-22 16:41:59 +00:00
Stanislav Shwartsman
7f7c249934
disasm and some cpuid code according to recently published AVX_319433-007.pdf document
2010-07-22 15:12:08 +00:00
Stanislav Shwartsman
cd6314b65c
Added ability to configure CPUID stepping through .bochsrc.
...
Next is CPUID model/extended model.
2010-07-16 21:03:52 +00:00
Stanislav Shwartsman
59ad9d8de8
Fixes
2010-07-15 20:18:03 +00:00
Stanislav Shwartsman
41ddb26c6f
Fixed save/restore of x87 regs
2010-07-01 20:00:33 +00:00
Stanislav Shwartsman
4cf15cd18b
Fixed RDTSCP VMEXIT reason
2010-07-01 16:31:46 +00:00
Stanislav Shwartsman
d47c84320a
swap bits in instr
2010-06-29 19:38:56 +00:00
Stanislav Shwartsman
8e94474e03
bug fix
2010-06-21 05:35:45 +00:00
Stanislav Shwartsman
8099effaf5
typo
2010-06-18 14:24:45 +00:00
Stanislav Shwartsman
9ec1d79b8c
warning fix
2010-06-18 14:15:53 +00:00
Stanislav Shwartsman
eaa2e0e0ea
[PATCH] cpu/init.cc: proper CPL restore in after_restore_statE
2010-06-04 20:31:04 +00:00
Stanislav Shwartsman
23a28d2892
Fixed compilation with vs2008
2010-06-03 19:36:13 +00:00
Stanislav Shwartsman
f3980b522f
bugfux
2010-06-02 05:44:12 +00:00
Stanislav Shwartsman
67aec1dc22
warning fix
2010-05-26 18:37:54 +00:00
Stanislav Shwartsman
84880793f3
optimize for speed
2010-05-26 18:34:25 +00:00
Stanislav Shwartsman
95df639614
compilation fix
2010-05-25 18:52:01 +00:00
Stanislav Shwartsman
8d8d1590f5
fetchdecide rework for AVX (0xF3 SSE prefix encoded as 2 in VEX)
2010-05-23 19:17:41 +00:00
Stanislav Shwartsman
b2dffd9258
undo incorrect change for ia32_feature_control msr init
2010-05-23 05:32:00 +00:00
Stanislav Shwartsman
c21a8fd935
sse4.2 string instruction do not required aligned mem access
2010-05-22 19:55:12 +00:00
Stanislav Shwartsman
1c00193616
cleanup
2010-05-22 10:43:39 +00:00
Stanislav Shwartsman
b6c26d394c
enable VMX lock bit - required for VMXON
2010-05-22 10:21:31 +00:00
Stanislav Shwartsman
d8b1d60239
when in HLT run time faster for single cpu
2010-05-22 10:17:58 +00:00
Stanislav Shwartsman
fff0a79aea
a little simpler fetchdecode
2010-05-21 21:17:32 +00:00
Stanislav Shwartsman
3dfcfd0ccd
Split shift opcodes | optimize SAR opcode
2010-05-18 07:28:05 +00:00
Stanislav Shwartsman
32ff6e4879
MSR BX_DEBUG prints
2010-05-16 13:56:22 +00:00
Stanislav Shwartsman
05bbbb1a2c
compilation fix
2010-05-16 05:23:18 +00:00
Volker Ruppert
cdb7e0eb96
- fixed usage of variable 'apic_id_mask' for compatibility with win32 plugin target
2010-05-15 09:23:50 +00:00
Stanislav Shwartsman
9c69b15ecb
fetchdecode tables reorg phase1
2010-05-13 05:38:24 +00:00
Stanislav Shwartsman
74b87d2b68
fixes for CPUID and alloweds bits in CRs
2010-05-12 21:33:04 +00:00
Stanislav Shwartsman
f95ddc4029
Debug Extensions was introduced in Pentium
2010-05-12 18:48:51 +00:00
Stanislav Shwartsman
d849cdf128
- Determine and select max physical address size automatically at
...
configure time:
- 32-bit physical address for 386/486 guests
- 36-bit physical address for PSE-36 enabled Pentium guest
- 40-bit physical address for PAE enabled P6 or later guests
2010-05-12 14:55:12 +00:00
Stanislav Shwartsman
49934bc853
cache page split instructions
...
next step - cache page split traces
2010-05-08 08:30:04 +00:00
Stanislav Shwartsman
b0d5142e18
comp fixes
2010-05-06 21:46:39 +00:00
Stanislav Shwartsman
1c47847e23
Show more fields for verbose debugger 'page'command
2010-05-05 20:10:15 +00:00
Stanislav Shwartsman
9a43a89a61
verbose page command from the debugger
2010-05-04 20:16:38 +00:00
Stanislav Shwartsman
aa76181208
Fixed debug translation
2010-05-04 19:02:51 +00:00
Stanislav Shwartsman
41e9663b89
optimization
2010-05-02 17:01:15 +00:00
Stanislav Shwartsman
4e6d7835c6
#GP/#SS priority
2010-05-02 17:00:05 +00:00
Stanislav Shwartsman
0478b326c3
remove ome ifdefs
2010-05-02 15:11:39 +00:00
Stanislav Shwartsman
acc82363cd
undefined CR fault higher prio than CPL GP
2010-05-02 15:10:27 +00:00
Stanislav Shwartsman
48a461116f
PUSH segment register fix to be like real CPU
2010-04-30 09:12:52 +00:00
Stanislav Shwartsman
1f0d4f9663
compilation fix
2010-04-29 21:04:23 +00:00
Stanislav Shwartsman
f5a2ca3b48
optimize for x86-64 OFF
2010-04-29 20:03:03 +00:00
Stanislav Shwartsman
50f3547dbe
optimize for x86-64 OFF
2010-04-29 19:56:10 +00:00
Stanislav Shwartsman
ca95477b7f
Implement x86-64 PCID extension
2010-04-29 19:34:32 +00:00
Stanislav Shwartsman
1c2fa8cd0c
move 1G_pages support to runtime option
2010-04-24 09:36:04 +00:00
Stanislav Shwartsman
ea95341e05
compile fix
2010-04-22 18:48:39 +00:00
Stanislav Shwartsman
30fecf9792
changes in comments only
2010-04-22 17:51:37 +00:00
Stanislav Shwartsman
3c6a8375fd
small optimization
2010-04-22 17:41:05 +00:00
Stanislav Shwartsman
c9f0779199
cleanup
2010-04-20 06:14:55 +00:00
Stanislav Shwartsman
b9be4fcd3e
fix
2010-04-19 11:09:35 +00:00
Stanislav Shwartsman
7319d2eee1
FENCE instructions are SSE2 only
2010-04-18 09:21:24 +00:00
Stanislav Shwartsman
cb281a1440
typo fix
2010-04-16 20:09:23 +00:00
Stanislav Shwartsman
43bc0f1f2b
optimize some of x87 tables
2010-04-16 19:52:44 +00:00
Stanislav Shwartsman
59eb1200c2
fixed IMUL eflags
2010-04-15 19:50:57 +00:00
Stanislav Shwartsman
749d6c33d2
relocate lazy_flags code from cpu.h
2010-04-15 05:51:00 +00:00
Stanislav Shwartsman
9746e16657
SSE unmasked exceptions report fix
2010-04-14 20:20:17 +00:00
Stanislav Shwartsman
89c87e2743
fixes
2010-04-14 17:33:19 +00:00
Stanislav Shwartsman
77f8857ddb
Fixed dbg_linear2phy function for legacy PAE
2010-04-14 15:41:57 +00:00
Stanislav Shwartsman
df07dab80f
verbose phy mem access tracing
2010-04-13 17:56:50 +00:00
Stanislav Shwartsman
afcbca5bba
bugfix
2010-04-11 05:28:19 +00:00
Stanislav Shwartsman
b85791686b
fixed mtrr_deftype reset value
2010-04-10 07:32:48 +00:00
Stanislav Shwartsman
6dbafd6f60
bugfix
2010-04-09 15:19:14 +00:00
Stanislav Shwartsman
51b6180b28
don't use magic constant
2010-04-09 11:34:52 +00:00
Stanislav Shwartsman
955e237e46
unrestricted guests support (VMXx2)
2010-04-09 11:31:55 +00:00
Stanislav Shwartsman
04349e1041
compilation fix for CPU < 6
2010-04-09 07:15:54 +00:00
Stanislav Shwartsman
dd6cc5ce42
update todo
2010-04-08 20:08:05 +00:00
Stanislav Shwartsman
689ecc57dd
split 2 more SSE opcodes
2010-04-08 17:35:32 +00:00
Stanislav Shwartsman
546d974248
If CR0.PE = 0, the following instructions cause invalid-opcode exceptions and
...
do not cause VM exits: INVEPT, INVVPID, LLDT, LTR, SLDT, STR, VMCLEAR,
VMLAUNCH, VMPTRLD, VMPTRST, VMREAD, VMRESUME, VMWRITE, VMXOFF,
and VMXON.
2010-04-08 17:00:55 +00:00
Stanislav Shwartsman
50462dde9a
RDTSCP could be run outside long64
2010-04-08 16:38:41 +00:00
Stanislav Shwartsman
6e1204cb84
Merged X2APIC + X2APIC virtualization
2010-04-08 15:50:39 +00:00
Stanislav Shwartsman
df7db31fb4
EPT + VPID - VMXx2 support
2010-04-07 17:12:17 +00:00
Stanislav Shwartsman
fa57efb9a8
fix PANIC on 386
2010-04-07 16:02:52 +00:00
Stanislav Shwartsman
62b5c27e1b
compilation fixes
2010-04-07 14:49:18 +00:00
Stanislav Shwartsman
c94e72d4d3
make lpf_mask smaller
2010-04-07 14:38:53 +00:00
Stanislav Shwartsman
10505dca81
PDPTR checks fix
2010-04-06 19:26:03 +00:00
Stanislav Shwartsman
bd8789646a
cleanup
2010-04-05 09:49:26 +00:00
Stanislav Shwartsman
7b23a893ac
P5 has 4 LVT entries
2010-04-05 09:36:17 +00:00
Stanislav Shwartsman
b4cd188f07
Update (c)
2010-04-04 19:56:55 +00:00
Stanislav Shwartsman
c98cc9ec86
very old typo fix
2010-04-04 19:48:18 +00:00
Stanislav Shwartsman
aea9f50b4a
implemented Descriptor Table exiting control
2010-04-04 19:23:47 +00:00
Stanislav Shwartsman
9cece96d14
fixes
2010-04-04 18:46:03 +00:00
Stanislav Shwartsman
eec8c8e3d2
dbg function fix
2010-04-04 09:05:21 +00:00
Stanislav Shwartsman
21de4f8b8b
remove cr3_masked
2010-04-04 09:04:12 +00:00
Stanislav Shwartsman
58bbf0d0b1
compilation fix for 386
2010-04-03 19:21:07 +00:00
Stanislav Shwartsman
25d3d950b2
vmx fix
2010-04-03 19:18:38 +00:00
Stanislav Shwartsman
eab8826173
restore back some code - optimization conflicting with EPT implementation
2010-04-03 18:00:30 +00:00
Stanislav Shwartsman
a445b5c4f3
optimization + fix
2010-04-03 16:52:33 +00:00
Stanislav Shwartsman
3f4cf46c2d
fixed crash in single cpu mode due to early construction of APIC
2010-04-03 10:14:42 +00:00
Stanislav Shwartsman
7c42447c77
move secondary VMEXEC controls to -enable-vmx=2 option
...
EPT coming next
2010-04-03 07:30:23 +00:00
Stanislav Shwartsman
d39d485ece
changes variable name to better one
2010-04-03 05:59:07 +00:00
Stanislav Shwartsman
93220f6b6e
fixes
2010-04-02 21:22:17 +00:00
Stanislav Shwartsman
9d3eee21fc
LAR fix in long mode
2010-04-02 19:53:29 +00:00
Stanislav Shwartsman
01de3e1926
PEXTRB/W/D/EXTRACTPS fixed
2010-04-02 19:03:47 +00:00
Stanislav Shwartsman
caa30e3462
bugfix
2010-04-02 18:24:27 +00:00
Stanislav Shwartsman
87ad43d25a
handle DMA when halted as well
2010-04-02 17:15:14 +00:00
Stanislav Shwartsman
8260358afe
removed redundant check
2010-04-02 16:56:59 +00:00
Stanislav Shwartsman
7080435433
VMX compilation fix
2010-04-02 08:03:04 +00:00
Stanislav Shwartsman
929ea0e071
update VMX msrs + bugfix in VMENTRY capabilities MSR
2010-04-01 21:32:25 +00:00
Stanislav Shwartsman
b049646621
compilation fix for x86_64 disable
2010-04-01 20:53:55 +00:00
Stanislav Shwartsman
a625abaaf0
small fixes
2010-04-01 20:08:57 +00:00
Stanislav Shwartsman
585cc3492b
paging similication
2010-04-01 20:06:09 +00:00
Stanislav Shwartsman
5c23538d94
redundant ifdef
2010-04-01 12:32:11 +00:00
Stanislav Shwartsman
9224bf60aa
paging phase 3
2010-04-01 12:23:52 +00:00