about summary refs log tree commit diff stats
path: root/apps
diff options
context:
space:
mode:
authorKartik Agaram <vc@akkartik.com>2020-02-20 17:51:49 -0800
committerKartik Agaram <vc@akkartik.com>2020-02-20 17:51:49 -0800
commitf624fcbd1a5c1c6cce118e75046d779eee932128 (patch)
tree2ccca5e5734c497d2dd3d79f10b377e8a4b08182 /apps
parent3fd4de70581e311c9f181c03c54a5b96bae20296 (diff)
downloadmu-f624fcbd1a5c1c6cce118e75046d779eee932128.tar.gz
6035
Diffstat (limited to 'apps')
-rwxr-xr-xapps/mubin147659 -> 147647 bytes
-rw-r--r--apps/mu.subx36
2 files changed, 18 insertions, 18 deletions
diff --git a/apps/mu b/apps/mu
index 2615f56a..e6845871 100755
--- a/apps/mu
+++ b/apps/mu
Binary files differdiff --git a/apps/mu.subx b/apps/mu.subx
index 2861336e..85c3b04a 100644
--- a/apps/mu.subx
+++ b/apps/mu.subx
@@ -7158,42 +7158,41 @@ emit-subx-call-operand:  # out: (addr buffered-file), operand: (handle var)
     89/<- %ebp 4/r32/esp
     # . save registers
     50/push-eax
-    # eax = operand
-    8b/-> *(ebp+0xc) 0/r32/eax
+    56/push-esi
+    # esi = operand
+    8b/-> *(ebp+0xc) 6/r32/esi
     # if (operand->register) emit "%__"
     {
-      81 7/subop/compare *(eax+0x10) 0/imm32  # Var-register
+      81 7/subop/compare *(esi+0x10) 0/imm32  # Var-register
       74/jump-if-= break/disp8
 $emit-subx-call-operand:register:
       (write-buffered *(ebp+8) " %")
-      (write-buffered *(ebp+8) *(eax+0x10))  # Var-register
+      (write-buffered *(ebp+8) *(esi+0x10))  # Var-register
       e9/jump $emit-subx-call-operand:end/disp32
     }
     # else if (operand->stack-offset) emit "*(ebp+__)"
     {
-      81 7/subop/compare *(eax+0xc) 0/imm32  # Var-stack-offset
+      81 7/subop/compare *(esi+0xc) 0/imm32  # Var-stack-offset
       74/jump-if-= break/disp8
 $emit-subx-call-operand:stack:
       (write-buffered *(ebp+8) Space)
       (write-buffered *(ebp+8) "*(ebp+")
-      8b/-> *(ebp+0xc) 0/r32/eax
-      (print-int32-buffered *(ebp+8) *(eax+0xc))  # Var-stack-offset
+      (print-int32-buffered *(ebp+8) *(esi+0xc))  # Var-stack-offset
       (write-buffered *(ebp+8) ")")
       e9/jump $emit-subx-call-operand:end/disp32
     }
     # else if (operand->type == literal) emit "__"
     {
-      50/push-eax
-      8b/-> *(eax+4) 0/r32/eax  # Var-type
+      8b/-> *(esi+4) 0/r32/eax  # Var-type
       81 7/subop/compare *eax 0/imm32  # Tree-left
-      58/pop-to-eax
       75/jump-if-!= break/disp8
 $emit-subx-call-operand:literal:
       (write-buffered *(ebp+8) Space)
-      (write-buffered *(ebp+8) *eax)
+      (write-buffered *(ebp+8) *esi)  # Var-name
     }
 $emit-subx-call-operand:end:
     # . restore registers
+    5e/pop-to-esi
     58/pop-to-eax
     # . epilogue
     89/<- %esp 5/r32/ebp
@@ -7206,29 +7205,30 @@ emit-subx-var-as-rm32:  # out: (addr buffered-file), operand: (handle var)
     89/<- %ebp 4/r32/esp
     # . save registers
     50/push-eax
-    # eax = operand
-    8b/-> *(ebp+0xc) 0/r32/eax
+    56/push-esi
+    # esi = operand
+    8b/-> *(ebp+0xc) 6/r32/esi
     # if (operand->register) emit "%__"
     {
-      81 7/subop/compare *(eax+0x10) 0/imm32  # Var-register
+      81 7/subop/compare *(esi+0x10) 0/imm32  # Var-register
       74/jump-if-= break/disp8
 $emit-subx-var-as-rm32:register:
       (write-buffered *(ebp+8) " %")
-      (write-buffered *(ebp+8) *(eax+0x10))  # Var-register
+      (write-buffered *(ebp+8) *(esi+0x10))  # Var-register
     }
     # else if (operand->stack-offset) emit "*(ebp+__)"
     {
-      81 7/subop/compare *(eax+0xc) 0/imm32  # Var-stack-offset
+      81 7/subop/compare *(esi+0xc) 0/imm32  # Var-stack-offset
       74/jump-if-= break/disp8
 $emit-subx-var-as-rm32:stack:
       (write-buffered *(ebp+8) Space)
       (write-buffered *(ebp+8) "*(ebp+")
-      8b/-> *(ebp+0xc) 0/r32/eax
-      (print-int32-buffered *(ebp+8) *(eax+0xc))  # Var-stack-offset
+      (print-int32-buffered *(ebp+8) *(esi+0xc))  # Var-stack-offset
       (write-buffered *(ebp+8) ")")
     }
 $emit-subx-var-as-rm32:end:
     # . restore registers
+    5e/pop-to-esi
     58/pop-to-eax
     # . epilogue
     89/<- %esp 5/r32/ebp
n299' href='#n299'>299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416