Commit Graph

81 Commits

Author SHA1 Message Date
Stanislav Shwartsman
bd60e0264c change Copyright to Bochs Project 2009-12-04 16:53:12 +00:00
Stanislav Shwartsman
c9383813f0 don't have to keep both limit and limit_scale 2009-04-05 18:16:29 +00:00
Stanislav Shwartsman
e5be60be64 Fixed lazy flags bug I added in one of my prev merges
ICACHE code reorganization
2009-03-22 21:12:35 +00:00
Stanislav Shwartsman
9e723a044f - Added configure option to enable/disable A20 pin support. Disabling the
A20 pin support slightly speeds up the emulation.

  - small code cleanup
2009-03-10 16:28:01 +00:00
Stanislav Shwartsman
592484408f Initial NMI virtualization for VMX, clean out CPU pins set/clear code 2009-02-03 19:17:15 +00:00
Stanislav Shwartsman
9929e6ed78 - updated FSF address 2009-01-16 18:18:59 +00:00
Stanislav Shwartsman
098308dd9f some variable renames + comp warn fix 2008-12-01 19:06:14 +00:00
Stanislav Shwartsman
c1306f7d75 small non-significant speedups 2008-09-06 21:10:40 +00:00
Stanislav Shwartsman
f275eb3e86 - CALL instructions should push old EIP to stack before checking new EIP for CS.limits 2008-08-16 15:32:44 +00:00
Stanislav Shwartsman
1da5943f1a More use of LOAD_Ex method 2008-08-10 19:34:28 +00:00
Stanislav Shwartsman
5dd02b26e3 Make even more efficient RmAddr calculation - good optimizing compiler could make more efficient code than it was before 2008-08-08 09:22:49 +00:00
Stanislav Shwartsman
b65816a92d Fixed problem in my morning checkin + some more changes 2008-06-23 15:58:22 +00:00
Stanislav Shwartsman
678ac970aa Reorganize ctrl_xfer8.cc code, allows to inline branch32 method 2008-06-22 03:45:55 +00:00
Stanislav Shwartsman
bef3450baa Fixes to 64-bit mode 2008-05-11 20:46:11 +00:00
Stanislav Shwartsman
ec1ff39a5f Splitted memory access methods for 32 and 64-bit code.
The 64-bit code got >10% speedup, the 32-bit code also got about 2% because laddr cacluation optimization
2008-05-10 18:10:53 +00:00
Stanislav Shwartsman
09c875b11c Fixed dbg comment 2008-05-08 21:04:03 +00:00
Stanislav Shwartsman
3dc0438c43 Implemented CALL_Far64 and JMP_Far64 according to Intel docs 2008-04-13 20:57:49 +00:00
Stanislav Shwartsman
167c7075fb Use fastcall gcc attribute for all cpu execution functions - this pure "compiler helper" optimization brings additional 2% speedup to Bochs code 2008-03-22 21:29:41 +00:00
Stanislav Shwartsman
a2897933a3 white space cleanup 2008-02-02 21:46:54 +00:00
Stanislav Shwartsman
37fbb82baa Cleanups. Move bxInstruction_c definition to separate file instr.h 2008-01-29 17:13:10 +00:00
Stanislav Shwartsman
c6fd4ebf94 Split CALL_Ev and JMP_Ev methods 2008-01-12 16:40:38 +00:00
Stanislav Shwartsman
d9984bb3a1 Eliminate BxResolve call from the heart of cpu loop and move into instructions that really require this calculation. Yes, it blows the code of EVERY CPU method but it has >15% speedup ! 2008-01-10 19:37:56 +00:00
Stanislav Shwartsman
d830c301cf Fixed 64-bit versions of LOOP instructions, some cleanups 2007-12-21 17:30:49 +00:00
Stanislav Shwartsman
5d4e32b8da Avoid pointer params for every read_virtual_* except 16-byte SSE and 10-byte x87 reads 2007-12-20 20:58:38 +00:00
Stanislav Shwartsman
a545bf63ce push_64 and pop_64 could happen only in 64-bit mode 2007-12-16 21:40:44 +00:00
Stanislav Shwartsman
4f78ff2153 Code cleanup 2007-12-16 21:21:29 +00:00
Stanislav Shwartsman
42d06b2d2b make some functions RSP safe so it is not needed to save/restore RSP for the anymore 2007-11-24 15:27:55 +00:00
Stanislav Shwartsman
e51184c8cf Eliminate saving of RSP from heart of cpu_loop
Now save RSP only where it is really required
2007-11-24 14:22:34 +00:00
Stanislav Shwartsman
d9e58bd598 split11b on opcode tables level - split almost eevery splittable instruction
will be continued
2007-11-17 12:44:10 +00:00
Stanislav Shwartsman
edfff23ca0 Split JCC methods to 16 different methods per branch condition 2007-11-12 18:20:15 +00:00
Stanislav Shwartsman
aed6640ef4 speedup JCC for 64-bit -> separate JZ/JNZ for single faster methods 2007-11-11 21:26:10 +00:00
Stanislav Shwartsman
292153b30e Fixed BranchImm cases in 64-bit mode 2007-10-22 17:41:41 +00:00
Stanislav Shwartsman
8065ada31f Some EIP setting cleanups.
OK, currently I see big mess with setting of CS/EIP and SS/ESP everywhere, I have to unify it and make it easier !
2007-10-18 21:27:56 +00:00
Stanislav Shwartsman
e812f81e7b Fixes in zero upper ECX 2007-09-25 16:11:32 +00:00
Stanislav Shwartsman
6c3420a18b Add debug prints before any #GP excepion which only possible to be generated 2006-06-09 22:29:07 +00:00
Stanislav Shwartsman
fe644dfcbf - Code cleanup, remove x86-64 code from functions which cannot be called from x86-64
- Fix PANIC multiple SSE prefix decoding (fetchdecode and disasm)
- More Bit32u -> bx_phy_address convert
- Lazy flags optimization
2006-05-12 17:04:19 +00:00
Stanislav Shwartsman
f347ab97bf Fixed CALL/JMP far through call gate 64
Decode SWAPGS and RDTSCP instructions
Indent changes in fetchdecode
2006-03-22 20:47:11 +00:00
Stanislav Shwartsman
d6f85c12f6 NMI support inside the CPU.
Added two functions to query NMI and SMI from Bochs debugger.
In future they could be used for generating NMI or SMI by user request using GUI button (could be implemented separatelly later and under configure-time or .bocshrc option)
2006-03-16 20:24:09 +00:00
Stanislav Shwartsman
e85a90a720 Remove cpu.h -> devices.cc dependancy, kill_bochs_request moved from CPU to bx_pc_system
Small Icache simplification and speedup
2006-03-14 18:11:22 +00:00
Stanislav Shwartsman
7b6c2587a9 Now devices could be compiled separatelly from CPU
Averything that required cpu.h include now has it explicitly and there are a lot of files not dependant by CPU at all which will compile a lot faster now ...
2006-03-06 22:03:16 +00:00
Stanislav Shwartsman
2646484dc1 Fix 'show' command in Boch debugger.
Fully supported show-interrupts, show-mode and show-call options
Enable toggling of show options (bug report from SF)
2006-02-12 20:21:36 +00:00
Stanislav Shwartsman
e2a5b9c338 MOV to/from test register are UD in x86-64 2005-11-11 22:02:42 +00:00
Stanislav Shwartsman
ea30a3ef06 Implemented CALL FAR in 64-bit mode 2005-08-04 19:38:51 +00:00
Stanislav Shwartsman
954aae3f99 Speedup push/pop operations, they actually not needed to do can_push/can_pop checkes, the same checkes already done in read/write_virtial methods
Split push_seg_reg methods according to op size
2005-07-31 17:57:27 +00:00
Stanislav Shwartsman
51e03f071d Fixed XLAT instruction for x86-64
Small optimization for lazy flags for ADD/ADC/SUB/SBB instructions
Enable RETF64 for same privelege level return
2005-07-21 01:59:05 +00:00
Stanislav Shwartsman
aceb8c683b Initial implementation of RETF64 2005-07-20 01:26:47 +00:00
Stanislav Shwartsman
169fa0c574 Clearify the code. x86-64 code always running in pmode so it is not needed to check if we are in protected mode everytime 2005-07-10 20:32:32 +00:00
Stanislav Shwartsman
6df9640844 implement jump_far64 for code segments
the panic message moved to TASK-GATE64 far jmp which is still not implemented
2005-05-19 18:13:08 +00:00
Stanislav Shwartsman
caa0648188 Move duplicated code to separate function
And fix a bug I added by previous merge
2005-04-17 21:51:59 +00:00
Stanislav Shwartsman
6fa52214b0 Canonical address check for RIP in x86-64 2005-04-17 18:54:54 +00:00