Commit Graph

56 Commits

Author SHA1 Message Date
Aaron Culliney
e4e0c941d3 Refactor CPU assembly for simplicity and efficiency
- Variables needed in assembly now accessible in a struct pointer that  avoids __PIC__ nastiness
    - Reduces code size and execution time for CPU thread
2018-01-15 16:19:21 -08:00
Aaron Culliney
ddcef734c7 Disable excessive IRQ checking for now 2016-10-23 17:39:00 -07:00
Aaron Culliney
97d538c4d2 Hackishly fix issue on x86 Android __PIC__ builds 2016-10-15 19:07:43 -07:00
Aaron Culliney
ccd05e52fe Improve timing conformance in Mockingboard
- Correctly calculate 7 cycles for handling IRQs
    - More frequent calls to MB_UpdateCycles()
    - Correctly calculate timing for MB_EndOfVideoFrame() when testing/tracing/debugging
2016-10-09 12:19:21 -07:00
Aaron Culliney
4fd6a87340 Pinpoint IRQ requests in CPU tracing 2016-10-02 14:24:04 -07:00
Aaron Culliney
3edb24ea3b Change cycle counts to conform with AppleWin 2016-10-02 14:23:59 -07:00
Aaron Culliney
fd5b97189a HACK : get iOS building again
- TODO FIXME : actually get proper __PIC__ code written for Mac/i386
2016-05-15 18:13:20 -07:00
Aaron Culliney
7b3eabb12f Fix x86 and x86_64 __PIC__ code for Linux and Mac 2016-05-01 18:49:18 -07:00
Aaron Culliney
90b52702d6 Refactor __PIC__ codepaths on x86_64 2016-04-21 22:09:04 -07:00
Aaron Culliney
f872e0c05c fix i386 variant of op_SBC_dec (now re-passes tests on x86 Android) 2015-12-16 21:12:45 -08:00
Aaron Culliney
e4c669f016 x86 builds and basically works on Android x86 devices 2015-11-09 22:45:52 -08:00
Aaron Culliney
2cc23cf35d Upgrade to GPLv3 "or later" and update copyrights 2015-10-22 21:09:13 -07:00
Aaron Culliney
ed60b2ea73 Refactor VM initialization and shutdown 2015-09-11 23:03:17 -07:00
Aaron Culliney
792c0a0b08 DAA & DAS algorithms in ARM assembly 2015-02-22 13:46:58 -08:00
Aaron Culliney
d517339842 All 65c02 CPU tests for ARM pass, except for decimal mode 2015-02-21 21:06:01 -08:00
Aaron Culliney
28aea0bf14 Remove redundant code 2015-02-17 11:06:50 -08:00
Aaron Culliney
15dd90902c REFACTOR : more common code into macros 2015-02-16 10:28:57 -08:00
Aaron Culliney
5aa4c20249 REFACTOR : style+clarity changes 2015-02-16 09:42:13 -08:00
Aaron Culliney
0801050455 REFACTOR : move special case initialization codepath to C 2015-02-16 08:47:26 -08:00
Aaron Culliney
30c09da259 REFACTOR : simplified/streamlined some assembly 2015-02-16 08:47:26 -08:00
Aaron Culliney
12ba31f1af REFACTOR : whitespace, style, remove deadcode, extract code into macro 2015-02-16 08:47:26 -08:00
Aaron Culliney
9a87aa8a3d REFACTOR : migrate stack page offset into altzp configuration 2015-02-16 08:47:26 -08:00
Aaron Culliney
b246baa90d REFACTOR : macro renaming for clarity/readability 2015-02-16 08:47:26 -08:00
Aaron Culliney
cf79056b28 Merge x86-specific apple2.h stuff into cpu-regs.h 2015-02-16 08:47:26 -08:00
Aaron Culliney
851d22568b Use 32bit counters to avoid overflow
- Previously there were cases where we could overflow cpu65_cycles_to_execute when adding the cycles_speaker_feedback
2015-02-03 22:10:47 -08:00
Aaron Culliney
e6ca42be64 CPU fixes from tracing against AppleWin
- All regs are 0xFF on reboot
    - Stack pointer is 0xFC on reboot
    - Flags are set accordingly
    - Fix op_JMP_ind tracing display
2014-11-18 22:27:25 -08:00
Aaron Culliney
9bbe906f43 CPU_TRACING bugfix and more readable
- GetImm mode was not reporting correct arg
    - Converts it to a format easier to compare against similar CPU trace output from AppleWin
    - Sanity-check arg counts
2014-11-18 22:16:44 -08:00
Aaron Culliney
9144b48885 Enable abusive CPU_TRACING test 2014-11-02 12:09:30 -08:00
Aaron Culliney
4ff57ab7dd Slightly improve CPU trace files 2014-10-31 16:32:34 -07:00
Aaron Culliney
f11b6948bb Work around broken assembly for PLP instruction on Mac 2014-10-11 19:36:49 -07:00
Aaron Culliney
a37ed6cd98 tests run again on Mac 2014-10-11 19:34:12 -07:00
Aaron Culliney
4c9c1fb62a First cut at a facility to do CPU tracing
* Also includes a test that traces booting the test disk
2014-10-11 18:28:48 -07:00
Aaron Culliney
a99b5a1d68 HACKs around bizarre bytecode generation on Darwin
* CPU tests pass now, w00t!
2014-06-25 23:01:22 -07:00
Aaron Culliney
10e03e9bc5 Get tests working again
* Refactor naming of saved CPU state variables
    * Allows convenient addressing from assembly
2014-06-22 11:17:44 -07:00
Aaron Culliney
ed8b41c9a0 New CPP macros to accommodate Darwin 2014-06-21 14:21:33 -07:00
Aaron Culliney
d650982e51 Slightly less hackishly, use "private" pointers to set struct vals 2014-06-21 14:21:05 -07:00
Aaron Culliney
a4670b1eda Use CPP macro for duplicate assembly 2014-06-21 14:20:28 -07:00
Aaron Culliney
c13caa0798 add callLQ preprocessor macro 2014-06-21 14:05:00 -07:00
Aaron Culliney
44f06dfb48 don't {Pre,Post}fix Project Preprocessor macro with __ 2014-06-21 13:46:02 -07:00
Aaron Culliney
995643dfa2 DAA and DAS algorithms for x86_64 2014-06-13 23:57:56 -07:00
Aaron Culliney
1b2a46dff4 x86_64 bugfix : subtract 32bit int type 2014-06-08 15:46:59 -07:00
Aaron Culliney
f72976a566 Fix calling conventions on x86_64 2014-06-08 13:12:48 -07:00
Aaron Culliney
45f29f363f Fix ROR instruction on x86_64 2014-06-08 13:12:12 -07:00
Aaron Culliney
c33cdb4b25 x86_64 target builds 2014-06-08 11:01:38 -07:00
Aaron Culliney
126d049ffc Refactor to two jump vectors
* Believe needed to allow minimal change for x86_64 codepath
2014-06-07 16:05:38 -07:00
Aaron Culliney
71f71af834 Use name-indirection for assembly acting on full-length registers 2014-06-07 15:05:29 -07:00
Aaron Culliney
efc63aeb7a Refactoring: removing redundant code 2014-06-07 14:21:12 -07:00
Aaron Culliney
23e6e0ea75 Use name-indirection for all registers 2014-06-07 13:59:49 -07:00
Aaron Culliney
30cf264aa6 Refactoring: shifting to avoid stack hit 2014-06-07 13:40:18 -07:00
Aaron Culliney
05e10b7eb8 inline macros used once and brace apple vm specific code 2014-06-07 13:08:01 -07:00