From 53f52a67b7c5bb8af12c92a2f3a219e75dd9b0c3 Mon Sep 17 00:00:00 2001 From: Irene Knapp Date: Wed, 20 May 2026 18:23:07 -0700 Subject: colon, semicolon, and compiled integers all work with log-load now yay next up is to figure out why calling newly-defined docol-based words with it does not work Force-Push: yes Change-Id: I9c5f50d20f43ad8a15b6db58e046f1e0bb158266 --- transform.e | 32 ++++++++++++++++++++++---------- 1 file changed, 22 insertions(+), 10 deletions(-) (limited to 'transform.e') diff --git a/transform.e b/transform.e index 581cb0b..723484c 100644 --- a/transform.e +++ b/transform.e @@ -1466,6 +1466,7 @@ allocate-transform-state s" transform-state" variable swap-transform-variables ~ As usual, we do these in reverse. L@' log-load-comma + L@' lit L@' log-load-comma L@' log-load-find-execution-token L@' litstring @@ -1476,6 +1477,7 @@ allocate-transform-state s" transform-state" variable here @ s" lit" packstring 8 packalign here ! offset-to-target-address-space , ~ log-load-find-execution-token offset-to-target-address-space , ~ log-load-comma + offset-to-target-address-space , ~ lit swap , ~ the value offset-to-target-address-space , ~ log-load-comma @@ -1587,16 +1589,26 @@ allocate-transform-state s" transform-state" variable ~ below. It is likely to be extremely useful to read and understand ";asm" in ~ interpret.e before attempting to understand "log-load;asm". : log-load-semicolon-assembly-alternate - ~ TODO this is just unimplemented, which seems bad :D - ~ here @ pack-next 8 packalign here ! - ~ latest @ dup unhide-entry entry-to-execution-token - ~ ~ The codeword needs to be transformed to the target address space. - ~ dup 8 + host-address-space-to-target - ~ swap ! - - ~ ~ Since [ is an immediate word, we have to go to extra trouble to compile - ~ ~ it as part of ;asm. - ~ [ ' [ entry-to-execution-token , ] + ~ We generate code that statically invokes log-load-semicolon-assembly, + ~ which does all the actual work. There's quite a few steps, so it makes + ~ sense to have a word that bundles them up. + log-load-roll-log-address + + swap-transform-variables + ~ As usual, we do these in reverse. + L@' log-load-semicolon-assembly + swap-transform-variables + + ~ The stack delta of this call is 0. + offset-to-target-address-space , ~ log-load-semicolon-assembly + + log-load-unroll-log-address + + ~ This is where we would unhide the entry, but again, we don't do that. + + ~ Since [ is an immediate word, we have to go to extra trouble to compile + ~ it as part of ;. + [ ' [ entry-to-execution-token , ] ; make-immediate -- cgit 1.4.1