Commit Graph

466 Commits

Author SHA1 Message Date
drmortalwombat 60868c71d3 Fix single tail loop opt for search loops (e.g. strlen) 2024-07-31 21:11:13 +02:00
drmortalwombat 9013952431 Fix missing int range adaption on complex address optimization 2024-07-31 17:59:20 +02:00
drmortalwombat 0b8304b40d More cross block const pointer forwarding 2024-07-28 17:52:07 +02:00
drmortalwombat 5bb8ca0b89 Improve fix point arithmetic 2024-07-28 14:41:17 +02:00
drmortalwombat 5b50389340 Optimize 32bit shifts 2024-07-21 21:43:59 +02:00
drmortalwombat 3dd23ec789 Additional register allocation step after late inlining 2024-07-21 10:40:37 +02:00
drmortalwombat d0fb062006 Make log and exp intrinsics for const evaluation 2024-07-17 12:42:15 +02:00
drmortalwombat c229a27992 Improve cross loop value propagation 2024-07-16 08:36:52 +02:00
drmortalwombat 68a648440a Fix crash on short lea optimization due to lost temp dependencies 2024-07-10 18:31:32 +02:00
drmortalwombat a3bf7296bb Reduce index register usage, where ORA Imm would suffice 2024-07-09 11:24:02 +02:00
drmortalwombat 301431f12a Eliminate duplicate loop counting variables 2024-07-05 10:12:55 +02:00
drmortalwombat bf89d7af33 Improve loop register allocation 2024-07-03 22:23:27 +02:00
drmortalwombat d070e32b4d Loop unrolling for pointer limited short loops 2024-06-30 21:54:56 +02:00
drmortalwombat 7eb149a71b Optimize value range of right shifts 2024-06-30 15:45:34 +02:00
drmortalwombat 1c0db235a8 Fix emulator cycle count 2024-06-30 12:29:41 +02:00
drmortalwombat 715f295f5e Add goto and labels in C code 2024-06-25 20:45:44 +02:00
drmortalwombat 1598360b65 Fix relational bool ops constant folding 2024-06-22 15:41:02 +02:00
drmortalwombat d4a381f71c Fix size heuristic of loop condition slicing 2024-06-20 09:42:22 +02:00
drmortalwombat 277afd156d Fix over eager const pointer forwarding 2024-06-16 09:01:36 +02:00
drmortalwombat 58361e39b8 Fix crash on late const typecast to pointer 2024-06-15 13:35:17 +02:00
drmortalwombat 4cf64ee170 Fix loop inversion invariant integer range recovery 2024-06-11 21:01:20 +02:00
drmortalwombat 5ccfab0342 Fix IEC code for non interrupt usage 2024-06-11 12:12:29 +02:00
drmortalwombat fbc9607e17 Ensure actual update of index variable in loops in non debug builds 2024-05-30 17:51:59 +02:00
drmortalwombat 2e1c020db4 Bump version number 2024-05-26 08:43:14 +02:00
drmortalwombat 3460c06508 Improve strength reduction in loops 2024-05-22 20:36:22 +02:00
drmortalwombat d3734a66e0 Fix complex loop intercode index reversal 2024-05-22 12:16:30 +02:00
drmortalwombat 86e0cbf9c2 Alternate forward and backward int value range check 2024-05-19 10:19:42 +02:00
drmortalwombat 04d1abd803 Some peephole loop optimizations 2024-05-12 21:06:50 +02:00
drmortalwombat 37776dfaee Remove more conditional branches from loops 2024-05-05 13:14:23 +02:00
drmortalwombat c28f342f3e Remove some superflous range violation warnings 2024-05-03 14:54:58 +02:00
drmortalwombat fb72e8baf8 Fix over eager parameter reordering 2024-05-01 15:30:18 +02:00
drmortalwombat 9b47a34840 Improve reordering of function arguments 2024-04-28 20:15:17 +02:00
drmortalwombat 411648b130 Improve long counting loops 2024-04-22 22:48:15 +02:00
drmortalwombat 611f672b81 Add warning for static buffer overflow 2024-04-15 15:40:37 +02:00
drmortalwombat fbfd597306 Fix float param to const propagation 2024-04-12 15:50:46 +02:00
drmortalwombat fefa462730 Improve zero page variable usage 2024-04-08 22:04:50 +02:00
drmortalwombat 7b20e6cca0 Optimize 16 bit counting loops 2024-03-31 14:29:22 +02:00
drmortalwombat 6cfdc0ce5f Fix removal of consecutive indexed stores in unrolled loop 2024-03-29 18:49:58 +01:00
drmortalwombat 1f17f1c198 Fix assert in peephole optimizer 2024-03-26 08:23:13 +01:00
drmortalwombat aa601a5727 Change memset and memclr to intrinsic functions 2024-03-24 11:22:13 +01:00
drmortalwombat 85fad64e9c Optimize post inc/dec while loop conditions 2024-03-21 19:33:50 +01:00
drmortalwombat 30d942478f Fix infinite loop in move condition out of loop 2024-03-13 22:14:29 +01:00
drmortalwombat 0c43952e37 Improve constant branch forwarding 2024-03-07 13:20:39 +01:00
drmortalwombat 2d50d56606 Fix copy and load with striped arrays 2024-02-27 18:02:12 +01:00
drmortalwombat 0b58e9eaaf Fix global aliasing collision with striped data 2024-02-25 18:00:10 +01:00
drmortalwombat 22ffbfa63c Fix source location when coalescing JSR and RTS in JMP 2024-02-24 09:52:32 +01:00
drmortalwombat 94a3097ba7 Fix find loop optimization with mirrored condition 2024-02-21 15:05:17 +01:00
drmortalwombat cc5a90ac21 Fix long unsigned int comparison 2024-02-18 18:30:51 +01:00
drmortalwombat 6f7efd9efc Optimized long multiply 2024-02-17 12:06:15 +01:00
drmortalwombat b84cce7609 Improve compatibility with some C quirks 2024-02-16 21:39:35 +01:00
drmortalwombat 003550337a Fix debug and linux build 2024-02-15 13:29:02 +01:00
drmortalwombat c909995011 Reduce compiler memory footprint 2024-02-15 09:58:26 +01:00
drmortalwombat 18cfbc713a Force some inline calls in vdc 2024-02-14 15:24:01 +01:00
drmortalwombat 806539a2d6 add "tan" to intrinsic functions 2024-02-13 20:49:11 +01:00
drmortalwombat bcc20d3986 Switch to x64 compiler binary 2024-02-13 16:53:44 +01:00
drmortalwombat 7d6eb36ee7 Fix assignment of immediates to returned struct 2024-02-04 09:43:52 +01:00
drmortalwombat 80efe2351b Optimize short wait loop handling 2024-01-28 19:09:59 +01:00
drmortalwombat c1083b44dc Optimize constant loops 2024-01-27 10:19:14 +01:00
drmortalwombat 3992b1d547 Add warning for out of bounds accesses 2024-01-24 17:30:03 +01:00
drmortalwombat 2c1a87ce02 Control assert with _DEBUG to avoid gcc core dump 2024-01-23 16:53:30 +01:00
drmortalwombat bcc5e9d362 Fix propagation of conditions out of loops 2024-01-23 09:02:38 +01:00
drmortalwombat 4fc3e019d5 Add ranges in case statements (gcc extension) 2024-01-21 15:17:46 +01:00
drmortalwombat 8a49ffd111 Improve unrolled loops towards zero 2024-01-20 13:49:25 +01:00
drmortalwombat a19469d851 Fix exportet variable alignment calculation 2024-01-16 08:12:47 +01:00
drmortalwombat 265be6e766 Move linker chattyness into -v2 2024-01-12 22:51:11 +01:00
drmortalwombat cac7db4358 Fix memory size mismatch in reverse integer range propagation due to register renaming 2024-01-10 22:59:45 +01:00
drmortalwombat d9f81ad653 Improve cross function memory aliasing analysis 2024-01-03 22:23:20 +01:00
drmortalwombat 34947da898 Fix loop integer range propagation 2024-01-02 22:21:05 +01:00
drmortalwombat da20b4d27a Fix atan2, failed in mathtest.c 2023-12-30 09:21:17 +01:00
drmortalwombat a305dbb1cd Improve function placement in linker 2023-12-23 10:40:45 +01:00
drmortalwombat 4a8010a3a0 Fix loss of zero page dependency in tail code merge 2023-12-17 12:40:09 +01:00
drmortalwombat ae4b48c445 Various loop optimizations 2023-12-16 21:03:09 +01:00
drmortalwombat 8ab46e29dd Direct parameter forwarding 2023-12-02 10:58:20 +01:00
drmortalwombat 003306f961 Fix noinline, improve cartridge use of bank 0 2023-11-29 20:53:04 +01:00
drmortalwombat cf28c1a618 Move conditions out of loops 2023-11-28 17:40:44 +01:00
drmortalwombat 57537cd43a Join common branch code sequences 2023-11-26 15:46:59 +01:00
drmortalwombat eec4ed45d1 Fix global array aliasing error 2023-11-20 22:53:12 +01:00
drmortalwombat 0309fcb286 Fixed copy with offset 2023-11-20 08:29:23 +01:00
drmortalwombat 157f9c00e5 Fix do while loop with function condition 2023-11-16 16:40:11 +01:00
drmortalwombat 44e6921842 Change string literal processing to use unsigned chars 2023-11-14 15:02:35 +01:00
drmortalwombat ee03f08f52 Fix over eager zp parameter reuse 2023-11-11 22:37:35 +01:00
drmortalwombat 3be6d20006 Add enum class 2023-11-09 16:33:50 +01:00
drmortalwombat 06ab48461b Implement striped unions 2023-11-06 21:33:04 +01:00
drmortalwombat 8ea991db81 Optimize div/mod unsigned pairs 2023-11-03 20:16:23 +01:00
drmortalwombat 8aeddf0316 Fix previous fix 2023-10-30 19:43:37 +01:00
drmortalwombat 8a27cba1f9 Fix inifinite pumping loop in integer range optimizer 2023-10-30 18:02:34 +01:00
drmortalwombat 1d4eb70414 Optimize struct copies 2023-10-29 17:55:26 +01:00
drmortalwombat d9a8c5ea08 Fix template expansion of member functions 2023-10-27 14:53:19 +02:00
drmortalwombat 0080a85345 Fix deadlock on empty switch statement 2023-10-26 07:54:03 +02:00
drmortalwombat f6536a412e Fix SAR/MUL optimization 2023-10-24 21:20:07 +02:00
drmortalwombat 982fe17aed Fix compiler crash when using function result in if condition 2023-10-24 14:29:46 +02:00
drmortalwombat f8f81f6d4c Optimize compile time 2023-10-22 19:35:37 +02:00
drmortalwombat 0f5e933002 Optimize cross block constant propagation 2023-10-18 15:57:59 +02:00
drmortalwombat 7858e32d12 Improve handling of single member structs 2023-10-15 20:17:04 +02:00
drmortalwombat eb16767bdb Optimize wide right shift 2023-10-15 13:59:30 +02:00
drmortalwombat 3da58bf1ca Fix line directive off by one error 2023-10-15 12:01:24 +02:00
drmortalwombat d160b2ae65 Optimize bitfields 2023-10-14 16:51:33 +02:00
drmortalwombat 9156db9c32 Restart integer range estimation from full state 2023-10-14 13:43:11 +02:00
drmortalwombat ecf8e69cf2 Add restricted pointer attribute to newly allocated memory 2023-10-13 11:18:16 +02:00
drmortalwombat 2027ac5d4c Fix template expansion in multiple cpp 2023-10-12 14:10:34 +02:00