Commit Graph

38 Commits

Author SHA1 Message Date
Irmen de Jong
2e37f5dee3 IR: support for multi-returnvalue function calls (asmsubs)
note: the VM can't execute these though as it has no CPU hardware registers
2024-03-23 00:30:17 +01:00
Irmen de Jong
80f39e8097 Merge branch 'booleans'
# Conflicts:
#	compiler/res/prog8lib/cx16/monogfx.p8
#	compiler/res/prog8lib/virtual/monogfx.p8
#	compiler/src/prog8/compiler/astprocessing/BoolRemover.kt
#	compiler/test/TestTypecasts.kt
#	docs/source/todo.rst
#	examples/cx16/highresbitmap.p8
#	examples/test.p8
#	httpCompilerService/src/prog8/http/TestHttp.kt
2024-03-11 01:00:48 +01:00
Irmen de Jong
ed15fac691 improve IR error message 2024-03-09 13:38:25 +01:00
Irmen de Jong
41afeccd51 compiler stuff 2024-03-02 23:19:20 +01:00
Irmen de Jong
968609d06d IR: fix problems with symbol offsets and unused subroutines/chunks 2024-01-13 16:43:41 +01:00
Irmen de Jong
f2daa17b92 tweak some not optimizations
cleanup IR typestring
2024-01-05 17:49:56 +01:00
Irmen de Jong
6d9fccacb1 boolean not expression tweaks and optimizations 2024-01-05 13:32:16 +01:00
Irmen de Jong
eba0bde6f3 Merge branch 'optimize-st'
# Conflicts:
#	examples/test.p8
2023-12-17 02:11:01 +01:00
Irmen de Jong
b24df31c2b IR: fix codegen for routines returning in CPU Status register flag 2023-12-14 21:16:14 +01:00
Irmen de Jong
f97b3f23e2 optimize symbol table for IR 2023-12-12 19:26:27 +01:00
Irmen de Jong
af5ca2d0b8 vm: treat floats as 64 bits doubles. 0.0 printed as "0". 2023-11-21 00:57:56 +01:00
Irmen de Jong
c7d54570cc IR: sXX, CONCAT instructions now use 3 register format 2023-07-21 00:07:56 +02:00
Irmen de Jong
f9200a2b75 fix IR loader for romsub calls (calls to an address) 2023-07-02 23:41:15 +02:00
Irmen de Jong
bfaad1388c IR: handle split arrays without new custom opcodes 2023-06-03 01:51:02 +02:00
Irmen de Jong
52a77db60f adding split array type 2023-05-26 19:11:07 +02:00
Irmen de Jong
88ce9300bc fix parse cpureg in IR regspec 2023-05-14 21:02:40 +02:00
Irmen de Jong
0e3d75cfeb move irType() to intermediate module 2023-05-14 20:44:32 +02:00
Irmen de Jong
630c8a5faa IR: fix romsub encoding 2023-05-14 18:08:06 +02:00
Irmen de Jong
905921a684 IR: new (sys)call instructions that encapsulate the full subroutine call
to fix the bugs resulting from nesting subroutine calls (as param to another call etc)
2023-05-14 15:20:25 +02:00
Irmen de Jong
bff3c4f95c IR now converts IRInlineAsmChunk (of type IR) into regular code chunks directly.
.p8ir files usually won't contain <INLINEASM> nodes any longer
2023-05-09 21:04:31 +02:00
Irmen de Jong
efd7d6f0c0 tweak IR call args setting now via special SETPARAM instruction 2023-04-14 02:10:39 +02:00
Irmen de Jong
9b37ac483f vm fix str to word conversion
ir SYSCALL puts result(s) on value stack,  instead of on hardcoded r0, r1
2023-04-10 16:26:42 +02:00
Irmen de Jong
ac21e1be5c vm syscall instruction no longer fixed to r0 2023-04-10 13:44:05 +02:00
Irmen de Jong
9b952fbc44 tweaking IR instruction set branch instructions 2023-04-09 22:17:19 +02:00
Irmen de Jong
ccdf05e922 tweaking IR instruction formats 2023-04-09 16:12:16 +02:00
Irmen de Jong
fd269453a4 todos 2023-03-04 14:14:01 +01:00
Irmen de Jong
6f67fc0e02 ir: get rid of '_' symbol prefix 2022-11-03 21:54:53 +01:00
Irmen de Jong
a5ef353484 ir: fix memory mapped var as for loop counter 2022-10-30 14:54:47 +01:00
Irmen de Jong
7cc3cc3990 ir: fix non-code chunk linkage 2022-10-30 12:55:06 +01:00
Irmen de Jong
30ee65fd14 ir: ensure that block and sub labels are also on the first chunk in said block/sub 2022-10-23 18:54:08 +02:00
Irmen de Jong
fabae6e970 ir: fix handling of labeled chunks 2022-10-16 23:53:17 +02:00
Irmen de Jong
6fc89607d3 ir: moving to labeled chunks, no more IRLabel nodes 2022-10-07 00:34:56 +02:00
Irmen de Jong
af6be44676 ir: adding register usage inspections
fix compiler problems with untrimmed inlined asm, and when only a single return statement is present in a subroutine
2022-09-30 20:25:00 +02:00
Irmen de Jong
5a8f97a0b6 ir: adding last missing features to be able to encode all of Prog8 2022-09-30 16:01:00 +02:00
Irmen de Jong
1d2ce2cbeb consolidate IR line parse function 2022-09-27 18:02:57 +02:00
Irmen de Jong
9d219ae4b9 refactor 2022-09-27 03:32:39 +02:00
Irmen de Jong
1d65d63bd9 ir: making sure all names are scoped properly. textelite now runs in vm 2022-09-25 18:02:35 +02:00
Irmen de Jong
627ed51a1b IR: mem mapped vars and memory slabs 2022-09-19 15:20:40 +02:00