aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--TODO1
-rw-r--r--compiler/elymasGlobal.ey6
-rw-r--r--doc/global.md30
3 files changed, 34 insertions, 3 deletions
diff --git a/TODO b/TODO
index b8dee38..921f232 100644
--- a/TODO
+++ b/TODO
@@ -1,3 +1,4 @@
+* rewrite [ ... ] conds when everything is inline
* apply the trace extractor to non-tail situations
* forward scope-cannot-escape information
* inline trivial functions when optimizer generates ... /rax :movqImmReg /rax :callqReg sequence
diff --git a/compiler/elymasGlobal.ey b/compiler/elymasGlobal.ey
index b35aa7a..0a48385 100644
--- a/compiler/elymasGlobal.ey
+++ b/compiler/elymasGlobal.ey
@@ -1111,7 +1111,7 @@
:retn
]] /ey,-- defv
- # move topmost position marker left/upwards and shift stack
+ # move topmost position marker left/downwards and shift stack
[[
/rbx :popqReg
/rsp /rsi :movqRegReg
@@ -1130,7 +1130,7 @@
:retn
]] /ey--, defv
- # access element left (higher up in stack) of topmost position marker
+ # access element left (below in stack) of topmost position marker
[[
/rbx :popqReg
/rsp /rdi :movqRegReg
@@ -1143,7 +1143,7 @@
:retn
]] /ey_, defv
- # access element right (lower in stack) of topmost position marker
+ # access element right (above in stack) of topmost position marker
[[
/rbx :popqReg
/rsp /rdi :movqRegReg
diff --git a/doc/global.md b/doc/global.md
index 8880d5d..fbc9009 100644
--- a/doc/global.md
+++ b/doc/global.md
@@ -909,3 +909,33 @@ Takes two integers. Returns the larger one.
-----
Takes two integers. Returns the smaller one.
+
+
+`,`
+---
+Puts a position marker on the stack.
+
+
+`,--`
+-----
+Deletes the topmost position marker within the stack and compacts the stack contents to cover the hole.
+
+
+`--,`
+-----
+Deletes whatever is below the topmost position marker in the stack and compacts the stack contents to cover the hole.
+
+
+`_,`
+----
+Copies the stack element below the topmost position marker to the top of the stack.
+
+
+`,_`
+----
+Copies the stack element above the topmost position marker to the top of the stack.
+
+
+`,---`
+------
+Deletes all stack contents up to and including the topmost position marker.