Commit graph

  • de755c170d Tidy Paul Holden 2023-09-14 22:57:27 +01:00
  • 004cf70d30 Simplify screen->device transforms. Paul Holden 2023-09-14 22:56:40 +01:00
  • 1370d033b4 Add a Transform2D class. Paul Holden 2023-09-14 22:47:01 +01:00
  • 671f2e7832 Add a Vector2 class. Paul Holden 2023-09-13 23:55:46 +01:00
  • 1ca706cee3 Rename Matrix to Matrix4x4. Paul Holden 2023-09-13 23:48:52 +01:00
  • 00fc438524 Tidy Paul Holden 2023-09-13 08:06:07 +01:00
  • 7380c3f852 Overhaul handling of software rendering. Paul Holden 2023-09-12 23:58:50 +01:00
  • b594b29843 Fix software rendering for Rayman and Donald Duck (pitch was wrong). Paul Holden 2023-09-11 23:11:39 +01:00
  • d8ce4c93db Improve executeGBI2_MoveMem debug output. Paul Holden 2023-09-11 22:29:45 +01:00
  • 067c22eb84 Remove logGLCall. Paul Holden 2023-09-11 08:10:52 +01:00
  • c01945887b Fix texture wrapping issues for texrects that have negative dsdx or dtdy. Paul Holden 2023-09-10 22:30:11 +01:00
  • e20267d2f6 Remove unused imports. Paul Holden 2023-09-10 21:20:35 +01:00
  • d2b8074ef2 Tidy Paul Holden 2023-09-10 21:20:10 +01:00
  • 6c4c1a617a bun update Paul Holden 2023-09-10 21:13:34 +01:00
  • 9d18353bd9 Rename to eq for brevity. Paul Holden 2023-09-10 21:10:53 +01:00
  • 10e428e36f Add some tests for event_queue. Paul Holden 2023-09-10 20:52:30 +01:00
  • 761021bc18 Make recompiler export the functions it needs. Paul Holden 2023-09-10 20:27:54 +01:00
  • 6a77a1b984 Move tests alongside source. Paul Holden 2023-09-10 20:11:56 +01:00
  • 5d476c4ce2 Fix tests. Paul Holden 2023-09-10 20:06:49 +01:00
  • c7dcff1a80 Tidy raiseX() functions. Paul Holden 2023-09-10 18:17:40 +01:00
  • c35bf10e68 Move causeExcCode constants to cpu_constants.js. Paul Holden 2023-09-10 17:58:00 +01:00
  • 081cfaeab9 Tidy and dedupe more instruction decode helpers. Paul Holden 2023-09-10 16:07:11 +01:00
  • 4c70291c24 Fix and dedupe simpleOp. Paul Holden 2023-09-10 15:51:34 +01:00
  • 185af2c31f Fix asserts. Paul Holden 2023-09-10 15:36:56 +01:00
  • dba431578c Move cpu1 instruction handling to cpu1.js. Paul Holden 2023-09-10 15:36:47 +01:00
  • 88e1ab857b Move checkCauseIP3Consistent to CPU0. Paul Holden 2023-09-10 15:12:28 +01:00
  • 1e5c017b0e Remove some unused functions. Paul Holden 2023-09-10 15:09:31 +01:00
  • 2f331b816c Dedupe instruction decode helpers. Paul Holden 2023-09-10 15:08:25 +01:00
  • 446127e17b Split all the code generation out of r4300.js. Paul Holden 2023-09-10 14:57:43 +01:00
  • cbd881a02a Use this rather than cpu0. Paul Holden 2023-09-10 14:28:20 +01:00
  • 71b3435b43 Actually remove n64js.getRamDataView. Paul Holden 2023-09-10 14:24:42 +01:00
  • 9de368dff2 Remove n64js.getRamDataView. Paul Holden 2023-09-10 14:24:18 +01:00
  • e7c1fceeea Move getRamS32Array to hle.js. Paul Holden 2023-09-10 14:21:18 +01:00
  • 5ad008c239 Push n64js.getRamU8Array to call sites and remove. Paul Holden 2023-09-10 14:18:42 +01:00
  • e4899bbf86 Remove n64js.checkSIStatusConsistent. Paul Holden 2023-09-10 14:12:04 +01:00
  • 026d7139a1 getRandomU32 is unused. Paul Holden 2023-09-10 14:10:32 +01:00
  • 07e6d3d042 Log some more details from the rom header. Paul Holden 2023-09-10 14:04:31 +01:00
  • 3c2b111e6b Move systemFrequency to Hardware. Paul Holden 2023-09-10 13:51:58 +01:00
  • 6f4b3cb0a4 Add a TODO Paul Holden 2023-09-10 13:51:15 +01:00
  • e30bce9682 Periodically log audio sync. Paul Holden 2023-09-10 10:21:41 +01:00
  • e7d70154e3 Skip render frames if we start running too far ahead of realtime. Paul Holden 2023-09-10 10:16:29 +01:00
  • c4a3c1faf0 Fix some system constants based on https://n64brew.dev/wiki/ROM_Header. Paul Holden 2023-09-10 10:09:51 +01:00
  • 13137b723d VI interrupts should be based on the system clock, not the video clock. Paul Holden 2023-09-10 10:08:42 +01:00
  • 5d4a51f3f3 Fix lint warnings. Paul Holden 2023-09-09 22:35:36 +01:00
  • 93081b85b6 Fix call to unmappedAddressValue. Paul Holden 2023-09-09 22:27:47 +01:00
  • 919a481396 Update info. Paul Holden 2023-09-09 22:20:22 +01:00
  • a1a4dd0d3e Reimplemt EventQueue as a linked list. Paul Holden 2023-09-09 22:11:33 +01:00
  • 6107f4995f Rename countdown arg to cycles. Paul Holden 2023-09-09 14:02:43 +01:00
  • 64aa2b2850 Encapsulate more code in EventQueue. Paul Holden 2023-09-09 14:01:52 +01:00
  • 467d711d06 Split event queue out to a separate class. Paul Holden 2023-09-09 13:51:55 +01:00
  • 69269e8f72 Move run to CPU0. Paul Holden 2023-09-09 13:29:24 +01:00
  • 293fffcccd Move runImpl to CPU0. Paul Holden 2023-09-09 13:25:35 +01:00
  • 7ea9432a22 Move handleEmulatedException to CPU0. Paul Holden 2023-09-09 13:23:09 +01:00
  • 93d1a4aae6 Move onEventCountdownReached to CPU0. Paul Holden 2023-09-09 13:20:57 +01:00
  • b3b62a18e6 Rename handleCount -> onEventCountdownReached. Paul Holden 2023-09-09 13:17:19 +01:00
  • 565062c2bd Tidy Paul Holden 2023-09-09 13:15:20 +01:00
  • a3df6cbe3d Simplify kEventRunForCycles handling in speedHack. Paul Holden 2023-09-09 12:13:39 +01:00
  • d33f89d389 Tidy Paul Holden 2023-09-09 12:01:53 +01:00
  • eb2c01ff0c Use for/of. Paul Holden 2023-09-09 12:00:33 +01:00
  • d824732399 Add an option for whether to run audio task processing. Paul Holden 2023-09-09 11:45:31 +01:00
  • 77223a67dd Implement Audio. Paul Holden 2023-09-09 11:43:09 +01:00
  • c25825844c Remove bounds checks for get/setVec. Paul Holden 2023-09-09 11:15:40 +01:00
  • 43dff97c94 Optimise RSP to remove some BigInt conversions. Paul Holden 2023-09-09 11:13:33 +01:00
  • c58d2759d7 Don't run speedHack when the RSP is running. Paul Holden 2023-09-09 10:00:09 +01:00
  • 8fb5f05a00 Fix COUNT so that it increments once every 2 instructions. Paul Holden 2023-09-09 09:48:13 +01:00
  • 83a47be410 Fix reference to undefined var. Paul Holden 2023-09-08 20:29:42 +01:00
  • 8b7ceef4c4 Rename getCount to getOpsExecuted. Paul Holden 2023-09-08 20:27:07 +01:00
  • 6d26400a4a Add accessors for accumulator low/mid/high which avoid BigInt conversions. Paul Holden 2023-09-07 20:42:58 +01:00
  • 102654dc36 Reduce nesting in speedHack. Paul Holden 2023-09-07 20:40:07 +01:00
  • 00ef9922c6 Remove wrappers around executeX functions. Paul Holden 2023-09-07 20:32:30 +01:00
  • de630a24f3 Fix lint warnings. Paul Holden 2023-09-07 09:04:26 +01:00
  • 3e643de36d Add a getCyclesUntilEvent helper and fix getVblCount. Paul Holden 2023-09-07 09:03:41 +01:00
  • 454ed067eb Refactor setGLBlendMode. Paul Holden 2023-09-06 22:05:37 +01:00
  • e0abf51547 Debug color images. Paul Holden 2023-09-06 21:39:33 +01:00
  • f001721d64 Fix lint errors. Paul Holden 2023-09-06 21:37:25 +01:00
  • 49b6122b92 Add eslint config. Paul Holden 2023-09-06 21:32:00 +01:00
  • 96bc2cc071 Fix lint errors. Paul Holden 2023-09-06 21:31:31 +01:00
  • a6cd10c121 Improve accuracy of SP DMAs. Paul Holden 2023-09-06 08:57:58 +01:00
  • 58db855730 Improve accuracy of PI DMA emulation. Paul Holden 2023-09-05 23:12:04 +01:00
  • 2e658c4997 Make the SystemEvent type a string so it doesn't need to be maintained centrally, and move VI interrupt stuff to vi.js. Paul Holden 2023-09-05 22:50:59 +01:00
  • c824e9a92b Add handler function to SystemEvent. Paul Holden 2023-09-05 22:06:55 +01:00
  • 25596179a0 Improve cpu status table. Paul Holden 2023-09-05 08:48:58 +01:00
  • db6dd1bf54 Show single value for VCC/VCO. Paul Holden 2023-09-05 08:44:25 +01:00
  • 8dd30f5b1a Fix toHex when bits >= 32. Paul Holden 2023-09-05 08:39:20 +01:00
  • 7b13da432d Tidy Paul Holden 2023-09-05 08:27:56 +01:00
  • b731221b25 Add some TODOs. Paul Holden 2023-09-05 08:26:45 +01:00
  • 4375413975 Add some todos. Paul Holden 2023-09-05 08:25:21 +01:00
  • 842e797b7f Add a tab for RSP task state. Paul Holden 2023-09-05 08:23:18 +01:00
  • ad5093af7c Rename toString64_bigint to toString64. Paul Holden 2023-09-04 23:25:21 +01:00
  • b0b7673400 Replace uses of toString64 with toString64_bigint. Paul Holden 2023-09-04 23:22:23 +01:00
  • 3dcd94a531 Apply masking in toHex. Paul Holden 2023-09-04 23:19:29 +01:00
  • 1e9b7a643e Fix toString64_bigint formatting (wasn't padding with zeros) and resolve toStringN TODO. Paul Holden 2023-09-04 23:11:52 +01:00
  • 5478fe11c4 Add VCO, VCC, VCE. Paul Holden 2023-09-04 22:57:19 +01:00
  • 2a7eba8333 Show RSP registers. Paul Holden 2023-09-04 22:51:38 +01:00
  • d7956ab645 Hoist opsExecuted out as a local var. Paul Holden 2023-09-04 22:03:46 +01:00
  • a69fccf182 Flesh out disassembly for the RSP debugger. Paul Holden 2023-09-04 22:02:19 +01:00
  • 25cac85239 Make imem wrap when disassembling. Paul Holden 2023-09-04 22:01:33 +01:00
  • 1c1bd078b3 Refactor makeRecentMemoryAccesses to use a helper function to resolve the memory access. Paul Holden 2023-09-04 21:56:24 +01:00
  • 69caeebc13 Wrap up lastPC in CPUDebugState. Paul Holden 2023-09-04 20:45:35 +01:00
  • 5dab0f74eb Fix rollup config for rollup v3. Paul Holden 2023-09-04 20:37:47 +01:00