1
0
mirror of https://github.com/dschmenk/PLASMA.git synced 2025-02-04 14:31:51 +00:00

97 Commits

Author SHA1 Message Date
David Schmenk
286f627c72 Update tokens.h 2017-08-03 12:14:13 -07:00
dschmenk
4906a5a4c5 Remove GNU C warning 2017-08-03 06:29:46 -07:00
David Schmenk
9eb0e7286a Undo lambda funcs when RVALUE only statements 2017-08-02 20:42:18 -07:00
David Schmenk
64fe1b2e70 Lambda functions working except double parsed in function list ??? 2017-08-02 16:05:14 -07:00
David Schmenk
e65adf2050 Lambda WIP 2017-07-30 13:22:24 -07:00
Steven Flintham
f801d47b1b Check type in emit_dab and emit_daw
Without this the new optimisations can cause invalid code to be emitted.
2017-07-28 23:20:52 +01:00
Steven Flintham
75d5266fba Expose longer sequences to the optimiser
emit_seq() no longer emits directly but adds the sequence to a pending
sequence, which we emit only when necessary (e.g. when we're about to
emit a branch target, or when the parser is about to emit an opcode
directly).

This exposes more opportunities to the optimiser - in particular, the
earlier commit which taught the optimiser how to change things like
"SLW [n]:LLW [n]" to "DLW [n]" now gets a chance to kick in where one
statement updates a variable and the following statement uses the
updated value.
2017-07-28 23:09:26 +01:00
Steven Flintham
b6efb90995 Allow optimiser to introduce DUP opcodes 2017-07-28 23:06:02 +01:00
Steven Flintham
e9c4e062c3 Add more peephole optimisations 2017-07-28 23:03:44 +01:00
Steven Flintham
7ad91aa9e3 Wrap macro constants in parentheses
Later commits assume they can use macro constants without needing to
provide their own parentheses.
2017-07-28 22:59:04 +01:00
Steven Flintham
8a672501b7 Refactor elimination of *current* op in optimiser
The code to handle this was duplicated in two places; this pulls it out
to a common chunk of code triggered by negative values of freeops.

This isn't a big win here, but it sets us up to re-use this code in
later commits.
2017-07-28 22:57:46 +01:00
dschmenk
c4912583de Add CFFB to portable VM with test case 2017-07-27 19:15:57 -07:00
Steven Flintham
d5f5326962 Use opcode $5E for CFFB 2017-07-26 20:22:27 +01:00
Steven Flintham
8610d2f56e Add CFFB opcode 2017-07-18 20:37:43 +01:00
Dave Schmenk
976fddd094 Fix dereference from array (and found bug in dgr.pla with it) 2017-07-10 09:25:40 -07:00
Dave Schmenk
0b95baaefc Fix predef paramaters, multiple per line, and asm defs with parameters 2017-06-07 19:26:03 -07:00
David Schmenk
92535477ff Optimize NOT before branch 2017-06-07 17:41:50 -07:00
David Schmenk
7d35fd7726 Clean up scan_rewind string parsing and add branch optimizations 2017-06-07 14:27:52 -07:00
David Schmenk
d7d50f3d37 Remove 8-bit bunch license that shouldn't be there. 2017-06-06 13:02:51 -07:00
David Schmenk
def57dc263 Fix some pointer to pointer problems and scan_rewind with string quotes 2017-06-06 12:27:59 -07:00
David Schmenk
47ed2014e3 On the road to 1.0: source code cleanup 2017-06-03 08:08:30 -07:00
dschmenk
45500004dd On the road to 1.0: optimize MUL/DIV by POW2 2017-06-01 12:23:29 -07:00
dschmenk
b19956b3ba On the road to 1.0 2017-05-31 18:31:04 -07:00
David Schmenk
ee8fd77c26 Check for existing string in pool before copying CS string from aux mem 2017-03-26 20:36:03 -07:00
David Schmenk
8ed9c9868d Tab vs spaces cleanup 2017-02-12 19:35:33 -08:00
David Schmenk
73559b7f0b Remove useless type casts 2017-02-12 19:03:46 -08:00
Peter Ferrie
21b5c85d7a include header for uintptr_t 2017-01-22 10:51:59 -08:00
Peter Ferrie
afe3b284ed suppress GCC warnings 2017-01-06 15:08:28 -08:00
David Schmenk
bf3e1f668f Sanbox broken with w->[x] = ??. plasm broken with w->2 = ?? 2016-11-21 16:41:17 -08:00
dschmenk
c5d9fc8568 Remove SHIFT+LEFT_ARROW = delete for Apple ][ (shift key mod) 2016-08-01 13:10:12 -07:00
David Schmenk
9ab2daf808 Fix compliment(~ and #) and logical not (!) operator 2016-07-24 12:13:21 -07:00
Peter Ferrie
28ea563039 smaller alpha detection 2016-03-22 21:27:43 -07:00
dschmenk
3c29dcb7e2 Add literal hex chars to strings - thanks Martin Haye! 2016-01-29 13:53:37 -08:00
dschmenk
bfd0f367ad Add Martin's updates 2016-01-06 12:32:01 -08:00
dschmenk
f5e9dba8ac Increase ID length to 32 2016-01-06 12:22:15 -08:00
dschmenk
0614edd3e2 add increment and decrement statements 2016-01-06 12:13:48 -08:00
dschmenk
6110f6e3a3 Fix constant address function call 2015-12-10 06:37:07 -08:00
dschmenk
d6f3b5c475 Internet CHAT client/server 2015-12-01 16:56:35 -08:00
David Schmenk
8b662b09be Bump version # due to VM change 2015-10-26 18:20:08 -07:00
dschmenk
4aca6e749c Martin Haye's include processing code 2015-09-25 07:59:19 -07:00
dschmenk
4ef760f0e4 Update version # rto reflect latest fixes 2015-09-08 16:11:08 -07:00
David Schmenk
d09299ebd4 Fix keyboard reading for IIe so Virtual ][ works in full-screen 2015-07-03 19:51:32 -07:00
dschmenk
79c3e4248d Bump version # and update SANDBOX examples 2015-02-26 15:21:29 -08:00
dschmenk
3f48559d56 Add in-line strings 2015-02-26 13:02:53 -08:00
dschmenk
970ae32b88 Working HTTP server 2015-02-12 13:00:44 -08:00
dschmenk
5651c0b125 fix dynamic driver laoding and wiznet WIP 2015-02-03 08:56:44 -08:00
dschmenk
f2c9526c79 Huge update: memset() now matches C library for params. stdlib renamed
cmdsys so that dependencies have to be updated. Version now 0.8 -
getting close
2015-01-28 12:42:05 -08:00
dschmenk
561459cacf Oh the pain of parsing lvalues 2015-01-28 10:47:13 -08:00
David Schmenk
9455d23add Found a bug in BRNE/BREQ, WHEN parsing, ang got ARP request/reply
working
2015-01-24 18:04:14 -08:00
David Schmenk
c2dccbdc18 Fix pointer dereferences once and for all (I hope). Simplify memory
manager. Homing in on ethernet interface
2015-01-24 10:00:45 -08:00