summary refs log tree commit diff
path: root/amd64.e
diff options
context:
space:
mode:
authorIrene Knapp <ireneista@irenes.space>2026-05-20 00:34:28 -0700
committerIrene Knapp <ireneista@irenes.space>2026-05-20 00:34:28 -0700
commit25bb4c7651323b6879064cfdfb74d1771f56abca (patch)
tree6452f1664d148f18d7c1b1f1c48fcd594bac28a2 /amd64.e
parenta89cd2c5f5f618eeab16fbef482f30f12640f58b (diff)
add a really powerful stack depth tracking feature for transforms to use
also said feature seems to work, which is flatly astonishing

just a little more now...

Force-Push: yes
Change-Id: I1bda7e99e524ac73a761859e86e01251e7d17525
Diffstat (limited to 'amd64.e')
-rw-r--r--amd64.e10
1 files changed, 10 insertions, 0 deletions
diff --git a/amd64.e b/amd64.e
index 4ffc64f..e098505 100644
--- a/amd64.e
+++ b/amd64.e
@@ -851,11 +851,21 @@ s" :cc-greater" keyword
 ~ Control flow instructions
 ~ ~~~~~~~~~~~~~~~~~~~~~~~~~
 
+~   Pretend to subtract right from left, and set the flags the same way as if
+~ we actually had.
+~
 ~ (output point, left register, right register -- output point)
 : cmp-reg64-reg64
   3roll rex-w 0x3B pack8 3unroll
   reg64 swap addressing-reg64 ;
 
+~   Pretend to xor left with right, and set the flags the same way as if we
+~ actually had.
+~
+~   The names of the condition codes can be a little confusing when using them
+~ after "test", because they're really premised on the idea that you did
+~ "cmp".
+~
 ~ (output point, left register, right register -- output point)
 : test-reg64-reg64
   3roll rex-w 0x85 pack8 3unroll