https://github.com/akkartik/mu/blob/master/apps/mu.subx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237 == data
238
239 Program:
240 _Program-functions:
241 0/imm32
242 _Program-functions->payload:
243 0/imm32
244 _Program-types:
245 0/imm32
246 _Program-types->payload:
247 0/imm32
248 _Program-signatures:
249 0/imm32
250 _Program-signatures->payload:
251 0/imm32
252
253
254
255
256
257
258
259
260
261
262
263
264 Function-name:
265 0/imm32
266 Function-inouts:
267 8/imm32
268 Function-outputs:
269 0x10/imm32
270 Function-body:
271 0x18/imm32
272 Function-next:
273 0x20/imm32
274 Function-size:
275 0x28/imm32/40
276
277 Primitive-name:
278 0/imm32
279 Primitive-inouts:
280 8/imm32
281 Primitive-outputs:
282 0x10/imm32
283 Primitive-subx-name:
284 0x18/imm32
285 Primitive-subx-rm32:
286 0x20/imm32
287 Primitive-subx-r32:
288 0x24/imm32
289 Primitive-subx-imm32:
290 0x28/imm32
291 Primitive-subx-imm8:
292 0x2c/imm32
293 Primitive-subx-disp32:
294 0x30/imm32
295 Primitive-subx-xm32:
296 0x34/imm32
297 Primitive-subx-x32:
298 0x38/imm32
299 Primitive-next:
300 0x3c/imm32
301 Primitive-size:
302 0x44/imm32/68
303
304 Stmt-tag:
305 0/imm32
306
307 Block-stmts:
308 4/imm32
309 Block-var:
310 0xc/imm32
311
312 Stmt1-operation:
313 4/imm32
314 Stmt1-inouts:
315 0xc/imm32
316 Stmt1-outputs:
317 0x14/imm32
318
319 Vardef-var:
320 4/imm32
321
322 Regvardef-operation:
323 4/imm32
324 Regvardef-inouts:
325 0xc/imm32
326 Regvardef-outputs:
327 0x14/imm32
328
329 Stmt-size:
330 0x1c/imm32
331
332 Var-name:
333 0/imm32
334 Var-type:
335 8/imm32
336 Var-block-depth:
337 0x10/imm32
338 Var-offset:
339 0x14/imm32
340 Var-register:
341 0x18/imm32
342 Var-size:
343 0x20/imm32
344
345 List-value:
346 0/imm32
347 List-next:
348 8/imm32
349 List-size:
350 0x10/imm32
351
352
353 Stmt-var-value:
354 0/imm32
355 Stmt-var-next:
356 8/imm32
357 Stmt-var-is-deref:
358 0x10/imm32
359 Stmt-var-size:
360 0x14/imm32
361
362
363
364 Live-var-value:
365 0/imm32
366 Live-var-register-spilled:
367 8/imm32
368 Live-var-size:
369 0xc/imm32
370
371
372
373 Type-tree-is-atom:
374 0/imm32
375
376 Type-tree-value:
377 4/imm32
378 Type-tree-value-size:
379 8/imm32
380 Type-tree-parameter-name:
381 8/imm32
382
383 Type-tree-left:
384 4/imm32
385 Type-tree-right:
386 0xc/imm32
387
388 Type-tree-size:
389 0x14/imm32
390
391
392
393
394 Type-id:
395 0/imm32/write
396 0/imm32/read
397 0x100/imm32/size
398
399 0/imm32
400
401 "int"/imm32
402 "addr"/imm32
403 "array"/imm32
404 "handle"/imm32
405 "boolean"/imm32
406 0/imm32
407
408 "offset"/imm32
409
410 "byte"/imm32
411 0/imm32
412
413 0/imm32
414
415 "stream"/imm32
416 "slice"/imm32
417 "code-point"/imm32
418 "grapheme"/imm32
419
420
421 "float"/imm32
422
423
424 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32
425 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32
426 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32
427 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32
428 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32
429 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32 0/imm32
430
431 Primitive-type-ids:
432 0x40
433
434
435
436
437 Typeinfo-id:
438 0/imm32
439 Typeinfo-fields:
440 4/imm32
441
442
443
444
445
446 Typeinfo-total-size-in-bytes:
447 0xc/imm32
448 Typeinfo-next:
449 0x10/imm32
450 Typeinfo-size:
451 0x18/imm32
452
453
454
455 Typeinfo-fields-row-size:
456 0x10/imm32
457
458
459
460
461
462
463
464
465 Typeinfo-entry-input-var:
466 0/imm32
467 Typeinfo-entry-index:
468 8/imm32
469 Typeinfo-entry-output-var:
470 0xc/imm32
471 Typeinfo-entry-size:
472 0x14/imm32
473
474 == code
475
476 Entry:
477
478 89/<- %ebp 4/r32/esp
479 (new-segment *Heap-size Heap)
480
481 {
482
483 81 7/subop/compare *ebp 1/imm32
484 7e/jump-if-<= break/disp8
485
486 (kernel-string-equal? *(ebp+8) "test")
487 3d/compare-eax-and 0/imm32/false
488 74/jump-if-= break/disp8
489
490 (run-tests)
491
492 8b/-> *Num-test-failures 3/r32/ebx
493 eb/jump $mu-main:end/disp8
494 }
495
496 (convert-mu Stdin Stdout Stderr 0)
497 (flush Stdout)
498
499 bb/copy-to-ebx 0/imm32
500 $mu-main:end:
501 e8/call syscall_exit/disp32
502
503 convert-mu:
504
505 55/push-ebp
506 89/<- %ebp 4/r32/esp
507
508 50/push-eax
509
510 c7 0/subop/copy *Next-block-index 1/imm32
511 8b/-> *Primitive-type-ids 0/r32/eax
512 89/<- *Type-id 0/r32/eax
513 c7 0/subop/copy *_Program-functions 0/imm32
514 c7 0/subop/copy *_Program-functions->payload 0/imm32
515 c7 0/subop/copy *_Program-types 0/imm32
516 c7 0/subop/copy *_Program-types->payload 0/imm32
517 c7 0/subop/copy *_Program-signatures 0/imm32
518 c7 0/subop/copy *_Program-signatures->payload 0/imm32
519
520 (parse-mu *(ebp+8) *(ebp+0x10) *(ebp+0x14))
521 (populate-mu-type-sizes *(ebp+0x10) *(ebp+0x14))
522
523 (check-mu-types *(ebp+0x10) *(ebp+0x14))
524 (emit-subx *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
525 $convert-mu:end:
526
527 58/pop-to-eax
528
529 89/<- %esp 5/r32/ebp
530 5d/pop-to-ebp
531 c3/return
532
533 test-convert-empty-input:
534
535
536 55/push-ebp
537 89/<- %ebp 4/r32/esp
538
539 (clear-stream _test-input-stream)
540 (clear-stream $_test-input-buffered-file->buffer)
541 (clear-stream _test-output-stream)
542 (clear-stream $_test-output-buffered-file->buffer)
543
544 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
545 (flush _test-output-buffered-file)
546 (check-stream-equal _test-output-stream "" "F - test-convert-empty-input")
547
548 89/<- %esp 5/r32/ebp
549 5d/pop-to-ebp
550 c3/return
551
552 test-convert-function-skeleton:
553
554 55/push-ebp
555 89/<- %ebp 4/r32/esp
556
557 (clear-stream _test-input-stream)
558 (clear-stream $_test-input-buffered-file->buffer)
559 (clear-stream _test-output-stream)
560 (clear-stream $_test-output-buffered-file->buffer)
561
562 (write _test-input-stream "fn foo {\n")
563 (write _test-input-stream "}\n")
564
565 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
566 (flush _test-output-buffered-file)
567 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
573
574 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-skeleton/0")
575 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-skeleton/1")
576 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-skeleton/2")
577 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-skeleton/3")
578 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-skeleton/4")
579 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-skeleton/5")
580 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-skeleton/6")
581 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-skeleton/7")
582
583 89/<- %esp 5/r32/ebp
584 5d/pop-to-ebp
585 c3/return
586
587 test-convert-multiple-function-skeletons:
588
589 55/push-ebp
590 89/<- %ebp 4/r32/esp
591
592 (clear-stream _test-input-stream)
593 (clear-stream $_test-input-buffered-file->buffer)
594 (clear-stream _test-output-stream)
595 (clear-stream $_test-output-buffered-file->buffer)
596
597 (write _test-input-stream "fn foo {\n")
598 (write _test-input-stream "}\n")
599 (write _test-input-stream "fn bar {\n")
600 (write _test-input-stream "}\n")
601
602 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
603 (flush _test-output-buffered-file)
604 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
610
611 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-multiple-function-skeletons/0")
612 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-multiple-function-skeletons/1")
613 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-multiple-function-skeletons/2")
614 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-multiple-function-skeletons/3")
615 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-multiple-function-skeletons/4")
616 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-multiple-function-skeletons/5")
617 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-multiple-function-skeletons/6")
618 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-multiple-function-skeletons/7")
619
620 (check-next-stream-line-equal _test-output-stream "bar:" "F - test-convert-multiple-function-skeletons/10")
621 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-multiple-function-skeletons/11")
622 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-multiple-function-skeletons/12")
623 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-multiple-function-skeletons/13")
624 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-multiple-function-skeletons/14")
625 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-multiple-function-skeletons/15")
626 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-multiple-function-skeletons/16")
627 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-multiple-function-skeletons/17")
628
629 89/<- %esp 5/r32/ebp
630 5d/pop-to-ebp
631 c3/return
632
633 test-convert-function-with-arg:
634
635 55/push-ebp
636 89/<- %ebp 4/r32/esp
637
638 (clear-stream _test-input-stream)
639 (clear-stream $_test-input-buffered-file->buffer)
640 (clear-stream _test-output-stream)
641 (clear-stream $_test-output-buffered-file->buffer)
642
643 (write _test-input-stream "fn foo n: int {\n")
644 (write _test-input-stream "}\n")
645
646 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
647 (flush _test-output-buffered-file)
648 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
654
655 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-arg/0")
656 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-arg/1")
657 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-arg/2")
658 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-arg/3")
659 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-arg/4")
660 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-arg/5")
661 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-arg/6")
662 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-arg/7")
663
664 89/<- %esp 5/r32/ebp
665 5d/pop-to-ebp
666 c3/return
667
668 test-convert-function-with-arg-and-body:
669
670 55/push-ebp
671 89/<- %ebp 4/r32/esp
672
673 (clear-stream _test-input-stream)
674 (clear-stream $_test-input-buffered-file->buffer)
675 (clear-stream _test-output-stream)
676 (clear-stream $_test-output-buffered-file->buffer)
677
678 (write _test-input-stream "fn foo n: int {\n")
679 (write _test-input-stream " increment n\n")
680 (write _test-input-stream "}\n")
681
682 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
683 (flush _test-output-buffered-file)
684 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
690
691 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-arg-and-body/0")
692 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-arg-and-body/1")
693 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-arg-and-body/2")
694 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-arg-and-body/3")
695 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-arg-and-body/4")
696 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-arg-and-body/5")
697 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0x00000008)" "F - test-convert-function-with-arg-and-body/6")
698 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-arg-and-body/7")
699 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-arg-and-body/8")
700 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-arg-and-body/9")
701 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-arg-and-body/10")
702 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-arg-and-body/11")
703 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-arg-and-body/12")
704
705 89/<- %esp 5/r32/ebp
706 5d/pop-to-ebp
707 c3/return
708
709 test-convert-function-distinguishes-args:
710
711 55/push-ebp
712 89/<- %ebp 4/r32/esp
713
714 (clear-stream _test-input-stream)
715 (clear-stream $_test-input-buffered-file->buffer)
716 (clear-stream _test-output-stream)
717 (clear-stream $_test-output-buffered-file->buffer)
718
719 (write _test-input-stream "fn foo a: int, b: int {\n")
720 (write _test-input-stream " increment b\n")
721 (write _test-input-stream "}\n")
722
723 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
724 (flush _test-output-buffered-file)
725 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
731
732 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-distinguishes-args/0")
733 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-distinguishes-args/1")
734 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-distinguishes-args/2")
735 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-distinguishes-args/3")
736 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-distinguishes-args/4")
737 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-distinguishes-args/5")
738 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0x0000000c)" "F - test-convert-function-distinguishes-args/6")
739 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-distinguishes-args/7")
740 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-distinguishes-args/8")
741 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-distinguishes-args/9")
742 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-distinguishes-args/10")
743 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-distinguishes-args/11")
744 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-distinguishes-args/12")
745
746 89/<- %esp 5/r32/ebp
747 5d/pop-to-ebp
748 c3/return
749
750 test-convert-function-returns-result:
751
752 55/push-ebp
753 89/<- %ebp 4/r32/esp
754
755 (clear-stream _test-input-stream)
756 (clear-stream $_test-input-buffered-file->buffer)
757 (clear-stream _test-output-stream)
758 (clear-stream $_test-output-buffered-file->buffer)
759
760 (write _test-input-stream "fn foo a: int, b: int -> result/eax: int {\n")
761 (write _test-input-stream " result <- copy a\n")
762 (write _test-input-stream " result <- increment\n")
763 (write _test-input-stream "}\n")
764
765 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
766 (flush _test-output-buffered-file)
767 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
773
774 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-returns-result/0")
775 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-returns-result/1")
776 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-returns-result/2")
777 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-returns-result/3")
778 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-returns-result/4")
779 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-returns-result/5")
780 (check-next-stream-line-equal _test-output-stream " 8b/-> *(ebp+0x00000008) 0x00000000/r32" "F - test-convert-function-returns-result/6")
781 (check-next-stream-line-equal _test-output-stream " 40/increment-eax" "F - test-convert-function-returns-result/7")
782 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-returns-result/8")
783 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-returns-result/9")
784 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-returns-result/10")
785 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-returns-result/11")
786 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-returns-result/12")
787 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-returns-result/13")
788
789 89/<- %esp 5/r32/ebp
790 5d/pop-to-ebp
791 c3/return
792
793 test-convert-function-with-literal-arg:
794
795 55/push-ebp
796 89/<- %ebp 4/r32/esp
797
798 (clear-stream _test-input-stream)
799 (clear-stream $_test-input-buffered-file->buffer)
800 (clear-stream _test-output-stream)
801 (clear-stream $_test-output-buffered-file->buffer)
802
803 (write _test-input-stream "fn foo a: int, b: int -> result/eax: int {\n")
804 (write _test-input-stream " result <- copy a\n")
805 (write _test-input-stream " result <- add 1\n")
806 (write _test-input-stream "}\n")
807
808 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
809 (flush _test-output-buffered-file)
810 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
816
817 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-literal-arg/0")
818 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-literal-arg/1")
819 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-literal-arg/2")
820 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-literal-arg/3")
821 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-literal-arg/4")
822 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-literal-arg/5")
823 (check-next-stream-line-equal _test-output-stream " 8b/-> *(ebp+0x00000008) 0x00000000/r32" "F - test-convert-function-with-literal-arg/6")
824 (check-next-stream-line-equal _test-output-stream " 05/add-to-eax 1/imm32" "F - test-convert-function-with-literal-arg/7")
825 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-literal-arg/8")
826 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-literal-arg/9")
827 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-literal-arg/10")
828 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-literal-arg/11")
829 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-literal-arg/12")
830 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-literal-arg/13")
831
832 89/<- %esp 5/r32/ebp
833 5d/pop-to-ebp
834 c3/return
835
836 test-convert-function-with-literal-arg-2:
837
838 55/push-ebp
839 89/<- %ebp 4/r32/esp
840
841 (clear-stream _test-input-stream)
842 (clear-stream $_test-input-buffered-file->buffer)
843 (clear-stream _test-output-stream)
844 (clear-stream $_test-output-buffered-file->buffer)
845
846 (write _test-input-stream "fn foo a: int, b: int -> result/ebx: int {\n")
847 (write _test-input-stream " result <- copy a\n")
848 (write _test-input-stream " result <- add 1\n")
849 (write _test-input-stream "}\n")
850
851 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
852 (flush _test-output-buffered-file)
853 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
859
860 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-literal-arg-2/0")
861 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-literal-arg-2/1")
862 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-literal-arg-2/2")
863 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-literal-arg-2/3")
864 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-literal-arg-2/4")
865 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-literal-arg-2/5")
866 (check-next-stream-line-equal _test-output-stream " 8b/-> *(ebp+0x00000008) 0x00000003/r32" "F - test-convert-function-with-literal-arg-2/6")
867 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %ebx 1/imm32" "F - test-convert-function-with-literal-arg-2/7")
868 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-literal-arg-2/8")
869 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-literal-arg-2/9")
870 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-literal-arg-2/10")
871 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-literal-arg-2/11")
872 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-literal-arg-2/12")
873 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-literal-arg-2/13")
874
875 89/<- %esp 5/r32/ebp
876 5d/pop-to-ebp
877 c3/return
878
879 test-convert-function-call-with-literal-arg:
880
881 55/push-ebp
882 89/<- %ebp 4/r32/esp
883
884 (clear-stream _test-input-stream)
885 (clear-stream $_test-input-buffered-file->buffer)
886 (clear-stream _test-output-stream)
887 (clear-stream $_test-output-buffered-file->buffer)
888
889 (write _test-input-stream "fn main -> result/ebx: int {\n")
890 (write _test-input-stream " result <- do-add 3 4\n")
891 (write _test-input-stream "}\n")
892 (write _test-input-stream "fn do-add a: int, b: int -> result/ebx: int {\n")
893 (write _test-input-stream " result <- copy a\n")
894 (write _test-input-stream " result <- add b\n")
895 (write _test-input-stream "}\n")
896
897 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
898 (flush _test-output-buffered-file)
899 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
905
906 (check-next-stream-line-equal _test-output-stream "main:" "F - test-convert-function-call-with-literal-arg/0")
907 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call-with-literal-arg/1")
908 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call-with-literal-arg/2")
909 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call-with-literal-arg/3")
910 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-call-with-literal-arg/4")
911 (check-next-stream-line-equal _test-output-stream "$main:0x00000001:loop:" "F - test-convert-function-call-with-literal-arg/5")
912 (check-next-stream-line-equal _test-output-stream " (do-add 3 4)" "F - test-convert-function-call-with-literal-arg/6")
913 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-call-with-literal-arg/7")
914 (check-next-stream-line-equal _test-output-stream "$main:0x00000001:break:" "F - test-convert-function-call-with-literal-arg/8")
915 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call-with-literal-arg/9")
916 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call-with-literal-arg/10")
917 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call-with-literal-arg/11")
918 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call-with-literal-arg/12")
919 (check-next-stream-line-equal _test-output-stream "do-add:" "F - test-convert-function-call-with-literal-arg/13")
920 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call-with-literal-arg/14")
921 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call-with-literal-arg/15")
922 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call-with-literal-arg/16")
923 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-call-with-literal-arg/17")
924 (check-next-stream-line-equal _test-output-stream "$do-add:0x00000002:loop:" "F - test-convert-function-call-with-literal-arg/18")
925 (check-next-stream-line-equal _test-output-stream " 8b/-> *(ebp+0x00000008) 0x00000003/r32" "F - test-convert-function-call-with-literal-arg/19")
926 (check-next-stream-line-equal _test-output-stream " 03/add *(ebp+0x0000000c) 0x00000003/r32" "F - test-convert-function-call-with-literal-arg/20")
927 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-call-with-literal-arg/21")
928 (check-next-stream-line-equal _test-output-stream "$do-add:0x00000002:break:" "F - test-convert-function-call-with-literal-arg/22")
929 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call-with-literal-arg/23")
930 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call-with-literal-arg/24")
931 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call-with-literal-arg/25")
932 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call-with-literal-arg/26")
933
934 89/<- %esp 5/r32/ebp
935 5d/pop-to-ebp
936 c3/return
937
938 test-convert-function-call-with-signature:
939
940 55/push-ebp
941 89/<- %ebp 4/r32/esp
942
943 (clear-stream _test-input-stream)
944 (clear-stream $_test-input-buffered-file->buffer)
945 (clear-stream _test-output-stream)
946 (clear-stream $_test-output-buffered-file->buffer)
947
948 (write _test-input-stream "fn main -> result/ebx: int {\n")
949 (write _test-input-stream " result <- do-add 3 4\n")
950 (write _test-input-stream "}\n")
951 (write _test-input-stream "sig do-add a: int, b: int -> result/ebx: int\n")
952
953 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
954 (flush _test-output-buffered-file)
955 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
961
962 (check-next-stream-line-equal _test-output-stream "main:" "F - test-convert-function-call-with-signature/0")
963 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call-with-signature/1")
964 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call-with-signature/2")
965 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call-with-signature/3")
966 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-call-with-signature/4")
967 (check-next-stream-line-equal _test-output-stream "$main:0x00000001:loop:" "F - test-convert-function-call-with-signature/5")
968 (check-next-stream-line-equal _test-output-stream " (do-add 3 4)" "F - test-convert-function-call-with-signature/6")
969 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-call-with-signature/7")
970 (check-next-stream-line-equal _test-output-stream "$main:0x00000001:break:" "F - test-convert-function-call-with-signature/8")
971 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call-with-signature/9")
972 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call-with-signature/10")
973 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call-with-signature/11")
974 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call-with-signature/12")
975
976 89/<- %esp 5/r32/ebp
977 5d/pop-to-ebp
978 c3/return
979
980 test-convert-function-with-local-var-in-mem:
981
982 55/push-ebp
983 89/<- %ebp 4/r32/esp
984
985 (clear-stream _test-input-stream)
986 (clear-stream $_test-input-buffered-file->buffer)
987 (clear-stream _test-output-stream)
988 (clear-stream $_test-output-buffered-file->buffer)
989
990 (write _test-input-stream "fn foo {\n")
991 (write _test-input-stream " var x: int\n")
992 (write _test-input-stream " increment x\n")
993 (write _test-input-stream "}\n")
994
995 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
996 (flush _test-output-buffered-file)
997 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
1003
1004 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-local-var-in-mem/0")
1005 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-local-var-in-mem/1")
1006 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-local-var-in-mem/2")
1007 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-local-var-in-mem/3")
1008 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-in-mem/4")
1009 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-local-var-in-mem/5")
1010 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-local-var-in-mem/6")
1011 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0xfffffffc)" "F - test-convert-function-with-local-var-in-mem/7")
1012 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-local-var-in-mem/8")
1013 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-in-mem/9")
1014 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-local-var-in-mem/10")
1015 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-local-var-in-mem/11")
1016 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-local-var-in-mem/12")
1017 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-local-var-in-mem/13")
1018 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-local-var-in-mem/14")
1019
1020 89/<- %esp 5/r32/ebp
1021 5d/pop-to-ebp
1022 c3/return
1023
1024 test-convert-invalid-literal:
1025
1026 55/push-ebp
1027 89/<- %ebp 4/r32/esp
1028
1029 (clear-stream _test-input-stream)
1030 (clear-stream $_test-input-buffered-file->buffer)
1031 (clear-stream _test-output-stream)
1032 (clear-stream $_test-output-buffered-file->buffer)
1033 (clear-stream _test-error-stream)
1034 (clear-stream $_test-error-buffered-file->buffer)
1035
1036 68/push 0/imm32
1037 68/push 0/imm32
1038 89/<- %edx 4/r32/esp
1039 (tailor-exit-descriptor %edx 0x10)
1040
1041 (write _test-input-stream "fn foo {\n")
1042 (write _test-input-stream " increment 1n\n")
1043 (write _test-input-stream "}\n")
1044
1045 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1046
1047
1048 89/<- %edx 4/r32/esp
1049 (flush _test-output-buffered-file)
1050 (flush _test-error-buffered-file)
1051 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1057
1058 (check-stream-equal _test-output-stream "" "F - test-convert-invalid-literal: output should be empty")
1059 (check-next-stream-line-equal _test-error-stream "fn foo: variable '1n' cannot begin with a digit (or do you have a typo in a number?)" "F - test-convert-invalid-literal: error message")
1060
1061 (check-ints-equal *(edx+4) 2 "F - test-convert-invalid-literal: exit status")
1062
1063 81 0/subop/add %esp 8/imm32
1064
1065 5d/pop-to-ebp
1066 c3/return
1067
1068 test-local-var-in-mem-has-no-initializer:
1069
1070 55/push-ebp
1071 89/<- %ebp 4/r32/esp
1072
1073 (clear-stream _test-input-stream)
1074 (clear-stream $_test-input-buffered-file->buffer)
1075 (clear-stream _test-output-stream)
1076 (clear-stream $_test-output-buffered-file->buffer)
1077 (clear-stream _test-error-stream)
1078 (clear-stream $_test-error-buffered-file->buffer)
1079
1080 68/push 0/imm32
1081 68/push 0/imm32
1082 89/<- %edx 4/r32/esp
1083 (tailor-exit-descriptor %edx 0x10)
1084
1085 (write _test-input-stream "fn foo {\n")
1086 (write _test-input-stream " var x: int <- copy 0\n")
1087 (write _test-input-stream " increment x\n")
1088 (write _test-input-stream "}\n")
1089
1090 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1091
1092
1093 89/<- %edx 4/r32/esp
1094 (flush _test-output-buffered-file)
1095 (flush _test-error-buffered-file)
1096 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1102
1103 (check-stream-equal _test-output-stream "" "F - test-var-in-mem-has-no-initializer: output should be empty")
1104 (check-next-stream-line-equal _test-error-stream "fn foo: var x: variables on the stack can't take an initializer" "F - test-var-in-mem-has-no-initializer: error message")
1105
1106 (check-ints-equal *(edx+4) 2 "F - test-var-in-mem-has-no-initializer: exit status")
1107
1108 81 0/subop/add %esp 8/imm32
1109
1110 5d/pop-to-ebp
1111 c3/return
1112
1113 test-convert-function-with-local-var-with-compound-type-in-mem:
1114
1115 55/push-ebp
1116 89/<- %ebp 4/r32/esp
1117
1118 (clear-stream _test-input-stream)
1119 (clear-stream $_test-input-buffered-file->buffer)
1120 (clear-stream _test-output-stream)
1121 (clear-stream $_test-output-buffered-file->buffer)
1122
1123 (write _test-input-stream "fn foo {\n")
1124 (write _test-input-stream " var x: (addr int)\n")
1125 (write _test-input-stream " copy-to x, 0\n")
1126 (write _test-input-stream "}\n")
1127
1128 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
1129 (flush _test-output-buffered-file)
1130 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
1136
1137 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-local-var-with-compound-type-in-mem/0")
1138 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-local-var-with-compound-type-in-mem/1")
1139 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-local-var-with-compound-type-in-mem/2")
1140 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-local-var-with-compound-type-in-mem/3")
1141 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-with-compound-type-in-mem/4")
1142 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-local-var-with-compound-type-in-mem/5")
1143 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-local-var-with-compound-type-in-mem/6")
1144 (check-next-stream-line-equal _test-output-stream " c7 0/subop/copy *(ebp+0xfffffffc) 0/imm32" "F - test-convert-function-with-local-var-with-compound-type-in-mem/7")
1145 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-local-var-with-compound-type-in-mem/8")
1146 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-with-compound-type-in-mem/9")
1147 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-local-var-with-compound-type-in-mem/10")
1148 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-local-var-with-compound-type-in-mem/11")
1149 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-local-var-with-compound-type-in-mem/12")
1150 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-local-var-with-compound-type-in-mem/13")
1151 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-local-var-with-compound-type-in-mem/14")
1152
1153 89/<- %esp 5/r32/ebp
1154 5d/pop-to-ebp
1155 c3/return
1156
1157 test-convert-function-with-local-var-in-reg:
1158
1159 55/push-ebp
1160 89/<- %ebp 4/r32/esp
1161
1162 (clear-stream _test-input-stream)
1163 (clear-stream $_test-input-buffered-file->buffer)
1164 (clear-stream _test-output-stream)
1165 (clear-stream $_test-output-buffered-file->buffer)
1166
1167 (write _test-input-stream "fn foo {\n")
1168 (write _test-input-stream " var x/ecx: int <- copy 3\n")
1169 (write _test-input-stream " x <- increment\n")
1170 (write _test-input-stream "}\n")
1171
1172 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
1173 (flush _test-output-buffered-file)
1174 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
1180
1181 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-local-var-in-reg/0")
1182 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-local-var-in-reg/1")
1183 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-local-var-in-reg/2")
1184 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-local-var-in-reg/3")
1185 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-in-reg/4")
1186 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-local-var-in-reg/5")
1187 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-function-with-local-var-in-reg/6")
1188 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-convert-function-with-local-var-in-reg/7")
1189 (check-next-stream-line-equal _test-output-stream " 41/increment-ecx" "F - test-convert-function-with-local-var-in-reg/8")
1190 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-function-with-local-var-in-reg/9")
1191 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-in-reg/10")
1192 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-local-var-in-reg/11")
1193 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-local-var-in-reg/12")
1194 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-local-var-in-reg/13")
1195 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-local-var-in-reg/14")
1196 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-local-var-in-reg/15")
1197
1198 89/<- %esp 5/r32/ebp
1199 5d/pop-to-ebp
1200 c3/return
1201
1202 test-convert-function-with-allocate:
1203
1204 55/push-ebp
1205 89/<- %ebp 4/r32/esp
1206
1207 (clear-stream _test-input-stream)
1208 (clear-stream $_test-input-buffered-file->buffer)
1209 (clear-stream _test-output-stream)
1210 (clear-stream $_test-output-buffered-file->buffer)
1211
1212 (write _test-input-stream "fn foo {\n")
1213 (write _test-input-stream " var x/ecx: (addr handle int) <- copy 0\n")
1214 (write _test-input-stream " allocate x\n")
1215 (write _test-input-stream "}\n")
1216
1217 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
1218 (flush _test-output-buffered-file)
1219 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
1225
1226 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-allocate/0")
1227 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-allocate/1")
1228 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-allocate/2")
1229 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-allocate/3")
1230 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-allocate/4")
1231 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-allocate/5")
1232 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-function-with-allocate/6")
1233 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 0/imm32" "F - test-convert-function-with-allocate/7")
1234 (check-next-stream-line-equal _test-output-stream " (allocate Heap 0x00000004 %ecx)" "F - test-convert-function-with-allocate/8")
1235 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-function-with-allocate/9")
1236 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-allocate/10")
1237 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-allocate/11")
1238 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-allocate/12")
1239 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-allocate/13")
1240 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-allocate/14")
1241 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-allocate/15")
1242
1243 89/<- %esp 5/r32/ebp
1244 5d/pop-to-ebp
1245 c3/return
1246
1247 test-initializer-in-hex:
1248
1249 55/push-ebp
1250 89/<- %ebp 4/r32/esp
1251
1252 (clear-stream _test-input-stream)
1253 (clear-stream $_test-input-buffered-file->buffer)
1254 (clear-stream _test-output-stream)
1255 (clear-stream $_test-output-buffered-file->buffer)
1256 (clear-stream _test-error-stream)
1257 (clear-stream $_test-error-buffered-file->buffer)
1258
1259 68/push 0/imm32
1260 68/push 0/imm32
1261 89/<- %edx 4/r32/esp
1262 (tailor-exit-descriptor %edx 0x10)
1263
1264 (write _test-input-stream "fn foo {\n")
1265 (write _test-input-stream " var x/ecx: int <- copy 10\n")
1266 (write _test-input-stream "}\n")
1267
1268 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1269
1270
1271 89/<- %edx 4/r32/esp
1272 (flush _test-output-buffered-file)
1273 (flush _test-error-buffered-file)
1274 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1280
1281 (check-stream-equal _test-output-stream "" "F - test-initializer-in-hex: output should be empty")
1282 (check-next-stream-line-equal _test-error-stream "literal integers are always hex in Mu; either start '10' with a '0x' to be unambiguous, or convert it to decimal." "F - test-initializer-in-hex: error message")
1283
1284 (check-ints-equal *(edx+4) 2 "F - test-initializer-in-hex: exit status")
1285
1286 81 0/subop/add %esp 8/imm32
1287
1288 5d/pop-to-ebp
1289 c3/return
1290
1291 test-convert-function-with-second-local-var-in-same-reg:
1292
1293 55/push-ebp
1294 89/<- %ebp 4/r32/esp
1295
1296 (clear-stream _test-input-stream)
1297 (clear-stream $_test-input-buffered-file->buffer)
1298 (clear-stream _test-output-stream)
1299 (clear-stream $_test-output-buffered-file->buffer)
1300
1301 (write _test-input-stream "fn foo {\n")
1302 (write _test-input-stream " var x/ecx: int <- copy 3\n")
1303 (write _test-input-stream " var y/ecx: int <- copy 4\n")
1304 (write _test-input-stream " y <- increment\n")
1305 (write _test-input-stream "}\n")
1306
1307 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
1308 (flush _test-output-buffered-file)
1309 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
1315
1316 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-second-local-var-in-same-reg/0")
1317 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-second-local-var-in-same-reg/1")
1318 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-second-local-var-in-same-reg/2")
1319 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-second-local-var-in-same-reg/3")
1320 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-second-local-var-in-same-reg/4")
1321 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-second-local-var-in-same-reg/5")
1322 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-function-with-second-local-var-in-same-reg/6")
1323 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-convert-function-with-second-local-var-in-same-reg/7")
1324 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 4/imm32" "F - test-convert-function-with-second-local-var-in-same-reg/8")
1325 (check-next-stream-line-equal _test-output-stream " 41/increment-ecx" "F - test-convert-function-with-second-local-var-in-same-reg/9")
1326 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-function-with-second-local-var-in-same-reg/10")
1327 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-second-local-var-in-same-reg/11")
1328 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-second-local-var-in-same-reg/12")
1329 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-second-local-var-in-same-reg/13")
1330 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-second-local-var-in-same-reg/14")
1331 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-second-local-var-in-same-reg/15")
1332 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-second-local-var-in-same-reg/16")
1333
1334 89/<- %esp 5/r32/ebp
1335 5d/pop-to-ebp
1336 c3/return
1337
1338 test-read-clobbered-reg-var:
1339
1340 55/push-ebp
1341 89/<- %ebp 4/r32/esp
1342
1343 (clear-stream _test-input-stream)
1344 (clear-stream $_test-input-buffered-file->buffer)
1345 (clear-stream _test-output-stream)
1346 (clear-stream $_test-output-buffered-file->buffer)
1347 (clear-stream _test-error-stream)
1348 (clear-stream $_test-error-buffered-file->buffer)
1349
1350 68/push 0/imm32
1351 68/push 0/imm32
1352 89/<- %edx 4/r32/esp
1353 (tailor-exit-descriptor %edx 0x10)
1354
1355 (write _test-input-stream "fn foo {\n")
1356 (write _test-input-stream " var x/ecx: int <- copy 3\n")
1357 (write _test-input-stream " var y/ecx: int <- copy 4\n")
1358 (write _test-input-stream " x <- increment\n")
1359 (write _test-input-stream "}\n")
1360
1361 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1362
1363
1364 89/<- %edx 4/r32/esp
1365 (flush _test-output-buffered-file)
1366 (flush _test-error-buffered-file)
1367 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1373
1374 (check-stream-equal _test-output-stream "" "F - test-read-clobbered-reg-var: output should be empty")
1375 (check-next-stream-line-equal _test-error-stream "fn foo: register ecx reads var 'x' after writing var 'y'" "F - test-read-clobbered-reg-var: error message")
1376
1377 (check-ints-equal *(edx+4) 2 "F - test-read-clobbered-reg-var: exit status")
1378
1379 81 0/subop/add %esp 8/imm32
1380
1381 5d/pop-to-ebp
1382 c3/return
1383
1384 test-overlapping-int-fp-registers:
1385
1386 55/push-ebp
1387 89/<- %ebp 4/r32/esp
1388
1389 (clear-stream _test-input-stream)
1390 (clear-stream $_test-input-buffered-file->buffer)
1391 (clear-stream _test-output-stream)
1392 (clear-stream $_test-output-buffered-file->buffer)
1393 (clear-stream _test-error-stream)
1394 (clear-stream $_test-error-buffered-file->buffer)
1395
1396 68/push 0/imm32
1397 68/push 0/imm32
1398 89/<- %edx 4/r32/esp
1399 (tailor-exit-descriptor %edx 0x10)
1400
1401 (write _test-input-stream "fn foo {\n")
1402 (write _test-input-stream " var x/eax: int <- copy 3\n")
1403 (write _test-input-stream " var y/xmm0: float <- convert x\n")
1404 (write _test-input-stream " x <- increment\n")
1405 (write _test-input-stream "}\n")
1406
1407 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1408
1409
1410 89/<- %edx 4/r32/esp
1411 (flush _test-output-buffered-file)
1412 (flush _test-error-buffered-file)
1413 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1419
1420 (check-next-stream-line-equal _test-error-stream "" "F - test-overlapping-int-fp-registers: error message")
1421
1422
1423 81 0/subop/add %esp 8/imm32
1424
1425 5d/pop-to-ebp
1426 c3/return
1427
1428 test-convert-function-call:
1429
1430 55/push-ebp
1431 89/<- %ebp 4/r32/esp
1432
1433 (clear-stream _test-input-stream)
1434 (clear-stream $_test-input-buffered-file->buffer)
1435 (clear-stream _test-output-stream)
1436 (clear-stream $_test-output-buffered-file->buffer)
1437
1438 (write _test-input-stream "fn main -> result/ebx: int {\n")
1439 (write _test-input-stream " result <- foo\n")
1440 (write _test-input-stream "}\n")
1441 (write _test-input-stream "fn foo -> result/ebx: int {\n")
1442 (write _test-input-stream " result <- copy 3\n")
1443 (write _test-input-stream "}\n")
1444
1445 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
1446 (flush _test-output-buffered-file)
1447 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
1453
1454 (check-next-stream-line-equal _test-output-stream "main:" "F - test-convert-function-call/0")
1455 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call/1")
1456 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call/2")
1457 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call/3")
1458 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-call/4")
1459 (check-next-stream-line-equal _test-output-stream "$main:0x00000001:loop:" "F - test-convert-function-call/5")
1460 (check-next-stream-line-equal _test-output-stream " (foo)" "F - test-convert-function-call/6")
1461 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-call/7")
1462 (check-next-stream-line-equal _test-output-stream "$main:0x00000001:break:" "F - test-convert-function-call/8")
1463 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call/9")
1464 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call/10")
1465 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call/11")
1466 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call/12")
1467 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-call/13")
1468 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call/14")
1469 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call/15")
1470 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call/16")
1471 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-call/17")
1472 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-call/18")
1473 (check-next-stream-line-equal _test-output-stream " bb/copy-to-ebx 3/imm32" "F - test-convert-function-call/19")
1474 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-call/20")
1475 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-call/21")
1476 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call/22")
1477 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call/23")
1478 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call/24")
1479 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call/25")
1480
1481 89/<- %esp 5/r32/ebp
1482 5d/pop-to-ebp
1483 c3/return
1484
1485 test-convert-function-call-with-inout-with-compound-type:
1486
1487 55/push-ebp
1488 89/<- %ebp 4/r32/esp
1489
1490 (clear-stream _test-input-stream)
1491 (clear-stream $_test-input-buffered-file->buffer)
1492 (clear-stream _test-output-stream)
1493 (clear-stream $_test-output-buffered-file->buffer)
1494
1495 (write _test-input-stream "fn f {\n")
1496 (write _test-input-stream " var x: (addr int)\n")
1497 (write _test-input-stream " g x\n")
1498 (write _test-input-stream "}\n")
1499 (write _test-input-stream "fn g a: (addr int) {\n")
1500 (write _test-input-stream "}\n")
1501
1502 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
1503 (flush _test-output-buffered-file)
1504 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
1510
1511 (check-next-stream-line-equal _test-output-stream "f:" "F - test-convert-function-call-with-inout-with-compound-type/0")
1512 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call-with-inout-with-compound-type/1")
1513 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call-with-inout-with-compound-type/2")
1514 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call-with-inout-with-compound-type/3")
1515 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-call-with-inout-with-compound-type/4")
1516 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:loop:" "F - test-convert-function-call-with-inout-with-compound-type/5")
1517 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-call-with-inout-with-compound-type/6")
1518 (check-next-stream-line-equal _test-output-stream " (g *(ebp+0xfffffffc))" "F - test-convert-function-call-with-inout-with-compound-type/7")
1519 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-call-with-inout-with-compound-type/8")
1520 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-call-with-inout-with-compound-type/9")
1521 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:break:" "F - test-convert-function-call-with-inout-with-compound-type/10")
1522 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call-with-inout-with-compound-type/11")
1523 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call-with-inout-with-compound-type/12")
1524 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call-with-inout-with-compound-type/13")
1525 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call-with-inout-with-compound-type/14")
1526 (check-next-stream-line-equal _test-output-stream "g:" "F - test-convert-function-call-with-inout-with-compound-type/15")
1527 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call-with-inout-with-compound-type/16")
1528 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call-with-inout-with-compound-type/17")
1529 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call-with-inout-with-compound-type/18")
1530 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call-with-inout-with-compound-type/19")
1531 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call-with-inout-with-compound-type/20")
1532 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call-with-inout-with-compound-type/21")
1533 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call-with-inout-with-compound-type/22")
1534
1535 89/<- %esp 5/r32/ebp
1536 5d/pop-to-ebp
1537 c3/return
1538
1539 test-convert-function-call-with-inout-with-type-parameter:
1540
1541 55/push-ebp
1542 89/<- %ebp 4/r32/esp
1543
1544 (clear-stream _test-input-stream)
1545 (clear-stream $_test-input-buffered-file->buffer)
1546 (clear-stream _test-output-stream)
1547 (clear-stream $_test-output-buffered-file->buffer)
1548 (clear-stream _test-error-stream)
1549 (clear-stream $_test-error-buffered-file->buffer)
1550
1551 68/push 0/imm32
1552 68/push 0/imm32
1553 89/<- %edx 4/r32/esp
1554 (tailor-exit-descriptor %edx 0x10)
1555
1556 (write _test-input-stream "fn f {\n")
1557 (write _test-input-stream " var x: (addr int)\n")
1558 (write _test-input-stream " g x\n")
1559 (write _test-input-stream "}\n")
1560 (write _test-input-stream "fn g a: (addr _) {\n")
1561 (write _test-input-stream "}\n")
1562
1563 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1564
1565
1566 89/<- %edx 4/r32/esp
1567 (flush _test-output-buffered-file)
1568 (flush _test-error-buffered-file)
1569 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1575
1576 (check-stream-equal _test-error-stream "" "F - test-convert-function-call-with-inout-with-type-parameter: error stream should be empty")
1577
1578
1579 81 0/subop/add %esp 8/imm32
1580
1581 5d/pop-to-ebp
1582 c3/return
1583
1584 test-convert-function-call-with-incorrect-inout-type:
1585
1586 55/push-ebp
1587 89/<- %ebp 4/r32/esp
1588
1589 (clear-stream _test-input-stream)
1590 (clear-stream $_test-input-buffered-file->buffer)
1591 (clear-stream _test-output-stream)
1592 (clear-stream $_test-output-buffered-file->buffer)
1593 (clear-stream _test-error-stream)
1594 (clear-stream $_test-error-buffered-file->buffer)
1595
1596 68/push 0/imm32
1597 68/push 0/imm32
1598 89/<- %edx 4/r32/esp
1599 (tailor-exit-descriptor %edx 0x10)
1600
1601 (write _test-input-stream "fn f {\n")
1602 (write _test-input-stream " var x: int\n")
1603 (write _test-input-stream " g x\n")
1604 (write _test-input-stream "}\n")
1605 (write _test-input-stream "fn g a: foo {\n")
1606 (write _test-input-stream "}\n")
1607
1608 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1609
1610
1611 89/<- %edx 4/r32/esp
1612 (flush _test-output-buffered-file)
1613 (flush _test-error-buffered-file)
1614 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1620
1621 (check-stream-equal _test-output-stream "" "F - test-convert-function-call-with-incorrect-inout-type: output should be empty")
1622 (check-next-stream-line-equal _test-error-stream "fn f: call g: type for inout 'x' is not right" "F - test-convert-function-call-with-incorrect-inout-type: error message")
1623
1624 (check-ints-equal *(edx+4) 2 "F - test-convert-function-call-with-incorrect-inout-type: exit status")
1625
1626 81 0/subop/add %esp 8/imm32
1627 5d/pop-to-ebp
1628 c3/return
1629
1630 test-convert-function-call-with-inout-with-incorrect-compound-type:
1631
1632 55/push-ebp
1633 89/<- %ebp 4/r32/esp
1634
1635 (clear-stream _test-input-stream)
1636 (clear-stream $_test-input-buffered-file->buffer)
1637 (clear-stream _test-output-stream)
1638 (clear-stream $_test-output-buffered-file->buffer)
1639 (clear-stream _test-error-stream)
1640 (clear-stream $_test-error-buffered-file->buffer)
1641
1642 68/push 0/imm32
1643 68/push 0/imm32
1644 89/<- %edx 4/r32/esp
1645 (tailor-exit-descriptor %edx 0x10)
1646
1647 (write _test-input-stream "fn f {\n")
1648 (write _test-input-stream " var x: (addr int)\n")
1649 (write _test-input-stream " g x\n")
1650 (write _test-input-stream "}\n")
1651 (write _test-input-stream "fn g a: (addr bool) {\n")
1652 (write _test-input-stream "}\n")
1653
1654 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1655
1656
1657 89/<- %edx 4/r32/esp
1658 (flush _test-output-buffered-file)
1659 (flush _test-error-buffered-file)
1660 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1666
1667 (check-stream-equal _test-output-stream "" "F - test-convert-function-call-with-inout-with-incorrect-compound-type: output should be empty")
1668 (check-next-stream-line-equal _test-error-stream "fn f: call g: type for inout 'x' is not right" "F - test-convert-function-call-with-inout-with-incorrect-compound-type: error message")
1669
1670 81 0/subop/add %esp 8/imm32
1671
1672 5d/pop-to-ebp
1673 c3/return
1674
1675 test-convert-function-call-with-inout-with-multiple-type-parameters:
1676
1677 55/push-ebp
1678 89/<- %ebp 4/r32/esp
1679
1680 (clear-stream _test-input-stream)
1681 (clear-stream $_test-input-buffered-file->buffer)
1682 (clear-stream _test-output-stream)
1683 (clear-stream $_test-output-buffered-file->buffer)
1684 (clear-stream _test-error-stream)
1685 (clear-stream $_test-error-buffered-file->buffer)
1686
1687 68/push 0/imm32
1688 68/push 0/imm32
1689 89/<- %edx 4/r32/esp
1690 (tailor-exit-descriptor %edx 0x10)
1691
1692 (write _test-input-stream "fn f {\n")
1693 (write _test-input-stream " var x: (addr int)\n")
1694 (write _test-input-stream " var y: (addr int)\n")
1695 (write _test-input-stream " g x, y\n")
1696 (write _test-input-stream "}\n")
1697 (write _test-input-stream "fn g a: (addr _), b: (addr _) {\n")
1698 (write _test-input-stream "}\n")
1699
1700 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1701
1702
1703 89/<- %edx 4/r32/esp
1704 (flush _test-output-buffered-file)
1705 (flush _test-error-buffered-file)
1706 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1712
1713 (check-stream-equal _test-error-stream "" "F - test-convert-function-call-with-inout-with-multiple-type-parameters: error stream should be empty")
1714
1715
1716 81 0/subop/add %esp 8/imm32
1717
1718 5d/pop-to-ebp
1719 c3/return
1720
1721 test-type-parameter-matches-rest-of-type:
1722
1723 55/push-ebp
1724 89/<- %ebp 4/r32/esp
1725
1726 (clear-stream _test-input-stream)
1727 (clear-stream $_test-input-buffered-file->buffer)
1728 (clear-stream _test-output-stream)
1729 (clear-stream $_test-output-buffered-file->buffer)
1730 (clear-stream _test-error-stream)
1731 (clear-stream $_test-error-buffered-file->buffer)
1732
1733 68/push 0/imm32
1734 68/push 0/imm32
1735 89/<- %edx 4/r32/esp
1736 (tailor-exit-descriptor %edx 0x10)
1737
1738 (write _test-input-stream "fn f {\n")
1739 (write _test-input-stream " var x: (addr array int)\n")
1740 (write _test-input-stream " g x\n")
1741 (write _test-input-stream "}\n")
1742 (write _test-input-stream "fn g a: (addr _) {\n")
1743 (write _test-input-stream "}\n")
1744
1745 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1746
1747
1748 89/<- %edx 4/r32/esp
1749 (flush _test-output-buffered-file)
1750 (flush _test-error-buffered-file)
1751 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1757
1758 (check-stream-equal _test-error-stream "" "F - test-type-parameter-matches-rest-of-type: error stream should be empty")
1759
1760
1761 81 0/subop/add %esp 8/imm32
1762
1763 5d/pop-to-ebp
1764 c3/return
1765
1766 test-convert-function-call-with-inout-with-incompatible-type-parameters:
1767
1768 55/push-ebp
1769 89/<- %ebp 4/r32/esp
1770
1771 (clear-stream _test-input-stream)
1772 (clear-stream $_test-input-buffered-file->buffer)
1773 (clear-stream _test-output-stream)
1774 (clear-stream $_test-output-buffered-file->buffer)
1775 (clear-stream _test-error-stream)
1776 (clear-stream $_test-error-buffered-file->buffer)
1777
1778 68/push 0/imm32
1779 68/push 0/imm32
1780 89/<- %edx 4/r32/esp
1781 (tailor-exit-descriptor %edx 0x10)
1782
1783 (write _test-input-stream "fn f {\n")
1784 (write _test-input-stream " var x: (addr int)\n")
1785 (write _test-input-stream " var y: (addr boolean)\n")
1786 (write _test-input-stream " g x, y\n")
1787 (write _test-input-stream "}\n")
1788 (write _test-input-stream "fn g a: (addr _T), b: (addr _T) {\n")
1789 (write _test-input-stream "}\n")
1790
1791 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1792
1793
1794 89/<- %edx 4/r32/esp
1795 (flush _test-output-buffered-file)
1796 (flush _test-error-buffered-file)
1797 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1803
1804 (check-stream-equal _test-output-stream "" "F - test-convert-function-call-with-inout-with-incompatible-type-parameters: output should be empty")
1805 (check-next-stream-line-equal _test-error-stream "fn f: call g: type for inout 'y' is not right" "F - test-convert-function-call-with-inout-with-incompatible-type-parameters: error message")
1806
1807 81 0/subop/add %esp 8/imm32
1808
1809 5d/pop-to-ebp
1810 c3/return
1811
1812 test-convert-function-call-with-too-few-inouts:
1813
1814 55/push-ebp
1815 89/<- %ebp 4/r32/esp
1816
1817 (clear-stream _test-input-stream)
1818 (clear-stream $_test-input-buffered-file->buffer)
1819 (clear-stream _test-output-stream)
1820 (clear-stream $_test-output-buffered-file->buffer)
1821 (clear-stream _test-error-stream)
1822 (clear-stream $_test-error-buffered-file->buffer)
1823
1824 68/push 0/imm32
1825 68/push 0/imm32
1826 89/<- %edx 4/r32/esp
1827 (tailor-exit-descriptor %edx 0x10)
1828
1829 (write _test-input-stream "fn f {\n")
1830 (write _test-input-stream " g\n")
1831 (write _test-input-stream "}\n")
1832 (write _test-input-stream "fn g a: int {\n")
1833 (write _test-input-stream "}\n")
1834
1835 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1836
1837
1838 89/<- %edx 4/r32/esp
1839 (flush _test-output-buffered-file)
1840 (flush _test-error-buffered-file)
1841 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1847
1848 (check-stream-equal _test-output-stream "" "F - test-convert-function-call-with-too-few-inouts: output should be empty")
1849 (check-next-stream-line-equal _test-error-stream "fn f: call g: too few inouts" "F - test-convert-function-call-with-too-few-inouts: error message")
1850
1851 (check-ints-equal *(edx+4) 2 "F - test-convert-function-call-with-too-few-inouts: exit status")
1852
1853 81 0/subop/add %esp 8/imm32
1854 5d/pop-to-ebp
1855 c3/return
1856
1857 test-convert-function-call-with-too-many-inouts:
1858
1859 55/push-ebp
1860 89/<- %ebp 4/r32/esp
1861
1862 (clear-stream _test-input-stream)
1863 (clear-stream $_test-input-buffered-file->buffer)
1864 (clear-stream _test-output-stream)
1865 (clear-stream $_test-output-buffered-file->buffer)
1866 (clear-stream _test-error-stream)
1867 (clear-stream $_test-error-buffered-file->buffer)
1868
1869 68/push 0/imm32
1870 68/push 0/imm32
1871 89/<- %edx 4/r32/esp
1872 (tailor-exit-descriptor %edx 0x10)
1873
1874 (write _test-input-stream "fn f {\n")
1875 (write _test-input-stream " var x: int\n")
1876 (write _test-input-stream " g x\n")
1877 (write _test-input-stream "}\n")
1878 (write _test-input-stream "fn g {\n")
1879 (write _test-input-stream "}\n")
1880
1881 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1882
1883
1884 89/<- %edx 4/r32/esp
1885 (flush _test-output-buffered-file)
1886 (flush _test-error-buffered-file)
1887 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1893
1894 (check-stream-equal _test-output-stream "" "F - test-convert-function-call-with-too-many-inouts: output should be empty")
1895 (check-next-stream-line-equal _test-error-stream "fn f: call g: too many inouts" "F - test-convert-function-call-with-too-many-inouts: error message")
1896
1897 (check-ints-equal *(edx+4) 2 "F - test-convert-function-call-with-too-many-inouts: exit status")
1898
1899 81 0/subop/add %esp 8/imm32
1900 5d/pop-to-ebp
1901 c3/return
1902
1903 test-convert-function-call-with-incorrect-output-type:
1904
1905 55/push-ebp
1906 89/<- %ebp 4/r32/esp
1907
1908 (clear-stream _test-input-stream)
1909 (clear-stream $_test-input-buffered-file->buffer)
1910 (clear-stream _test-output-stream)
1911 (clear-stream $_test-output-buffered-file->buffer)
1912 (clear-stream _test-error-stream)
1913 (clear-stream $_test-error-buffered-file->buffer)
1914
1915 68/push 0/imm32
1916 68/push 0/imm32
1917 89/<- %edx 4/r32/esp
1918 (tailor-exit-descriptor %edx 0x10)
1919
1920 (write _test-input-stream "fn f {\n")
1921 (write _test-input-stream " var x/eax: int <- g\n")
1922 (write _test-input-stream "}\n")
1923 (write _test-input-stream "fn g -> a/eax: foo {\n")
1924 (write _test-input-stream "}\n")
1925
1926 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1927
1928
1929 89/<- %edx 4/r32/esp
1930 (flush _test-output-buffered-file)
1931 (flush _test-error-buffered-file)
1932 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1938
1939 (check-stream-equal _test-output-stream "" "F - test-convert-function-call-with-incorrect-output-type: output should be empty")
1940 (check-next-stream-line-equal _test-error-stream "fn f: call g: type for output 'x' is not right" "F - test-convert-function-call-with-incorrect-output-type: error message")
1941
1942 (check-ints-equal *(edx+4) 2 "F - test-convert-function-call-with-incorrect-output-type: exit status")
1943
1944 81 0/subop/add %esp 8/imm32
1945 5d/pop-to-ebp
1946 c3/return
1947
1948 test-convert-function-call-with-too-few-outputs:
1949
1950 55/push-ebp
1951 89/<- %ebp 4/r32/esp
1952
1953 (clear-stream _test-input-stream)
1954 (clear-stream $_test-input-buffered-file->buffer)
1955 (clear-stream _test-output-stream)
1956 (clear-stream $_test-output-buffered-file->buffer)
1957 (clear-stream _test-error-stream)
1958 (clear-stream $_test-error-buffered-file->buffer)
1959
1960 68/push 0/imm32
1961 68/push 0/imm32
1962 89/<- %edx 4/r32/esp
1963 (tailor-exit-descriptor %edx 0x10)
1964
1965 (write _test-input-stream "fn f {\n")
1966 (write _test-input-stream " g\n")
1967 (write _test-input-stream "}\n")
1968 (write _test-input-stream "fn g -> a/eax: int {\n")
1969 (write _test-input-stream "}\n")
1970
1971 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
1972
1973
1974 89/<- %edx 4/r32/esp
1975 (flush _test-output-buffered-file)
1976 (flush _test-error-buffered-file)
1977 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
1983
1984 (check-stream-equal _test-output-stream "" "F - test-convert-function-call-with-too-few-outputs: output should be empty")
1985 (check-next-stream-line-equal _test-error-stream "fn f: call g: too few outputs" "F - test-convert-function-call-with-too-few-outputs: error message")
1986
1987 (check-ints-equal *(edx+4) 2 "F - test-convert-function-call-with-too-few-outputs: exit status")
1988
1989 81 0/subop/add %esp 8/imm32
1990 5d/pop-to-ebp
1991 c3/return
1992
1993 test-convert-function-call-with-too-many-outputs:
1994
1995 55/push-ebp
1996 89/<- %ebp 4/r32/esp
1997
1998 (clear-stream _test-input-stream)
1999 (clear-stream $_test-input-buffered-file->buffer)
2000 (clear-stream _test-output-stream)
2001 (clear-stream $_test-output-buffered-file->buffer)
2002 (clear-stream _test-error-stream)
2003 (clear-stream $_test-error-buffered-file->buffer)
2004
2005 68/push 0/imm32
2006 68/push 0/imm32
2007 89/<- %edx 4/r32/esp
2008 (tailor-exit-descriptor %edx 0x10)
2009
2010 (write _test-input-stream "fn f {\n")
2011 (write _test-input-stream " var x/eax: int <- g\n")
2012 (write _test-input-stream "}\n")
2013 (write _test-input-stream "fn g {\n")
2014 (write _test-input-stream "}\n")
2015
2016 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
2017
2018
2019 89/<- %edx 4/r32/esp
2020 (flush _test-output-buffered-file)
2021 (flush _test-error-buffered-file)
2022 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
2028
2029 (check-stream-equal _test-output-stream "" "F - test-convert-function-call-with-too-many-outputs: output should be empty")
2030 (check-next-stream-line-equal _test-error-stream "fn f: call g: too many outputs" "F - test-convert-function-call-with-too-many-outputs: error message")
2031
2032 (check-ints-equal *(edx+4) 2 "F - test-convert-function-call-with-too-many-outputs: exit status")
2033
2034 81 0/subop/add %esp 8/imm32
2035 5d/pop-to-ebp
2036 c3/return
2037
2038 test-convert-function-call-with-missing-output-register:
2039
2040 55/push-ebp
2041 89/<- %ebp 4/r32/esp
2042
2043 (clear-stream _test-input-stream)
2044 (clear-stream $_test-input-buffered-file->buffer)
2045 (clear-stream _test-output-stream)
2046 (clear-stream $_test-output-buffered-file->buffer)
2047 (clear-stream _test-error-stream)
2048 (clear-stream $_test-error-buffered-file->buffer)
2049
2050 68/push 0/imm32
2051 68/push 0/imm32
2052 89/<- %edx 4/r32/esp
2053 (tailor-exit-descriptor %edx 0x10)
2054
2055 (write _test-input-stream "fn f {\n")
2056 (write _test-input-stream " var x: int\n")
2057 (write _test-input-stream " x <- g\n")
2058 (write _test-input-stream "}\n")
2059 (write _test-input-stream "fn g -> a/eax: int {\n")
2060 (write _test-input-stream "}\n")
2061
2062 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
2063
2064
2065 89/<- %edx 4/r32/esp
2066 (flush _test-output-buffered-file)
2067 (flush _test-error-buffered-file)
2068 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
2074
2075 (check-stream-equal _test-output-stream "" "F - test-convert-function-call-with-missing-output-register: output should be empty")
2076 (check-next-stream-line-equal _test-error-stream "fn f: call g: output 'x' is not in a register" "F - test-convert-function-call-with-missing-output-register: error message")
2077
2078 (check-ints-equal *(edx+4) 2 "F - test-convert-function-call-with-missing-output-register: exit status")
2079
2080 81 0/subop/add %esp 8/imm32
2081 5d/pop-to-ebp
2082 c3/return
2083
2084 test-convert-function-call-with-incorrect-output-register:
2085
2086 55/push-ebp
2087 89/<- %ebp 4/r32/esp
2088
2089 (clear-stream _test-input-stream)
2090 (clear-stream $_test-input-buffered-file->buffer)
2091 (clear-stream _test-output-stream)
2092 (clear-stream $_test-output-buffered-file->buffer)
2093 (clear-stream _test-error-stream)
2094 (clear-stream $_test-error-buffered-file->buffer)
2095
2096 68/push 0/imm32
2097 68/push 0/imm32
2098 89/<- %edx 4/r32/esp
2099 (tailor-exit-descriptor %edx 0x10)
2100
2101 (write _test-input-stream "fn f {\n")
2102 (write _test-input-stream " var x/ecx: int <- g\n")
2103 (write _test-input-stream "}\n")
2104 (write _test-input-stream "fn g -> a/eax: int {\n")
2105 (write _test-input-stream "}\n")
2106
2107 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
2108
2109
2110 89/<- %edx 4/r32/esp
2111 (flush _test-output-buffered-file)
2112 (flush _test-error-buffered-file)
2113 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
2119
2120 (check-stream-equal _test-output-stream "" "F - test-convert-function-call-with-incorrect-output-register: output should be empty")
2121 (check-next-stream-line-equal _test-error-stream "fn f: call g: register for output 'x' is not right" "F - test-convert-function-call-with-incorrect-output-register: error message")
2122
2123 (check-ints-equal *(edx+4) 2 "F - test-convert-function-call-with-incorrect-output-register: exit status")
2124
2125 81 0/subop/add %esp 8/imm32
2126 5d/pop-to-ebp
2127 c3/return
2128
2129 test-convert-function-with-local-var-dereferenced:
2130
2131 55/push-ebp
2132 89/<- %ebp 4/r32/esp
2133
2134 (clear-stream _test-input-stream)
2135 (clear-stream $_test-input-buffered-file->buffer)
2136 (clear-stream _test-output-stream)
2137 (clear-stream $_test-output-buffered-file->buffer)
2138
2139 (write _test-input-stream "fn foo {\n")
2140 (write _test-input-stream " var x/ecx: (addr int) <- copy 0\n")
2141 (write _test-input-stream " increment *x\n")
2142 (write _test-input-stream "}\n")
2143
2144 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2145 (flush _test-output-buffered-file)
2146 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2152
2153 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-local-var-dereferenced/0")
2154 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-local-var-dereferenced/1")
2155 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-local-var-dereferenced/2")
2156 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-local-var-dereferenced/3")
2157 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-dereferenced/4")
2158 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-local-var-dereferenced/5")
2159 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-function-with-local-var-dereferenced/6")
2160 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 0/imm32" "F - test-convert-function-with-local-var-dereferenced/7")
2161 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *ecx" "F - test-convert-function-with-local-var-dereferenced/8")
2162 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-function-with-local-var-dereferenced/9")
2163 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-dereferenced/10")
2164 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-local-var-dereferenced/11")
2165 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-local-var-dereferenced/12")
2166 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-local-var-dereferenced/13")
2167 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-local-var-dereferenced/14")
2168 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-local-var-dereferenced/15")
2169
2170 89/<- %esp 5/r32/ebp
2171 5d/pop-to-ebp
2172 c3/return
2173
2174
2175 test-convert-function-with-byte-operations:
2176
2177 55/push-ebp
2178 89/<- %ebp 4/r32/esp
2179
2180 (clear-stream _test-input-stream)
2181 (clear-stream $_test-input-buffered-file->buffer)
2182 (clear-stream _test-output-stream)
2183 (clear-stream $_test-output-buffered-file->buffer)
2184
2185 (write _test-input-stream "fn foo {\n")
2186 (write _test-input-stream " var x/eax: byte <- copy 0\n")
2187 (write _test-input-stream " var y/ecx: byte <- copy 0\n")
2188 (write _test-input-stream " y <- copy-byte x\n")
2189 (write _test-input-stream " var z/edx: (addr byte) <- copy 0\n")
2190 (write _test-input-stream " y <- copy-byte *z\n")
2191 (write _test-input-stream " copy-byte-to *z, x\n")
2192 (write _test-input-stream "}\n")
2193
2194 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2195 (flush _test-output-buffered-file)
2196 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2202
2203 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-byte-operations/0")
2204 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-byte-operations/1")
2205 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-byte-operations/2")
2206 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-byte-operations/3")
2207 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-byte-operations/4")
2208 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-byte-operations/5")
2209 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-function-with-byte-operations/6")
2210 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-function-with-byte-operations/7")
2211 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-function-with-byte-operations/8")
2212 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 0/imm32" "F - test-convert-function-with-byte-operations/9")
2213 (check-next-stream-line-equal _test-output-stream " 8a/byte-> %eax 0x00000001/r32" "F - test-convert-function-with-byte-operations/10")
2214 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %edx" "F - test-convert-function-with-byte-operations/11")
2215 (check-next-stream-line-equal _test-output-stream " ba/copy-to-edx 0/imm32" "F - test-convert-function-with-byte-operations/12")
2216 (check-next-stream-line-equal _test-output-stream " 8a/byte-> *edx 0x00000001/r32" "F - test-convert-function-with-byte-operations/13")
2217 (check-next-stream-line-equal _test-output-stream " 88/byte<- *edx 0x00000000/r32" "F - test-convert-function-with-byte-operations/14")
2218 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %edx" "F - test-convert-function-with-byte-operations/15")
2219 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-function-with-byte-operations/16")
2220 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-function-with-byte-operations/17")
2221 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-byte-operations/18")
2222 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-byte-operations/19")
2223 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-byte-operations/20")
2224 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-byte-operations/21")
2225 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-byte-operations/22")
2226 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-byte-operations/23")
2227
2228 89/<- %esp 5/r32/ebp
2229 5d/pop-to-ebp
2230 c3/return
2231
2232
2233 test-copy-byte-var-from-fn-arg:
2234
2235 55/push-ebp
2236 89/<- %ebp 4/r32/esp
2237
2238 (clear-stream _test-input-stream)
2239 (clear-stream $_test-input-buffered-file->buffer)
2240 (clear-stream _test-output-stream)
2241 (clear-stream $_test-output-buffered-file->buffer)
2242
2243 (write _test-input-stream "fn foo x: byte, y: int {\n")
2244 (write _test-input-stream " var a/eax: byte <- copy x\n")
2245 (write _test-input-stream " var b/eax: int <- copy y\n")
2246 (write _test-input-stream "}\n")
2247
2248 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2249 (flush _test-output-buffered-file)
2250 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2256
2257 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-copy-byte-from-fn-arg/0")
2258 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-copy-byte-from-fn-arg/1")
2259 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-copy-byte-from-fn-arg/2")
2260 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-copy-byte-from-fn-arg/3")
2261 (check-next-stream-line-equal _test-output-stream " {" "F - test-copy-byte-from-fn-arg/4")
2262 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-copy-byte-from-fn-arg/5")
2263 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-copy-byte-from-fn-arg/6")
2264 (check-next-stream-line-equal _test-output-stream " 8b/-> *(ebp+0x00000008) 0x00000000/r32" "F - test-copy-byte-from-fn-arg/7")
2265 (check-next-stream-line-equal _test-output-stream " 8b/-> *(ebp+0x0000000c) 0x00000000/r32" "F - test-copy-byte-from-fn-arg/8")
2266 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-copy-byte-from-fn-arg/9")
2267 (check-next-stream-line-equal _test-output-stream " }" "F - test-copy-byte-from-fn-arg/10")
2268 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-copy-byte-from-fn-arg/11")
2269 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-copy-byte-from-fn-arg/12")
2270 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-copy-byte-from-fn-arg/13")
2271 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-copy-byte-from-fn-arg/14")
2272 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-copy-byte-from-fn-arg/15")
2273
2274 89/<- %esp 5/r32/ebp
2275 5d/pop-to-ebp
2276 c3/return
2277
2278 test-convert-compare-register-with-literal:
2279
2280 55/push-ebp
2281 89/<- %ebp 4/r32/esp
2282
2283 (clear-stream _test-input-stream)
2284 (clear-stream $_test-input-buffered-file->buffer)
2285 (clear-stream _test-output-stream)
2286 (clear-stream $_test-output-buffered-file->buffer)
2287
2288 (write _test-input-stream "fn foo {\n")
2289 (write _test-input-stream " var x/ecx: int <- copy 0\n")
2290 (write _test-input-stream " compare x, 0\n")
2291 (write _test-input-stream "}\n")
2292
2293 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2294 (flush _test-output-buffered-file)
2295 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2301
2302 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-compare-register-with-literal/0")
2303 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-compare-register-with-literal/1")
2304 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-compare-register-with-literal/2")
2305 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-compare-register-with-literal/3")
2306 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-compare-register-with-literal/4")
2307 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-compare-register-with-literal/5")
2308 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-compare-register-with-literal/6")
2309 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 0/imm32" "F - test-convert-compare-register-with-literal/7")
2310 (check-next-stream-line-equal _test-output-stream " 81 7/subop/compare %ecx 0/imm32" "F - test-convert-compare-register-with-literal/8")
2311 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-compare-register-with-literal/9")
2312 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-compare-register-with-literal/10")
2313 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-compare-register-with-literal/11")
2314 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-compare-register-with-literal/12")
2315 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-compare-register-with-literal/13")
2316 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-compare-register-with-literal/14")
2317 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-compare-register-with-literal/15")
2318
2319 89/<- %esp 5/r32/ebp
2320 5d/pop-to-ebp
2321 c3/return
2322
2323 test-unknown-variable:
2324
2325 55/push-ebp
2326 89/<- %ebp 4/r32/esp
2327
2328 (clear-stream _test-input-stream)
2329 (clear-stream $_test-input-buffered-file->buffer)
2330 (clear-stream _test-output-stream)
2331 (clear-stream $_test-output-buffered-file->buffer)
2332 (clear-stream _test-error-stream)
2333 (clear-stream $_test-error-buffered-file->buffer)
2334
2335 68/push 0/imm32
2336 68/push 0/imm32
2337 89/<- %edx 4/r32/esp
2338 (tailor-exit-descriptor %edx 0x10)
2339
2340 (write _test-input-stream "fn foo {\n")
2341 (write _test-input-stream " compare x, 0\n")
2342 (write _test-input-stream "}\n")
2343
2344 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
2345
2346
2347 89/<- %edx 4/r32/esp
2348 (flush _test-output-buffered-file)
2349 (flush _test-error-buffered-file)
2350 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
2356
2357 (check-stream-equal _test-output-stream "" "F - test-unknown-variable: output should be empty")
2358 (check-next-stream-line-equal _test-error-stream "fn foo: unknown variable 'x'" "F - test-unknown-variable: error message")
2359
2360 (check-ints-equal *(edx+4) 2 "F - test-unknown-variable: exit status")
2361
2362 81 0/subop/add %esp 8/imm32
2363
2364 5d/pop-to-ebp
2365 c3/return
2366
2367 test-convert-function-with-local-var-in-block:
2368
2369 55/push-ebp
2370 89/<- %ebp 4/r32/esp
2371
2372 (clear-stream _test-input-stream)
2373 (clear-stream $_test-input-buffered-file->buffer)
2374 (clear-stream _test-output-stream)
2375 (clear-stream $_test-output-buffered-file->buffer)
2376
2377 (write _test-input-stream "fn foo {\n")
2378 (write _test-input-stream " {\n")
2379 (write _test-input-stream " var x: int\n")
2380 (write _test-input-stream " increment x\n")
2381 (write _test-input-stream " }\n")
2382 (write _test-input-stream "}\n")
2383
2384 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2385 (flush _test-output-buffered-file)
2386 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2392
2393 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-local-var-in-block/0")
2394 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-local-var-in-block/1")
2395 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-local-var-in-block/2")
2396 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-local-var-in-block/3")
2397 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-in-block/4")
2398 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-local-var-in-block/5")
2399 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-in-block/6")
2400 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-with-local-var-in-block/7")
2401 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-local-var-in-block/8")
2402 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0xfffffffc)" "F - test-convert-function-with-local-var-in-block/9")
2403 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-local-var-in-block/10")
2404 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-in-block/11")
2405 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-with-local-var-in-block/12")
2406 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-in-block/13")
2407 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-local-var-in-block/14")
2408 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-local-var-in-block/15")
2409 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-local-var-in-block/16")
2410 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-local-var-in-block/17")
2411 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-local-var-in-block/18")
2412
2413 89/<- %esp 5/r32/ebp
2414 5d/pop-to-ebp
2415 c3/return
2416
2417 test-convert-function-with-local-var-in-mem-after-block:
2418
2419 55/push-ebp
2420 89/<- %ebp 4/r32/esp
2421
2422 (clear-stream _test-input-stream)
2423 (clear-stream $_test-input-buffered-file->buffer)
2424 (clear-stream _test-output-stream)
2425 (clear-stream $_test-output-buffered-file->buffer)
2426
2427 (write _test-input-stream "fn foo {\n")
2428 (write _test-input-stream " {\n")
2429 (write _test-input-stream " var y: int\n")
2430 (write _test-input-stream " }\n")
2431 (write _test-input-stream " var x: int\n")
2432 (write _test-input-stream " increment x\n")
2433 (write _test-input-stream "}\n")
2434
2435 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2436 (flush _test-output-buffered-file)
2437 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2443
2444 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-local-var-in-mem-after-block/0")
2445 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-local-var-in-mem-after-block/1")
2446 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-local-var-in-mem-after-block/2")
2447 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-local-var-in-mem-after-block/3")
2448 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-in-mem-after-block/4")
2449 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-local-var-in-mem-after-block/5")
2450 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-in-mem-after-block/6")
2451 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-with-local-var-in-mem-after-block/7")
2452 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-local-var-in-mem-after-block/8")
2453 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-local-var-in-mem-after-block/9")
2454 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-in-mem-after-block/10")
2455 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-with-local-var-in-mem-after-block/11")
2456 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-local-var-in-mem-after-block/12")
2457 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0xfffffffc)" "F - test-convert-function-with-local-var-in-mem-after-block/13")
2458 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-local-var-in-mem-after-block/14")
2459 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-in-mem-after-block/15")
2460 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-local-var-in-mem-after-block/16")
2461 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-local-var-in-mem-after-block/17")
2462 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-local-var-in-mem-after-block/18")
2463 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-local-var-in-mem-after-block/19")
2464 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-local-var-in-mem-after-block/20")
2465
2466 89/<- %esp 5/r32/ebp
2467 5d/pop-to-ebp
2468 c3/return
2469
2470 test-convert-function-with-local-var-in-named-block:
2471
2472 55/push-ebp
2473 89/<- %ebp 4/r32/esp
2474
2475 (clear-stream _test-input-stream)
2476 (clear-stream $_test-input-buffered-file->buffer)
2477 (clear-stream _test-output-stream)
2478 (clear-stream $_test-output-buffered-file->buffer)
2479
2480 (write _test-input-stream "fn foo {\n")
2481 (write _test-input-stream " $bar: {\n")
2482 (write _test-input-stream " var x: int\n")
2483 (write _test-input-stream " increment x\n")
2484 (write _test-input-stream " }\n")
2485 (write _test-input-stream "}\n")
2486
2487 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2488 (flush _test-output-buffered-file)
2489 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2495
2496 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-local-var-in-named-block/0")
2497 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-local-var-in-named-block/1")
2498 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-local-var-in-named-block/2")
2499 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-local-var-in-named-block/3")
2500 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-in-named-block/4")
2501 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-local-var-in-named-block/5")
2502 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-in-named-block/6")
2503 (check-next-stream-line-equal _test-output-stream "$bar:loop:" "F - test-convert-function-with-local-var-in-named-block/7")
2504 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-local-var-in-named-block/8")
2505 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0xfffffffc)" "F - test-convert-function-with-local-var-in-named-block/9")
2506 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-local-var-in-named-block/10")
2507 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-in-named-block/11")
2508 (check-next-stream-line-equal _test-output-stream "$bar:break:" "F - test-convert-function-with-local-var-in-named-block/12")
2509 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-in-named-block/13")
2510 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-local-var-in-named-block/14")
2511 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-local-var-in-named-block/15")
2512 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-local-var-in-named-block/16")
2513 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-local-var-in-named-block/17")
2514 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-local-var-in-named-block/18")
2515
2516 89/<- %esp 5/r32/ebp
2517 5d/pop-to-ebp
2518 c3/return
2519
2520 test-unknown-variable-in-named-block:
2521
2522 55/push-ebp
2523 89/<- %ebp 4/r32/esp
2524
2525 (clear-stream _test-input-stream)
2526 (clear-stream $_test-input-buffered-file->buffer)
2527 (clear-stream _test-output-stream)
2528 (clear-stream $_test-output-buffered-file->buffer)
2529 (clear-stream _test-error-stream)
2530 (clear-stream $_test-error-buffered-file->buffer)
2531
2532 68/push 0/imm32
2533 68/push 0/imm32
2534 89/<- %edx 4/r32/esp
2535 (tailor-exit-descriptor %edx 0x10)
2536
2537 (write _test-input-stream "fn foo {\n")
2538 (write _test-input-stream " $a: {\n")
2539 (write _test-input-stream " compare x, 0\n")
2540 (write _test-input-stream " }\n")
2541 (write _test-input-stream "}\n")
2542
2543 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
2544
2545
2546 89/<- %edx 4/r32/esp
2547 (flush _test-output-buffered-file)
2548 (flush _test-error-buffered-file)
2549 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
2555
2556 (check-stream-equal _test-output-stream "" "F - test-unknown-variable-in-named-block: output should be empty")
2557 (check-next-stream-line-equal _test-error-stream "fn foo: unknown variable 'x'" "F - test-unknown-variable-in-named-block: error message")
2558
2559 (check-ints-equal *(edx+4) 2 "F - test-unknown-variable-in-named-block: exit status")
2560
2561 81 0/subop/add %esp 8/imm32
2562
2563 5d/pop-to-ebp
2564 c3/return
2565
2566 test-always-shadow-outermost-reg-vars-in-function:
2567
2568 55/push-ebp
2569 89/<- %ebp 4/r32/esp
2570
2571 (clear-stream _test-input-stream)
2572 (clear-stream $_test-input-buffered-file->buffer)
2573 (clear-stream _test-output-stream)
2574 (clear-stream $_test-output-buffered-file->buffer)
2575
2576 (write _test-input-stream "fn foo {\n")
2577 (write _test-input-stream " var x/ecx: int <- copy 3\n")
2578 (write _test-input-stream "}\n")
2579
2580 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2581 (flush _test-output-buffered-file)
2582 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2588
2589 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-always-shadow-outermost-reg-vars-in-function/0")
2590 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-always-shadow-outermost-reg-vars-in-function/1")
2591 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-always-shadow-outermost-reg-vars-in-function/2")
2592 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-always-shadow-outermost-reg-vars-in-function/3")
2593 (check-next-stream-line-equal _test-output-stream " {" "F - test-always-shadow-outermost-reg-vars-in-function/4")
2594 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-always-shadow-outermost-reg-vars-in-function/5")
2595 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-compare-register-with-literal/6")
2596 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-always-shadow-outermost-reg-vars-in-function/8")
2597 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-compare-register-with-literal/9")
2598 (check-next-stream-line-equal _test-output-stream " }" "F - test-always-shadow-outermost-reg-vars-in-function/12")
2599 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-always-shadow-outermost-reg-vars-in-function/13")
2600 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-always-shadow-outermost-reg-vars-in-function/14")
2601 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-always-shadow-outermost-reg-vars-in-function/15")
2602 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-always-shadow-outermost-reg-vars-in-function/16")
2603 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-always-shadow-outermost-reg-vars-in-function/17")
2604
2605 89/<- %esp 5/r32/ebp
2606 5d/pop-to-ebp
2607 c3/return
2608
2609 _pending-test-clobber-dead-local:
2610
2611 55/push-ebp
2612 89/<- %ebp 4/r32/esp
2613
2614 (clear-stream _test-input-stream)
2615 (clear-stream $_test-input-buffered-file->buffer)
2616 (clear-stream _test-output-stream)
2617 (clear-stream $_test-output-buffered-file->buffer)
2618
2619 (write _test-input-stream "fn foo {\n")
2620 (write _test-input-stream " var x/ecx: int <- copy 3\n")
2621 (write _test-input-stream " {\n")
2622 (write _test-input-stream " var y/ecx: int <- copy 4\n")
2623 (write _test-input-stream " }\n")
2624 (write _test-input-stream "}\n")
2625
2626 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2627 (flush _test-output-buffered-file)
2628 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2634
2635 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-clobber-dead-local/0")
2636 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-clobber-dead-local/1")
2637 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-clobber-dead-local/2")
2638 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-clobber-dead-local/3")
2639 (check-next-stream-line-equal _test-output-stream " {" "F - test-clobber-dead-local/4")
2640 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-clobber-dead-local/5")
2641 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-clobber-dead-local/6")
2642 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-clobber-dead-local/7")
2643 (check-next-stream-line-equal _test-output-stream " {" "F - test-clobber-dead-local/8")
2644 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-clobber-dead-local/9")
2645 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 4/imm32" "F - test-clobber-dead-local/10")
2646 (check-next-stream-line-equal _test-output-stream " }" "F - test-clobber-dead-local/11")
2647 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-clobber-dead-local/12")
2648 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-clobber-dead-local/13")
2649 (check-next-stream-line-equal _test-output-stream " }" "F - test-clobber-dead-local/14")
2650 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-clobber-dead-local/15")
2651 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-clobber-dead-local/16")
2652 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-clobber-dead-local/17")
2653 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-clobber-dead-local/18")
2654 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-clobber-dead-local/19")
2655
2656 89/<- %esp 5/r32/ebp
2657 5d/pop-to-ebp
2658 c3/return
2659
2660 test-shadow-live-local:
2661
2662 55/push-ebp
2663 89/<- %ebp 4/r32/esp
2664
2665 (clear-stream _test-input-stream)
2666 (clear-stream $_test-input-buffered-file->buffer)
2667 (clear-stream _test-output-stream)
2668 (clear-stream $_test-output-buffered-file->buffer)
2669
2670 (write _test-input-stream "fn foo {\n")
2671 (write _test-input-stream " var x/ecx: int <- copy 3\n")
2672 (write _test-input-stream " {\n")
2673 (write _test-input-stream " var y/ecx: int <- copy 4\n")
2674 (write _test-input-stream " }\n")
2675 (write _test-input-stream " x <- increment\n")
2676 (write _test-input-stream "}\n")
2677
2678 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2679 (flush _test-output-buffered-file)
2680 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2686
2687 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-shadow-live-local/0")
2688 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-shadow-live-local/1")
2689 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-shadow-live-local/2")
2690 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-shadow-live-local/3")
2691 (check-next-stream-line-equal _test-output-stream " {" "F - test-shadow-live-local/4")
2692 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-shadow-live-local/5")
2693 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-shadow-live-local/6")
2694 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-shadow-live-local/7")
2695 (check-next-stream-line-equal _test-output-stream " {" "F - test-shadow-live-local/8")
2696 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-shadow-live-local/9")
2697 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-shadow-live-local/10")
2698 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 4/imm32" "F - test-shadow-live-local/11")
2699 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-shadow-live-local/12")
2700 (check-next-stream-line-equal _test-output-stream " }" "F - test-shadow-live-local/13")
2701 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-shadow-live-local/14")
2702 (check-next-stream-line-equal _test-output-stream " 41/increment-ecx" "F - test-shadow-live-local/15")
2703 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-shadow-live-local/16")
2704 (check-next-stream-line-equal _test-output-stream " }" "F - test-shadow-live-local/17")
2705 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-shadow-live-local/18")
2706 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-shadow-live-local/19")
2707 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-shadow-live-local/20")
2708 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-shadow-live-local/21")
2709 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-shadow-live-local/22")
2710
2711 89/<- %esp 5/r32/ebp
2712 5d/pop-to-ebp
2713 c3/return
2714
2715 test-shadow-name:
2716
2717 55/push-ebp
2718 89/<- %ebp 4/r32/esp
2719
2720 (clear-stream _test-input-stream)
2721 (clear-stream $_test-input-buffered-file->buffer)
2722 (clear-stream _test-output-stream)
2723 (clear-stream $_test-output-buffered-file->buffer)
2724
2725 (write _test-input-stream "fn foo {\n")
2726 (write _test-input-stream " var x/ecx: int <- copy 3\n")
2727 (write _test-input-stream " {\n")
2728 (write _test-input-stream " var x/edx: int <- copy 4\n")
2729 (write _test-input-stream " }\n")
2730 (write _test-input-stream " x <- increment\n")
2731 (write _test-input-stream "}\n")
2732
2733 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2734 (flush _test-output-buffered-file)
2735 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2741
2742 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-shadow-name/0")
2743 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-shadow-name/1")
2744 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-shadow-name/2")
2745 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-shadow-name/3")
2746 (check-next-stream-line-equal _test-output-stream " {" "F - test-shadow-name/4")
2747 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-shadow-name/5")
2748 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-shadow-name/6")
2749 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-shadow-name/7")
2750 (check-next-stream-line-equal _test-output-stream " {" "F - test-shadow-name/8")
2751 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-shadow-name/9")
2752 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %edx" "F - test-shadow-name/10")
2753 (check-next-stream-line-equal _test-output-stream " ba/copy-to-edx 4/imm32" "F - test-shadow-name/11")
2754 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %edx" "F - test-shadow-name/12")
2755 (check-next-stream-line-equal _test-output-stream " }" "F - test-shadow-name/13")
2756 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-shadow-name/14")
2757 (check-next-stream-line-equal _test-output-stream " 41/increment-ecx" "F - test-shadow-name/15")
2758 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-shadow-name/16")
2759 (check-next-stream-line-equal _test-output-stream " }" "F - test-shadow-name/17")
2760 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-shadow-name/18")
2761 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-shadow-name/19")
2762 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-shadow-name/20")
2763 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-shadow-name/21")
2764 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-shadow-name/22")
2765
2766 89/<- %esp 5/r32/ebp
2767 5d/pop-to-ebp
2768 c3/return
2769
2770 test-shadow-name-2:
2771
2772 55/push-ebp
2773 89/<- %ebp 4/r32/esp
2774
2775 (clear-stream _test-input-stream)
2776 (clear-stream $_test-input-buffered-file->buffer)
2777 (clear-stream _test-output-stream)
2778 (clear-stream $_test-output-buffered-file->buffer)
2779
2780 (write _test-input-stream "fn foo {\n")
2781 (write _test-input-stream " var x/ecx: int <- copy 3\n")
2782 (write _test-input-stream " {\n")
2783 (write _test-input-stream " var x/edx: int <- copy 4\n")
2784 (write _test-input-stream " var y/ecx: int <- copy 5\n")
2785 (write _test-input-stream " }\n")
2786 (write _test-input-stream " x <- increment\n")
2787 (write _test-input-stream "}\n")
2788
2789 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2790 (flush _test-output-buffered-file)
2791 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2797
2798 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-shadow-name-2/0")
2799 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-shadow-name-2/1")
2800 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-shadow-name-2/2")
2801 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-shadow-name-2/3")
2802 (check-next-stream-line-equal _test-output-stream " {" "F - test-shadow-name-2/4")
2803 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-shadow-name-2/5")
2804 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-shadow-name-2/6")
2805 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-shadow-name-2/7")
2806 (check-next-stream-line-equal _test-output-stream " {" "F - test-shadow-name-2/8")
2807 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-shadow-name-2/9")
2808 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %edx" "F - test-shadow-name-2/10")
2809 (check-next-stream-line-equal _test-output-stream " ba/copy-to-edx 4/imm32" "F - test-shadow-name-2/11")
2810 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-shadow-name-2/12")
2811 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 5/imm32" "F - test-shadow-name-2/13")
2812 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-shadow-name-2/14")
2813 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %edx" "F - test-shadow-name-2/15")
2814 (check-next-stream-line-equal _test-output-stream " }" "F - test-shadow-name-2/16")
2815 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-shadow-name-2/17")
2816 (check-next-stream-line-equal _test-output-stream " 41/increment-ecx" "F - test-shadow-name-2/18")
2817 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-shadow-name-2/19")
2818 (check-next-stream-line-equal _test-output-stream " }" "F - test-shadow-name-2/20")
2819 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-shadow-name-2/21")
2820 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-shadow-name-2/22")
2821 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-shadow-name-2/23")
2822 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-shadow-name-2/24")
2823 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-shadow-name-2/25")
2824
2825 89/<- %esp 5/r32/ebp
2826 5d/pop-to-ebp
2827 c3/return
2828
2829 test-do-not-spill-same-register-in-block:
2830
2831 55/push-ebp
2832 89/<- %ebp 4/r32/esp
2833
2834 (clear-stream _test-input-stream)
2835 (clear-stream $_test-input-buffered-file->buffer)
2836 (clear-stream _test-output-stream)
2837 (clear-stream $_test-output-buffered-file->buffer)
2838
2839 (write _test-input-stream "fn foo {\n")
2840 (write _test-input-stream " var x/ecx: int <- copy 3\n")
2841 (write _test-input-stream " var y/ecx: int <- copy 4\n")
2842 (write _test-input-stream " y <- increment\n")
2843 (write _test-input-stream "}\n")
2844
2845 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2846 (flush _test-output-buffered-file)
2847 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2853
2854 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-do-not-spill-same-register-in-block/0")
2855 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-do-not-spill-same-register-in-block/1")
2856 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-do-not-spill-same-register-in-block/2")
2857 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-do-not-spill-same-register-in-block/3")
2858 (check-next-stream-line-equal _test-output-stream " {" "F - test-do-not-spill-same-register-in-block/4")
2859 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-do-not-spill-same-register-in-block/5")
2860 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-do-not-spill-same-register-in-block/6")
2861 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-do-not-spill-same-register-in-block/7")
2862 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 4/imm32" "F - test-do-not-spill-same-register-in-block/8")
2863 (check-next-stream-line-equal _test-output-stream " 41/increment-ecx" "F - test-do-not-spill-same-register-in-block/9")
2864 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-do-not-spill-same-register-in-block/10")
2865 (check-next-stream-line-equal _test-output-stream " }" "F - test-do-not-spill-same-register-in-block/11")
2866 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-do-not-spill-same-register-in-block/12")
2867 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-do-not-spill-same-register-in-block/13")
2868 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-do-not-spill-same-register-in-block/14")
2869 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-do-not-spill-same-register-in-block/15")
2870 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-do-not-spill-same-register-in-block/16")
2871
2872 89/<- %esp 5/r32/ebp
2873 5d/pop-to-ebp
2874 c3/return
2875
2876 test-spill-different-register-in-block:
2877
2878 55/push-ebp
2879 89/<- %ebp 4/r32/esp
2880
2881 (clear-stream _test-input-stream)
2882 (clear-stream $_test-input-buffered-file->buffer)
2883 (clear-stream _test-output-stream)
2884 (clear-stream $_test-output-buffered-file->buffer)
2885
2886 (write _test-input-stream "fn foo {\n")
2887 (write _test-input-stream " var x/eax: int <- copy 3\n")
2888 (write _test-input-stream " var y/ecx: int <- copy 4\n")
2889 (write _test-input-stream " y <- increment\n")
2890 (write _test-input-stream "}\n")
2891
2892 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2893 (flush _test-output-buffered-file)
2894 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2900
2901 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-spill-different-register-in-block/0")
2902 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-spill-different-register-in-block/1")
2903 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-spill-different-register-in-block/2")
2904 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-spill-different-register-in-block/3")
2905 (check-next-stream-line-equal _test-output-stream " {" "F - test-spill-different-register-in-block/4")
2906 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-spill-different-register-in-block/5")
2907 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-spill-different-register-in-block/6")
2908 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 3/imm32" "F - test-spill-different-register-in-block/7")
2909 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-spill-different-register-in-block/8")
2910 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 4/imm32" "F - test-spill-different-register-in-block/9")
2911 (check-next-stream-line-equal _test-output-stream " 41/increment-ecx" "F - test-spill-different-register-in-block/10")
2912 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-spill-different-register-in-block/11")
2913 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-spill-different-register-in-block/12")
2914 (check-next-stream-line-equal _test-output-stream " }" "F - test-spill-different-register-in-block/13")
2915 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-spill-different-register-in-block/14")
2916 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-spill-different-register-in-block/15")
2917 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-spill-different-register-in-block/16")
2918 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-spill-different-register-in-block/17")
2919 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-spill-different-register-in-block/18")
2920
2921 89/<- %esp 5/r32/ebp
2922 5d/pop-to-ebp
2923 c3/return
2924
2925 test-shadow-live-output:
2926
2927 55/push-ebp
2928 89/<- %ebp 4/r32/esp
2929
2930 (clear-stream _test-input-stream)
2931 (clear-stream $_test-input-buffered-file->buffer)
2932 (clear-stream _test-output-stream)
2933 (clear-stream $_test-output-buffered-file->buffer)
2934
2935 (write _test-input-stream "fn foo -> x/ecx: int {\n")
2936 (write _test-input-stream " x <- copy 3\n")
2937 (write _test-input-stream " {\n")
2938 (write _test-input-stream " var y/ecx: int <- copy 4\n")
2939 (write _test-input-stream " }\n")
2940 (write _test-input-stream " x <- increment\n")
2941 (write _test-input-stream "}\n")
2942
2943 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
2944 (flush _test-output-buffered-file)
2945 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
2951
2952 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-shadow-live-output/0")
2953 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-shadow-live-output/1")
2954 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-shadow-live-output/2")
2955 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-shadow-live-output/3")
2956 (check-next-stream-line-equal _test-output-stream " {" "F - test-shadow-live-output/4")
2957 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-shadow-live-output/5")
2958 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-shadow-live-output/7")
2959 (check-next-stream-line-equal _test-output-stream " {" "F - test-shadow-live-output/8")
2960 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-shadow-live-output/9")
2961 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-shadow-live-output/10")
2962 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 4/imm32" "F - test-shadow-live-output/11")
2963 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-shadow-live-output/12")
2964 (check-next-stream-line-equal _test-output-stream " }" "F - test-shadow-live-output/13")
2965 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-shadow-live-output/14")
2966 (check-next-stream-line-equal _test-output-stream " 41/increment-ecx" "F - test-shadow-live-output/15")
2967 (check-next-stream-line-equal _test-output-stream " }" "F - test-shadow-live-output/17")
2968 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-shadow-live-output/18")
2969 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-shadow-live-output/19")
2970 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-shadow-live-output/20")
2971 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-shadow-live-output/21")
2972 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-shadow-live-output/21")
2973
2974 89/<- %esp 5/r32/ebp
2975 5d/pop-to-ebp
2976 c3/return
2977
2978 test-stmt-defines-output-in-same-register-as-inout:
2979
2980 55/push-ebp
2981 89/<- %ebp 4/r32/esp
2982
2983 (clear-stream _test-input-stream)
2984 (clear-stream $_test-input-buffered-file->buffer)
2985 (clear-stream _test-output-stream)
2986 (clear-stream $_test-output-buffered-file->buffer)
2987 (clear-stream _test-error-stream)
2988 (clear-stream $_test-error-buffered-file->buffer)
2989
2990 68/push 0/imm32
2991 68/push 0/imm32
2992 89/<- %edx 4/r32/esp
2993 (tailor-exit-descriptor %edx 0x10)
2994
2995 (write _test-input-stream "fn foo -> x/ecx: int {\n")
2996 (write _test-input-stream " var y/ecx: int <- copy 4\n")
2997 (write _test-input-stream " x <- copy y\n")
2998 (write _test-input-stream "}\n")
2999
3000 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
3001
3002
3003 89/<- %edx 4/r32/esp
3004 (flush _test-output-buffered-file)
3005 (flush _test-error-buffered-file)
3006 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
3012
3013 (check-stream-equal _test-error-stream "" "F - test-stmt-defines-output-in-same-register-as-inout: error stream should be empty")
3014
3015
3016 81 0/subop/add %esp 8/imm32
3017
3018 5d/pop-to-ebp
3019 c3/return
3020
3021 test-local-clobbered-by-fn-output:
3022
3023 55/push-ebp
3024 89/<- %ebp 4/r32/esp
3025
3026 (clear-stream _test-input-stream)
3027 (clear-stream $_test-input-buffered-file->buffer)
3028 (clear-stream _test-output-stream)
3029 (clear-stream $_test-output-buffered-file->buffer)
3030
3031 (write _test-input-stream "fn foo -> x/ecx: int {\n")
3032 (write _test-input-stream " var y/ecx: int <- copy 4\n")
3033 (write _test-input-stream " x <- copy y\n")
3034 (write _test-input-stream "}\n")
3035
3036 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3037 (flush _test-output-buffered-file)
3038 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3044
3045 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-local-clobbered-by-fn-output/0")
3046 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-local-clobbered-by-fn-output/1")
3047 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-local-clobbered-by-fn-output/2")
3048 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-local-clobbered-by-fn-output/3")
3049 (check-next-stream-line-equal _test-output-stream " {" "F - test-local-clobbered-by-fn-output/4")
3050 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-local-clobbered-by-fn-output/5")
3051 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 4/imm32" "F - test-local-clobbered-by-fn-output/6")
3052 (check-next-stream-line-equal _test-output-stream " 89/<- %ecx 0x00000001/r32" "F - test-local-clobbered-by-fn-output/7")
3053 (check-next-stream-line-equal _test-output-stream " }" "F - test-local-clobbered-by-fn-output/8")
3054 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-local-clobbered-by-fn-output/9")
3055 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-local-clobbered-by-fn-output/10")
3056 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-local-clobbered-by-fn-output/11")
3057 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-local-clobbered-by-fn-output/12")
3058 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-local-clobbered-by-fn-output/13")
3059
3060 89/<- %esp 5/r32/ebp
3061 5d/pop-to-ebp
3062 c3/return
3063
3064 test-read-output:
3065
3066 55/push-ebp
3067 89/<- %ebp 4/r32/esp
3068
3069 (clear-stream _test-input-stream)
3070 (clear-stream $_test-input-buffered-file->buffer)
3071 (clear-stream _test-output-stream)
3072 (clear-stream $_test-output-buffered-file->buffer)
3073
3074 (write _test-input-stream "fn foo -> x/ecx: int {\n")
3075 (write _test-input-stream " x <- copy 0x34\n")
3076 (write _test-input-stream " compare x, 0x35\n")
3077 (write _test-input-stream "}\n")
3078
3079 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3080 (flush _test-output-buffered-file)
3081 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3087
3088 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-read-output/0")
3089 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-read-output/1")
3090 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-read-output/2")
3091 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-read-output/3")
3092 (check-next-stream-line-equal _test-output-stream " {" "F - test-read-output/4")
3093 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-read-output/5")
3094 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 0x34/imm32" "F - test-read-output/6")
3095 (check-next-stream-line-equal _test-output-stream " 81 7/subop/compare %ecx 0x35/imm32" "F - test-read-output/7")
3096 (check-next-stream-line-equal _test-output-stream " }" "F - test-read-output/8")
3097 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-read-output/9")
3098 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-read-output/10")
3099 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-read-output/11")
3100 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-read-output/12")
3101 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-read-output/13")
3102
3103 89/<- %esp 5/r32/ebp
3104 5d/pop-to-ebp
3105 c3/return
3106
3107 test-fn-output-written-in-inner-block:
3108
3109 55/push-ebp
3110 89/<- %ebp 4/r32/esp
3111
3112 (clear-stream _test-input-stream)
3113 (clear-stream $_test-input-buffered-file->buffer)
3114 (clear-stream _test-output-stream)
3115 (clear-stream $_test-output-buffered-file->buffer)
3116
3117 (write _test-input-stream "fn foo -> out/edi: int {\n")
3118 (write _test-input-stream " var a/eax: int <- copy 3\n")
3119 (write _test-input-stream " {\n")
3120 (write _test-input-stream " var a/ecx: int <- copy 4\n")
3121 (write _test-input-stream " out <- copy a\n")
3122 (write _test-input-stream " }\n")
3123 (write _test-input-stream " compare a, 0\n")
3124 (write _test-input-stream "}\n")
3125
3126 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3127 (flush _test-output-buffered-file)
3128 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3134
3135
3136 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-fn-output-written-in-inner-block/0")
3137 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-fn-output-written-in-inner-block/1")
3138 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-fn-output-written-in-inner-block/2")
3139 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-fn-output-written-in-inner-block/3")
3140 (check-next-stream-line-equal _test-output-stream " {" "F - test-fn-output-written-in-inner-block/4")
3141 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-fn-output-written-in-inner-block/5")
3142 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-fn-output-written-in-inner-block/6")
3143 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 3/imm32" "F - test-fn-output-written-in-inner-block/7")
3144 (check-next-stream-line-equal _test-output-stream " {" "F - test-fn-output-written-in-inner-block/8")
3145 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-fn-output-written-in-inner-block/9")
3146 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-fn-output-written-in-inner-block/10")
3147 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 4/imm32" "F - test-fn-output-written-in-inner-block/10")
3148 (check-next-stream-line-equal _test-output-stream " 89/<- %edi 0x00000001/r32" "F - test-fn-output-written-in-inner-block/11")
3149 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-fn-output-written-in-inner-block/12")
3150 (check-next-stream-line-equal _test-output-stream " }" "F - test-fn-output-written-in-inner-block/13")
3151 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-fn-output-written-in-inner-block/14")
3152 (check-next-stream-line-equal _test-output-stream " 3d/compare-eax-with 0/imm32" "F - test-fn-output-written-in-inner-block/15")
3153 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-fn-output-written-in-inner-block/16")
3154 (check-next-stream-line-equal _test-output-stream " }" "F - test-fn-output-written-in-inner-block/17")
3155 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-fn-output-written-in-inner-block/18")
3156 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-fn-output-written-in-inner-block/19")
3157 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-fn-output-written-in-inner-block/20")
3158 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-fn-output-written-in-inner-block/21")
3159 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-fn-output-written-in-inner-block/22")
3160
3161 89/<- %esp 5/r32/ebp
3162 5d/pop-to-ebp
3163 c3/return
3164
3165 test-convert-function-with-branches-in-block:
3166
3167 55/push-ebp
3168 89/<- %ebp 4/r32/esp
3169
3170 (clear-stream _test-input-stream)
3171 (clear-stream $_test-input-buffered-file->buffer)
3172 (clear-stream _test-output-stream)
3173 (clear-stream $_test-output-buffered-file->buffer)
3174
3175 (write _test-input-stream "fn foo x: int {\n")
3176 (write _test-input-stream " {\n")
3177 (write _test-input-stream " break-if->=\n")
3178 (write _test-input-stream " loop-if-addr<\n")
3179 (write _test-input-stream " increment x\n")
3180 (write _test-input-stream " loop\n")
3181 (write _test-input-stream " }\n")
3182 (write _test-input-stream "}\n")
3183
3184 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3185 (flush _test-output-buffered-file)
3186 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3192
3193 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-branches-in-block/0")
3194 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-branches-in-block/1")
3195 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-branches-in-block/2")
3196 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-branches-in-block/3")
3197 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-block/4")
3198 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-branches-in-block/5")
3199 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-block/6")
3200 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-with-branches-in-block/7")
3201 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-block/8")
3202 (check-next-stream-line-equal _test-output-stream " 0f 8c/jump-if-< break/disp32" "F - test-convert-function-with-branches-in-block/9")
3203 (check-next-stream-line-equal _test-output-stream " e9/jump $foo:0x00000002:break/disp32" "F - test-convert-function-with-branches-in-block/10")
3204 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-block/11")
3205 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-block/12")
3206 (check-next-stream-line-equal _test-output-stream " 0f 83/jump-if-addr>= break/disp32" "F - test-convert-function-with-branches-in-block/13")
3207 (check-next-stream-line-equal _test-output-stream " e9/jump $foo:0x00000002:loop/disp32" "F - test-convert-function-with-branches-in-block/14")
3208 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-block/15")
3209 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0x00000008)" "F - test-convert-function-with-branches-in-block/16")
3210 (check-next-stream-line-equal _test-output-stream " e9/jump loop/disp32" "F - test-convert-function-with-branches-in-block/17")
3211 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-block/18")
3212 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-with-branches-in-block/19")
3213 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-block/20")
3214 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-branches-in-block/21")
3215 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-branches-in-block/22")
3216 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-branches-in-block/23")
3217 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-branches-in-block/24")
3218 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-branches-in-block/25")
3219
3220 89/<- %esp 5/r32/ebp
3221 5d/pop-to-ebp
3222 c3/return
3223
3224 test-convert-function-with-branches-in-block-2:
3225
3226 55/push-ebp
3227 89/<- %ebp 4/r32/esp
3228
3229 (clear-stream _test-input-stream)
3230 (clear-stream $_test-input-buffered-file->buffer)
3231 (clear-stream _test-output-stream)
3232 (clear-stream $_test-output-buffered-file->buffer)
3233
3234 (write _test-input-stream "fn foo x: int {\n")
3235 (write _test-input-stream " {\n")
3236 (write _test-input-stream " break-if->=\n")
3237 (write _test-input-stream " loop-if-float<\n")
3238 (write _test-input-stream " increment x\n")
3239 (write _test-input-stream " loop\n")
3240 (write _test-input-stream " }\n")
3241 (write _test-input-stream "}\n")
3242
3243 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3244 (flush _test-output-buffered-file)
3245 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3251
3252 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-branches-in-block/0")
3253 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-branches-in-block/1")
3254 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-branches-in-block/2")
3255 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-branches-in-block/3")
3256 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-block/4")
3257 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-branches-in-block/5")
3258 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-block/6")
3259 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-with-branches-in-block/7")
3260 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-block/8")
3261 (check-next-stream-line-equal _test-output-stream " 0f 8c/jump-if-< break/disp32" "F - test-convert-function-with-branches-in-block/9")
3262 (check-next-stream-line-equal _test-output-stream " e9/jump $foo:0x00000002:break/disp32" "F - test-convert-function-with-branches-in-block/10")
3263 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-block/11")
3264 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-block/12")
3265 (check-next-stream-line-equal _test-output-stream " 0f 83/jump-if-addr>= break/disp32" "F - test-convert-function-with-branches-in-block/13")
3266 (check-next-stream-line-equal _test-output-stream " e9/jump $foo:0x00000002:loop/disp32" "F - test-convert-function-with-branches-in-block/14")
3267 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-block/15")
3268 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0x00000008)" "F - test-convert-function-with-branches-in-block/16")
3269 (check-next-stream-line-equal _test-output-stream " e9/jump loop/disp32" "F - test-convert-function-with-branches-in-block/17")
3270 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-block/18")
3271 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-with-branches-in-block/19")
3272 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-block/20")
3273 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-branches-in-block/21")
3274 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-branches-in-block/22")
3275 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-branches-in-block/23")
3276 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-branches-in-block/24")
3277 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-branches-in-block/25")
3278
3279 89/<- %esp 5/r32/ebp
3280 5d/pop-to-ebp
3281 c3/return
3282
3283 test-convert-function-with-branches-in-named-block:
3284
3285 55/push-ebp
3286 89/<- %ebp 4/r32/esp
3287
3288 (clear-stream _test-input-stream)
3289 (clear-stream $_test-input-buffered-file->buffer)
3290 (clear-stream _test-output-stream)
3291 (clear-stream $_test-output-buffered-file->buffer)
3292
3293 (write _test-input-stream "fn foo x: int {\n")
3294 (write _test-input-stream " $bar: {\n")
3295 (write _test-input-stream " break-if->= $bar\n")
3296 (write _test-input-stream " loop-if-addr< $bar\n")
3297 (write _test-input-stream " increment x\n")
3298 (write _test-input-stream " loop\n")
3299 (write _test-input-stream " }\n")
3300 (write _test-input-stream "}\n")
3301
3302 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3303 (flush _test-output-buffered-file)
3304 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3310
3311 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-branches-in-named-block/0")
3312 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-branches-in-named-block/1")
3313 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-branches-in-named-block/2")
3314 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-branches-in-named-block/3")
3315 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-named-block/4")
3316 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-branches-in-named-block/5")
3317 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-named-block/6")
3318 (check-next-stream-line-equal _test-output-stream "$bar:loop:" "F - test-convert-function-with-branches-in-named-block/7")
3319 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-named-block/8")
3320 (check-next-stream-line-equal _test-output-stream " 0f 8c/jump-if-< break/disp32" "F - test-convert-function-with-branches-in-named-block/9")
3321 (check-next-stream-line-equal _test-output-stream " e9/jump $bar:break/disp32" "F - test-convert-function-with-branches-in-named-block/10")
3322 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-named-block/11")
3323 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-in-named-block/12")
3324 (check-next-stream-line-equal _test-output-stream " 0f 83/jump-if-addr>= break/disp32" "F - test-convert-function-with-branches-in-named-block/13")
3325 (check-next-stream-line-equal _test-output-stream " e9/jump $bar:loop/disp32" "F - test-convert-function-with-branches-in-named-block/14")
3326 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-named-block/15")
3327 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0x00000008)" "F - test-convert-function-with-branches-in-named-block/16")
3328 (check-next-stream-line-equal _test-output-stream " e9/jump loop/disp32" "F - test-convert-function-with-branches-in-named-block/17")
3329 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-named-block/18")
3330 (check-next-stream-line-equal _test-output-stream "$bar:break:" "F - test-convert-function-with-branches-in-named-block/19")
3331 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-in-named-block/20")
3332 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-branches-in-named-block/21")
3333 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-branches-in-named-block/22")
3334 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-branches-in-named-block/23")
3335 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-branches-in-named-block/24")
3336 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-branches-in-named-block/25")
3337
3338 89/<- %esp 5/r32/ebp
3339 5d/pop-to-ebp
3340 c3/return
3341
3342 test-convert-function-with-var-in-nested-block:
3343
3344 55/push-ebp
3345 89/<- %ebp 4/r32/esp
3346
3347 (clear-stream _test-input-stream)
3348 (clear-stream $_test-input-buffered-file->buffer)
3349 (clear-stream _test-output-stream)
3350 (clear-stream $_test-output-buffered-file->buffer)
3351
3352 (write _test-input-stream "fn foo x: int {\n")
3353 (write _test-input-stream " {\n")
3354 (write _test-input-stream " {\n")
3355 (write _test-input-stream " var x: int\n")
3356 (write _test-input-stream " increment x\n")
3357 (write _test-input-stream " }\n")
3358 (write _test-input-stream " }\n")
3359 (write _test-input-stream "}\n")
3360
3361 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3362 (flush _test-output-buffered-file)
3363 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3369
3370 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-var-in-nested-block/0")
3371 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-var-in-nested-block/1")
3372 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-var-in-nested-block/2")
3373 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-var-in-nested-block/3")
3374 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-var-in-nested-block/4")
3375 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-var-in-nested-block/5")
3376 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-var-in-nested-block/6")
3377 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-with-var-in-nested-block/7")
3378 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-var-in-nested-block/8")
3379 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:loop:" "F - test-convert-function-with-var-in-nested-block/9")
3380 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-var-in-nested-block/10")
3381 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0xfffffffc)" "F - test-convert-function-with-var-in-nested-block/11")
3382 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-var-in-nested-block/12")
3383 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-var-in-nested-block/13")
3384 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:break:" "F - test-convert-function-with-var-in-nested-block/14")
3385 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-var-in-nested-block/15")
3386 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-with-var-in-nested-block/16")
3387 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-var-in-nested-block/17")
3388 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-var-in-nested-block/18")
3389 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-var-in-nested-block/19")
3390 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-var-in-nested-block/20")
3391 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-var-in-nested-block/21")
3392 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-var-in-nested-block/22")
3393
3394 89/<- %esp 5/r32/ebp
3395 5d/pop-to-ebp
3396 c3/return
3397
3398 test-convert-function-with-multiple-vars-in-nested-blocks:
3399
3400 55/push-ebp
3401 89/<- %ebp 4/r32/esp
3402
3403 (clear-stream _test-input-stream)
3404 (clear-stream $_test-input-buffered-file->buffer)
3405 (clear-stream _test-output-stream)
3406 (clear-stream $_test-output-buffered-file->buffer)
3407
3408 (write _test-input-stream "fn foo x: int {\n")
3409 (write _test-input-stream " {\n")
3410 (write _test-input-stream " var x/eax: int <- copy 0\n")
3411 (write _test-input-stream " {\n")
3412 (write _test-input-stream " var y: int\n")
3413 (write _test-input-stream " x <- add y\n")
3414 (write _test-input-stream " }\n")
3415 (write _test-input-stream " }\n")
3416 (write _test-input-stream "}\n")
3417
3418 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3419 (flush _test-output-buffered-file)
3420 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3426
3427 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-multiple-vars-in-nested-blocks/0")
3428 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-multiple-vars-in-nested-blocks/1")
3429 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-multiple-vars-in-nested-blocks/2")
3430 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-multiple-vars-in-nested-blocks/3")
3431 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-multiple-vars-in-nested-blocks/4")
3432 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-multiple-vars-in-nested-blocks/5")
3433 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-multiple-vars-in-nested-blocks/6")
3434 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-with-multiple-vars-in-nested-blocks/7")
3435 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-function-with-multiple-vars-in-nested-blocks/8")
3436 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-function-with-multiple-vars-in-nested-blocks/9")
3437 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-multiple-vars-in-nested-blocks/10")
3438 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:loop:" "F - test-convert-function-with-multiple-vars-in-nested-blocks/11")
3439 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-multiple-vars-in-nested-blocks/12")
3440 (check-next-stream-line-equal _test-output-stream " 03/add *(ebp+0xfffffff8) 0x00000000/r32" "F - test-convert-function-with-multiple-vars-in-nested-blocks/13")
3441 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-multiple-vars-in-nested-blocks/14")
3442 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-multiple-vars-in-nested-blocks/15")
3443 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:break:" "F - test-convert-function-with-multiple-vars-in-nested-blocks/16")
3444 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-function-with-multiple-vars-in-nested-blocks/17")
3445 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-multiple-vars-in-nested-blocks/18")
3446 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-with-multiple-vars-in-nested-blocks/19")
3447 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-multiple-vars-in-nested-blocks/20")
3448 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-multiple-vars-in-nested-blocks/21")
3449 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-multiple-vars-in-nested-blocks/22")
3450 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-multiple-vars-in-nested-blocks/23")
3451 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-multiple-vars-in-nested-blocks/24")
3452 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-multiple-vars-in-nested-blocks/25")
3453
3454 89/<- %esp 5/r32/ebp
3455 5d/pop-to-ebp
3456 c3/return
3457
3458 test-convert-function-with-branches-and-local-vars:
3459
3460
3461
3462
3463 55/push-ebp
3464 89/<- %ebp 4/r32/esp
3465
3466 (clear-stream _test-input-stream)
3467 (clear-stream $_test-input-buffered-file->buffer)
3468 (clear-stream _test-output-stream)
3469 (clear-stream $_test-output-buffered-file->buffer)
3470
3471 (write _test-input-stream "fn foo {\n")
3472 (write _test-input-stream " {\n")
3473 (write _test-input-stream " var x: int\n")
3474 (write _test-input-stream " break-if->=\n")
3475 (write _test-input-stream " increment x\n")
3476 (write _test-input-stream " }\n")
3477 (write _test-input-stream "}\n")
3478
3479 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3480 (flush _test-output-buffered-file)
3481 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3487
3488 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-branches-and-local-vars/0")
3489 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-branches-and-local-vars/1")
3490 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-branches-and-local-vars/2")
3491 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-branches-and-local-vars/3")
3492 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-and-local-vars/4")
3493 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-branches-and-local-vars/5")
3494 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-and-local-vars/6")
3495 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-with-branches-and-local-vars/7")
3496 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-branches-and-local-vars/8")
3497 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-and-local-vars/9")
3498 (check-next-stream-line-equal _test-output-stream " 0f 8c/jump-if-< break/disp32" "F - test-convert-function-with-branches-and-local-vars/10")
3499 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-branches-and-local-vars/11")
3500 (check-next-stream-line-equal _test-output-stream " e9/jump $foo:0x00000002:break/disp32" "F - test-convert-function-with-branches-and-local-vars/12")
3501 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-and-local-vars/13")
3502 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0xfffffffc)" "F - test-convert-function-with-branches-and-local-vars/14")
3503 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-branches-and-local-vars/15")
3504 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-and-local-vars/16")
3505 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-with-branches-and-local-vars/17")
3506 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-and-local-vars/18")
3507 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-branches-and-local-vars/19")
3508 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-branches-and-local-vars/20")
3509 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-branches-and-local-vars/21")
3510 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-branches-and-local-vars/22")
3511 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-branches-and-local-vars/23")
3512
3513 89/<- %esp 5/r32/ebp
3514 5d/pop-to-ebp
3515 c3/return
3516
3517 test-convert-function-with-conditional-loops-and-local-vars:
3518
3519
3520
3521
3522 55/push-ebp
3523 89/<- %ebp 4/r32/esp
3524
3525 (clear-stream _test-input-stream)
3526 (clear-stream $_test-input-buffered-file->buffer)
3527 (clear-stream _test-output-stream)
3528 (clear-stream $_test-output-buffered-file->buffer)
3529
3530 (write _test-input-stream "fn foo {\n")
3531 (write _test-input-stream " {\n")
3532 (write _test-input-stream " var x: int\n")
3533 (write _test-input-stream " loop-if->=\n")
3534 (write _test-input-stream " increment x\n")
3535 (write _test-input-stream " }\n")
3536 (write _test-input-stream "}\n")
3537
3538 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3539 (flush _test-output-buffered-file)
3540 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3546
3547 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-conditional-loops-and-local-vars/0")
3548 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-conditional-loops-and-local-vars/1")
3549 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-conditional-loops-and-local-vars/2")
3550 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-conditional-loops-and-local-vars/3")
3551 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-conditional-loops-and-local-vars/4")
3552 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-conditional-loops-and-local-vars/5")
3553 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-conditional-loops-and-local-vars/6")
3554 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-with-conditional-loops-and-local-vars/7")
3555 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-conditional-loops-and-local-vars/8")
3556 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-conditional-loops-and-local-vars/9")
3557 (check-next-stream-line-equal _test-output-stream " 0f 8c/jump-if-< break/disp32" "F - test-convert-function-with-conditional-loops-and-local-vars/10")
3558 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-conditional-loops-and-local-vars/11")
3559 (check-next-stream-line-equal _test-output-stream " e9/jump $foo:0x00000002:loop/disp32" "F - test-convert-function-with-conditional-loops-and-local-vars/12")
3560 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-conditional-loops-and-local-vars/13")
3561 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0xfffffffc)" "F - test-convert-function-with-conditional-loops-and-local-vars/14")
3562 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-conditional-loops-and-local-vars/15")
3563 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-conditional-loops-and-local-vars/16")
3564 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-with-conditional-loops-and-local-vars/17")
3565 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-conditional-loops-and-local-vars/18")
3566 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-conditional-loops-and-local-vars/19")
3567 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-conditional-loops-and-local-vars/20")
3568 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-conditional-loops-and-local-vars/21")
3569 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-conditional-loops-and-local-vars/22")
3570 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-conditional-loops-and-local-vars/23")
3571
3572 89/<- %esp 5/r32/ebp
3573 5d/pop-to-ebp
3574 c3/return
3575
3576 test-convert-function-with-unconditional-loops-and-local-vars:
3577
3578
3579
3580
3581 55/push-ebp
3582 89/<- %ebp 4/r32/esp
3583
3584 (clear-stream _test-input-stream)
3585 (clear-stream $_test-input-buffered-file->buffer)
3586 (clear-stream _test-output-stream)
3587 (clear-stream $_test-output-buffered-file->buffer)
3588
3589 (write _test-input-stream "fn foo {\n")
3590 (write _test-input-stream " {\n")
3591 (write _test-input-stream " var x: int\n")
3592 (write _test-input-stream " loop\n")
3593 (write _test-input-stream " increment x\n")
3594 (write _test-input-stream " }\n")
3595 (write _test-input-stream "}\n")
3596
3597 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3598 (flush _test-output-buffered-file)
3599 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3605
3606 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-unconditional-loops-and-local-vars/0")
3607 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-unconditional-loops-and-local-vars/1")
3608 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-unconditional-loops-and-local-vars/2")
3609 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-unconditional-loops-and-local-vars/3")
3610 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-unconditional-loops-and-local-vars/4")
3611 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-unconditional-loops-and-local-vars/5")
3612 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-unconditional-loops-and-local-vars/6")
3613 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-with-unconditional-loops-and-local-vars/7")
3614 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-unconditional-loops-and-local-vars/8")
3615 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-unconditional-loops-and-local-vars/9")
3616 (check-next-stream-line-equal _test-output-stream " e9/jump loop/disp32" "F - test-convert-function-with-unconditional-loops-and-local-vars/10")
3617
3618 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-unconditional-loops-and-local-vars/11")
3619 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-with-unconditional-loops-and-local-vars/12")
3620 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-unconditional-loops-and-local-vars/13")
3621 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-unconditional-loops-and-local-vars/14")
3622 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-unconditional-loops-and-local-vars/15")
3623 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-unconditional-loops-and-local-vars/16")
3624 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-unconditional-loops-and-local-vars/17")
3625 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-unconditional-loops-and-local-vars/18")
3626
3627 89/<- %esp 5/r32/ebp
3628 5d/pop-to-ebp
3629 c3/return
3630
3631 test-convert-function-with-branches-and-loops-and-local-vars:
3632
3633 55/push-ebp
3634 89/<- %ebp 4/r32/esp
3635
3636 (clear-stream _test-input-stream)
3637 (clear-stream $_test-input-buffered-file->buffer)
3638 (clear-stream _test-output-stream)
3639 (clear-stream $_test-output-buffered-file->buffer)
3640
3641 (write _test-input-stream "fn foo {\n")
3642 (write _test-input-stream " {\n")
3643 (write _test-input-stream " var x: int\n")
3644 (write _test-input-stream " break-if->=\n")
3645 (write _test-input-stream " increment x\n")
3646 (write _test-input-stream " loop\n")
3647 (write _test-input-stream " }\n")
3648 (write _test-input-stream "}\n")
3649
3650 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3651 (flush _test-output-buffered-file)
3652 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3658
3659 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-branches-and-loops-and-local-vars/0")
3660 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-branches-and-loops-and-local-vars/1")
3661 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-branches-and-loops-and-local-vars/2")
3662 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-branches-and-loops-and-local-vars/3")
3663 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-and-loops-and-local-vars/4")
3664 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-branches-and-loops-and-local-vars/5")
3665 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-and-loops-and-local-vars/6")
3666 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-with-branches-and-loops-and-local-vars/7")
3667 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-branches-and-loops-and-local-vars/8")
3668 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-branches-and-loops-and-local-vars/9")
3669 (check-next-stream-line-equal _test-output-stream " 0f 8c/jump-if-< break/disp32" "F - test-convert-function-with-branches-and-loops-and-local-vars/10")
3670 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-branches-and-loops-and-local-vars/11")
3671 (check-next-stream-line-equal _test-output-stream " e9/jump $foo:0x00000002:break/disp32" "F - test-convert-function-with-branches-and-loops-and-local-vars/12")
3672 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-and-loops-and-local-vars/13")
3673 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0xfffffffc)" "F - test-convert-function-with-branches-and-loops-and-local-vars/14")
3674 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-branches-and-loops-and-local-vars/15")
3675 (check-next-stream-line-equal _test-output-stream " e9/jump loop/disp32" "F - test-convert-function-with-branches-and-loops-and-local-vars/16")
3676 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-and-loops-and-local-vars/17")
3677 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-with-branches-and-loops-and-local-vars/18")
3678 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-branches-and-loops-and-local-vars/19")
3679 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-branches-and-loops-and-local-vars/20")
3680 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-branches-and-loops-and-local-vars/21")
3681 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-branches-and-loops-and-local-vars/22")
3682 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-branches-and-loops-and-local-vars/23")
3683 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-branches-and-loops-and-local-vars/24")
3684
3685 89/<- %esp 5/r32/ebp
3686 5d/pop-to-ebp
3687 c3/return
3688
3689 test-convert-function-with-nonlocal-branches-and-loops-and-local-vars:
3690
3691 55/push-ebp
3692 89/<- %ebp 4/r32/esp
3693
3694 (clear-stream _test-input-stream)
3695 (clear-stream $_test-input-buffered-file->buffer)
3696 (clear-stream _test-output-stream)
3697 (clear-stream $_test-output-buffered-file->buffer)
3698
3699 (write _test-input-stream "fn foo {\n")
3700 (write _test-input-stream " a: {\n")
3701 (write _test-input-stream " var x: int\n")
3702 (write _test-input-stream " {\n")
3703 (write _test-input-stream " var y: int\n")
3704 (write _test-input-stream " break-if->= a\n")
3705 (write _test-input-stream " increment x\n")
3706 (write _test-input-stream " loop\n")
3707 (write _test-input-stream " }\n")
3708 (write _test-input-stream " }\n")
3709 (write _test-input-stream "}\n")
3710
3711 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3712 (flush _test-output-buffered-file)
3713 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3719
3720 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/0")
3721 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/1")
3722 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/2")
3723 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/3")
3724 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/4")
3725 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/5")
3726 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/6")
3727 (check-next-stream-line-equal _test-output-stream "a:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/7")
3728 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/8")
3729 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/9")
3730 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/10")
3731 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/11")
3732 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/12")
3733 (check-next-stream-line-equal _test-output-stream " 0f 8c/jump-if-< break/disp32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/13")
3734 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/14")
3735 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/15")
3736 (check-next-stream-line-equal _test-output-stream " e9/jump a:break/disp32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/16")
3737 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/17")
3738 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *(ebp+0xfffffffc)" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/18")
3739 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/19")
3740 (check-next-stream-line-equal _test-output-stream " e9/jump loop/disp32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/20")
3741 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/21")
3742 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/22")
3743 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/23")
3744 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/24")
3745 (check-next-stream-line-equal _test-output-stream "a:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/25")
3746 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/26")
3747 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/27")
3748 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/28")
3749 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/29")
3750 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/30")
3751 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars/31")
3752
3753 89/<- %esp 5/r32/ebp
3754 5d/pop-to-ebp
3755 c3/return
3756
3757 test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2:
3758
3759 55/push-ebp
3760 89/<- %ebp 4/r32/esp
3761
3762 (clear-stream _test-input-stream)
3763 (clear-stream $_test-input-buffered-file->buffer)
3764 (clear-stream _test-output-stream)
3765 (clear-stream $_test-output-buffered-file->buffer)
3766
3767
3768 (write _test-input-stream "fn foo {\n")
3769 (write _test-input-stream " a: {\n")
3770 (write _test-input-stream " var x: int\n")
3771 (write _test-input-stream " {\n")
3772 (write _test-input-stream " break-if->= a\n")
3773 (write _test-input-stream " }\n")
3774 (write _test-input-stream " }\n")
3775 (write _test-input-stream "}\n")
3776
3777 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3778 (flush _test-output-buffered-file)
3779 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3785
3786 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/0")
3787 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/1")
3788 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/2")
3789 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/3")
3790 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/4")
3791 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/5")
3792 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/6")
3793 (check-next-stream-line-equal _test-output-stream "a:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/7")
3794 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/8")
3795 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/9")
3796 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/10")
3797 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/11")
3798 (check-next-stream-line-equal _test-output-stream " 0f 8c/jump-if-< break/disp32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/12")
3799 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/13")
3800 (check-next-stream-line-equal _test-output-stream " e9/jump a:break/disp32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/14")
3801 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/15")
3802 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/16")
3803 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/17")
3804 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/18")
3805 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/19")
3806 (check-next-stream-line-equal _test-output-stream "a:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/20")
3807 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/21")
3808 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/22")
3809 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/23")
3810 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/24")
3811 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/25")
3812 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-2/26")
3813
3814 89/<- %esp 5/r32/ebp
3815 5d/pop-to-ebp
3816 c3/return
3817
3818 test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3:
3819
3820 55/push-ebp
3821 89/<- %ebp 4/r32/esp
3822
3823 (clear-stream _test-input-stream)
3824 (clear-stream $_test-input-buffered-file->buffer)
3825 (clear-stream _test-output-stream)
3826 (clear-stream $_test-output-buffered-file->buffer)
3827
3828
3829 (write _test-input-stream "fn foo {\n")
3830 (write _test-input-stream " a: {\n")
3831 (write _test-input-stream " var x: int\n")
3832 (write _test-input-stream " {\n")
3833 (write _test-input-stream " break a\n")
3834 (write _test-input-stream " }\n")
3835 (write _test-input-stream " }\n")
3836 (write _test-input-stream "}\n")
3837
3838 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3839 (flush _test-output-buffered-file)
3840 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3846
3847 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/0")
3848 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/1")
3849 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/2")
3850 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/3")
3851 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/4")
3852 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/5")
3853 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/6")
3854 (check-next-stream-line-equal _test-output-stream "a:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/7")
3855 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/8")
3856 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/9")
3857 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/10")
3858 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/11")
3859 (check-next-stream-line-equal _test-output-stream " e9/jump a:break/disp32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/12")
3860 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/14")
3861 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/15")
3862 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/16")
3863 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/17")
3864 (check-next-stream-line-equal _test-output-stream "a:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/18")
3865 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/19")
3866 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/20")
3867 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/21")
3868 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/22")
3869 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/23")
3870 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-3/24")
3871
3872 89/<- %esp 5/r32/ebp
3873 5d/pop-to-ebp
3874 c3/return
3875
3876 test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4:
3877
3878 55/push-ebp
3879 89/<- %ebp 4/r32/esp
3880
3881 (clear-stream _test-input-stream)
3882 (clear-stream $_test-input-buffered-file->buffer)
3883 (clear-stream _test-output-stream)
3884 (clear-stream $_test-output-buffered-file->buffer)
3885
3886 (write _test-input-stream "fn foo {\n")
3887 (write _test-input-stream " a: {\n")
3888 (write _test-input-stream " var x/esi: int <- copy 0\n")
3889 (write _test-input-stream " {\n")
3890 (write _test-input-stream " break a\n")
3891 (write _test-input-stream " }\n")
3892 (write _test-input-stream " }\n")
3893 (write _test-input-stream "}\n")
3894
3895 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3896 (flush _test-output-buffered-file)
3897 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3903
3904 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/0")
3905 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/1")
3906 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/2")
3907 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/3")
3908 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/4")
3909 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/5")
3910 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/6")
3911 (check-next-stream-line-equal _test-output-stream "a:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/7")
3912 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %esi" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/8")
3913 (check-next-stream-line-equal _test-output-stream " be/copy-to-esi 0/imm32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/9")
3914 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/10")
3915 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:loop:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/11")
3916 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %esi" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/12")
3917 (check-next-stream-line-equal _test-output-stream " e9/jump a:break/disp32" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/13")
3918 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/14")
3919 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/15")
3920 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %esi" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/16")
3921 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/17")
3922 (check-next-stream-line-equal _test-output-stream "a:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/18")
3923 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/19")
3924 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/20")
3925 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/21")
3926 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/22")
3927 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/23")
3928 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-nonlocal-branches-and-loops-and-local-vars-4/24")
3929
3930 89/<- %esp 5/r32/ebp
3931 5d/pop-to-ebp
3932 c3/return
3933
3934 test-convert-function-with-nonlocal-unconditional-break-and-local-vars:
3935
3936 55/push-ebp
3937 89/<- %ebp 4/r32/esp
3938
3939 (clear-stream _test-input-stream)
3940 (clear-stream $_test-input-buffered-file->buffer)
3941 (clear-stream _test-output-stream)
3942 (clear-stream $_test-output-buffered-file->buffer)
3943
3944 (write _test-input-stream "fn foo {\n")
3945 (write _test-input-stream " a: {\n")
3946 (write _test-input-stream " var x: int\n")
3947 (write _test-input-stream " {\n")
3948 (write _test-input-stream " var y: int\n")
3949 (write _test-input-stream " break a\n")
3950 (write _test-input-stream " increment x\n")
3951 (write _test-input-stream " }\n")
3952 (write _test-input-stream " }\n")
3953 (write _test-input-stream "}\n")
3954
3955 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
3956 (flush _test-output-buffered-file)
3957 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
3963
3964 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/0")
3965 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/1")
3966 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/2")
3967 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/3")
3968 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/4")
3969 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/5")
3970 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/6")
3971 (check-next-stream-line-equal _test-output-stream "a:loop:" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/7")
3972 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/8")
3973 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/9")
3974 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:loop:" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/10")
3975 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/11")
3976 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/12")
3977 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/13")
3978 (check-next-stream-line-equal _test-output-stream " e9/jump a:break/disp32" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/14")
3979 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/15")
3980 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:break:" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/16")
3981 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/17")
3982 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/18")
3983 (check-next-stream-line-equal _test-output-stream "a:break:" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/19")
3984 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/20")
3985 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/21")
3986 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/22")
3987 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/23")
3988 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/24")
3989 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-nonlocal-unconditional-break-and-local-vars/25")
3990
3991 89/<- %esp 5/r32/ebp
3992 5d/pop-to-ebp
3993 c3/return
3994
3995 test-convert-function-with-unconditional-break-and-local-vars:
3996
3997 55/push-ebp
3998 89/<- %ebp 4/r32/esp
3999
4000 (clear-stream _test-input-stream)
4001 (clear-stream $_test-input-buffered-file->buffer)
4002 (clear-stream _test-output-stream)
4003 (clear-stream $_test-output-buffered-file->buffer)
4004
4005 (write _test-input-stream "fn foo {\n")
4006 (write _test-input-stream " {\n")
4007 (write _test-input-stream " var x: int\n")
4008 (write _test-input-stream " {\n")
4009 (write _test-input-stream " var y: int\n")
4010 (write _test-input-stream " break\n")
4011 (write _test-input-stream " increment x\n")
4012 (write _test-input-stream " }\n")
4013 (write _test-input-stream " }\n")
4014 (write _test-input-stream "}\n")
4015
4016 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4017 (flush _test-output-buffered-file)
4018 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4024
4025 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-unconditional-break-and-local-vars/0")
4026 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-unconditional-break-and-local-vars/1")
4027 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-unconditional-break-and-local-vars/2")
4028 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-unconditional-break-and-local-vars/3")
4029 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-unconditional-break-and-local-vars/4")
4030 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-unconditional-break-and-local-vars/5")
4031 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-unconditional-break-and-local-vars/6")
4032 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-with-unconditional-break-and-local-vars/7")
4033 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-unconditional-break-and-local-vars/8")
4034 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-unconditional-break-and-local-vars/9")
4035 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:loop:" "F - test-convert-function-with-unconditional-break-and-local-vars/10")
4036 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-unconditional-break-and-local-vars/11")
4037 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-unconditional-break-and-local-vars/12")
4038 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-unconditional-break-and-local-vars/13")
4039 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:break:" "F - test-convert-function-with-unconditional-break-and-local-vars/14")
4040 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-unconditional-break-and-local-vars/15")
4041 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-unconditional-break-and-local-vars/16")
4042 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-with-unconditional-break-and-local-vars/17")
4043 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-unconditional-break-and-local-vars/18")
4044 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-unconditional-break-and-local-vars/19")
4045 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-unconditional-break-and-local-vars/20")
4046 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-unconditional-break-and-local-vars/21")
4047 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-unconditional-break-and-local-vars/22")
4048 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-unconditional-break-and-local-vars/23")
4049
4050 89/<- %esp 5/r32/ebp
4051 5d/pop-to-ebp
4052 c3/return
4053
4054 test-convert-function-with-nonlocal-unconditional-loop-and-local-vars:
4055
4056 55/push-ebp
4057 89/<- %ebp 4/r32/esp
4058
4059 (clear-stream _test-input-stream)
4060 (clear-stream $_test-input-buffered-file->buffer)
4061 (clear-stream _test-output-stream)
4062 (clear-stream $_test-output-buffered-file->buffer)
4063
4064 (write _test-input-stream "fn foo {\n")
4065 (write _test-input-stream " a: {\n")
4066 (write _test-input-stream " var x: int\n")
4067 (write _test-input-stream " {\n")
4068 (write _test-input-stream " var y: int\n")
4069 (write _test-input-stream " loop a\n")
4070 (write _test-input-stream " increment x\n")
4071 (write _test-input-stream " }\n")
4072 (write _test-input-stream " }\n")
4073 (write _test-input-stream "}\n")
4074
4075 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4076 (flush _test-output-buffered-file)
4077 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4083
4084 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/0")
4085 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/1")
4086 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/2")
4087 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/3")
4088 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/4")
4089 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/5")
4090 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/6")
4091 (check-next-stream-line-equal _test-output-stream "a:loop:" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/7")
4092 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/8")
4093 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/9")
4094 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:loop:" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/10")
4095 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/11")
4096 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/12")
4097 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/13")
4098 (check-next-stream-line-equal _test-output-stream " e9/jump a:loop/disp32" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/14")
4099 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/15")
4100 (check-next-stream-line-equal _test-output-stream "$foo:0x00000003:break:" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/16")
4101 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/17")
4102 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/18")
4103 (check-next-stream-line-equal _test-output-stream "a:break:" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/19")
4104 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/20")
4105 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/21")
4106 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/22")
4107 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/23")
4108 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/24")
4109 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-nonlocal-unconditional-loop-and-local-vars/25")
4110
4111 89/<- %esp 5/r32/ebp
4112 5d/pop-to-ebp
4113 c3/return
4114
4115 test-convert-function-with-local-array-var-in-mem:
4116
4117 55/push-ebp
4118 89/<- %ebp 4/r32/esp
4119
4120 (clear-stream _test-input-stream)
4121 (clear-stream $_test-input-buffered-file->buffer)
4122 (clear-stream _test-output-stream)
4123 (clear-stream $_test-output-buffered-file->buffer)
4124
4125 (write _test-input-stream "fn foo {\n")
4126 (write _test-input-stream " var x: (array int 3)\n")
4127 (write _test-input-stream "}\n")
4128
4129 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4130 (flush _test-output-buffered-file)
4131 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4137
4138 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-local-array-var-in-mem/0")
4139 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-local-array-var-in-mem/1")
4140 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-local-array-var-in-mem/2")
4141 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-local-array-var-in-mem/3")
4142 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-array-var-in-mem/4")
4143 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-local-array-var-in-mem/5")
4144
4145 (check-next-stream-line-equal _test-output-stream " (push-n-zero-bytes 0x0000000c)" "F - test-convert-function-with-local-array-var-in-mem/7")
4146 (check-next-stream-line-equal _test-output-stream " 68/push 0x0000000c/imm32" "F - test-convert-function-with-local-array-var-in-mem/8")
4147
4148 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000010/imm32" "F - test-convert-function-with-local-array-var-in-mem/9")
4149
4150 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-array-var-in-mem/10")
4151 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-local-array-var-in-mem/11")
4152 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-local-array-var-in-mem/12")
4153 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-local-array-var-in-mem/13")
4154 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-local-array-var-in-mem/14")
4155 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-local-array-var-in-mem/15")
4156
4157 89/<- %esp 5/r32/ebp
4158 5d/pop-to-ebp
4159 c3/return
4160
4161 test-array-size-in-hex:
4162
4163 55/push-ebp
4164 89/<- %ebp 4/r32/esp
4165
4166 (clear-stream _test-input-stream)
4167 (clear-stream $_test-input-buffered-file->buffer)
4168 (clear-stream _test-output-stream)
4169 (clear-stream $_test-output-buffered-file->buffer)
4170 (clear-stream _test-error-stream)
4171 (clear-stream $_test-error-buffered-file->buffer)
4172
4173 68/push 0/imm32
4174 68/push 0/imm32
4175 89/<- %edx 4/r32/esp
4176 (tailor-exit-descriptor %edx 0x10)
4177
4178 (write _test-input-stream "fn foo {\n")
4179 (write _test-input-stream " var x: (array int 10)\n")
4180 (write _test-input-stream "}\n")
4181
4182 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
4183
4184
4185 89/<- %edx 4/r32/esp
4186 (flush _test-output-buffered-file)
4187 (flush _test-error-buffered-file)
4188 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
4194
4195 (check-stream-equal _test-output-stream "" "F - test-array-size-in-hex: output should be empty")
4196 (check-next-stream-line-equal _test-error-stream "literal integers are always hex in Mu; either start '10' with a '0x' to be unambiguous, or convert it to decimal." "F - test-array-size-in-hex: error message")
4197
4198 (check-ints-equal *(edx+4) 2 "F - test-array-size-in-hex: exit status")
4199
4200 81 0/subop/add %esp 8/imm32
4201
4202 5d/pop-to-ebp
4203 c3/return
4204
4205 test-convert-function-with-populate:
4206
4207 55/push-ebp
4208 89/<- %ebp 4/r32/esp
4209
4210 (clear-stream _test-input-stream)
4211 (clear-stream $_test-input-buffered-file->buffer)
4212 (clear-stream _test-output-stream)
4213 (clear-stream $_test-output-buffered-file->buffer)
4214
4215 (write _test-input-stream "fn foo {\n")
4216 (write _test-input-stream " var x/ecx: (addr handle array int) <- copy 0\n")
4217 (write _test-input-stream " populate x, 7\n")
4218 (write _test-input-stream "}\n")
4219
4220 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4221 (flush _test-output-buffered-file)
4222 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4228
4229 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-populate/0")
4230 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-populate/1")
4231 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-populate/2")
4232 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-populate/3")
4233 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-populate/4")
4234 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-populate/5")
4235 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-function-with-populate/6")
4236 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 0/imm32" "F - test-convert-function-with-populate/7")
4237 (check-next-stream-line-equal _test-output-stream " (allocate-array2 Heap 0x00000004 7 %ecx)" "F - test-convert-function-with-populate/8")
4238 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-function-with-populate/9")
4239 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-populate/10")
4240 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-populate/11")
4241 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-populate/12")
4242 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-populate/13")
4243 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-populate/14")
4244 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-populate/15")
4245
4246 89/<- %esp 5/r32/ebp
4247 5d/pop-to-ebp
4248 c3/return
4249
4250
4251 test-convert-function-with-local-array-of-bytes-in-mem:
4252
4253 55/push-ebp
4254 89/<- %ebp 4/r32/esp
4255
4256 (clear-stream _test-input-stream)
4257 (clear-stream $_test-input-buffered-file->buffer)
4258 (clear-stream _test-output-stream)
4259 (clear-stream $_test-output-buffered-file->buffer)
4260
4261 (write _test-input-stream "fn foo {\n")
4262 (write _test-input-stream " var x: (array byte 3)\n")
4263 (write _test-input-stream "}\n")
4264
4265 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4266 (flush _test-output-buffered-file)
4267 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4273
4274 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-local-array-of-bytes-in-mem/0")
4275 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-local-array-of-bytes-in-mem/1")
4276 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-local-array-of-bytes-in-mem/2")
4277 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-local-array-of-bytes-in-mem/3")
4278 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-array-of-bytes-in-mem/4")
4279 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-local-array-of-bytes-in-mem/5")
4280
4281 (check-next-stream-line-equal _test-output-stream " (push-n-zero-bytes 0x00000003)" "F - test-convert-function-with-local-array-of-bytes-in-mem/7")
4282 (check-next-stream-line-equal _test-output-stream " 68/push 0x00000003/imm32" "F - test-convert-function-with-local-array-of-bytes-in-mem/8")
4283
4284 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000007/imm32" "F - test-convert-function-with-local-array-of-bytes-in-mem/9")
4285
4286 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-array-of-bytes-in-mem/10")
4287 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-local-array-of-bytes-in-mem/11")
4288 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-local-array-of-bytes-in-mem/12")
4289 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-local-array-of-bytes-in-mem/13")
4290 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-local-array-of-bytes-in-mem/14")
4291 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-local-array-of-bytes-in-mem/15")
4292
4293 89/<- %esp 5/r32/ebp
4294 5d/pop-to-ebp
4295 c3/return
4296
4297 test-convert-address:
4298
4299 55/push-ebp
4300 89/<- %ebp 4/r32/esp
4301
4302 (clear-stream _test-input-stream)
4303 (clear-stream $_test-input-buffered-file->buffer)
4304 (clear-stream _test-output-stream)
4305 (clear-stream $_test-output-buffered-file->buffer)
4306
4307 (write _test-input-stream "fn foo {\n")
4308 (write _test-input-stream " var a: int\n")
4309 (write _test-input-stream " var b/eax: (addr int) <- address a\n")
4310 (write _test-input-stream "}\n")
4311
4312 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4313 (flush _test-output-buffered-file)
4314 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4320
4321 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-address/0")
4322 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-address/1")
4323 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-address/2")
4324 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-address/3")
4325 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-address/4")
4326 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-address/5")
4327 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-address/6")
4328 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-address/7")
4329 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(ebp+0xfffffffc) 0x00000000/r32" "F - test-convert-address/8")
4330 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-address/9")
4331 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-address/10")
4332 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-address/11")
4333 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-address/12")
4334 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-address/13")
4335 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-address/14")
4336 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-address/15")
4337 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-address/16")
4338
4339 89/<- %esp 5/r32/ebp
4340 5d/pop-to-ebp
4341 c3/return
4342
4343 test-convert-floating-point-convert:
4344
4345 55/push-ebp
4346 89/<- %ebp 4/r32/esp
4347
4348 (clear-stream _test-input-stream)
4349 (clear-stream $_test-input-buffered-file->buffer)
4350 (clear-stream _test-output-stream)
4351 (clear-stream $_test-output-buffered-file->buffer)
4352
4353 (write _test-input-stream "fn foo {\n")
4354 (write _test-input-stream " var a/eax: int <- copy 0\n")
4355 (write _test-input-stream " var b/xmm1: float <- convert a\n")
4356 (write _test-input-stream "}\n")
4357
4358 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4359 (flush _test-output-buffered-file)
4360 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4366
4367 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-floating-point-convert/0")
4368 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-floating-point-convert/1")
4369 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-floating-point-convert/2")
4370 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-floating-point-convert/3")
4371 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-floating-point-convert/4")
4372 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-floating-point-convert/5")
4373 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-floating-point-convert/6")
4374 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-floating-point-convert/7")
4375 (check-next-stream-line-equal _test-output-stream " 81 5/subop/subtract %esp 4/imm32" "F - test-convert-floating-point-convert/8")
4376 (check-next-stream-line-equal _test-output-stream " f3 0f 11/<- *esp 1/x32" "F - test-convert-floating-point-convert/9")
4377 (check-next-stream-line-equal _test-output-stream " f3 0f 2a/convert-to-float %eax 0x00000001/x32" "F - test-convert-floating-point-convert/10")
4378 (check-next-stream-line-equal _test-output-stream " f3 0f 10/-> *esp 1/x32" "F - test-convert-floating-point-convert/11")
4379 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 4/imm32" "F - test-convert-length-of-array-on-stack/12")
4380 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-floating-point-convert/13")
4381 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-floating-point-convert/14")
4382 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-floating-point-convert/15")
4383 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-floating-point-convert/16")
4384 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-floating-point-convert/17")
4385 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-floating-point-convert/18")
4386 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-floating-point-convert/19")
4387
4388 89/<- %esp 5/r32/ebp
4389 5d/pop-to-ebp
4390 c3/return
4391
4392 test-convert-floating-point-convert-2:
4393
4394 55/push-ebp
4395 89/<- %ebp 4/r32/esp
4396
4397 (clear-stream _test-input-stream)
4398 (clear-stream $_test-input-buffered-file->buffer)
4399 (clear-stream _test-output-stream)
4400 (clear-stream $_test-output-buffered-file->buffer)
4401
4402 (write _test-input-stream "fn foo {\n")
4403 (write _test-input-stream " var a/eax: int <- copy 0\n")
4404 (write _test-input-stream " var b/xmm1: float <- convert a\n")
4405 (write _test-input-stream " a <- convert b\n")
4406 (write _test-input-stream "}\n")
4407
4408 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4409 (flush _test-output-buffered-file)
4410 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4416
4417 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-floating-point-convert-2/0")
4418 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-floating-point-convert-2/1")
4419 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-floating-point-convert-2/2")
4420 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-floating-point-convert-2/3")
4421 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-floating-point-convert-2/4")
4422 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-floating-point-convert-2/5")
4423 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-floating-point-convert-2/6")
4424 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-floating-point-convert-2/7")
4425 (check-next-stream-line-equal _test-output-stream " 81 5/subop/subtract %esp 4/imm32" "F - test-convert-floating-point-convert-2/8")
4426 (check-next-stream-line-equal _test-output-stream " f3 0f 11/<- *esp 1/x32" "F - test-convert-floating-point-convert-2/9")
4427 (check-next-stream-line-equal _test-output-stream " f3 0f 2a/convert-to-float %eax 0x00000001/x32" "F - test-convert-floating-point-convert-2/10")
4428 (check-next-stream-line-equal _test-output-stream " f3 0f 2d/convert-to-int %xmm1 0x00000000/r32" "F - test-convert-floating-point-convert-2/11")
4429 (check-next-stream-line-equal _test-output-stream " f3 0f 10/-> *esp 1/x32" "F - test-convert-floating-point-convert-2/12")
4430 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 4/imm32" "F - test-convert-length-of-array-on-stack/13")
4431 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-floating-point-convert-2/14")
4432 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-floating-point-convert-2/15")
4433 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-floating-point-convert-2/16")
4434 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-floating-point-convert-2/17")
4435 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-floating-point-convert-2/18")
4436 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-floating-point-convert-2/19")
4437 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-floating-point-convert-2/20")
4438
4439 89/<- %esp 5/r32/ebp
4440 5d/pop-to-ebp
4441 c3/return
4442
4443 test-convert-floating-point-operation:
4444
4445 55/push-ebp
4446 89/<- %ebp 4/r32/esp
4447
4448 (clear-stream _test-input-stream)
4449 (clear-stream $_test-input-buffered-file->buffer)
4450 (clear-stream _test-output-stream)
4451 (clear-stream $_test-output-buffered-file->buffer)
4452
4453 (write _test-input-stream "fn f {\n")
4454 (write _test-input-stream " var m: float\n")
4455 (write _test-input-stream " var x/xmm1: float <- copy m\n")
4456 (write _test-input-stream " var y/xmm5: float <- copy m\n")
4457 (write _test-input-stream " x <- copy y\n")
4458 (write _test-input-stream " copy-to m, y\n")
4459 (write _test-input-stream " x <- add y\n")
4460 (write _test-input-stream " x <- add m\n")
4461 (write _test-input-stream " x <- subtract y\n")
4462 (write _test-input-stream " x <- subtract m\n")
4463 (write _test-input-stream " x <- multiply y\n")
4464 (write _test-input-stream " x <- multiply m\n")
4465 (write _test-input-stream " x <- divide y\n")
4466 (write _test-input-stream " x <- divide m\n")
4467 (write _test-input-stream " x <- reciprocal y\n")
4468 (write _test-input-stream " x <- reciprocal m\n")
4469 (write _test-input-stream " x <- square-root y\n")
4470 (write _test-input-stream " x <- square-root m\n")
4471 (write _test-input-stream " x <- inverse-square-root y\n")
4472 (write _test-input-stream " x <- inverse-square-root m\n")
4473 (write _test-input-stream " x <- max y\n")
4474 (write _test-input-stream " x <- max m\n")
4475 (write _test-input-stream " x <- min y\n")
4476 (write _test-input-stream " x <- min m\n")
4477 (write _test-input-stream " compare x, y\n")
4478 (write _test-input-stream " compare x, m\n")
4479 (write _test-input-stream "}\n")
4480
4481 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4482 (flush _test-output-buffered-file)
4483 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4489
4490 (check-next-stream-line-equal _test-output-stream "f:" "F - test-convert-floating-point-operation/0")
4491 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-floating-point-operation/1")
4492 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-floating-point-operation/2")
4493 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-floating-point-operation/3")
4494 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-floating-point-operation/4")
4495 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:loop:" "F - test-convert-floating-point-operation/5")
4496 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-floating-point-operation/6")
4497 (check-next-stream-line-equal _test-output-stream " 81 5/subop/subtract %esp 4/imm32" "F - test-convert-floating-point-operation/7")
4498 (check-next-stream-line-equal _test-output-stream " f3 0f 11/<- *esp 1/x32" "F - test-convert-floating-point-operation/8")
4499 (check-next-stream-line-equal _test-output-stream " f3 0f 10/copy *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-operation/9")
4500 (check-next-stream-line-equal _test-output-stream " 81 5/subop/subtract %esp 4/imm32" "F - test-convert-floating-point-operation/10")
4501 (check-next-stream-line-equal _test-output-stream " f3 0f 11/<- *esp 5/x32" "F - test-convert-floating-point-operation/11")
4502 (check-next-stream-line-equal _test-output-stream " f3 0f 10/copy *(ebp+0xfffffffc) 0x00000005/x32" "F - test-convert-floating-point-operation/12")
4503 (check-next-stream-line-equal _test-output-stream " f3 0f 11/copy %xmm1 0x00000005/x32" "F - test-convert-floating-point-operation/13")
4504 (check-next-stream-line-equal _test-output-stream " f3 0f 11/copy *(ebp+0xfffffffc) 0x00000005/x32" "F - test-convert-floating-point-operation/14")
4505 (check-next-stream-line-equal _test-output-stream " f3 0f 58/add %xmm5 0x00000001/x32" "F - test-convert-floating-point-operation/15")
4506 (check-next-stream-line-equal _test-output-stream " f3 0f 58/add *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-operation/16")
4507 (check-next-stream-line-equal _test-output-stream " f3 0f 5c/subtract %xmm5 0x00000001/x32" "F - test-convert-floating-point-operation/17")
4508 (check-next-stream-line-equal _test-output-stream " f3 0f 5c/subtract *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-operation/18")
4509 (check-next-stream-line-equal _test-output-stream " f3 0f 59/multiply %xmm5 0x00000001/x32" "F - test-convert-floating-point-operation/19")
4510 (check-next-stream-line-equal _test-output-stream " f3 0f 59/multiply *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-operation/20")
4511 (check-next-stream-line-equal _test-output-stream " f3 0f 5e/divide %xmm5 0x00000001/x32" "F - test-convert-floating-point-operation/21")
4512 (check-next-stream-line-equal _test-output-stream " f3 0f 5e/divide *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-operation/22")
4513 (check-next-stream-line-equal _test-output-stream " f3 0f 53/reciprocal %xmm5 0x00000001/x32" "F - test-convert-floating-point-operation/23")
4514 (check-next-stream-line-equal _test-output-stream " f3 0f 53/reciprocal *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-operation/24")
4515 (check-next-stream-line-equal _test-output-stream " f3 0f 51/square-root %xmm5 0x00000001/x32" "F - test-convert-floating-point-operation/25")
4516 (check-next-stream-line-equal _test-output-stream " f3 0f 51/square-root *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-operation/26")
4517 (check-next-stream-line-equal _test-output-stream " f3 0f 52/inverse-square-root %xmm5 0x00000001/x32" "F - test-convert-floating-point-operation/27")
4518 (check-next-stream-line-equal _test-output-stream " f3 0f 52/inverse-square-root *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-operation/28")
4519 (check-next-stream-line-equal _test-output-stream " f3 0f 5f/max %xmm5 0x00000001/x32" "F - test-convert-floating-point-operation/29")
4520 (check-next-stream-line-equal _test-output-stream " f3 0f 5f/max *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-operation/30")
4521 (check-next-stream-line-equal _test-output-stream " f3 0f 5d/min %xmm5 0x00000001/x32" "F - test-convert-floating-point-operation/31")
4522 (check-next-stream-line-equal _test-output-stream " f3 0f 5d/min *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-operation/32")
4523 (check-next-stream-line-equal _test-output-stream " 0f 2f/compare %xmm1 0x00000005/x32" "F - test-convert-floating-point-operation/33")
4524 (check-next-stream-line-equal _test-output-stream " 0f 2f/compare *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-operation/34")
4525 (check-next-stream-line-equal _test-output-stream " f3 0f 10/-> *esp 5/x32" "F - test-convert-floating-point-operation/35")
4526 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 4/imm32" "F - test-convert-floating-point-operation/36")
4527 (check-next-stream-line-equal _test-output-stream " f3 0f 10/-> *esp 1/x32" "F - test-convert-floating-point-operation/37")
4528 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 4/imm32" "F - test-convert-floating-point-operation/38")
4529 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-floating-point-operation/39")
4530 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-floating-point-operation/40")
4531 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:break:" "F - test-convert-floating-point-operation/41")
4532 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-floating-point-operation/42")
4533 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-floating-point-operation/43")
4534 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-floating-point-operation/44")
4535 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-floating-point-operation/45")
4536
4537 89/<- %esp 5/r32/ebp
4538 5d/pop-to-ebp
4539 c3/return
4540
4541 test-convert-floating-point-dereferenced:
4542
4543 55/push-ebp
4544 89/<- %ebp 4/r32/esp
4545
4546 (clear-stream _test-input-stream)
4547 (clear-stream $_test-input-buffered-file->buffer)
4548 (clear-stream _test-output-stream)
4549 (clear-stream $_test-output-buffered-file->buffer)
4550
4551 (write _test-input-stream "fn f {\n")
4552 (write _test-input-stream " var m: float\n")
4553 (write _test-input-stream " var x/xmm1: float <- copy m\n")
4554 (write _test-input-stream " var y/eax: (addr float) <- copy 0\n")
4555 (write _test-input-stream " x <- multiply *y\n")
4556 (write _test-input-stream "}\n")
4557
4558 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4559 (flush _test-output-buffered-file)
4560 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4566
4567 (check-next-stream-line-equal _test-output-stream "f:" "F - test-convert-floating-point-dereferenced/0")
4568 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-floating-point-dereferenced/1")
4569 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-floating-point-dereferenced/2")
4570 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-floating-point-dereferenced/3")
4571 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-floating-point-dereferenced/4")
4572 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:loop:" "F - test-convert-floating-point-dereferenced/5")
4573 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-floating-point-dereferenced/6")
4574 (check-next-stream-line-equal _test-output-stream " 81 5/subop/subtract %esp 4/imm32" "F - test-convert-floating-point-dereferenced/7")
4575 (check-next-stream-line-equal _test-output-stream " f3 0f 11/<- *esp 1/x32" "F - test-convert-floating-point-dereferenced/8")
4576 (check-next-stream-line-equal _test-output-stream " f3 0f 10/copy *(ebp+0xfffffffc) 0x00000001/x32" "F - test-convert-floating-point-dereferenced/9")
4577 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-floating-point-dereferenced/10")
4578 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-floating-point-dereferenced/11")
4579 (check-next-stream-line-equal _test-output-stream " f3 0f 59/multiply *eax 0x00000001/x32" "F - test-convert-floating-point-dereferenced/12")
4580 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-floating-point-dereferenced/13")
4581 (check-next-stream-line-equal _test-output-stream " f3 0f 10/-> *esp 1/x32" "F - test-convert-floating-point-dereferenced/14")
4582 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 4/imm32" "F - test-convert-floating-point-dereferenced/15")
4583 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-floating-point-dereferenced/16")
4584 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-floating-point-dereferenced/17")
4585 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:break:" "F - test-convert-floating-point-dereferenced/18")
4586 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-floating-point-dereferenced/19")
4587 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-floating-point-dereferenced/20")
4588 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-floating-point-dereferenced/21")
4589 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-floating-point-dereferenced/22")
4590
4591 89/<- %esp 5/r32/ebp
4592 5d/pop-to-ebp
4593 c3/return
4594
4595 test-convert-length-of-array:
4596
4597 55/push-ebp
4598 89/<- %ebp 4/r32/esp
4599
4600 (clear-stream _test-input-stream)
4601 (clear-stream $_test-input-buffered-file->buffer)
4602 (clear-stream _test-output-stream)
4603 (clear-stream $_test-output-buffered-file->buffer)
4604
4605 (write _test-input-stream "fn foo a: (addr array int) {\n")
4606 (write _test-input-stream " var b/eax: (addr array int) <- copy a\n")
4607 (write _test-input-stream " var c/eax: int <- length b\n")
4608 (write _test-input-stream "}\n")
4609
4610 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4611 (flush _test-output-buffered-file)
4612 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4618
4619 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-length-of-array/0")
4620 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-length-of-array/1")
4621 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-length-of-array/2")
4622 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-length-of-array/3")
4623 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-length-of-array/4")
4624 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-length-of-array/5")
4625 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-length-of-array/6")
4626 (check-next-stream-line-equal _test-output-stream " 8b/-> *(ebp+0x00000008) 0x00000000/r32" "F - test-convert-length-of-array/7")
4627 (check-next-stream-line-equal _test-output-stream " 8b/-> *eax 0x00000000/r32" "F - test-convert-length-of-array/8")
4628 (check-next-stream-line-equal _test-output-stream " c1/shift 5/subop/>> %eax 0x00000002/imm8" "F - test-convert-length-of-array/9")
4629 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-length-of-array/10")
4630 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-length-of-array/11")
4631 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-length-of-array/12")
4632 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-length-of-array/13")
4633 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-length-of-array/14")
4634 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-length-of-array/15")
4635 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-length-of-array/16")
4636
4637 89/<- %esp 5/r32/ebp
4638 5d/pop-to-ebp
4639 c3/return
4640
4641
4642 test-convert-length-of-array-of-bytes:
4643
4644 55/push-ebp
4645 89/<- %ebp 4/r32/esp
4646
4647 (clear-stream _test-input-stream)
4648 (clear-stream $_test-input-buffered-file->buffer)
4649 (clear-stream _test-output-stream)
4650 (clear-stream $_test-output-buffered-file->buffer)
4651
4652 (write _test-input-stream "fn foo a: (addr array byte) {\n")
4653 (write _test-input-stream " var b/eax: (addr array byte) <- copy a\n")
4654 (write _test-input-stream " var c/eax: int <- length b\n")
4655 (write _test-input-stream "}\n")
4656
4657 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4658 (flush _test-output-buffered-file)
4659 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4665
4666 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-length-of-array-of-bytes/0")
4667 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-length-of-array-of-bytes/1")
4668 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-length-of-array-of-bytes/2")
4669 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-length-of-array-of-bytes/3")
4670 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-length-of-array-of-bytes/4")
4671 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-length-of-array-of-bytes/5")
4672 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-length-of-array-of-bytes/6")
4673 (check-next-stream-line-equal _test-output-stream " 8b/-> *(ebp+0x00000008) 0x00000000/r32" "F - test-convert-length-of-array-of-bytes/7")
4674 (check-next-stream-line-equal _test-output-stream " 8b/-> *eax 0x00000000/r32" "F - test-convert-length-of-array-of-bytes/8")
4675 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-length-of-array-of-bytes/9")
4676 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-length-of-array-of-bytes/10")
4677 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-length-of-array-of-bytes/11")
4678 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-length-of-array-of-bytes/12")
4679 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-length-of-array-of-bytes/13")
4680 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-length-of-array-of-bytes/14")
4681 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-length-of-array-of-bytes/15")
4682
4683 89/<- %esp 5/r32/ebp
4684 5d/pop-to-ebp
4685 c3/return
4686
4687 test-convert-length-of-array-on-stack:
4688
4689 55/push-ebp
4690 89/<- %ebp 4/r32/esp
4691
4692 (clear-stream _test-input-stream)
4693 (clear-stream $_test-input-buffered-file->buffer)
4694 (clear-stream _test-output-stream)
4695 (clear-stream $_test-output-buffered-file->buffer)
4696
4697 (write _test-input-stream "fn foo {\n")
4698 (write _test-input-stream " var a: (array int 3)\n")
4699 (write _test-input-stream " var b/eax: int <- length a\n")
4700 (write _test-input-stream "}\n")
4701
4702 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4703 (flush _test-output-buffered-file)
4704 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4710
4711 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-length-of-array-on-stack/0")
4712 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-length-of-array-on-stack/1")
4713 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-length-of-array-on-stack/2")
4714 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-length-of-array-on-stack/3")
4715 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-length-of-array-on-stack/4")
4716 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-length-of-array-on-stack/5")
4717
4718 (check-next-stream-line-equal _test-output-stream " (push-n-zero-bytes 0x0000000c)" "F - test-convert-length-of-array-on-stack/6")
4719 (check-next-stream-line-equal _test-output-stream " 68/push 0x0000000c/imm32" "F - test-convert-length-of-array-on-stack/7")
4720 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-length-of-array-on-stack/8")
4721 (check-next-stream-line-equal _test-output-stream " 8b/-> *(ebp+0xfffffff0) 0x00000000/r32" "F - test-convert-length-of-array-on-stack/9")
4722 (check-next-stream-line-equal _test-output-stream " c1/shift 5/subop/>> %eax 0x00000002/imm8" "F - test-convert-length-of-array-on-stack/10")
4723 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-length-of-array-on-stack/11")
4724 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000010/imm32" "F - test-convert-length-of-array-on-stack/12")
4725 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-length-of-array-on-stack/13")
4726 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-length-of-array-on-stack/14")
4727 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-length-of-array-on-stack/15")
4728 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-length-of-array-on-stack/16")
4729 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-length-of-array-on-stack/17")
4730 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-length-of-array-on-stack/18")
4731
4732 89/<- %esp 5/r32/ebp
4733 5d/pop-to-ebp
4734 c3/return
4735
4736 test-reg-var-def-with-read-of-same-register:
4737
4738 55/push-ebp
4739 89/<- %ebp 4/r32/esp
4740
4741 (clear-stream _test-input-stream)
4742 (clear-stream $_test-input-buffered-file->buffer)
4743 (clear-stream _test-output-stream)
4744 (clear-stream $_test-output-buffered-file->buffer)
4745 (clear-stream _test-error-stream)
4746 (clear-stream $_test-error-buffered-file->buffer)
4747
4748 68/push 0/imm32
4749 68/push 0/imm32
4750 89/<- %edx 4/r32/esp
4751 (tailor-exit-descriptor %edx 0x10)
4752
4753 (write _test-input-stream "fn foo {\n")
4754 (write _test-input-stream " var arr/eax: (addr array int) <- copy 0\n")
4755 (write _test-input-stream " var idx/ecx: int <- copy 3\n")
4756 (write _test-input-stream " var x/eax: (addr int) <- index arr, idx\n")
4757 (write _test-input-stream "}\n")
4758
4759 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
4760
4761
4762 89/<- %edx 4/r32/esp
4763 (flush _test-output-buffered-file)
4764 (flush _test-error-buffered-file)
4765 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4771 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
4777 (check-stream-equal _test-error-stream "" "F - test-reg-var-def-with-read-of-same-register: error stream should be empty")
4778
4779 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-reg-var-def-with-read-of-same-register/0")
4780 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-reg-var-def-with-read-of-same-register/1")
4781 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-reg-var-def-with-read-of-same-register/2")
4782 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-reg-var-def-with-read-of-same-register/3")
4783 (check-next-stream-line-equal _test-output-stream " {" "F - test-reg-var-def-with-read-of-same-register/4")
4784 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-reg-var-def-with-read-of-same-register/5")
4785 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-reg-var-def-with-read-of-same-register/6")
4786 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-reg-var-def-with-read-of-same-register/7")
4787 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-reg-var-def-with-read-of-same-register/8")
4788 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-reg-var-def-with-read-of-same-register/9")
4789 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + ecx<<0x00000002 + 4) 0x00000000/r32" "F - test-reg-var-def-with-read-of-same-register/11")
4790 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-reg-var-def-with-read-of-same-register/13")
4791 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-reg-var-def-with-read-of-same-register/14")
4792 (check-next-stream-line-equal _test-output-stream " }" "F - test-reg-var-def-with-read-of-same-register/15")
4793 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-reg-var-def-with-read-of-same-register/16")
4794 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-reg-var-def-with-read-of-same-register/17")
4795 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-reg-var-def-with-read-of-same-register/18")
4796 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-reg-var-def-with-read-of-same-register/19")
4797 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-reg-var-def-with-read-of-same-register/20")
4798
4799 81 0/subop/add %esp 8/imm32
4800
4801 5d/pop-to-ebp
4802 c3/return
4803
4804 test-convert-index-into-array:
4805
4806 55/push-ebp
4807 89/<- %ebp 4/r32/esp
4808
4809 (clear-stream _test-input-stream)
4810 (clear-stream $_test-input-buffered-file->buffer)
4811 (clear-stream _test-output-stream)
4812 (clear-stream $_test-output-buffered-file->buffer)
4813
4814 (write _test-input-stream "fn foo {\n")
4815 (write _test-input-stream " var arr/eax: (addr array int) <- copy 0\n")
4816 (write _test-input-stream " var idx/ecx: int <- copy 3\n")
4817 (write _test-input-stream " var x/eax: (addr int) <- index arr, idx\n")
4818 (write _test-input-stream "}\n")
4819
4820 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4821 (flush _test-output-buffered-file)
4822 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4828
4829 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-index-into-array/0")
4830 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-index-into-array/1")
4831 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-index-into-array/2")
4832 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-index-into-array/3")
4833 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-index-into-array/4")
4834 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-index-into-array/5")
4835 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-index-into-array/6")
4836 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-index-into-array/7")
4837 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-index-into-array/8")
4838 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-convert-index-into-array/9")
4839 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + ecx<<0x00000002 + 4) 0x00000000/r32" "F - test-convert-index-into-array/10")
4840 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-index-into-array/11")
4841 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-index-into-array/12")
4842 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-index-into-array/13")
4843 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-index-into-array/14")
4844 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-index-into-array/15")
4845 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-index-into-array/16")
4846 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-index-into-array/17")
4847 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-index-into-array/18")
4848
4849 89/<- %esp 5/r32/ebp
4850 5d/pop-to-ebp
4851 c3/return
4852
4853 test-convert-index-into-array-of-bytes:
4854
4855 55/push-ebp
4856 89/<- %ebp 4/r32/esp
4857
4858 (clear-stream _test-input-stream)
4859 (clear-stream $_test-input-buffered-file->buffer)
4860 (clear-stream _test-output-stream)
4861 (clear-stream $_test-output-buffered-file->buffer)
4862
4863 (write _test-input-stream "fn foo {\n")
4864 (write _test-input-stream " var arr/eax: (addr array byte) <- copy 0\n")
4865 (write _test-input-stream " var idx/ecx: int <- copy 3\n")
4866 (write _test-input-stream " var x/eax: (addr byte) <- index arr, idx\n")
4867 (write _test-input-stream "}\n")
4868
4869 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4870 (flush _test-output-buffered-file)
4871 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4877
4878 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-index-into-array-of-bytes/0")
4879 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-index-into-array-of-bytes/1")
4880 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-index-into-array-of-bytes/2")
4881 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-index-into-array-of-bytes/3")
4882 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-index-into-array-of-bytes/4")
4883 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-index-into-array-of-bytes/5")
4884 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-index-into-array-of-bytes/6")
4885 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-index-into-array-of-bytes/7")
4886 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-index-into-array-of-bytes/8")
4887 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-convert-index-into-array-of-bytes/9")
4888 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + ecx<<0x00000000 + 4) 0x00000000/r32" "F - test-convert-index-into-array-of-bytes/11")
4889 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-index-into-array-of-bytes/13")
4890 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-index-into-array-of-bytes/14")
4891 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-index-into-array-of-bytes/15")
4892 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-index-into-array-of-bytes/16")
4893 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-index-into-array-of-bytes/17")
4894 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-index-into-array-of-bytes/18")
4895 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-index-into-array-of-bytes/19")
4896 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-index-into-array-of-bytes/20")
4897
4898 89/<- %esp 5/r32/ebp
4899 5d/pop-to-ebp
4900 c3/return
4901
4902 test-convert-index-into-array-with-literal:
4903
4904 55/push-ebp
4905 89/<- %ebp 4/r32/esp
4906
4907 (clear-stream _test-input-stream)
4908 (clear-stream $_test-input-buffered-file->buffer)
4909 (clear-stream _test-output-stream)
4910 (clear-stream $_test-output-buffered-file->buffer)
4911
4912 (write _test-input-stream "fn foo {\n")
4913 (write _test-input-stream " var arr/eax: (addr array int) <- copy 0\n")
4914 (write _test-input-stream " var x/eax: (addr int) <- index arr, 2\n")
4915 (write _test-input-stream "}\n")
4916
4917 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4918 (flush _test-output-buffered-file)
4919 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4925
4926 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-index-into-array-with-literal/0")
4927 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-index-into-array-with-literal/1")
4928 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-index-into-array-with-literal/2")
4929 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-index-into-array-with-literal/3")
4930 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-index-into-array-with-literal/4")
4931 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-index-into-array-with-literal/5")
4932 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-index-into-array-with-literal/6")
4933 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-index-into-array-with-literal/7")
4934
4935 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + 0x0000000c) 0x00000000/r32" "F - test-convert-index-into-array-with-literal/8")
4936 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-index-into-array-with-literal/9")
4937 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-index-into-array-with-literal/10")
4938 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-index-into-array-with-literal/11")
4939 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-index-into-array-with-literal/12")
4940 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-index-into-array-with-literal/13")
4941 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-index-into-array-with-literal/14")
4942 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-index-into-array-with-literal/15")
4943
4944 89/<- %esp 5/r32/ebp
4945 5d/pop-to-ebp
4946 c3/return
4947
4948 test-convert-index-into-array-of-bytes-with-literal:
4949
4950 55/push-ebp
4951 89/<- %ebp 4/r32/esp
4952
4953 (clear-stream _test-input-stream)
4954 (clear-stream $_test-input-buffered-file->buffer)
4955 (clear-stream _test-output-stream)
4956 (clear-stream $_test-output-buffered-file->buffer)
4957
4958 (write _test-input-stream "fn foo {\n")
4959 (write _test-input-stream " var arr/eax: (addr array byte) <- copy 0\n")
4960 (write _test-input-stream " var x/eax: (addr byte) <- index arr, 2\n")
4961 (write _test-input-stream "}\n")
4962
4963 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
4964 (flush _test-output-buffered-file)
4965 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
4971
4972 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-index-into-array-of-bytes-with-literal/0")
4973 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-index-into-array-of-bytes-with-literal/1")
4974 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-index-into-array-of-bytes-with-literal/2")
4975 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-index-into-array-of-bytes-with-literal/3")
4976 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-index-into-array-of-bytes-with-literal/4")
4977 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-index-into-array-of-bytes-with-literal/5")
4978 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-index-into-array-of-bytes-with-literal/6")
4979 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-index-into-array-of-bytes-with-literal/7")
4980
4981 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + 0x00000006) 0x00000000/r32" "F - test-convert-index-into-array-of-bytes-with-literal/8")
4982 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-index-into-array-of-bytes-with-literal/9")
4983 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-index-into-array-of-bytes-with-literal/10")
4984 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-index-into-array-of-bytes-with-literal/11")
4985 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-index-into-array-of-bytes-with-literal/12")
4986 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-index-into-array-of-bytes-with-literal/13")
4987 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-index-into-array-of-bytes-with-literal/14")
4988 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-index-into-array-of-bytes-with-literal/15")
4989
4990 89/<- %esp 5/r32/ebp
4991 5d/pop-to-ebp
4992 c3/return
4993
4994 test-convert-index-into-array-on-stack:
4995
4996 55/push-ebp
4997 89/<- %ebp 4/r32/esp
4998
4999 (clear-stream _test-input-stream)
5000 (clear-stream $_test-input-buffered-file->buffer)
5001 (clear-stream _test-output-stream)
5002 (clear-stream $_test-output-buffered-file->buffer)
5003
5004 (write _test-input-stream "fn foo {\n")
5005 (write _test-input-stream " var arr: (array int 3)\n")
5006 (write _test-input-stream " var idx/eax: int <- copy 2\n")
5007 (write _test-input-stream " var x/eax: (addr int) <- index arr, idx\n")
5008 (write _test-input-stream "}\n")
5009
5010 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5011 (flush _test-output-buffered-file)
5012 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5018
5019 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-index-into-array-on-stack/0")
5020 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-index-into-array-on-stack/1")
5021 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-index-into-array-on-stack/2")
5022 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-index-into-array-on-stack/3")
5023 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-index-into-array-on-stack/4")
5024 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-index-into-array-on-stack/5")
5025
5026 (check-next-stream-line-equal _test-output-stream " (push-n-zero-bytes 0x0000000c)" "F - test-convert-index-into-array-on-stack/6")
5027 (check-next-stream-line-equal _test-output-stream " 68/push 0x0000000c/imm32" "F - test-convert-index-into-array-on-stack/7")
5028
5029 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-index-into-array-on-stack/8")
5030 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 2/imm32" "F - test-convert-index-into-array-on-stack/9")
5031
5032 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(ebp + eax<<0x00000002 + 0xfffffff4) 0x00000000/r32" "F - test-convert-index-into-array-on-stack/10")
5033
5034 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-index-into-array-on-stack/11")
5035
5036 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000010/imm32" "F - test-convert-index-into-array-on-stack/12")
5037
5038 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-index-into-array-on-stack/13")
5039 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-index-into-array-on-stack/14")
5040 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-index-into-array-on-stack/15")
5041 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-index-into-array-on-stack/16")
5042 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-index-into-array-on-stack/17")
5043 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-index-into-array-on-stack/18")
5044
5045 89/<- %esp 5/r32/ebp
5046 5d/pop-to-ebp
5047 c3/return
5048
5049 test-convert-index-into-array-on-stack-with-literal:
5050
5051 55/push-ebp
5052 89/<- %ebp 4/r32/esp
5053
5054 (clear-stream _test-input-stream)
5055 (clear-stream $_test-input-buffered-file->buffer)
5056 (clear-stream _test-output-stream)
5057 (clear-stream $_test-output-buffered-file->buffer)
5058
5059 (write _test-input-stream "fn foo {\n")
5060 (write _test-input-stream " var arr: (array int 3)\n")
5061 (write _test-input-stream " var x/eax: (addr int) <- index arr, 2\n")
5062 (write _test-input-stream "}\n")
5063
5064 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5065 (flush _test-output-buffered-file)
5066 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5072
5073 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-index-into-array-on-stack-with-literal/0")
5074 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-index-into-array-on-stack-with-literal/1")
5075 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-index-into-array-on-stack-with-literal/2")
5076 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-index-into-array-on-stack-with-literal/3")
5077 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-index-into-array-on-stack-with-literal/4")
5078 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-index-into-array-on-stack-with-literal/5")
5079
5080 (check-next-stream-line-equal _test-output-stream " (push-n-zero-bytes 0x0000000c)" "F - test-convert-index-into-array-on-stack-with-literal/6")
5081 (check-next-stream-line-equal _test-output-stream " 68/push 0x0000000c/imm32" "F - test-convert-index-into-array-on-stack-with-literal/7")
5082
5083 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-index-into-array-on-stack-with-literal/8")
5084
5085 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(ebp + 0xfffffffc) 0x00000000/r32" "F - test-convert-index-into-array-on-stack-with-literal/9")
5086
5087 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-index-into-array-on-stack-with-literal/10")
5088
5089 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000010/imm32" "F - test-convert-index-into-array-on-stack-with-literal/11")
5090
5091 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-index-into-array-on-stack-with-literal/12")
5092 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-index-into-array-on-stack-with-literal/13")
5093 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-index-into-array-on-stack-with-literal/14")
5094 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-index-into-array-on-stack-with-literal/15")
5095 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-index-into-array-on-stack-with-literal/16")
5096 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-index-into-array-on-stack-with-literal/17")
5097
5098 89/<- %esp 5/r32/ebp
5099 5d/pop-to-ebp
5100 c3/return
5101
5102 test-convert-index-into-array-of-bytes-on-stack-with-literal:
5103
5104 55/push-ebp
5105 89/<- %ebp 4/r32/esp
5106
5107 (clear-stream _test-input-stream)
5108 (clear-stream $_test-input-buffered-file->buffer)
5109 (clear-stream _test-output-stream)
5110 (clear-stream $_test-output-buffered-file->buffer)
5111
5112 (write _test-input-stream "fn foo {\n")
5113 (write _test-input-stream " var arr: (array byte 3)\n")
5114 (write _test-input-stream " var x/eax: (addr byte) <- index arr, 2\n")
5115 (write _test-input-stream "}\n")
5116
5117 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5118 (flush _test-output-buffered-file)
5119 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5125
5126 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/0")
5127 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/1")
5128 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/2")
5129 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/3")
5130 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/4")
5131 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/5")
5132
5133 (check-next-stream-line-equal _test-output-stream " (push-n-zero-bytes 0x00000003)" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/6")
5134 (check-next-stream-line-equal _test-output-stream " 68/push 0x00000003/imm32" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/7")
5135
5136 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/8")
5137
5138 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(ebp + 0xffffffff) 0x00000000/r32" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/9")
5139
5140 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/10")
5141
5142 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000007/imm32" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/11")
5143
5144 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/12")
5145 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/13")
5146 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/14")
5147 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/15")
5148 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/16")
5149 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-index-into-array-of-bytes-on-stack-with-literal/17")
5150
5151 89/<- %esp 5/r32/ebp
5152 5d/pop-to-ebp
5153 c3/return
5154
5155 test-convert-index-into-array-using-offset:
5156
5157 55/push-ebp
5158 89/<- %ebp 4/r32/esp
5159
5160 (clear-stream _test-input-stream)
5161 (clear-stream $_test-input-buffered-file->buffer)
5162 (clear-stream _test-output-stream)
5163 (clear-stream $_test-output-buffered-file->buffer)
5164
5165 (write _test-input-stream "fn foo {\n")
5166 (write _test-input-stream " var arr/eax: (addr array int) <- copy 0\n")
5167 (write _test-input-stream " var idx/ecx: int <- copy 3\n")
5168 (write _test-input-stream " var off/ecx: (offset int) <- compute-offset arr, idx\n")
5169 (write _test-input-stream " var x/eax: (addr int) <- index arr, off\n")
5170 (write _test-input-stream "}\n")
5171
5172 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5173 (flush _test-output-buffered-file)
5174 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5180
5181 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-index-into-array-using-offset/0")
5182 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-index-into-array-using-offset/1")
5183 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-index-into-array-using-offset/2")
5184 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-index-into-array-using-offset/3")
5185 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-index-into-array-using-offset/4")
5186 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-index-into-array-using-offset/5")
5187 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-index-into-array-using-offset/6")
5188 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-index-into-array-using-offset/7")
5189 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-index-into-array-using-offset/8")
5190 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-convert-index-into-array-using-offset/9")
5191 (check-next-stream-line-equal _test-output-stream " 69/multiply %ecx 0x00000004/imm32 0x00000001/r32" "F - test-convert-index-into-array-using-offset/10")
5192 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + ecx + 4) 0x00000000/r32" "F - test-convert-index-into-array-using-offset/11")
5193 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-index-into-array-using-offset/12")
5194 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-index-into-array-using-offset/13")
5195 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-index-into-array-using-offset/14")
5196 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-index-into-array-using-offset/15")
5197 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-index-into-array-using-offset/16")
5198 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-index-into-array-using-offset/17")
5199 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-index-into-array-using-offset/18")
5200 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-index-into-array-using-offset/19")
5201
5202 89/<- %esp 5/r32/ebp
5203 5d/pop-to-ebp
5204 c3/return
5205
5206 test-convert-index-into-array-of-bytes-using-offset:
5207
5208 55/push-ebp
5209 89/<- %ebp 4/r32/esp
5210
5211 (clear-stream _test-input-stream)
5212 (clear-stream $_test-input-buffered-file->buffer)
5213 (clear-stream _test-output-stream)
5214 (clear-stream $_test-output-buffered-file->buffer)
5215
5216 (write _test-input-stream "fn foo {\n")
5217 (write _test-input-stream " var arr/eax: (addr array byte) <- copy 0\n")
5218 (write _test-input-stream " var idx/ecx: int <- copy 3\n")
5219 (write _test-input-stream " var off/ecx: (offset byte) <- compute-offset arr, idx\n")
5220 (write _test-input-stream " var x/eax: (addr byte) <- index arr, off\n")
5221 (write _test-input-stream "}\n")
5222
5223 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5224 (flush _test-output-buffered-file)
5225 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5231
5232 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-index-into-array-of-bytes-using-offset/0")
5233 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-index-into-array-of-bytes-using-offset/1")
5234 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-index-into-array-of-bytes-using-offset/2")
5235 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-index-into-array-of-bytes-using-offset/3")
5236 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-index-into-array-of-bytes-using-offset/4")
5237 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-index-into-array-of-bytes-using-offset/5")
5238 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-index-into-array-of-bytes-using-offset/6")
5239 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-index-into-array-of-bytes-using-offset/7")
5240 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-index-into-array-of-bytes-using-offset/8")
5241 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-convert-index-into-array-of-bytes-using-offset/9")
5242 (check-next-stream-line-equal _test-output-stream " 69/multiply %ecx 0x00000001/imm32 0x00000001/r32" "F - test-convert-index-into-array-of-bytes-using-offset/10")
5243 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + ecx + 4) 0x00000000/r32" "F - test-convert-index-into-array-of-bytes-using-offset/11")
5244 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-index-into-array-of-bytes-using-offset/12")
5245 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-index-into-array-of-bytes-using-offset/13")
5246 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-index-into-array-of-bytes-using-offset/14")
5247 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-index-into-array-of-bytes-using-offset/15")
5248 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-index-into-array-of-bytes-using-offset/16")
5249 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-index-into-array-of-bytes-using-offset/17")
5250 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-index-into-array-of-bytes-using-offset/18")
5251 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-index-into-array-of-bytes-using-offset/19")
5252
5253 89/<- %esp 5/r32/ebp
5254 5d/pop-to-ebp
5255 c3/return
5256
5257 test-convert-index-into-array-using-offset-on-stack:
5258
5259 55/push-ebp
5260 89/<- %ebp 4/r32/esp
5261
5262 (clear-stream _test-input-stream)
5263 (clear-stream $_test-input-buffered-file->buffer)
5264 (clear-stream _test-output-stream)
5265 (clear-stream $_test-output-buffered-file->buffer)
5266
5267 (write _test-input-stream "fn foo {\n")
5268 (write _test-input-stream " var arr/eax: (addr array int) <- copy 0\n")
5269 (write _test-input-stream " var idx: int\n")
5270 (write _test-input-stream " var off/ecx: (offset int) <- compute-offset arr, idx\n")
5271 (write _test-input-stream " var x/eax: (addr int) <- index arr, off\n")
5272 (write _test-input-stream "}\n")
5273
5274 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5275 (flush _test-output-buffered-file)
5276 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5282
5283 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-index-into-array-using-offset-on-stack/0")
5284 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-index-into-array-using-offset-on-stack/1")
5285 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-index-into-array-using-offset-on-stack/2")
5286 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-index-into-array-using-offset-on-stack/3")
5287 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-index-into-array-using-offset-on-stack/4")
5288 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-index-into-array-using-offset-on-stack/5")
5289 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-index-into-array-using-offset-on-stack/6")
5290 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-index-into-array-using-offset-on-stack/7")
5291 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-index-into-array-using-offset-on-stack/8")
5292 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-index-into-array-using-offset-on-stack/9")
5293 (check-next-stream-line-equal _test-output-stream " 69/multiply *(ebp+0xfffffff8) 0x00000004/imm32 0x00000001/r32" "F - test-convert-index-into-array-using-offset-on-stack/10")
5294 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + ecx + 4) 0x00000000/r32" "F - test-convert-index-into-array-using-offset-on-stack/11")
5295 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-index-into-array-using-offset-on-stack/12")
5296 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-index-into-array-using-offset-on-stack/13")
5297 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-index-into-array-using-offset-on-stack/14")
5298 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-index-into-array-using-offset-on-stack/15")
5299 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-index-into-array-using-offset-on-stack/16")
5300 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-index-into-array-using-offset-on-stack/17")
5301 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-index-into-array-using-offset-on-stack/18")
5302 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-index-into-array-using-offset-on-stack/19")
5303 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-index-into-array-using-offset-on-stack/20")
5304
5305 89/<- %esp 5/r32/ebp
5306 5d/pop-to-ebp
5307 c3/return
5308
5309 test-convert-index-into-array-of-bytes-using-offset-on-stack:
5310
5311 55/push-ebp
5312 89/<- %ebp 4/r32/esp
5313
5314 (clear-stream _test-input-stream)
5315 (clear-stream $_test-input-buffered-file->buffer)
5316 (clear-stream _test-output-stream)
5317 (clear-stream $_test-output-buffered-file->buffer)
5318
5319 (write _test-input-stream "fn foo {\n")
5320 (write _test-input-stream " var arr/eax: (addr array byte) <- copy 0\n")
5321 (write _test-input-stream " var idx: int\n")
5322 (write _test-input-stream " var off/ecx: (offset byte) <- compute-offset arr, idx\n")
5323 (write _test-input-stream " var x/eax: (addr byte) <- index arr, off\n")
5324 (write _test-input-stream "}\n")
5325
5326 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5327 (flush _test-output-buffered-file)
5328 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5334
5335 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/0")
5336 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/1")
5337 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/2")
5338 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/3")
5339 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/4")
5340 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/5")
5341 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/6")
5342 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/7")
5343 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/8")
5344 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/9")
5345 (check-next-stream-line-equal _test-output-stream " 69/multiply *(ebp+0xfffffff8) 0x00000001/imm32 0x00000001/r32" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/10")
5346 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + ecx + 4) 0x00000000/r32" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/11")
5347 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/12")
5348 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/13")
5349 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/14")
5350 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/15")
5351 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/16")
5352 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/17")
5353 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/18")
5354 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/19")
5355 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-index-into-array-of-bytes-using-offset-on-stack/20")
5356
5357 89/<- %esp 5/r32/ebp
5358 5d/pop-to-ebp
5359 c3/return
5360
5361 test-convert-function-and-type-definition:
5362
5363 55/push-ebp
5364 89/<- %ebp 4/r32/esp
5365
5366 (clear-stream _test-input-stream)
5367 (clear-stream $_test-input-buffered-file->buffer)
5368 (clear-stream _test-output-stream)
5369 (clear-stream $_test-output-buffered-file->buffer)
5370
5371 (write _test-input-stream "fn foo a: (addr t) {\n")
5372 (write _test-input-stream " var _a/eax: (addr t) <- copy a\n")
5373 (write _test-input-stream " var b/ecx: (addr int) <- get _a, x\n")
5374 (write _test-input-stream " var c/ecx: (addr int) <- get _a, y\n")
5375 (write _test-input-stream "}\n")
5376 (write _test-input-stream "type t {\n")
5377 (write _test-input-stream " x: int\n")
5378 (write _test-input-stream " y: int\n")
5379 (write _test-input-stream "}\n")
5380
5381 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5382 (flush _test-output-buffered-file)
5383 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5389
5390 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-and-type-definition/0")
5391 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-and-type-definition/1")
5392 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-and-type-definition/2")
5393 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-and-type-definition/3")
5394 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-and-type-definition/4")
5395 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-and-type-definition/5")
5396 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-function-and-type-definition/6")
5397 (check-next-stream-line-equal _test-output-stream " 8b/-> *(ebp+0x00000008) 0x00000000/r32" "F - test-convert-function-and-type-definition/7")
5398 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-function-and-type-definition/8")
5399 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + 0x00000000) 0x00000001/r32" "F - test-convert-function-and-type-definition/9")
5400 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + 0x00000004) 0x00000001/r32" "F - test-convert-function-and-type-definition/11")
5401 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-function-and-type-definition/13")
5402 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-function-and-type-definition/14")
5403 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-and-type-definition/15")
5404 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-and-type-definition/16")
5405 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-and-type-definition/17")
5406 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-and-type-definition/18")
5407 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-and-type-definition/19")
5408 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-and-type-definition/20")
5409
5410 89/<- %esp 5/r32/ebp
5411 5d/pop-to-ebp
5412 c3/return
5413
5414 test-type-definition-with-array:
5415
5416 55/push-ebp
5417 89/<- %ebp 4/r32/esp
5418
5419 (clear-stream _test-input-stream)
5420 (clear-stream $_test-input-buffered-file->buffer)
5421 (clear-stream _test-output-stream)
5422 (clear-stream $_test-output-buffered-file->buffer)
5423 (clear-stream _test-error-stream)
5424 (clear-stream $_test-error-buffered-file->buffer)
5425
5426 68/push 0/imm32
5427 68/push 0/imm32
5428 89/<- %edx 4/r32/esp
5429 (tailor-exit-descriptor %edx 0x10)
5430
5431 (write _test-input-stream "type t {\n")
5432 (write _test-input-stream " a: (array int 3)\n")
5433 (write _test-input-stream "}\n")
5434
5435 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
5436
5437
5438 89/<- %edx 4/r32/esp
5439 (flush _test-output-buffered-file)
5440 (flush _test-error-buffered-file)
5441 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
5447
5448 (check-stream-equal _test-output-stream "" "F - test-type-definition-with-array: output should be empty")
5449 (check-next-stream-line-equal _test-error-stream "type t: 'array' elements not allowed for now" "F - test-type-definition-with-array: error message")
5450
5451 (check-ints-equal *(edx+4) 2 "F - test-type-definition-with-array: exit status")
5452
5453 81 0/subop/add %esp 8/imm32
5454
5455 5d/pop-to-ebp
5456 c3/return
5457
5458 test-type-definition-with-addr:
5459
5460 55/push-ebp
5461 89/<- %ebp 4/r32/esp
5462
5463 (clear-stream _test-input-stream)
5464 (clear-stream $_test-input-buffered-file->buffer)
5465 (clear-stream _test-output-stream)
5466 (clear-stream $_test-output-buffered-file->buffer)
5467 (clear-stream _test-error-stream)
5468 (clear-stream $_test-error-buffered-file->buffer)
5469
5470 68/push 0/imm32
5471 68/push 0/imm32
5472 89/<- %edx 4/r32/esp
5473 (tailor-exit-descriptor %edx 0x10)
5474
5475 (write _test-input-stream "type t {\n")
5476 (write _test-input-stream " a: (addr int)\n")
5477 (write _test-input-stream "}\n")
5478
5479 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
5480
5481
5482 89/<- %edx 4/r32/esp
5483 (flush _test-output-buffered-file)
5484 (flush _test-error-buffered-file)
5485 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
5491
5492 (check-stream-equal _test-output-stream "" "F - test-type-definition-with-addr: output should be empty")
5493 (check-next-stream-line-equal _test-error-stream "type t: 'addr' elements not allowed" "F - test-type-definition-with-addr: error message")
5494
5495 (check-ints-equal *(edx+4) 2 "F - test-type-definition-with-addr: exit status")
5496
5497 81 0/subop/add %esp 8/imm32
5498
5499 5d/pop-to-ebp
5500 c3/return
5501
5502 test-convert-function-with-local-var-with-user-defined-type:
5503
5504 55/push-ebp
5505 89/<- %ebp 4/r32/esp
5506
5507 (clear-stream _test-input-stream)
5508 (clear-stream $_test-input-buffered-file->buffer)
5509 (clear-stream _test-output-stream)
5510 (clear-stream $_test-output-buffered-file->buffer)
5511
5512 (write _test-input-stream "fn foo {\n")
5513 (write _test-input-stream " var a: t\n")
5514 (write _test-input-stream "}\n")
5515 (write _test-input-stream "type t {\n")
5516 (write _test-input-stream " x: int\n")
5517 (write _test-input-stream " y: int\n")
5518 (write _test-input-stream "}\n")
5519
5520 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5521 (flush _test-output-buffered-file)
5522 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5528
5529 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-local-var-with-user-defined-type/0")
5530 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-local-var-with-user-defined-type/1")
5531 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-local-var-with-user-defined-type/2")
5532 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-local-var-with-user-defined-type/3")
5533 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-with-user-defined-type/4")
5534 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-local-var-with-user-defined-type/5")
5535 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-local-var-with-user-defined-type/6")
5536 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-local-var-with-user-defined-type/7")
5537 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000008/imm32" "F - test-convert-function-with-local-var-with-user-defined-type/8")
5538 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-with-user-defined-type/9")
5539 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-local-var-with-user-defined-type/10")
5540 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-local-var-with-user-defined-type/11")
5541 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-local-var-with-user-defined-type/12")
5542 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-local-var-with-user-defined-type/13")
5543 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-local-var-with-user-defined-type/14")
5544
5545 89/<- %esp 5/r32/ebp
5546 5d/pop-to-ebp
5547 c3/return
5548
5549 test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type:
5550
5551 55/push-ebp
5552 89/<- %ebp 4/r32/esp
5553
5554 (clear-stream _test-input-stream)
5555 (clear-stream $_test-input-buffered-file->buffer)
5556 (clear-stream _test-output-stream)
5557 (clear-stream $_test-output-buffered-file->buffer)
5558
5559 (write _test-input-stream "fn foo {\n")
5560 (write _test-input-stream " var a: t\n")
5561 (write _test-input-stream "}\n")
5562 (write _test-input-stream "type t {\n")
5563 (write _test-input-stream " x: s\n")
5564 (write _test-input-stream "}\n")
5565 (write _test-input-stream "type s {\n")
5566 (write _test-input-stream " z: int\n")
5567 (write _test-input-stream "}\n")
5568
5569 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5570 (flush _test-output-buffered-file)
5571 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5577
5578 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/0")
5579 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/1")
5580 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/2")
5581 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/3")
5582 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/4")
5583 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/5")
5584 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/7")
5585 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000004/imm32" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/8")
5586 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/9")
5587 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/10")
5588 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/11")
5589 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/12")
5590 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/13")
5591 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-with-local-var-with-user-defined-type-containing-user-defined-type/14")
5592
5593 89/<- %esp 5/r32/ebp
5594 5d/pop-to-ebp
5595 c3/return
5596
5597 test-convert-function-call-with-arg-of-user-defined-type:
5598
5599 55/push-ebp
5600 89/<- %ebp 4/r32/esp
5601
5602 (clear-stream _test-input-stream)
5603 (clear-stream $_test-input-buffered-file->buffer)
5604 (clear-stream _test-output-stream)
5605 (clear-stream $_test-output-buffered-file->buffer)
5606
5607 (write _test-input-stream "fn f {\n")
5608 (write _test-input-stream " var a: t\n")
5609 (write _test-input-stream " foo a\n")
5610 (write _test-input-stream "}\n")
5611 (write _test-input-stream "fn foo x: t {\n")
5612 (write _test-input-stream "}\n")
5613 (write _test-input-stream "type t {\n")
5614 (write _test-input-stream " x: int\n")
5615 (write _test-input-stream " y: int\n")
5616 (write _test-input-stream "}\n")
5617
5618 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5619 (flush _test-output-buffered-file)
5620 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5626
5627 (check-next-stream-line-equal _test-output-stream "f:" "F - test-convert-function-call-with-arg-of-user-defined-type/0")
5628 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call-with-arg-of-user-defined-type/1")
5629 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/2")
5630 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call-with-arg-of-user-defined-type/3")
5631 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-call-with-arg-of-user-defined-type/4")
5632 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:loop:" "F - test-convert-function-call-with-arg-of-user-defined-type/5")
5633
5634 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-call-with-arg-of-user-defined-type/6")
5635 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-call-with-arg-of-user-defined-type/7")
5636
5637 (check-next-stream-line-equal _test-output-stream " (foo *(ebp+0xfffffff8) *(ebp+0xfffffffc))" "F - test-convert-function-call-with-arg-of-user-defined-type/8")
5638
5639 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000008/imm32" "F - test-convert-function-call-with-arg-of-user-defined-type/9")
5640 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-call-with-arg-of-user-defined-type/10")
5641 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:break:" "F - test-convert-function-call-with-arg-of-user-defined-type/11")
5642 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call-with-arg-of-user-defined-type/12")
5643 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/13")
5644 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/14")
5645 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call-with-arg-of-user-defined-type/15")
5646 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-call-with-arg-of-user-defined-type/16")
5647 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call-with-arg-of-user-defined-type/17")
5648 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/18")
5649 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call-with-arg-of-user-defined-type/19")
5650 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call-with-arg-of-user-defined-type/20")
5651 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/21")
5652 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/22")
5653 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call-with-arg-of-user-defined-type/23")
5654
5655 89/<- %esp 5/r32/ebp
5656 5d/pop-to-ebp
5657 c3/return
5658
5659 test-convert-function-call-with-arg-of-user-defined-type-register-indirect:
5660
5661 55/push-ebp
5662 89/<- %ebp 4/r32/esp
5663
5664 (clear-stream _test-input-stream)
5665 (clear-stream $_test-input-buffered-file->buffer)
5666 (clear-stream _test-output-stream)
5667 (clear-stream $_test-output-buffered-file->buffer)
5668
5669 (write _test-input-stream "fn f {\n")
5670 (write _test-input-stream " var a/eax: (addr t) <- copy 0\n")
5671 (write _test-input-stream " foo *a\n")
5672 (write _test-input-stream "}\n")
5673 (write _test-input-stream "fn foo x: t {\n")
5674 (write _test-input-stream "}\n")
5675 (write _test-input-stream "type t {\n")
5676 (write _test-input-stream " x: int\n")
5677 (write _test-input-stream " y: int\n")
5678 (write _test-input-stream "}\n")
5679
5680 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5681 (flush _test-output-buffered-file)
5682 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5688
5689 (check-next-stream-line-equal _test-output-stream "f:" "F - test-convert-function-call-with-arg-of-user-defined-type/0")
5690 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call-with-arg-of-user-defined-type/1")
5691 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/2")
5692 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call-with-arg-of-user-defined-type/3")
5693 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-call-with-arg-of-user-defined-type/4")
5694 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:loop:" "F - test-convert-function-call-with-arg-of-user-defined-type/5")
5695
5696 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-function-call-with-arg-of-user-defined-type/6")
5697 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-function-call-with-arg-of-user-defined-type/7")
5698
5699 (check-next-stream-line-equal _test-output-stream " (foo *(eax+0x00000000) *(eax+0x00000004))" "F - test-convert-function-call-with-arg-of-user-defined-type/8")
5700
5701 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-function-call-with-arg-of-user-defined-type/9")
5702 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-call-with-arg-of-user-defined-type/10")
5703 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:break:" "F - test-convert-function-call-with-arg-of-user-defined-type/11")
5704 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call-with-arg-of-user-defined-type/12")
5705 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/13")
5706 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/14")
5707 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call-with-arg-of-user-defined-type/15")
5708 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-call-with-arg-of-user-defined-type/16")
5709 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call-with-arg-of-user-defined-type/17")
5710 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/18")
5711 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call-with-arg-of-user-defined-type/19")
5712 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call-with-arg-of-user-defined-type/20")
5713 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/21")
5714 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type/22")
5715 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call-with-arg-of-user-defined-type/23")
5716
5717 89/<- %esp 5/r32/ebp
5718 5d/pop-to-ebp
5719 c3/return
5720
5721
5722
5723 test-convert-function-call-with-arg-of-user-defined-type-by-reference:
5724
5725 55/push-ebp
5726 89/<- %ebp 4/r32/esp
5727
5728 (clear-stream _test-input-stream)
5729 (clear-stream $_test-input-buffered-file->buffer)
5730 (clear-stream _test-output-stream)
5731 (clear-stream $_test-output-buffered-file->buffer)
5732
5733 (write _test-input-stream "fn f {\n")
5734 (write _test-input-stream " var a: t\n")
5735 (write _test-input-stream " var b/eax: (addr t) <- address a\n")
5736 (write _test-input-stream " foo b\n")
5737 (write _test-input-stream "}\n")
5738 (write _test-input-stream "fn foo x: (addr t) {\n")
5739 (write _test-input-stream " var x/ecx: (addr int) <- copy x\n")
5740 (write _test-input-stream " increment *x\n")
5741 (write _test-input-stream "}\n")
5742 (write _test-input-stream "type t {\n")
5743 (write _test-input-stream " x: int\n")
5744 (write _test-input-stream " y: int\n")
5745 (write _test-input-stream "}\n")
5746
5747 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5748 (flush _test-output-buffered-file)
5749 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5755
5756 (check-next-stream-line-equal _test-output-stream "f:" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/0")
5757 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/1")
5758 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/2")
5759 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/3")
5760 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/4")
5761 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:loop:" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/5")
5762
5763 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/6")
5764 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/7")
5765
5766 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/8")
5767 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(ebp+0xfffffff8) 0x00000000/r32" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/9")
5768
5769 (check-next-stream-line-equal _test-output-stream " (foo %eax)" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/10")
5770
5771 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/11")
5772 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000008/imm32" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/12")
5773 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/13")
5774 (check-next-stream-line-equal _test-output-stream "$f:0x00000001:break:" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/14")
5775 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/15")
5776 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/16")
5777 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/17")
5778 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/18")
5779 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/19")
5780 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/20")
5781 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/21")
5782 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/22")
5783 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/23")
5784 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:loop:" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/24")
5785 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/25")
5786 (check-next-stream-line-equal _test-output-stream " 8b/-> *(ebp+0x00000008) 0x00000001/r32" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/26")
5787 (check-next-stream-line-equal _test-output-stream " ff 0/subop/increment *ecx" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/27")
5788 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/28")
5789 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/29")
5790 (check-next-stream-line-equal _test-output-stream "$foo:0x00000002:break:" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/30")
5791 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/31")
5792 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/32")
5793 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/33")
5794 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-function-call-with-arg-of-user-defined-type-by-reference/34")
5795
5796 89/<- %esp 5/r32/ebp
5797 5d/pop-to-ebp
5798 c3/return
5799
5800 test-convert-get-on-local-variable:
5801
5802 55/push-ebp
5803 89/<- %ebp 4/r32/esp
5804
5805 (clear-stream _test-input-stream)
5806 (clear-stream $_test-input-buffered-file->buffer)
5807 (clear-stream _test-output-stream)
5808 (clear-stream $_test-output-buffered-file->buffer)
5809
5810 (write _test-input-stream "fn foo {\n")
5811 (write _test-input-stream " var a: t\n")
5812 (write _test-input-stream " var c/ecx: (addr int) <- get a, y\n")
5813 (write _test-input-stream "}\n")
5814 (write _test-input-stream "type t {\n")
5815 (write _test-input-stream " x: int\n")
5816 (write _test-input-stream " y: int\n")
5817 (write _test-input-stream "}\n")
5818
5819 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5820 (flush _test-output-buffered-file)
5821 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5827
5828 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-get-on-local-variable/0")
5829 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-get-on-local-variable/1")
5830 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-get-on-local-variable/2")
5831 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-get-on-local-variable/3")
5832 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-get-on-local-variable/4")
5833 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-get-on-local-variable/5")
5834
5835 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-get-on-local-variable/6")
5836 (check-next-stream-line-equal _test-output-stream " 68/push 0/imm32" "F - test-convert-get-on-local-variable/7")
5837
5838 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-get-on-local-variable/8")
5839
5840 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(ebp+0xfffffffc) 0x00000001/r32" "F - test-convert-get-on-local-variable/9")
5841
5842 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-get-on-local-variable/10")
5843
5844 (check-next-stream-line-equal _test-output-stream " 81 0/subop/add %esp 0x00000008/imm32" "F - test-convert-get-on-local-variable/11")
5845 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-get-on-local-variable/12")
5846 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-get-on-local-variable/13")
5847 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-get-on-local-variable/14")
5848 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-get-on-local-variable/15")
5849 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-get-on-local-variable/16")
5850 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-get-on-local-variable/17")
5851
5852 89/<- %esp 5/r32/ebp
5853 5d/pop-to-ebp
5854 c3/return
5855
5856 test-convert-get-on-function-argument:
5857
5858 55/push-ebp
5859 89/<- %ebp 4/r32/esp
5860
5861 (clear-stream _test-input-stream)
5862 (clear-stream $_test-input-buffered-file->buffer)
5863 (clear-stream _test-output-stream)
5864 (clear-stream $_test-output-buffered-file->buffer)
5865
5866 (write _test-input-stream "fn foo a: t {\n")
5867 (write _test-input-stream " var c/ecx: (addr int) <- get a, y\n")
5868 (write _test-input-stream "}\n")
5869 (write _test-input-stream "type t {\n")
5870 (write _test-input-stream " x: int\n")
5871 (write _test-input-stream " y: int\n")
5872 (write _test-input-stream "}\n")
5873
5874 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5875 (flush _test-output-buffered-file)
5876 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5882
5883 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-get-on-function-argument/0")
5884 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-get-on-function-argument/1")
5885 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-get-on-function-argument/2")
5886 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-get-on-function-argument/3")
5887 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-get-on-function-argument/4")
5888 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-get-on-function-argument/5")
5889
5890 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-get-on-function-argument/6")
5891
5892 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(ebp+0x0000000c) 0x00000001/r32" "F - test-convert-get-on-function-argument/7")
5893
5894 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-get-on-function-argument/8")
5895 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-get-on-function-argument/9")
5896 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-get-on-function-argument/10")
5897 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-get-on-function-argument/11")
5898 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-get-on-function-argument/12")
5899 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-get-on-function-argument/13")
5900 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-get-on-function-argument/14")
5901
5902 89/<- %esp 5/r32/ebp
5903 5d/pop-to-ebp
5904 c3/return
5905
5906 test-convert-get-on-function-argument-with-known-type:
5907
5908 55/push-ebp
5909 89/<- %ebp 4/r32/esp
5910
5911 (clear-stream _test-input-stream)
5912 (clear-stream $_test-input-buffered-file->buffer)
5913 (clear-stream _test-output-stream)
5914 (clear-stream $_test-output-buffered-file->buffer)
5915
5916 (write _test-input-stream "type t {\n")
5917 (write _test-input-stream " x: int\n")
5918 (write _test-input-stream " y: int\n")
5919 (write _test-input-stream "}\n")
5920 (write _test-input-stream "fn foo a: t {\n")
5921 (write _test-input-stream " var c/ecx: (addr int) <- get a, y\n")
5922 (write _test-input-stream "}\n")
5923
5924 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
5925 (flush _test-output-buffered-file)
5926 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
5932
5933 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-get-on-function-argument-with-known-type/0")
5934 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-get-on-function-argument-with-known-type/1")
5935 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-get-on-function-argument-with-known-type/2")
5936 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-get-on-function-argument-with-known-type/3")
5937 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-get-on-function-argument-with-known-type/4")
5938 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-get-on-function-argument-with-known-type/5")
5939
5940 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-get-on-function-argument-with-known-type/6")
5941
5942 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(ebp+0x0000000c) 0x00000001/r32" "F - test-convert-get-on-function-argument-with-known-type/7")
5943
5944 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-get-on-function-argument-with-known-type/8")
5945 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-get-on-function-argument-with-known-type/9")
5946 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-get-on-function-argument-with-known-type/10")
5947 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-get-on-function-argument-with-known-type/11")
5948 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-get-on-function-argument-with-known-type/12")
5949 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-get-on-function-argument-with-known-type/13")
5950 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-get-on-function-argument-with-known-type/14")
5951
5952 89/<- %esp 5/r32/ebp
5953 5d/pop-to-ebp
5954 c3/return
5955
5956 test-add-with-too-many-inouts:
5957
5958 55/push-ebp
5959 89/<- %ebp 4/r32/esp
5960
5961 (clear-stream _test-input-stream)
5962 (clear-stream $_test-input-buffered-file->buffer)
5963 (clear-stream _test-output-stream)
5964 (clear-stream $_test-output-buffered-file->buffer)
5965 (clear-stream _test-error-stream)
5966 (clear-stream $_test-error-buffered-file->buffer)
5967
5968 68/push 0/imm32
5969 68/push 0/imm32
5970 89/<- %edx 4/r32/esp
5971 (tailor-exit-descriptor %edx 0x10)
5972
5973 (write _test-input-stream "fn foo {\n")
5974 (write _test-input-stream " var a: int\n")
5975 (write _test-input-stream " var b/ecx: int <- add a, 0\n")
5976 (write _test-input-stream "}\n")
5977
5978 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
5979
5980
5981 89/<- %edx 4/r32/esp
5982 (flush _test-output-buffered-file)
5983 (flush _test-error-buffered-file)
5984 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
5990
5991 (check-stream-equal _test-output-stream "" "F - test-add-with-too-many-inouts: output should be empty")
5992 (check-next-stream-line-equal _test-error-stream "fn foo: stmt add: too many inouts; most primitives support at most two arguments, across inouts and outputs" "F - test-add-with-too-many-inouts: error message")
5993
5994 (check-ints-equal *(edx+4) 2 "F - test-add-with-too-many-inouts: exit status")
5995
5996 81 0/subop/add %esp 8/imm32
5997
5998 5d/pop-to-ebp
5999 c3/return
6000
6001 test-add-with-too-many-inouts-2:
6002
6003 55/push-ebp
6004 89/<- %ebp 4/r32/esp
6005
6006 (clear-stream _test-input-stream)
6007 (clear-stream $_test-input-buffered-file->buffer)
6008 (clear-stream _test-output-stream)
6009 (clear-stream $_test-output-buffered-file->buffer)
6010 (clear-stream _test-error-stream)
6011 (clear-stream $_test-error-buffered-file->buffer)
6012
6013 68/push 0/imm32
6014 68/push 0/imm32
6015 89/<- %edx 4/r32/esp
6016 (tailor-exit-descriptor %edx 0x10)
6017
6018 (write _test-input-stream "fn foo {\n")
6019 (write _test-input-stream " var a: int\n")
6020 (write _test-input-stream " add-to a, 0, 1\n")
6021 (write _test-input-stream "}\n")
6022
6023 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6024
6025
6026 89/<- %edx 4/r32/esp
6027 (flush _test-output-buffered-file)
6028 (flush _test-error-buffered-file)
6029 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6035
6036 (check-stream-equal _test-output-stream "" "F - test-add-with-too-many-inouts-2: output should be empty")
6037 (check-next-stream-line-equal _test-error-stream "fn foo: stmt add-to: too many inouts; most primitives support at most two arguments, across inouts and outputs" "F - test-add-with-too-many-inouts-2: error message")
6038
6039 (check-ints-equal *(edx+4) 2 "F - test-add-with-too-many-inouts-2: exit status")
6040
6041 81 0/subop/add %esp 8/imm32
6042
6043 5d/pop-to-ebp
6044 c3/return
6045
6046 test-add-with-too-many-outputs:
6047
6048 55/push-ebp
6049 89/<- %ebp 4/r32/esp
6050
6051 (clear-stream _test-input-stream)
6052 (clear-stream $_test-input-buffered-file->buffer)
6053 (clear-stream _test-output-stream)
6054 (clear-stream $_test-output-buffered-file->buffer)
6055 (clear-stream _test-error-stream)
6056 (clear-stream $_test-error-buffered-file->buffer)
6057
6058 68/push 0/imm32
6059 68/push 0/imm32
6060 89/<- %edx 4/r32/esp
6061 (tailor-exit-descriptor %edx 0x10)
6062
6063 (write _test-input-stream "fn foo {\n")
6064 (write _test-input-stream " var a/eax: int <- copy 0\n")
6065 (write _test-input-stream " var b/ebx: int <- copy 0\n")
6066 (write _test-input-stream " var c/ecx: int <- copy 0\n")
6067 (write _test-input-stream " c, b <- add a\n")
6068 (write _test-input-stream "}\n")
6069
6070 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6071
6072
6073 89/<- %edx 4/r32/esp
6074 (flush _test-output-buffered-file)
6075 (flush _test-error-buffered-file)
6076 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6082
6083 (check-stream-equal _test-output-stream "" "F - test-add-with-too-many-outputs: output should be empty")
6084 (check-next-stream-line-equal _test-error-stream "fn foo: stmt add: too many outputs; most primitives support at most one output" "F - test-add-with-too-many-outputs: error message")
6085
6086 (check-ints-equal *(edx+4) 2 "F - test-add-with-too-many-outputs: exit status")
6087
6088 81 0/subop/add %esp 8/imm32
6089
6090 5d/pop-to-ebp
6091 c3/return
6092
6093 test-add-with-non-number:
6094
6095 55/push-ebp
6096 89/<- %ebp 4/r32/esp
6097
6098 (clear-stream _test-input-stream)
6099 (clear-stream $_test-input-buffered-file->buffer)
6100 (clear-stream _test-output-stream)
6101 (clear-stream $_test-output-buffered-file->buffer)
6102 (clear-stream _test-error-stream)
6103 (clear-stream $_test-error-buffered-file->buffer)
6104
6105 68/push 0/imm32
6106 68/push 0/imm32
6107 89/<- %edx 4/r32/esp
6108 (tailor-exit-descriptor %edx 0x10)
6109
6110 (write _test-input-stream "fn foo {\n")
6111 (write _test-input-stream " var a: int\n")
6112 (write _test-input-stream " var b/ecx: (addr int) <- add a\n")
6113 (write _test-input-stream "}\n")
6114
6115 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6116
6117
6118 89/<- %edx 4/r32/esp
6119 (flush _test-output-buffered-file)
6120 (flush _test-error-buffered-file)
6121 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6127
6128 (check-stream-equal _test-output-stream "" "F - test-add-with-non-number: output should be empty")
6129 (check-next-stream-line-equal _test-error-stream "fn foo: stmt add: only non-addr scalar args permitted" "F - test-add-with-non-number: error message")
6130
6131 (check-ints-equal *(edx+4) 2 "F - test-add-with-non-number: exit status")
6132
6133 81 0/subop/add %esp 8/imm32
6134
6135 5d/pop-to-ebp
6136 c3/return
6137
6138 test-add-with-addr-dereferenced:
6139
6140 55/push-ebp
6141 89/<- %ebp 4/r32/esp
6142
6143 (clear-stream _test-input-stream)
6144 (clear-stream $_test-input-buffered-file->buffer)
6145 (clear-stream _test-output-stream)
6146 (clear-stream $_test-output-buffered-file->buffer)
6147
6148 (write _test-input-stream "fn foo {\n")
6149 (write _test-input-stream " var a/eax: (addr int) <- copy 0\n")
6150 (write _test-input-stream " add-to *a, 1\n")
6151 (write _test-input-stream "}\n")
6152
6153 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
6154 (flush _test-output-buffered-file)
6155
6156
6157 89/<- %esp 5/r32/ebp
6158 5d/pop-to-ebp
6159 c3/return
6160
6161 test-get-with-wrong-field:
6162
6163 55/push-ebp
6164 89/<- %ebp 4/r32/esp
6165
6166 (clear-stream _test-input-stream)
6167 (clear-stream $_test-input-buffered-file->buffer)
6168 (clear-stream _test-output-stream)
6169 (clear-stream $_test-output-buffered-file->buffer)
6170 (clear-stream _test-error-stream)
6171 (clear-stream $_test-error-buffered-file->buffer)
6172
6173 68/push 0/imm32
6174 68/push 0/imm32
6175 89/<- %edx 4/r32/esp
6176 (tailor-exit-descriptor %edx 0x10)
6177
6178 (write _test-input-stream "fn foo {\n")
6179 (write _test-input-stream " var a: t\n")
6180 (write _test-input-stream " var c/ecx: (addr int) <- get a, y\n")
6181 (write _test-input-stream "}\n")
6182 (write _test-input-stream "type t {\n")
6183 (write _test-input-stream " x: int\n")
6184 (write _test-input-stream "}\n")
6185
6186 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6187
6188
6189 89/<- %edx 4/r32/esp
6190 (flush _test-output-buffered-file)
6191 (flush _test-error-buffered-file)
6192 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6198
6199 (check-stream-equal _test-output-stream "" "F - test-get-with-wrong-field: output should be empty")
6200 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: type 't' has no member called 'y'" "F - test-get-with-wrong-field: error message")
6201
6202 (check-ints-equal *(edx+4) 2 "F - test-get-with-wrong-field: exit status")
6203
6204 81 0/subop/add %esp 8/imm32
6205
6206 5d/pop-to-ebp
6207 c3/return
6208
6209 test-get-with-wrong-base-type:
6210
6211 55/push-ebp
6212 89/<- %ebp 4/r32/esp
6213
6214 (clear-stream _test-input-stream)
6215 (clear-stream $_test-input-buffered-file->buffer)
6216 (clear-stream _test-output-stream)
6217 (clear-stream $_test-output-buffered-file->buffer)
6218 (clear-stream _test-error-stream)
6219 (clear-stream $_test-error-buffered-file->buffer)
6220
6221 68/push 0/imm32
6222 68/push 0/imm32
6223 89/<- %edx 4/r32/esp
6224 (tailor-exit-descriptor %edx 0x10)
6225
6226 (write _test-input-stream "fn foo {\n")
6227 (write _test-input-stream " var a: int\n")
6228 (write _test-input-stream " var c/ecx: (addr int) <- get a, y\n")
6229 (write _test-input-stream "}\n")
6230
6231 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6232
6233
6234 89/<- %edx 4/r32/esp
6235 (flush _test-output-buffered-file)
6236 (flush _test-error-buffered-file)
6237 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6243
6244 (check-stream-equal _test-output-stream "" "F - test-get-with-wrong-base-type: output should be empty")
6245 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: var 'a' must have a 'type' definition" "F - test-get-with-wrong-base-type: error message")
6246
6247 (check-ints-equal *(edx+4) 2 "F - test-get-with-wrong-base-type: exit status")
6248
6249 81 0/subop/add %esp 8/imm32
6250
6251 5d/pop-to-ebp
6252 c3/return
6253
6254 test-get-with-wrong-base-type-2:
6255
6256 55/push-ebp
6257 89/<- %ebp 4/r32/esp
6258
6259 (clear-stream _test-input-stream)
6260 (clear-stream $_test-input-buffered-file->buffer)
6261 (clear-stream _test-output-stream)
6262 (clear-stream $_test-output-buffered-file->buffer)
6263 (clear-stream _test-error-stream)
6264 (clear-stream $_test-error-buffered-file->buffer)
6265
6266 68/push 0/imm32
6267 68/push 0/imm32
6268 89/<- %edx 4/r32/esp
6269 (tailor-exit-descriptor %edx 0x10)
6270
6271 (write _test-input-stream "fn foo {\n")
6272 (write _test-input-stream " var a: (addr t)\n")
6273 (write _test-input-stream " var c/ecx: (addr int) <- get a, y\n")
6274 (write _test-input-stream "}\n")
6275 (write _test-input-stream "type t {\n")
6276 (write _test-input-stream " x: int\n")
6277 (write _test-input-stream "}\n")
6278
6279 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6280
6281
6282 89/<- %edx 4/r32/esp
6283 (flush _test-output-buffered-file)
6284 (flush _test-error-buffered-file)
6285 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6291
6292 (check-stream-equal _test-output-stream "" "F - test-get-with-wrong-base-type-2: output should be empty")
6293 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: var 'a' is an 'addr' type, and so must live in a register" "F - test-get-with-wrong-base-type-2: error message")
6294
6295 (check-ints-equal *(edx+4) 2 "F - test-get-with-wrong-base-type-2: exit status")
6296
6297 81 0/subop/add %esp 8/imm32
6298
6299 5d/pop-to-ebp
6300 c3/return
6301
6302 test-get-with-wrong-offset-type:
6303
6304 55/push-ebp
6305 89/<- %ebp 4/r32/esp
6306
6307 (clear-stream _test-input-stream)
6308 (clear-stream $_test-input-buffered-file->buffer)
6309 (clear-stream _test-output-stream)
6310 (clear-stream $_test-output-buffered-file->buffer)
6311 (clear-stream _test-error-stream)
6312 (clear-stream $_test-error-buffered-file->buffer)
6313
6314 68/push 0/imm32
6315 68/push 0/imm32
6316 89/<- %edx 4/r32/esp
6317 (tailor-exit-descriptor %edx 0x10)
6318
6319 (write _test-input-stream "fn foo {\n")
6320 (write _test-input-stream " var a: t\n")
6321 (write _test-input-stream " var b: int\n")
6322 (write _test-input-stream " var c/ecx: (addr int) <- get a, b\n")
6323 (write _test-input-stream "}\n")
6324 (write _test-input-stream "type t {\n")
6325 (write _test-input-stream " x: int\n")
6326 (write _test-input-stream "}\n")
6327
6328 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6329
6330
6331 89/<- %edx 4/r32/esp
6332 (flush _test-output-buffered-file)
6333 (flush _test-error-buffered-file)
6334 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6340
6341 (check-stream-equal _test-output-stream "" "F - test-get-with-wrong-offset-type: output should be empty")
6342 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: type 't' has no member called 'b'" "F - test-get-with-wrong-offset-type: error message")
6343
6344 (check-ints-equal *(edx+4) 2 "F - test-get-with-wrong-offset-type: exit status")
6345
6346 81 0/subop/add %esp 8/imm32
6347
6348 5d/pop-to-ebp
6349 c3/return
6350
6351 test-get-with-wrong-output-type:
6352
6353 55/push-ebp
6354 89/<- %ebp 4/r32/esp
6355
6356 (clear-stream _test-input-stream)
6357 (clear-stream $_test-input-buffered-file->buffer)
6358 (clear-stream _test-output-stream)
6359 (clear-stream $_test-output-buffered-file->buffer)
6360 (clear-stream _test-error-stream)
6361 (clear-stream $_test-error-buffered-file->buffer)
6362
6363 68/push 0/imm32
6364 68/push 0/imm32
6365 89/<- %edx 4/r32/esp
6366 (tailor-exit-descriptor %edx 0x10)
6367
6368 (write _test-input-stream "fn foo {\n")
6369 (write _test-input-stream " var a: t\n")
6370 (write _test-input-stream " var c: (addr int)\n")
6371 (write _test-input-stream " c <- get a, x\n")
6372 (write _test-input-stream "}\n")
6373 (write _test-input-stream "type t {\n")
6374 (write _test-input-stream " x: int\n")
6375 (write _test-input-stream "}\n")
6376
6377 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6378
6379
6380 89/<- %edx 4/r32/esp
6381 (flush _test-output-buffered-file)
6382 (flush _test-error-buffered-file)
6383 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6389
6390 (check-stream-equal _test-output-stream "" "F - test-get-with-wrong-output-type: output should be empty")
6391 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: output 'c' is not in a register" "F - test-get-with-wrong-output-type: error message")
6392
6393 (check-ints-equal *(edx+4) 2 "F - test-get-with-wrong-output-type: exit status")
6394
6395 81 0/subop/add %esp 8/imm32
6396
6397 5d/pop-to-ebp
6398 c3/return
6399
6400 test-get-with-wrong-output-type-2:
6401
6402 55/push-ebp
6403 89/<- %ebp 4/r32/esp
6404
6405 (clear-stream _test-input-stream)
6406 (clear-stream $_test-input-buffered-file->buffer)
6407 (clear-stream _test-output-stream)
6408 (clear-stream $_test-output-buffered-file->buffer)
6409 (clear-stream _test-error-stream)
6410 (clear-stream $_test-error-buffered-file->buffer)
6411
6412 68/push 0/imm32
6413 68/push 0/imm32
6414 89/<- %edx 4/r32/esp
6415 (tailor-exit-descriptor %edx 0x10)
6416
6417 (write _test-input-stream "fn foo {\n")
6418 (write _test-input-stream " var a: t\n")
6419 (write _test-input-stream " var c/ecx: int <- get a, x\n")
6420 (write _test-input-stream "}\n")
6421 (write _test-input-stream "type t {\n")
6422 (write _test-input-stream " x: int\n")
6423 (write _test-input-stream "}\n")
6424
6425 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6426
6427
6428 89/<- %edx 4/r32/esp
6429 (flush _test-output-buffered-file)
6430 (flush _test-error-buffered-file)
6431 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6437
6438 (check-stream-equal _test-output-stream "" "F - test-get-with-wrong-output-type-2: output should be empty")
6439 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: output must be an address" "F - test-get-with-wrong-output-type-2: error message")
6440
6441 (check-ints-equal *(edx+4) 2 "F - test-get-with-wrong-output-type-2: exit status")
6442
6443 81 0/subop/add %esp 8/imm32
6444
6445 5d/pop-to-ebp
6446 c3/return
6447
6448 test-get-with-wrong-output-type-3:
6449
6450 55/push-ebp
6451 89/<- %ebp 4/r32/esp
6452
6453 (clear-stream _test-input-stream)
6454 (clear-stream $_test-input-buffered-file->buffer)
6455 (clear-stream _test-output-stream)
6456 (clear-stream $_test-output-buffered-file->buffer)
6457 (clear-stream _test-error-stream)
6458 (clear-stream $_test-error-buffered-file->buffer)
6459
6460 68/push 0/imm32
6461 68/push 0/imm32
6462 89/<- %edx 4/r32/esp
6463 (tailor-exit-descriptor %edx 0x10)
6464
6465 (write _test-input-stream "fn foo {\n")
6466 (write _test-input-stream " var a: t\n")
6467 (write _test-input-stream " var c/ecx: (array int) <- get a, x\n")
6468 (write _test-input-stream "}\n")
6469 (write _test-input-stream "type t {\n")
6470 (write _test-input-stream " x: int\n")
6471 (write _test-input-stream "}\n")
6472
6473 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6474
6475
6476 89/<- %edx 4/r32/esp
6477 (flush _test-output-buffered-file)
6478 (flush _test-error-buffered-file)
6479 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6485
6486 (check-stream-equal _test-output-stream "" "F - test-get-with-wrong-output-type-3: output should be empty")
6487 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: output must be an address" "F - test-get-with-wrong-output-type-3: error message")
6488
6489 (check-ints-equal *(edx+4) 2 "F - test-get-with-wrong-output-type-3: exit status")
6490
6491 81 0/subop/add %esp 8/imm32
6492
6493 5d/pop-to-ebp
6494 c3/return
6495
6496 test-get-with-wrong-output-type-4:
6497
6498 55/push-ebp
6499 89/<- %ebp 4/r32/esp
6500
6501 (clear-stream _test-input-stream)
6502 (clear-stream $_test-input-buffered-file->buffer)
6503 (clear-stream _test-output-stream)
6504 (clear-stream $_test-output-buffered-file->buffer)
6505 (clear-stream _test-error-stream)
6506 (clear-stream $_test-error-buffered-file->buffer)
6507
6508 68/push 0/imm32
6509 68/push 0/imm32
6510 89/<- %edx 4/r32/esp
6511 (tailor-exit-descriptor %edx 0x10)
6512
6513 (write _test-input-stream "fn foo {\n")
6514 (write _test-input-stream " var a: t\n")
6515 (write _test-input-stream " var c/ecx: (addr boolean) <- get a, x\n")
6516 (write _test-input-stream "}\n")
6517 (write _test-input-stream "type t {\n")
6518 (write _test-input-stream " x: int\n")
6519 (write _test-input-stream "}\n")
6520
6521 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6522
6523
6524 89/<- %edx 4/r32/esp
6525 (flush _test-output-buffered-file)
6526 (flush _test-error-buffered-file)
6527 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6533
6534 (check-stream-equal _test-output-stream "" "F - test-get-with-wrong-output-type-4: output should be empty")
6535 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: wrong output type for member 'x' of type 't'" "F - test-get-with-wrong-output-type-4: error message")
6536
6537 (check-ints-equal *(edx+4) 2 "F - test-get-with-wrong-output-type-4: exit status")
6538
6539 81 0/subop/add %esp 8/imm32
6540
6541 5d/pop-to-ebp
6542 c3/return
6543
6544 test-get-with-wrong-output-type-5:
6545
6546 55/push-ebp
6547 89/<- %ebp 4/r32/esp
6548
6549 (clear-stream _test-input-stream)
6550 (clear-stream $_test-input-buffered-file->buffer)
6551 (clear-stream _test-output-stream)
6552 (clear-stream $_test-output-buffered-file->buffer)
6553
6554 (write _test-input-stream "fn foo {\n")
6555 (write _test-input-stream " var a: t\n")
6556 (write _test-input-stream " var c/ecx: (addr handle int) <- get a, x\n")
6557 (write _test-input-stream "}\n")
6558 (write _test-input-stream "type t {\n")
6559 (write _test-input-stream " x: (handle int)\n")
6560 (write _test-input-stream "}\n")
6561
6562 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
6563 (flush _test-output-buffered-file)
6564
6565
6566 89/<- %esp 5/r32/ebp
6567 5d/pop-to-ebp
6568 c3/return
6569
6570 test-get-with-too-few-inouts:
6571
6572 55/push-ebp
6573 89/<- %ebp 4/r32/esp
6574
6575 (clear-stream _test-input-stream)
6576 (clear-stream $_test-input-buffered-file->buffer)
6577 (clear-stream _test-output-stream)
6578 (clear-stream $_test-output-buffered-file->buffer)
6579 (clear-stream _test-error-stream)
6580 (clear-stream $_test-error-buffered-file->buffer)
6581
6582 68/push 0/imm32
6583 68/push 0/imm32
6584 89/<- %edx 4/r32/esp
6585 (tailor-exit-descriptor %edx 0x10)
6586
6587 (write _test-input-stream "fn foo {\n")
6588 (write _test-input-stream " var a: t\n")
6589 (write _test-input-stream " var c/ecx: (addr int) <- get a\n")
6590 (write _test-input-stream "}\n")
6591 (write _test-input-stream "type t {\n")
6592 (write _test-input-stream " x: int\n")
6593 (write _test-input-stream "}\n")
6594
6595 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6596
6597
6598 89/<- %edx 4/r32/esp
6599 (flush _test-output-buffered-file)
6600 (flush _test-error-buffered-file)
6601 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6607
6608 (check-stream-equal _test-output-stream "" "F - test-get-with-too-few-inouts: output should be empty")
6609 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: too few inouts (2 required)" "F - test-get-with-too-few-inouts: error message")
6610
6611 (check-ints-equal *(edx+4) 2 "F - test-get-with-too-few-inouts: exit status")
6612
6613 81 0/subop/add %esp 8/imm32
6614
6615 5d/pop-to-ebp
6616 c3/return
6617
6618 test-get-with-too-many-inouts:
6619
6620 55/push-ebp
6621 89/<- %ebp 4/r32/esp
6622
6623 (clear-stream _test-input-stream)
6624 (clear-stream $_test-input-buffered-file->buffer)
6625 (clear-stream _test-output-stream)
6626 (clear-stream $_test-output-buffered-file->buffer)
6627 (clear-stream _test-error-stream)
6628 (clear-stream $_test-error-buffered-file->buffer)
6629
6630 68/push 0/imm32
6631 68/push 0/imm32
6632 89/<- %edx 4/r32/esp
6633 (tailor-exit-descriptor %edx 0x10)
6634
6635 (write _test-input-stream "fn foo {\n")
6636 (write _test-input-stream " var a: t\n")
6637 (write _test-input-stream " var c/ecx: (addr int) <- get a, x, 0\n")
6638 (write _test-input-stream "}\n")
6639 (write _test-input-stream "type t {\n")
6640 (write _test-input-stream " x: int\n")
6641 (write _test-input-stream "}\n")
6642
6643 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6644
6645
6646 89/<- %edx 4/r32/esp
6647 (flush _test-output-buffered-file)
6648 (flush _test-error-buffered-file)
6649 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6655
6656 (check-stream-equal _test-output-stream "" "F - test-get-with-too-many-inouts: output should be empty")
6657 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: too many inouts (2 required)" "F - test-get-with-too-many-inouts: error message")
6658
6659 (check-ints-equal *(edx+4) 2 "F - test-get-with-too-many-inouts: exit status")
6660
6661 81 0/subop/add %esp 8/imm32
6662
6663 5d/pop-to-ebp
6664 c3/return
6665
6666 test-get-with-no-output:
6667
6668 55/push-ebp
6669 89/<- %ebp 4/r32/esp
6670
6671 (clear-stream _test-input-stream)
6672 (clear-stream $_test-input-buffered-file->buffer)
6673 (clear-stream _test-output-stream)
6674 (clear-stream $_test-output-buffered-file->buffer)
6675 (clear-stream _test-error-stream)
6676 (clear-stream $_test-error-buffered-file->buffer)
6677
6678 68/push 0/imm32
6679 68/push 0/imm32
6680 89/<- %edx 4/r32/esp
6681 (tailor-exit-descriptor %edx 0x10)
6682
6683 (write _test-input-stream "fn foo {\n")
6684 (write _test-input-stream " var a: t\n")
6685 (write _test-input-stream " get a, x\n")
6686 (write _test-input-stream "}\n")
6687 (write _test-input-stream "type t {\n")
6688 (write _test-input-stream " x: int\n")
6689 (write _test-input-stream "}\n")
6690
6691 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6692
6693
6694 89/<- %edx 4/r32/esp
6695 (flush _test-output-buffered-file)
6696 (flush _test-error-buffered-file)
6697 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6703
6704 (check-stream-equal _test-output-stream "" "F - test-get-with-no-output: output should be empty")
6705 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: must have an output" "F - test-get-with-no-output: error message")
6706
6707 (check-ints-equal *(edx+4) 2 "F - test-get-with-no-output: exit status")
6708
6709 81 0/subop/add %esp 8/imm32
6710
6711 5d/pop-to-ebp
6712 c3/return
6713
6714 test-get-with-too-many-outputs:
6715
6716 55/push-ebp
6717 89/<- %ebp 4/r32/esp
6718
6719 (clear-stream _test-input-stream)
6720 (clear-stream $_test-input-buffered-file->buffer)
6721 (clear-stream _test-output-stream)
6722 (clear-stream $_test-output-buffered-file->buffer)
6723 (clear-stream _test-error-stream)
6724 (clear-stream $_test-error-buffered-file->buffer)
6725
6726 68/push 0/imm32
6727 68/push 0/imm32
6728 89/<- %edx 4/r32/esp
6729 (tailor-exit-descriptor %edx 0x10)
6730
6731 (write _test-input-stream "fn foo {\n")
6732 (write _test-input-stream " var a: t\n")
6733 (write _test-input-stream " var b: int\n")
6734 (write _test-input-stream " var c/eax: (addr int) <- copy 0\n")
6735 (write _test-input-stream " c, b <- get a, x\n")
6736 (write _test-input-stream "}\n")
6737 (write _test-input-stream "type t {\n")
6738 (write _test-input-stream " x: int\n")
6739 (write _test-input-stream "}\n")
6740
6741 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
6742
6743
6744 89/<- %edx 4/r32/esp
6745 (flush _test-output-buffered-file)
6746 (flush _test-error-buffered-file)
6747 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
6753
6754 (check-stream-equal _test-output-stream "" "F - test-get-with-too-many-outputs: output should be empty")
6755 (check-next-stream-line-equal _test-error-stream "fn foo: stmt get: too many outputs (1 required)" "F - test-get-with-too-many-outputs: error message")
6756
6757 (check-ints-equal *(edx+4) 2 "F - test-get-with-too-many-outputs: exit status")
6758
6759 81 0/subop/add %esp 8/imm32
6760
6761 5d/pop-to-ebp
6762 c3/return
6763
6764 test-convert-array-of-user-defined-types:
6765
6766 55/push-ebp
6767 89/<- %ebp 4/r32/esp
6768
6769 (clear-stream _test-input-stream)
6770 (clear-stream $_test-input-buffered-file->buffer)
6771 (clear-stream _test-output-stream)
6772 (clear-stream $_test-output-buffered-file->buffer)
6773
6774 (write _test-input-stream "type t {\n")
6775 (write _test-input-stream " x: int\n")
6776 (write _test-input-stream " y: int\n")
6777 (write _test-input-stream "}\n")
6778 (write _test-input-stream "fn foo {\n")
6779 (write _test-input-stream " var arr/eax: (addr array t) <- copy 0\n")
6780 (write _test-input-stream " var idx/ecx: int <- copy 3\n")
6781 (write _test-input-stream " var x/eax: (addr t) <- index arr, idx\n")
6782 (write _test-input-stream "}\n")
6783
6784 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
6785 (flush _test-output-buffered-file)
6786 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
6792
6793 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-array-of-user-defined-types/0")
6794 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-array-of-user-defined-types/1")
6795 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-array-of-user-defined-types/2")
6796 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-array-of-user-defined-types/3")
6797 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-array-of-user-defined-types/4")
6798 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-array-of-user-defined-types/5")
6799 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-array-of-user-defined-types/6")
6800 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-array-of-user-defined-types/7")
6801 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-array-of-user-defined-types/8")
6802 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 3/imm32" "F - test-convert-array-of-user-defined-types/9")
6803 (check-next-stream-line-equal _test-output-stream " 8d/copy-address *(eax + ecx<<0x00000003 + 4) 0x00000000/r32" "F - test-convert-array-of-user-defined-types/11")
6804 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-array-of-user-defined-types/13")
6805 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-array-of-user-defined-types/14")
6806 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-array-of-user-defined-types/15")
6807 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-array-of-user-defined-types/16")
6808 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-array-of-user-defined-types/17")
6809 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-array-of-user-defined-types/18")
6810 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-array-of-user-defined-types/19")
6811 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-array-of-user-defined-types/20")
6812
6813 89/<- %esp 5/r32/ebp
6814 5d/pop-to-ebp
6815 c3/return
6816
6817 test-convert-length-of-array-of-user-defined-types-to-eax:
6818
6819 55/push-ebp
6820 89/<- %ebp 4/r32/esp
6821
6822 (clear-stream _test-input-stream)
6823 (clear-stream $_test-input-buffered-file->buffer)
6824 (clear-stream _test-output-stream)
6825 (clear-stream $_test-output-buffered-file->buffer)
6826
6827 (write _test-input-stream "type t {\n")
6828 (write _test-input-stream " x: int\n")
6829 (write _test-input-stream " y: int\n")
6830 (write _test-input-stream " z: int\n")
6831 (write _test-input-stream "}\n")
6832 (write _test-input-stream "fn foo {\n")
6833 (write _test-input-stream " var arr/eax: (addr array t) <- copy 0\n")
6834 (write _test-input-stream " var x/eax: (addr t) <- length arr\n")
6835 (write _test-input-stream "}\n")
6836
6837 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
6838 (flush _test-output-buffered-file)
6839 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
6845
6846 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-length-of-array-of-user-defined-types-to-eax/0")
6847 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-length-of-array-of-user-defined-types-to-eax/1")
6848 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-length-of-array-of-user-defined-types-to-eax/2")
6849 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-length-of-array-of-user-defined-types-to-eax/3")
6850 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-length-of-array-of-user-defined-types-to-eax/4")
6851 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-length-of-array-of-user-defined-types-to-eax/5")
6852
6853 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-length-of-array-of-user-defined-types-to-eax/6")
6854 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-length-of-array-of-user-defined-types-to-eax/7")
6855
6856 (check-next-stream-line-equal _test-output-stream " 51/push-ecx" "F - test-convert-length-of-array-of-user-defined-types-to-eax/8")
6857 (check-next-stream-line-equal _test-output-stream " 52/push-edx" "F - test-convert-length-of-array-of-user-defined-types-to-eax/9")
6858 (check-next-stream-line-equal _test-output-stream " 8b/-> *eax 0x00000000/r32" "F - test-convert-length-of-array-of-user-defined-types-to-eax/10")
6859 (check-next-stream-line-equal _test-output-stream " 31/xor %edx 2/r32/edx" "F - test-convert-length-of-array-of-user-defined-types-to-eax/11")
6860 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 0x0000000c/imm32" "F - test-convert-length-of-array-of-user-defined-types-to-eax/12")
6861 (check-next-stream-line-equal _test-output-stream " f7 7/subop/idiv-eax-edx-by %ecx" "F - test-convert-length-of-array-of-user-defined-types-to-eax/13")
6862 (check-next-stream-line-equal _test-output-stream " 5a/pop-to-edx" "F - test-convert-length-of-array-of-user-defined-types-to-eax/14")
6863 (check-next-stream-line-equal _test-output-stream " 59/pop-to-ecx" "F - test-convert-length-of-array-of-user-defined-types-to-eax/15")
6864
6865 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-length-of-array-of-user-defined-types-to-eax/16")
6866
6867 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-length-of-array-of-user-defined-types-to-eax/17")
6868 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-length-of-array-of-user-defined-types-to-eax/18")
6869 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-length-of-array-of-user-defined-types-to-eax/19")
6870 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-length-of-array-of-user-defined-types-to-eax/20")
6871 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-length-of-array-of-user-defined-types-to-eax/21")
6872 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-length-of-array-of-user-defined-types-to-eax/22")
6873
6874 89/<- %esp 5/r32/ebp
6875 5d/pop-to-ebp
6876 c3/return
6877
6878 test-convert-length-of-array-of-user-defined-types-to-ecx:
6879
6880 55/push-ebp
6881 89/<- %ebp 4/r32/esp
6882
6883 (clear-stream _test-input-stream)
6884 (clear-stream $_test-input-buffered-file->buffer)
6885 (clear-stream _test-output-stream)
6886 (clear-stream $_test-output-buffered-file->buffer)
6887
6888 (write _test-input-stream "type t {\n")
6889 (write _test-input-stream " x: int\n")
6890 (write _test-input-stream " y: int\n")
6891 (write _test-input-stream " z: int\n")
6892 (write _test-input-stream "}\n")
6893 (write _test-input-stream "fn foo {\n")
6894 (write _test-input-stream " var arr/eax: (addr array t) <- copy 0\n")
6895 (write _test-input-stream " var x/ecx: (addr t) <- length arr\n")
6896 (write _test-input-stream "}\n")
6897
6898 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
6899 (flush _test-output-buffered-file)
6900 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
6906
6907 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/0")
6908 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/1")
6909 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/2")
6910 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/3")
6911 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/4")
6912 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/5")
6913
6914 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/6")
6915 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/7")
6916
6917 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ecx" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/8")
6918
6919 (check-next-stream-line-equal _test-output-stream " 50/push-eax" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/9")
6920 (check-next-stream-line-equal _test-output-stream " 52/push-edx" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/10")
6921 (check-next-stream-line-equal _test-output-stream " 8b/-> *eax 0x00000000/r32" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/11")
6922 (check-next-stream-line-equal _test-output-stream " 31/xor %edx 2/r32/edx" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/12")
6923 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 0x0000000c/imm32" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/13")
6924 (check-next-stream-line-equal _test-output-stream " f7 7/subop/idiv-eax-edx-by %ecx" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/14")
6925 (check-next-stream-line-equal _test-output-stream " 89/<- %ecx 0/r32/eax" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/15")
6926 (check-next-stream-line-equal _test-output-stream " 5a/pop-to-edx" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/16")
6927 (check-next-stream-line-equal _test-output-stream " 58/pop-to-eax" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/17")
6928
6929 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ecx" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/18")
6930
6931 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/19")
6932
6933 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/20")
6934 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/21")
6935 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/22")
6936 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/23")
6937 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/24")
6938 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-length-of-array-of-user-defined-types-to-ecx/25")
6939
6940 89/<- %esp 5/r32/ebp
6941 5d/pop-to-ebp
6942 c3/return
6943
6944 test-convert-length-of-array-of-user-defined-types-to-edx:
6945
6946 55/push-ebp
6947 89/<- %ebp 4/r32/esp
6948
6949 (clear-stream _test-input-stream)
6950 (clear-stream $_test-input-buffered-file->buffer)
6951 (clear-stream _test-output-stream)
6952 (clear-stream $_test-output-buffered-file->buffer)
6953
6954 (write _test-input-stream "type t {\n")
6955 (write _test-input-stream " x: int\n")
6956 (write _test-input-stream " y: int\n")
6957 (write _test-input-stream " z: int\n")
6958 (write _test-input-stream "}\n")
6959 (write _test-input-stream "fn foo {\n")
6960 (write _test-input-stream " var arr/eax: (addr array t) <- copy 0\n")
6961 (write _test-input-stream " var x/edx: (addr t) <- length arr\n")
6962 (write _test-input-stream "}\n")
6963
6964 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
6965 (flush _test-output-buffered-file)
6966 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
6972
6973 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-length-of-array-of-user-defined-types-to-edx/0")
6974 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-length-of-array-of-user-defined-types-to-edx/1")
6975 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-length-of-array-of-user-defined-types-to-edx/2")
6976 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-length-of-array-of-user-defined-types-to-edx/3")
6977 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-length-of-array-of-user-defined-types-to-edx/4")
6978 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-length-of-array-of-user-defined-types-to-edx/5")
6979
6980 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-length-of-array-of-user-defined-types-to-edx/6")
6981 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-length-of-array-of-user-defined-types-to-edx/7")
6982
6983 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %edx" "F - test-convert-length-of-array-of-user-defined-types-to-edx/8")
6984
6985 (check-next-stream-line-equal _test-output-stream " 50/push-eax" "F - test-convert-length-of-array-of-user-defined-types-to-edx/9")
6986 (check-next-stream-line-equal _test-output-stream " 51/push-ecx" "F - test-convert-length-of-array-of-user-defined-types-to-edx/10")
6987 (check-next-stream-line-equal _test-output-stream " 8b/-> *eax 0x00000000/r32" "F - test-convert-length-of-array-of-user-defined-types-to-edx/11")
6988 (check-next-stream-line-equal _test-output-stream " 31/xor %edx 2/r32/edx" "F - test-convert-length-of-array-of-user-defined-types-to-edx/12")
6989 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 0x0000000c/imm32" "F - test-convert-length-of-array-of-user-defined-types-to-edx/13")
6990 (check-next-stream-line-equal _test-output-stream " f7 7/subop/idiv-eax-edx-by %ecx" "F - test-convert-length-of-array-of-user-defined-types-to-edx/14")
6991 (check-next-stream-line-equal _test-output-stream " 89/<- %edx 0/r32/eax" "F - test-convert-length-of-array-of-user-defined-types-to-edx/15")
6992 (check-next-stream-line-equal _test-output-stream " 59/pop-to-ecx" "F - test-convert-length-of-array-of-user-defined-types-to-edx/16")
6993 (check-next-stream-line-equal _test-output-stream " 58/pop-to-eax" "F - test-convert-length-of-array-of-user-defined-types-to-edx/17")
6994
6995 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %edx" "F - test-convert-length-of-array-of-user-defined-types-to-edx/18")
6996
6997 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-length-of-array-of-user-defined-types-to-edx/19")
6998
6999 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-length-of-array-of-user-defined-types-to-edx/20")
7000 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-length-of-array-of-user-defined-types-to-edx/21")
7001 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-length-of-array-of-user-defined-types-to-edx/22")
7002 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-length-of-array-of-user-defined-types-to-edx/23")
7003 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-length-of-array-of-user-defined-types-to-edx/24")
7004 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-length-of-array-of-user-defined-types-to-edx/25")
7005
7006 89/<- %esp 5/r32/ebp
7007 5d/pop-to-ebp
7008 c3/return
7009
7010 test-convert-length-of-array-of-user-defined-types:
7011
7012 55/push-ebp
7013 89/<- %ebp 4/r32/esp
7014
7015 (clear-stream _test-input-stream)
7016 (clear-stream $_test-input-buffered-file->buffer)
7017 (clear-stream _test-output-stream)
7018 (clear-stream $_test-output-buffered-file->buffer)
7019
7020 (write _test-input-stream "type t {\n")
7021 (write _test-input-stream " x: int\n")
7022 (write _test-input-stream " y: int\n")
7023 (write _test-input-stream " z: int\n")
7024 (write _test-input-stream "}\n")
7025 (write _test-input-stream "fn foo {\n")
7026 (write _test-input-stream " var arr/eax: (addr array t) <- copy 0\n")
7027 (write _test-input-stream " var x/ebx: (addr t) <- length arr\n")
7028 (write _test-input-stream "}\n")
7029
7030 (convert-mu _test-input-buffered-file _test-output-buffered-file Stderr 0)
7031 (flush _test-output-buffered-file)
7032 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
7038
7039 (check-next-stream-line-equal _test-output-stream "foo:" "F - test-convert-length-of-array-of-user-defined-types/0")
7040 (check-next-stream-line-equal _test-output-stream " # . prologue" "F - test-convert-length-of-array-of-user-defined-types/1")
7041 (check-next-stream-line-equal _test-output-stream " 55/push-ebp" "F - test-convert-length-of-array-of-user-defined-types/2")
7042 (check-next-stream-line-equal _test-output-stream " 89/<- %ebp 4/r32/esp" "F - test-convert-length-of-array-of-user-defined-types/3")
7043 (check-next-stream-line-equal _test-output-stream " {" "F - test-convert-length-of-array-of-user-defined-types/4")
7044 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:loop:" "F - test-convert-length-of-array-of-user-defined-types/5")
7045 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %eax" "F - test-convert-length-of-array-of-user-defined-types/6")
7046 (check-next-stream-line-equal _test-output-stream " b8/copy-to-eax 0/imm32" "F - test-convert-length-of-array-of-user-defined-types/7")
7047 (check-next-stream-line-equal _test-output-stream " ff 6/subop/push %ebx" "F - test-convert-length-of-array-of-user-defined-types/8")
7048 (check-next-stream-line-equal _test-output-stream " 50/push-eax" "F - test-convert-length-of-array-of-user-defined-types/9")
7049 (check-next-stream-line-equal _test-output-stream " 51/push-ecx" "F - test-convert-length-of-array-of-user-defined-types/10")
7050 (check-next-stream-line-equal _test-output-stream " 52/push-edx" "F - test-convert-length-of-array-of-user-defined-types/11")
7051 (check-next-stream-line-equal _test-output-stream " 8b/-> *eax 0x00000000/r32" "F - test-convert-length-of-array-of-user-defined-types/12")
7052 (check-next-stream-line-equal _test-output-stream " 31/xor %edx 2/r32/edx" "F - test-convert-length-of-array-of-user-defined-types/13")
7053 (check-next-stream-line-equal _test-output-stream " b9/copy-to-ecx 0x0000000c/imm32" "F - test-convert-length-of-array-of-user-defined-types/14")
7054 (check-next-stream-line-equal _test-output-stream " f7 7/subop/idiv-eax-edx-by %ecx" "F - test-convert-length-of-array-of-user-defined-types/15")
7055 (check-next-stream-line-equal _test-output-stream " 89/<- %ebx 0/r32/eax" "F - test-convert-length-of-array-of-user-defined-types/16")
7056 (check-next-stream-line-equal _test-output-stream " 5a/pop-to-edx" "F - test-convert-length-of-array-of-user-defined-types/17")
7057 (check-next-stream-line-equal _test-output-stream " 59/pop-to-ecx" "F - test-convert-length-of-array-of-user-defined-types/18")
7058 (check-next-stream-line-equal _test-output-stream " 58/pop-to-eax" "F - test-convert-length-of-array-of-user-defined-types/19")
7059 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %ebx" "F - test-convert-length-of-array-of-user-defined-types/20")
7060 (check-next-stream-line-equal _test-output-stream " 8f 0/subop/pop %eax" "F - test-convert-length-of-array-of-user-defined-types/21")
7061 (check-next-stream-line-equal _test-output-stream " }" "F - test-convert-length-of-array-of-user-defined-types/22")
7062 (check-next-stream-line-equal _test-output-stream "$foo:0x00000001:break:" "F - test-convert-length-of-array-of-user-defined-types/23")
7063 (check-next-stream-line-equal _test-output-stream " # . epilogue" "F - test-convert-length-of-array-of-user-defined-types/24")
7064 (check-next-stream-line-equal _test-output-stream " 89/<- %esp 5/r32/ebp" "F - test-convert-length-of-array-of-user-defined-types/25")
7065 (check-next-stream-line-equal _test-output-stream " 5d/pop-to-ebp" "F - test-convert-length-of-array-of-user-defined-types/26")
7066 (check-next-stream-line-equal _test-output-stream " c3/return" "F - test-convert-length-of-array-of-user-defined-types/27")
7067
7068 89/<- %esp 5/r32/ebp
7069 5d/pop-to-ebp
7070 c3/return
7071
7072 test-index-with-non-array-atom-base-type:
7073
7074 55/push-ebp
7075 89/<- %ebp 4/r32/esp
7076
7077 (clear-stream _test-input-stream)
7078 (clear-stream $_test-input-buffered-file->buffer)
7079 (clear-stream _test-output-stream)
7080 (clear-stream $_test-output-buffered-file->buffer)
7081 (clear-stream _test-error-stream)
7082 (clear-stream $_test-error-buffered-file->buffer)
7083
7084 68/push 0/imm32
7085 68/push 0/imm32
7086 89/<- %edx 4/r32/esp
7087 (tailor-exit-descriptor %edx 0x10)
7088
7089 (write _test-input-stream "fn foo {\n")
7090 (write _test-input-stream " var a: int\n")
7091 (write _test-input-stream " var c/ecx: (addr int) <- index a, 0\n")
7092 (write _test-input-stream "}\n")
7093
7094 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7095
7096
7097 89/<- %edx 4/r32/esp
7098 (flush _test-output-buffered-file)
7099 (flush _test-error-buffered-file)
7100 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7106
7107 (check-stream-equal _test-output-stream "" "F - test-index-with-non-array-atom-base-type: output should be empty")
7108 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: var 'a' is not an array" "F - test-index-with-non-array-atom-base-type: error message")
7109
7110 (check-ints-equal *(edx+4) 2 "F - test-index-with-non-array-atom-base-type: exit status")
7111
7112 81 0/subop/add %esp 8/imm32
7113
7114 5d/pop-to-ebp
7115 c3/return
7116
7117 test-index-with-non-array-compound-base-type:
7118
7119 55/push-ebp
7120 89/<- %ebp 4/r32/esp
7121
7122 (clear-stream _test-input-stream)
7123 (clear-stream $_test-input-buffered-file->buffer)
7124 (clear-stream _test-output-stream)
7125 (clear-stream $_test-output-buffered-file->buffer)
7126 (clear-stream _test-error-stream)
7127 (clear-stream $_test-error-buffered-file->buffer)
7128
7129 68/push 0/imm32
7130 68/push 0/imm32
7131 89/<- %edx 4/r32/esp
7132 (tailor-exit-descriptor %edx 0x10)
7133
7134 (write _test-input-stream "fn foo {\n")
7135 (write _test-input-stream " var a: (handle int)\n")
7136 (write _test-input-stream " var c/ecx: (addr int) <- index a, 0\n")
7137 (write _test-input-stream "}\n")
7138
7139 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7140
7141
7142 89/<- %edx 4/r32/esp
7143 (flush _test-output-buffered-file)
7144 (flush _test-error-buffered-file)
7145 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7151
7152 (check-stream-equal _test-output-stream "" "F - test-index-with-non-array-compound-base-type: output should be empty")
7153 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: var 'a' is not an array" "F - test-index-with-non-array-compound-base-type: error message")
7154
7155 (check-ints-equal *(edx+4) 2 "F - test-index-with-non-array-compound-base-type: exit status")
7156
7157 81 0/subop/add %esp 8/imm32
7158
7159 5d/pop-to-ebp
7160 c3/return
7161
7162 test-index-with-non-array-compound-base-type-2:
7163
7164 55/push-ebp
7165 89/<- %ebp 4/r32/esp
7166
7167 (clear-stream _test-input-stream)
7168 (clear-stream $_test-input-buffered-file->buffer)
7169 (clear-stream _test-output-stream)
7170 (clear-stream $_test-output-buffered-file->buffer)
7171 (clear-stream _test-error-stream)
7172 (clear-stream $_test-error-buffered-file->buffer)
7173
7174 68/push 0/imm32
7175 68/push 0/imm32
7176 89/<- %edx 4/r32/esp
7177 (tailor-exit-descriptor %edx 0x10)
7178
7179 (write _test-input-stream "fn foo {\n")
7180 (write _test-input-stream " var a: (addr int)\n")
7181 (write _test-input-stream " var c/ecx: (addr int) <- index a, 0\n")
7182 (write _test-input-stream "}\n")
7183
7184 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7185
7186
7187 89/<- %edx 4/r32/esp
7188 (flush _test-output-buffered-file)
7189 (flush _test-error-buffered-file)
7190 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7196
7197 (check-stream-equal _test-output-stream "" "F - test-index-with-non-array-compound-base-type-2: output should be empty")
7198 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: var 'a' is not an array" "F - test-index-with-non-array-compound-base-type-2: error message")
7199
7200 (check-ints-equal *(edx+4) 2 "F - test-index-with-non-array-compound-base-type-2: exit status")
7201
7202 81 0/subop/add %esp 8/imm32
7203
7204 5d/pop-to-ebp
7205 c3/return
7206
7207 test-index-with-array-atom-base-type:
7208
7209 55/push-ebp
7210 89/<- %ebp 4/r32/esp
7211
7212 (clear-stream _test-input-stream)
7213 (clear-stream $_test-input-buffered-file->buffer)
7214 (clear-stream _test-output-stream)
7215 (clear-stream $_test-output-buffered-file->buffer)
7216 (clear-stream _test-error-stream)
7217 (clear-stream $_test-error-buffered-file->buffer)
7218
7219 68/push 0/imm32
7220 68/push 0/imm32
7221 89/<- %edx 4/r32/esp
7222 (tailor-exit-descriptor %edx 0x10)
7223
7224 (write _test-input-stream "fn foo {\n")
7225 (write _test-input-stream " var a: array\n")
7226 (write _test-input-stream " var c/ecx: (addr int) <- index a, 0\n")
7227 (write _test-input-stream "}\n")
7228
7229 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7230
7231
7232 89/<- %edx 4/r32/esp
7233 (flush _test-output-buffered-file)
7234 (flush _test-error-buffered-file)
7235 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7241
7242 (check-stream-equal _test-output-stream "" "F - test-index-with-array-atom-base-type: output should be empty")
7243 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: array 'a' must specify the type of its elements" "F - test-index-with-array-atom-base-type: error message")
7244
7245 (check-ints-equal *(edx+4) 2 "F - test-index-with-array-atom-base-type: exit status")
7246
7247 81 0/subop/add %esp 8/imm32
7248
7249 5d/pop-to-ebp
7250 c3/return
7251
7252 test-index-with-addr-base-on-stack:
7253
7254 55/push-ebp
7255 89/<- %ebp 4/r32/esp
7256
7257 (clear-stream _test-input-stream)
7258 (clear-stream $_test-input-buffered-file->buffer)
7259 (clear-stream _test-output-stream)
7260 (clear-stream $_test-output-buffered-file->buffer)
7261 (clear-stream _test-error-stream)
7262 (clear-stream $_test-error-buffered-file->buffer)
7263
7264 68/push 0/imm32
7265 68/push 0/imm32
7266 89/<- %edx 4/r32/esp
7267 (tailor-exit-descriptor %edx 0x10)
7268
7269 (write _test-input-stream "fn foo {\n")
7270 (write _test-input-stream " var a: (addr array int)\n")
7271 (write _test-input-stream " var c/ecx: (addr int) <- index a, 0\n")
7272 (write _test-input-stream "}\n")
7273
7274 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7275
7276
7277 89/<- %edx 4/r32/esp
7278 (flush _test-output-buffered-file)
7279 (flush _test-error-buffered-file)
7280 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7286
7287 (check-stream-equal _test-output-stream "" "F - test-index-with-addr-base-on-stack: output should be empty")
7288 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: var 'a' is an addr to an array, and so must live in a register" "F - test-index-with-addr-base-on-stack: error message")
7289
7290 (check-ints-equal *(edx+4) 2 "F - test-index-with-addr-base-on-stack: exit status")
7291
7292 81 0/subop/add %esp 8/imm32
7293
7294 5d/pop-to-ebp
7295 c3/return
7296
7297 test-index-with-array-base-in-register:
7298
7299 55/push-ebp
7300 89/<- %ebp 4/r32/esp
7301
7302 (clear-stream _test-input-stream)
7303 (clear-stream $_test-input-buffered-file->buffer)
7304 (clear-stream _test-output-stream)
7305 (clear-stream $_test-output-buffered-file->buffer)
7306 (clear-stream _test-error-stream)
7307 (clear-stream $_test-error-buffered-file->buffer)
7308
7309 68/push 0/imm32
7310 68/push 0/imm32
7311 89/<- %edx 4/r32/esp
7312 (tailor-exit-descriptor %edx 0x10)
7313
7314 (write _test-input-stream "fn foo {\n")
7315 (write _test-input-stream " var a/eax: (array int 3) <- copy 0\n")
7316 (write _test-input-stream " var c/ecx: (addr int) <- index a, 0\n")
7317 (write _test-input-stream "}\n")
7318
7319 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7320
7321
7322 89/<- %edx 4/r32/esp
7323 (flush _test-output-buffered-file)
7324 (flush _test-error-buffered-file)
7325 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7331
7332 (check-stream-equal _test-output-stream "" "F - test-index-with-array-base-in-register: output should be empty")
7333 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: var 'a' is an array, and so must live on the stack" "F - test-index-with-array-base-in-register: error message")
7334
7335 (check-ints-equal *(edx+4) 2 "F - test-index-with-array-base-in-register: exit status")
7336
7337 81 0/subop/add %esp 8/imm32
7338
7339 5d/pop-to-ebp
7340 c3/return
7341
7342 test-index-with-wrong-index-type:
7343
7344 55/push-ebp
7345 89/<- %ebp 4/r32/esp
7346
7347 (clear-stream _test-input-stream)
7348 (clear-stream $_test-input-buffered-file->buffer)
7349 (clear-stream _test-output-stream)
7350 (clear-stream $_test-output-buffered-file->buffer)
7351 (clear-stream _test-error-stream)
7352 (clear-stream $_test-error-buffered-file->buffer)
7353
7354 68/push 0/imm32
7355 68/push 0/imm32
7356 89/<- %edx 4/r32/esp
7357 (tailor-exit-descriptor %edx 0x10)
7358
7359 (write _test-input-stream "fn foo {\n")
7360 (write _test-input-stream " var a/eax: (addr array int) <- copy 0\n")
7361 (write _test-input-stream " var b: boolean\n")
7362 (write _test-input-stream " var c/ecx: (addr int) <- index a, b\n")
7363 (write _test-input-stream "}\n")
7364
7365 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7366
7367
7368 89/<- %edx 4/r32/esp
7369 (flush _test-output-buffered-file)
7370 (flush _test-error-buffered-file)
7371 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7377
7378 (check-stream-equal _test-output-stream "" "F - test-index-with-wrong-index-type: output should be empty")
7379 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: second argument 'b' must be an int or offset" "F - test-index-with-wrong-index-type: error message")
7380
7381 (check-ints-equal *(edx+4) 2 "F - test-index-with-wrong-index-type: exit status")
7382
7383 81 0/subop/add %esp 8/imm32
7384
7385 5d/pop-to-ebp
7386 c3/return
7387
7388 test-index-with-offset-atom-index-type:
7389
7390 55/push-ebp
7391 89/<- %ebp 4/r32/esp
7392
7393 (clear-stream _test-input-stream)
7394 (clear-stream $_test-input-buffered-file->buffer)
7395 (clear-stream _test-output-stream)
7396 (clear-stream $_test-output-buffered-file->buffer)
7397 (clear-stream _test-error-stream)
7398 (clear-stream $_test-error-buffered-file->buffer)
7399
7400 68/push 0/imm32
7401 68/push 0/imm32
7402 89/<- %edx 4/r32/esp
7403 (tailor-exit-descriptor %edx 0x10)
7404
7405 (write _test-input-stream "fn foo {\n")
7406 (write _test-input-stream " var a/eax: (addr array int) <- copy 0\n")
7407 (write _test-input-stream " var b: offset\n")
7408 (write _test-input-stream " var c/ecx: (addr int) <- index a, b\n")
7409 (write _test-input-stream "}\n")
7410
7411 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7412
7413
7414 89/<- %edx 4/r32/esp
7415 (flush _test-output-buffered-file)
7416 (flush _test-error-buffered-file)
7417 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7423
7424 (check-stream-equal _test-output-stream "" "F - test-index-with-offset-atom-index-type: output should be empty")
7425 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: offset 'b' must specify the type of array elements" "F - test-index-with-offset-atom-index-type: error message")
7426
7427 (check-ints-equal *(edx+4) 2 "F - test-index-with-offset-atom-index-type: exit status")
7428
7429 81 0/subop/add %esp 8/imm32
7430
7431 5d/pop-to-ebp
7432 c3/return
7433
7434 test-index-with-offset-on-stack:
7435
7436 55/push-ebp
7437 89/<- %ebp 4/r32/esp
7438
7439 (clear-stream _test-input-stream)
7440 (clear-stream $_test-input-buffered-file->buffer)
7441 (clear-stream _test-output-stream)
7442 (clear-stream $_test-output-buffered-file->buffer)
7443 (clear-stream _test-error-stream)
7444 (clear-stream $_test-error-buffered-file->buffer)
7445
7446 68/push 0/imm32
7447 68/push 0/imm32
7448 89/<- %edx 4/r32/esp
7449 (tailor-exit-descriptor %edx 0x10)
7450
7451 (write _test-input-stream "fn foo {\n")
7452 (write _test-input-stream " var a/eax: (addr array int) <- copy 0\n")
7453 (write _test-input-stream " var b: int\n")
7454 (write _test-input-stream " var c/ecx: (addr int) <- index a, b\n")
7455 (write _test-input-stream "}\n")
7456
7457 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7458
7459
7460 89/<- %edx 4/r32/esp
7461 (flush _test-output-buffered-file)
7462 (flush _test-error-buffered-file)
7463 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7469
7470 (check-stream-equal _test-output-stream "" "F - test-index-with-offset-on-stack: output should be empty")
7471 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: second argument 'b' must be in a register" "F - test-index-with-offset-on-stack: error message")
7472
7473 (check-ints-equal *(edx+4) 2 "F - test-index-with-offset-on-stack: exit status")
7474
7475 81 0/subop/add %esp 8/imm32
7476
7477 5d/pop-to-ebp
7478 c3/return
7479
7480 test-index-needs-offset-type:
7481
7482 55/push-ebp
7483 89/<- %ebp 4/r32/esp
7484
7485 (clear-stream _test-input-stream)
7486 (clear-stream $_test-input-buffered-file->buffer)
7487 (clear-stream _test-output-stream)
7488 (clear-stream $_test-output-buffered-file->buffer)
7489 (clear-stream _test-error-stream)
7490 (clear-stream $_test-error-buffered-file->buffer)
7491
7492 68/push 0/imm32
7493 68/push 0/imm32
7494 89/<- %edx 4/r32/esp
7495 (tailor-exit-descriptor %edx 0x10)
7496
7497 (write _test-input-stream "fn foo {\n")
7498 (write _test-input-stream " var a/eax: (addr array t) <- copy 0\n")
7499 (write _test-input-stream " var b/ebx: int <- copy 0\n")
7500 (write _test-input-stream " var c/ecx: (addr int) <- index a, b\n")
7501 (write _test-input-stream "}\n")
7502 (write _test-input-stream "type t {\n")
7503 (write _test-input-stream " x: int\n")
7504 (write _test-input-stream " y: int\n")
7505 (write _test-input-stream " z: int\n")
7506 (write _test-input-stream "}\n")
7507
7508 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7509
7510
7511 89/<- %edx 4/r32/esp
7512 (flush _test-output-buffered-file)
7513 (flush _test-error-buffered-file)
7514 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7520
7521 (check-stream-equal _test-output-stream "" "F - test-index-needs-offset-type: output should be empty")
7522 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: cannot take an int for array 'a'; create an offset instead. See mu.md for details." "F - test-index-needs-offset-type: error message")
7523
7524 (check-ints-equal *(edx+4) 2 "F - test-index-needs-offset-type: exit status")
7525
7526 81 0/subop/add %esp 8/imm32
7527
7528 5d/pop-to-ebp
7529 c3/return
7530
7531 test-index-with-output-not-address:
7532
7533 55/push-ebp
7534 89/<- %ebp 4/r32/esp
7535
7536 (clear-stream _test-input-stream)
7537 (clear-stream $_test-input-buffered-file->buffer)
7538 (clear-stream _test-output-stream)
7539 (clear-stream $_test-output-buffered-file->buffer)
7540 (clear-stream _test-error-stream)
7541 (clear-stream $_test-error-buffered-file->buffer)
7542
7543 68/push 0/imm32
7544 68/push 0/imm32
7545 89/<- %edx 4/r32/esp
7546 (tailor-exit-descriptor %edx 0x10)
7547
7548 (write _test-input-stream "fn foo {\n")
7549 (write _test-input-stream " var a/ebx: (addr array boolean) <- copy 0\n")
7550 (write _test-input-stream " var o/edi: int <- index a, 0\n")
7551 (write _test-input-stream "}\n")
7552
7553 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7554
7555
7556 89/<- %edx 4/r32/esp
7557 (flush _test-output-buffered-file)
7558 (flush _test-error-buffered-file)
7559 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7565
7566 (check-stream-equal _test-output-stream "" "F - test-index-with-output-not-address: output should be empty")
7567 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: output 'o' must be an address" "F - test-index-with-output-not-address: error message")
7568
7569 (check-ints-equal *(edx+4) 2 "F - test-index-with-output-not-address: exit status")
7570
7571 81 0/subop/add %esp 8/imm32
7572
7573 5d/pop-to-ebp
7574 c3/return
7575
7576 test-index-with-output-not-address-2:
7577
7578 55/push-ebp
7579 89/<- %ebp 4/r32/esp
7580
7581 (clear-stream _test-input-stream)
7582 (clear-stream $_test-input-buffered-file->buffer)
7583 (clear-stream _test-output-stream)
7584 (clear-stream $_test-output-buffered-file->buffer)
7585 (clear-stream _test-error-stream)
7586 (clear-stream $_test-error-buffered-file->buffer)
7587
7588 68/push 0/imm32
7589 68/push 0/imm32
7590 89/<- %edx 4/r32/esp
7591 (tailor-exit-descriptor %edx 0x10)
7592
7593 (write _test-input-stream "fn foo {\n")
7594 (write _test-input-stream " var a/ebx: (addr array boolean) <- copy 0\n")
7595 (write _test-input-stream " var o/edi: (int) <- index a, 0\n")
7596 (write _test-input-stream "}\n")
7597
7598 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7599
7600
7601 89/<- %edx 4/r32/esp
7602 (flush _test-output-buffered-file)
7603 (flush _test-error-buffered-file)
7604 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7610
7611 (check-stream-equal _test-output-stream "" "F - test-index-with-output-not-address-2: output should be empty")
7612 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: output 'o' must be an address" "F - test-index-with-output-not-address-2: error message")
7613
7614 (check-ints-equal *(edx+4) 2 "F - test-index-with-output-not-address-2: exit status")
7615
7616 81 0/subop/add %esp 8/imm32
7617
7618 5d/pop-to-ebp
7619 c3/return
7620
7621 test-index-with-wrong-output-type:
7622
7623 55/push-ebp
7624 89/<- %ebp 4/r32/esp
7625
7626 (clear-stream _test-input-stream)
7627 (clear-stream $_test-input-buffered-file->buffer)
7628 (clear-stream _test-output-stream)
7629 (clear-stream $_test-output-buffered-file->buffer)
7630 (clear-stream _test-error-stream)
7631 (clear-stream $_test-error-buffered-file->buffer)
7632
7633 68/push 0/imm32
7634 68/push 0/imm32
7635 89/<- %edx 4/r32/esp
7636 (tailor-exit-descriptor %edx 0x10)
7637
7638 (write _test-input-stream "fn foo {\n")
7639 (write _test-input-stream " var a/ebx: (addr array boolean) <- copy 0\n")
7640 (write _test-input-stream " var o/edi: (addr int) <- index a, 0\n")
7641 (write _test-input-stream "}\n")
7642
7643 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7644
7645
7646 89/<- %edx 4/r32/esp
7647 (flush _test-output-buffered-file)
7648 (flush _test-error-buffered-file)
7649 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7655
7656 (check-stream-equal _test-output-stream "" "F - test-index-with-wrong-output-type: output should be empty")
7657 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: output 'o' does not have the right type" "F - test-index-with-wrong-output-type: error message")
7658
7659 (check-ints-equal *(edx+4) 2 "F - test-index-with-wrong-output-type: exit status")
7660
7661 81 0/subop/add %esp 8/imm32
7662
7663 5d/pop-to-ebp
7664 c3/return
7665
7666 test-index-with-wrong-output-compound-type:
7667
7668 55/push-ebp
7669 89/<- %ebp 4/r32/esp
7670
7671 (clear-stream _test-input-stream)
7672 (clear-stream $_test-input-buffered-file->buffer)
7673 (clear-stream _test-output-stream)
7674 (clear-stream $_test-output-buffered-file->buffer)
7675 (clear-stream _test-error-stream)
7676 (clear-stream $_test-error-buffered-file->buffer)
7677
7678 68/push 0/imm32
7679 68/push 0/imm32
7680 89/<- %edx 4/r32/esp
7681 (tailor-exit-descriptor %edx 0x10)
7682
7683 (write _test-input-stream "fn foo {\n")
7684 (write _test-input-stream " var a/ebx: (addr array handle boolean) <- copy 0\n")
7685 (write _test-input-stream " var o/edi: (addr handle int) <- index a, 0\n")
7686 (write _test-input-stream "}\n")
7687
7688 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7689
7690
7691 89/<- %edx 4/r32/esp
7692 (flush _test-output-buffered-file)
7693 (flush _test-error-buffered-file)
7694 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7700
7701 (check-stream-equal _test-output-stream "" "F - test-index-with-wrong-output-compound-type: output should be empty")
7702 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: output 'o' does not have the right type" "F - test-index-with-wrong-output-compound-type: error message")
7703
7704 (check-ints-equal *(edx+4) 2 "F - test-index-with-wrong-output-compound-type: exit status")
7705
7706 81 0/subop/add %esp 8/imm32
7707
7708 5d/pop-to-ebp
7709 c3/return
7710
7711 test-index-with-no-inouts:
7712
7713 55/push-ebp
7714 89/<- %ebp 4/r32/esp
7715
7716 (clear-stream _test-input-stream)
7717 (clear-stream $_test-input-buffered-file->buffer)
7718 (clear-stream _test-output-stream)
7719 (clear-stream $_test-output-buffered-file->buffer)
7720 (clear-stream _test-error-stream)
7721 (clear-stream $_test-error-buffered-file->buffer)
7722
7723 68/push 0/imm32
7724 68/push 0/imm32
7725 89/<- %edx 4/r32/esp
7726 (tailor-exit-descriptor %edx 0x10)
7727
7728 (write _test-input-stream "fn foo {\n")
7729 (write _test-input-stream " var c/ecx: (addr int) <- index\n")
7730 (write _test-input-stream "}\n")
7731
7732 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7733
7734
7735 89/<- %edx 4/r32/esp
7736 (flush _test-output-buffered-file)
7737 (flush _test-error-buffered-file)
7738 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7744
7745 (check-stream-equal _test-output-stream "" "F - test-index-with-no-inouts: output should be empty")
7746 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: too few inouts (2 required)" "F - test-index-with-no-inouts: error message")
7747
7748 (check-ints-equal *(edx+4) 2 "F - test-index-with-no-inouts: exit status")
7749
7750 81 0/subop/add %esp 8/imm32
7751
7752 5d/pop-to-ebp
7753 c3/return
7754
7755 test-index-with-too-few-inouts:
7756
7757 55/push-ebp
7758 89/<- %ebp 4/r32/esp
7759
7760 (clear-stream _test-input-stream)
7761 (clear-stream $_test-input-buffered-file->buffer)
7762 (clear-stream _test-output-stream)
7763 (clear-stream $_test-output-buffered-file->buffer)
7764 (clear-stream _test-error-stream)
7765 (clear-stream $_test-error-buffered-file->buffer)
7766
7767 68/push 0/imm32
7768 68/push 0/imm32
7769 89/<- %edx 4/r32/esp
7770 (tailor-exit-descriptor %edx 0x10)
7771
7772 (write _test-input-stream "fn foo {\n")
7773 (write _test-input-stream " var a: (array int 3)\n")
7774 (write _test-input-stream " var c/ecx: (addr int) <- index a\n")
7775 (write _test-input-stream "}\n")
7776
7777 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7778
7779
7780 89/<- %edx 4/r32/esp
7781 (flush _test-output-buffered-file)
7782 (flush _test-error-buffered-file)
7783 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7789
7790 (check-stream-equal _test-output-stream "" "F - test-index-with-too-few-inouts: output should be empty")
7791 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: too few inouts (2 required)" "F - test-index-with-too-few-inouts: error message")
7792
7793 (check-ints-equal *(edx+4) 2 "F - test-index-with-too-few-inouts: exit status")
7794
7795 81 0/subop/add %esp 8/imm32
7796
7797 5d/pop-to-ebp
7798 c3/return
7799
7800 test-index-with-too-many-inouts:
7801
7802 55/push-ebp
7803 89/<- %ebp 4/r32/esp
7804
7805 (clear-stream _test-input-stream)
7806 (clear-stream $_test-input-buffered-file->buffer)
7807 (clear-stream _test-output-stream)
7808 (clear-stream $_test-output-buffered-file->buffer)
7809 (clear-stream _test-error-stream)
7810 (clear-stream $_test-error-buffered-file->buffer)
7811
7812 68/push 0/imm32
7813 68/push 0/imm32
7814 89/<- %edx 4/r32/esp
7815 (tailor-exit-descriptor %edx 0x10)
7816
7817 (write _test-input-stream "fn foo {\n")
7818 (write _test-input-stream " var a: (array int 3)\n")
7819 (write _test-input-stream " var c/ecx: (addr int) <- index a, 0, 0\n")
7820 (write _test-input-stream "}\n")
7821
7822 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7823
7824
7825 89/<- %edx 4/r32/esp
7826 (flush _test-output-buffered-file)
7827 (flush _test-error-buffered-file)
7828 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7834
7835 (check-stream-equal _test-output-stream "" "F - test-index-with-too-many-inouts: output should be empty")
7836 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: too many inouts (2 required)" "F - test-index-with-too-many-inouts: error message")
7837
7838 (check-ints-equal *(edx+4) 2 "F - test-index-with-too-many-inouts: exit status")
7839
7840 81 0/subop/add %esp 8/imm32
7841
7842 5d/pop-to-ebp
7843 c3/return
7844
7845 test-index-with-no-output:
7846
7847 55/push-ebp
7848 89/<- %ebp 4/r32/esp
7849
7850 (clear-stream _test-input-stream)
7851 (clear-stream $_test-input-buffered-file->buffer)
7852 (clear-stream _test-output-stream)
7853 (clear-stream $_test-output-buffered-file->buffer)
7854 (clear-stream _test-error-stream)
7855 (clear-stream $_test-error-buffered-file->buffer)
7856
7857 68/push 0/imm32
7858 68/push 0/imm32
7859 89/<- %edx 4/r32/esp
7860 (tailor-exit-descriptor %edx 0x10)
7861
7862 (write _test-input-stream "fn foo {\n")
7863 (write _test-input-stream " var a: (array int 3)\n")
7864 (write _test-input-stream " index a, 0\n")
7865 (write _test-input-stream "}\n")
7866
7867 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7868
7869
7870 89/<- %edx 4/r32/esp
7871 (flush _test-output-buffered-file)
7872 (flush _test-error-buffered-file)
7873 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7879
7880 (check-stream-equal _test-output-stream "" "F - test-index-with-no-output: output should be empty")
7881 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: must have an output" "F - test-index-with-no-output: error message")
7882
7883 (check-ints-equal *(edx+4) 2 "F - test-index-with-no-output: exit status")
7884
7885 81 0/subop/add %esp 8/imm32
7886
7887 5d/pop-to-ebp
7888 c3/return
7889
7890 test-index-with-too-many-outputs:
7891
7892 55/push-ebp
7893 89/<- %ebp 4/r32/esp
7894
7895 (clear-stream _test-input-stream)
7896 (clear-stream $_test-input-buffered-file->buffer)
7897 (clear-stream _test-output-stream)
7898 (clear-stream $_test-output-buffered-file->buffer)
7899 (clear-stream _test-error-stream)
7900 (clear-stream $_test-error-buffered-file->buffer)
7901
7902 68/push 0/imm32
7903 68/push 0/imm32
7904 89/<- %edx 4/r32/esp
7905 (tailor-exit-descriptor %edx 0x10)
7906
7907 (write _test-input-stream "fn foo {\n")
7908 (write _test-input-stream " var a: (array int 3)\n")
7909 (write _test-input-stream " var b/eax: (addr int) <- copy 0\n")
7910 (write _test-input-stream " var c/ecx: (addr int) <- copy 0\n")
7911 (write _test-input-stream " b, c <- index a, 0\n")
7912 (write _test-input-stream "}\n")
7913
7914 (convert-mu _test-input-buffered-file _test-output-buffered-file _test-error-buffered-file %edx)
7915
7916
7917 89/<- %edx 4/r32/esp
7918 (flush _test-output-buffered-file)
7919 (flush _test-error-buffered-file)
7920 +-- 6 lines: #? # dump _test-error-stream ------------------------------------------------------------------------------------------------------------------------------------------
7926
7927 (check-stream-equal _test-output-stream "" "F - test-index-with-too-many-outputs: output should be empty")
7928 (check-next-stream-line-equal _test-error-stream "fn foo: stmt index: too many outputs (1 required)" "F - test-index-with-too-many-outputs: error message")
7929
7930 (check-ints-equal *(edx+4) 2 "F - test-index-with-too-many-outputs: exit status")
7931
7932 81 0/subop/add %esp 8/imm32
7933
7934 5d/pop-to-ebp
7935 c3/return
7936
7937
7938
7939
7940
7941 == data
7942
7943
7944 Next-block-index:
7945 1/imm32
7946
7947 Curr-block-depth:
7948 1/imm32
7949
7950 == code
7951
7952 parse-mu:
7953
7954
7955
7956
7957
7958
7959
7960
7961
7962
7963
7964
7965
7966
7967
7968
7969
7970
7971
7972
7973
7974
7975
7976
7977
7978
7979
7980
7981
7982
7983
7984
7985
7986
7987
7988
7989
7990
7991 55/push-ebp
7992 89/<- %ebp 4/r32/esp
7993
7994 68/push _Program-signatures/imm32
7995
7996 50/push-eax
7997 51/push-ecx
7998 52/push-edx
7999 53/push-ebx
8000 56/push-esi
8001 57/push-edi
8002
8003 81 5/subop/subtract %esp 0x200/imm32
8004 68/push 0x200/imm32/size
8005 68/push 0/imm32/read
8006 68/push 0/imm32/write
8007 89/<- %ecx 4/r32/esp
8008
8009 68/push 0/imm32/end
8010 68/push 0/imm32/start
8011 89/<- %edx 4/r32/esp
8012
8013 bf/copy-to-edi _Program-functions/imm32
8014
8015 81 5/subop/subtract %esp 0xc00/imm32
8016 68/push 0xc00/imm32/size
8017 68/push 0/imm32/top
8018 89/<- %ebx 4/r32/esp
8019 {
8020 $parse-mu:line-loop:
8021 (clear-stream %ecx)
8022 (read-line-buffered *(ebp+8) %ecx)
8023
8024 81 7/subop/compare *ecx 0/imm32
8025 0f 84/jump-if-= break/disp32
8026 +-- 6 lines: #? # dump line ------------------------------------------------------------------------------------------------------------------------------------------------------
8032 (next-mu-token %ecx %edx)
8033
8034 (slice-empty? %edx)
8035 3d/compare-eax-and 0/imm32/false
8036 0f 85/jump-if-!= loop/disp32
8037
8038
8039 8b/-> *edx 0/r32/eax
8040 8a/copy-byte *eax 0/r32/AL
8041 81 4/subop/and %eax 0xff/imm32
8042
8043 3d/compare-eax-and 0x23/imm32/hash
8044 0f 84/jump-if-= loop/disp32
8045
8046 {
8047 $parse-mu:fn:
8048 (slice-equal? %edx "fn")
8049 3d/compare-eax-and 0/imm32/false
8050 0f 84/jump-if-= break/disp32
8051
8052 68/push 0/imm32
8053 68/push 0/imm32
8054 89/<- %esi 4/r32/esp
8055
8056 (allocate Heap *Function-size %esi)
8057
8058 (lookup *esi *(esi+4))
8059
8060 (clear-stack %ebx)
8061
8062 (populate-mu-function-header %ecx %eax %ebx *(ebp+0xc) *(ebp+0x10))
8063 (populate-mu-function-body *(ebp+8) %eax %ebx *(ebp+0xc) *(ebp+0x10))
8064
8065 8b/-> *esi 0/r32/eax
8066 89/<- *edi 0/r32/eax
8067 8b/-> *(esi+4) 0/r32/eax
8068 89/<- *(edi+4) 0/r32/eax
8069
8070
8071 (lookup *esi *(esi+4))
8072
8073 8d/copy-address *(eax+0x20) 7/r32/edi
8074
8075 81 0/subop/add %esp 8/imm32
8076
8077 e9/jump $parse-mu:line-loop/disp32
8078 }
8079
8080
8081 {
8082 $parse-mu:sig:
8083 (slice-equal? %edx "sig")
8084 3d/compare-eax-and 0/imm32/false
8085 0f 84/jump-if-= break/disp32
8086
8087 57/push-edi
8088 8b/-> *(ebp-4) 7/r32/edi
8089
8090 68/push 0/imm32
8091 68/push 0/imm32
8092 89/<- %esi 4/r32/esp
8093
8094 (allocate Heap *Function-size %esi)
8095
8096 (lookup *esi *(esi+4))
8097
8098 (populate-mu-function-signature %ecx %eax *(ebp+0xc) *(ebp+0x10))
8099
8100 8b/-> *esi 0/r32/eax
8101 89/<- *edi 0/r32/eax
8102 8b/-> *(esi+4) 0/r32/eax
8103 89/<- *(edi+4) 0/r32/eax
8104
8105
8106 (lookup *esi *(esi+4))
8107
8108 8d/copy-address *(eax+0x20) 7/r32/edi
8109
8110 81 0/subop/add %esp 8/imm32
8111
8112 89/<- *(ebp-4) 7/r32/edi
8113
8114 5f/pop-to-edi
8115
8116 e9/jump $parse-mu:line-loop/disp32
8117 }
8118
8119 {
8120 $parse-mu:type:
8121 (slice-equal? %edx "type")
8122 3d/compare-eax-and 0/imm32
8123 0f 84/jump-if-= break/disp32
8124 (next-mu-token %ecx %edx)
8125
8126 (pos-or-insert-slice Type-id %edx)
8127
8128 51/push-ecx
8129
8130 68/push 0/imm32
8131 68/push 0/imm32
8132 89/<- %ecx 4/r32/esp
8133 (find-or-create-typeinfo %eax %ecx)
8134
8135 (lookup *ecx *(ecx+4))
8136
8137
8138 (populate-mu-type *(ebp+8) %eax *(ebp+0xc) *(ebp+0x10))
8139
8140
8141 81 0/subop/add %esp 8/imm32
8142
8143 59/pop-to-ecx
8144 e9/jump $parse-mu:line-loop/disp32
8145 }
8146
8147 e9/jump $parse-mu:error1/disp32
8148 }
8149 $parse-mu:end:
8150
8151 81 0/subop/add %esp 0x20c/imm32
8152 81 0/subop/add %esp 0xc08/imm32
8153 81 0/subop/add %esp 8/imm32
8154
8155 5f/pop-to-edi
8156 5e/pop-to-esi
8157 5b/pop-to-ebx
8158 5a/pop-to-edx
8159 59/pop-to-ecx
8160 58/pop-to-eax
8161
8162 81 0/subop/add %esp 4/imm32
8163
8164 89/<- %esp 5/r32/ebp
8165 5d/pop-to-ebp
8166 c3/return
8167
8168 $parse-mu:error1:
8169
8170 (write-buffered *(ebp+0xc) "unexpected top-level command: ")
8171 (write-slice-buffered *(ebp+0xc) %edx)
8172 (write-buffered *(ebp+0xc) "\n")
8173 (flush *(ebp+0xc))
8174 (stop *(ebp+0x10) 1)
8175
8176
8177 $parse-mu:error2:
8178
8179 (write-int32-hex-buffered *(ebp+0xc) *ebx)
8180 (write-buffered *(ebp+0xc) " vars not reclaimed after fn '")
8181 (write-slice-buffered *(ebp+0xc) *eax)
8182 (write-buffered *(ebp+0xc) "'\n")
8183 (flush *(ebp+0xc))
8184 (stop *(ebp+0x10) 1)
8185
8186
8187
8188
8189
8190
8191
8192
8193
8194
8195
8196
8197
8198
8199
8200
8201 populate-mu-function-header:
8202
8203
8204
8205
8206
8207
8208
8209
8210
8211
8212
8213
8214
8215
8216
8217
8218
8219
8220
8221
8222
8223
8224
8225
8226
8227
8228
8229
8230
8231
8232 55/push-ebp
8233 89/<- %ebp 4/r32/esp
8234
8235 50/push-eax
8236 51/push-ecx
8237 52/push-edx
8238 53/push-ebx
8239 57/push-edi
8240
8241 8b/-> *(ebp+0xc) 7/r32/edi
8242
8243 68/push 0/imm32/end
8244 68/push 0/imm32/start
8245 89/<- %ecx 4/r32/esp
8246
8247 68/push 0/imm32
8248 68/push 0/imm32
8249 89/<- %ebx 4/r32/esp
8250
8251 (next-mu-token *(ebp+8) %ecx)
8252
8253
8254 (slice-empty? %ecx)
8255 3d/compare-eax-and 0/imm32/false
8256 0f 85/jump-if-!= $populate-mu-function-header:error1/disp32
8257
8258 (slice-equal? %ecx "{")
8259 3d/compare-eax-and 0/imm32/false
8260 0f 85/jump-if-!= $populate-mu-function-header:error1/disp32
8261
8262 (slice-equal? %ecx "->")
8263 3d/compare-eax-and 0/imm32/false
8264 0f 85/jump-if-!= $populate-mu-function-header:error1/disp32
8265
8266 (slice-equal? %ecx "}")
8267 3d/compare-eax-and 0/imm32/false
8268 0f 85/jump-if-!= $populate-mu-function-header:error1/disp32
8269
8270 (slice-to-string Heap %ecx %edi)
8271
8272 {
8273 $populate-mu-function-header:check-for-inout:
8274 (next-mu-token *(ebp+8) %ecx)
8275
8276 (slice-empty? %ecx)
8277 3d/compare-eax-and 0/imm32/false
8278 0f 85/jump-if-!= $populate-mu-function-header:error1/disp32
8279
8280 (slice-equal? %ecx "{")
8281 3d/compare-eax-and 0/imm32/false
8282 0f 85/jump-if-!= $populate-mu-function-header:done/disp32
8283
8284 (slice-equal? %ecx "->")
8285 3d/compare-eax-and 0/imm32/false
8286 0f 85/jump-if-!= break/disp32
8287
8288 (slice-equal? %ecx "}")
8289 3d/compare-eax-and 0/imm32/false
8290 0f 85/jump-if-!= $populate-mu-function-header:error1/disp32
8291
8292 (parse-var-with-type %ecx *(ebp+8) %ebx *(ebp+0x14) *(ebp+0x18))
8293
8294
8295 (lookup *ebx *(ebx+4))
8296 81 7/subop/compare *(eax+0x18) 0/imm32
8297 0f 85/jump-if-!= $populate-mu-function-header:error2/disp32
8298
8299
8300
8301 8d/copy-address *(edi+8) 0/r32/eax
8302 (append-list Heap *ebx *(ebx+4) *(edi+8) *(edi+0xc) %eax)
8303
8304 (push *(ebp+0x10) *ebx)
8305 (push *(ebp+0x10) *(ebx+4))
8306 (push *(ebp+0x10) 0)
8307
8308 e9/jump loop/disp32
8309 }
8310
8311 {
8312 $populate-mu-function-header:check-for-out:
8313 (next-mu-token *(ebp+8) %ecx)
8314
8315 (slice-empty? %ecx)
8316 3d/compare-eax-and 0/imm32/false
8317 0f 85/jump-if-!= $populate-mu-function-header:error1/disp32
8318
8319 (slice-equal? %ecx "{")
8320 3d/compare-eax-and 0/imm32/false
8321 0f 85/jump-if-!= break/disp32
8322
8323 (slice-equal? %ecx "->")
8324 3d/compare-eax-and 0/imm32/false
8325 0f 85/jump-if-!= $populate-mu-function-header:error1/disp32
8326
8327 (slice-equal? %ecx "}")
8328 3d/compare-eax-and 0/imm32/false
8329 0f 85/jump-if-!= $populate-mu-function-header:error1/disp32
8330
8331 (parse-var-with-type %ecx *(ebp+8) %ebx *(ebp+0x14) *(ebp+0x18))
8332
8333
8334 (lookup *ebx *(ebx+4))
8335 81 7/subop/compare *(eax+0x18) 0/imm32
8336 0f 84/jump-if-= $populate-mu-function-header:error3/disp32
8337
8338 8d/copy-address *(edi+0x10) 0/r32/eax
8339 (append-list Heap *ebx *(ebx+4) *(edi+0x10) *(edi+0x14) %eax)
8340
8341 e9/jump loop/disp32
8342 }
8343 $populate-mu-function-header:done:
8344 (check-no-tokens-left *(ebp+8))
8345 $populate-mu-function-header:end:
8346
8347 81 0/subop/add %esp 0x10/imm32
8348
8349 5f/pop-to-edi
8350 5b/pop-to-ebx
8351 5a/pop-to-edx
8352 59/pop-to-ecx
8353 58/pop-to-eax
8354
8355 89/<- %esp 5/r32/ebp
8356 5d/pop-to-ebp
8357 c3/return
8358
8359 $populate-mu-function-header:error1:
8360
8361 (write-buffered *(ebp+0x14) "function header not in form 'fn <name> [inouts] [-> outputs] {' -- '")
8362 (flush *(ebp+0x14))
8363 (rewind-stream *(ebp+8))
8364 (write-stream-data *(ebp+0x14) *(ebp+8))
8365 (write-buffered *(ebp+0x14) "'\n")
8366 (flush *(ebp+0x14))
8367 (stop *(ebp+0x18) 1)
8368
8369
8370 $populate-mu-function-header:error2:
8371
8372 (write-buffered *(ebp+0x14) "fn ")
8373 50/push-eax
8374 (lookup *edi *(edi+4))
8375 (write-buffered *(ebp+0x14) %eax)
8376 58/pop-to-eax
8377 (write-buffered *(ebp+0x14) ": function inout '")
8378 (lookup *eax *(eax+4))
8379 (write-buffered *(ebp+0x10) %eax)
8380 (write-buffered *(ebp+0x14) "' cannot be in a register")
8381 (flush *(ebp+0x14))
8382 (stop *(ebp+0x18) 1)
8383
8384
8385 $populate-mu-function-header:error3:
8386
8387 (write-buffered *(ebp+0x14) "fn ")
8388 50/push-eax
8389 (lookup *edi *(edi+4))
8390 (write-buffered *(ebp+0x14) %eax)
8391 58/pop-to-eax
8392 (write-buffered *(ebp+0x14) ": function output '")
8393 (lookup *ebx *(ebx+4))
8394 (lookup *eax *(eax+4))
8395 (write-buffered *(ebp+0x14) %eax)
8396 (write-buffered *(ebp+0x14) "' must be in a register, in instruction '")
8397 (rewind-stream *(ebp+8))
8398 (write-stream-data *(ebp+0x14) *(ebp+8))
8399 (write-buffered *(ebp+0x14) "'\n")
8400 (flush *(ebp+0x14))
8401 (stop *(ebp+0x18) 1)
8402
8403
8404
8405
8406
8407
8408
8409
8410
8411
8412
8413 populate-mu-function-signature:
8414
8415
8416
8417
8418
8419
8420
8421
8422
8423
8424
8425
8426
8427
8428
8429
8430
8431
8432
8433
8434
8435
8436
8437
8438
8439 55/push-ebp
8440 89/<- %ebp 4/r32/esp
8441
8442 50/push-eax
8443 51/push-ecx
8444 52/push-edx
8445 53/push-ebx
8446 57/push-edi
8447
8448 8b/-> *(ebp+0xc) 7/r32/edi
8449
8450 68/push 0/imm32/end
8451 68/push 0/imm32/start
8452 89/<- %ecx 4/r32/esp
8453
8454 68/push 0/imm32
8455 68/push 0/imm32
8456 89/<- %ebx 4/r32/esp
8457
8458 (next-mu-token *(ebp+8) %ecx)
8459
8460
8461 (slice-equal? %ecx "{")
8462 3d/compare-eax-and 0/imm32/false
8463 0f 85/jump-if-!= $populate-mu-function-signature:error1/disp32
8464
8465 (slice-equal? %ecx "->")
8466 3d/compare-eax-and 0/imm32/false
8467 0f 85/jump-if-!= $populate-mu-function-signature:error1/disp32
8468
8469 (slice-equal? %ecx "}")
8470 3d/compare-eax-and 0/imm32/false
8471 0f 85/jump-if-!= $populate-mu-function-signature:error1/disp32
8472
8473 (slice-to-string Heap %ecx %edi)
8474
8475 {
8476 $populate-mu-function-signature:check-for-inout:
8477 (next-mu-token *(ebp+8) %ecx)
8478 (slice-empty? %ecx)
8479 3d/compare-eax-and 0/imm32/false
8480 0f 85/jump-if-!= break/disp32
8481
8482 (slice-equal? %ecx "->")
8483 3d/compare-eax-and 0/imm32/false
8484 0f 85/jump-if-!= break/disp32
8485
8486 (slice-equal? %ecx "{")
8487 3d/compare-eax-and 0/imm32/false
8488 0f 85/jump-if-!= $populate-mu-function-signature:error1/disp32
8489
8490 (slice-equal? %ecx "}")
8491 3d/compare-eax-and 0/imm32/false
8492 0f 85/jump-if-!= $populate-mu-function-signature:error1/disp32
8493
8494 (parse-var-with-type %ecx *(ebp+8) %ebx *(ebp+0x10) *(ebp+0x14))
8495
8496
8497 (lookup *ebx *(ebx+4))
8498 81 7/subop/compare *(eax+0x18) 0/imm32
8499 0f 85/jump-if-!= $populate-mu-function-signature:error2/disp32
8500
8501
8502
8503 8d/copy-address *(edi+8) 0/r32/eax
8504 (append-list Heap *ebx *(ebx+4) *(edi+8) *(edi+0xc) %eax)
8505
8506 e9/jump loop/disp32
8507 }
8508
8509 {
8510 $populate-mu-function-signature:check-for-out:
8511 (next-mu-token *(ebp+8) %ecx)
8512 (slice-empty? %ecx)
8513 3d/compare-eax-and 0/imm32/false
8514 0f 85/jump-if-!= break/disp32
8515
8516 (slice-equal? %ecx "{")
8517 3d/compare-eax-and 0/imm32/false
8518 0f 85/jump-if-!= $populate-mu-function-signature:error1/disp32
8519
8520 (slice-equal? %ecx "->")
8521 3d/compare-eax-and 0/imm32/false
8522 0f 85/jump-if-!= $populate-mu-function-signature:error1/disp32
8523
8524 (slice-equal? %ecx "}")
8525 3d/compare-eax-and 0/imm32/false
8526 0f 85/jump-if-!= $populate-mu-function-signature:error1/disp32
8527
8528 (parse-var-with-type %ecx *(ebp+8) %ebx *(ebp+0x10) *(ebp+0x14))
8529
8530
8531 (lookup *ebx *(ebx+4))
8532 81 7/subop/compare *(eax+0x18) 0/imm32
8533 0f 84/jump-if-= $populate-mu-function-signature:error3/disp32
8534
8535 8d/copy-address *(edi+0x10) 0/r32/eax
8536 (append-list Heap *ebx *(ebx+4) *(edi+0x10) *(edi+0x14) %eax)
8537
8538 e9/jump loop/disp32
8539 }
8540 $populate-mu-function-signature:done:
8541 (check-no-tokens-left *(ebp+8))
8542 $populate-mu-function-signature:end:
8543
8544 81 0/subop/add %esp 0x10/imm32
8545
8546 5f/pop-to-edi
8547 5b/pop-to-ebx
8548 5a/pop-to-edx
8549 59/pop-to-ecx
8550 58/pop-to-eax
8551
8552 89/<- %esp 5/r32/ebp
8553 5d/pop-to-ebp
8554 c3/return
8555
8556 $populate-mu-function-signature:error1:
8557
8558 (write-buffered *(ebp+0x10) "function signature not in form 'fn <name> [inouts] [-> outputs] {' -- '")
8559 (flush *(ebp+0x10))
8560 (rewind-stream *(ebp+8))
8561 (write-stream-data *(ebp+0x10) *(ebp+8))
8562 (write-buffered *(ebp+0x10) "'\n")
8563 (flush *(ebp+0x10))
8564 (stop *(ebp+0x14) 1)
8565
8566
8567 $populate-mu-function-signature:error2:
8568
8569 (write-buffered *(ebp+0x10) "fn ")
8570 50/push-eax
8571 (lookup *edi *(edi+4))
8572 (write-buffered *(ebp+0x10) %eax)
8573 58/pop-to-eax
8574 (write-buffered *(ebp+0x10) ": function inout '")
8575 (lookup *eax *(eax+4))
8576 (write-buffered *(ebp+0x10) %eax)
8577 (write-buffered *(ebp+0x10) "' cannot be in a register")
8578 (flush *(ebp+0x10))
8579 (stop *(ebp+0x14) 1)
8580
8581
8582 $populate-mu-function-signature:error3:
8583
8584 (write-buffered *(ebp+0x10) "fn ")
8585 50/push-eax
8586 (lookup *edi *(edi+4))
8587 (write-buffered *(ebp+0x10) %eax)
8588 58/pop-to-eax
8589 (write-buffered *(ebp+0x10) ": function output '")
8590 (lookup *ebx *(ebx+4))
8591 (lookup *eax *(eax+4))
8592 (write-buffered *(ebp+0x10) %eax)
8593 (write-buffered *(ebp+0x10) "' must be in a register, in instruction '")
8594 (rewind-stream *(ebp+8))
8595 (write-stream-data *(ebp+0x10) *(ebp+8))
8596 (write-buffered *(ebp+0x10) "'\n")
8597 (flush *(ebp+0x10))
8598 (stop *(ebp+0x14) 1)
8599
8600
8601 test-function-header-with-arg:
8602
8603 55/push-ebp
8604 89/<- %ebp 4/r32/esp
8605
8606 8b/-> *Primitive-type-ids 0/r32/eax
8607 89/<- *Type-id 0/r32/eax
8608 (clear-stream _test-input-stream)
8609 (write _test-input-stream "foo n: int {\n")
8610
8611 2b/subtract *Function-size 4/r32/esp
8612 89/<- %ecx 4/r32/esp
8613 (zero-out %ecx *Function-size)
8614
8615 81 5/subop/subtract %esp 0xc0/imm32
8616 68/push 0xc0/imm32/size
8617 68/push 0/imm32/top
8618 89/<- %ebx 4/r32/esp
8619
8620 (populate-mu-function-header _test-input-stream %ecx %ebx Stderr 0)
8621
8622 (lookup *ecx *(ecx+4))
8623 (check-strings-equal %eax "foo" "F - test-function-header-with-arg/name")
8624
8625 (lookup *(ecx+8) *(ecx+0xc))
8626 (lookup *eax *(eax+4))
8627 89/<- %edx 0/r32/eax
8628
8629 (lookup *edx *(edx+4))
8630 (check-strings-equal %eax "n" "F - test-function-header-with-arg/inout:0")
8631
8632 (lookup *(edx+8) *(edx+0xc))
8633 (check-ints-equal *eax 1 "F - test-function-header-with-arg/inout:0/type:0")
8634 (check-ints-equal *(eax+4) 1 "F - test-function-header-with-arg/inout:0/type:1")
8635 (check-ints-equal *(eax+0xc) 0 "F - test-function-header-with-arg/inout:0/type:2")
8636
8637 89/<- %esp 5/r32/ebp
8638 5d/pop-to-ebp
8639 c3/return
8640
8641 test-function-header-with-multiple-args:
8642
8643 55/push-ebp
8644 89/<- %ebp 4/r32/esp
8645
8646 8b/-> *Primitive-type-ids 0/r32/eax
8647 89/<- *Type-id 0/r32/eax
8648 (clear-stream _test-input-stream)
8649 (write _test-input-stream "foo a: int, b: int c: int {\n")
8650
8651 2b/subtract *Function-size 4/r32/esp
8652 89/<- %ecx 4/r32/esp
8653 (zero-out %ecx *Function-size)
8654
8655 81 5/subop/subtract %esp 0xc0/imm32
8656 68/push 0xc0/imm32/size
8657 68/push 0/imm32/top
8658 89/<- %ebx 4/r32/esp
8659
8660 (populate-mu-function-header _test-input-stream %ecx %ebx Stderr 0)
8661
8662 (lookup *ecx *(ecx+4))
8663 (check-strings-equal %eax "foo" "F - test-function-header-with-multiple-args/name")
8664
8665 (lookup *(ecx+8) *(ecx+0xc))
8666 89/<- %edx 0/r32/eax
8667 $test-function-header-with-multiple-args:inout0:
8668
8669 (lookup *edx *(edx+4))
8670 89/<- %ebx 0/r32/eax
8671
8672 (lookup *ebx *(ebx+4))
8673 (check-strings-equal %eax "a" "F - test-function-header-with-multiple-args/inout:0")
8674
8675 (lookup *(ebx+8) *(ebx+0xc))
8676 (check-ints-equal *eax 1 "F - test-function-header-with-multiple-args/inout:0/type:0")
8677 (check-ints-equal *(eax+4) 1 "F - test-function-header-with-multiple-args/inout:0/type:1")
8678 (check-ints-equal *(eax+0xc) 0 "F - test-function-header-with-multiple-args/inout:0/type:2")
8679 $test-function-header-with-multiple-args:inout1:
8680
8681 (lookup *(edx+8) *(edx+0xc))
8682 89/<- %edx 0/r32/eax
8683
8684 (lookup *edx *(edx+4))
8685 89/<- %ebx 0/r32/eax
8686
8687 (lookup *ebx *(ebx+4))
8688 (check-strings-equal %eax "b" "F - test-function-header-with-multiple-args/inout:1")
8689
8690 (lookup *(ebx+8) *(ebx+0xc))
8691 (check-ints-equal *eax 1 "F - test-function-header-with-multiple-args/inout:1/type:0")
8692 (check-ints-equal *(eax+4) 1 "F - test-function-header-with-multiple-args/inout:1/type:1")
8693 (check-ints-equal *(eax+0xc) 0 "F - test-function-header-with-multiple-args/inout:1/type:2")
8694 $test-function-header-with-multiple-args:inout2:
8695
8696 (lookup *(edx+8) *(edx+0xc))
8697 89/<- %edx 0/r32/eax
8698
8699 (lookup *edx *(edx+4))
8700 89/<- %ebx 0/r32/eax
8701
8702 (lookup *ebx *(ebx+4))
8703 (check-strings-equal %eax "c" "F - test-function-header-with-multiple-args/inout:2")
8704
8705 (lookup *(ebx+8) *(ebx+0xc))
8706 (check-ints-equal *eax 1 "F - test-function-header-with-multiple-args/inout:2/type:0")
8707 (check-ints-equal *(eax+4) 1 "F - test-function-header-with-multiple-args/inout:2/type:1")
8708 (check-ints-equal *(eax+0xc) 0 "F - test-function-header-with-multiple-args/inout:2/type:2")
8709
8710 89/<- %esp 5/r32/ebp
8711 5d/pop-to-ebp
8712 c3/return
8713
8714 test-function-header-with-multiple-args-and-outputs:
8715
8716 55/push-ebp
8717 89/<- %ebp 4/r32/esp
8718
8719 8b/-> *Primitive-type-ids 0/r32/eax
8720 89/<- *Type-id 0/r32/eax
8721 (clear-stream _test-input-stream)
8722 (write _test-input-stream "foo a: int, b: int, c: int -> x/ecx: int y/edx: int {\n")
8723
8724 2b/subtract *Function-size 4/r32/esp
8725 89/<- %ecx 4/r32/esp
8726 (zero-out %ecx *Function-size)
8727
8728 81 5/subop/subtract %esp 0xc0/imm32
8729 68/push 0xc0/imm32/size
8730 68/push 0/imm32/top
8731 89/<- %ebx 4/r32/esp
8732
8733 (populate-mu-function-header _test-input-stream %ecx %ebx Stderr 0)
8734
8735 (lookup *ecx *(ecx+4))
8736 (check-strings-equal %eax "foo" "F - test-function-header-with-multiple-args-and-outputs/name")
8737
8738 (lookup *(ecx+8) *(ecx+0xc))
8739 89/<- %edx 0/r32/eax
8740 $test-function-header-with-multiple-args-and-outputs:inout0:
8741
8742 (lookup *edx *(edx+4))
8743 89/<- %ebx 0/r32/eax
8744
8745 (lookup *ebx *(ebx+4))
8746 (check-strings-equal %eax "a" "F - test-function-header-with-multiple-args-and-outputs/inout:0")
8747
8748 (lookup *(ebx+8) *(ebx+0xc))
8749 (check-ints-equal *eax 1 "F - test-function-header-with-multiple-args-and-outputs/inout:0/type:0")
8750 (check-ints-equal *(eax+4) 1 "F - test-function-header-with-multiple-args-and-outputs/inout:0/type:1")
8751 (check-ints-equal *(eax+0xc) 0 "F - test-function-header-with-multiple-args-and-outputs/inout:0/type:2")
8752 $test-function-header-with-multiple-args-and-outputs:inout1:
8753
8754 (lookup *(edx+8) *(edx+0xc))
8755 89/<- %edx 0/r32/eax
8756
8757 (lookup *edx *(edx+4))
8758 89/<- %ebx 0/r32/eax
8759
8760 (lookup *ebx *(ebx+4))
8761 (check-strings-equal %eax "b" "F - test-function-header-with-multiple-args-and-outputs/inout:1")
8762
8763 (lookup *(ebx+8) *(ebx+0xc))
8764 (check-ints-equal *eax 1 "F - test-function-header-with-multiple-args-and-outputs/inout:1/type:0")
8765 (check-ints-equal *(eax+4) 1 "F - test-function-header-with-multiple-args-and-outputs/inout:1/type:1")
8766 (check-ints-equal *(eax+0xc) 0 "F - test-function-header-with-multiple-args-and-outputs/inout:1/type:2")
8767 $test-function-header-with-multiple-args-and-outputs:inout2:
8768
8769 (lookup *(edx+8) *(edx+0xc))
8770 89/<- %edx 0/r32/eax
8771
8772 (lookup *edx *(edx+4))
8773 89/<- %ebx 0/r32/eax
8774
8775 (lookup *ebx *(ebx+4))
8776 (check-strings-equal %eax "c" "F - test-function-header-with-multiple-args-and-outputs/inout:2")
8777
8778 (lookup *(ebx+8) *(ebx+0xc))
8779 (check-ints-equal *eax 1 "F - test-function-header-with-multiple-args-and-outputs/inout:2/type:0")
8780 (check-ints-equal *(eax+4) 1 "F - test-function-header-with-multiple-args-and-outputs/inout:2/type:1")
8781 (check-ints-equal *(eax+0xc) 0 "F - test-function-header-with-multiple-args-and-outputs/inout:2/type:2")
8782 $test-function-header-with-multiple-args-and-outputs:out0:
8783
8784 (lookup *(ecx+0x10) *(ecx+0x14))
8785 89/<- %edx 0/r32/eax
8786
8787 (lookup *edx *(edx+4))
8788 89/<- %ebx 0/r32/eax
8789
8790 (lookup *ebx *(ebx+4))
8791 (check-strings-equal %eax "x" "F - test-function-header-with-multiple-args-and-outputs/output:0")
8792
8793 (lookup *(ebx+0x18) *(ebx+0x1c))
8794 (check-strings-equal %eax "ecx" "F - test-function-header-with-multiple-args-and-outputs/output:0/register")
8795
8796 (lookup *(ebx+8) *(ebx+0xc))
8797 (check-ints-equal *eax 1 "F - test-function-header-with-multiple-args-and-outputs/output:0/type:0")
8798 (check-ints-equal *(eax+4) 1 "F - test-function-header-with-multiple-args-and-outputs/output:0/type:1")
8799 (check-ints-equal *(eax+0xc) 0 "F - test-function-header-with-multiple-args-and-outputs/output:0/type:2")
8800 $test-function-header-with-multiple-args-and-outputs:out1:
8801
8802 (lookup *(edx+8) *(edx+0xc))
8803 89/<- %edx 0/r32/eax
8804
8805 (lookup *edx *(edx+4))
8806 89/<- %ebx 0/r32/eax
8807
8808 (lookup *ebx *(ebx+4))
8809 (check-strings-equal %eax "y" "F - test-function-header-with-multiple-args-and-outputs/output:1")
8810
8811 (lookup *(ebx+0x18) *(ebx+0x1c))
8812 (check-strings-equal %eax "edx" "F - test-function-header-with-multiple-args-and-outputs/output:1/register")
8813
8814 (lookup *(ebx+8) *(ebx+0xc))
8815 (check-ints-equal *eax 1 "F - test-function-header-with-multiple-args-and-outputs/output:1/type:0")
8816 (check-ints-equal *(eax+4) 1 "F - test-function-header-with-multiple-args-and-outputs/output:1/type:1")
8817 (check-ints-equal *(eax+0c) 0 "F - test-function-header-with-multiple-args-and-outputs/output:1/type:2")
8818
8819 89/<- %esp 5/r32/ebp
8820 5d/pop-to-ebp
8821 c3/return
8822
8823
8824
8825
8826
8827
8828
8829
8830 parse-var-with-type:
8831
8832
8833
8834
8835
8836
8837
8838
8839
8840
8841
8842
8843
8844
8845
8846
8847 55/push-ebp
8848 89/<- %ebp 4/r32/esp
8849
8850 50/push-eax
8851 51/push-ecx
8852 52/push-edx
8853 53/push-ebx
8854 56/push-esi
8855 57/push-edi
8856
8857 8b/-> *(ebp+8) 6/r32/esi
8858
8859 8b/-> *(esi+4) 1/r32/ecx
8860 49/decrement-ecx
8861 8a/copy-byte *ecx 1/r32/CL
8862 81 4/subop/and %ecx 0xff/imm32
8863 81 7/subop/compare %ecx 0x3a/imm32/colon
8864 0f 85/jump-if-!= $parse-var-with-type:abort/disp32
8865
8866 ff 1/subop/decrement *(esi+4)
8867
8868 68/push 0/imm32/end
8869 68/push 0/imm32/start
8870 89/<- %ecx 4/r32/esp
8871 $parse-var-with-type:parse-name:
8872 (next-token-from-slice *esi *(esi+4) 0x2f %ecx)
8873 $parse-var-with-type:create-var:
8874
8875 (new-var-from-slice Heap %ecx *(ebp+0x10))
8876
8877 $parse-var-with-type:save-register:
8878
8879 8b/-> *(ebp+0x10) 7/r32/edi
8880 (lookup *edi *(edi+4))
8881 89/<- %edi 0/r32/eax
8882
8883 (next-token-from-slice *(ecx+4) *(esi+4) 0x2f %ecx)
8884
8885 {
8886 $parse-var-with-type:write-register:
8887 (slice-empty? %ecx)
8888 3d/compare-eax-and 0/imm32/false
8889 75/jump-if-!= break/disp8
8890
8891 8d/copy-address *(edi+0x18) 0/r32/eax
8892 (slice-to-string Heap %ecx %eax)
8893 }
8894 $parse-var-with-type:save-type:
8895 8d/copy-address *(edi+8) 0/r32/eax
8896 (parse-type Heap *(ebp+0xc) %eax *(ebp+0x14) *(ebp+0x18))
8897 $parse-var-with-type:end:
8898
8899 81 0/subop/add %esp 8/imm32
8900
8901 5f/pop-to-edi
8902 5e/pop-to-esi
8903 5b/pop-to-ebx
8904 5a/pop-to-edx
8905 59/pop-to-ecx
8906 58/pop-to-eax
8907
8908 89/<- %esp 5/r32/ebp
8909 5d/pop-to-ebp
8910 c3/return
8911
8912 $parse-var-with-type:abort:
8913
8914 (write-buffered *(ebp+0x14) "var should have form 'name: type' in '")
8915 (flush *(ebp+0x14))
8916 (rewind-stream *(ebp+0xc))
8917 (write-stream-data *(ebp+0x14) *(ebp+0xc))
8918 (write-buffered *(ebp+0x14) "'\n")
8919 (flush *(ebp+0x14))
8920 (stop *(ebp+0x18) 1)
8921
8922
8923 parse-type:
8924
8925
8926
8927
8928
8929
8930
8931
8932
8933
8934
8935
8936
8937
8938
8939
8940
8941
8942
8943
8944
8945
8946 55/push-ebp
8947 89/<- %ebp 4/r32/esp
8948
8949 50/push-eax
8950 51/push-ecx
8951 52/push-edx
8952
8953 (zero-out *(ebp+0x10) *Handle-size)
8954
8955 68/push 0/imm32
8956 68/push 0/imm32
8957 89/<- %ecx 4/r32/esp
8958
8959 (next-mu-token *(ebp+0xc) %ecx)
8960
8961
8962
8963
8964
8965 (slice-equal? %ecx "")
8966 3d/compare-eax-and 0/imm32/false
8967 0f 85/jump-if-!= $parse-type:abort/disp32
8968
8969 (slice-equal? %ecx "{")
8970 3d/compare-eax-and 0/imm32/false
8971 0f 85/jump-if-!= $parse-type:abort/disp32
8972
8973 (slice-equal? %ecx "}")
8974 3d/compare-eax-and 0/imm32/false
8975 0f 85/jump-if-!= $parse-type:abort/disp32
8976
8977 (slice-equal? %ecx "->")
8978 3d/compare-eax-and 0/imm32/false
8979 0f 85/jump-if-!= $parse-type:abort/disp32
8980
8981 (slice-equal? %ecx ")")
8982 3d/compare-eax-and 0/imm32/false
8983 0f 85/jump-if-!= $parse-type:end/disp32
8984
8985 (allocate *(ebp+8) *Type-tree-size *(ebp+0x10))
8986
8987 8b/-> *(ebp+0x10) 2/r32/edx
8988 (lookup *edx *(edx+4))
8989 89/<- %edx 0/r32/eax
8990 {
8991
8992 (slice-equal? %ecx "(")
8993 3d/compare-eax-and 0/imm32/false
8994 0f 85/jump-if-!= break/disp32
8995
8996 {
8997 $parse-type:check-for-int:
8998
8999 8b/-> *ecx 0/r32/eax
9000 8a/copy-byte *eax 0/r32/AL
9001 81 4/subop/and %eax 0xff/imm32
9002
9003 (is-decimal-digit? %eax)
9004 3d/compare-eax-and 0/imm32/false
9005 74/jump-if-= break/disp8
9006
9007 (is-hex-int? %ecx)
9008 3d/compare-eax-and 0/imm32/false
9009 74/jump-if-= break/disp8
9010 $parse-type:int:
9011 (check-mu-hex-int %ecx *(ebp+0x14) *(ebp+0x18))
9012 (parse-hex-int-from-slice %ecx)
9013 c7 0/subop/copy *(edx+4) 9/imm32/type-id-array-capacity
9014 89/<- *(edx+8) 0/r32/eax
9015 e9/jump $parse-type:end/disp32
9016 }
9017 $parse-type:atom:
9018
9019 c7 0/subop/copy *edx 1/imm32/true
9020 {
9021 $parse-type:check-for-type-parameter:
9022
9023 8b/-> *ecx 0/r32/eax
9024 8a/copy-byte *eax 0/r32/AL
9025 81 4/subop/and %eax 0xff/imm32
9026
9027 3d/compare-eax-and 0x5f/imm32/_
9028 75/jump-if-!= break/disp8
9029 $parse-type:type-parameter:
9030
9031 c7 0/subop/copy *(edx+4) 0xa/imm32/type-parameter
9032
9033 8d/copy-address *(edx+8) 0/r32/eax
9034 (slice-to-string *(ebp+8) %ecx %eax)
9035 e9/jump $parse-type:end/disp32
9036 }
9037 $parse-type:non-type-parameter:
9038
9039 (pos-or-insert-slice Type-id %ecx)
9040 89/<- *(edx+4) 0/r32/eax
9041 e9/jump $parse-type:end/disp32
9042 }
9043 $parse-type:non-atom:
9044
9045
9046 8d/copy-address *(edx+4) 0/r32/eax
9047 (parse-type *(ebp+8) *(ebp+0xc) %eax *(ebp+0x14) *(ebp+0x18))
9048
9049 8d/copy-address *(edx+0xc) 0/r32/eax
9050 (parse-type-tree *(ebp+8) *(ebp+0xc) %eax *(ebp+0x14) *(ebp+0x18))
9051 $parse-type:end:
9052
9053 81 0/subop/add %esp 8/imm32
9054
9055 5a/pop-to-edx
9056 59/pop-to-ecx
9057 58/pop-to-eax
9058
9059 89/<- %esp 5/r32/ebp
9060 5d/pop-to-ebp
9061 c3/return
9062
9063 $parse-type:abort:
9064
9065 (write-buffered *(ebp+0x14) "unexpected token when parsing type: '")
9066 (write-slice-buffered *(ebp+0x14) %ecx)
9067 (write-buffered *(ebp+0x14) "'\n")
9068 (flush *(ebp+0x14))
9069 (stop *(ebp+0x18) 1)
9070
9071
9072 parse-type-tree:
9073
9074
9075
9076
9077
9078
9079
9080
9081
9082 55/push-ebp
9083 89/<- %ebp 4/r32/esp
9084
9085 50/push-eax
9086 51/push-ecx
9087 52/push-edx
9088
9089 (zero-out *(ebp+0x10) *Handle-size)
9090
9091 68/push 0/imm32
9092 68/push 0/imm32
9093 89/<- %ecx 4/r32/esp
9094
9095 (parse-type *(ebp+8) *(ebp+0xc) %ecx *(ebp+0x14) *(ebp+0x18))
9096
9097 81 7/subop/compare *ecx 0/imm32
9098 74/jump-if-= $parse-type-tree:end/disp8
9099
9100 (allocate *(ebp+8) *Type-tree-size *(ebp+0x10))
9101
9102 8b/-> *(ebp+0x10) 2/r32/edx
9103 (lookup *edx *(edx+4))
9104 89/<- %edx 0/r32/eax
9105
9106 8b/-> *ecx 0/r32/eax
9107 89/<- *(edx+4) 0/r32/eax
9108 8b/-> *(ecx+4) 0/r32/eax
9109 89/<- *(edx+8) 0/r32/eax
9110
9111 8d/copy-address *(edx+0xc) 0/r32/eax
9112 (parse-type-tree *(ebp+8) *(ebp+0xc) %eax *(ebp+0x14) *(ebp+0x18))
9113 $parse-type-tree:end:
9114
9115 81 0/subop/add %esp 8/imm32
9116
9117 5a/pop-to-edx
9118 59/pop-to-ecx
9119 58/pop-to-eax
9120
9121 89/<- %esp 5/r32/ebp
9122 5d/pop-to-ebp
9123 c3/return
9124
9125 next-mu-token:
9126
9127
9128
9129
9130
9131
9132
9133
9134
9135
9136
9137
9138
9139
9140
9141
9142
9143
9144
9145
9146
9147
9148
9149
9150
9151
9152
9153
9154
9155
9156
9157
9158
9159
9160
9161
9162
9163
9164
9165
9166
9167
9168
9169
9170 55/push-ebp
9171 89/<- %ebp 4/r32/esp
9172
9173 50/push-eax
9174 51/push-ecx
9175 56/push-esi
9176 57/push-edi
9177
9178 8b/-> *(ebp+8) 6/r32/esi
9179
9180 8b/-> *(ebp+0xc) 7/r32/edi
9181 $next-mu-token:start:
9182 (skip-chars-matching-whitespace %esi)
9183 $next-mu-token:check0:
9184
9185
9186 8b/-> *(esi+4) 1/r32/ecx
9187
9188 3b/compare<- *esi 1/r32/ecx
9189 c7 0/subop/copy *edi 0/imm32
9190 c7 0/subop/copy *(edi+4) 0/imm32
9191 0f 8d/jump-if->= $next-mu-token:end/disp32
9192
9193 8d/copy-address *(esi+ecx+0xc) 0/r32/eax
9194 89/<- *edi 0/r32/eax
9195
9196 31/xor-with %eax 0/r32/eax
9197 8a/copy-byte *(esi+ecx+0xc) 0/r32/AL
9198 {
9199 $next-mu-token:check-for-comma:
9200
9201 3d/compare-eax-and 0x2c/imm32/comma
9202 75/jump-if-!= break/disp8
9203
9204 ff 0/subop/increment *(esi+4)
9205
9206 e9/jump $next-mu-token:start/disp32
9207 }
9208 {
9209 $next-mu-token:check-for-comment:
9210
9211 3d/compare-eax-and 0x23/imm32/pound
9212 75/jump-if-!= break/disp8
9213
9214 e9/jump $next-mu-token:done/disp32
9215 }
9216 {
9217 $next-mu-token:check-for-string-literal:
9218
9219 3d/compare-eax-and 0x22/imm32/dquote
9220 75/jump-if-!= break/disp8
9221 (skip-string %esi)
9222
9223 e9/jump $next-mu-token:done/disp32
9224 }
9225 {
9226 $next-mu-token:check-for-open-paren:
9227
9228 3d/compare-eax-and 0x28/imm32/open-paren
9229 75/jump-if-!= break/disp8
9230
9231 ff 0/subop/increment *(esi+4)
9232
9233 e9/jump $next-mu-token:done/disp32
9234 }
9235 {
9236 $next-mu-token:check-for-close-paren:
9237
9238 3d/compare-eax-and 0x29/imm32/close-paren
9239 75/jump-if-!= break/disp8
9240
9241 ff 0/subop/increment *(esi+4)
9242
9243 e9/jump $next-mu-token:done/disp32
9244 }
9245 {
9246 $next-mu-token:regular-word-without-metadata:
9247
9248
9249 8b/-> *(esi+4) 1/r32/ecx
9250
9251 3b/compare<- *esi 1/r32/ecx
9252 7d/jump-if->= break/disp8
9253
9254 31/xor-with %eax 0/r32/eax
9255 8a/copy-byte *(esi+ecx+0xc) 0/r32/AL
9256
9257 3d/compare-eax-and 0x20/imm32/space
9258 74/jump-if-= break/disp8
9259
9260 3d/compare-eax-and 0xd/imm32/carriage-return
9261 74/jump-if-= break/disp8
9262
9263 3d/compare-eax-and 0xa/imm32/newline
9264 74/jump-if-= break/disp8
9265
9266 3d/compare-eax-and 0x28/imm32/open-paren
9267 0f 84/jump-if-= break/disp32
9268
9269 3d/compare-eax-and 0x29/imm32/close-paren
9270 0f 84/jump-if-= break/disp32
9271
9272 3d/compare-eax-and 0x2c/imm32/comma
9273 0f 84/jump-if-= break/disp32
9274
9275 ff 0/subop/increment *(esi+4)
9276
9277 e9/jump loop/disp32
9278 }
9279 $next-mu-token:done:
9280
9281 8b/-> *(esi+4) 1/r32/ecx
9282 8d/copy-address *(esi+ecx+0xc) 0/r32/eax
9283 89/<- *(edi+4) 0/r32/eax
9284 $next-mu-token:end:
9285
9286 5f/pop-to-edi
9287 5e/pop-to-esi
9288 59/pop-to-ecx
9289 58/pop-to-eax
9290
9291 89/<- %esp 5/r32/ebp
9292 5d/pop-to-ebp
9293 c3/return
9294
9295 pos-or-insert-slice:
9296
9297 55/push-ebp
9298 89/<- %ebp 4/r32/esp
9299
9300 (pos-slice *(ebp+8) *(ebp+0xc))
9301 3d/compare-eax-and -1/imm32
9302 75/jump-if-!= $pos-or-insert-slice:end/disp8
9303 $pos-or-insert-slice:insert:
9304
9305 68/push 0/imm32
9306 68/push 0/imm32
9307 89/<- %eax 4/r32/esp
9308 (slice-to-string Heap *(ebp+0xc) %eax)
9309
9310 (lookup *eax *(eax+4))
9311 (write-int *(ebp+8) %eax)
9312 (pos-slice *(ebp+8) *(ebp+0xc))
9313 $pos-or-insert-slice:end:
9314
9315 81 0/subop/add %esp 8/imm32
9316
9317 89/<- %esp 5/r32/ebp
9318 5d/pop-to-ebp
9319 c3/return
9320
9321
9322
9323 pos-slice:
9324
9325 55/push-ebp
9326 89/<- %ebp 4/r32/esp
9327
9328 51/push-ecx
9329 52/push-edx
9330 53/push-ebx
9331 56/push-esi
9332
9333
9334
9335
9336
9337 8b/-> *(ebp+8) 6/r32/esi
9338
9339 b9/copy-to-ecx 0/imm32
9340
9341 8d/copy-address *(esi+0xc) 2/r32/edx
9342
9343 8b/-> *esi 3/r32/ebx
9344 8d/copy-address *(esi+ebx+0xc) 3/r32/ebx
9345 {
9346
9347
9348
9349
9350
9351 39/compare %edx 3/r32/ebx
9352 b8/copy-to-eax -1/imm32
9353 73/jump-if-addr>= $pos-slice:end/disp8
9354
9355 (slice-equal? *(ebp+0xc) *edx)
9356 3d/compare-eax-and 0/imm32/false
9357 75/jump-if-!= break/disp8
9358
9359 41/increment-ecx
9360
9361 81 0/subop/add %edx 4/imm32
9362
9363 eb/jump loop/disp8
9364 }
9365
9366 89/<- %eax 1/r32/ecx
9367 $pos-slice:end:
9368
9369
9370
9371
9372 5e/pop-to-esi
9373 5b/pop-to-ebx
9374 5a/pop-to-edx
9375 59/pop-to-ecx
9376
9377 89/<- %esp 5/r32/ebp
9378 5d/pop-to-ebp
9379 c3/return
9380
9381 test-parse-var-with-type:
9382
9383 55/push-ebp
9384 89/<- %ebp 4/r32/esp
9385
9386 8b/-> *Primitive-type-ids 0/r32/eax
9387 89/<- *Type-id 0/r32/eax
9388
9389 b8/copy-to-eax "x:"/imm32
9390 8b/-> *eax 1/r32/ecx
9391 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9392 05/add-to-eax 4/imm32
9393
9394 51/push-ecx
9395 50/push-eax
9396 89/<- %ecx 4/r32/esp
9397
9398 (clear-stream _test-input-stream)
9399 (write _test-input-stream "int")
9400
9401 68/push 0/imm32
9402 68/push 0/imm32
9403 89/<- %edx 4/r32/esp
9404
9405 (parse-var-with-type %ecx _test-input-stream %edx Stderr 0)
9406
9407 (lookup *edx *(edx+4))
9408 89/<- %edx 0/r32/eax
9409
9410 (lookup *edx *(edx+4))
9411 (check-strings-equal %eax "x" "F - test-parse-var-with-type/name")
9412
9413 (lookup *(edx+8) *(edx+0xc))
9414 (check-ints-equal *eax 1 "F - test-parse-var-with-type/type:0")
9415 (check-ints-equal *(eax+4) 1 "F - test-parse-var-with-type/type:1")
9416 (check-ints-equal *(eax+0xc) 0 "F - test-parse-var-with-type/type:2")
9417
9418 89/<- %esp 5/r32/ebp
9419 5d/pop-to-ebp
9420 c3/return
9421
9422 test-parse-var-with-type-and-register:
9423
9424 55/push-ebp
9425 89/<- %ebp 4/r32/esp
9426
9427 8b/-> *Primitive-type-ids 0/r32/eax
9428 89/<- *Type-id 0/r32/eax
9429
9430 b8/copy-to-eax "x/eax:"/imm32
9431 8b/-> *eax 1/r32/ecx
9432 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9433 05/add-to-eax 4/imm32
9434
9435 51/push-ecx
9436 50/push-eax
9437 89/<- %ecx 4/r32/esp
9438
9439 (clear-stream _test-input-stream)
9440 (write _test-input-stream "int")
9441
9442 68/push 0/imm32
9443 68/push 0/imm32
9444 89/<- %edx 4/r32/esp
9445
9446 (parse-var-with-type %ecx _test-input-stream %edx Stderr 0)
9447
9448 (lookup *edx *(edx+4))
9449 89/<- %edx 0/r32/eax
9450
9451 (lookup *edx *(edx+4))
9452 (check-strings-equal %eax "x" "F - test-parse-var-with-type-and-register/name")
9453
9454 (lookup *(edx+0x18) *(edx+0x1c))
9455 (check-strings-equal %eax "eax" "F - test-parse-var-with-type-and-register/register")
9456
9457 (lookup *(edx+8) *(edx+0xc))
9458 (check-ints-equal *eax 1 "F - test-parse-var-with-type-and-register/type:0")
9459 (check-ints-equal *(eax+4) 1 "F - test-parse-var-with-type-and-register/type:1")
9460 (check-ints-equal *(eax+0xc) 0 "F - test-parse-var-with-type-and-register/type:2")
9461
9462 89/<- %esp 5/r32/ebp
9463 5d/pop-to-ebp
9464 c3/return
9465
9466 test-parse-var-with-trailing-characters:
9467
9468 55/push-ebp
9469 89/<- %ebp 4/r32/esp
9470
9471 8b/-> *Primitive-type-ids 0/r32/eax
9472 89/<- *Type-id 0/r32/eax
9473
9474 b8/copy-to-eax "x:"/imm32
9475 8b/-> *eax 1/r32/ecx
9476 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9477 05/add-to-eax 4/imm32
9478
9479 51/push-ecx
9480 50/push-eax
9481 89/<- %ecx 4/r32/esp
9482
9483 (clear-stream _test-input-stream)
9484 (write _test-input-stream "int,")
9485
9486 68/push 0/imm32
9487 68/push 0/imm32
9488 89/<- %edx 4/r32/esp
9489
9490 (parse-var-with-type %ecx _test-input-stream %edx Stderr 0)
9491
9492 (lookup *edx *(edx+4))
9493 89/<- %edx 0/r32/eax
9494
9495 (lookup *edx *(edx+4))
9496 (check-strings-equal %eax "x" "F - test-parse-var-with-trailing-characters/name")
9497
9498 (check-ints-equal *(edx+0x18) 0 "F - test-parse-var-with-trailing-characters/register")
9499
9500 (lookup *(edx+8) *(edx+0xc))
9501 (check-ints-equal *eax 1 "F - test-parse-var-with-trailing-characters/type:0")
9502 (check-ints-equal *(eax+4) 1 "F - test-parse-var-with-trailing-characters/type:1")
9503 (check-ints-equal *(eax+0xc) 0 "F - test-parse-var-with-trailing-characters/type:1")
9504
9505 89/<- %esp 5/r32/ebp
9506 5d/pop-to-ebp
9507 c3/return
9508
9509 test-parse-var-with-register-and-trailing-characters:
9510
9511 55/push-ebp
9512 89/<- %ebp 4/r32/esp
9513
9514 8b/-> *Primitive-type-ids 0/r32/eax
9515 89/<- *Type-id 0/r32/eax
9516
9517 b8/copy-to-eax "x/eax:"/imm32
9518 8b/-> *eax 1/r32/ecx
9519 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9520 05/add-to-eax 4/imm32
9521
9522 51/push-ecx
9523 50/push-eax
9524 89/<- %ecx 4/r32/esp
9525
9526 (clear-stream _test-input-stream)
9527 (write _test-input-stream "int,")
9528
9529 68/push 0/imm32
9530 68/push 0/imm32
9531 89/<- %edx 4/r32/esp
9532
9533 (parse-var-with-type %ecx _test-input-stream %edx Stderr 0)
9534
9535 (lookup *edx *(edx+4))
9536 89/<- %edx 0/r32/eax
9537
9538 (lookup *edx *(edx+4))
9539 (check-strings-equal %eax "x" "F - test-parse-var-with-register-and-trailing-characters/name")
9540
9541 (lookup *(edx+0x18) *(edx+0x1c))
9542 (check-strings-equal %eax "eax" "F - test-parse-var-with-register-and-trailing-characters/register")
9543
9544 (lookup *(edx+8) *(edx+0xc))
9545 (check-ints-equal *eax 1 "F - test-parse-var-with-register-and-trailing-characters/type:0")
9546 (check-ints-equal *(eax+4) 1 "F - test-parse-var-with-register-and-trailing-characters/type:1")
9547 (check-ints-equal *(eax+0xc) 0 "F - test-parse-var-with-register-and-trailing-characters/type:2")
9548
9549 89/<- %esp 5/r32/ebp
9550 5d/pop-to-ebp
9551 c3/return
9552
9553 test-parse-var-with-compound-type:
9554
9555 55/push-ebp
9556 89/<- %ebp 4/r32/esp
9557
9558 8b/-> *Primitive-type-ids 0/r32/eax
9559 89/<- *Type-id 0/r32/eax
9560
9561 b8/copy-to-eax "x:"/imm32
9562 8b/-> *eax 1/r32/ecx
9563 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9564 05/add-to-eax 4/imm32
9565
9566 51/push-ecx
9567 50/push-eax
9568 89/<- %ecx 4/r32/esp
9569
9570 (clear-stream _test-input-stream)
9571 (write _test-input-stream "(addr int)")
9572
9573 68/push 0/imm32
9574 68/push 0/imm32
9575 89/<- %edx 4/r32/esp
9576
9577 (parse-var-with-type %ecx _test-input-stream %edx Stderr 0)
9578
9579 (lookup *edx *(edx+4))
9580 89/<- %edx 0/r32/eax
9581
9582 (lookup *edx *(edx+4))
9583 (check-strings-equal %eax "x" "F - test-parse-var-with-compound-type/name")
9584
9585 (check-ints-equal *(edx+0x18) 0 "F - test-parse-var-with-compound-type/register")
9586
9587
9588 (lookup *(edx+8) *(edx+0xc))
9589 89/<- %edx 0/r32/eax
9590
9591 (check-ints-equal *edx 0 "F - test-parse-var-with-compound-type/type:0")
9592
9593 (lookup *(edx+4) *(edx+8))
9594 (check-ints-equal *eax 1 "F - test-parse-var-with-compound-type/type:1")
9595 (check-ints-equal *(eax+4) 2 "F - test-parse-var-with-compound-type/type:2")
9596
9597 (lookup *(edx+0xc) *(edx+0x10))
9598 (lookup *(eax+4) *(eax+8))
9599 (check-ints-equal *eax 1 "F - test-parse-var-with-compound-type/type:3")
9600 (check-ints-equal *(eax+4) 1 "F - test-parse-var-with-compound-type/type:4")
9601
9602 (check-ints-equal *(eax+0xc) 0 "F - test-parse-var-with-compound-type/type:5")
9603
9604 89/<- %esp 5/r32/ebp
9605 5d/pop-to-ebp
9606 c3/return
9607
9608
9609
9610
9611 is-identifier?:
9612
9613 55/push-ebp
9614 89/<- %ebp 4/r32/esp
9615
9616 (slice-empty? *(ebp+8))
9617 3d/compare-eax-and 0/imm32/false
9618 75/jump-if-!= $is-identifier?:false/disp8
9619
9620 8b/-> *(ebp+8) 0/r32/eax
9621 8b/-> *eax 0/r32/eax
9622 8a/copy-byte *eax 0/r32/AL
9623 81 4/subop/and %eax 0xff/imm32
9624
9625 3d/compare-eax-and 0x24/imm32/$
9626 74/jump-if-= $is-identifier?:true/disp8
9627
9628 3d/compare-eax-and 0x5f/imm32/_
9629 74/jump-if-= $is-identifier?:true/disp8
9630
9631 25/and-eax-with 0x5f/imm32
9632
9633 3d/compare-eax-and 0x41/imm32/A
9634 7c/jump-if-< $is-identifier?:false/disp8
9635
9636 3d/compare-eax-and 0x5a/imm32/Z
9637 7f/jump-if-> $is-identifier?:false/disp8
9638
9639 $is-identifier?:true:
9640 b8/copy-to-eax 1/imm32/true
9641 eb/jump $is-identifier?:end/disp8
9642 $is-identifier?:false:
9643 b8/copy-to-eax 0/imm32/false
9644 $is-identifier?:end:
9645
9646 89/<- %esp 5/r32/ebp
9647 5d/pop-to-ebp
9648 c3/return
9649
9650 test-is-identifier-dollar:
9651
9652 55/push-ebp
9653 89/<- %ebp 4/r32/esp
9654
9655 b8/copy-to-eax "$a"/imm32
9656 8b/-> *eax 1/r32/ecx
9657 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9658 05/add-to-eax 4/imm32
9659
9660 51/push-ecx
9661 50/push-eax
9662 89/<- %ecx 4/r32/esp
9663
9664 (is-identifier? %ecx)
9665 (check-ints-equal %eax 1 "F - test-is-identifier-dollar")
9666
9667 89/<- %esp 5/r32/ebp
9668 5d/pop-to-ebp
9669 c3/return
9670
9671 test-is-identifier-underscore:
9672
9673 55/push-ebp
9674 89/<- %ebp 4/r32/esp
9675
9676 b8/copy-to-eax "_a"/imm32
9677 8b/-> *eax 1/r32/ecx
9678 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9679 05/add-to-eax 4/imm32
9680
9681 51/push-ecx
9682 50/push-eax
9683 89/<- %ecx 4/r32/esp
9684
9685 (is-identifier? %ecx)
9686 (check-ints-equal %eax 1 "F - test-is-identifier-underscore")
9687
9688 89/<- %esp 5/r32/ebp
9689 5d/pop-to-ebp
9690 c3/return
9691
9692 test-is-identifier-a:
9693
9694 55/push-ebp
9695 89/<- %ebp 4/r32/esp
9696
9697 b8/copy-to-eax "a$"/imm32
9698 8b/-> *eax 1/r32/ecx
9699 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9700 05/add-to-eax 4/imm32
9701
9702 51/push-ecx
9703 50/push-eax
9704 89/<- %ecx 4/r32/esp
9705
9706 (is-identifier? %ecx)
9707 (check-ints-equal %eax 1 "F - test-is-identifier-a")
9708
9709 89/<- %esp 5/r32/ebp
9710 5d/pop-to-ebp
9711 c3/return
9712
9713 test-is-identifier-z:
9714
9715 55/push-ebp
9716 89/<- %ebp 4/r32/esp
9717
9718 b8/copy-to-eax "z$"/imm32
9719 8b/-> *eax 1/r32/ecx
9720 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9721 05/add-to-eax 4/imm32
9722
9723 51/push-ecx
9724 50/push-eax
9725 89/<- %ecx 4/r32/esp
9726
9727 (is-identifier? %ecx)
9728 (check-ints-equal %eax 1 "F - test-is-identifier-z")
9729
9730 89/<- %esp 5/r32/ebp
9731 5d/pop-to-ebp
9732 c3/return
9733
9734 test-is-identifier-A:
9735
9736 55/push-ebp
9737 89/<- %ebp 4/r32/esp
9738
9739 b8/copy-to-eax "A$"/imm32
9740 8b/-> *eax 1/r32/ecx
9741 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9742 05/add-to-eax 4/imm32
9743
9744 51/push-ecx
9745 50/push-eax
9746 89/<- %ecx 4/r32/esp
9747
9748 (is-identifier? %ecx)
9749 (check-ints-equal %eax 1 "F - test-is-identifier-A")
9750
9751 89/<- %esp 5/r32/ebp
9752 5d/pop-to-ebp
9753 c3/return
9754
9755 test-is-identifier-Z:
9756
9757 55/push-ebp
9758 89/<- %ebp 4/r32/esp
9759
9760 b8/copy-to-eax "Z$"/imm32
9761 8b/-> *eax 1/r32/ecx
9762 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9763 05/add-to-eax 4/imm32
9764
9765 51/push-ecx
9766 50/push-eax
9767 89/<- %ecx 4/r32/esp
9768
9769 (is-identifier? %ecx)
9770 (check-ints-equal %eax 1 "F - test-is-identifier-Z")
9771
9772 89/<- %esp 5/r32/ebp
9773 5d/pop-to-ebp
9774 c3/return
9775
9776 test-is-identifier-at:
9777
9778
9779 55/push-ebp
9780 89/<- %ebp 4/r32/esp
9781
9782 b8/copy-to-eax "@a"/imm32
9783 8b/-> *eax 1/r32/ecx
9784 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9785 05/add-to-eax 4/imm32
9786
9787 51/push-ecx
9788 50/push-eax
9789 89/<- %ecx 4/r32/esp
9790
9791 (is-identifier? %ecx)
9792 (check-ints-equal %eax 0 "F - test-is-identifier-@")
9793
9794 89/<- %esp 5/r32/ebp
9795 5d/pop-to-ebp
9796 c3/return
9797
9798 test-is-identifier-square-bracket:
9799
9800
9801 55/push-ebp
9802 89/<- %ebp 4/r32/esp
9803
9804 b8/copy-to-eax "[a"/imm32
9805 8b/-> *eax 1/r32/ecx
9806 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9807 05/add-to-eax 4/imm32
9808
9809 51/push-ecx
9810 50/push-eax
9811 89/<- %ecx 4/r32/esp
9812
9813 (is-identifier? %ecx)
9814 (check-ints-equal %eax 0 "F - test-is-identifier-@")
9815
9816 89/<- %esp 5/r32/ebp
9817 5d/pop-to-ebp
9818 c3/return
9819
9820 test-is-identifier-backtick:
9821
9822
9823 55/push-ebp
9824 89/<- %ebp 4/r32/esp
9825
9826 b8/copy-to-eax "`a"/imm32
9827 8b/-> *eax 1/r32/ecx
9828 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9829 05/add-to-eax 4/imm32
9830
9831 51/push-ecx
9832 50/push-eax
9833 89/<- %ecx 4/r32/esp
9834
9835 (is-identifier? %ecx)
9836 (check-ints-equal %eax 0 "F - test-is-identifier-backtick")
9837
9838 89/<- %esp 5/r32/ebp
9839 5d/pop-to-ebp
9840 c3/return
9841
9842 test-is-identifier-curly-brace-open:
9843
9844
9845 55/push-ebp
9846 89/<- %ebp 4/r32/esp
9847
9848 b8/copy-to-eax "{a"/imm32
9849 8b/-> *eax 1/r32/ecx
9850 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9851 05/add-to-eax 4/imm32
9852
9853 51/push-ecx
9854 50/push-eax
9855 89/<- %ecx 4/r32/esp
9856
9857 (is-identifier? %ecx)
9858 (check-ints-equal %eax 0 "F - test-is-identifier-curly-brace-open")
9859
9860 89/<- %esp 5/r32/ebp
9861 5d/pop-to-ebp
9862 c3/return
9863
9864 test-is-identifier-curly-brace-close:
9865
9866 55/push-ebp
9867 89/<- %ebp 4/r32/esp
9868
9869 b8/copy-to-eax "}a"/imm32
9870 8b/-> *eax 1/r32/ecx
9871 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9872 05/add-to-eax 4/imm32
9873
9874 51/push-ecx
9875 50/push-eax
9876 89/<- %ecx 4/r32/esp
9877
9878 (is-identifier? %ecx)
9879 (check-ints-equal %eax 0 "F - test-is-identifier-curly-brace-close")
9880
9881 89/<- %esp 5/r32/ebp
9882 5d/pop-to-ebp
9883 c3/return
9884
9885 test-is-identifier-hyphen:
9886
9887
9888 55/push-ebp
9889 89/<- %ebp 4/r32/esp
9890
9891 b8/copy-to-eax "-a"/imm32
9892 8b/-> *eax 1/r32/ecx
9893 8d/copy-address *(eax+ecx+4) 1/r32/ecx
9894 05/add-to-eax 4/imm32
9895
9896 51/push-ecx
9897 50/push-eax
9898 89/<- %ecx 4/r32/esp
9899
9900 (is-identifier? %ecx)
9901 (check-ints-equal %eax 0 "F - test-is-identifier-hyphen")
9902
9903 89/<- %esp 5/r32/ebp
9904 5d/pop-to-ebp
9905 c3/return
9906
9907 populate-mu-function-body:
9908
9909 55/push-ebp
9910 89/<- %ebp 4/r32/esp
9911
9912 50/push-eax
9913 56/push-esi
9914 57/push-edi
9915
9916 8b/-> *(ebp+8) 6/r32/esi
9917
9918 8b/-> *(ebp+0xc) 7/r32/edi
9919
9920 c7 0/subop/copy *Curr-block-depth 1/imm32
9921
9922 8d/copy-address *(edi+0x18) 0/r32/eax
9923 (parse-mu-block %esi *(ebp+0x10) %edi %eax *(ebp+0x14) *(ebp+0x18))
9924 $populate-mu-function-body:end:
9925
9926 5f/pop-to-edi
9927 5e/pop-to-esi
9928 58/pop-to-eax
9929
9930 89/<- %esp 5/r32/ebp
9931 5d/pop-to-ebp
9932 c3/return
9933
9934
9935 parse-mu-block:
9936
9937
9938
9939
9940
9941
9942
9943
9944
9945
9946
9947
9948
9949
9950
9951
9952
9953
9954
9955
9956
9957
9958
9959
9960
9961
9962
9963
9964
9965
9966
9967
9968
9969
9970
9971
9972
9973 55/push-ebp
9974 89/<- %ebp 4/r32/esp
9975
9976 50/push-eax
9977 51/push-ecx
9978 52/push-edx
9979 53/push-ebx
9980 57/push-edi
9981
9982 81 5/subop/subtract %esp 0x200/imm32
9983 68/push 0x200/imm32/size
9984 68/push 0/imm32/read
9985 68/push 0/imm32/write
9986 89/<- %ecx 4/r32/esp
9987
9988 68/push 0/imm32/end
9989 68/push 0/imm32/start
9990 89/<- %edx 4/r32/esp
9991
9992 (allocate Heap *Stmt-size *(ebp+0x14))
9993
9994 8b/-> *(ebp+0x14) 7/r32/edi
9995 (lookup *edi *(edi+4))
9996 89/<- %edi 0/r32/eax
9997
9998
9999 8d/copy-address *(edi+0xc) 0/r32/eax
10000 (new-block-name *(ebp+0x10) %eax)
10001
10002 (push *(ebp+0xc) *(edi+0xc))
10003 (push *(ebp+0xc) *(edi+0x10))
10004 (push *(ebp+0xc) 0)
10005
10006 ff 0/subop/increment *Curr-block-depth
10007 {
10008 $parse-mu-block:line-loop:
10009
10010 (clear-stream %ecx)
10011 (read-line-buffered *(ebp+8) %ecx)
10012
10013
10014
10015
10016
10017
10018 81 7/subop/compare *ecx 0/imm32
10019 0f 84/jump-if-= break/disp32
10020
10021
10022
10023 (next-mu-token %ecx %edx)
10024
10025
10026
10027
10028
10029 (slice-empty? %edx)
10030 3d/compare-eax-and 0/imm32/false
10031 0f 85/jump-if-!= loop/disp32
10032
10033
10034 8b/-> *edx 0/r32/eax
10035 8a/copy-byte *eax 0/r32/AL
10036 81 4/subop/and %eax 0xff/imm32
10037
10038 3d/compare-eax-and 0x23/imm32/hash
10039 0f 84/jump-if-= loop/disp32
10040
10041 {
10042 $parse-mu-block:check-for-block:
10043 (slice-equal? %edx "{")
10044 3d/compare-eax-and 0/imm32/false
10045 74/jump-if-= break/disp8
10046 (check-no-tokens-left %ecx)
10047
10048
10049 68/push 0/imm32
10050 68/push 0/imm32
10051 89/<- %eax 4/r32/esp
10052
10053 (parse-mu-block *(ebp+8) *(ebp+0xc) *(ebp+0x10) %eax *(ebp+0x18) *(ebp+0x1c))
10054 (append-to-block Heap %edi *eax *(eax+4))
10055
10056 81 0/subop/add %esp 8/imm32
10057
10058 e9/jump $parse-mu-block:line-loop/disp32
10059 }
10060
10061 $parse-mu-block:check-for-end:
10062 (slice-equal? %edx "}")
10063 3d/compare-eax-and 0/imm32/false
10064 0f 85/jump-if-!= break/disp32
10065
10066 {
10067 $parse-mu-block:check-for-named-block:
10068
10069 8b/-> *(edx+4) 0/r32/eax
10070 48/decrement-eax
10071 8a/copy-byte *eax 0/r32/AL
10072 81 4/subop/and %eax 0xff/imm32
10073
10074 3d/compare-eax-and 0x3a/imm32/colon
10075 0f 85/jump-if-!= break/disp32
10076
10077
10078
10079 ff 1/subop/decrement *(edx+4)
10080
10081 68/push 0/imm32
10082 68/push 0/imm32
10083 89/<- %eax 4/r32/esp
10084
10085 (parse-mu-named-block %edx *(ebp+8) *(ebp+0xc) *(ebp+0x10) %eax *(ebp+0x18) *(ebp+0x1c))
10086 (append-to-block Heap %edi *eax *(eax+4))
10087
10088 81 0/subop/add %esp 8/imm32
10089
10090 e9/jump $parse-mu-block:line-loop/disp32
10091 }
10092
10093 {
10094 $parse-mu-block:check-for-var:
10095 (slice-equal? %edx "var")
10096 3d/compare-eax-and 0/imm32/false
10097 74/jump-if-= break/disp8
10098
10099 68/push 0/imm32
10100 68/push 0/imm32
10101 89/<- %eax 4/r32/esp
10102
10103 (parse-mu-var-def %ecx *(ebp+0xc) %eax *(ebp+0x10) *(ebp+0x18) *(ebp+0x1c))
10104 (append-to-block Heap %edi *eax *(eax+4))
10105
10106 81 0/subop/add %esp 8/imm32
10107
10108 e9/jump $parse-mu-block:line-loop/disp32
10109 }
10110 $parse-mu-block:regular-stmt:
10111
10112
10113 68/push 0/imm32
10114 68/push 0/imm32
10115 89/<- %eax 4/r32/esp
10116
10117 (parse-mu-stmt %ecx *(ebp+0xc) *(ebp+0x10) %eax *(ebp+0x18) *(ebp+0x1c))
10118 (append-to-block Heap %edi *eax *(eax+4))
10119
10120 81 0/subop/add %esp 8/imm32
10121
10122 e9/jump loop/disp32
10123 }
10124 (clean-up-blocks *(ebp+0xc) *Curr-block-depth *(ebp+0x10))
10125
10126 ff 1/subop/decrement *Curr-block-depth
10127
10128 (pop *(ebp+0xc))
10129 (pop *(ebp+0xc))
10130 (pop *(ebp+0xc))
10131 $parse-mu-block:end:
10132
10133 81 0/subop/add %esp 0x214/imm32
10134
10135 5f/pop-to-edi
10136 5b/pop-to-ebx
10137 5a/pop-to-edx
10138 59/pop-to-ecx
10139 58/pop-to-eax
10140
10141 89/<- %esp 5/r32/ebp
10142 5d/pop-to-ebp
10143 c3/return
10144
10145 $parse-mu-block:abort:
10146
10147 (write-buffered *(ebp+0x18) "'{' or '}' should be on its own line, but got '")
10148 (rewind-stream %ecx)
10149 (write-stream-data *(ebp+0x18) %ecx)
10150 (write-buffered *(ebp+0x18) "'\n")
10151 (flush *(ebp+0x18))
10152 (stop *(ebp+0x1c) 1)
10153
10154
10155 new-block-name:
10156
10157 55/push-ebp
10158 89/<- %ebp 4/r32/esp
10159
10160 50/push-eax
10161 51/push-ecx
10162 52/push-edx
10163
10164 8b/-> *(ebp+8) 0/r32/eax
10165 (lookup *eax *(eax+4))
10166 8b/-> *eax 0/r32/eax
10167 05/add-to-eax 0xd/imm32
10168 89/<- %ecx 0/r32/eax
10169
10170 29/subtract-from %esp 1/r32/ecx
10171 ff 6/subop/push %ecx
10172 68/push 0/imm32/read
10173 68/push 0/imm32/write
10174 89/<- %edx 4/r32/esp
10175 (clear-stream %edx)
10176
10177 8b/-> *(ebp+8) 0/r32/eax
10178 (lookup *eax *(eax+4))
10179
10180 (write %edx "$")
10181 (write %edx %eax)
10182 (write %edx ":")
10183 (write-int32-hex %edx *Next-block-index)
10184 ff 0/subop/increment *Next-block-index
10185
10186
10187 8b/-> *edx 0/r32/eax
10188
10189 8d/copy-address *(edx+0xc) 2/r32/edx
10190
10191 01/add-to %eax 2/r32/edx
10192
10193 ff 6/subop/push %eax
10194 ff 6/subop/push %edx
10195 89/<- %eax 4/r32/esp
10196
10197 (new-literal Heap %eax *(ebp+0xc))
10198
10199
10200
10201
10202
10203
10204
10205 $new-block-name:end:
10206
10207 81 0/subop/add %ecx 0xc/imm32
10208 81 0/subop/add %ecx 8/imm32
10209 01/add-to %esp 1/r32/ecx
10210
10211 5a/pop-to-edx
10212 59/pop-to-ecx
10213 58/pop-to-eax
10214
10215 89/<- %esp 5/r32/ebp
10216 5d/pop-to-ebp
10217 c3/return
10218
10219 check-no-tokens-left:
10220
10221 55/push-ebp
10222 89/<- %ebp 4/r32/esp
10223
10224 50/push-eax
10225 51/push-ecx
10226
10227 68/push 0/imm32/end
10228 68/push 0/imm32/start
10229 89/<- %ecx 4/r32/esp
10230
10231 (next-mu-token *(ebp+8) %ecx)
10232
10233 (slice-empty? %ecx)
10234 3d/compare-eax-and 0/imm32/false
10235 75/jump-if-!= $check-no-tokens-left:end/disp8
10236
10237
10238 8b/-> *edx 0/r32/eax
10239 8a/copy-byte *eax 0/r32/AL
10240 81 4/subop/and %eax 0xff/imm32
10241
10242 3d/compare-eax-and 0x23/imm32/hash
10243 74/jump-if-= $check-no-tokens-left:end/disp8
10244
10245 (write-buffered Stderr "'{' or '}' should be on its own line, but got '")
10246 (rewind-stream %ecx)
10247 (write-stream 2 %ecx)
10248 (write-buffered Stderr "'\n")
10249 (flush Stderr)
10250
10251 bb/copy-to-ebx 1/imm32
10252 e8/call syscall_exit/disp32
10253
10254 $check-no-tokens-left:end:
10255
10256 81 0/subop/add %esp 8/imm32
10257
10258 59/pop-to-ecx
10259 58/pop-to-eax
10260
10261 89/<- %esp 5/r32/ebp
10262 5d/pop-to-ebp
10263 c3/return
10264
10265 parse-mu-named-block:
10266
10267
10268
10269
10270
10271
10272
10273
10274
10275
10276 55/push-ebp
10277 89/<- %ebp 4/r32/esp
10278
10279 50/push-eax
10280 51/push-ecx
10281 57/push-edi
10282
10283 68/push 0/imm32
10284 68/push 0/imm32
10285 89/<- %ecx 4/r32/esp
10286
10287 (new-literal Heap *(ebp+8) %ecx)
10288
10289 (push *(ebp+0x10) *ecx)
10290 (push *(ebp+0x10) *(ecx+4))
10291 (push *(ebp+0x10) 0)
10292
10293 (parse-mu-block *(ebp+0xc) *(ebp+0x10) *(ebp+0x14) *(ebp+0x18) *(ebp+0x1c) *(ebp+0x20))
10294
10295 (pop *(ebp+0x10))
10296 (pop *(ebp+0x10))
10297 (pop *(ebp+0x10))
10298
10299 8b/-> *(ebp+0x18) 7/r32/edi
10300 (lookup *edi *(edi+4))
10301 89/<- %edi 0/r32/eax
10302
10303 c7 0/subop/copy *edi 0/imm32/block
10304
10305 8b/-> *ecx 0/r32/eax
10306 89/<- *(edi+0xc) 0/r32/eax
10307 8b/-> *(ecx+4) 0/r32/eax
10308 89/<- *(edi+0x10) 0/r32/eax
10309 $parse-mu-named-block:end:
10310
10311 81 0/subop/add %esp 8/imm32
10312
10313 5f/pop-to-edi
10314 59/pop-to-ecx
10315 58/pop-to-eax
10316
10317 89/<- %esp 5/r32/ebp
10318 5d/pop-to-ebp
10319 c3/return
10320
10321 parse-mu-var-def:
10322
10323 55/push-ebp
10324 89/<- %ebp 4/r32/esp
10325
10326 50/push-eax
10327 51/push-ecx
10328 52/push-edx
10329 53/push-ebx
10330 57/push-edi
10331
10332 8b/-> *(ebp+0x10) 7/r32/edi
10333
10334 68/push 0/imm32/end
10335 68/push 0/imm32/start
10336 89/<- %ecx 4/r32/esp
10337
10338 68/push 0/imm32
10339 68/push 0/imm32
10340 89/<- %edx 4/r32/esp
10341
10342 (next-mu-token *(ebp+8) %ecx)
10343 (parse-var-with-type %ecx *(ebp+8) %edx *(ebp+0x18) *(ebp+0x1c))
10344
10345 (lookup *edx *(edx+4))
10346
10347 8b/-> *Curr-block-depth 3/r32/ebx
10348 89/<- *(eax+0x10) 3/r32/ebx
10349
10350 8b/-> *(eax+0x18) 0/r32/eax
10351 3d/compare-eax-and 0/imm32
10352 {
10353 75/jump-if-!= break/disp8
10354
10355
10356 (next-mu-token *(ebp+8) %ecx)
10357 (slice-empty? %ecx)
10358 3d/compare-eax-and 0/imm32/false
10359 0f 84/jump-if-= $parse-mu-var-def:error2/disp32
10360
10361 (new-var-def Heap *edx *(edx+4) %edi)
10362 e9/jump $parse-mu-var-def:update-vars/disp32
10363 }
10364
10365 {
10366 0f 84/jump-if-= break/disp32
10367
10368
10369
10370 (next-mu-token *(ebp+8) %ecx)
10371 (slice-equal? %ecx "<-")
10372 3d/compare-eax-and 0/imm32/false
10373 0f 84/jump-if-= $parse-mu-var-def:error1/disp32
10374
10375 (new-reg-var-def Heap *edx *(edx+4) %edi)
10376 (lookup *edi *(edi+4))
10377 (add-operation-and-inputs-to-stmt %eax *(ebp+8) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18) *(ebp+0x1c))
10378 }
10379 $parse-mu-var-def:update-vars:
10380
10381 (push *(ebp+0xc) *edx)
10382 (push *(ebp+0xc) *(edx+4))
10383 (push *(ebp+0xc) 0)
10384 $parse-mu-var-def:end:
10385
10386 81 0/subop/add %esp 0x10/imm32
10387
10388 5f/pop-to-edi
10389 5b/pop-to-ebx
10390 5a/pop-to-edx
10391 59/pop-to-ecx
10392 58/pop-to-eax
10393
10394 89/<- %esp 5/r32/ebp
10395 5d/pop-to-ebp
10396 c3/return
10397
10398 $parse-mu-var-def:error1:
10399 (rewind-stream *(ebp+8))
10400
10401 (write-buffered *(ebp+0x18) "register variable requires a valid instruction to initialize but got '")
10402 (flush *(ebp+0x18))
10403 (write-stream-data *(ebp+0x18) *(ebp+8))
10404 (write-buffered *(ebp+0x18) "'\n")
10405 (flush *(ebp+0x18))
10406 (stop *(ebp+0x1c) 1)
10407
10408
10409 $parse-mu-var-def:error2:
10410 (rewind-stream *(ebp+8))
10411
10412 (write-buffered *(ebp+0x18) "fn ")
10413 8b/-> *(ebp+0x14) 0/r32/eax
10414 (lookup *eax *(eax+4))
10415 (write-buffered *(ebp+0x18) %eax)
10416 (write-buffered *(ebp+0x18) ": var ")
10417
10418 (lookup *edx *(edx+4))
10419 (lookup *eax *(eax+4))
10420 (write-buffered *(ebp+0x18) %eax)
10421 (write-buffered *(ebp+0x18) ": variables on the stack can't take an initializer\n")
10422 (flush *(ebp+0x18))
10423 (stop *(ebp+0x1c) 1)
10424
10425
10426 test-parse-mu-var-def:
10427
10428
10429 55/push-ebp
10430 89/<- %ebp 4/r32/esp
10431
10432 8b/-> *Primitive-type-ids 0/r32/eax
10433 89/<- *Type-id 0/r32/eax
10434 (clear-stream _test-input-stream)
10435 (write _test-input-stream "n: int\n")
10436 c7 0/subop/copy *Curr-block-depth 1/imm32
10437
10438 68/push 0/imm32
10439 68/push 0/imm32
10440 89/<- %esi 4/r32/esp
10441
10442 81 5/subop/subtract %esp 0xc0/imm32
10443 68/push 0xc0/imm32/size
10444 68/push 0/imm32/top
10445 89/<- %ecx 4/r32/esp
10446 (clear-stack %ecx)
10447
10448 (parse-mu-var-def _test-input-stream %ecx %esi 0 Stderr 0)
10449
10450 (lookup *esi *(esi+4))
10451 89/<- %esi 0/r32/eax
10452
10453 (check-ints-equal *esi 2 "F - test-parse-mu-var-def/tag")
10454
10455 (lookup *(esi+4) *(esi+8))
10456 89/<- %ecx 0/r32/eax
10457
10458 (lookup *ecx *(ecx+4))
10459 (check-strings-equal %eax "n" "F - test-parse-mu-var-def/var-name")
10460
10461 (check-ints-equal *(ecx+0x18) 0 "F - test-parse-mu-var-def/var-register")
10462
10463 (check-ints-equal *(ecx+0x10) 1 "F - test-parse-mu-var-def/output-block-depth")
10464
10465 (lookup *(ecx+8) *(ecx+0xc))
10466 (check-ints-equal *eax 1 "F - test-parse-mu-var-def/var-type:0")
10467 (check-ints-equal *(eax+4) 1 "F - test-parse-mu-var-def/var-type:1")
10468 (check-ints-equal *(eax+0xc) 0 "F - test-parse-mu-var-def/var-type:2")
10469
10470 89/<- %esp 5/r32/ebp
10471 5d/pop-to-ebp
10472 c3/return
10473
10474 test-parse-mu-reg-var-def:
10475
10476
10477 55/push-ebp
10478 89/<- %ebp 4/r32/esp
10479
10480 8b/-> *Primitive-type-ids 0/r32/eax
10481 89/<- *Type-id 0/r32/eax
10482 (clear-stream _test-input-stream)
10483 (write _test-input-stream "n/eax: int <- copy 0\n")
10484 c7 0/subop/copy *Curr-block-depth 1/imm32
10485
10486 68/push 0/imm32
10487 68/push 0/imm32
10488 89/<- %esi 4/r32/esp
10489
10490 81 5/subop/subtract %esp 0xc0/imm32
10491 68/push 0xc0/imm32/size
10492 68/push 0/imm32/top
10493 89/<- %ecx 4/r32/esp
10494 (clear-stack %ecx)
10495
10496 (parse-mu-var-def _test-input-stream %ecx %esi 0 Stderr 0)
10497
10498 (lookup *esi *(esi+4))
10499 89/<- %esi 0/r32/eax
10500
10501 (check-ints-equal *esi 3 "F - test-parse-mu-reg-var-def/tag")
10502
10503
10504 (lookup *(esi+0x14) *(esi+0x18))
10505
10506 (check-ints-equal *(eax+8) 0 "F - test-parse-mu-reg-var-def/single-output")
10507
10508 (lookup *eax *(eax+4))
10509
10510 89/<- %ecx 0/r32/eax
10511
10512 (lookup *ecx *(ecx+4))
10513 (check-strings-equal %eax "n" "F - test-parse-mu-reg-var-def/output-name")
10514
10515 (lookup *(ecx+0x18) *(ecx+0x1c))
10516 (check-strings-equal %eax "eax" "F - test-parse-mu-reg-var-def/output-register")
10517
10518 (check-ints-equal *(ecx+0x10) 1 "F - test-parse-mu-reg-var-def/output-block-depth")
10519
10520 (lookup *(ecx+8) *(ecx+0xc))
10521 (check-ints-equal *eax 1 "F - test-parse-mu-reg-var-def/output-type:0")
10522 (check-ints-equal *(eax+4) 1 "F - test-parse-mu-reg-var-def/output-type:1")
10523 (check-ints-equal *(eax+0xc) 0 "F - test-parse-mu-reg-var-def/output-type:2")
10524
10525 89/<- %esp 5/r32/ebp
10526 5d/pop-to-ebp
10527 c3/return
10528
10529 parse-mu-stmt:
10530
10531
10532
10533
10534
10535
10536
10537
10538
10539
10540
10541
10542
10543
10544
10545
10546
10547
10548
10549
10550
10551
10552
10553
10554 55/push-ebp
10555 89/<- %ebp 4/r32/esp
10556
10557 50/push-eax
10558 51/push-ecx
10559 52/push-edx
10560 53/push-ebx
10561 57/push-edi
10562
10563 68/push 0/imm32/end
10564 68/push 0/imm32/start
10565 89/<- %ecx 4/r32/esp
10566
10567 ba/copy-to-edx 0/imm32/false
10568
10569 68/push 0/imm32
10570 68/push 0/imm32
10571 89/<- %ebx 4/r32/esp
10572
10573 (allocate Heap *Stmt-size *(ebp+0x14))
10574
10575 8b/-> *(ebp+0x14) 7/r32/edi
10576 (lookup *edi *(edi+4))
10577 89/<- %edi 0/r32/eax
10578
10579 c7 0/subop/copy *edi 1/imm32/stmt1
10580 {
10581 (stmt-has-outputs? *(ebp+8))
10582 3d/compare-eax-and 0/imm32/false
10583 0f 84/jump-if-= break/disp32
10584 {
10585 $parse-mu-stmt:read-outputs:
10586
10587 (next-mu-token *(ebp+8) %ecx)
10588
10589 (slice-empty? %ecx)
10590 3d/compare-eax-and 0/imm32/false
10591 0f 85/jump-if-!= break/disp32
10592
10593 (slice-equal? %ecx "<-")
10594 3d/compare-eax-and 0/imm32/false
10595 0f 85/jump-if-!= break/disp32
10596
10597 ba/copy-to-edx 0/imm32/false
10598
10599 8b/-> *ecx 0/r32/eax
10600 8a/copy-byte *eax 0/r32/AL
10601 81 4/subop/and %eax 0xff/imm32
10602 3d/compare-eax-and 0x2a/imm32/asterisk
10603 {
10604 75/jump-if-!= break/disp8
10605 ff 0/subop/increment *ecx
10606 ba/copy-to-edx 1/imm32/true
10607 }
10608
10609 (is-identifier? %ecx)
10610 3d/compare-eax-and 0/imm32/false
10611 0f 84/jump-if-= $parse-mu-stmt:abort/disp32
10612
10613 (lookup-var-or-find-in-fn-outputs %ecx *(ebp+0xc) *(ebp+0x10) %ebx *(ebp+0x18) *(ebp+0x1c))
10614 8d/copy-address *(edi+0x14) 0/r32/eax
10615 (append-stmt-var Heap *ebx *(ebx+4) *(edi+0x14) *(edi+0x18) %edx %eax)
10616
10617 e9/jump loop/disp32
10618 }
10619 }
10620 (add-operation-and-inputs-to-stmt %edi *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x18) *(ebp+0x1c))
10621 $parse-mu-stmt:define-outputs:
10622
10623 (lookup *(edi+0x14) *(edi+0x18))
10624 89/<- %edi 0/r32/eax
10625 {
10626 $parse-mu-stmt:define-outputs-loop:
10627
10628 81 7/subop/compare %edi 0/imm32
10629 74/jump-if-= break/disp8
10630
10631 (maybe-define-var *edi *(edi+4) *(ebp+0xc))
10632
10633
10634 (lookup *(edi+8) *(edi+0xc))
10635 89/<- %edi 0/r32/eax
10636
10637 eb/jump loop/disp8
10638 }
10639 $parse-mu-stmt:end:
10640
10641 81 0/subop/add %esp 0x10/imm32
10642
10643 5f/pop-to-edi
10644 5b/pop-to-ebx
10645 5a/pop-to-edx
10646 59/pop-to-ecx
10647 58/pop-to-eax
10648
10649 89/<- %esp 5/r32/ebp
10650 5d/pop-to-ebp
10651 c3/return
10652
10653 $parse-mu-stmt:abort:
10654
10655 (write-buffered *(ebp+0x18) "invalid identifier '")
10656 (write-slice-buffered *(ebp+0x18) %ecx)
10657 (write-buffered *(ebp+0x18) "'\n")
10658 (flush *(ebp+0x18))
10659 (stop *(ebp+0x1c) 1)
10660
10661
10662 add-operation-and-inputs-to-stmt:
10663
10664
10665
10666
10667
10668
10669
10670
10671 55/push-ebp
10672 89/<- %ebp 4/r32/esp
10673
10674 50/push-eax
10675 51/push-ecx
10676 52/push-edx
10677 53/push-ebx
10678 56/push-esi
10679 57/push-edi
10680
10681 8b/-> *(ebp+8) 7/r32/edi
10682
10683 68/push 0/imm32/end
10684 68/push 0/imm32/start
10685 89/<- %ecx 4/r32/esp
10686
10687 ba/copy-to-edx 0/imm32/false
10688
10689 68/push 0/imm32
10690 68/push 0/imm32
10691 89/<- %esi 4/r32/esp
10692 $add-operation-and-inputs-to-stmt:read-operation:
10693 (next-mu-token *(ebp+0xc) %ecx)
10694 8d/copy-address *(edi+4) 0/r32/eax
10695 (slice-to-string Heap %ecx %eax)
10696
10697 (slice-equal? %ecx "get")
10698 89/<- %ebx 0/r32/eax
10699 {
10700 $add-operation-and-inputs-to-stmt:read-inouts:
10701
10702 (next-mu-token *(ebp+0xc) %ecx)
10703
10704 (slice-empty? %ecx)
10705 3d/compare-eax-and 0/imm32/false
10706 0f 85/jump-if-!= break/disp32
10707
10708 (slice-equal? %ecx "<-")
10709 3d/compare-eax-and 0/imm32/false
10710 0f 85/jump-if-!= $add-operation-and-inputs-to-stmt:abort/disp32
10711
10712 {
10713 81 7/subop/compare %ebx 0/imm32/false
10714 74/jump-if-= break/disp8
10715 (lookup *(edi+0xc) *(edi+0x10))
10716 3d/compare-eax-and 0/imm32
10717 74/jump-if-= break/disp8
10718 (lookup-or-create-constant %eax %ecx %esi)
10719
10720
10721
10722
10723
10724
10725
10726
10727
10728
10729 e9/jump $add-operation-and-inputs-to-stmt:save-var/disp32
10730 }
10731
10732 ba/copy-to-edx 0/imm32/false
10733
10734 8b/-> *ecx 0/r32/eax
10735 8a/copy-byte *eax 0/r32/AL
10736 81 4/subop/and %eax 0xff/imm32
10737 3d/compare-eax-and 0x2a/imm32/asterisk
10738 {
10739 75/jump-if-!= break/disp8
10740 $add-operation-and-inputs-to-stmt:inout-is-deref:
10741 ff 0/subop/increment *ecx
10742 ba/copy-to-edx 1/imm32/true
10743 }
10744 (lookup-var-or-literal %ecx *(ebp+0x10) %esi *(ebp+0x14) *(ebp+0x18) *(ebp+0x1c))
10745 $add-operation-and-inputs-to-stmt:save-var:
10746 8d/copy-address *(edi+0xc) 0/r32/eax
10747 (append-stmt-var Heap *esi *(esi+4) *(edi+0xc) *(edi+0x10) %edx %eax)
10748
10749 e9/jump loop/disp32
10750 }
10751 $add-operation-and-inputs-to-stmt:end:
10752
10753 81 0/subop/add %esp 0x10/imm32
10754
10755 5f/pop-to-edi
10756 5e/pop-to-esi
10757 5b/pop-to-ebx
10758 5a/pop-to-edx
10759 59/pop-to-ecx
10760 58/pop-to-eax
10761
10762 89/<- %esp 5/r32/ebp
10763 5d/pop-to-ebp
10764 c3/return
10765
10766 $add-operation-and-inputs-to-stmt:abort:
10767
10768 (write-buffered *(ebp+0x18) "fn ")
10769 8b/-> *(ebp+0x14) 0/r32/eax
10770 (lookup *eax *(eax+4))
10771 (write-buffered *(ebp+0x18) %eax)
10772 (rewind-stream *(ebp+0xc))
10773 (write-buffered *(ebp+0x18) ": invalid identifier in '")
10774 (write-stream-data *(ebp+0x18) *(ebp+0xc))
10775 (write-buffered *(ebp+0x18) "'\n")
10776 (flush *(ebp+0x18))
10777 (stop *(ebp+0x1c) 1)
10778
10779
10780 stmt-has-outputs?:
10781
10782 55/push-ebp
10783 89/<- %ebp 4/r32/esp
10784
10785 51/push-ecx
10786
10787 68/push 0/imm32/end
10788 68/push 0/imm32/start
10789 89/<- %ecx 4/r32/esp
10790
10791 b8/copy-to-eax 0/imm32/false
10792 (rewind-stream *(ebp+8))
10793 {
10794 (next-mu-token *(ebp+8) %ecx)
10795
10796 (slice-empty? %ecx)
10797 3d/compare-eax-and 0/imm32/false
10798 b8/copy-to-eax 0/imm32/false/result
10799 0f 85/jump-if-!= break/disp32
10800
10801
10802 8b/-> *ecx 0/r32/eax
10803 8a/copy-byte *eax 0/r32/AL
10804 81 4/subop/and %eax 0xff/imm32
10805
10806 3d/compare-eax-and 0x23/imm32/hash
10807 b8/copy-to-eax 0/imm32/false/result
10808 0f 84/jump-if-= break/disp32
10809
10810 (slice-equal? %ecx "<-")
10811 3d/compare-eax-and 0/imm32/false
10812 74/jump-if-= loop/disp8
10813 b8/copy-to-eax 1/imm32/true
10814 }
10815 $stmt-has-outputs:end:
10816 (rewind-stream *(ebp+8))
10817
10818 81 0/subop/add %esp 8/imm32
10819
10820 59/pop-to-ecx
10821
10822 89/<- %esp 5/r32/ebp
10823 5d/pop-to-ebp
10824 c3/return
10825
10826
10827
10828 lookup-var-or-literal:
10829
10830 55/push-ebp
10831 89/<- %ebp 4/r32/esp
10832
10833 50/push-eax
10834 51/push-ecx
10835 56/push-esi
10836
10837 8b/-> *(ebp+8) 6/r32/esi
10838
10839 (slice-empty? %esi)
10840 3d/compare-eax-and 0/imm32/false
10841 0f 85/jump-if-!= $lookup-var-or-literal:abort/disp32
10842
10843 8b/-> *esi 1/r32/ecx
10844 8a/copy-byte *ecx 1/r32/CL
10845 81 4/subop/and %ecx 0xff/imm32
10846
10847 {
10848 81 7/subop/compare %ecx 0x2d/imm32/dash
10849 74/jump-if-= $lookup-var-or-literal:literal/disp8
10850 (is-decimal-digit? %ecx)
10851 3d/compare-eax-and 0/imm32/false
10852 74/jump-if-= break/disp8
10853 $lookup-var-or-literal:literal:
10854 (new-literal-integer Heap %esi *(ebp+0x10) *(ebp+0x14) *(ebp+0x18) *(ebp+0x1c))
10855 eb/jump $lookup-var-or-literal:end/disp8
10856 }
10857
10858 {
10859 81 7/subop/compare %ecx 0x22/imm32/dquote
10860 75/jump-if-!= break/disp8
10861 $lookup-var-or-literal:literal-string:
10862 (new-literal Heap %esi *(ebp+0x10))
10863 eb/jump $lookup-var-or-literal:end/disp8
10864 }
10865
10866 {
10867 $lookup-var-or-literal:var:
10868 (lookup-var %esi *(ebp+0xc) *(ebp+0x10) *(ebp+0x14) *(ebp+0x18) *(ebp+0x1c))
10869 }
10870 $lookup-var-or-literal:end:
10871
10872 5e/pop-to-esi
10873 59/pop-to-ecx
10874 58/pop-to-eax
10875
10876 89/<- %esp 5/r32/ebp
10877 5d/pop-to-ebp
10878 c3/return
10879
10880 $lookup-var-or-literal:abort:
10881 (write-buffered *(ebp+0x18) "fn ")
10882 8b/-> *(ebp+0x14) 0/r32/eax
10883 (lookup *eax *(eax+4))
10884 (write-buffered *(ebp+0x18) %eax)
10885 (write-buffered *(ebp+0x18) ": empty variable!")
10886 (flush *(ebp+0x18))
10887 (stop *(ebp+0x1c) 1)
10888
10889
10890
10891 lookup-var:
10892
10893 55/push-ebp
10894 89/<- %ebp 4/r32/esp
10895
10896 50/push-eax
10897
10898 (lookup-var-helper *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14) *(ebp+0x18) *(ebp+0x1c))
10899
10900 8b/-> *(ebp+0x10) 0/r32/eax
10901 81 7/subop/compare *eax 0/imm32
10902 74/jump-if-= $lookup-var:abort/disp8
10903 $lookup-var:end:
10904
10905 58/pop-to-eax
10906
10907 89/<- %esp 5/r32/ebp
10908 5d/pop-to-ebp
10909 c3/return
10910
10911 $lookup-var:abort:
10912 (write-buffered *(ebp+0x18) "fn ")
10913 8b/-> *(ebp+0x14) 0/r32/eax
10914 (lookup *eax *(eax+4))
10915 (write-buffered *(ebp+0x18) %eax)
10916 (write-buffered *(ebp+0x18) ": unknown variable '")
10917 (write-slice-buffered *(ebp+0x18) *(ebp+8))
10918 (write-buffered *(ebp+0x18) "'\n")
10919 (flush *(ebp+0x18))
10920 (stop *(ebp+0x1c) 1)
10921
10922
10923
10924
10925 lookup-var-helper:
10926
10927
10928
10929
10930
10931
10932
10933
10934
10935
10936 55/push-ebp
10937 89/<- %ebp 4/r32/esp
10938
10939 50/push-eax
10940 51/push-ecx
10941 52/push-edx
10942 53/push-ebx
10943 56/push-esi
10944 57/push-edi
10945
10946 (zero-out *(ebp+0x10) *Handle-size)
10947
10948 8b/-> *(ebp+0xc) 6/r32/esi
10949
10950 8b/-> *esi 3/r32/ebx
10951
10952 3b/compare<- *(esi+4) 0/r32/eax
10953 0f 8f/jump-if-> $lookup-var-helper:error1/disp32
10954
10955 8d/copy-address *(esi+8) 2/r32/edx
10956
10957 8d/copy-address *(esi+ebx-4) 3/r32/ebx
10958
10959 68/push 0/imm32
10960 68/push 0/imm32
10961 68/push 0/imm32
10962 68/push 0/imm32
10963 68/push 0/imm32
10964 68/push 0/imm32
10965 68/push 0/imm32
10966 68/push 0/imm32
10967 68/push 0/imm32
10968 68/push 0/imm32
10969 68/push 0/imm32
10970 68/push 0/imm32
10971 68/push 0/imm32
10972 68/push 0/imm32
10973 68/push 0/imm32
10974 68/push 0/imm32
10975 89/<- %edi 4/r32/esp
10976 {
10977 $lookup-var-helper:loop:
10978
10979 39/compare %ebx 2/r32/edx
10980 0f 82/jump-if-addr< break/disp32
10981
10982 (lookup *ebx *(ebx+4))
10983 89/<- %ecx 0/r32/eax
10984
10985 (lookup *ecx *(ecx+4))
10986
10987 (slice-equal? *(ebp+8) %eax)
10988 3d/compare-eax-and 0/imm32/false
10989 {
10990 74/jump-if-= break/disp8
10991 $lookup-var-helper:found:
10992
10993 (lookup *(ecx+0x18) *(ecx+0x1c))
10994 3d/compare-eax-and 0/imm32
10995 {
10996 74/jump-if-= break/disp8
10997 $lookup-var-helper:found-register:
10998
10999 (get Mu-registers-unique %eax 0xc "Mu-registers-unique")
11000 8b/-> *eax 0/r32/eax
11001
11002 8b/-> *(edi+eax<<2) 0/r32/eax
11003 3d/compare-eax-and 0/imm32
11004 0f 85/jump-if-!= $lookup-var-helper:error2/disp32
11005 }
11006 $lookup-var-helper:return:
11007
11008 8b/-> *(ebp+0x10) 6/r32/esi
11009
11010 8b/-> *ebx 0/r32/eax
11011 89/<- *esi 0/r32/eax
11012 8b/-> *(ebx+4) 0/r32/eax
11013 89/<- *(esi+4) 0/r32/eax
11014
11015 eb/jump $lookup-var-helper:end/disp8
11016 }
11017
11018
11019 (lookup *(ecx+0x18) *(ecx+0x1c))
11020
11021 3d/compare-eax-and 0/imm32
11022 74/jump-if-= $lookup-var-helper:continue/disp8
11023
11024 (get Mu-registers-unique %eax 0xc "Mu-registers-unique")
11025 8b/-> *eax 0/r32/eax
11026
11027 89/<- *(edi+eax<<2) 1/r32/ecx
11028 $lookup-var-helper:continue:
11029
11030 81 5/subop/subtract %ebx 0xc/imm32
11031 e9/jump loop/disp32
11032 }
11033 $lookup-var-helper:end:
11034
11035 81 0/subop/add %esp 0x40/imm32
11036
11037 5f/pop-to-edi
11038 5e/pop-to-esi
11039 5b/pop-to-ebx
11040 5a/pop-to-edx
11041 59/pop-to-ecx
11042 58/pop-to-eax
11043
11044 89/<- %esp 5/r32/ebp
11045 5d/pop-to-ebp
11046 c3/return
11047
11048 $lookup-var-helper:error1:
11049 (write-buffered *(ebp+0x18) "fn ")
11050 8b/-> *(ebp+0x14) 0/r32/eax
11051 (lookup *eax *(eax+4))
11052 (write-buffered *(ebp+0x18) %eax)
11053 (write-buffered *(ebp+0x18) ": malformed stack when looking up '")
11054 (write-slice-buffered *(ebp+0x18) *(ebp+8))
11055 (write-buffered *(ebp+0x18) "'\n")
11056 (flush *(ebp+0x18))
11057 (stop *(ebp+0x1c) 1)
11058
11059
11060 $lookup-var-helper:error2:
11061
11062 (write-buffered *(ebp+0x18) "fn ")
11063 50/push-eax
11064 8b/-> *(ebp+0x14) 0/r32/eax
11065 (lookup *eax *(eax+4))
11066 (write-buffered *(ebp+0x18) %eax)
11067 58/pop-eax
11068 (write-buffered *(ebp+0x18) ": register ")
11069 50/push-eax
11070 (lookup *(eax+0x18) *(eax+0x1c))
11071 (write-buffered *(ebp+0x18) %eax)
11072 58/pop-to-eax
11073 (write-buffered *(ebp+0x18) " reads var '")
11074 (write-slice-buffered *(ebp+0x18) *(ebp+8))
11075 (write-buffered *(ebp+0x18) "' after writing var '")
11076 (lookup *eax *(eax+4))
11077 (write-buffered *(ebp+0x18) %eax)
11078 (write-buffered *(ebp+0x18) "'\n")
11079 (flush *(ebp+0x18))
11080 (stop *(ebp+0x1c) 1)
11081
11082
11083 dump-vars:
11084
11085
11086
11087
11088
11089
11090
11091
11092
11093 55/push-ebp
11094 89/<- %ebp 4/r32/esp
11095
11096 52/push-edx
11097 53/push-ebx
11098 56/push-esi
11099
11100 8b/-> *(ebp+8) 6/r32/esi
11101
11102 8b/-> *esi 3/r32/ebx
11103
11104 8d/copy-address *(esi+8) 2/r32/edx
11105
11106 8d/copy-address *(esi+ebx-4) 3/r32/ebx
11107 {
11108 $dump-vars:loop:
11109
11110 39/compare %ebx 2/r32/edx
11111 0f 82/jump-if-addr< break/disp32
11112
11113 (write-buffered Stderr " var@")
11114 (dump-var 2 %ebx)
11115
11116 81 5/subop/subtract %ebx 0xc/imm32
11117 e9/jump loop/disp32
11118 }
11119 $dump-vars:end:
11120
11121 5e/pop-to-esi
11122 5b/pop-to-ebx
11123 5a/pop-to-edx
11124
11125 89/<- %esp 5/r32/ebp
11126 5d/pop-to-ebp
11127 c3/return
11128
11129 == data
11130
11131 Mu-registers:
11132
11133 0xa8/imm32/write
11134 0/imm32/read
11135 0xa8/imm32/length
11136
11137
11138
11139 0x11/imm32/alloc-id $Mu-register-eax/imm32 0/imm32
11140 0x11/imm32/alloc-id $Mu-register-ecx/imm32 1/imm32
11141 0x11/imm32/alloc-id $Mu-register-edx/imm32 2/imm32
11142 0x11/imm32/alloc-id $Mu-register-ebx/imm32 3/imm32
11143 0x11/imm32/alloc-id $Mu-register-esi/imm32 6/imm32
11144 0x11/imm32/alloc-id $Mu-register-edi/imm32 7/imm32
11145
11146 0x11/imm32/alloc-id $Mu-register-xmm0/imm32 0/imm32
11147 0x11/imm32/alloc-id $Mu-register-xmm1/imm32 1/imm32
11148 0x11/imm32/alloc-id $Mu-register-xmm2/imm32 2/imm32
11149 0x11/imm32/alloc-id $Mu-register-xmm3/imm32 3/imm32
11150 0x11/imm32/alloc-id $Mu-register-xmm4/imm32 4/imm32
11151 0x11/imm32/alloc-id $Mu-register-xmm5/imm32 5/imm32
11152 0x11/imm32/alloc-id $Mu-register-xmm6/imm32 6/imm32
11153 0x11/imm32/alloc-id $Mu-register-xmm7/imm32 7/imm32
11154
11155
11156
11157
11158 Mu-registers-unique:
11159
11160 0xa8/imm32/write
11161 0/imm32/read
11162 0xa8/imm32/length
11163
11164
11165 0x11/imm32/alloc-id $Mu-register-eax/imm32 0/imm32
11166 0x11/imm32/alloc-id $Mu-register-ecx/imm32 1/imm32
11167 0x11/imm32/alloc-id $Mu-register-edx/imm32 2/imm32
11168 0x11/imm32/alloc-id $Mu-register-ebx/imm32 3/imm32
11169 0x11/imm32/alloc-id $Mu-register-esi/imm32 6/imm32
11170 0x11/imm32/alloc-id $Mu-register-edi/imm32 7/imm32
11171
11172 0x11/imm32/alloc-id $Mu-register-xmm0/imm32 8/imm32
11173 0x11/imm32/alloc-id $Mu-register-xmm1/imm32 9/imm32
11174 0x11/imm32/alloc-id $Mu-register-xmm2/imm32 0xa/imm32
11175 0x11/imm32/alloc-id $Mu-register-xmm3/imm32 0xb/imm32
11176 0x11/imm32/alloc-id $Mu-register-xmm4/imm32 0xc/imm32
11177 0x11/imm32/alloc-id $Mu-register-xmm5/imm32 0xd/imm32
11178 0x11/imm32/alloc-id $Mu-register-xmm6/imm32 0xe/imm32
11179 0x11/imm32/alloc-id $Mu-register-xmm7/imm32 0xf/imm32
11180
11181 $Mu-register-eax:
11182 0x11/imm32/alloc-id
11183 3/imm32/size
11184 0x65/e 0x61/a 0x78/x
11185
11186 $Mu-register-ecx:
11187 0x11/imm32/alloc-id
11188 3/imm32/size
11189 0x65/e 0x63/c 0x78/x
11190
11191 $Mu-register-edx:
11192 0x11/imm32/alloc-id
11193 3/imm32/size
11194 0x65/e 0x64/d 0x78/x
11195
11196 $Mu-register-ebx:
11197 0x11/imm32/alloc-id
11198 3/imm32/size
11199 0x65/e 0x62/b 0x78/x
11200
11201 $Mu-register-esi:
11202 0x11/imm32/alloc-id
11203 3/imm32/size
11204 0x65/e 0x73/s 0x69/i
11205
11206 $Mu-register-edi:
11207 0x11/imm32/alloc-id
11208 3/imm32/size
11209 0x65/e 0x64/d 0x69/i
11210
11211 $Mu-register-xmm0:
11212 0x11/imm32/alloc-id:fake:payload
11213
11214 0x4/imm32/size
11215 0x78/x 0x6d/m 0x6d/m 0x30/0
11216
11217 $Mu-register-xmm1:
11218 0x11/imm32/alloc-id:fake:payload
11219
11220 0x4/imm32/size
11221 0x78/x 0x6d/m 0x6d/m 0x31/1
11222
11223 $Mu-register-xmm2:
11224 0x11/imm32/alloc-id:fake:payload
11225
11226 0x4/imm32/size
11227 0x78/x 0x6d/m 0x6d/m 0x32/2
11228
11229 $Mu-register-xmm3:
11230 0x11/imm32/alloc-id:fake:payload
11231
11232 0x4/imm32/size
11233 0x78/x 0x6d/m 0x6d/m 0x33/3
11234
11235 $Mu-register-xmm4:
11236 0x11/imm32/alloc-id:fake:payload
11237
11238 0x4/imm32/size
11239 0x78/x 0x6d/m 0x6d/m 0x34/4
11240
11241 $Mu-register-xmm5:
11242 0x11/imm32/alloc-id:fake:payload
11243
11244 0x4/imm32/size
11245 0x78/x 0x6d/m 0x6d/m 0x35/5
11246
11247 $Mu-register-xmm6:
11248 0x11/imm32/alloc-id:fake:payload
11249
11250 0x4/imm32/size
11251 0x78/x 0x6d/m 0x6d/m 0x36/6
11252
11253 $Mu-register-xmm7:
11254 0x11/imm32/alloc-id:fake:payload
11255
11256 0x4/imm32/size
11257 0x78/x 0x6d/m 0x6d/m 0x37/7
11258
11259 == code
11260
11261
11262 lookup-var-or-find-in-fn-outputs:
11263
11264 55/push-ebp
11265 89/<- %ebp 4/r32/esp
11266
11267 50/push-eax
11268
11269 (lookup-var-helper *(ebp+8) *(ebp+0xc) *(ebp+0x14) *(ebp+0x10) *(ebp+0x18) *(ebp+0x1c))
11270 {
11271
11272 8b/-> *(ebp+0x14) 0/r32/eax
11273 81 7/subop/compare *eax 0/imm32
11274 75/jump-if-!= break/disp8
11275
11276 (find-in-function-outputs *(ebp+0x10) *(ebp+8) *(ebp+0x14))
11277 8b/-> *(ebp+0x14) 0/r32/eax
11278 81 7/subop/compare *eax 0/imm32
11279
11280 0f 84/jump-if-= $lookup-or-define-var:abort/disp32
11281 }
11282 $lookup-or-define-var:end:
11283
11284 58/pop-to-eax
11285
11286 89/<- %esp 5/r32/ebp
11287 5d/pop-to-ebp
11288 c3/return
11289
11290 $lookup-or-define-var:abort:
11291 (write-buffered *(ebp+0x18) "unknown variable '")
11292 (write-slice-buffered *(ebp+0x18) *(ebp+8))
11293 (write-buffered *(ebp+0x18) "'\n")
11294 (flush *(ebp+0x18))
11295 (stop *(ebp+0x1c) 1)
11296
11297
11298 find-in-function-outputs:
11299
11300 55/push-ebp
11301 89/<- %ebp 4/r32/esp
11302
11303 50/push-eax
11304 51/push-ecx
11305
11306 8b/-> *(ebp+8) 1/r32/ecx
11307 (lookup *(ecx+0x10) *(ecx+0x14))
11308 89/<- %ecx 0/r32/eax
11309
11310 {
11311 81 7/subop/compare %ecx 0/imm32
11312 74/jump-if-= break/disp8
11313
11314 (lookup *ecx *(ecx+4))
11315
11316 (lookup *eax *(eax+4))
11317
11318 (slice-equal? *(ebp+0xc) %eax)
11319 3d/compare-eax-and 0/imm32/false
11320 {
11321 74/jump-if-= break/disp8
11322
11323 57/push-edi
11324 8b/-> *(ebp+0x10) 7/r32/edi
11325
11326 8b/-> *ecx 0/r32/eax
11327 89/<- *edi 0/r32/eax
11328 8b/-> *(ecx+4) 0/r32/eax
11329 89/<- *(edi+4) 0/r32/eax
11330
11331 5f/pop-to-edi
11332 eb/jump $find-in-function-outputs:end/disp8
11333 }
11334
11335 (lookup *(ecx+8) *(ecx+0xc))
11336 89/<- %ecx 0/r32/eax
11337
11338 eb/jump loop/disp8
11339 }
11340 b8/copy-to-eax 0/imm32
11341 $find-in-function-outputs:end:
11342
11343 59/pop-to-ecx
11344 58/pop-to-eax
11345
11346 89/<- %esp 5/r32/ebp
11347 5d/pop-to-ebp
11348 c3/return
11349
11350
11351 maybe-define-var:
11352
11353 55/push-ebp
11354 89/<- %ebp 4/r32/esp
11355
11356 50/push-eax
11357
11358 (lookup *(ebp+8) *(ebp+0xc))
11359
11360 (binding-exists? %eax *(ebp+0x10))
11361 3d/compare-eax-and 0/imm32/false
11362 75/jump-if-!= $maybe-define-var:end/disp8
11363
11364 (push *(ebp+0x10) *(ebp+8))
11365 (push *(ebp+0x10) *(ebp+0xc))
11366 (push *(ebp+0x10) 0)
11367 $maybe-define-var:end:
11368
11369 58/pop-to-eax
11370
11371 89/<- %esp 5/r32/ebp
11372 5d/pop-to-ebp
11373 c3/return
11374
11375
11376 binding-exists?:
11377
11378
11379
11380
11381
11382
11383
11384
11385
11386
11387
11388 55/push-ebp
11389 89/<- %ebp 4/r32/esp
11390
11391 51/push-ecx
11392 52/push-edx
11393 56/push-esi
11394
11395 8b/-> *(ebp+8) 0/r32/eax
11396 (lookup *eax *(eax+4))
11397 89/<- %ecx 0/r32/eax
11398
11399 8b/-> *(ebp+0xc) 6/r32/esi
11400
11401 8b/-> *esi 0/r32/eax
11402
11403 8d/copy-address *(esi+8) 2/r32/edx
11404
11405 8d/copy-address *(esi+eax-4) 6/r32/esi
11406 {
11407 $binding-exists?:loop:
11408
11409 39/compare %esi 2/r32/edx
11410 0f 82/jump-if-addr< break/disp32
11411
11412 (lookup *esi *(esi+4))
11413
11414 (lookup *eax *(eax+4))
11415
11416 (string-equal? %ecx %eax)
11417 3d/compare-eax-and 0/imm32/false
11418 75/jump-if-!= $binding-exists?:end/disp8
11419
11420 81 5/subop/subtract %esi 0xc/imm32
11421 e9/jump loop/disp32
11422 }
11423 b8/copy-to-eax 0/imm32/false
11424 $binding-exists?:end:
11425
11426 5e/pop-to-esi
11427 5a/pop-to-edx
11428 59/pop-to-ecx
11429
11430 89/<- %esp 5/r32/ebp
11431 5d/pop-to-ebp
11432 c3/return
11433
11434 test-parse-mu-stmt:
11435
11436 55/push-ebp
11437 89/<- %ebp 4/r32/esp
11438
11439 8b/-> *Primitive-type-ids 0/r32/eax
11440 89/<- *Type-id 0/r32/eax
11441 (clear-stream _test-input-stream)
11442 (write _test-input-stream "increment n\n")
11443
11444 81 5/subop/subtract %esp 0xc0/imm32
11445 68/push 0xc0/imm32/size
11446 68/push 0/imm32/top
11447 89/<- %ecx 4/r32/esp
11448 (clear-stack %ecx)
11449
11450 68/push 0/imm32
11451 68/push 0/imm32
11452 89/<- %edx 4/r32/esp
11453
11454 68/push 0/imm32
11455 68/push 0/imm32
11456 89/<- %eax 4/r32/esp
11457
11458 (copy-array Heap "n" %eax)
11459 (new-var Heap *eax *(eax+4) %edx)
11460
11461 (push %ecx *edx)
11462 (push %ecx *(edx+4))
11463 (push %ecx 0)
11464
11465 68/push 0/imm32
11466 68/push 0/imm32
11467 89/<- %eax 4/r32/esp
11468
11469 (parse-mu-stmt _test-input-stream %ecx 0 %eax Stderr 0)
11470
11471 (lookup *eax *(eax+4))
11472 89/<- %edx 0/r32/eax
11473
11474 (check-ints-equal *edx 1 "F - test-parse-mu-stmt/tag")
11475
11476 (lookup *(edx+4) *(edx+8))
11477 (check-strings-equal %eax "increment" "F - test-parse-mu-stmt/name")
11478
11479
11480 (lookup *(edx+0xc) *(edx+0x10))
11481
11482 (lookup *eax *(eax+4))
11483
11484 (lookup *eax *(eax+4))
11485
11486 (check-strings-equal %eax "n" "F - test-parse-mu-stmt/inout:0")
11487
11488 89/<- %esp 5/r32/ebp
11489 5d/pop-to-ebp
11490 c3/return
11491
11492 test-parse-mu-stmt-with-comma:
11493
11494 55/push-ebp
11495 89/<- %ebp 4/r32/esp
11496
11497 8b/-> *Primitive-type-ids 0/r32/eax
11498 89/<- *Type-id 0/r32/eax
11499 (clear-stream _test-input-stream)
11500 (write _test-input-stream "copy-to n, 3\n")
11501
11502 81 5/subop/subtract %esp 0xc0/imm32
11503 68/push 0xc0/imm32/size
11504 68/push 0/imm32/top
11505 89/<- %ecx 4/r32/esp
11506 (clear-stack %ecx)
11507
11508 68/push 0/imm32
11509 68/push 0/imm32
11510 89/<- %edx 4/r32/esp
11511
11512 68/push 0/imm32
11513 68/push 0/imm32
11514 89/<- %eax 4/r32/esp
11515
11516 (copy-array Heap "n" %eax)
11517 (new-var Heap *eax *(eax+4) %edx)
11518
11519 (push %ecx *edx)
11520 (push %ecx *(edx+4))
11521 (push %ecx 0)
11522
11523 68/push 0/imm32
11524 68/push 0/imm32
11525 89/<- %eax 4/r32/esp
11526
11527 (parse-mu-stmt _test-input-stream %ecx 0 %eax Stderr 0)
11528
11529 (lookup *eax *(eax+4))
11530 89/<- %edx 0/r32/eax
11531
11532 (check-ints-equal *edx 1 "F - test-parse-mu-stmt-with-comma/tag")
11533
11534 (lookup *(edx+4) *(edx+8))
11535 (check-strings-equal %eax "copy-to" "F - test-parse-mu-stmt-with-comma/name")
11536
11537
11538 (lookup *(edx+0xc) *(edx+0x10))
11539
11540 (lookup *eax *(eax+4))
11541
11542 (lookup *eax *(eax+4))
11543
11544 (check-strings-equal %eax "n" "F - test-parse-mu-stmt-with-comma/inout:0")
11545
11546 89/<- %esp 5/r32/ebp
11547 5d/pop-to-ebp
11548 c3/return
11549
11550 new-var:
11551
11552 55/push-ebp
11553 89/<- %ebp 4/r32/esp
11554
11555 50/push-eax
11556 51/push-ecx
11557
11558 8b/-> *(ebp+0x14) 1/r32/ecx
11559
11560 (allocate *(ebp+8) *Var-size %ecx)
11561
11562 (lookup *ecx *(ecx+4))
11563
11564 8b/-> *(ebp+0xc) 1/r32/ecx
11565 89/<- *eax 1/r32/ecx
11566 8b/-> *(ebp+0x10) 1/r32/ecx
11567 89/<- *(eax+4) 1/r32/ecx
11568
11569
11570
11571
11572
11573
11574
11575
11576
11577 $new-var:end:
11578
11579 59/pop-to-ecx
11580 58/pop-to-eax
11581
11582 89/<- %esp 5/r32/ebp
11583 5d/pop-to-ebp
11584 c3/return
11585
11586 new-literal-integer:
11587
11588 55/push-ebp
11589 89/<- %ebp 4/r32/esp
11590
11591 50/push-eax
11592 51/push-ecx
11593
11594 (is-hex-int? *(ebp+0xc))
11595 3d/compare-eax-and 0/imm32/false
11596 0f 84/jump-if-= $new-literal-integer:abort/disp32
11597
11598 (check-mu-hex-int *(ebp+0xc) *(ebp+0x18) *(ebp+0x1c))
11599
11600 (new-var-from-slice *(ebp+8) *(ebp+0xc) *(ebp+0x10))
11601
11602 8b/-> *(ebp+0x10) 0/r32/eax
11603 (lookup *eax *(eax+4))
11604 89/<- %ecx 0/r32/eax
11605
11606 8b/-> *Curr-block-depth 0/r32/eax
11607 89/<- *(ecx+0x10) 0/r32/eax
11608
11609 8d/copy-address *(ecx+8) 0/r32/eax
11610 (allocate *(ebp+8) *Type-tree-size %eax)
11611 (lookup *(ecx+8) *(ecx+0xc))
11612 c7 0/subop/copy *eax 1/imm32/true
11613
11614 $new-literal-integer:end:
11615
11616 81 0/subop/add %esp 8/imm32
11617
11618 59/pop-to-ecx
11619 58/pop-to-eax
11620
11621 89/<- %esp 5/r32/ebp
11622 5d/pop-to-ebp
11623 c3/return
11624
11625 $new-literal-integer:abort:
11626 (write-buffered *(ebp+0x18) "fn ")
11627 8b/-> *(ebp+0x14) 0/r32/eax
11628 (lookup *eax *(eax+4))
11629 (write-buffered *(ebp+0x18) %eax)
11630 (write-buffered *(ebp+0x18) ": variable '")
11631 (write-slice-buffered *(ebp+0x18) *(ebp+0xc))
11632 (write-buffered *(ebp+0x18) "' cannot begin with a digit (or do you have a typo in a number?)\n")
11633 (flush *(ebp+0x18))
11634 (stop *(ebp+0x1c) 1)
11635
11636
11637
11638 check-mu-hex-int:
11639
11640 55/push-ebp
11641 89/<- %ebp 4/r32/esp
11642
11643 50/push-eax
11644 51/push-ecx
11645 52/push-edx
11646
11647 8b/-> *(ebp+8) 1/r32/ecx
11648
11649 8b/-> *ecx 2/r32/edx
11650
11651 b8/copy-to-eax 0/imm32
11652 8a/copy-byte *edx 0/r32/AL
11653 3d/compare-eax-and 0x2d/imm32/dash
11654 {
11655 75/jump-if-!= break/disp8
11656 42/increment-edx
11657 }
11658
11659 8b/-> *(ecx+4) 1/r32/ecx
11660
11661 89/<- %eax 1/r32/ecx
11662 29/subtract-from %eax 2/r32/edx
11663
11664 3d/compare-eax-with 1/imm32
11665 0f 8e/jump-if-<= $check-mu-hex-int:end/disp32
11666 $check-mu-hex-int:length->-1:
11667
11668
11669 51/push-ecx
11670 52/push-edx
11671 89/<- %eax 4/r32/esp
11672
11673 (slice-starts-with? %eax "0x")
11674
11675 81 0/subop/add %esp 8/imm32
11676
11677 3d/compare-eax-with 0/imm32/false
11678 75/jump-if-!= $check-mu-hex-int:end/disp8
11679 $check-mu-hex-int:abort:
11680
11681 (write-buffered *(ebp+0xc) "literal integers are always hex in Mu; either start '")
11682 (write-slice-buffered *(ebp+0xc) *(ebp+8))
11683 (write-buffered *(ebp+0xc) "' with a '0x' to be unambiguous, or convert it to decimal.\n")
11684 (flush *(ebp+0xc))
11685 (stop *(ebp+0x10) 1)
11686 $check-mu-hex-int:end:
11687
11688 5a/pop-to-edx
11689 59/pop-to-ecx
11690 58/pop-to-eax
11691
11692 89/<- %esp 5/r32/ebp
11693 5d/pop-to-ebp
11694 c3/return
11695
11696 new-literal:
11697
11698 55/push-ebp
11699 89/<- %ebp 4/r32/esp
11700
11701 50/push-eax
11702 51/push-ecx
11703
11704 68/push 0/imm32
11705 68/push 0/imm32
11706 89/<- %ecx 4/r32/esp
11707
11708 (slice-to-string Heap *(ebp+0xc) %ecx)
11709
11710 (new-var *(ebp+8) *ecx *(ecx+4) *(ebp+0x10))
11711
11712 8b/-> *(ebp+0x10) 1/r32/ecx
11713 (lookup *ecx *(ecx+4))
11714 89/<- %ecx 0/r32/eax
11715
11716 8b/-> *Curr-block-depth 0/r32/eax
11717 89/<- *(ecx+0x10) 0/r32/eax
11718
11719 8d/copy-address *(ecx+8) 0/r32/eax
11720 (allocate *(ebp+8) *Type-tree-size %eax)
11721 (lookup *(ecx+8) *(ecx+0xc))
11722
11723 c7 0/subop/copy *eax 1/imm32/true
11724 $new-literal:end:
11725
11726 81 0/subop/add %esp 8/imm32
11727
11728 59/pop-to-ecx
11729 58/pop-to-eax
11730
11731 89/<- %esp 5/r32/ebp
11732 5d/pop-to-ebp
11733 c3/return
11734
11735 new-var-from-slice:
11736
11737 55/push-ebp
11738 89/<- %ebp 4/r32/esp
11739
11740 51/push-ecx
11741
11742 68/push 0/imm32
11743 68/push 0/imm32
11744 89/<- %ecx 4/r32/esp
11745
11746 (slice-to-string Heap *(ebp+0xc) %ecx)
11747
11748 (new-var *(ebp+8) *ecx *(ecx+4) *(ebp+0x10))
11749 $new-var-from-slice:end:
11750
11751 81 0/subop/add %esp 8/imm32
11752
11753 59/pop-to-ecx
11754
11755 89/<- %esp 5/r32/ebp
11756 5d/pop-to-ebp
11757 c3/return
11758
11759 new-var-def:
11760
11761 55/push-ebp
11762 89/<- %ebp 4/r32/esp
11763
11764 50/push-eax
11765 51/push-ecx
11766
11767 (allocate *(ebp+8) *Stmt-size *(ebp+0x14))
11768
11769 8b/-> *(ebp+0x14) 0/r32/eax
11770 (lookup *eax *(eax+4))
11771
11772 c7 0/subop/copy *eax 2/imm32/tag/var-on-stack
11773
11774 8b/-> *(ebp+0xc) 1/r32/ecx
11775 89/<- *(eax+4) 1/r32/ecx
11776 8b/-> *(ebp+0x10) 1/r32/ecx
11777 89/<- *(eax+8) 1/r32/ecx
11778 $new-var-def:end:
11779
11780 59/pop-to-ecx
11781 58/pop-to-eax
11782
11783 89/<- %esp 5/r32/ebp
11784 5d/pop-to-ebp
11785 c3/return
11786
11787 new-reg-var-def:
11788
11789 55/push-ebp
11790 89/<- %ebp 4/r32/esp
11791
11792 50/push-eax
11793
11794 8b/-> *(ebp+0x14) 0/r32/eax
11795
11796 (allocate *(ebp+8) *Stmt-size %eax)
11797
11798 (lookup *eax *(eax+4))
11799
11800 c7 0/subop/copy *eax 3/imm32/tag/var-in-register
11801
11802 8d/copy-address *(eax+0x14) 0/r32/eax
11803 (append-stmt-var Heap *(ebp+0xc) *(ebp+0x10) 0 0 0 %eax)
11804 $new-reg-var-def:end:
11805
11806 58/pop-to-eax
11807
11808 89/<- %esp 5/r32/ebp
11809 5d/pop-to-ebp
11810 c3/return
11811
11812 append-list:
11813
11814 55/push-ebp
11815 89/<- %ebp 4/r32/esp
11816
11817 50/push-eax
11818 51/push-ecx
11819 57/push-edi
11820
11821 8b/-> *(ebp+0x1c) 7/r32/edi
11822
11823 (allocate *(ebp+8) *List-size %edi)
11824
11825 (lookup *edi *(edi+4))
11826 89/<- %edi 0/r32/eax
11827
11828 8b/-> *(ebp+0xc) 0/r32/eax
11829 89/<- *edi 0/r32/eax
11830 8b/-> *(ebp+0x10) 0/r32/eax
11831 89/<- *(edi+4) 0/r32/eax
11832
11833 81 7/subop/compare *(ebp+0x14) 0/imm32
11834 74/jump-if-= $append-list:end/disp8
11835
11836 $append-list:non-empty-list:
11837
11838 (lookup *(ebp+0x14) *(ebp+0x18))
11839
11840 {
11841 81 7/subop/compare *(eax+8) 0/imm32
11842 74/jump-if-= break/disp8
11843
11844 (lookup *(eax+8) *(eax+0xc))
11845
11846 eb/jump loop/disp8
11847 }
11848
11849 8b/-> *(ebp+0x1c) 7/r32/edi
11850
11851 8b/-> *edi 1/r32/ecx
11852 89/<- *(eax+8) 1/r32/ecx
11853 8b/-> *(edi+4) 1/r32/ecx
11854 89/<- *(eax+0xc) 1/r32/ecx
11855
11856 8b/-> *(ebp+0x14) 1/r32/ecx
11857 89/<- *edi 1/r32/ecx
11858 8b/-> *(ebp+0x18) 1/r32/ecx
11859 89/<- *(edi+4) 1/r32/ecx
11860 $append-list:end:
11861
11862 5f/pop-to-edi
11863 59/pop-to-ecx
11864 58/pop-to-eax
11865
11866 89/<- %esp 5/r32/ebp
11867 5d/pop-to-ebp
11868 c3/return
11869
11870 append-stmt-var:
11871
11872 55/push-ebp
11873 89/<- %ebp 4/r32/esp
11874
11875 50/push-eax
11876 51/push-ecx
11877 57/push-edi
11878
11879 8b/-> *(ebp+0x20) 7/r32/edi
11880
11881 (allocate *(ebp+8) *Stmt-var-size %edi)
11882
11883 (lookup *edi *(edi+4))
11884 89/<- %ecx 0/r32/eax
11885
11886 8b/-> *(ebp+0xc) 0/r32/eax
11887 89/<- *ecx 0/r32/eax
11888 8b/-> *(ebp+0x10) 0/r32/eax
11889 89/<- *(ecx+4) 0/r32/eax
11890
11891 8b/-> *(ebp+0x1c) 0/r32/eax
11892 89/<- *(ecx+0x10) 0/r32/eax
11893
11894 81 7/subop/compare *(ebp+0x14) 0/imm32/null
11895 74/jump-if-= $append-stmt-var:end/disp8
11896
11897
11898 (lookup *(ebp+0x14) *(ebp+0x18))
11899
11900 {
11901 81 7/subop/compare *(eax+8) 0/imm32
11902 74/jump-if-= break/disp8
11903
11904 (lookup *(eax+8) *(eax+0xc))
11905
11906 eb/jump loop/disp8
11907 }
11908
11909 8b/-> *edi 1/r32/ecx
11910 89/<- *(eax+8) 1/r32/ecx
11911 8b/-> *(edi+4) 1/r32/ecx
11912 89/<- *(eax+0xc) 1/r32/ecx
11913
11914 8b/-> *(ebp+0x14) 1/r32/ecx
11915 89/<- *edi 1/r32/ecx
11916 8b/-> *(ebp+0x18) 1/r32/ecx
11917 89/<- *(edi+4) 1/r32/ecx
11918 $append-stmt-var:end:
11919
11920 5f/pop-to-edi
11921 59/pop-to-ecx
11922 58/pop-to-eax
11923
11924 89/<- %esp 5/r32/ebp
11925 5d/pop-to-ebp
11926 c3/return
11927
11928 append-to-block:
11929
11930 55/push-ebp
11931 89/<- %ebp 4/r32/esp
11932
11933 50/push-eax
11934 56/push-esi
11935
11936 8b/-> *(ebp+0xc) 6/r32/esi
11937
11938 8d/copy-address *(esi+4) 0/r32/eax
11939 (append-list *(ebp+8) *(ebp+0x10) *(ebp+0x14) *(esi+4) *(esi+8) %eax)
11940 $append-to-block:end:
11941
11942 5e/pop-to-esi
11943 58/pop-to-eax
11944
11945 89/<- %esp 5/r32/ebp
11946 5d/pop-to-ebp
11947 c3/return
11948
11949
11950
11951
11952
11953
11954
11955 lookup-or-create-constant:
11956
11957 55/push-ebp
11958 89/<- %ebp 4/r32/esp
11959
11960 50/push-eax
11961 56/push-esi
11962
11963 (container-type *(ebp+8))
11964 89/<- %esi 0/r32/eax
11965
11966 68/push 0/imm32
11967 68/push 0/imm32
11968 89/<- %eax 4/r32/esp
11969 (find-or-create-typeinfo %esi %eax)
11970
11971 (lookup *eax *(eax+4))
11972
11973
11974
11975
11976
11977 (find-or-create-typeinfo-output-var %eax *(ebp+0xc) *(ebp+0x10))
11978
11979
11980
11981
11982
11983
11984
11985
11986
11987
11988
11989
11990
11991 $lookup-or-create-constant:end:
11992
11993 81 0/subop/add %esp 8/imm32
11994
11995 5e/pop-to-esi
11996 58/pop-to-eax
11997
11998 89/<- %esp 5/r32/ebp
11999 5d/pop-to-ebp
12000 c3/return
12001
12002
12003
12004
12005
12006 container-type:
12007
12008 55/push-ebp
12009 89/<- %ebp 4/r32/esp
12010
12011 8b/-> *(ebp+8) 0/r32/eax
12012 (lookup *eax *(eax+4))
12013 (lookup *(eax+8) *(eax+0xc))
12014 {
12015 81 7/subop/compare *(eax+8) 0/imm32
12016 74/jump-if-= break/disp8
12017 (lookup *(eax+0xc) *(eax+0x10))
12018 (lookup *(eax+4) *(eax+8))
12019 }
12020 8b/-> *(eax+4) 0/r32/eax
12021 $container-type:end:
12022
12023 89/<- %esp 5/r32/ebp
12024 5d/pop-to-ebp
12025 c3/return
12026
12027 is-container?:
12028
12029 55/push-ebp
12030 89/<- %ebp 4/r32/esp
12031
12032 8b/-> *(ebp+8) 0/r32/eax
12033 c1/shift 4/subop/left %eax 2/imm8
12034 3b/compare 0/r32/eax *Primitive-type-ids
12035 0f 9d/set-if->= %al
12036 81 4/subop/and %eax 0xff/imm32
12037 $is-container?:end:
12038
12039 89/<- %esp 5/r32/ebp
12040 5d/pop-to-ebp
12041 c3/return
12042
12043 find-or-create-typeinfo:
12044
12045 55/push-ebp
12046 89/<- %ebp 4/r32/esp
12047
12048 50/push-eax
12049 51/push-ecx
12050 52/push-edx
12051 57/push-edi
12052
12053 8b/-> *(ebp+0xc) 7/r32/edi
12054
12055 68/push 0/imm32
12056 68/push 0/imm32
12057 89/<- %ecx 4/r32/esp
12058
12059 (find-typeinfo *(ebp+8) %edi)
12060 {
12061
12062 81 7/subop/compare *edi 0/imm32
12063 0f 85/jump-if-!= break/disp32
12064 $find-or-create-typeinfo:create:
12065
12066 (allocate Heap *Typeinfo-size %edi)
12067
12068 (lookup *edi *(edi+4))
12069
12070
12071
12072
12073
12074
12075
12076 8b/-> *(ebp+8) 2/r32/edx
12077 89/<- *eax 2/r32/edx
12078
12079
12080 (new-stream Heap 0x40 *Typeinfo-fields-row-size %ecx)
12081
12082 8b/-> *ecx 2/r32/edx
12083 89/<- *(eax+4) 2/r32/edx
12084 8b/-> *(ecx+4) 2/r32/edx
12085 89/<- *(eax+8) 2/r32/edx
12086
12087 8b/-> *_Program-types 1/r32/ecx
12088 89/<- *(eax+0x10) 1/r32/ecx
12089 8b/-> *_Program-types->payload 1/r32/ecx
12090 89/<- *(eax+0x14) 1/r32/ecx
12091
12092 8b/-> *edi 1/r32/ecx
12093 89/<- *_Program-types 1/r32/ecx
12094 8b/-> *(edi+4) 1/r32/ecx
12095 89/<- *_Program-types->payload 1/r32/ecx
12096 }
12097 $find-or-create-typeinfo:end:
12098
12099 81 0/subop/add %esp 8/imm32
12100
12101 5f/pop-to-edi
12102 5a/pop-to-edx
12103 59/pop-to-ecx
12104 58/pop-to-eax
12105
12106 89/<- %esp 5/r32/ebp
12107 5d/pop-to-ebp
12108 c3/return
12109
12110 find-typeinfo:
12111
12112 55/push-ebp
12113 89/<- %ebp 4/r32/esp
12114
12115 50/push-eax
12116 51/push-ecx
12117 52/push-edx
12118 57/push-edi
12119
12120 8b/-> *(ebp+8) 1/r32/ecx
12121
12122 8b/-> *(ebp+0xc) 7/r32/edi
12123
12124 8b/-> *_Program-types 0/r32/eax
12125 89/<- *edi 0/r32/eax
12126 8b/-> *_Program-types->payload 0/r32/eax
12127 89/<- *(edi+4) 0/r32/eax
12128 {
12129 $find-typeinfo:loop:
12130
12131 81 7/subop/compare *edi 0/imm32
12132 74/jump-if-= break/disp8
12133 $find-typeinfo:check:
12134
12135 (lookup *edi *(edi+4))
12136
12137 39/compare *eax 1/r32/ecx
12138 74/jump-if-= break/disp8
12139 $find-typeinfo:continue:
12140
12141 8b/-> *(eax+0x10) 2/r32/edx
12142 89/<- *edi 2/r32/edx
12143 8b/-> *(eax+0x14) 2/r32/edx
12144 89/<- *(edi+4) 2/r32/edx
12145
12146 eb/jump loop/disp8
12147 }
12148 $find-typeinfo:end:
12149
12150 5f/pop-to-edi
12151 5a/pop-to-edx
12152 59/pop-to-ecx
12153 58/pop-to-eax
12154
12155 89/<- %esp 5/r32/ebp
12156 5d/pop-to-ebp
12157 c3/return
12158
12159 find-or-create-typeinfo-output-var:
12160
12161 55/push-ebp
12162 89/<- %ebp 4/r32/esp
12163
12164 50/push-eax
12165 52/push-edx
12166 57/push-edi
12167
12168 68/push 0/imm32
12169 68/push 0/imm32
12170 89/<- %edi 4/r32/esp
12171
12172 (find-or-create-typeinfo-fields *(ebp+8) *(ebp+0xc) %edi)
12173
12174 (lookup *edi *(edi+4))
12175 89/<- %edi 0/r32/eax
12176
12177 {
12178 81 7/subop/compare *(edi+0xc) 0/imm32
12179 0f 85/jump-if-!= break/disp32
12180
12181
12182 68/push 0/imm32
12183 68/push 0/imm32
12184 89/<- %eax 4/r32/esp
12185 (slice-to-string Heap *(ebp+0xc) %eax)
12186
12187 8d/copy-address *(edi+0xc) 2/r32/edx
12188 (new-var Heap *eax *(eax+4) %edx)
12189
12190 81 0/subop/add %esp 8/imm32
12191
12192 (lookup *(edi+0xc) *(edi+0x10))
12193 89/<- %edx 0/r32/eax
12194
12195 8d/copy-address *(edx+8) 0/r32/eax
12196 (allocate Heap *Type-tree-size %eax)
12197 (lookup *(edx+8) *(edx+0xc))
12198 c7 0/subop/copy *eax 1/imm32/true
12199 c7 0/subop/copy *(eax+4) 6/imm32/constant
12200 c7 0/subop/copy *(eax+8) 0/imm32
12201 c7 0/subop/copy *(eax+0xc) 0/imm32
12202 c7 0/subop/copy *(eax+0x10) 0/imm32
12203
12204 c7 0/subop/copy *(edx+0x14) -1/imm32/uninitialized
12205 }
12206
12207 8b/-> *(ebp+0x10) 2/r32/edx
12208 8b/-> *(edi+0xc) 0/r32/eax
12209 89/<- *edx 0/r32/eax
12210 8b/-> *(edi+0x10) 0/r32/eax
12211 89/<- *(edx+4) 0/r32/eax
12212 $find-or-create-typeinfo-output-var:end:
12213
12214 81 0/subop/add %esp 8/imm32
12215
12216 5f/pop-to-edi
12217 5a/pop-to-edx
12218 58/pop-to-eax
12219
12220 89/<- %esp 5/r32/ebp
12221 5d/pop-to-ebp
12222 c3/return
12223
12224 find-or-create-typeinfo-fields:
12225
12226 55/push-ebp
12227 89/<- %ebp 4/r32/esp
12228
12229 50/push-eax
12230 56/push-esi
12231 57/push-edi
12232
12233 8b/-> *(ebp+8) 0/r32/eax
12234 (lookup *(eax+4) *(eax+8))
12235
12236 8b/-> *(ebp+0x10) 7/r32/edi
12237
12238 (get-or-insert-slice %eax *(ebp+0xc) *Typeinfo-fields-row-size Heap)
12239 89/<- %esi 0/r32/eax
12240
12241 {
12242 81 7/subop/compare *esi 0/imm32
12243 75/jump-if-!= break/disp8
12244 (allocate Heap *Typeinfo-entry-size %esi)
12245
12246
12247
12248
12249
12250
12251
12252
12253
12254
12255
12256
12257
12258
12259
12260 }
12261
12262
12263 8b/-> *esi 0/r32/eax
12264 89/<- *edi 0/r32/eax
12265 8b/-> *(esi+4) 0/r32/eax
12266 89/<- *(edi+4) 0/r32/eax
12267 $find-or-create-typeinfo-fields:end:
12268
12269 5f/pop-to-edi
12270 5e/pop-to-esi
12271 58/pop-to-eax
12272
12273 89/<- %esp 5/r32/ebp
12274 5d/pop-to-ebp
12275 c3/return
12276
12277 populate-mu-type:
12278
12279
12280
12281
12282
12283
12284
12285
12286
12287
12288
12289
12290
12291
12292
12293
12294
12295
12296
12297
12298
12299
12300
12301
12302
12303 55/push-ebp
12304 89/<- %ebp 4/r32/esp
12305
12306 68/push 0/imm32
12307
12308 50/push-eax
12309 51/push-ecx
12310 52/push-edx
12311 53/push-ebx
12312 56/push-esi
12313 57/push-edi
12314
12315 8b/-> *(ebp+0xc) 7/r32/edi
12316
12317 81 5/subop/subtract %esp 0x200/imm32
12318 68/push 0x200/imm32/size
12319 68/push 0/imm32/read
12320 68/push 0/imm32/write
12321 89/<- %ecx 4/r32/esp
12322
12323 68/push 0/imm32/end
12324 68/push 0/imm32/start
12325 89/<- %edx 4/r32/esp
12326
12327 68/push 0/imm32
12328 68/push 0/imm32
12329 89/<- %esi 4/r32/esp
12330
12331 68/push 0/imm32
12332 68/push 0/imm32
12333 89/<- %ebx 4/r32/esp
12334 {
12335 $populate-mu-type:line-loop:
12336 (clear-stream %ecx)
12337 (read-line-buffered *(ebp+8) %ecx)
12338
12339 81 7/subop/compare *ecx 0/imm32
12340 0f 84/jump-if-= $populate-mu-type:error1/disp32
12341 +-- 6 lines: #? # dump line ------------------------------------------------------------------------------------------------------------------------------------------------------
12347 (next-mu-token %ecx %edx)
12348
12349 (slice-empty? %edx)
12350 3d/compare-eax-and 0/imm32
12351 0f 85/jump-if-!= loop/disp32
12352
12353 (slice-equal? %edx "}")
12354 3d/compare-eax-and 0/imm32
12355 0f 85/jump-if-!= break/disp32
12356 $populate-mu-type:parse-element:
12357
12358
12359
12360
12361 (parse-var-with-type %edx %ecx %esi *(ebp+0x10) *(ebp+0x14))
12362
12363 (lookup *esi *(esi+4))
12364 (lookup *(eax+8) *(eax+0xc))
12365 (is-mu-addr-type? %eax)
12366 3d/compare-eax-and 0/imm32/false
12367 0f 85/jump-if-!= $populate-mu-type:error2/disp32
12368
12369 (lookup *esi *(esi+4))
12370 (lookup *(eax+8) *(eax+0xc))
12371 (is-mu-array-type? %eax)
12372 3d/compare-eax-and 0/imm32/false
12373 0f 85/jump-if-!= $populate-mu-type:error3/disp32
12374
12375 (lookup *esi *(esi+4))
12376 (lookup *(eax+8) *(eax+0xc))
12377 (is-simple-mu-type? %eax 8)
12378 3d/compare-eax-and 0/imm32/false
12379 0f 85/jump-if-!= $populate-mu-type:error4/disp32
12380
12381 (lookup *esi *(esi+4))
12382 (lookup *(eax+8) *(eax+0xc))
12383 (is-simple-mu-type? %eax 0xc)
12384 3d/compare-eax-and 0/imm32/false
12385 0f 85/jump-if-!= $populate-mu-type:error5/disp32
12386
12387 (lookup *esi *(esi+4))
12388 (lookup *(eax+8) *(eax+0xc))
12389 (is-mu-stream-type? %eax)
12390 3d/compare-eax-and 0/imm32/false
12391 0f 85/jump-if-!= $populate-mu-type:error6/disp32
12392
12393 51/push-ecx
12394 $populate-mu-type:create-typeinfo-fields:
12395
12396 (find-or-create-typeinfo-fields %edi %edx %ebx)
12397
12398 (lookup *ebx *(ebx+4))
12399 8b/-> *(ebp-4) 1/r32/ecx
12400
12401
12402
12403
12404
12405
12406 89/<- *(eax+8) 1/r32/ecx
12407
12408 ff 0/subop/increment *(ebp-4)
12409 $populate-mu-type:set-input-type:
12410
12411 8b/-> *esi 1/r32/ecx
12412 89/<- *eax 1/r32/ecx
12413 8b/-> *(esi+4) 1/r32/ecx
12414 89/<- *(eax+4) 1/r32/ecx
12415
12416 59/pop-to-ecx
12417 {
12418 $populate-mu-type:create-output-type:
12419
12420 81 7/subop/compare *(eax+0xc) 0/imm32
12421 75/jump-if-!= break/disp8
12422 8d/copy-address *(eax+0xc) 0/r32/eax
12423 (new-literal Heap %edx %eax)
12424 }
12425 e9/jump loop/disp32
12426 }
12427 $populate-mu-type:invalidate-total-size-in-bytes:
12428
12429
12430
12431 c7 0/subop/copy *(edi+0xc) -2/imm32/uninitialized
12432 $populate-mu-type:end:
12433
12434 81 0/subop/add %esp 0x224/imm32
12435
12436 5f/pop-to-edi
12437 5e/pop-to-esi
12438 5b/pop-to-ebx
12439 5a/pop-to-edx
12440 59/pop-to-ecx
12441 58/pop-to-eax
12442
12443 81 0/subop/add %esp 4/imm32
12444
12445 89/<- %esp 5/r32/ebp
12446 5d/pop-to-ebp
12447 c3/return
12448
12449 $populate-mu-type:error1:
12450
12451 (write-buffered *(ebp+0x10) "incomplete type definition '")
12452 (type-name *edi)
12453 (write-buffered *(ebp+0x10) %eax)
12454 (write-buffered *(ebp+0x10) "\n")
12455 (flush *(ebp+0x10))
12456 (stop *(ebp+0x14) 1)
12457
12458
12459 $populate-mu-type:error2:
12460 (write-buffered *(ebp+0x10) "type ")
12461 (type-name *edi)
12462 (write-buffered *(ebp+0x10) %eax)
12463 (write-buffered *(ebp+0x10) ": 'addr' elements not allowed\n")
12464 (flush *(ebp+0x10))
12465 (stop *(ebp+0x14) 1)
12466
12467
12468 $populate-mu-type:error3:
12469 (write-buffered *(ebp+0x10) "type ")
12470 (type-name *edi)
12471 (write-buffered *(ebp+0x10) %eax)
12472 (write-buffered *(ebp+0x10) ": 'array' elements not allowed for now\n")
12473 (flush *(ebp+0x10))
12474 (stop *(ebp+0x14) 1)
12475
12476
12477 $populate-mu-type:error4:
12478 (write-buffered *(ebp+0x10) "type ")
12479 (type-name *edi)
12480 (write-buffered *(ebp+0x10) %eax)
12481 (write-buffered *(ebp+0x10) ": 'byte' elements not allowed\n")
12482 (flush *(ebp+0x10))
12483 (stop *(ebp+0x14) 1)
12484
12485
12486 $populate-mu-type:error5:
12487 (write-buffered *(ebp+0x10) "type ")
12488 (type-name *edi)
12489 (write-buffered *(ebp+0x10) %eax)
12490 (write-buffered *(ebp+0x10) ": 'slice' elements not allowed\n")
12491 (flush *(ebp+0x10))
12492 (stop *(ebp+0x14) 1)
12493
12494
12495 $populate-mu-type:error6:
12496 (write-buffered *(ebp+0x10) "type ")
12497 (type-name *edi)
12498 (write-buffered *(ebp+0x10) %eax)
12499 (write-buffered *(ebp+0x10) ": 'stream' elements not allowed for now\n")
12500 (flush *(ebp+0x10))
12501 (stop *(ebp+0x14) 1)
12502
12503
12504 type-name:
12505
12506 55/push-ebp
12507 89/<- %ebp 4/r32/esp
12508
12509 (index Type-id *(ebp+8))
12510 $type-name:end:
12511
12512 89/<- %esp 5/r32/ebp
12513 5d/pop-to-ebp
12514 c3/return
12515
12516 index:
12517
12518 55/push-ebp
12519 89/<- %ebp 4/r32/esp
12520
12521 56/push-esi
12522
12523
12524 8b/-> *(ebp+8) 6/r32/esi
12525
12526 8b/-> *(ebp+0xc) 0/r32/eax
12527
12528 8b/-> *(esi+eax<<2+0xc) 0/r32/eax
12529 $index:end:
12530
12531 5e/pop-to-esi
12532
12533 89/<- %esp 5/r32/ebp
12534 5d/pop-to-ebp
12535 c3/return
12536
12537
12538
12539
12540
12541
12542
12543
12544
12545
12546 populate-mu-type-sizes:
12547
12548 55/push-ebp
12549 89/<- %ebp 4/r32/esp
12550 $populate-mu-type-sizes:total-sizes:
12551
12552 (lookup *_Program-types *_Program-types->payload)
12553 {
12554
12555 3d/compare-eax-and 0/imm32/null
12556 74/jump-if-= break/disp8
12557 (populate-mu-type-sizes-in-type %eax *(ebp+8) *(ebp+0xc))
12558
12559 (lookup *(eax+0x10) *(eax+0x14))
12560 eb/jump loop/disp8
12561 }
12562 $populate-mu-type-sizes:offsets:
12563
12564 (lookup *_Program-types *_Program-types->payload)
12565 {
12566
12567 3d/compare-eax-and 0/imm32/null
12568 74/jump-if-= break/disp8
12569 (populate-mu-type-offsets %eax *(ebp+8) *(ebp+0xc))
12570
12571 (lookup *(eax+0x10) *(eax+0x14))
12572 eb/jump loop/disp8
12573 }
12574 $populate-mu-type-sizes:end:
12575
12576 89/<- %esp 5/r32/ebp
12577 5d/pop-to-ebp
12578 c3/return
12579
12580
12581
12582
12583 populate-mu-type-sizes-in-type:
12584
12585 55/push-ebp
12586 89/<- %ebp 4/r32/esp
12587
12588 50/push-eax
12589 51/push-ecx
12590 52/push-edx
12591 56/push-esi
12592 57/push-edi
12593
12594 8b/-> *(ebp+8) 6/r32/esi
12595
12596 81 7/subop/compare *(esi+0xc) 0/imm32
12597 0f 8d/jump-if->= $populate-mu-type-sizes-in-type:end/disp32
12598
12599 81 7/subop/compare *(esi+0xc) -1/imm32/being-computed
12600 0f 84/jump-if-= $populate-mu-type-sizes-in-type:abort/disp32
12601
12602 c7 0/subop/copy *(esi+0xc) -1/imm32/being-computed
12603
12604 bf/copy-to-edi 0/imm32
12605
12606
12607 (lookup *(esi+4) *(esi+8))
12608 89/<- %ecx 0/r32/eax
12609
12610 8b/-> *ecx 2/r32/edx
12611
12612 8d/copy-address *(ecx+0xc) 1/r32/ecx
12613
12614 8d/copy-address *(ecx+edx) 2/r32/edx
12615 {
12616 $populate-mu-type-sizes-in-type:loop:
12617
12618 39/compare %ecx 2/r32/edx
12619 73/jump-if-addr>= break/disp8
12620
12621 (lookup *(ecx+8) *(ecx+0xc))
12622
12623 81 7/subop/compare *eax 0/imm32
12624 74/jump-if-= $populate-mu-type-sizes-in-type:end/disp8
12625
12626 (lookup *eax *(eax+4))
12627 (compute-size-of-var %eax *(ebp+0xc) *(ebp+0x10))
12628
12629 01/add-to %edi 0/r32/eax
12630
12631 81 0/subop/add %ecx 0x10/imm32
12632
12633 eb/jump loop/disp8
12634 }
12635
12636 89/<- *(esi+0xc) 7/r32/edi
12637 $populate-mu-type-sizes-in-type:end:
12638
12639 5f/pop-to-edi
12640 5e/pop-to-esi
12641 5a/pop-to-edx
12642 59/pop-to-ecx
12643 58/pop-to-eax
12644
12645 89/<- %esp 5/r32/ebp
12646 5d/pop-to-ebp
12647 c3/return
12648
12649 $populate-mu-type-sizes-in-type:abort:
12650 (write-buffered *(ebp+0xc) "cycle in type definitions\n")
12651 (flush *(ebp+0xc))
12652 (stop *(ebp+0x10) 1)
12653
12654
12655
12656
12657 compute-size-of-var:
12658
12659 55/push-ebp
12660 89/<- %ebp 4/r32/esp
12661
12662 51/push-ecx
12663
12664 8b/-> *(ebp+8) 1/r32/ecx
12665 (lookup *(ecx+8) *(ecx+0xc))
12666 89/<- %ecx 0/r32/eax
12667
12668 {
12669 81 7/subop/compare *ecx 0/imm32/false
12670 75/jump-if-!= break/disp8
12671 (lookup *(ecx+4) *(ecx+8))
12672 89/<- %ecx 0/r32/eax
12673 }
12674
12675 (compute-size-of-type-id *(ecx+4) *(ebp+0xc) *(ebp+0x10))
12676 $compute-size-of-var:end:
12677
12678 59/pop-to-ecx
12679
12680 89/<- %esp 5/r32/ebp
12681 5d/pop-to-ebp
12682 c3/return
12683
12684 compute-size-of-type-id:
12685
12686 55/push-ebp
12687 89/<- %ebp 4/r32/esp
12688
12689 51/push-ecx
12690
12691 68/push 0/imm32
12692 68/push 0/imm32
12693 89/<- %ecx 4/r32/esp
12694
12695 8b/-> *(ebp+8) 0/r32/eax
12696
12697 3d/compare-eax-and 0/imm32/literal
12698 0f 84/jump-if-= $compute-size-of-type-id:end/disp32
12699
12700 3d/compare-eax-and 8/imm32/byte
12701 {
12702 75/jump-if-!= break/disp8
12703 b8/copy-to-eax 4/imm32
12704 eb/jump $compute-size-of-type-id:end/disp8
12705 }
12706
12707 3d/compare-eax-and 4/imm32/handle
12708 {
12709 75/jump-if-!= break/disp8
12710 b8/copy-to-eax 8/imm32
12711 eb/jump $compute-size-of-type-id:end/disp8
12712 }
12713
12714 3d/compare-eax-and 0xc/imm32/slice
12715 {
12716 75/jump-if-!= break/disp8
12717 b8/copy-to-eax 8/imm32
12718 eb/jump $compute-size-of-type-id:end/disp8
12719 }
12720
12721
12722 (find-typeinfo %eax %ecx)
12723 {
12724 81 7/subop/compare *ecx 0/imm32
12725 74/jump-if-= break/disp8
12726 $compute-size-of-type-id:user-defined:
12727 (lookup *ecx *(ecx+4))
12728 (populate-mu-type-sizes-in-type %eax *(ebp+0xc) *(ebp+0x10))
12729 8b/-> *(eax+0xc) 0/r32/eax
12730 eb/jump $compute-size-of-type-id:end/disp8
12731 }
12732
12733 b8/copy-to-eax 4/imm32
12734 $compute-size-of-type-id:end:
12735
12736 81 0/subop/add %esp 8/imm32
12737
12738 59/pop-to-ecx
12739
12740 89/<- %esp 5/r32/ebp
12741 5d/pop-to-ebp
12742 c3/return
12743
12744
12745
12746
12747 populate-mu-type-offsets:
12748
12749 55/push-ebp
12750 89/<- %ebp 4/r32/esp
12751
12752 50/push-eax
12753 51/push-ecx
12754 52/push-edx
12755 53/push-ebx
12756 56/push-esi
12757 57/push-edi
12758
12759
12760 bf/copy-to-edi 0/imm32
12761
12762 8b/-> *(ebp+8) 1/r32/ecx
12763 (lookup *(ecx+4) *(ecx+8))
12764 89/<- %ecx 0/r32/eax
12765
12766 8b/-> *ecx 2/r32/edx
12767 c1 5/subop/shift-right-logical %edx 4/imm8
12768
12769 bb/copy-to-ebx 0/imm32
12770 {
12771 $populate-mu-type-offsets:loop:
12772 39/compare %ebx 2/r32/edx
12773 0f 8d/jump-if->= break/disp32
12774
12775
12776
12777
12778
12779
12780
12781 (locate-typeinfo-entry-with-index %ecx %ebx *(ebp+0xc) *(ebp+0x10))
12782 89/<- %esi 0/r32/eax
12783
12784 81 7/subop/compare %esi 0/imm32
12785 74/jump-if-= $populate-mu-type-offsets:end/disp8
12786
12787 81 7/subop/compare *esi 0/imm32
12788 74/jump-if-= $populate-mu-type-offsets:end/disp8
12789
12790
12791 (lookup *(esi+0xc) *(esi+0x10))
12792 89/<- *(eax+0x14) 7/r32/edi
12793
12794 (lookup *esi *(esi+4))
12795 (size-of %eax)
12796 01/add-to %edi 0/r32/eax
12797
12798 43/increment-ebx
12799 e9/jump loop/disp32
12800 }
12801 $populate-mu-type-offsets:end:
12802
12803 5f/pop-to-edi
12804 5e/pop-to-esi
12805 5b/pop-to-ebx
12806 5a/pop-to-edx
12807 59/pop-to-ecx
12808 58/pop-to-eax
12809
12810 89/<- %esp 5/r32/ebp
12811 5d/pop-to-ebp
12812 c3/return
12813
12814 locate-typeinfo-entry-with-index:
12815
12816 55/push-ebp
12817 89/<- %ebp 4/r32/esp
12818
12819 51/push-ecx
12820 52/push-edx
12821 53/push-ebx
12822 56/push-esi
12823 57/push-edi
12824
12825 8b/-> *(ebp+8) 6/r32/esi
12826
12827 8d/copy-address *(esi+0xc) 1/r32/ecx
12828
12829 8b/-> *esi 2/r32/edx
12830 8d/copy-address *(ecx+edx) 2/r32/edx
12831 {
12832 $locate-typeinfo-entry-with-index:loop:
12833 39/compare %ecx 2/r32/edx
12834 73/jump-if-addr>= break/disp8
12835
12836 (lookup *(ecx+8) *(ecx+0xc))
12837
12838 8b/-> *(eax+8) 3/r32/ebx
12839
12840
12841
12842
12843
12844
12845 39/compare *(ebp+0xc) 3/r32/ebx
12846 74/jump-if-= $locate-typeinfo-entry-with-index:end/disp8
12847
12848 81 0/subop/add %ecx 0x10/imm32
12849
12850 eb/jump loop/disp8
12851 }
12852
12853 b8/copy-to-eax 0/imm32
12854 $locate-typeinfo-entry-with-index:end:
12855
12856
12857
12858
12859
12860 5f/pop-to-edi
12861 5e/pop-to-esi
12862 5b/pop-to-ebx
12863 5a/pop-to-edx
12864 59/pop-to-ecx
12865
12866 89/<- %esp 5/r32/ebp
12867 5d/pop-to-ebp
12868 c3/return
12869
12870 dump-typeinfos:
12871
12872 55/push-ebp
12873 89/<- %ebp 4/r32/esp
12874
12875 50/push-eax
12876
12877 (write-buffered Stderr *(ebp+8))
12878 (flush Stderr)
12879
12880 (lookup *_Program-types *_Program-types->payload)
12881 {
12882
12883 3d/compare-eax-and 0/imm32
12884 74/jump-if-= break/disp8
12885 (write-buffered Stderr "---\n")
12886 (flush Stderr)
12887 (dump-typeinfo %eax)
12888
12889 (lookup *(eax+0x10) *(eax+0x14))
12890 eb/jump loop/disp8
12891 }
12892 $dump-typeinfos:end:
12893
12894 58/pop-to-eax
12895
12896 89/<- %esp 5/r32/ebp
12897 5d/pop-to-ebp
12898 c3/return
12899
12900 dump-typeinfo:
12901
12902 55/push-ebp
12903 89/<- %ebp 4/r32/esp
12904
12905 50/push-eax
12906 51/push-ecx
12907 52/push-edx
12908 53/push-ebx
12909 56/push-esi
12910 57/push-edi
12911
12912 8b/-> *(ebp+8) 6/r32/esi
12913
12914 (lookup *(esi+4) *(esi+8))
12915 89/<- %ecx 0/r32/eax
12916 (write-buffered Stderr "id:")
12917 (write-int32-hex-buffered Stderr *esi)
12918 (write-buffered Stderr "\n")
12919 (write-buffered Stderr "fields @ ")
12920 (write-int32-hex-buffered Stderr %ecx)
12921 (write-buffered Stderr Newline)
12922 (flush Stderr)
12923 (write-buffered Stderr " write: ")
12924 (write-int32-hex-buffered Stderr *ecx)
12925 (write-buffered Stderr Newline)
12926 (flush Stderr)
12927 (write-buffered Stderr " read: ")
12928 (write-int32-hex-buffered Stderr *(ecx+4))
12929 (write-buffered Stderr Newline)
12930 (flush Stderr)
12931 (write-buffered Stderr " size: ")
12932 (write-int32-hex-buffered Stderr *(ecx+8))
12933 (write-buffered Stderr Newline)
12934 (flush Stderr)
12935
12936 8b/-> *ecx 2/r32/edx
12937
12938 8d/copy-address *(ecx+0xc) 1/r32/ecx
12939
12940 8d/copy-address *(ecx+edx) 2/r32/edx
12941 {
12942 $dump-typeinfo:loop:
12943
12944 39/compare %ecx 2/r32/edx
12945 0f 83/jump-if-addr>= break/disp32
12946 (write-buffered Stderr " row:\n")
12947 (write-buffered Stderr " key: ")
12948 (write-int32-hex-buffered Stderr *ecx)
12949 (write-buffered Stderr ",")
12950 (write-int32-hex-buffered Stderr *(ecx+4))
12951 (write-buffered Stderr " = '")
12952 (lookup *ecx *(ecx+4))
12953 (write-buffered Stderr %eax)
12954 (write-buffered Stderr "' @ ")
12955 (write-int32-hex-buffered Stderr %eax)
12956 (write-buffered Stderr Newline)
12957 (flush Stderr)
12958 (write-buffered Stderr " value: ")
12959 (write-int32-hex-buffered Stderr *(ecx+8))
12960 (write-buffered Stderr ",")
12961 (write-int32-hex-buffered Stderr *(ecx+0xc))
12962 (write-buffered Stderr " = typeinfo-entry@")
12963 (lookup *(ecx+8) *(ecx+0xc))
12964 (write-int32-hex-buffered Stderr %eax)
12965 (write-buffered Stderr Newline)
12966 (flush Stderr)
12967 (write-buffered Stderr " input var@")
12968 (dump-var 5 %eax)
12969 (lookup *(ecx+8) *(ecx+0xc))
12970 (write-buffered Stderr " index: ")
12971 (write-int32-hex-buffered Stderr *(eax+8))
12972 (write-buffered Stderr Newline)
12973 (flush Stderr)
12974 (write-buffered Stderr " output var@")
12975 8d/copy-address *(eax+0xc) 0/r32/eax
12976 (dump-var 5 %eax)
12977 (flush Stderr)
12978
12979 81 0/subop/add %ecx 0x10/imm32
12980
12981 e9/jump loop/disp32
12982 }
12983 $dump-typeinfo:end:
12984
12985 5f/pop-to-edi
12986 5e/pop-to-esi
12987 5b/pop-to-ebx
12988 5a/pop-to-edx
12989 59/pop-to-ecx
12990 58/pop-to-eax
12991
12992 89/<- %esp 5/r32/ebp
12993 5d/pop-to-ebp
12994 c3/return
12995
12996 dump-var:
12997
12998 55/push-ebp
12999 89/<- %ebp 4/r32/esp
13000
13001 50/push-eax
13002 53/push-ebx
13003
13004 8b/-> *(ebp+0xc) 0/r32/eax
13005
13006 (write-int32-hex-buffered Stderr *eax)
13007 (write-buffered Stderr ",")
13008 (write-int32-hex-buffered Stderr *(eax+4))
13009 (write-buffered Stderr "->")
13010 (lookup *eax *(eax+4))
13011 (write-int32-hex-buffered Stderr %eax)
13012 (write-buffered Stderr Newline)
13013 (flush Stderr)
13014 {
13015 3d/compare-eax-and 0/imm32
13016 0f 84/jump-if-= break/disp32
13017 (emit-indent Stderr *(ebp+8))
13018 (write-buffered Stderr "name: ")
13019 89/<- %ebx 0/r32/eax
13020 (write-int32-hex-buffered Stderr *ebx)
13021 (write-buffered Stderr ",")
13022 (write-int32-hex-buffered Stderr *(ebx+4))
13023 (write-buffered Stderr "->")
13024 (lookup *ebx *(ebx+4))
13025 (write-int32-hex-buffered Stderr %eax)
13026 {
13027 3d/compare-eax-and 0/imm32
13028 74/jump-if-= break/disp8
13029 (write-buffered Stderr Space)
13030 (write-buffered Stderr %eax)
13031 }
13032 (write-buffered Stderr Newline)
13033 (flush Stderr)
13034 (emit-indent Stderr *(ebp+8))
13035 (write-buffered Stderr "block depth: ")
13036 (write-int32-hex-buffered Stderr *(ebx+0x10))
13037 (write-buffered Stderr Newline)
13038 (flush Stderr)
13039 (emit-indent Stderr *(ebp+8))
13040 (write-buffered Stderr "stack offset: ")
13041 (write-int32-hex-buffered Stderr *(ebx+0x14))
13042 (write-buffered Stderr Newline)
13043 (flush Stderr)
13044 (emit-indent Stderr *(ebp+8))
13045 (write-buffered Stderr "reg: ")
13046 (write-int32-hex-buffered Stderr *(ebx+0x18))
13047 (write-buffered Stderr ",")
13048 (write-int32-hex-buffered Stderr *(ebx+0x1c))
13049 (write-buffered Stderr "->")
13050 (flush Stderr)
13051 (lookup *(ebx+0x18) *(ebx+0x1c))
13052 (write-int32-hex-buffered Stderr %eax)
13053 {
13054 3d/compare-eax-and 0/imm32
13055 74/jump-if-= break/disp8
13056 (write-buffered Stderr Space)
13057 (write-buffered Stderr %eax)
13058 }
13059 (write-buffered Stderr Newline)
13060 (flush Stderr)
13061 }
13062 $dump-var:end:
13063
13064 5b/pop-to-ebx
13065 58/pop-to-eax
13066
13067 89/<- %esp 5/r32/ebp
13068 5d/pop-to-ebp
13069 c3/return
13070
13071
13072
13073
13074
13075 check-mu-types:
13076
13077 55/push-ebp
13078 89/<- %ebp 4/r32/esp
13079
13080 50/push-eax
13081
13082 (lookup *_Program-functions *_Program-functions->payload)
13083 {
13084 $check-mu-types:loop:
13085
13086 3d/compare-eax-and 0/imm32
13087 0f 84/jump-if-= break/disp32
13088 +-- 8 lines: #? # dump curr->name ------------------------------------------------------------------------------------------------------------------------------------------------
13096 (check-mu-function %eax *(ebp+8) *(ebp+0xc))
13097
13098 (lookup *(eax+0x20) *(eax+0x24))
13099 e9/jump loop/disp32
13100 }
13101 $check-mu-types:end:
13102
13103 58/pop-to-eax
13104
13105 89/<- %esp 5/r32/ebp
13106 5d/pop-to-ebp
13107 c3/return
13108
13109 check-mu-function:
13110
13111 55/push-ebp
13112 89/<- %ebp 4/r32/esp
13113
13114 50/push-eax
13115
13116 8b/-> *(ebp+8) 0/r32/eax
13117
13118
13119 (lookup *(eax+0x18) *(eax+0x1c))
13120 (check-mu-block %eax *(ebp+8) *(ebp+0xc) *(ebp+0x10))
13121 $check-mu-function:end:
13122
13123 58/pop-to-eax
13124
13125 89/<- %esp 5/r32/ebp
13126 5d/pop-to-ebp
13127 c3/return
13128
13129 check-mu-block:
13130
13131 55/push-ebp
13132 89/<- %ebp 4/r32/esp
13133
13134 50/push-eax
13135
13136 8b/-> *(ebp+8) 0/r32/eax
13137
13138 (lookup *(eax+4) *(eax+8))
13139
13140 {
13141 $check-mu-block:check-empty:
13142 3d/compare-eax-and 0/imm32
13143 0f 84/jump-if-= break/disp32
13144
13145 (check-mu-stmt-list %eax *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13146 }
13147 $check-mu-block:end:
13148
13149 58/pop-to-eax
13150
13151 89/<- %esp 5/r32/ebp
13152 5d/pop-to-ebp
13153 c3/return
13154
13155 check-mu-stmt-list:
13156
13157 55/push-ebp
13158 89/<- %ebp 4/r32/esp
13159
13160 50/push-eax
13161 56/push-esi
13162
13163 8b/-> *(ebp+8) 6/r32/esi
13164 {
13165 $check-mu-stmt-list:loop:
13166 81 7/subop/compare %esi 0/imm32
13167 0f 84/jump-if-= break/disp32
13168
13169 (lookup *esi *(esi+4))
13170 {
13171 $check-mu-stmt-list:check-for-block:
13172 81 7/subop/compare *eax 0/imm32/block
13173 75/jump-if-!= break/disp8
13174 $check-mu-stmt-list:block:
13175 (check-mu-block %eax *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13176 eb/jump $check-mu-stmt-list:continue/disp8
13177 }
13178 {
13179 $check-mu-stmt-list:check-for-stmt1:
13180 81 7/subop/compare *eax 1/imm32/stmt1
13181 0f 85/jump-if-!= break/disp32
13182 $check-mu-stmt-list:stmt1:
13183 (check-mu-stmt %eax *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13184 eb/jump $check-mu-stmt-list:continue/disp8
13185 }
13186 {
13187 $check-mu-stmt-list:check-for-reg-var-def:
13188 81 7/subop/compare *eax 3/imm32/reg-var-def
13189 0f 85/jump-if-!= break/disp32
13190 $check-mu-stmt-list:reg-var-def:
13191 (check-mu-stmt %eax *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13192 eb/jump $check-mu-stmt-list:continue/disp8
13193 }
13194 $check-mu-stmt-list:continue:
13195
13196 (lookup *(esi+8) *(esi+0xc))
13197 89/<- %esi 0/r32/eax
13198 e9/jump loop/disp32
13199 }
13200 $check-mu-stmt-list:end:
13201
13202 5e/pop-to-esi
13203 58/pop-to-eax
13204
13205 89/<- %esp 5/r32/ebp
13206 5d/pop-to-ebp
13207 c3/return
13208
13209 check-mu-stmt:
13210
13211 55/push-ebp
13212 89/<- %ebp 4/r32/esp
13213
13214 50/push-eax
13215
13216 (has-primitive-name? *(ebp+8))
13217 3d/compare-eax-and 0/imm32/false
13218 {
13219 74/jump-if-= break/disp8
13220 (check-mu-primitive *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13221 e9/jump $check-mu-stmt:end/disp32
13222 }
13223
13224
13225 (lookup *_Program-functions *_Program-functions->payload)
13226 (find-matching-function %eax *(ebp+8))
13227 3d/compare-eax-and 0/imm32
13228 {
13229 74/jump-if-= break/disp8
13230 (check-mu-call *(ebp+8) %eax *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13231 eb/jump $check-mu-stmt:end/disp8
13232 }
13233
13234 (lookup *_Program-signatures *_Program-signatures->payload)
13235 (find-matching-function %eax *(ebp+8))
13236 3d/compare-eax-and 0/imm32
13237 {
13238 74/jump-if-= break/disp8
13239 (check-mu-call *(ebp+8) %eax *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13240 eb/jump $check-mu-stmt:end/disp8
13241 }
13242
13243 e9/jump $check-mu-stmt:unknown-call/disp32
13244 $check-mu-stmt:end:
13245
13246 58/pop-to-eax
13247
13248 89/<- %esp 5/r32/ebp
13249 5d/pop-to-ebp
13250 c3/return
13251
13252 $check-mu-stmt:unknown-call:
13253 (write-buffered *(ebp+0x10) "unknown function '")
13254 8b/-> *(ebp+8) 0/r32/eax
13255 (lookup *(eax+4) *(eax+8))
13256 (write-buffered *(ebp+0x10) %eax)
13257 (write-buffered *(ebp+0x10) "'\n")
13258 (flush *(ebp+0x10))
13259 (stop *(ebp+0x14) 1)
13260
13261
13262 has-primitive-name?:
13263
13264 55/push-ebp
13265 89/<- %ebp 4/r32/esp
13266
13267 51/push-ecx
13268 56/push-esi
13269
13270 8b/-> *(ebp+8) 6/r32/esi
13271 (lookup *(esi+4) *(esi+8))
13272 89/<- %esi 0/r32/eax
13273
13274 (string-equal? %esi "get")
13275 3d/compare-eax-and 0/imm32/false
13276 0f 85/jump-if-!= $has-primitive-name?:end/disp32
13277
13278 (string-equal? %esi "index")
13279 3d/compare-eax-and 0/imm32/false
13280 0f 85/jump-if-!= $has-primitive-name?:end/disp32
13281
13282 (string-equal? %esi "length")
13283 3d/compare-eax-and 0/imm32/false
13284 0f 85/jump-if-!= $has-primitive-name?:end/disp32
13285
13286 (string-equal? %esi "compute-offset")
13287 3d/compare-eax-and 0/imm32/false
13288 0f 85/jump-if-!= $has-primitive-name?:end/disp32
13289
13290 (string-equal? %esi "copy-object")
13291 3d/compare-eax-and 0/imm32/false
13292 0f 85/jump-if-!= $has-primitive-name?:end/disp32
13293
13294 (string-equal? %esi "allocate")
13295 3d/compare-eax-and 0/imm32/false
13296 0f 85/jump-if-!= $has-primitive-name?:end/disp32
13297
13298 (string-equal? %esi "populate")
13299 3d/compare-eax-and 0/imm32/false
13300 0f 85/jump-if-!= $has-primitive-name?:end/disp32
13301
13302 (string-equal? %esi "populate-stream")
13303 3d/compare-eax-and 0/imm32/false
13304 0f 85/jump-if-!= $has-primitive-name?:end/disp32
13305
13306 (string-equal? %esi "read-from-stream")
13307 3d/compare-eax-and 0/imm32/false
13308 0f 85/jump-if-!= $has-primitive-name?:end/disp32
13309
13310 (string-equal? %esi "write-to-stream")
13311 3d/compare-eax-and 0/imm32/false
13312 0f 85/jump-if-!= $has-primitive-name?:end/disp32
13313
13314 b9/copy-to-ecx Primitives/imm32
13315 {
13316 $has-primitive-name?:loop:
13317
13318 81 7/subop/compare %ecx 0/imm32
13319 74/jump-if-= break/disp8
13320
13321 (lookup *ecx *(ecx+4))
13322
13323
13324
13325 (string-equal? %esi %eax)
13326 3d/compare-eax-and 0/imm32/false
13327 75/jump-if-!= $has-primitive-name?:end/disp8
13328 $has-primitive-name?:next-primitive:
13329
13330 (lookup *(ecx+0x3c) *(ecx+0x40))
13331 89/<- %ecx 0/r32/eax
13332
13333 e9/jump loop/disp32
13334 }
13335
13336 b8/copy-to-eax 0/imm32
13337 $has-primitive-name?:end:
13338
13339 5e/pop-to-esi
13340 59/pop-to-ecx
13341
13342 89/<- %esp 5/r32/ebp
13343 5d/pop-to-ebp
13344 c3/return
13345
13346 check-mu-primitive:
13347
13348 55/push-ebp
13349 89/<- %ebp 4/r32/esp
13350
13351 50/push-eax
13352 51/push-ecx
13353
13354 8b/-> *(ebp+8) 0/r32/eax
13355 (lookup *(eax+4) *(eax+8))
13356 89/<- %ecx 0/r32/eax
13357
13358 {
13359 (string-equal? %ecx "copy")
13360 3d/compare-eax-and 0/imm32/false
13361 74/jump-if-= break/disp8
13362 (check-mu-copy-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13363 e9/jump $check-mu-primitive:end/disp32
13364 }
13365
13366 {
13367 (string-equal? %ecx "copy-to")
13368 3d/compare-eax-and 0/imm32/false
13369 74/jump-if-= break/disp8
13370 (check-mu-copy-to-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13371 e9/jump $check-mu-primitive:end/disp32
13372 }
13373
13374 {
13375 (string-equal? %ecx "compare")
13376 3d/compare-eax-and 0/imm32/false
13377 74/jump-if-= break/disp8
13378 (check-mu-compare-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13379 e9/jump $check-mu-primitive:end/disp32
13380 }
13381
13382 {
13383 (string-equal? %ecx "address")
13384 3d/compare-eax-and 0/imm32/false
13385 74/jump-if-= break/disp8
13386 (check-mu-address-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13387 e9/jump $check-mu-primitive:end/disp32
13388 }
13389
13390 {
13391 (string-equal? %ecx "get")
13392 3d/compare-eax-and 0/imm32/false
13393 74/jump-if-= break/disp8
13394 (check-mu-get-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13395 e9/jump $check-mu-primitive:end/disp32
13396 }
13397
13398 {
13399 (string-equal? %ecx "index")
13400 3d/compare-eax-and 0/imm32/false
13401 74/jump-if-= break/disp8
13402 (check-mu-index-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13403 e9/jump $check-mu-primitive:end/disp32
13404 }
13405
13406 {
13407 (string-equal? %ecx "length")
13408 3d/compare-eax-and 0/imm32/false
13409 74/jump-if-= break/disp8
13410 (check-mu-length-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13411 e9/jump $check-mu-primitive:end/disp32
13412 }
13413
13414 {
13415 (string-equal? %ecx "compute-offset")
13416 3d/compare-eax-and 0/imm32/false
13417 74/jump-if-= break/disp8
13418 (check-mu-compute-offset-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13419 e9/jump $check-mu-primitive:end/disp32
13420 }
13421
13422 {
13423 (string-equal? %ecx "copy-object")
13424 3d/compare-eax-and 0/imm32/false
13425 74/jump-if-= break/disp8
13426 (check-mu-copy-object-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13427 e9/jump $check-mu-primitive:end/disp32
13428 }
13429
13430 {
13431 (string-equal? %ecx "allocate")
13432 3d/compare-eax-and 0/imm32/false
13433 74/jump-if-= break/disp8
13434 (check-mu-allocate-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13435 e9/jump $check-mu-primitive:end/disp32
13436 }
13437
13438 {
13439 (string-equal? %ecx "populate")
13440 3d/compare-eax-and 0/imm32/false
13441 74/jump-if-= break/disp8
13442 (check-mu-populate-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13443 e9/jump $check-mu-primitive:end/disp32
13444 }
13445
13446 {
13447 (string-equal? %ecx "populate-stream")
13448 3d/compare-eax-and 0/imm32/false
13449 74/jump-if-= break/disp8
13450 (check-mu-populate-stream-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13451 e9/jump $check-mu-primitive:end/disp32
13452 }
13453
13454 {
13455 (string-equal? %ecx "read-from-stream")
13456 3d/compare-eax-and 0/imm32/false
13457 74/jump-if-= break/disp8
13458 (check-mu-read-from-stream-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13459 e9/jump $check-mu-primitive:end/disp32
13460 }
13461
13462 {
13463 (string-equal? %ecx "write-to-stream")
13464 3d/compare-eax-and 0/imm32/false
13465 74/jump-if-= break/disp8
13466 (check-mu-write-to-stream-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13467 e9/jump $check-mu-primitive:end/disp32
13468 }
13469
13470 {
13471 (string-equal? %ecx "convert")
13472 3d/compare-eax-and 0/imm32/false
13473 74/jump-if-= break/disp8
13474 (check-mu-convert-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13475 e9/jump $check-mu-primitive:end/disp32
13476 }
13477
13478 (check-mu-numberlike-primitive *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13479 $check-mu-primitive:end:
13480
13481 59/pop-to-ecx
13482 58/pop-to-eax
13483
13484 89/<- %esp 5/r32/ebp
13485 5d/pop-to-ebp
13486 c3/return
13487
13488
13489 check-mu-numberlike-primitive:
13490
13491 55/push-ebp
13492 89/<- %ebp 4/r32/esp
13493
13494 50/push-eax
13495 51/push-ecx
13496 56/push-esi
13497
13498 8b/-> *(ebp+8) 6/r32/esi
13499
13500 b9/copy-to-ecx 2/imm32
13501
13502
13503 (lookup *(esi+0x14) *(esi+0x18))
13504 {
13505 3d/compare-eax-and 0/imm32
13506 74/jump-if-= break/disp8
13507 $check-mu-numberlike-primitive:output:
13508 (check-mu-numberlike-output %eax *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13509 (lookup *(eax+8) *(eax+0xc))
13510 3d/compare-eax-and 0/imm32
13511 0f 85/jump-if-!= $check-mu-numberlike-primitive:error-too-many-outputs/disp32
13512
13513
13514 49/decrement-ecx
13515 }
13516
13517 (lookup *(esi+0xc) *(esi+0x10))
13518 {
13519 3d/compare-eax-and 0/imm32
13520 0f 84/jump-if-= $check-mu-numberlike-primitive:end/disp32
13521 $check-mu-numberlike-primitive:first-inout:
13522 (check-mu-numberlike-arg %eax *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13523
13524 49/decrement-ecx
13525 }
13526
13527 (lookup *(eax+8) *(eax+0xc))
13528 {
13529 3d/compare-eax-and 0/imm32
13530 74/jump-if-= $check-mu-numberlike-primitive:end/disp8
13531 $check-mu-numberlike-primitive:second-inout:
13532
13533 81 7/subop/compare %ecx 0/imm32
13534 0f 84/jump-if-= $check-mu-numberlike-primitive:error-too-many-inouts/disp32
13535 $check-mu-numberlike-primitive:second-inout-permitted:
13536 (check-mu-numberlike-arg %eax *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
13537 }
13538 $check-mu-numberlike-primitive:third-inout:
13539
13540 81 7/subop/compare *(eax+8) 0/imm32
13541 0f 85/jump-if-!= $check-mu-numberlike-primitive:error-too-many-inouts/disp32
13542 $check-mu-numberlike-primitive:end:
13543
13544 5e/pop-to-esi
13545 59/pop-to-ecx
13546 58/pop-to-eax
13547
13548 89/<- %esp 5/r32/ebp
13549 5d/pop-to-ebp
13550 c3/return
13551
13552 $check-mu-numberlike-primitive:error-too-many-inouts:
13553 (write-buffered *(ebp+0x10) "fn ")
13554 8b/-> *(ebp+0xc) 0/r32/eax
13555 (lookup *eax *(eax+4))
13556 (write-buffered *(ebp+0x10) %eax)
13557 (write-buffered *(ebp+0x10) ": stmt ")
13558 (lookup *(esi+4) *(esi+8))
13559 (write-buffered *(ebp+0x10) %eax)
13560 (write-buffered *(ebp+0x10) ": too many inouts; most primitives support at most two arguments, across inouts and outputs\n")
13561 (flush *(ebp+0x10))
13562 (stop *(ebp+0x14) 1)
13563
13564
13565 $check-mu-numberlike-primitive:error-too-many-outputs:
13566 (write-buffered *(ebp+0x10) "fn ")
13567 8b/-> *(ebp+0xc) 0/r32/eax
13568 (lookup *eax *(eax+4))
13569 (write-buffered *(ebp+0x10) %eax)
13570 (write-buffered *(ebp+0x10) ": stmt ")
13571 (lookup *(esi+4) *(esi+8))
13572 (write-buffered *(ebp+0x10) %eax)
13573 (write-buffered *(ebp+0x10) ": too many outputs; most primitives support at most one output\n")
13574 (flush *(ebp+0x10))
13575 (stop *(ebp+0x14) 1)
13576
13577
13578 check-mu-numberlike-arg:
13579
13580 55/push-ebp
13581 89/<- %ebp 4/r32/esp
13582
13583 50/push-eax
13584 56/push-esi
13585
13586 8b/-> *(ebp+8) 0/r32/eax
13587 (lookup *eax *(eax+4))
13588 (lookup *(eax+8) *(eax+0xc))
13589 89/<- %esi 0/r32/eax
13590 $check-mu-numberlike-arg:check-literal:
13591
13592 (is-simple-mu-type? %esi 0)
13593 3d/compare-eax-and 0/imm32/false
13594 75/jump-if-!= $check-mu-numberlike-arg:end/disp8
13595 $check-mu-numberlike-arg:check-addr:
13596
13597 {
13598 (is-mu-addr-type? %esi)
13599 3d/compare-eax-and 0/imm32/false
13600 74/jump-if-= break/disp8
13601 8b/-> *(ebp+8) 0/r32/eax
13602 8b/-> *(eax+0x10) 0/r32/eax
13603 3d/compare-eax-and 0/imm32/false
13604 75/jump-if-!= $check-mu-numberlike-arg:end/disp8
13605 }
13606 $check-mu-numberlike-arg:output-checks:
13607 (check-mu-numberlike-output *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14) *(ebp+0x18))
13608 $check-mu-numberlike-arg:end:
13609
13610 5e/pop-to-esi
13611 58/pop-to-eax
13612
13613 89/<- %esp 5/r32/ebp
13614 5d/pop-to-ebp
13615 c3/return
13616
13617 check-mu-numberlike-output:
13618
13619 55/push-ebp
13620 89/<- %ebp 4/r32/esp
13621
13622 50/push-eax
13623 56/push-esi
13624
13625 8b/-> *(ebp+8) 0/r32/eax
13626 (lookup *eax *(eax+4))
13627 (lookup *(eax+8) *(eax+0xc))
13628 89/<- %esi 0/r32/eax
13629 $check-mu-numberlike-output:check-int:
13630
13631 (is-simple-mu-type? %esi 1)
13632 3d/compare-eax-and 0/imm32/false
13633 0f 85/jump-if-!= $check-mu-numberlike-output:end/disp32
13634 $check-mu-numberlike-output:check-float:
13635
13636 (is-simple-mu-type? %esi 0xf)
13637 3d/compare-eax-and 0/imm32/false
13638 75/jump-if-!= $check-mu-numberlike-output:end/disp8
13639 $check-mu-numberlike-output:check-boolean:
13640
13641 (is-simple-mu-type? %esi 5)
13642 3d/compare-eax-and 0/imm32/false
13643 75/jump-if-!= $check-mu-numberlike-output:end/disp8
13644 $check-mu-numberlike-output:check-byte:
13645
13646 (is-simple-mu-type? %esi 8)
13647 3d/compare-eax-and 0/imm32/false
13648 75/jump-if-!= $check-mu-numberlike-output:end/disp8
13649 $check-mu-numberlike-output:check-code-point:
13650
13651 (is-simple-mu-type? %esi 0xd)
13652 3d/compare-eax-and 0/imm32/false
13653 75/jump-if-!= $check-mu-numberlike-output:end/disp8
13654 $check-mu-numberlike-output:check-grapheme:
13655
13656 (is-simple-mu-type? %esi 0xe)
13657 3d/compare-eax-and 0/imm32/false
13658 75/jump-if-!= $check-mu-numberlike-output:end/disp8
13659 e9/jump $check-mu-numberlike-output:fail/disp32
13660 $check-mu-numberlike-output:end:
13661
13662 5e/pop-to-esi
13663 58/pop-to-eax
13664
13665 89/<- %esp 5/r32/ebp
13666 5d/pop-to-ebp
13667 c3/return
13668
13669 $check-mu-numberlike-output:fail:
13670
13671 (write-buffered *(ebp+0x14) "fn ")
13672 8b/-> *(ebp+0x10) 0/r32/eax
13673 (lookup *eax *(eax+4))
13674 (write-buffered *(ebp+0x14) %eax)
13675 (write-buffered *(ebp+0x14) ": stmt ")
13676 8b/-> *(ebp+0xc) 0/r32/eax
13677 (lookup *(eax+4) *(eax+8))
13678 (write-buffered *(ebp+0x14) %eax)
13679 (write-buffered *(ebp+0x14) ": only non-addr scalar args permitted\n")
13680 (flush *(ebp+0x14))
13681 (stop *(ebp+0x18) 1)
13682
13683
13684 check-mu-copy-stmt:
13685
13686 55/push-ebp
13687 89/<- %ebp 4/r32/esp
13688
13689 $check-mu-copy-stmt:end:
13690
13691
13692 89/<- %esp 5/r32/ebp
13693 5d/pop-to-ebp
13694 c3/return
13695
13696 check-mu-copy-to-stmt:
13697
13698 55/push-ebp
13699 89/<- %ebp 4/r32/esp
13700
13701 $check-mu-copy-to-stmt:end:
13702
13703
13704 89/<- %esp 5/r32/ebp
13705 5d/pop-to-ebp
13706 c3/return
13707
13708 check-mu-compare-stmt:
13709
13710 55/push-ebp
13711 89/<- %ebp 4/r32/esp
13712
13713 $check-mu-compare-stmt:end:
13714
13715
13716 89/<- %esp 5/r32/ebp
13717 5d/pop-to-ebp
13718 c3/return
13719
13720 check-mu-address-stmt:
13721
13722 55/push-ebp
13723 89/<- %ebp 4/r32/esp
13724
13725 $check-mu-address-stmt:end:
13726
13727
13728 89/<- %esp 5/r32/ebp
13729 5d/pop-to-ebp
13730 c3/return
13731
13732 check-mu-get-stmt:
13733
13734 55/push-ebp
13735 89/<- %ebp 4/r32/esp
13736
13737 50/push-eax
13738 51/push-ecx
13739 52/push-edx
13740 53/push-ebx
13741 56/push-esi
13742 57/push-edi
13743
13744 8b/-> *(ebp+8) 6/r32/esi
13745
13746
13747 (lookup *(esi+0xc) *(esi+0x10))
13748 3d/compare-eax-and 0/imm32/false
13749 0f 84/jump-if-= $check-mu-get-stmt:error-too-few-inouts/disp32
13750 (lookup *eax *(eax+4))
13751 89/<- %ecx 0/r32/eax
13752 $check-mu-get-stmt:check-base:
13753
13754
13755
13756 (lookup *(ecx+8) *(ecx+0xc))
13757 89/<- %ebx 0/r32/eax
13758 {
13759 81 7/subop/compare *ebx 0/imm32/false
13760 0f 85/jump-if-!= break/disp32
13761 $check-mu-get-stmt:base-is-compound:
13762
13763 (lookup *(ebx+4) *(ebx+8))
13764 (is-simple-mu-type? %eax 2)
13765 3d/compare-eax-and 0/imm32/false
13766 74/jump-if-= break/disp8
13767 $check-mu-get-stmt:base-is-addr:
13768
13769 81 7/subop/compare *(ecx+0x18) 0/imm32
13770 0f 84/jump-if-= $check-mu-get-stmt:error-base-type-addr-but-not-register/disp32
13771 $check-mu-get-stmt:base-is-addr-in-register:
13772
13773 (lookup *(ebx+0xc) *(ebx+0x10))
13774 81 7/subop/compare *(eax+0xc) 0/imm32
13775 0f 85/jump-if-!= $check-mu-get-stmt:error-bad-base/disp32
13776 $check-mu-get-stmt:base-is-addr-to-atom-in-register:
13777 (lookup *(eax+4) *(eax+8))
13778 89/<- %ebx 0/r32/eax
13779 }
13780 $check-mu-get-stmt:check-base-typeinfo:
13781
13782
13783 8b/-> *(ebx+4) 3/r32/ebx
13784 (is-container? %ebx)
13785 3d/compare-eax-and 0/imm32/false
13786 0f 84/jump-if-= $check-mu-get-stmt:error-bad-base/disp32
13787
13788
13789 68/push 0/imm32
13790 68/push 0/imm32
13791 89/<- %ecx 4/r32/esp
13792
13793 (find-typeinfo %ebx %ecx)
13794 (lookup *ecx *(ecx+4))
13795
13796 81 0/subop/add %esp 8/imm32
13797
13798 89/<- %edx 0/r32/eax
13799
13800 (lookup *(esi+0xc) *(esi+0x10))
13801 (lookup *(eax+8) *(eax+0xc))
13802 89/<- %ecx 0/r32/eax
13803
13804 3d/compare-eax-and 0/imm32/false
13805 0f 84/jump-if-= $check-mu-get-stmt:error-too-few-inouts/disp32
13806
13807 (lookup *ecx *(ecx+4))
13808 89/<- %ecx 0/r32/eax
13809
13810 81 7/subop/compare *(ecx+0x14) -1/imm32/uninitialized
13811 0f 84/jump-if-= $check-mu-get-stmt:error-bad-field/disp32
13812
13813 (lookup *(esi+0xc) *(esi+0x10))
13814 (lookup *(eax+8) *(eax+0xc))
13815 (lookup *(eax+8) *(eax+0xc))
13816 3d/compare-eax-and 0/imm32/false
13817 0f 85/jump-if-!= $check-mu-get-stmt:error-too-many-inouts/disp32
13818
13819 (lookup *(esi+0x14) *(esi+0x18))
13820
13821 3d/compare-eax-and 0/imm32/false
13822 0f 84/jump-if-= $check-mu-get-stmt:error-too-few-outputs/disp32
13823 (lookup *eax *(eax+4))
13824 89/<- %edi 0/r32/eax
13825 $check-mu-get-stmt:check-output-type:
13826
13827
13828 (lookup *(edi+0x18) *(edi+0x1c))
13829 3d/compare-eax-and 0/imm32
13830 0f 84/jump-if-= $check-mu-get-stmt:error-output-not-in-register/disp32
13831
13832 (lookup *(edi+8) *(edi+0xc))
13833 81 7/subop/compare *eax 0/imm32/false
13834 0f 85/jump-if-!= $check-mu-get-stmt:error-output-type-not-address/disp32
13835
13836 (lookup *(eax+4) *(eax+8))
13837 (is-simple-mu-type? %eax 2)
13838 3d/compare-eax-and 0/imm32/false
13839 0f 84/jump-if-= $check-mu-get-stmt:error-output-type-not-address/disp32
13840 $check-mu-get-stmt:check-output-type-match:
13841
13842 (lookup *(edi+8) *(edi+0xc))
13843 (lookup *(eax+0xc) *(eax+0x10))
13844
13845 81 7/subop/compare *(eax+0xc) 0/imm32/null
13846 {
13847 75/jump-if-!= break/disp8
13848 (lookup *(eax+4) *(eax+8))
13849 }
13850 89/<- %edi 0/r32/eax
13851
13852 (lookup *ecx *(ecx+4))
13853 89/<- %ecx 0/r32/eax
13854
13855 (lookup *(edx+4) *(edx+8))
13856 (get %eax %ecx 0x10)
13857
13858 (lookup *eax *(eax+4))
13859 (lookup *eax *(eax+4))
13860 (lookup *(eax+8) *(eax+0xc))
13861
13862 (type-equal? %edi %eax)
13863 3d/compare-eax-and 0/imm32/false
13864 0f 84/jump-if-= $check-mu-get-stmt:error-bad-output-type/disp32
13865
13866 (lookup *(esi+0x14) *(esi+0x18))
13867 (lookup *(eax+8) *(eax+0xc))
13868 3d/compare-eax-and 0/imm32/false
13869 0f 85/jump-if-!= $check-mu-get-stmt:error-too-many-outputs/disp32
13870 $check-mu-get-stmt:end:
13871
13872 5f/pop-to-edi
13873 5e/pop-to-esi
13874 5b/pop-to-ebx
13875 5a/pop-to-edx
13876 59/pop-to-ecx
13877 58/pop-to-eax
13878
13879 89/<- %esp 5/r32/ebp
13880 5d/pop-to-ebp
13881 c3/return
13882
13883 $check-mu-get-stmt:error-too-few-inouts:
13884 (write-buffered *(ebp+0x10) "fn ")
13885 8b/-> *(ebp+0xc) 0/r32/eax
13886 (lookup *eax *(eax+4))
13887 (write-buffered *(ebp+0x10) %eax)
13888 (write-buffered *(ebp+0x10) ": stmt get: too few inouts (2 required)\n")
13889 (flush *(ebp+0x10))
13890 (stop *(ebp+0x14) 1)
13891
13892
13893 $check-mu-get-stmt:error-too-many-inouts:
13894 (write-buffered *(ebp+0x10) "fn ")
13895 8b/-> *(ebp+0xc) 0/r32/eax
13896 (lookup *eax *(eax+4))
13897 (write-buffered *(ebp+0x10) %eax)
13898 (write-buffered *(ebp+0x10) ": stmt get: too many inouts (2 required)\n")
13899 (flush *(ebp+0x10))
13900 (stop *(ebp+0x14) 1)
13901
13902
13903 $check-mu-get-stmt:error-too-few-outputs:
13904 (write-buffered *(ebp+0x10) "fn ")
13905 8b/-> *(ebp+0xc) 0/r32/eax
13906 (lookup *eax *(eax+4))
13907 (write-buffered *(ebp+0x10) %eax)
13908 (write-buffered *(ebp+0x10) ": stmt get: must have an output\n")
13909 (flush *(ebp+0x10))
13910 (stop *(ebp+0x14) 1)
13911
13912
13913 $check-mu-get-stmt:error-too-many-outputs:
13914 (write-buffered *(ebp+0x10) "fn ")
13915 8b/-> *(ebp+0xc) 0/r32/eax
13916 (lookup *eax *(eax+4))
13917 (write-buffered *(ebp+0x10) %eax)
13918 (write-buffered *(ebp+0x10) ": stmt get: too many outputs (1 required)\n")
13919 (flush *(ebp+0x10))
13920 (stop *(ebp+0x14) 1)
13921
13922
13923 $check-mu-get-stmt:error-bad-base:
13924
13925 (write-buffered *(ebp+0x10) "fn ")
13926 8b/-> *(ebp+0xc) 0/r32/eax
13927 (lookup *eax *(eax+4))
13928 (write-buffered *(ebp+0x10) %eax)
13929 (write-buffered *(ebp+0x10) ": stmt get: var '")
13930 (lookup *(esi+0xc) *(esi+0x10))
13931 (lookup *eax *(eax+4))
13932 (lookup *eax *(eax+4))
13933 (write-buffered *(ebp+0x10) %eax)
13934 (write-buffered *(ebp+0x10) "' must have a 'type' definition\n")
13935 (flush *(ebp+0x10))
13936 (stop *(ebp+0x14) 1)
13937
13938
13939 $check-mu-get-stmt:error-base-type-addr-but-not-register:
13940 (write-buffered *(ebp+0x10) "fn ")
13941 8b/-> *(ebp+0xc) 0/r32/eax
13942 (lookup *eax *(eax+4))
13943 (write-buffered *(ebp+0x10) %eax)
13944 (write-buffered *(ebp+0x10) ": stmt get: var '")
13945 (lookup *(esi+0xc) *(esi+0x10))
13946 (lookup *eax *(eax+4))
13947 (lookup *eax *(eax+4))
13948 (write-buffered *(ebp+0x10) %eax)
13949 (write-buffered *(ebp+0x10) "' is an 'addr' type, and so must live in a register\n")
13950 (flush *(ebp+0x10))
13951 (stop *(ebp+0x14) 1)
13952
13953
13954 $check-mu-get-stmt:error-bad-field:
13955
13956 (write-buffered *(ebp+0x10) "fn ")
13957 8b/-> *(ebp+0xc) 0/r32/eax
13958 (lookup *eax *(eax+4))
13959 (write-buffered *(ebp+0x10) %eax)
13960 (write-buffered *(ebp+0x10) ": stmt get: type '")
13961
13962 bf/copy-to-edi Type-id/imm32
13963 (write-buffered *(ebp+0x10) *(edi+ebx<<2+0xc))
13964
13965 (write-buffered *(ebp+0x10) "' has no member called '")
13966 (lookup *ecx *(ecx+4))
13967 (write-buffered *(ebp+0x10) %eax)
13968 (write-buffered *(ebp+0x10) "'\n")
13969 (flush *(ebp+0x10))
13970 (stop *(ebp+0x14) 1)
13971
13972
13973 $check-mu-get-stmt:error-output-not-in-register:
13974 (write-buffered *(ebp+0x10) "fn ")
13975 8b/-> *(ebp+0xc) 0/r32/eax
13976 (lookup *eax *(eax+4))
13977 (write-buffered *(ebp+0x10) %eax)
13978 (write-buffered *(ebp+0x10) ": stmt get: output '")
13979 (lookup *edi *(edi+4))
13980 (write-buffered *(ebp+0x10) %eax)
13981 (write-buffered *(ebp+0x10) "' is not in a register\n")
13982 (flush *(ebp+0x10))
13983 (stop *(ebp+0x14) 1)
13984
13985
13986 $check-mu-get-stmt:error-output-type-not-address:
13987 (write-buffered *(ebp+0x10) "fn ")
13988 8b/-> *(ebp+0xc) 0/r32/eax
13989 (lookup *eax *(eax+4))
13990 (write-buffered *(ebp+0x10) %eax)
13991 (write-buffered *(ebp+0x10) ": stmt get: output must be an address\n")
13992 (flush *(ebp+0x10))
13993 (stop *(ebp+0x14) 1)
13994
13995
13996 $check-mu-get-stmt:error-bad-output-type:
13997 (write-buffered *(ebp+0x10) "fn ")
13998 8b/-> *(ebp+0xc) 0/r32/eax
13999 (lookup *eax *(eax+4))
14000 (write-buffered *(ebp+0x10) %eax)
14001 (write-buffered *(ebp+0x10) ": stmt get: wrong output type for member '")
14002 (write-buffered *(ebp+0x10) %ecx)
14003 (write-buffered *(ebp+0x10) "' of type '")
14004 bf/copy-to-edi Type-id/imm32
14005 (write-buffered *(ebp+0x10) *(edi+ebx<<2+0xc))
14006 (write-buffered *(ebp+0x10) "'\n")
14007 (flush *(ebp+0x10))
14008 (stop *(ebp+0x14) 1)
14009
14010
14011 check-mu-index-stmt:
14012
14013 55/push-ebp
14014 89/<- %ebp 4/r32/esp
14015
14016 50/push-eax
14017 51/push-ecx
14018 52/push-edx
14019 53/push-ebx
14020 56/push-esi
14021 57/push-edi
14022
14023 8b/-> *(ebp+8) 6/r32/esi
14024
14025
14026 (lookup *(esi+0xc) *(esi+0x10))
14027 $check-mu-index-stmt:check-no-inouts:
14028 3d/compare-eax-and 0/imm32
14029 0f 84/jump-if-= $check-mu-index-stmt:error-too-few-inouts/disp32
14030 (lookup *eax *(eax+4))
14031 89/<- %ecx 0/r32/eax
14032
14033
14034 (lookup *(ecx+8) *(ecx+0xc))
14035 89/<- %ebx 0/r32/eax
14036
14037 81 7/subop/compare *ebx 0/imm32/false
14038 {
14039 74/jump-if-= break/disp8
14040 (is-simple-mu-type? %ebx 3)
14041 3d/compare-eax-and 0/imm32/false
14042 0f 85/jump-if-!= $check-mu-index-stmt:error-base-array-atom-type/disp32
14043 0f 84/jump-if-= $check-mu-index-stmt:error-base-non-array-type/disp32
14044 }
14045 $check-mu-index-stmt:base-is-compound:
14046
14047 {
14048 (lookup *(ebx+4) *(ebx+8))
14049 (is-simple-mu-type? %eax 2)
14050 3d/compare-eax-and 0/imm32/false
14051 75/jump-if-!= break/disp8
14052 (lookup *(ebx+4) *(ebx+8))
14053 (is-simple-mu-type? %eax 3)
14054 3d/compare-eax-and 0/imm32/false
14055 75/jump-if-!= break/disp8
14056 e9/jump $check-mu-index-stmt:error-base-non-array-type/disp32
14057 }
14058
14059 {
14060 (lookup *(ebx+4) *(ebx+8))
14061 (is-simple-mu-type? %eax 2)
14062 3d/compare-eax-and 0/imm32/false
14063 74/jump-if-= break/disp8
14064 $check-mu-index-stmt:base-is-addr:
14065 (lookup *(ebx+0xc) *(ebx+0x10))
14066 (lookup *(eax+4) *(eax+8))
14067 (is-simple-mu-type? %eax 3)
14068 3d/compare-eax-and 0/imm32/false
14069 0f 84/jump-if-= $check-mu-index-stmt:error-base-non-array-type/disp32
14070 $check-mu-index-stmt:check-base-addr-is-register:
14071 81 7/subop/compare *(ecx+0x18) 0/imm32
14072 0f 84/jump-if-= $check-mu-index-stmt:error-base-address-array-type-on-stack/disp32
14073 }
14074
14075 {
14076 (lookup *(ebx+4) *(ebx+8))
14077 (is-simple-mu-type? %eax 3)
14078 3d/compare-eax-and 0/imm32/false
14079 74/jump-if-= break/disp8
14080 $check-mu-index-stmt:base-is-array:
14081 81 7/subop/compare *(ecx+0x18) 0/imm32
14082 0f 85/jump-if-!= $check-mu-index-stmt:error-base-array-type-in-register/disp32
14083 }
14084
14085 {
14086 (lookup *(ebx+4) *(ebx+8))
14087 (is-simple-mu-type? %eax 2)
14088 3d/compare-eax-and 0/imm32/false
14089 74/jump-if-= break/disp8
14090 (lookup *(ebx+0xc) *(ebx+0x10))
14091 89/<- %ebx 0/r32/eax
14092 }
14093
14094
14095 (lookup *(esi+0xc) *(esi+0x10))
14096 (lookup *(eax+8) *(eax+0xc))
14097 $check-mu-index-stmt:check-single-inout:
14098 3d/compare-eax-and 0/imm32
14099 0f 84/jump-if-= $check-mu-index-stmt:error-too-few-inouts/disp32
14100 (lookup *eax *(eax+4))
14101 89/<- %ecx 0/r32/eax
14102
14103
14104 (lookup *(ecx+8) *(ecx+0xc))
14105 89/<- %edx 0/r32/eax
14106
14107 81 7/subop/compare *edx 0/imm32/false
14108 {
14109 74/jump-if-= break/disp8
14110 $check-mu-index-stmt:index-type-is-atom:
14111 (is-simple-mu-type? %edx 0)
14112 3d/compare-eax-and 0/imm32/false
14113 75/jump-if-!= $check-mu-index-stmt:index-type-done/disp8
14114 (is-simple-mu-type? %edx 1)
14115 3d/compare-eax-and 0/imm32/false
14116 75/jump-if-!= $check-mu-index-stmt:index-type-done/disp8
14117 (is-simple-mu-type? %edx 7)
14118 3d/compare-eax-and 0/imm32/false
14119 0f 85/jump-if-!= $check-mu-index-stmt:error-index-offset-atom-type/disp32
14120 e9/jump $check-mu-index-stmt:error-invalid-index-type/disp32
14121 }
14122
14123 {
14124 75/jump-if-!= break/disp8
14125 $check-mu-index-stmt:index-type-is-non-atom:
14126 (lookup *(edx+4) *(edx+8))
14127 (is-simple-mu-type? %eax 7)
14128 3d/compare-eax-and 0/imm32/false
14129 0f 84/jump-if-= $check-mu-index-stmt:error-invalid-index-type/disp32
14130 }
14131 $check-mu-index-stmt:index-type-done:
14132
14133 {
14134 (is-simple-mu-type? %edx 0)
14135 3d/compare-eax-and 0/imm32/false
14136 75/jump-if-!= break/disp8
14137 $check-mu-index-stmt:check-index-in-register:
14138 81 7/subop/compare *(ecx+0x18) 0/imm32
14139 0f 84/jump-if-= $check-mu-index-stmt:error-index-on-stack/disp32
14140 }
14141
14142 {
14143 (is-simple-mu-type? %edx 1)
14144 3d/compare-eax-and 0/imm32/false
14145 74/jump-if-= break/disp8
14146 $check-mu-index-stmt:check-index-can-be-int:
14147 (lookup *(esi+0xc) *(esi+0x10))
14148 (lookup *eax *(eax+4))
14149 (array-element-size %eax)
14150 3d/compare-eax-and 1/imm32
14151 74/jump-if-= break/disp8
14152 3d/compare-eax-and 2/imm32
14153 74/jump-if-= break/disp8
14154 3d/compare-eax-and 4/imm32
14155 74/jump-if-= break/disp8
14156 3d/compare-eax-and 8/imm32
14157 74/jump-if-= break/disp8
14158 e9/jump $check-mu-index-stmt:error-index-needs-offset/disp32
14159 }
14160
14161 (lookup *(esi+0xc) *(esi+0x10))
14162 (lookup *(eax+8) *(eax+0xc))
14163 (lookup *(eax+8) *(eax+0xc))
14164 3d/compare-eax-and 0/imm32/false
14165 0f 85/jump-if-!= $check-mu-index-stmt:error-too-many-inouts/disp32
14166
14167
14168 (lookup *(esi+0x14) *(esi+0x18))
14169 3d/compare-eax-and 0/imm32/false
14170 0f 84/jump-if-= $check-mu-index-stmt:error-too-few-outputs/disp32
14171 (lookup *eax *(eax+4))
14172 89/<- %edi 0/r32/eax
14173
14174
14175 (lookup *(edi+8) *(edi+0xc))
14176 89/<- %edx 0/r32/eax
14177 81 7/subop/compare *edx 0/imm32/false
14178 0f 85/jump-if-!= $check-mu-index-stmt:error-output-type-not-address/disp32
14179
14180 (lookup *(edx+4) *(edx+8))
14181 (is-simple-mu-type? %eax 2)
14182 3d/compare-eax-and 0/imm32/false
14183 0f 84/jump-if-= $check-mu-index-stmt:error-output-type-not-address/disp32
14184
14185 (type-tail %ebx)
14186 89/<- %ebx 0/r32/eax
14187 (type-tail %edx)
14188 (type-equal? %ebx %eax)
14189 3d/compare-eax-and 0/imm32/false
14190 0f 84/jump-if-= $check-mu-index-stmt:error-bad-output-type/disp32
14191
14192 (lookup *(esi+0x14) *(esi+0x18))
14193 (lookup *(eax+8) *(eax+0xc))
14194 3d/compare-eax-and 0/imm32/false
14195 0f 85/jump-if-!= $check-mu-index-stmt:error-too-many-outputs/disp32
14196 $check-mu-index-stmt:end:
14197
14198 5f/pop-to-edi
14199 5e/pop-to-esi
14200 5b/pop-to-ebx
14201 5a/pop-to-edx
14202 59/pop-to-ecx
14203 58/pop-to-eax
14204
14205 89/<- %esp 5/r32/ebp
14206 5d/pop-to-ebp
14207 c3/return
14208
14209 $check-mu-index-stmt:error-base-non-array-type:
14210 (write-buffered *(ebp+0x10) "fn ")
14211 8b/-> *(ebp+0xc) 0/r32/eax
14212 (lookup *eax *(eax+4))
14213 (write-buffered *(ebp+0x10) %eax)
14214 (write-buffered *(ebp+0x10) ": stmt index: var '")
14215 (lookup *ecx *(ecx+4))
14216 (write-buffered *(ebp+0x10) %eax)
14217 (write-buffered *(ebp+0x10) "' is not an array\n")
14218 (flush *(ebp+0x10))
14219 (stop *(ebp+0x14) 1)
14220
14221
14222 $check-mu-index-stmt:error-base-array-atom-type:
14223 (write-buffered *(ebp+0x10) "fn ")
14224 8b/-> *(ebp+0xc) 0/r32/eax
14225 (lookup *eax *(eax+4))
14226 (write-buffered *(ebp+0x10) %eax)
14227 (write-buffered *(ebp+0x10) ": stmt index: array '")
14228 (lookup *ecx *(ecx+4))
14229 (write-buffered *(ebp+0x10) %eax)
14230 (write-buffered *(ebp+0x10) "' must specify the type of its elements\n")
14231 (flush *(ebp+0x10))
14232 (stop *(ebp+0x14) 1)
14233
14234
14235 $check-mu-index-stmt:error-base-address-array-type-on-stack:
14236 (write-buffered *(ebp+0x10) "fn ")
14237 8b/-> *(ebp+0xc) 0/r32/eax
14238 (lookup *eax *(eax+4))
14239 (write-buffered *(ebp+0x10) %eax)
14240 (write-buffered *(ebp+0x10) ": stmt index: var '")
14241 (lookup *ecx *(ecx+4))
14242 (write-buffered *(ebp+0x10) %eax)
14243 (write-buffered *(ebp+0x10) "' is an addr to an array, and so must live in a register\n")
14244 (flush *(ebp+0x10))
14245 (stop *(ebp+0x14) 1)
14246
14247
14248 $check-mu-index-stmt:error-base-array-type-in-register:
14249 (write-buffered *(ebp+0x10) "fn ")
14250 8b/-> *(ebp+0xc) 0/r32/eax
14251 (lookup *eax *(eax+4))
14252 (write-buffered *(ebp+0x10) %eax)
14253 (write-buffered *(ebp+0x10) ": stmt index: var '")
14254 (lookup *ecx *(ecx+4))
14255 (write-buffered *(ebp+0x10) %eax)
14256 (write-buffered *(ebp+0x10) "' is an array, and so must live on the stack\n")
14257 (flush *(ebp+0x10))
14258 (stop *(ebp+0x14) 1)
14259
14260
14261 $check-mu-index-stmt:error-too-few-inouts:
14262 (write-buffered *(ebp+0x10) "fn ")
14263 8b/-> *(ebp+0xc) 0/r32/eax
14264 (lookup *eax *(eax+4))
14265 (write-buffered *(ebp+0x10) %eax)
14266 (write-buffered *(ebp+0x10) ": stmt index: too few inouts (2 required)\n")
14267 (flush *(ebp+0x10))
14268 (stop *(ebp+0x14) 1)
14269
14270
14271 $check-mu-index-stmt:error-invalid-index-type:
14272 (write-buffered *(ebp+0x10) "fn ")
14273 8b/-> *(ebp+0xc) 0/r32/eax
14274 (lookup *eax *(eax+4))
14275 (write-buffered *(ebp+0x10) %eax)
14276 (write-buffered *(ebp+0x10) ": stmt index: second argument '")
14277 (lookup *ecx *(ecx+4))
14278 (write-buffered *(ebp+0x10) %eax)
14279 (write-buffered *(ebp+0x10) "' must be an int or offset\n")
14280 (flush *(ebp+0x10))
14281 (stop *(ebp+0x14) 1)
14282
14283
14284 $check-mu-index-stmt:error-index-offset-atom-type:
14285 (write-buffered *(ebp+0x10) "fn ")
14286 8b/-> *(ebp+0xc) 0/r32/eax
14287 (lookup *eax *(eax+4))
14288 (write-buffered *(ebp+0x10) %eax)
14289 (write-buffered *(ebp+0x10) ": stmt index: offset '")
14290 (lookup *ecx *(ecx+4))
14291 (write-buffered *(ebp+0x10) %eax)
14292 (write-buffered *(ebp+0x10) "' must specify the type of array elements\n")
14293 (flush *(ebp+0x10))
14294 (stop *(ebp+0x14) 1)
14295
14296
14297 $check-mu-index-stmt:error-index-on-stack:
14298 (write-buffered *(ebp+0x10) "fn ")
14299 8b/-> *(ebp+0xc) 0/r32/eax
14300 (lookup *eax *(eax+4))
14301 (write-buffered *(ebp+0x10) %eax)
14302 (write-buffered *(ebp+0x10) ": stmt index: second argument '")
14303 (lookup *ecx *(ecx+4))
14304 (write-buffered *(ebp+0x10) %eax)
14305 (write-buffered *(ebp+0x10) "' must be in a register\n")
14306 (flush *(ebp+0x10))
14307 (stop *(ebp+0x14) 1)
14308
14309
14310 $check-mu-index-stmt:error-index-needs-offset:
14311 (write-buffered *(ebp+0x10) "fn ")
14312 8b/-> *(ebp+0xc) 0/r32/eax
14313 (lookup *eax *(eax+4))
14314 (write-buffered *(ebp+0x10) %eax)
14315 (write-buffered *(ebp+0x10) ": stmt index: cannot take an int for array '")
14316 (lookup *(esi+0xc) *(esi+0x10))
14317 (lookup *eax *(eax+4))
14318 (lookup *eax *(eax+4))
14319 (write-buffered *(ebp+0x10) %eax)
14320 (write-buffered *(ebp+0x10) "'; create an offset instead. See mu.md for details.\n")
14321 (flush *(ebp+0x10))
14322 (stop *(ebp+0x14) 1)
14323
14324
14325 $check-mu-index-stmt:error-too-many-inouts:
14326 (write-buffered *(ebp+0x10) "fn ")
14327 8b/-> *(ebp+0xc) 0/r32/eax
14328 (lookup *eax *(eax+4))
14329 (write-buffered *(ebp+0x10) %eax)
14330 (write-buffered *(ebp+0x10) ": stmt index: too many inouts (2 required)\n")
14331 (flush *(ebp+0x10))
14332 (stop *(ebp+0x14) 1)
14333
14334
14335 $check-mu-index-stmt:error-too-few-outputs:
14336 (write-buffered *(ebp+0x10) "fn ")
14337 8b/-> *(ebp+0xc) 0/r32/eax
14338 (lookup *eax *(eax+4))
14339 (write-buffered *(ebp+0x10) %eax)
14340 (write-buffered *(ebp+0x10) ": stmt index: must have an output\n")
14341 (flush *(ebp+0x10))
14342 (stop *(ebp+0x14) 1)
14343
14344
14345 $check-mu-index-stmt:error-too-many-outputs:
14346 (write-buffered *(ebp+0x10) "fn ")
14347 8b/-> *(ebp+0xc) 0/r32/eax
14348 (lookup *eax *(eax+4))
14349 (write-buffered *(ebp+0x10) %eax)
14350 (write-buffered *(ebp+0x10) ": stmt index: too many outputs (1 required)\n")
14351 (flush *(ebp+0x10))
14352 (stop *(ebp+0x14) 1)
14353
14354
14355 $check-mu-index-stmt:error-output-not-in-register:
14356 (write-buffered *(ebp+0x10) "fn ")
14357 8b/-> *(ebp+0xc) 0/r32/eax
14358 (lookup *eax *(eax+4))
14359 (write-buffered *(ebp+0x10) %eax)
14360 (write-buffered *(ebp+0x10) ": stmt index: output '")
14361 (lookup *edi *(edi+4))
14362 (write-buffered *(ebp+0x10) %eax)
14363 (write-buffered *(ebp+0x10) "' is not in a register\n")
14364 (flush *(ebp+0x10))
14365 (stop *(ebp+0x14) 1)
14366
14367
14368 $check-mu-index-stmt:error-output-type-not-address:
14369 (write-buffered *(ebp+0x10) "fn ")
14370 8b/-> *(ebp+0xc) 0/r32/eax
14371 (lookup *eax *(eax+4))
14372 (write-buffered *(ebp+0x10) %eax)
14373 (write-buffered *(ebp+0x10) ": stmt index: output '")
14374 (lookup *edi *(edi+4))
14375 (write-buffered *(ebp+0x10) %eax)
14376 (write-buffered *(ebp+0x10) "' must be an address\n")
14377 (flush *(ebp+0x10))
14378 (stop *(ebp+0x14) 1)
14379
14380
14381 $check-mu-index-stmt:error-bad-output-type:
14382 (write-buffered *(ebp+0x10) "fn ")
14383 8b/-> *(ebp+0xc) 0/r32/eax
14384 (lookup *eax *(eax+4))
14385 (write-buffered *(ebp+0x10) %eax)
14386 (write-buffered *(ebp+0x10) ": stmt index: output '")
14387 (lookup *edi *(edi+4))
14388 (write-buffered *(ebp+0x10) %eax)
14389 (write-buffered *(ebp+0x10) "' does not have the right type\n")
14390 (flush *(ebp+0x10))
14391 (stop *(ebp+0x14) 1)
14392
14393
14394 check-mu-length-stmt:
14395
14396 55/push-ebp
14397 89/<- %ebp 4/r32/esp
14398
14399 $check-mu-length-stmt:end:
14400
14401
14402 89/<- %esp 5/r32/ebp
14403 5d/pop-to-ebp
14404 c3/return
14405
14406 check-mu-compute-offset-stmt:
14407
14408 55/push-ebp
14409 89/<- %ebp 4/r32/esp
14410
14411 $check-mu-compute-offset-stmt:end:
14412
14413
14414 89/<- %esp 5/r32/ebp
14415 5d/pop-to-ebp
14416 c3/return
14417
14418 check-mu-copy-object-stmt:
14419
14420 55/push-ebp
14421 89/<- %ebp 4/r32/esp
14422
14423 $check-mu-copy-object-stmt:end:
14424
14425
14426 89/<- %esp 5/r32/ebp
14427 5d/pop-to-ebp
14428 c3/return
14429
14430 check-mu-allocate-stmt:
14431
14432 55/push-ebp
14433 89/<- %ebp 4/r32/esp
14434
14435 $check-mu-allocate-stmt:end:
14436
14437
14438 89/<- %esp 5/r32/ebp
14439 5d/pop-to-ebp
14440 c3/return
14441
14442 check-mu-populate-stmt:
14443
14444 55/push-ebp
14445 89/<- %ebp 4/r32/esp
14446
14447 $check-mu-populate-stmt:end:
14448
14449
14450 89/<- %esp 5/r32/ebp
14451 5d/pop-to-ebp
14452 c3/return
14453
14454 check-mu-populate-stream-stmt:
14455
14456 55/push-ebp
14457 89/<- %ebp 4/r32/esp
14458
14459 $check-mu-populate-stream-stmt:end:
14460
14461
14462 89/<- %esp 5/r32/ebp
14463 5d/pop-to-ebp
14464 c3/return
14465
14466 check-mu-read-from-stream-stmt:
14467
14468 55/push-ebp
14469 89/<- %ebp 4/r32/esp
14470
14471 $check-mu-read-from-stream-stmt:end:
14472
14473
14474 89/<- %esp 5/r32/ebp
14475 5d/pop-to-ebp
14476 c3/return
14477
14478 check-mu-write-to-stream-stmt:
14479
14480 55/push-ebp
14481 89/<- %ebp 4/r32/esp
14482
14483 $check-mu-write-to-stream-stmt:end:
14484
14485
14486 89/<- %esp 5/r32/ebp
14487 5d/pop-to-ebp
14488 c3/return
14489
14490 check-mu-convert-stmt:
14491
14492 55/push-ebp
14493 89/<- %ebp 4/r32/esp
14494
14495 $check-mu-convert-stmt:end:
14496
14497
14498 89/<- %esp 5/r32/ebp
14499 5d/pop-to-ebp
14500 c3/return
14501
14502 check-mu-call:
14503
14504 55/push-ebp
14505 89/<- %ebp 4/r32/esp
14506
14507 68/push 0/imm32
14508
14509 81 5/subop/subtract %esp 0x60/imm32
14510 68/push 0x60/imm32/size
14511 68/push 0/imm32/read
14512 68/push 0/imm32/write
14513
14514 89/<- *(ebp-4) 4/r32/esp
14515 (clear-stream *(ebp-4))
14516
14517 50/push-eax
14518 51/push-ecx
14519 52/push-edx
14520 53/push-ebx
14521 56/push-esi
14522 57/push-edi
14523
14524 8b/-> *(ebp+8) 6/r32/esi
14525
14526 8b/-> *(ebp+0xc) 7/r32/edi
14527
14528 (lookup *(esi+0xc) *(esi+0x10))
14529 89/<- %ecx 0/r32/eax
14530
14531 (lookup *(edi+8) *(edi+0xc))
14532 89/<- %edx 0/r32/eax
14533 {
14534 $check-mu-call:check-for-inouts:
14535
14536 81 7/subop/compare %ecx 0/imm32
14537 0f 84/jump-if-= break/disp32
14538
14539 81 7/subop/compare %edx 0/imm32
14540 0f 84/jump-if-= break/disp32
14541 $check-mu-call:check-inout-type:
14542
14543 (lookup *ecx *(ecx+4))
14544
14545 (lookup *(eax+8) *(eax+0xc))
14546 89/<- %ebx 0/r32/eax
14547
14548 81 7/subop/compare *(ecx+0x10) 0/imm32/false
14549 {
14550 74/jump-if-= break/disp8
14551 (lookup *(ebx+0xc) *(ebx+0x10))
14552 89/<- %ebx 0/r32/eax
14553
14554 81 7/subop/compare *(ebx+0xc) 0/imm32
14555 75/jump-if-!= break/disp8
14556 (lookup *(ebx+4) *(ebx+8))
14557 89/<- %ebx 0/r32/eax
14558 }
14559
14560 (lookup *edx *(edx+4))
14561
14562 (lookup *(eax+8) *(eax+0xc))
14563
14564 (type-match? %eax %ebx *(ebp-4))
14565 3d/compare-eax-and 0/imm32/false
14566 {
14567 0f 85/jump-if-!= break/disp32
14568 (write-buffered *(ebp+0x14) "fn ")
14569 8b/-> *(ebp+0x10) 0/r32/eax
14570 (lookup *eax *(eax+4))
14571 (write-buffered *(ebp+0x14) %eax)
14572 (write-buffered *(ebp+0x14) ": call ")
14573 (lookup *edi *(edi+4))
14574 (write-buffered *(ebp+0x14) %eax)
14575 (write-buffered *(ebp+0x14) ": type for inout '")
14576 (lookup *ecx *(ecx+4))
14577 (lookup *eax *(eax+4))
14578 (write-buffered *(ebp+0x14) %eax)
14579 (write-buffered *(ebp+0x14) "' is not right\n")
14580 (flush *(ebp+0x14))
14581 (stop *(ebp+0x18) 1)
14582 }
14583 $check-mu-call:continue-to-next-inout:
14584
14585 (lookup *(ecx+8) *(ecx+0xc))
14586 89/<- %ecx 0/r32/eax
14587
14588 (lookup *(edx+8) *(edx+0xc))
14589 89/<- %edx 0/r32/eax
14590
14591 e9/jump loop/disp32
14592 }
14593 $check-mu-call:check-inout-count:
14594
14595 39/compare %ecx 2/r32/edx
14596 {
14597 0f 84/jump-if-= break/disp32
14598
14599
14600 {
14601 81 7/subop/compare %ecx 0/imm32
14602 0f 84/jump-if-= break/disp32
14603 (write-buffered *(ebp+0x14) "fn ")
14604 8b/-> *(ebp+0x10) 0/r32/eax
14605 (lookup *eax *(eax+4))
14606 (write-buffered *(ebp+0x14) %eax)
14607 (write-buffered *(ebp+0x14) ": call ")
14608 (lookup *edi *(edi+4))
14609 (write-buffered *(ebp+0x14) %eax)
14610 (write-buffered *(ebp+0x14) ": too many inouts\n")
14611 (flush *(ebp+0x14))
14612 (stop *(ebp+0x18) 1)
14613 }
14614
14615 {
14616 81 7/subop/compare %edx 0/imm32
14617 0f 84/jump-if-= break/disp32
14618 (write-buffered *(ebp+0x14) "fn ")
14619 8b/-> *(ebp+0x10) 0/r32/eax
14620 (lookup *eax *(eax+4))
14621 (write-buffered *(ebp+0x14) %eax)
14622 (write-buffered *(ebp+0x14) ": call ")
14623 (lookup *edi *(edi+4))
14624 (write-buffered *(ebp+0x14) %eax)
14625 (write-buffered *(ebp+0x14) ": too few inouts\n")
14626 (flush *(ebp+0x14))
14627 (stop *(ebp+0x18) 1)
14628 }
14629 }
14630 $check-mu-call:check-outputs:
14631
14632 (lookup *(esi+0x14) *(esi+0x18))
14633 89/<- %ecx 0/r32/eax
14634
14635 (lookup *(edi+0x10) *(edi+0x14))
14636 89/<- %edx 0/r32/eax
14637 {
14638 $check-mu-call:check-for-outputs:
14639
14640 81 7/subop/compare %ecx 0/imm32
14641 0f 84/jump-if-= break/disp32
14642
14643 81 7/subop/compare %edx 0/imm32
14644 0f 84/jump-if-= break/disp32
14645 $check-mu-call:check-output-type:
14646
14647 (lookup *ecx *(ecx+4))
14648
14649 (lookup *(eax+8) *(eax+0xc))
14650 89/<- %ebx 0/r32/eax
14651
14652 81 7/subop/compare *(ecx+0x10) 0/imm32/false
14653 {
14654 74/jump-if-= break/disp8
14655 (lookup *(ebx+0xc) *(ebx+0x10))
14656 89/<- %ebx 0/r32/eax
14657 }
14658
14659 (lookup *edx *(edx+4))
14660
14661 (lookup *(eax+8) *(eax+0xc))
14662
14663 (type-match? %eax %ebx *(ebp-4))
14664 3d/compare-eax-and 0/imm32/false
14665 {
14666 0f 85/jump-if-!= break/disp32
14667 (write-buffered *(ebp+0x14) "fn ")
14668 8b/-> *(ebp+0x10) 0/r32/eax
14669 (lookup *eax *(eax+4))
14670 (write-buffered *(ebp+0x14) %eax)
14671 (write-buffered *(ebp+0x14) ": call ")
14672 (lookup *edi *(edi+4))
14673 (write-buffered *(ebp+0x14) %eax)
14674 (write-buffered *(ebp+0x14) ": type for output '")
14675 (lookup *ecx *(ecx+4))
14676 (lookup *eax *(eax+4))
14677 (write-buffered *(ebp+0x14) %eax)
14678 (write-buffered *(ebp+0x14) "' is not right\n")
14679 (flush *(ebp+0x14))
14680 (stop *(ebp+0x18) 1)
14681 }
14682 $check-mu-call:check-output-register:
14683
14684 (lookup *ecx *(ecx+4))
14685
14686 (lookup *(eax+18) *(eax+0x1c))
14687 89/<- %ebx 0/r32/eax
14688
14689 3d/compare-eax-and 0/imm32
14690 {
14691 0f 85/jump-if-!= break/disp32
14692 (write-buffered *(ebp+0x14) "fn ")
14693 8b/-> *(ebp+0x10) 0/r32/eax
14694 (lookup *eax *(eax+4))
14695 (write-buffered *(ebp+0x14) %eax)
14696 (write-buffered *(ebp+0x14) ": call ")
14697 (lookup *edi *(edi+4))
14698 (write-buffered *(ebp+0x14) %eax)
14699 (write-buffered *(ebp+0x14) ": output '")
14700 (lookup *ecx *(ecx+4))
14701 (lookup *eax *(eax+4))
14702 (write-buffered *(ebp+0x14) %eax)
14703 (write-buffered *(ebp+0x14) "' is not in a register\n")
14704 (flush *(ebp+0x14))
14705 (stop *(ebp+0x18) 1)
14706 }
14707
14708 (lookup *edx *(edx+4))
14709
14710 (lookup *(eax+18) *(eax+0x1c))
14711
14712 (string-equal? %eax %ebx)
14713 3d/compare-eax-and 0/imm32/false
14714 {
14715 0f 85/jump-if-!= break/disp32
14716 (write-buffered *(ebp+0x14) "fn ")
14717 8b/-> *(ebp+0x10) 0/r32/eax
14718 (lookup *eax *(eax+4))
14719 (write-buffered *(ebp+0x14) %eax)
14720 (write-buffered *(ebp+0x14) ": call ")
14721 (lookup *edi *(edi+4))
14722 (write-buffered *(ebp+0x14) %eax)
14723 (write-buffered *(ebp+0x14) ": register for output '")
14724 (lookup *ecx *(ecx+4))
14725 (lookup *eax *(eax+4))
14726 (write-buffered *(ebp+0x14) %eax)
14727 (write-buffered *(ebp+0x14) "' is not right\n")
14728 (flush *(ebp+0x14))
14729 (stop *(ebp+0x18) 1)
14730 }
14731 $check-mu-call:continue-to-next-output:
14732
14733 (lookup *(ecx+8) *(ecx+0xc))
14734 89/<- %ecx 0/r32/eax
14735
14736 (lookup *(edx+8) *(edx+0xc))
14737 89/<- %edx 0/r32/eax
14738
14739 e9/jump loop/disp32
14740 }
14741 $check-mu-call:check-output-count:
14742
14743 39/compare %ecx 2/r32/edx
14744 {
14745 0f 84/jump-if-= break/disp32
14746
14747
14748 {
14749 81 7/subop/compare %ecx 0/imm32
14750 0f 84/jump-if-= break/disp32
14751 (write-buffered *(ebp+0x14) "fn ")
14752 8b/-> *(ebp+0x10) 0/r32/eax
14753 (lookup *eax *(eax+4))
14754 (write-buffered *(ebp+0x14) %eax)
14755 (write-buffered *(ebp+0x14) ": call ")
14756 (lookup *edi *(edi+4))
14757 (write-buffered *(ebp+0x14) %eax)
14758 (write-buffered *(ebp+0x14) ": too many outputs\n")
14759 (flush *(ebp+0x14))
14760 (stop *(ebp+0x18) 1)
14761 }
14762
14763 {
14764 81 7/subop/compare %edx 0/imm32
14765 0f 84/jump-if-= break/disp32
14766 (write-buffered *(ebp+0x14) "fn ")
14767 8b/-> *(ebp+0x10) 0/r32/eax
14768 (lookup *eax *(eax+4))
14769 (write-buffered *(ebp+0x14) %eax)
14770 (write-buffered *(ebp+0x14) ": call ")
14771 (lookup *edi *(edi+4))
14772 (write-buffered *(ebp+0x14) %eax)
14773 (write-buffered *(ebp+0x14) ": too few outputs\n")
14774 (flush *(ebp+0x14))
14775 (stop *(ebp+0x18) 1)
14776 }
14777 }
14778 $check-mu-call:end:
14779
14780 5f/pop-to-edi
14781 5e/pop-to-esi
14782 5b/pop-to-ebx
14783 5a/pop-to-edx
14784 59/pop-to-ecx
14785 58/pop-to-eax
14786
14787 81 0/subop/add %esp 0x70/imm32
14788
14789 89/<- %esp 5/r32/ebp
14790 5d/pop-to-ebp
14791 c3/return
14792
14793
14794 type-match?:
14795
14796 55/push-ebp
14797 89/<- %ebp 4/r32/esp
14798
14799 (is-simple-mu-type? *(ebp+0xc) 0)
14800 3d/compare-eax-and 0/imm32/false
14801 b8/copy-to-eax 1/imm32/true
14802 75/jump-if-!= $type-match?:end/disp8
14803 $type-match?:baseline:
14804
14805 (type-component-match? *(ebp+8) *(ebp+0xc) *(ebp+0x10))
14806 $type-match?:end:
14807
14808 89/<- %esp 5/r32/ebp
14809 5d/pop-to-ebp
14810 c3/return
14811
14812 type-component-match?:
14813
14814 55/push-ebp
14815 89/<- %ebp 4/r32/esp
14816
14817 51/push-ecx
14818 52/push-edx
14819 53/push-ebx
14820
14821 8b/-> *(ebp+8) 1/r32/ecx
14822
14823 8b/-> *(ebp+0xc) 2/r32/edx
14824 $type-component-match?:compare-addr:
14825
14826 8b/-> %ecx 0/r32/eax
14827 39/compare %edx 0/r32/eax
14828 b8/copy-to-eax 1/imm32/true
14829 0f 84/jump-if-= $type-component-match?:end/disp32
14830
14831 b8/copy-to-eax 0/imm32/false
14832 81 7/subop/compare %ecx 0/imm32
14833 0f 84/jump-if-= $type-component-match?:end/disp32
14834
14835 81 7/subop/compare %edx 0/imm32
14836 0f 84/jump-if-= $type-component-match?:end/disp32
14837
14838 {
14839 $type-component-match?:check-type-parameter:
14840 81 7/subop/compare *ecx 0/imm32/false
14841 74/jump-if-= break/disp8
14842 81 7/subop/compare *(ecx+4) 0xa/imm32/type-parameter
14843 75/jump-if-!= break/disp8
14844 $type-component-match?:type-parameter:
14845 (type-parameter-match? *(ecx+8) *(ecx+0xc) %edx *(ebp+0x10))
14846 e9/jump $type-component-match?:end/disp32
14847 }
14848
14849 {
14850 $type-component-match?:check-list-type-parameter:
14851
14852 81 7/subop/compare *ecx 0/imm32/false
14853 75/jump-if-!= break/disp8
14854
14855 81 7/subop/compare *(ecx+0xc) 0/imm32
14856 75/jump-if-!= break/disp8
14857
14858 (lookup *(ecx+4) *(ecx+8))
14859 81 7/subop/compare *eax 0/imm32/false
14860 74/jump-if-= break/disp8
14861 81 7/subop/compare *(eax+4) 0xa/imm32/type-parameter
14862 75/jump-if-!= break/disp8
14863 $type-component-match?:list-type-parameter:
14864 (type-parameter-match? *(eax+8) *(eax+0xc) %edx *(ebp+0x10))
14865 e9/jump $type-component-match?:end/disp32
14866 }
14867 $type-component-match?:compare-atom-state:
14868
14869 8b/-> *ecx 3/r32/ebx
14870 39/compare *edx 3/r32/ebx
14871 b8/copy-to-eax 0/imm32/false
14872 0f 85/jump-if-!= $type-component-match?:end/disp32
14873
14874 {
14875 $type-component-match?:check-atom:
14876 81 7/subop/compare %ebx 0/imm32/false
14877 74/jump-if-= break/disp8
14878 $type-component-match?:is-atom:
14879 8b/-> *(ecx+4) 0/r32/eax
14880 39/compare *(edx+4) 0/r32/eax
14881 0f 94/set-if-= %al
14882 81 4/subop/and %eax 0xff/imm32
14883 e9/jump $type-component-match?:end/disp32
14884 }
14885 $type-component-match?:check-left:
14886
14887 (lookup *(ecx+4) *(ecx+8))
14888 89/<- %ebx 0/r32/eax
14889 (lookup *(edx+4) *(edx+8))
14890 (type-component-match? %ebx %eax *(ebp+0x10))
14891 3d/compare-eax-and 0/imm32/false
14892 74/jump-if-= $type-component-match?:end/disp8
14893 $type-component-match?:check-right:
14894
14895 (lookup *(ecx+0xc) *(ecx+0x10))
14896 89/<- %ebx 0/r32/eax
14897 (lookup *(edx+0xc) *(edx+0x10))
14898 (type-component-match? %ebx %eax *(ebp+0x10))
14899 $type-component-match?:end:
14900
14901 5b/pop-to-ebx
14902 5a/pop-to-edx
14903 59/pop-to-ecx
14904
14905 89/<- %esp 5/r32/ebp
14906 5d/pop-to-ebp
14907 c3/return
14908
14909 type-parameter-match?:
14910
14911 55/push-ebp
14912 89/<- %ebp 4/r32/esp
14913
14914 51/push-ecx
14915
14916 (get-or-insert-handle *(ebp+0x14) *(ebp+8) *(ebp+0xc) 0xc)
14917
14918 {
14919 81 7/subop/compare *eax 0/imm32
14920 75/jump-if-!= break/disp8
14921 8b/-> *(ebp+0x10) 1/r32/ecx
14922 89/<- *eax 1/r32/ecx
14923 }
14924
14925 (type-equal? *(ebp+0x10) *eax)
14926 $type-parameter-match?:end:
14927
14928 59/pop-to-ecx
14929
14930 89/<- %esp 5/r32/ebp
14931 5d/pop-to-ebp
14932 c3/return
14933
14934 size-of:
14935
14936 55/push-ebp
14937 89/<- %ebp 4/r32/esp
14938
14939 51/push-ecx
14940
14941 8b/-> *(ebp+8) 1/r32/ecx
14942
14943
14944
14945
14946
14947
14948
14949 (lookup *(ecx+8) *(ecx+0xc))
14950 89/<- %ecx 0/r32/eax
14951
14952 {
14953 (is-mu-array? %ecx)
14954 3d/compare-eax-and 0/imm32/false
14955 74/jump-if-= break/disp8
14956 (size-of-array %ecx)
14957 eb/jump $size-of:end/disp8
14958 }
14959
14960 {
14961 (is-mu-stream? %ecx)
14962 3d/compare-eax-and 0/imm32/false
14963 74/jump-if-= break/disp8
14964 (size-of-stream %ecx)
14965 eb/jump $size-of:end/disp8
14966 }
14967
14968 {
14969 81 7/subop/compare *ecx 0/imm32/false
14970 75/jump-if-!= break/disp8
14971 (lookup *(ecx+4) *(ecx+8))
14972 89/<- %ecx 0/r32/eax
14973 }
14974
14975 (size-of-type-id *(ecx+4))
14976 $size-of:end:
14977
14978 59/pop-to-ecx
14979
14980 89/<- %esp 5/r32/ebp
14981 5d/pop-to-ebp
14982 c3/return
14983
14984 size-of-deref:
14985
14986 55/push-ebp
14987 89/<- %ebp 4/r32/esp
14988
14989 51/push-ecx
14990
14991 8b/-> *(ebp+8) 1/r32/ecx
14992 (lookup *(ecx+8) *(ecx+0xc))
14993 89/<- %ecx 0/r32/eax
14994
14995
14996 (lookup *(ecx+0xc) *(ecx+0x10))
14997 89/<- %ecx 0/r32/eax
14998
14999 {
15000 (is-mu-array? %ecx)
15001 3d/compare-eax-and 0/imm32/false
15002 74/jump-if-= break/disp8
15003 (size-of-array %ecx)
15004 eb/jump $size-of-deref:end/disp8
15005 }
15006
15007 {
15008 (is-mu-stream? %ecx)
15009 3d/compare-eax-and 0/imm32/false
15010 74/jump-if-= break/disp8
15011 (size-of-stream %ecx)
15012 eb/jump $size-of-deref:end/disp8
15013 }
15014
15015 {
15016 81 7/subop/compare *ecx 0/imm32/false
15017 75/jump-if-!= break/disp8
15018 (lookup *(ecx+4) *(ecx+8))
15019 89/<- %ecx 0/r32/eax
15020 }
15021
15022 (size-of-type-id *(ecx+4))
15023 $size-of-deref:end:
15024
15025 59/pop-to-ecx
15026
15027 89/<- %esp 5/r32/ebp
15028 5d/pop-to-ebp
15029 c3/return
15030
15031 is-mu-array?:
15032
15033 55/push-ebp
15034 89/<- %ebp 4/r32/esp
15035
15036 51/push-ecx
15037
15038 8b/-> *(ebp+8) 1/r32/ecx
15039
15040 81 7/subop/compare *ecx 0/imm32/false
15041 75/jump-if-!= $is-mu-array?:return-false/disp8
15042
15043 (lookup *(ecx+4) *(ecx+8))
15044 81 7/subop/compare *eax 0/imm32/false
15045 74/jump-if-= $is-mu-array?:return-false/disp8
15046
15047 81 7/subop/compare *(eax+4) 3/imm32/array-type-id
15048 0f 94/set-if-= %al
15049 81 4/subop/and %eax 0xff/imm32
15050 eb/jump $is-mu-array?:end/disp8
15051 $is-mu-array?:return-false:
15052 b8/copy-to-eax 0/imm32/false
15053 $is-mu-array?:end:
15054
15055 59/pop-to-ecx
15056
15057 89/<- %esp 5/r32/ebp
15058 5d/pop-to-ebp
15059 c3/return
15060
15061
15062 size-of-array:
15063
15064 55/push-ebp
15065 89/<- %ebp 4/r32/esp
15066
15067 51/push-ecx
15068 52/push-edx
15069
15070 8b/-> *(ebp+8) 1/r32/ecx
15071
15072 (lookup *(ecx+0xc) *(ecx+0x10))
15073 89/<- %ecx 0/r32/eax
15074
15075 (lookup *(ecx+4) *(ecx+8))
15076 8b/-> *(eax+4) 2/r32/edx
15077
15078
15079 (lookup *(ecx+0xc) *(ecx+0x10))
15080 (lookup *(eax+4) *(eax+8))
15081 8b/-> *(eax+8) 1/r32/ecx
15082
15083 (size-of-type-id-as-array-element %edx)
15084 f7 4/subop/multiply-into-edx-eax %ecx
15085 05/add-to-eax 4/imm32
15086
15087 $size-of-array:end:
15088
15089 5a/pop-to-edx
15090 59/pop-to-ecx
15091
15092 89/<- %esp 5/r32/ebp
15093 5d/pop-to-ebp
15094 c3/return
15095
15096 is-mu-stream?:
15097
15098 55/push-ebp
15099 89/<- %ebp 4/r32/esp
15100
15101 51/push-ecx
15102
15103 8b/-> *(ebp+8) 1/r32/ecx
15104
15105 81 7/subop/compare *ecx 0/imm32/false
15106 75/jump-if-!= $is-mu-stream?:return-false/disp8
15107
15108 (lookup *(ecx+4) *(ecx+8))
15109 81 7/subop/compare *eax 0/imm32/false
15110 74/jump-if-= $is-mu-stream?:return-false/disp8
15111
15112 81 7/subop/compare *(eax+4) 0xb/imm32/stream-type-id
15113 0f 94/set-if-= %al
15114 81 4/subop/and %eax 0xff/imm32
15115 eb/jump $is-mu-stream?:end/disp8
15116 $is-mu-stream?:return-false:
15117 b8/copy-to-eax 0/imm32/false
15118 $is-mu-stream?:end:
15119
15120 59/pop-to-ecx
15121
15122 89/<- %esp 5/r32/ebp
15123 5d/pop-to-ebp
15124 c3/return
15125
15126
15127 size-of-stream:
15128
15129 55/push-ebp
15130 89/<- %ebp 4/r32/esp
15131
15132 (size-of-array *(ebp+8))
15133 05/add-to-eax 8/imm32
15134 $size-of-stream:end:
15135
15136 89/<- %esp 5/r32/ebp
15137 5d/pop-to-ebp
15138 c3/return
15139
15140 size-of-type-id:
15141
15142 55/push-ebp
15143 89/<- %ebp 4/r32/esp
15144
15145 51/push-ecx
15146
15147 68/push 0/imm32
15148 68/push 0/imm32
15149 89/<- %ecx 4/r32/esp
15150
15151 8b/-> *(ebp+8) 0/r32/eax
15152
15153 3d/compare-eax-and 0/imm32
15154 0f 84/jump-if-= $size-of-type-id:end/disp32
15155
15156 3d/compare-eax-and 8/imm32/byte
15157 {
15158 75/jump-if-!= break/disp8
15159 b8/copy-to-eax 4/imm32
15160 eb/jump $size-of-type-id:end/disp8
15161 }
15162
15163 3d/compare-eax-and 4/imm32/handle
15164 {
15165 75/jump-if-!= break/disp8
15166 b8/copy-to-eax 8/imm32
15167 eb/jump $size-of-type-id:end/disp8
15168 }
15169
15170 3d/compare-eax-and 0xc/imm32/slice
15171 {
15172 75/jump-if-!= break/disp8
15173 b8/copy-to-eax 8/imm32
15174 eb/jump $size-of-type-id:end/disp8
15175 }
15176
15177
15178 (find-typeinfo %eax %ecx)
15179 {
15180 81 7/subop/compare *ecx 0/imm32
15181 74/jump-if-= break/disp8
15182 $size-of-type-id:user-defined:
15183 (lookup *ecx *(ecx+4))
15184 8b/-> *(eax+0xc) 0/r32/eax
15185 eb/jump $size-of-type-id:end/disp8
15186 }
15187
15188 b8/copy-to-eax 4/imm32
15189 $size-of-type-id:end:
15190
15191 81 0/subop/add %esp 8/imm32
15192
15193 59/pop-to-ecx
15194
15195 89/<- %esp 5/r32/ebp
15196 5d/pop-to-ebp
15197 c3/return
15198
15199
15200
15201
15202 type-tail:
15203
15204 55/push-ebp
15205 89/<- %ebp 4/r32/esp
15206
15207 51/push-ecx
15208
15209 b8/copy-to-eax 0/imm32
15210
15211 8b/-> *(ebp+8) 1/r32/ecx
15212 $type-tail:check-atom:
15213
15214 81 7/subop/compare *ecx 0/imm32/false
15215 0f 85/jump-if-!= $type-tail:end/disp32
15216
15217 (lookup *(ecx+0xc) *(ecx+0x10))
15218 89/<- %ecx 0/r32/eax
15219 $type-tail:check-singleton:
15220
15221 {
15222 81 7/subop/compare *(ecx+0xc) 0/imm32
15223 75/jump-if-!= break/disp8
15224 (lookup *(ecx+4) *(ecx+8))
15225 e9/jump $type-tail:end/disp32
15226 }
15227
15228 {
15229 $type-tail:check-array-capacity:
15230 (lookup *(ecx+0xc) *(ecx+0x10))
15231 81 7/subop/compare *eax 0/imm32/false
15232 75/jump-if-!= break/disp8
15233 $type-tail:check-array-capacity-1:
15234 (lookup *(eax+4) *(eax+8))
15235 3d/compare-eax-and 0/imm32
15236 74/jump-if-= break/disp8
15237 $type-tail:check-array-capacity-2:
15238 (is-simple-mu-type? %eax 9)
15239 3d/compare-eax-and 0/imm32/false
15240 74/jump-if-= break/disp8
15241 $type-tail:array-capacity:
15242 (lookup *(ecx+4) *(ecx+8))
15243 eb/jump $type-tail:end/disp8
15244 }
15245 $type-tail:check-compound-left:
15246
15247 (lookup *(ecx+4) *(ecx+8))
15248 81 7/subop/compare *eax 0/imm32/false
15249 74/jump-if-= $type-tail:end/disp8
15250 $type-tail:return-tail:
15251
15252 89/<- %eax 1/r32/ecx
15253 $type-tail:end:
15254
15255 59/pop-to-ecx
15256
15257 89/<- %esp 5/r32/ebp
15258 5d/pop-to-ebp
15259 c3/return
15260
15261 type-equal?:
15262
15263 55/push-ebp
15264 89/<- %ebp 4/r32/esp
15265
15266 51/push-ecx
15267 52/push-edx
15268 53/push-ebx
15269
15270 8b/-> *(ebp+8) 1/r32/ecx
15271
15272 8b/-> *(ebp+0xc) 2/r32/edx
15273 $type-equal?:compare-addr:
15274
15275 8b/-> %ecx 0/r32/eax
15276 39/compare %edx 0/r32/eax
15277 b8/copy-to-eax 1/imm32/true
15278 0f 84/jump-if-= $type-equal?:end/disp32
15279 $type-equal?:compare-null-a:
15280
15281 b8/copy-to-eax 0/imm32/false
15282 81 7/subop/compare %ecx 0/imm32
15283 0f 84/jump-if-= $type-equal?:end/disp32
15284 $type-equal?:compare-null-b:
15285
15286 81 7/subop/compare %edx 0/imm32
15287 0f 84/jump-if-= $type-equal?:end/disp32
15288 $type-equal?:compare-atom-state:
15289
15290 8b/-> *ecx 3/r32/ebx
15291 39/compare *edx 3/r32/ebx
15292 b8/copy-to-eax 0/imm32/false
15293 0f 85/jump-if-!= $type-equal?:end/disp32
15294
15295 {
15296 $type-equal?:check-atom:
15297 81 7/subop/compare %ebx 0/imm32/false
15298 74/jump-if-= break/disp8
15299 $type-equal?:is-atom:
15300 8b/-> *(ecx+4) 0/r32/eax
15301 39/compare *(edx+4) 0/r32/eax
15302 0f 94/set-if-= %al
15303 81 4/subop/and %eax 0xff/imm32
15304 e9/jump $type-equal?:end/disp32
15305 }
15306 $type-equal?:check-left:
15307
15308 (lookup *(ecx+4) *(ecx+8))
15309 89/<- %ebx 0/r32/eax
15310 (lookup *(edx+4) *(edx+8))
15311 (type-equal? %eax %ebx)
15312 3d/compare-eax-and 0/imm32/false
15313 74/jump-if-= $type-equal?:end/disp8
15314 $type-equal?:check-right:
15315
15316 (lookup *(ecx+0xc) *(ecx+0x10))
15317 89/<- %ebx 0/r32/eax
15318 (lookup *(edx+0xc) *(edx+0x10))
15319 (type-equal? %eax %ebx)
15320 $type-equal?:end:
15321
15322 5b/pop-to-ebx
15323 5a/pop-to-edx
15324 59/pop-to-ecx
15325
15326 89/<- %esp 5/r32/ebp
15327 5d/pop-to-ebp
15328 c3/return
15329
15330
15331
15332
15333
15334 == data
15335
15336
15337 Curr-local-stack-offset:
15338 0/imm32
15339
15340 == code
15341
15342 emit-subx:
15343
15344 55/push-ebp
15345 89/<- %ebp 4/r32/esp
15346
15347 50/push-eax
15348
15349 (lookup *_Program-functions *_Program-functions->payload)
15350 {
15351
15352 3d/compare-eax-and 0/imm32
15353 0f 84/jump-if-= break/disp32
15354 (emit-subx-function *(ebp+8) %eax *(ebp+0xc) *(ebp+0x10))
15355
15356 (lookup *(eax+0x20) *(eax+0x24))
15357 e9/jump loop/disp32
15358 }
15359 $emit-subx:end:
15360
15361 58/pop-to-eax
15362
15363 89/<- %esp 5/r32/ebp
15364 5d/pop-to-ebp
15365 c3/return
15366
15367 emit-subx-function:
15368
15369 55/push-ebp
15370 89/<- %ebp 4/r32/esp
15371
15372 (populate-mu-type-offsets-in-inouts *(ebp+0xc))
15373
15374 50/push-eax
15375 51/push-ecx
15376 52/push-edx
15377
15378 c7 0/subop/copy *Curr-block-depth 1/imm32
15379 c7 0/subop/copy *Curr-local-stack-offset 0/imm32
15380
15381 8b/-> *(ebp+0xc) 1/r32/ecx
15382
15383 81 5/subop/subtract %esp 0xc00/imm32
15384 68/push 0xc00/imm32/size
15385 68/push 0/imm32/top
15386 89/<- %edx 4/r32/esp
15387
15388 (lookup *ecx *(ecx+4))
15389
15390 (write-buffered *(ebp+8) %eax)
15391 (write-buffered *(ebp+8) ":\n")
15392 (emit-subx-prologue *(ebp+8))
15393
15394 (lookup *(ecx+0x18) *(ecx+0x1c))
15395
15396 (emit-subx-block *(ebp+8) %eax %edx *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
15397 (emit-subx-epilogue *(ebp+8))
15398
15399
15400 $emit-subx-function:end:
15401
15402 81 0/subop/add %esp 0xc08/imm32
15403
15404 5a/pop-to-edx
15405 59/pop-to-ecx
15406 58/pop-to-eax
15407
15408 89/<- %esp 5/r32/ebp
15409 5d/pop-to-ebp
15410 c3/return
15411
15412 populate-mu-type-offsets-in-inouts:
15413
15414 55/push-ebp
15415 89/<- %ebp 4/r32/esp
15416
15417 50/push-eax
15418 51/push-ecx
15419 52/push-edx
15420 53/push-ebx
15421 57/push-edi
15422
15423 ba/copy-to-edx 8/imm32
15424
15425 8b/-> *(ebp+8) 1/r32/ecx
15426 (lookup *(ecx+8) *(ecx+0xc))
15427 89/<- %ecx 0/r32/eax
15428 {
15429 $populate-mu-type-offsets-in-inouts:loop:
15430 81 7/subop/compare %ecx 0/imm32
15431 74/jump-if-= break/disp8
15432
15433 (lookup *ecx *(ecx+4))
15434 89/<- %ebx 0/r32/eax
15435
15436
15437
15438
15439
15440
15441
15442
15443
15444
15445 89/<- *(ebx+0x14) 2/r32/edx
15446
15447 (size-of %ebx)
15448 01/add-to %edx 0/r32/eax
15449
15450 (lookup *(ecx+8) *(ecx+0xc))
15451 89/<- %ecx 0/r32/eax
15452
15453 eb/jump loop/disp8
15454 }
15455 $populate-mu-type-offsets-in-inouts:end:
15456
15457 5f/pop-to-edi
15458 5b/pop-to-ebx
15459 5a/pop-to-edx
15460 59/pop-to-ecx
15461 58/pop-to-eax
15462
15463 89/<- %esp 5/r32/ebp
15464 5d/pop-to-ebp
15465 c3/return
15466
15467 emit-subx-stmt-list:
15468
15469 55/push-ebp
15470 89/<- %ebp 4/r32/esp
15471
15472 50/push-eax
15473 51/push-ecx
15474 53/push-ebx
15475 56/push-esi
15476
15477 8b/-> *(ebp+0xc) 6/r32/esi
15478
15479 {
15480 $emit-subx-stmt-list:loop:
15481 81 7/subop/compare %esi 0/imm32
15482 0f 84/jump-if-= break/disp32
15483
15484 (lookup *esi *(esi+4))
15485 89/<- %ecx 0/r32/eax
15486 {
15487 $emit-subx-stmt-list:check-for-block:
15488 81 7/subop/compare *ecx 0/imm32/block
15489 75/jump-if-!= break/disp8
15490 $emit-subx-stmt-list:block:
15491 (emit-subx-block *(ebp+8) %ecx *(ebp+0x10) *(ebp+0x14) *(ebp+0x18) *(ebp+0x1c))
15492 }
15493 {
15494 $emit-subx-stmt-list:check-for-stmt:
15495 81 7/subop/compare *ecx 1/imm32/stmt1
15496 0f 85/jump-if-!= break/disp32
15497 $emit-subx-stmt-list:stmt1:
15498 {
15499 (is-mu-branch? %ecx)
15500 3d/compare-eax-and 0/imm32/false
15501 0f 84/jump-if-= break/disp32
15502 $emit-subx-stmt-list:branch-stmt:
15503 +-- 27 lines: # unconditional loops -----------------------------------------------------------------------------------------------------------------------------------------------------
15530 +-- 16 lines: # unconditional breaks ----------------------------------------------------------------------------------------------------------------------------------------------------
15546 +-- 38 lines: # simple conditional branches without a target ----------------------------------------------------------------------------------------------------------------------------
15584 +-- 19 lines: # conditional branches with an explicit target ----------------------------------------------------------------------------------------------------------------------------
15603 }
15604 $emit-subx-stmt-list:1-to-1:
15605 (emit-subx-stmt *(ebp+8) %ecx Primitives *(ebp+0x18) *(ebp+0x1c))
15606 e9/jump $emit-subx-stmt-list:continue/disp32
15607 }
15608 {
15609 $emit-subx-stmt-list:check-for-var-def:
15610 81 7/subop/compare *ecx 2/imm32/var-def
15611 75/jump-if-!= break/disp8
15612 $emit-subx-stmt-list:var-def:
15613 (emit-subx-var-def *(ebp+8) %ecx)
15614 (push *(ebp+0x10) *(ecx+4))
15615 (push *(ebp+0x10) *(ecx+8))
15616 (push *(ebp+0x10) 0)
15617
15618 eb/jump $emit-subx-stmt-list:continue/disp8
15619 }
15620 {
15621 $emit-subx-stmt-list:check-for-reg-var-def:
15622 81 7/subop/compare *ecx 3/imm32/reg-var-def
15623 0f 85/jump-if-!= break/disp32
15624 $emit-subx-stmt-list:reg-var-def:
15625
15626 (push-output-and-maybe-emit-spill *(ebp+8) %ecx *(ebp+0x10) %esi *(ebp+0x14) *(ebp+0x18) *(ebp+0x1c))
15627
15628 (emit-subx-stmt *(ebp+8) %ecx Primitives *(ebp+0x18) *(ebp+0x1c))
15629
15630 eb/jump $emit-subx-stmt-list:continue/disp8
15631 }
15632 $emit-subx-stmt-list:continue:
15633
15634 (lookup *(esi+8) *(esi+0xc))
15635 89/<- %esi 0/r32/eax
15636 e9/jump loop/disp32
15637 }
15638 $emit-subx-stmt-list:emit-cleanup:
15639 (emit-cleanup-code-until-depth *(ebp+8) *(ebp+0x10) *Curr-block-depth)
15640 $emit-subx-stmt-list:clean-up:
15641 (clean-up-stack-offset-state *(ebp+0x10) *Curr-block-depth)
15642 (clean-up-blocks *(ebp+0x10) *Curr-block-depth *(ebp+0x14))
15643 $emit-subx-stmt-list:end:
15644
15645 5e/pop-to-esi
15646 5b/pop-to-ebx
15647 59/pop-to-ecx
15648 58/pop-to-eax
15649
15650 89/<- %esp 5/r32/ebp
15651 5d/pop-to-ebp
15652 c3/return
15653
15654
15655 push-output-and-maybe-emit-spill:
15656
15657 55/push-ebp
15658 89/<- %ebp 4/r32/esp
15659
15660 50/push-eax
15661 51/push-ecx
15662 52/push-edx
15663
15664 8b/-> *(ebp+0xc) 1/r32/ecx
15665
15666 (lookup *(ecx+0x14) *(ecx+0x18))
15667
15668
15669 (lookup *eax *(eax+4))
15670 89/<- %ecx 0/r32/eax
15671
15672 8b/-> *Curr-block-depth 0/r32/eax
15673 89/<- *(ecx+0x10) 0/r32/eax
15674
15675
15676
15677
15678
15679
15680
15681
15682 81 7/subop/compare *(ecx+0x18) 0/imm32
15683 0f 84/jump-if-= $push-output-and-maybe-emit-spill:abort/disp32
15684
15685 (not-yet-spilled-this-block? %ecx *(ebp+0x10))
15686 89/<- %edx 0/r32/eax
15687 3d/compare-eax-and 0/imm32/false
15688 0f 84/jump-if-= $push-output-and-maybe-emit-spill:push/disp32
15689 (will-not-write-some-register? %ecx *(ebp+0x14) *(ebp+0x18))
15690 89/<- %edx 0/r32/eax
15691
15692 3d/compare-eax-and 0/imm32/false
15693 0f 84/jump-if-= $push-output-and-maybe-emit-spill:push/disp32
15694
15695
15696 81 5/subop/subtract *Curr-local-stack-offset 4/imm32
15697
15698 (lookup *(ecx+0x18) *(ecx+0x1c))
15699 (emit-push-register *(ebp+8) %eax)
15700 $push-output-and-maybe-emit-spill:push:
15701 8b/-> *(ebp+0xc) 1/r32/ecx
15702 (lookup *(ecx+0x14) *(ecx+0x18))
15703
15704 (push *(ebp+0x10) *eax)
15705 (push *(ebp+0x10) *(eax+4))
15706 (push *(ebp+0x10) %edx)
15707 $push-output-and-maybe-emit-spill:end:
15708
15709 5a/pop-to-edx
15710 59/pop-to-ecx
15711 58/pop-to-eax
15712
15713 89/<- %esp 5/r32/ebp
15714 5d/pop-to-ebp
15715 c3/return
15716
15717 $push-output-and-maybe-emit-spill:abort:
15718
15719 (write-buffered *(ebp+0x1c) "var '")
15720 (write-buffered *(ebp+0x1c) *eax)
15721 (write-buffered *(ebp+0x1c) "' initialized from an instruction must live in a register\n")
15722 (flush *(ebp+0x1c))
15723 (stop *(ebp+0x20) 1)
15724
15725
15726 emit-subx-cleanup-and-unconditional-nonlocal-branch:
15727
15728 55/push-ebp
15729 89/<- %ebp 4/r32/esp
15730
15731 50/push-eax
15732 51/push-ecx
15733
15734 8b/-> *(ebp+0xc) 1/r32/ecx
15735
15736 (lookup *(ecx+0xc) *(ecx+0x10))
15737 (lookup *eax *(eax+4))
15738 (lookup *eax *(eax+4))
15739
15740 (emit-cleanup-code-until-target *(ebp+8) *(ebp+0x10) %eax)
15741
15742 (emit-indent *(ebp+8) *Curr-block-depth)
15743 (write-buffered *(ebp+8) "e9/jump ")
15744 (write-buffered *(ebp+8) %eax)
15745 (lookup *(ecx+4) *(ecx+8))
15746 (string-starts-with? %eax "break")
15747 3d/compare-eax-and 0/imm32/false
15748 {
15749 74/jump-if-= break/disp8
15750 (write-buffered *(ebp+8) ":break/disp32\n")
15751 }
15752 3d/compare-eax-and 0/imm32/false
15753 {
15754 75/jump-if-!= break/disp8
15755 (write-buffered *(ebp+8) ":loop/disp32\n")
15756 }
15757 $emit-subx-cleanup-and-unconditional-nonlocal-branch:end:
15758
15759 59/pop-to-ecx
15760 58/pop-to-eax
15761
15762 89/<- %esp 5/r32/ebp
15763 5d/pop-to-ebp
15764 c3/return
15765
15766 is-mu-branch?:
15767
15768 55/push-ebp
15769 89/<- %ebp 4/r32/esp
15770
15771 51/push-ecx
15772
15773 8b/-> *(ebp+8) 1/r32/ecx
15774 (lookup *(ecx+4) *(ecx+8))
15775 89/<- %ecx 0/r32/eax
15776
15777 (string-starts-with? %ecx "loop")
15778 3d/compare-eax-and 0/imm32/false
15779 75/jump-if-not-equal $is-mu-branch?:end/disp8
15780
15781 (string-starts-with? %ecx "break")
15782 $is-mu-branch?:end:
15783
15784 59/pop-to-ecx
15785
15786 89/<- %esp 5/r32/ebp
15787 5d/pop-to-ebp
15788 c3/return
15789
15790 emit-reverse-break:
15791
15792 55/push-ebp
15793 89/<- %ebp 4/r32/esp
15794
15795 50/push-eax
15796
15797 8b/-> *(ebp+0xc) 0/r32/eax
15798
15799 (lookup *(eax+4) *(eax+8))
15800 (get Reverse-branch %eax 0x10 "reverse-branch: ")
15801 (emit-indent *(ebp+8) *Curr-block-depth)
15802 (lookup *eax *(eax+4))
15803 (write-buffered *(ebp+8) %eax)
15804 (write-buffered *(ebp+8) " break/disp32\n")
15805 $emit-reverse-break:end:
15806
15807 58/pop-to-eax
15808
15809 89/<- %esp 5/r32/ebp
15810 5d/pop-to-ebp
15811 c3/return
15812
15813 == data
15814
15815
15816 Reverse-branch:
15817
15818 0x1c0/imm32/write
15819 0/imm32/read
15820 0x1c0/imm32/size
15821
15822 0x11/imm32/alloc-id _string-break-if-=/imm32 0x11/imm32/alloc-id _string_0f_85_jump_label/imm32
15823 0x11/imm32/alloc-id _string-loop-if-=/imm32 0x11/imm32/alloc-id _string_0f_85_jump_label/imm32
15824 0x11/imm32/alloc-id _string-break-if-!=/imm32 0x11/imm32/alloc-id _string_0f_84_jump_label/imm32
15825 0x11/imm32/alloc-id _string-loop-if-!=/imm32 0x11/imm32/alloc-id _string_0f_84_jump_label/imm32
15826 0x11/imm32/alloc-id _string-break-if-</imm32 0x11/imm32/alloc-id _string_0f_8d_jump_label/imm32
15827 0x11/imm32/alloc-id _string-loop-if-</imm32 0x11/imm32/alloc-id _string_0f_8d_jump_label/imm32
15828 0x11/imm32/alloc-id _string-break-if->/imm32 0x11/imm32/alloc-id _string_0f_8e_jump_label/imm32
15829 0x11/imm32/alloc-id _string-loop-if->/imm32 0x11/imm32/alloc-id _string_0f_8e_jump_label/imm32
15830 0x11/imm32/alloc-id _string-break-if-<=/imm32 0x11/imm32/alloc-id _string_0f_87_jump_label/imm32
15831 0x11/imm32/alloc-id _string-loop-if-<=/imm32 0x11/imm32/alloc-id _string_0f_87_jump_label/imm32
15832 0x11/imm32/alloc-id _string-break-if->=/imm32 0x11/imm32/alloc-id _string_0f_8c_jump_label/imm32
15833 0x11/imm32/alloc-id _string-loop-if->=/imm32 0x11/imm32/alloc-id _string_0f_8c_jump_label/imm32
15834 0x11/imm32/alloc-id _string-break-if-addr</imm32 0x11/imm32/alloc-id _string_0f_83_jump_label/imm32
15835 0x11/imm32/alloc-id _string-loop-if-addr</imm32 0x11/imm32/alloc-id _string_0f_83_jump_label/imm32
15836 0x11/imm32/alloc-id _string-break-if-addr>/imm32 0x11/imm32/alloc-id _string_0f_86_jump_label/imm32
15837 0x11/imm32/alloc-id _string-loop-if-addr>/imm32 0x11/imm32/alloc-id _string_0f_86_jump_label/imm32
15838 0x11/imm32/alloc-id _string-break-if-addr<=/imm32 0x11/imm32/alloc-id _string_0f_87_jump_label/imm32
15839 0x11/imm32/alloc-id _string-loop-if-addr<=/imm32 0x11/imm32/alloc-id _string_0f_87_jump_label/imm32
15840 0x11/imm32/alloc-id _string-break-if-addr>=/imm32 0x11/imm32/alloc-id _string_0f_82_jump_label/imm32
15841 0x11/imm32/alloc-id _string-loop-if-addr>=/imm32 0x11/imm32/alloc-id _string_0f_82_jump_label/imm32
15842 0x11/imm32/alloc-id _string-break-if-float</imm32 0x11/imm32/alloc-id _string_0f_83_jump_label/imm32
15843 0x11/imm32/alloc-id _string-loop-if-float</imm32 0x11/imm32/alloc-id _string_0f_83_jump_label/imm32
15844 0x11/imm32/alloc-id _string-break-if-float>/imm32 0x11/imm32/alloc-id _string_0f_86_jump_label/imm32
15845 0x11/imm32/alloc-id _string-loop-if-float>/imm32 0x11/imm32/alloc-id _string_0f_86_jump_label/imm32
15846 0x11/imm32/alloc-id _string-break-if-float<=/imm32 0x11/imm32/alloc-id _string_0f_87_jump_label/imm32
15847 0x11/imm32/alloc-id _string-loop-if-float<=/imm32 0x11/imm32/alloc-id _string_0f_87_jump_label/imm32
15848 0x11/imm32/alloc-id _string-break-if-float>=/imm32 0x11/imm32/alloc-id _string_0f_82_jump_label/imm32
15849 0x11/imm32/alloc-id _string-loop-if-float>=/imm32 0x11/imm32/alloc-id _string_0f_82_jump_label/imm32
15850
15851 == code
15852
15853 emit-unconditional-jump-to-depth:
15854
15855 55/push-ebp
15856 89/<- %ebp 4/r32/esp
15857
15858 50/push-eax
15859 51/push-ecx
15860 52/push-edx
15861 53/push-ebx
15862 56/push-esi
15863
15864 8b/-> *(ebp+0xc) 1/r32/ecx
15865
15866 8b/-> *ecx 0/r32/eax
15867
15868 8d/copy-address *(ecx+eax-4) 6/r32/esi
15869
15870 8d/copy-address *(ecx+8) 1/r32/ecx
15871
15872 8b/-> *(ebp+0x10) 2/r32/edx
15873 {
15874 $emit-unconditional-jump-to-depth:loop:
15875
15876 39/compare %esi 1/r32/ecx
15877 0f 82/jump-if-addr< break/disp32
15878
15879 (lookup *esi *(esi+4))
15880 89/<- %ebx 0/r32/eax
15881
15882 39/compare *(ebx+0x10) 2/r32/edx
15883 0f 8c/jump-if-< break/disp32
15884 {
15885 $emit-unconditional-jump-to-depth:check:
15886
15887 39/compare *(ebx+0x10) 2/r32/edx
15888 0f 85/jump-if-!= break/disp32
15889 $emit-unconditional-jump-to-depth:depth-found:
15890
15891 (size-of %ebx)
15892 3d/compare-eax-and 0/imm32
15893 0f 85/jump-if-!= break/disp32
15894 $emit-unconditional-jump-to-depth:label-found:
15895
15896 (emit-indent *(ebp+8) *Curr-block-depth)
15897 (write-buffered *(ebp+8) "e9/jump ")
15898 (lookup *ebx *(ebx+4))
15899 (write-buffered *(ebp+8) %eax)
15900 (write-buffered *(ebp+8) ":")
15901 (write-buffered *(ebp+8) *(ebp+0x14))
15902 (write-buffered *(ebp+8) "/disp32\n")
15903 eb/jump $emit-unconditional-jump-to-depth:end/disp8
15904 }
15905
15906 81 5/subop/subtract %esi 0xc/imm32
15907 e9/jump loop/disp32
15908 }
15909
15910 $emit-unconditional-jump-to-depth:end:
15911
15912 5e/pop-to-esi
15913 5b/pop-to-ebx
15914 5a/pop-to-edx
15915 59/pop-to-ecx
15916 58/pop-to-eax
15917
15918 89/<- %esp 5/r32/ebp
15919 5d/pop-to-ebp
15920 c3/return
15921
15922
15923
15924 emit-cleanup-code-until-depth:
15925
15926 55/push-ebp
15927 89/<- %ebp 4/r32/esp
15928
15929 50/push-eax
15930 51/push-ecx
15931 52/push-edx
15932 53/push-ebx
15933 56/push-esi
15934
15935
15936
15937 8b/-> *(ebp+0xc) 1/r32/ecx
15938
15939 8b/-> *ecx 6/r32/esi
15940
15941 8d/copy-address *(ecx+esi-4) 6/r32/esi
15942
15943 81 0/subop/add %ecx 8/imm32
15944
15945 8b/-> *(ebp+0x10) 2/r32/edx
15946 {
15947 $emit-cleanup-code-until-depth:loop:
15948
15949 39/compare %esi 1/r32/ecx
15950 0f 82/jump-if-addr< break/disp32
15951
15952 (lookup *esi *(esi+4))
15953 89/<- %ebx 0/r32/eax
15954
15955
15956
15957
15958
15959
15960 39/compare *(ebx+0x10) 2/r32/edx
15961 0f 8c/jump-if-< break/disp32
15962
15963 81 7/subop/compare *(ebx+0x18) 0/imm32
15964 {
15965 0f 84/jump-if-= break/disp32
15966 {
15967 $emit-cleanup-code-until-depth:check-for-previous-spill:
15968 8b/-> *(esi+8) 0/r32/eax
15969 3d/compare-eax-and 0/imm32/false
15970 74/jump-if-= break/disp8
15971 $emit-cleanup-code-until-depth:reclaim-var-in-register:
15972 (lookup *(ebx+0x18) *(ebx+0x1c))
15973 (emit-pop-register *(ebp+8) %eax)
15974 }
15975 eb/jump $emit-cleanup-code-until-depth:continue/disp8
15976 }
15977
15978 {
15979 75/jump-if-!= break/disp8
15980 $emit-cleanup-code-until-depth:var-on-stack:
15981 (size-of %ebx)
15982
15983 3d/compare-eax-and 0/imm32
15984 74/jump-if-= break/disp8
15985 $emit-cleanup-code-until-depth:reclaim-var-on-stack:
15986 (emit-indent *(ebp+8) *Curr-block-depth)
15987 (write-buffered *(ebp+8) "81 0/subop/add %esp ")
15988 (write-int32-hex-buffered *(ebp+8) %eax)
15989 (write-buffered *(ebp+8) "/imm32\n")
15990 }
15991 $emit-cleanup-code-until-depth:continue:
15992
15993 81 5/subop/subtract %esi 0xc/imm32
15994 e9/jump loop/disp32
15995 }
15996 $emit-cleanup-code-until-depth:end:
15997
15998 5e/pop-to-esi
15999 5b/pop-to-ebx
16000 5a/pop-to-edx
16001 59/pop-to-ecx
16002 58/pop-to-eax
16003
16004 89/<- %esp 5/r32/ebp
16005 5d/pop-to-ebp
16006 c3/return
16007
16008 emit-push-register:
16009
16010 55/push-ebp
16011 89/<- %ebp 4/r32/esp
16012
16013 8b/-> *(ebp+0xc) 0/r32/eax
16014
16015 8a/copy-byte *(eax+4) 0/r32/AL
16016 81 4/subop/and %eax 0xff/imm32
16017
16018 {
16019 3d/compare-eax-and 0x78/imm32/x
16020 0f 85/jump-if-!= break/disp32
16021
16022 (emit-indent *(ebp+8) *Curr-block-depth)
16023 (write-buffered *(ebp+8) "81 5/subop/subtract %esp 4/imm32\n")
16024 (emit-indent *(ebp+8) *Curr-block-depth)
16025 (write-buffered *(ebp+8) "f3 0f 11/<- *esp ")
16026
16027 8b/-> *(ebp+0xc) 0/r32/eax
16028 8a/copy-byte *(eax+7) 0/r32/AL
16029 81 4/subop/and %eax 0xff/imm32
16030 (write-byte-buffered *(ebp+8) %eax)
16031 (write-buffered *(ebp+8) "/x32\n")
16032 e9/jump $emit-push-register:end/disp32
16033 }
16034
16035 (emit-indent *(ebp+8) *Curr-block-depth)
16036 (write-buffered *(ebp+8) "ff 6/subop/push %")
16037 (write-buffered *(ebp+8) *(ebp+0xc))
16038 (write-buffered *(ebp+8) Newline)
16039 $emit-push-register:end:
16040
16041 89/<- %esp 5/r32/ebp
16042 5d/pop-to-ebp
16043 c3/return
16044
16045 emit-pop-register:
16046
16047 55/push-ebp
16048 89/<- %ebp 4/r32/esp
16049
16050 8b/-> *(ebp+0xc) 0/r32/eax
16051
16052 8a/copy-byte *(eax+4) 0/r32/AL
16053 81 4/subop/and %eax 0xff/imm32
16054
16055 {
16056 3d/compare-eax-and 0x78/imm32/x
16057 0f 85/jump-if-!= break/disp32
16058
16059 (emit-indent *(ebp+8) *Curr-block-depth)
16060 (write-buffered *(ebp+8) "f3 0f 10/-> *esp ")
16061
16062 8b/-> *(ebp+0xc) 0/r32/eax
16063 8a/copy-byte *(eax+7) 0/r32/AL
16064 81 4/subop/and %eax 0xff/imm32
16065 (write-byte-buffered *(ebp+8) %eax)
16066 (write-buffered *(ebp+8) "/x32\n")
16067 (emit-indent *(ebp+8) *Curr-block-depth)
16068 (write-buffered *(ebp+8) "81 0/subop/add %esp 4/imm32\n")
16069 e9/jump $emit-push-register:end/disp32
16070 }
16071
16072 (emit-indent *(ebp+8) *Curr-block-depth)
16073 (write-buffered *(ebp+8) "8f 0/subop/pop %")
16074 (write-buffered *(ebp+8) *(ebp+0xc))
16075 (write-buffered *(ebp+8) Newline)
16076 $emit-pop-register:end:
16077
16078 89/<- %esp 5/r32/ebp
16079 5d/pop-to-ebp
16080 c3/return
16081
16082
16083
16084 emit-cleanup-code-until-target:
16085
16086 55/push-ebp
16087 89/<- %ebp 4/r32/esp
16088
16089 50/push-eax
16090 51/push-ecx
16091 52/push-edx
16092 53/push-ebx
16093
16094 8b/-> *(ebp+0xc) 1/r32/ecx
16095
16096 8b/-> *ecx 0/r32/eax
16097
16098 8d/copy-address *(ecx+eax-4) 2/r32/edx
16099
16100 81 0/subop/add %ecx 8/imm32
16101 {
16102 $emit-cleanup-code-until-target:loop:
16103
16104 39/compare %edx 1/r32/ecx
16105 0f 82/jump-if-addr< break/disp32
16106
16107 (lookup *edx *(edx+4))
16108 89/<- %ebx 0/r32/eax
16109
16110 (lookup *ebx *(ebx+4))
16111 (string-equal? %eax *(ebp+0x10))
16112 3d/compare-eax-and 0/imm32/false
16113 0f 85/jump-if-!= break/disp32
16114
16115 81 7/subop/compare *(ebx+0x18) 0/imm32
16116 {
16117 0f 84/jump-if-= break/disp32
16118 {
16119 $emit-cleanup-code-until-target:check-for-previous-spill:
16120 8b/-> *(edx+8) 0/r32/eax
16121 3d/compare-eax-and 0/imm32/false
16122 74/jump-if-= break/disp8
16123 $emit-cleanup-code-until-target:reclaim-var-in-register:
16124 (emit-indent *(ebp+8) *Curr-block-depth)
16125 (write-buffered *(ebp+8) "8f 0/subop/pop %")
16126 (lookup *(ebx+0x18) *(ebx+0x1c))
16127 (write-buffered *(ebp+8) %eax)
16128 (write-buffered *(ebp+8) Newline)
16129 }
16130 eb/jump $emit-cleanup-code-until-target:continue/disp8
16131 }
16132
16133 {
16134 75/jump-if-!= break/disp8
16135 $emit-cleanup-code-until-target:reclaim-var-on-stack:
16136 (size-of %ebx)
16137
16138 3d/compare-eax-and 0/imm32
16139 74/jump-if-= break/disp8
16140
16141 (emit-indent *(ebp+8) *Curr-block-depth)
16142 (write-buffered *(ebp+8) "81 0/subop/add %esp ")
16143 (write-int32-hex-buffered *(ebp+8) %eax)
16144 (write-buffered *(ebp+8) "/imm32\n")
16145 }
16146 $emit-cleanup-code-until-target:continue:
16147
16148 81 5/subop/subtract %edx 0xc/imm32
16149 e9/jump loop/disp32
16150 }
16151 $emit-cleanup-code-until-target:end:
16152
16153 5b/pop-to-ebx
16154 5a/pop-to-edx
16155 59/pop-to-ecx
16156 58/pop-to-eax
16157
16158 89/<- %esp 5/r32/ebp
16159 5d/pop-to-ebp
16160 c3/return
16161
16162
16163
16164 clean-up-stack-offset-state:
16165
16166 55/push-ebp
16167 89/<- %ebp 4/r32/esp
16168
16169 50/push-eax
16170 51/push-ecx
16171 52/push-edx
16172 53/push-ebx
16173 56/push-esi
16174
16175 8b/-> *(ebp+8) 1/r32/ecx
16176
16177 8b/-> *ecx 6/r32/esi
16178
16179 8d/copy-address *(ecx+esi-4) 6/r32/esi
16180
16181 81 0/subop/add %ecx 8/imm32
16182
16183 8b/-> *(ebp+0xc) 2/r32/edx
16184 {
16185 $clean-up-stack-offset-state:loop:
16186
16187 39/compare %esi 1/r32/ecx
16188 0f 82/jump-if-addr< break/disp32
16189
16190 (lookup *esi *(esi+4))
16191 89/<- %ebx 0/r32/eax
16192
16193 39/compare *(ebx+0x10) 2/r32/edx
16194 0f 8c/jump-if-< break/disp32
16195
16196 81 7/subop/compare *(ebx+0x18) 0/imm32
16197 {
16198 0f 84/jump-if-= break/disp32
16199 {
16200 $clean-up-stack-offset-state:check-for-previous-spill:
16201 8b/-> *(esi+8) 0/r32/eax
16202 3d/compare-eax-and 0/imm32/false
16203 74/jump-if-= break/disp8
16204 $clean-up-stack-offset-state:reclaim-var-in-register:
16205 81 0/subop/add *Curr-local-stack-offset 4/imm32
16206 }
16207 eb/jump $clean-up-stack-offset-state:continue/disp8
16208 }
16209
16210 {
16211 75/jump-if-!= break/disp8
16212 $clean-up-stack-offset-state:var-on-stack:
16213 (size-of %ebx)
16214 01/add-to *Curr-local-stack-offset 0/r32/eax
16215 }
16216 $clean-up-stack-offset-state:continue:
16217
16218 81 5/subop/subtract %esi 0xc/imm32
16219 e9/jump loop/disp32
16220 }
16221 $clean-up-stack-offset-state:end:
16222
16223 5e/pop-to-esi
16224 5b/pop-to-ebx
16225 5a/pop-to-edx
16226 59/pop-to-ecx
16227 58/pop-to-eax
16228
16229 89/<- %esp 5/r32/ebp
16230 5d/pop-to-ebp
16231 c3/return
16232
16233
16234
16235
16236 not-yet-spilled-this-block?:
16237
16238 55/push-ebp
16239 89/<- %ebp 4/r32/esp
16240
16241 51/push-ecx
16242 52/push-edx
16243 53/push-ebx
16244 56/push-esi
16245 57/push-edi
16246
16247 8b/-> *(ebp+0xc) 1/r32/ecx
16248
16249 8b/-> *ecx 0/r32/eax
16250
16251 8d/copy-address *(ecx+eax-4) 2/r32/edx
16252
16253 8d/copy-address *(ecx+8) 1/r32/ecx
16254
16255 8b/-> *(ebp+8) 3/r32/ebx
16256 8b/-> *(ebx+0x10) 3/r32/ebx
16257
16258 8b/-> *(ebp+8) 6/r32/esi
16259 (lookup *(esi+0x18) *(esi+0x1c))
16260 89/<- %esi 0/r32/eax
16261 {
16262 $not-yet-spilled-this-block?:loop:
16263
16264 39/compare %edx 1/r32/ecx
16265 0f 82/jump-if-addr< break/disp32
16266
16267 (lookup *edx *(edx+4))
16268 89/<- %edi 0/r32/eax
16269
16270 39/compare *(edi+0x10) 3/r32/ebx
16271 0f 8c/jump-if-< break/disp32
16272
16273 (lookup *(edi+0x18) *(edi+0x1c))
16274 89/<- %edi 0/r32/eax
16275
16276 {
16277 $not-yet-spilled-this-block?:check-reg:
16278 81 7/subop/compare %edi 0/imm32
16279 0f 84/jump-if-= break/disp32
16280
16281 (string-equal? %esi %edi)
16282 3d/compare-eax-and 0/imm32/false
16283 74/jump-if-= break/disp8
16284 $not-yet-spilled-this-block?:return-false:
16285 b8/copy-to-eax 0/imm32/false
16286 eb/jump $not-yet-spilled-this-block?:end/disp8
16287 }
16288 $not-yet-spilled-this-block?:continue:
16289
16290 81 5/subop/subtract %edx 0xc/imm32
16291 e9/jump loop/disp32
16292 }
16293 $not-yet-spilled-this-block?:return-true:
16294
16295 b8/copy-to-eax 1/imm32/true
16296 $not-yet-spilled-this-block?:end:
16297
16298 5f/pop-to-edi
16299 5e/pop-to-esi
16300 5b/pop-to-ebx
16301 5a/pop-to-edx
16302 59/pop-to-ecx
16303
16304 89/<- %esp 5/r32/ebp
16305 5d/pop-to-ebp
16306 c3/return
16307
16308
16309 will-not-write-some-register?:
16310
16311 55/push-ebp
16312 89/<- %ebp 4/r32/esp
16313
16314 8b/-> *(ebp+8) 0/r32/eax
16315
16316 (lookup *(eax+0x18) *(eax+0x1c))
16317
16318 (find-register *(ebp+0x10) %eax)
16319
16320 {
16321 3d/compare-eax-and 0/imm32
16322 75/jump-if-!= break/disp8
16323 b8/copy-to-eax 1/imm32/true
16324 eb/jump $will-not-write-some-register?:end/disp8
16325 }
16326
16327 (assigns-in-stmts? *(ebp+0xc) %eax)
16328 3d/compare-eax-and 0/imm32/false
16329
16330 0f 94/set-if-= %al
16331 $will-not-write-some-register?:end:
16332
16333 89/<- %esp 5/r32/ebp
16334 5d/pop-to-ebp
16335 c3/return
16336
16337
16338
16339 find-register:
16340
16341 55/push-ebp
16342 89/<- %ebp 4/r32/esp
16343
16344 51/push-ecx
16345
16346 8b/-> *(ebp+8) 1/r32/ecx
16347 (lookup *(ecx+0x10) *(ecx+0x14))
16348 89/<- %ecx 0/r32/eax
16349 {
16350 $find-register:loop:
16351
16352 81 7/subop/compare %ecx 0/imm32
16353 74/jump-if-= break/disp8
16354
16355 (lookup *ecx *(ecx+4))
16356 (lookup *(eax+0x18) *(eax+0x1c))
16357
16358 $find-register:compare:
16359 (string-equal? *(ebp+0xc) %eax)
16360 {
16361 3d/compare-eax-and 0/imm32/false
16362 74/jump-if-= break/disp8
16363 $find-register:found:
16364 (lookup *ecx *(ecx+4))
16365 eb/jump $find-register:end/disp8
16366 }
16367
16368 (lookup *(ecx+8) *(ecx+0xc))
16369 89/<- %ecx 0/r32/eax
16370
16371 eb/jump loop/disp8
16372 }
16373 $find-register:end:
16374
16375 59/pop-to-ecx
16376
16377 89/<- %esp 5/r32/ebp
16378 5d/pop-to-ebp
16379 c3/return
16380
16381 assigns-in-stmts?:
16382
16383 55/push-ebp
16384 89/<- %ebp 4/r32/esp
16385
16386 51/push-ecx
16387
16388 8b/-> *(ebp+8) 1/r32/ecx
16389 {
16390
16391 81 7/subop/compare %ecx 0/imm32
16392 74/jump-if-= break/disp8
16393
16394 (lookup *ecx *(ecx+4))
16395 (assigns-in-stmt? %eax *(ebp+0xc))
16396 3d/compare-eax-and 0/imm32/false
16397 75/jump-if-!= break/disp8
16398
16399 (lookup *(ecx+8) *(ecx+0xc))
16400 89/<- %ecx 0/r32/eax
16401
16402 eb/jump loop/disp8
16403 }
16404 $assigns-in-stmts?:end:
16405
16406 59/pop-to-ecx
16407
16408 89/<- %esp 5/r32/ebp
16409 5d/pop-to-ebp
16410 c3/return
16411
16412 assigns-in-stmt?:
16413
16414 55/push-ebp
16415 89/<- %ebp 4/r32/esp
16416
16417 51/push-ecx
16418
16419 8b/-> *(ebp+8) 1/r32/ecx
16420
16421 {
16422 81 7/subop/compare *ecx 1/imm32/stmt1
16423 75/jump-if-!= break/disp8
16424 (lookup *(ecx+0x14) *(ecx+0x18))
16425 (assigns-in-stmt-vars? %eax *(ebp+0xc))
16426 eb/jump $assigns-in-stmt?:end/disp8
16427 }
16428
16429 {
16430 81 7/subop/compare *ecx 0/imm32/block
16431 75/jump-if-!= break/disp8
16432 (lookup *(ecx+4) *(ecx+8))
16433 (assigns-in-stmts? %eax *(ebp+0xc))
16434 eb/jump $assigns-in-stmt?:end/disp8
16435 }
16436
16437 b8/copy 0/imm32/false
16438 $assigns-in-stmt?:end:
16439
16440 59/pop-to-ecx
16441
16442 89/<- %esp 5/r32/ebp
16443 5d/pop-to-ebp
16444 c3/return
16445
16446 assigns-in-stmt-vars?:
16447
16448 55/push-ebp
16449 89/<- %ebp 4/r32/esp
16450
16451 51/push-ecx
16452
16453 8b/-> *(ebp+8) 1/r32/ecx
16454 {
16455
16456 81 7/subop/compare %ecx 0/imm32
16457 74/jump-if-= break/disp8
16458
16459 (lookup *ecx *(ecx+4))
16460
16461 {
16462 39/compare *(ebp+0xc) 0/r32/eax
16463 75/jump-if-!= break/disp8
16464 81 7/subop/compare *(ecx+0x10) 0/imm32/false
16465 75/jump-if-!= break/disp8
16466 b8/copy-to-eax 1/imm32/true
16467 eb/jump $assigns-in-stmt-vars?:end/disp8
16468 }
16469
16470 (lookup *(ecx+8) *(ecx+0xc))
16471 89/<- %ecx 0/r32/eax
16472
16473 eb/jump loop/disp8
16474 }
16475 $assigns-in-stmt-vars?:end:
16476
16477 59/pop-to-ecx
16478
16479 89/<- %esp 5/r32/ebp
16480 5d/pop-to-ebp
16481 c3/return
16482
16483
16484
16485
16486
16487 same-register-spilled-before?:
16488
16489 55/push-ebp
16490 89/<- %ebp 4/r32/esp
16491
16492 51/push-ecx
16493 52/push-edx
16494 53/push-ebx
16495 56/push-esi
16496 57/push-edi
16497
16498 8b/-> *(ebp+8) 1/r32/ecx
16499
16500 (lookup *(ecx+0x18) *(ecx+0x1c))
16501 89/<- %edx 0/r32/eax
16502
16503 8b/-> *(ecx+0x10) 3/r32/ebx
16504
16505 8b/-> *(ebp+0xc) 1/r32/ecx
16506 81 0/subop/add %ecx 8/imm32
16507
16508
16509
16510 8b/-> *(ebp+0x10) 6/r32/esi
16511
16512 81 5/subop/subtract %esi 8/imm32
16513 {
16514 $same-register-spilled-before?:loop:
16515
16516 39/compare %esi 1/r32/ecx
16517 0f 82/jump-if-addr< break/disp32
16518
16519 (lookup *esi *(esi+4))
16520
16521 39/compare *(eax+0x10) 3/r32/ebx
16522 0f 8c/jump-if-< break/disp32
16523
16524 81 7/subop/compare *(eax+0x18) 0/imm32
16525 74/jump-if-= $same-register-spilled-before?:continue/disp8
16526
16527 (lookup *(eax+0x18) *(eax+0x1c))
16528 (string-equal? %eax %edx)
16529 3d/compare-eax-and 0/imm32/false
16530 b8/copy-to-eax 1/imm32/true
16531 75/jump-if-!= $same-register-spilled-before?:end/disp8
16532 $same-register-spilled-before?:continue:
16533
16534 81 5/subop/subtract %esi 8/imm32
16535 e9/jump loop/disp32
16536 }
16537 $same-register-spilled-before?:false:
16538 b8/copy-to-eax 0/imm32/false
16539 $same-register-spilled-before?:end:
16540
16541 5f/pop-to-edi
16542 5e/pop-to-esi
16543 5b/pop-to-ebx
16544 5a/pop-to-edx
16545 59/pop-to-ecx
16546
16547 89/<- %esp 5/r32/ebp
16548 5d/pop-to-ebp
16549 c3/return
16550
16551
16552
16553
16554
16555
16556
16557
16558
16559
16560
16561
16562
16563
16564 clean-up-blocks:
16565
16566
16567
16568
16569
16570
16571
16572
16573
16574
16575
16576
16577
16578
16579
16580
16581
16582
16583
16584
16585
16586
16587
16588 55/push-ebp
16589 89/<- %ebp 4/r32/esp
16590
16591 50/push-eax
16592 52/push-edx
16593 53/push-ebx
16594 56/push-esi
16595 57/push-edi
16596
16597 8b/-> *(ebp+8) 3/r32/ebx
16598
16599 8b/-> *(ebp+0xc) 2/r32/edx
16600 $clean-up-blocks:phase1:
16601
16602 8b/-> *ebx 7/r32/edi
16603 {
16604 $clean-up-blocks:loop1:
16605
16606 81 7/subop/compare %edi 0/imm32
16607 7e/jump-if-<= break/disp8
16608
16609 8d/copy-address *(ebx+edi-4) 0/r32/eax
16610 (lookup *eax *(eax+4))
16611
16612 39/compare *(eax+0x10) 2/r32/edx
16613 {
16614 7d/jump-if->= break/disp8
16615
16616 (in-function-outputs? *(ebp+0x10) %eax)
16617 3d/compare-eax-and 0/imm32/false
16618 74/jump-if-= $clean-up-blocks:phase2/disp8
16619 }
16620 $clean-up-blocks:loop1-continue:
16621
16622 81 5/subop/subtract %edi 0xc/imm32
16623
16624 eb/jump loop/disp8
16625 }
16626 $clean-up-blocks:phase2:
16627
16628 89/<- %esi 7/r32/edi
16629 {
16630 $clean-up-blocks:loop2:
16631
16632 3b/compare 6/r32/esi *ebx
16633 7d/jump-if->= break/disp8
16634
16635 8d/copy-address *(ebx+esi+8) 0/r32/eax
16636 (lookup *eax *(eax+4))
16637
16638 (in-function-outputs? *(ebp+0x10) %eax)
16639 3d/compare-eax-and 0/imm32/false
16640 74/jump-if-= $clean-up-blocks:loop2-continue/disp8
16641
16642
16643 {
16644 39/compare %esi 7/r32/edi
16645 7e/jump-if-<= break/disp8
16646 56/push-esi
16647 57/push-edi
16648
16649 8d/copy-address *(ebx+esi+8) 6/r32/esi
16650
16651 8d/copy-address *(ebx+edi+8) 7/r32/edi
16652
16653 8b/-> *esi 0/r32/eax
16654 89/<- *edi 0/r32/eax
16655 8b/-> *(esi+4) 0/r32/eax
16656 89/<- *(edi+4) 0/r32/eax
16657 8b/-> *(esi+8) 0/r32/eax
16658 89/<- *(edi+8) 0/r32/eax
16659 5f/pop-to-edi
16660 5e/pop-to-esi
16661 }
16662
16663 81 0/subop/add %edi 0xc/imm32
16664 $clean-up-blocks:loop2-continue:
16665
16666 81 0/subop/add %esi 0xc/imm32
16667
16668 eb/jump loop/disp8
16669 }
16670 89/<- *ebx 7/r32/edi
16671 $clean-up-blocks:end:
16672
16673 5f/pop-to-edi
16674 5e/pop-to-esi
16675 5b/pop-to-ebx
16676 5a/pop-to-edx
16677 58/pop-to-eax
16678
16679 89/<- %esp 5/r32/ebp
16680 5d/pop-to-ebp
16681 c3/return
16682
16683 in-function-outputs?:
16684
16685 55/push-ebp
16686 89/<- %ebp 4/r32/esp
16687
16688 51/push-ecx
16689
16690 8b/-> *(ebp+8) 1/r32/ecx
16691 (lookup *(ecx+0x10) *(ecx+0x14))
16692 89/<- %ecx 0/r32/eax
16693
16694 {
16695 81 7/subop/compare %ecx 0/imm32
16696 74/jump-if-= break/disp8
16697
16698 (lookup *ecx *(ecx+4))
16699
16700 39/compare *(ebp+0xc) 0/r32/eax
16701 b8/copy-to-eax 1/imm32/true
16702 74/jump-if-= $in-function-outputs?:end/disp8
16703
16704 (lookup *(ecx+8) *(ecx+0xc))
16705 89/<- %ecx 0/r32/eax
16706
16707 eb/jump loop/disp8
16708 }
16709 b8/copy-to-eax 0/imm32
16710 $in-function-outputs?:end:
16711
16712 59/pop-to-ecx
16713
16714 89/<- %esp 5/r32/ebp
16715 5d/pop-to-ebp
16716 c3/return
16717
16718 emit-subx-var-def:
16719
16720 55/push-ebp
16721 89/<- %ebp 4/r32/esp
16722
16723 50/push-eax
16724 51/push-ecx
16725 52/push-edx
16726
16727 8b/-> *(ebp+0xc) 0/r32/eax
16728
16729 (lookup *(eax+4) *(eax+8))
16730 89/<- %ecx 0/r32/eax
16731
16732 8b/-> *Curr-block-depth 0/r32/eax
16733 89/<- *(ecx+0x10) 0/r32/eax
16734
16735 (size-of %ecx)
16736 89/<- %edx 0/r32/eax
16737
16738 29/subtract-from *Curr-local-stack-offset 2/r32/edx
16739
16740 8b/-> *Curr-local-stack-offset 0/r32/eax
16741 89/<- *(ecx+0x14) 0/r32/eax
16742
16743 {
16744 (lookup *(ecx+8) *(ecx+0xc))
16745 (is-mu-array? %eax)
16746 3d/compare-eax-and 0/imm32/false
16747 0f 84/jump-if-= break/disp32
16748
16749 81 5/subop/subtract %edx 4/imm32
16750
16751 (emit-array-data-initialization *(ebp+8) %edx)
16752 e9/jump $emit-subx-var-def:end/disp32
16753 }
16754
16755
16756 {
16757 (lookup *(ecx+8) *(ecx+0xc))
16758 (is-mu-stream? %eax)
16759 3d/compare-eax-and 0/imm32/false
16760 0f 84/jump-if-= break/disp32
16761
16762 81 5/subop/subtract %edx 0xc/imm32
16763 (emit-array-data-initialization *(ebp+8) %edx)
16764
16765 (emit-indent *(ebp+8) *Curr-block-depth)
16766 (write-buffered *(ebp+8) "68/push 0/imm32\n")
16767 (emit-indent *(ebp+8) *Curr-block-depth)
16768 (write-buffered *(ebp+8) "68/push 0/imm32\n")
16769
16770 eb/jump $emit-subx-var-def:end/disp8
16771 }
16772
16773 {
16774 81 7/subop/compare %edx 0/imm32
16775 7e/jump-if-<= break/disp8
16776 (emit-indent *(ebp+8) *Curr-block-depth)
16777 (write-buffered *(ebp+8) "68/push 0/imm32\n")
16778
16779 81 5/subop/subtract %edx 4/imm32
16780
16781 eb/jump loop/disp8
16782 }
16783 $emit-subx-var-def:end:
16784
16785 5a/pop-to-edx
16786 59/pop-to-ecx
16787 58/pop-to-eax
16788
16789 89/<- %esp 5/r32/ebp
16790 5d/pop-to-ebp
16791 c3/return
16792
16793 emit-array-data-initialization:
16794
16795 55/push-ebp
16796 89/<- %ebp 4/r32/esp
16797
16798 (emit-indent *(ebp+8) *Curr-block-depth)
16799 (write-buffered *(ebp+8) "(push-n-zero-bytes ")
16800 (write-int32-hex-buffered *(ebp+8) *(ebp+0xc))
16801 (write-buffered *(ebp+8) ")\n")
16802 (emit-indent *(ebp+8) *Curr-block-depth)
16803 (write-buffered *(ebp+8) "68/push ")
16804 (write-int32-hex-buffered *(ebp+8) *(ebp+0xc))
16805 (write-buffered *(ebp+8) "/imm32\n")
16806 $emit-array-data-initialization:end:
16807
16808 89/<- %esp 5/r32/ebp
16809 5d/pop-to-ebp
16810 c3/return
16811
16812 emit-subx-stmt:
16813
16814 55/push-ebp
16815 89/<- %ebp 4/r32/esp
16816
16817 50/push-eax
16818 51/push-ecx
16819
16820
16821 8b/-> *(ebp+0xc) 1/r32/ecx
16822 (lookup *(ecx+4) *(ecx+8))
16823 89/<- %ecx 0/r32/eax
16824
16825 {
16826
16827 (string-equal? %ecx "length")
16828 3d/compare-eax-and 0/imm32
16829 0f 84/jump-if-= break/disp32
16830 (translate-mu-length-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
16831 e9/jump $emit-subx-stmt:end/disp32
16832 }
16833
16834 {
16835
16836 (string-equal? %ecx "index")
16837 3d/compare-eax-and 0/imm32
16838 0f 84/jump-if-= break/disp32
16839 (translate-mu-index-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
16840 e9/jump $emit-subx-stmt:end/disp32
16841 }
16842
16843 {
16844
16845 (string-equal? %ecx "compute-offset")
16846 3d/compare-eax-and 0/imm32
16847 0f 84/jump-if-= break/disp32
16848 (translate-mu-compute-index-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
16849 e9/jump $emit-subx-stmt:end/disp32
16850 }
16851
16852 {
16853
16854 (string-equal? %ecx "get")
16855 3d/compare-eax-and 0/imm32
16856 0f 84/jump-if-= break/disp32
16857 (translate-mu-get-stmt *(ebp+8) *(ebp+0xc))
16858 e9/jump $emit-subx-stmt:end/disp32
16859 }
16860
16861 {
16862
16863 (string-equal? %ecx "allocate")
16864 3d/compare-eax-and 0/imm32
16865 0f 84/jump-if-= break/disp32
16866 (translate-mu-allocate-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
16867 e9/jump $emit-subx-stmt:end/disp32
16868 }
16869
16870 {
16871
16872 (string-equal? %ecx "copy-object")
16873 3d/compare-eax-and 0/imm32
16874 0f 84/jump-if-= break/disp32
16875 (translate-mu-copy-object-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
16876 e9/jump $emit-subx-stmt:end/disp32
16877 }
16878
16879 {
16880
16881 (string-equal? %ecx "populate")
16882 3d/compare-eax-and 0/imm32
16883 0f 84/jump-if-= break/disp32
16884 (translate-mu-populate-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
16885 e9/jump $emit-subx-stmt:end/disp32
16886 }
16887
16888 {
16889
16890 (string-equal? %ecx "populate-stream")
16891 3d/compare-eax-and 0/imm32
16892 0f 84/jump-if-= break/disp32
16893 (translate-mu-populate-stream-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
16894 e9/jump $emit-subx-stmt:end/disp32
16895 }
16896
16897 {
16898
16899 (string-equal? %ecx "read-from-stream")
16900 3d/compare-eax-and 0/imm32
16901 0f 84/jump-if-= break/disp32
16902 (translate-mu-read-from-stream-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
16903 e9/jump $emit-subx-stmt:end/disp32
16904 }
16905
16906 {
16907
16908 (string-equal? %ecx "write-to-stream")
16909 3d/compare-eax-and 0/imm32
16910 0f 84/jump-if-= break/disp32
16911 (translate-mu-write-to-stream-stmt *(ebp+8) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
16912 e9/jump $emit-subx-stmt:end/disp32
16913 }
16914
16915 {
16916 $emit-subx-stmt:check-for-primitive:
16917
16918 (find-matching-primitive *(ebp+0x10) *(ebp+0xc))
16919 3d/compare-eax-and 0/imm32
16920 74/jump-if-= break/disp8
16921 $emit-subx-stmt:primitive:
16922 (emit-subx-primitive *(ebp+8) *(ebp+0xc) %eax)
16923 e9/jump $emit-subx-stmt:end/disp32
16924 }
16925
16926
16927 $emit-subx-stmt:call:
16928 (emit-call *(ebp+8) *(ebp+0xc))
16929 $emit-subx-stmt:end:
16930
16931 59/pop-to-ecx
16932 58/pop-to-eax
16933
16934 89/<- %esp 5/r32/ebp
16935 5d/pop-to-ebp
16936 c3/return
16937
16938 translate-mu-length-stmt:
16939
16940 55/push-ebp
16941 89/<- %ebp 4/r32/esp
16942
16943 50/push-eax
16944 51/push-ecx
16945 52/push-edx
16946 53/push-ebx
16947 56/push-esi
16948
16949 8b/-> *(ebp+0xc) 6/r32/esi
16950
16951 (lookup *(esi+0xc) *(esi+0x10))
16952 (lookup *eax *(eax+4))
16953 89/<- %ebx 0/r32/eax
16954
16955 (array-element-size %ebx *(ebp+0x10) *(ebp+0x14))
16956 89/<- %ecx 0/r32/eax
16957
16958 (lookup *(esi+0x14) *(esi+0x18))
16959 (lookup *eax *(eax+4))
16960 (lookup *(eax+0x18) *(eax+0x1c))
16961 89/<- %edx 0/r32/eax
16962
16963 {
16964 81 7/subop/compare %ecx 1/imm32
16965 75/jump-if-!= break/disp8
16966 $translate-mu-length-stmt:size-1:
16967 (emit-save-size-to *(ebp+8) %ebx %edx)
16968 e9/jump $translate-mu-length-stmt:end/disp32
16969 }
16970
16971 {
16972 (power-of-2? %ecx *(ebp+0x10) *(ebp+0x14))
16973 3d/compare-eax-and 0/imm32/false
16974 74/jump-if-= break/disp8
16975 81 7/subop/compare %ecx 0xff/imm32
16976 7f/jump-if-> break/disp8
16977 $translate-mu-length-stmt:size-power-of-2:
16978 (emit-save-size-to *(ebp+8) %ebx %edx)
16979 (emit-divide-by-shift-right *(ebp+8) %edx %ecx)
16980 e9/jump $translate-mu-length-stmt:end/disp32
16981 }
16982
16983
16984 {
16985 $translate-mu-length-stmt:complex:
16986 (string-equal? %edx "eax")
16987 3d/compare-eax-and 0/imm32/false
16988 75/break-if-!= break/disp8
16989 (emit-indent *(ebp+8) *Curr-block-depth)
16990 (write-buffered *(ebp+8) "50/push-eax\n")
16991 }
16992 {
16993 (string-equal? %edx "ecx")
16994 3d/compare-eax-and 0/imm32/false
16995 75/break-if-!= break/disp8
16996 (emit-indent *(ebp+8) *Curr-block-depth)
16997 (write-buffered *(ebp+8) "51/push-ecx\n")
16998 }
16999 {
17000 (string-equal? %edx "edx")
17001 3d/compare-eax-and 0/imm32/false
17002 75/break-if-!= break/disp8
17003 (emit-indent *(ebp+8) *Curr-block-depth)
17004 (write-buffered *(ebp+8) "52/push-edx\n")
17005 }
17006
17007 (emit-save-size-to *(ebp+8) %ebx "eax")
17008 (emit-indent *(ebp+8) *Curr-block-depth)
17009 (write-buffered *(ebp+8) "31/xor %edx 2/r32/edx\n")
17010 (emit-indent *(ebp+8) *Curr-block-depth)
17011 (write-buffered *(ebp+8) "b9/copy-to-ecx ")
17012 (write-int32-hex-buffered *(ebp+8) %ecx)
17013 (write-buffered *(ebp+8) "/imm32\n")
17014 (emit-indent *(ebp+8) *Curr-block-depth)
17015 (write-buffered *(ebp+8) "f7 7/subop/idiv-eax-edx-by %ecx\n")
17016 {
17017 (string-equal? %edx "eax")
17018 3d/compare-eax-and 0/imm32/false
17019 75/break-if-!= break/disp8
17020 (emit-indent *(ebp+8) *Curr-block-depth)
17021 (write-buffered *(ebp+8) "89/<- %")
17022 (write-buffered *(ebp+8) %edx)
17023 (write-buffered *(ebp+8) " 0/r32/eax\n")
17024 }
17025
17026 {
17027 (string-equal? %edx "edx")
17028 3d/compare-eax-and 0/imm32/false
17029 75/break-if-!= break/disp8
17030 (emit-indent *(ebp+8) *Curr-block-depth)
17031 (write-buffered *(ebp+8) "5a/pop-to-edx\n")
17032 }
17033 {
17034 (string-equal? %edx "ecx")
17035 3d/compare-eax-and 0/imm32/false
17036 75/break-if-!= break/disp8
17037 (emit-indent *(ebp+8) *Curr-block-depth)
17038 (write-buffered *(ebp+8) "59/pop-to-ecx\n")
17039 }
17040 {
17041 (string-equal? %edx "eax")
17042 3d/compare-eax-and 0/imm32/false
17043 75/break-if-!= break/disp8
17044 (emit-indent *(ebp+8) *Curr-block-depth)
17045 (write-buffered *(ebp+8) "58/pop-to-eax\n")
17046 }
17047 $translate-mu-length-stmt:end:
17048
17049 5e/pop-to-esi
17050 5b/pop-to-ebx
17051 5a/pop-to-edx
17052 59/pop-to-ecx
17053 58/pop-to-eax
17054
17055 89/<- %esp 5/r32/ebp
17056 5d/pop-to-ebp
17057 c3/return
17058
17059 array-element-size:
17060
17061 55/push-ebp
17062 89/<- %ebp 4/r32/esp
17063
17064 (array-element-type-id *(ebp+8) *(ebp+0xc) *(ebp+0x10))
17065 (size-of-type-id-as-array-element %eax)
17066 $array-element-size:end:
17067
17068 89/<- %esp 5/r32/ebp
17069 5d/pop-to-ebp
17070 c3/return
17071
17072 array-element-type-id:
17073
17074
17075 55/push-ebp
17076 89/<- %ebp 4/r32/esp
17077
17078 8b/-> *(ebp+8) 0/r32/eax
17079
17080 (lookup *(eax+8) *(eax+0xc))
17081
17082 3d/compare-eax-with 0/imm32
17083 0f 84/jump-if-== $array-element-type-id:error0/disp32
17084
17085 81 7/subop/compare *eax 0/imm32/false
17086 0f 85/jump-if-!= $array-element-type-id:error1/disp32
17087
17088 {
17089 50/push-eax
17090 (lookup *(eax+4) *(eax+8))
17091 (is-simple-mu-type? %eax 2)
17092 3d/compare-eax-with 0/imm32/false
17093 58/pop-to-eax
17094 74/jump-if-= break/disp8
17095 $array-element-type-id:skip-addr:
17096 (lookup *(eax+0xc) *(eax+0x10))
17097 }
17098
17099 3d/compare-eax-with 0/imm32
17100 0f 84/jump-if-= $array-element-type-id:error2/disp32
17101
17102 81 7/subop/compare *eax 0/imm32/false
17103 0f 85/jump-if-!= $array-element-type-id:error2/disp32
17104
17105 {
17106 50/push-eax
17107 (lookup *(eax+4) *(eax+8))
17108 (is-simple-mu-type? %eax 3)
17109 3d/compare-eax-with 0/imm32/false
17110 58/pop-to-eax
17111 $array-element-type-id:no-array:
17112 0f 84/jump-if-= $array-element-type-id:error2/disp32
17113 }
17114 $array-element-type-id:skip-array:
17115
17116 (lookup *(eax+0xc) *(eax+0x10))
17117
17118 3d/compare-eax-with 0/imm32
17119 0f 84/jump-if-= $array-element-type-id:error2/disp32
17120
17121 81 7/subop/compare *eax 0/imm32/false
17122 0f 85/jump-if-!= $array-element-type-id:error2/disp32
17123
17124 (lookup *(eax+4) *(eax+8))
17125 8b/-> *(eax+4) 0/r32/eax
17126 $array-element-type-id:end:
17127
17128 89/<- %esp 5/r32/ebp
17129 5d/pop-to-ebp
17130 c3/return
17131
17132 $array-element-type-id:error0:
17133 (write-buffered *(ebp+0xc) "array-element-type-id: var '")
17134 50/push-eax
17135 8b/-> *(ebp+8) 0/r32/eax
17136 (lookup *eax *(eax+4))
17137 (write-buffered *(ebp+0xc) %eax)
17138 58/pop-to-eax
17139 (write-buffered *(ebp+0xc) "' has no type\n")
17140 (flush *(ebp+0xc))
17141 (stop *(ebp+0x10) 1)
17142
17143
17144 $array-element-type-id:error1:
17145 (write-buffered *(ebp+0xc) "array-element-type-id: var '")
17146 50/push-eax
17147 8b/-> *(ebp+8) 0/r32/eax
17148 (lookup *eax *(eax+4))
17149 (write-buffered *(ebp+0xc) %eax)
17150 58/pop-to-eax
17151 (write-buffered *(ebp+0xc) "' has atomic type ")
17152 (write-int32-hex-buffered *(ebp+0xc) *(eax+4))
17153 (write-buffered *(ebp+0xc) Newline)
17154 (flush *(ebp+0xc))
17155 (stop *(ebp+0x10) 1)
17156
17157
17158 $array-element-type-id:error2:
17159 (write-buffered *(ebp+0xc) "array-element-type-id: var '")
17160 50/push-eax
17161 8b/-> *(ebp+8) 0/r32/eax
17162 (lookup *eax *(eax+4))
17163 (write-buffered *(ebp+0xc) %eax)
17164 58/pop-to-eax
17165 (write-buffered *(ebp+0xc) "' has non-array type\n")
17166 (flush *(ebp+0xc))
17167 (stop *(ebp+0x10) 1)
17168
17169
17170 size-of-type-id-as-array-element:
17171
17172 55/push-ebp
17173 89/<- %ebp 4/r32/esp
17174
17175 8b/-> *(ebp+8) 0/r32/eax
17176
17177 3d/compare-eax-and 8/imm32/byte
17178 {
17179 75/jump-if-!= break/disp8
17180 b8/copy-to-eax 1/imm32
17181 eb/jump $size-of-type-id-as-array-element:end/disp8
17182 }
17183
17184 (size-of-type-id %eax)
17185 $size-of-type-id-as-array-element:end:
17186
17187 89/<- %esp 5/r32/ebp
17188 5d/pop-to-ebp
17189 c3/return
17190
17191 emit-save-size-to:
17192
17193 55/push-ebp
17194 89/<- %ebp 4/r32/esp
17195
17196 50/push-eax
17197 53/push-ebx
17198
17199 8b/-> *(ebp+0xc) 3/r32/ebx
17200 (emit-indent *(ebp+8) *Curr-block-depth)
17201 (write-buffered *(ebp+8) "8b/-> *")
17202
17203 {
17204 81 7/subop/compare *(ebx+0x18)) 0/imm32
17205 74/jump-if-= break/disp8
17206 $emit-save-size-to:emit-base-from-register:
17207 (lookup *(ebx+0x18) *(ebx+0x1c))
17208 (write-buffered *(ebp+8) %eax)
17209 eb/jump $emit-save-size-to:emit-output/disp8
17210 }
17211
17212 {
17213 81 7/subop/compare *(ebx+0x14)) 0/imm32
17214 74/jump-if-= break/disp8
17215 $emit-save-size-to:emit-base-from-stack:
17216 (write-buffered *(ebp+8) "(ebp+")
17217 (write-int32-hex-buffered *(ebp+8) *(ebx+0x14))
17218 (write-buffered *(ebp+8) ")")
17219 }
17220 $emit-save-size-to:emit-output:
17221 (write-buffered *(ebp+8) " ")
17222 (get Mu-registers *(ebp+0x10) 0xc "Mu-registers")
17223 (write-int32-hex-buffered *(ebp+8) *eax)
17224 (write-buffered *(ebp+8) "/r32\n")
17225 $emit-save-size-to:end:
17226
17227 5b/pop-to-ebx
17228 58/pop-to-eax
17229
17230 89/<- %esp 5/r32/ebp
17231 5d/pop-to-ebp
17232 c3/return
17233
17234 emit-divide-by-shift-right:
17235
17236 55/push-ebp
17237 89/<- %ebp 4/r32/esp
17238
17239 50/push-eax
17240
17241 (emit-indent *(ebp+8) *Curr-block-depth)
17242 (write-buffered *(ebp+8) "c1/shift 5/subop/>> %")
17243 (write-buffered *(ebp+8) *(ebp+0xc))
17244 (write-buffered *(ebp+8) Space)
17245 (num-shift-rights *(ebp+0x10))
17246 (write-int32-hex-buffered *(ebp+8) %eax)
17247 (write-buffered *(ebp+8) "/imm8\n")
17248 $emit-divide-by-shift-right:end:
17249
17250 58/pop-to-eax
17251
17252 89/<- %esp 5/r32/ebp
17253 5d/pop-to-ebp
17254 c3/return
17255
17256 translate-mu-index-stmt:
17257
17258 55/push-ebp
17259 89/<- %ebp 4/r32/esp
17260
17261 51/push-ecx
17262
17263 8b/-> *(ebp+0xc) 1/r32/ecx
17264
17265 (lookup *(ecx+0xc) *(ecx+0x10))
17266 (lookup *eax *(eax+4))
17267 89/<- %ecx 0/r32/eax
17268
17269 {
17270 81 7/subop/compare *(ecx+0x18) 0/imm32
17271 74/jump-if-= break/disp8
17272
17273 (translate-mu-index-stmt-with-array-in-register *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
17274 eb/jump $translate-mu-index-stmt:end/disp8
17275 }
17276
17277 {
17278 81 7/subop/compare *(ecx+0x14) 0/imm32
17279 74/jump-if-= break/disp8
17280
17281 (translate-mu-index-stmt-with-array-on-stack *(ebp+8) *(ebp+0xc) *(ebp+0x10) *(ebp+0x14))
17282 eb/jump $translate-mu-index-stmt:end/disp8
17283 }
17284 $translate-mu-index-stmt:end:
17285
17286 59/pop-to-ecx
17287
17288 89/<- %esp 5/r32/ebp
17289 5d/pop-to-ebp
17290 c3/return
17291
17292 $translate-mu-index-stmt-with-array:error1:
17293 (write-buffered *(ebp+0x10) "couldn't translate an index instruction. second (index) input must either lie in a register or be a literal\n")
17294 (flush *(ebp+0x10))
17295 (stop *(ebp+0x14) 1)
17296
17297
17298 $translate-mu-index-stmt-with-array:error2:
17299 (write-buffered *(ebp+0x10) "couldn't translate an index instruction. second (index) input when in a register must be an int or offset\n")
17300 (flush *(ebp+0x10))
17301 (stop *(ebp+0x14) 1)
17302
17303
17304 translate-mu-index-stmt-with-array-in-register:
17305
17306 55/push-ebp
17307 89/<- %ebp 4/r32/esp
17308
17309 50/push-eax
17310 51/push-ecx
17311 52/push-edx
17312 53/push-ebx
17313
17314 (emit-indent *(ebp+8) *Curr-block-depth)
17315 (write-buffered *(ebp+8) "8d/copy-address *(")
17316
17317 $translate-mu-index-stmt-with-array-in-register:emit-base:
17318
17319 8b/-> *(ebp+0xc) 1/r32/ecx
17320
17321 (lookup *(ecx+0xc) *(ecx+0x10))
17322 (lookup *eax *(eax+4))
17323 89/<- %ebx 0/r32/eax
17324
17325 (lookup *(ebx+0x18) *(ebx+0x1c))
17326 (write-buffered *(ebp+8) %eax)
17327 (write-buffered *(ebp+8) " + ")
17328
17329 (lookup *(ecx+0xc) *(ecx+0x10))
17330 (lookup *(eax+8) *(eax+0xc))
17331 (lookup *eax *(eax+4))
17332 89/<- %edx 0/r32/eax
17333
17334 81 7/subop/compare *(edx+0x18) 0/imm32
17335 {
17336 0f 84/jump-if-= break/disp32
17337 $translate-mu-index-stmt-with-array-in-register:emit-register-index:
17338
17339 (lookup *(edx+8) *(edx+0xc))
17340 (is-simple-mu-type? %eax 1)
17341 3d/compare-eax-and 0/imm32/false
17342 {
17343 0f 84/jump-if-= break/disp32
17344 $translate-mu-index-stmt-with-array-in-register:emit-int-register-index:
17345
17346
17347 (lookup *(edx+0x18) *(edx+0x1c))
17348 (write-buffered *(ebp+8) %eax)
17349 (write-buffered *(ebp+8) "<<")
17350
17351
17352 (array-element-size %ebx *(ebp+0x10) *(ebp+0x14))
17353 (num-shift-rights %eax)
17354 (write-int32-hex-buffered *(ebp+8) %eax)
17355 e9/jump $translate-mu-index-stmt-with-array-in-register:emit-register-index-done/disp32
17356 }
17357
17358 (lookup *(edx+8) *(edx+0xc))
17359 81 7/subop/compare *eax 0/imm32/false
17360 0f 85/jump-if-!= $translate-mu-index-stmt-with-array:error2/disp32
17361
17362 (lookup *(eax+4) *(eax+8))
17363 (is-simple-mu-type? %eax 7)
17364 3d/compare-eax-and 0/imm32/false
17365 {
17366 0f 84/jump-if-= break/disp32
17367
17368 $translate-mu-index-stmt-with-array-in-register:emit-offset-register-index:
17369 (lookup *(edx+0x18) *(edx+0x1c))
17370 (write-buffered *(ebp+8) %eax)
17371 }
17372 $translate-mu-index-stmt-with-array-in-register:emit-register-index-done:
17373 (write-buffered *(ebp+8) " + 4) ")
17374 e9/jump $translate-mu-index-stmt-with-array-in-register:emit-output/disp32
17375 }
17376
17377 (lookup *(edx+8) *(edx+0xc))
17378 (is-simple-mu-type? %eax 0)
17379 3d/compare-eax-and 0/imm32/false
17380 {
17381 0f 84/jump-if-= break/disp32
17382 $translate-mu-index-stmt-with-array-in-register:emit-literal-index:
17383
17384 (lookup *edx *(edx+4))
17385 (parse-hex-int %eax)
17386 89/<- %edx 0/r32/eax
17387
17388 (array-element-size %ebx *(ebp+0x10) *(ebp+0x14))
17389 f7 4/subop/multiply-into-edx-eax %edx
17390
17391 05/add-to-eax 4/imm32
17392
17393
17394 (write-int32-hex-buffered *(ebp+8) %eax)
17395 (write-buffered *(ebp+8) ") ")
17396 e9/jump $translate-mu-index-stmt-with-array-in-register:emit-output/disp32
17397 }
17398
17399 e9/jump $translate-mu-index-stmt-with-array:error1/disp32
17400 $translate-mu-index-stmt-with-array-in-register:emit-output:
17401
17402 8b/-> *(ebp+0xc) 1/r32/ecx
17403 (lookup *(ecx+0x14) *(ecx+0x18))
17404 (lookup *eax *(eax+4))
17405 (lookup *(eax+0x18) *(eax+0x1c))
17406 (get Mu-registers %eax 0xc "Mu-registers")
17407 (write-int32-hex-buffered *(ebp+8) *eax)
17408 (write-buffered *(ebp+8) "/r32\n")
17409 $translate-mu-index-stmt-with-array-in-register:end:
17410
17411 5b/pop-to-ebx
17412 5a/pop-to-edx
17413 59/pop-to-ecx
17414 58/pop-to-eax
17415
17416 89/<- %esp 5/r32/ebp
17417 5d/pop-to-ebp
17418 c3/return
17419
17420 translate-mu-index-stmt-with-array-on-stack:
17421
17422 55/push-ebp
17423 89/<- %ebp 4/r32/esp
17424
17425 50/push-eax
17426 51/push-ecx
17427 52/push-edx
17428 53/push-ebx
17429
17430 (emit-indent *(ebp+8) *Curr-block-depth)
17431 (write-buffered *(ebp+8) "8d/copy-address *(ebp + ")
17432
17433 8b/-> *(ebp+0xc) 0/r32/eax
17434 (lookup *(eax+0xc) *(eax+0x10))
17435 89/<- %edx 0/r32/eax
17436
17437 (lookup *eax *(eax+4))
17438 89/<- %ecx 0/r32/eax
17439
17440 (lookup *(edx+8) *(edx+0xc))
17441
17442 (lookup *eax *(eax+4))
17443 89/<- %edx 0/r32/eax
17444
17445 81 7/subop/compare *(edx+0x18) 0/imm32
17446 {
17447 0f 84/jump-if-= break/disp32
17448 $translate-mu-index-stmt-with-array-on-stack:emit-register-index:
17449
17450 (lookup *(edx+8) *(edx+0xc))
17451 (is-simple-mu-type? %eax 1)
17452 3d/compare-eax-and 0/imm32/false
17453 {
17454 0f 84/jump-if-= break/disp32
17455 $translate-mu-index-stmt-with-array-on-stack:emit-int-register-index:
17456
17457
17458 (lookup *(edx+0x18) *(edx+0x1c))
17459 (write-buffered *(ebp+8) %eax)
17460 (write-buffered *(ebp+8) "<<")
17461
17462
17463 (array-element-size %ecx *(ebp+0x10) *(ebp+0x14))
17464 (num-shift-rights %eax)
17465 (write-int32-hex-buffered *(ebp+8) %eax)
17466
17467 (write-buffered *(ebp+8) " + ")
17468
17469 8b/-> *(ecx+0x14) 0/r32/eax
17470 05/add-to-eax 4/imm32
17471 (write-int32-hex-buffered *(ebp+8) %eax)
17472 e9/jump $translate-mu-index-stmt-with-array-on-stack:emit-register-index-done/disp32
17473 }
17474
17475 (lookup *(edx+8) *(edx+0xc))
17476 81 7/subop/compare *eax 0/imm32/false
17477 0f 85/jump-if-!= $translate-mu-index-stmt-with-array:error2/disp32
17478
17479 (lookup *(eax+4) *(eax+8))
17480 (is-simple-mu-type? %eax 7)
17481 3d/compare-eax-and 0/imm32/false
17482 {
17483 0f 84/jump-if-= break/disp32
17484
17485 $translate-mu-index-stmt-with-array-on-stack:emit-offset-register-index:
17486 (lookup *(edx+0x18) *(edx+0x1c))
17487 (write-buffered *(ebp+8) %eax)
17488 }
17489 $translate-mu-index-stmt-with-array-on-stack:emit-register-index-done:
17490 (write-buffered *(ebp+8) ") ")
17491 e9/jump $translate-mu-index-stmt-with-array-on-stack:emit-output/disp32
17492 }
17493
17494 (lookup *(edx+8) *(edx+0xc))
17495 (is-simple-mu-type? %eax 0)
17496 3d/compare-eax-and 0/imm32/false
17497 {
17498 0f 84/jump-if-= break/disp32
17499 $translate-mu-index-stmt-with-array-on-stack:emit-literal-index:
17500
17501 (lookup *edx *(edx+4))
17502 (parse-hex-int %eax)
17503 89/<- %edx 0/r32/eax
17504
17505 (array-element-size %ecx *(ebp+0x10) *(ebp+0x14))
17506 f7 4/subop/multiply-into-edx-eax %edx
17507
17508 03/add *(ecx+0x14) 0/r32/eax
17509
17510 05/add-to-eax 4/imm32
17511
17512
17513 (write-int32-hex-buffered *(ebp+8) %eax)
17514 (write-buffered *(ebp+8) ") ")
17515 e9/jump $translate-mu-index-stmt-with-array-on-stack:emit-output/disp32
17516 }
17517
17518 e9/jump $translate-mu-index-stmt-with-array:error1/disp32
17519 $translate-mu-index-stmt-with-array-on-stack:emit-output:
17520
17521 8b/-> *(ebp+0xc) 0/r32/eax
17522 (lookup *(eax+0x14) *(eax+0x18))
17523 (lookup *eax *(eax+4))
17524 (lookup *(eax+0x18) *(eax+0x1c))
17525 (get Mu-registers %eax 0xc "Mu-registers")
17526 (write-int32-hex-buffered *(ebp+8) *eax)
17527 (write-buffered *(ebp+8) "/r32\n")
17528 $translate-mu-index-stmt-with-array-on-stack:end:
17529
17530 5b/pop-to-ebx
17531 5a/pop-to-edx
17532 59/pop-to-ecx
17533 58/pop-to-eax
17534
17535 89/<- %esp 5/r32/ebp
17536 5d/pop-to-ebp
17537 c3/return
17538
17539 translate-mu-compute-index-stmt:
17540
17541 55/push-ebp
17542 89/<- %ebp 4/r32/esp
17543
17544 50/push-eax
17545 51/push-ecx
17546 52/push-edx
17547 53/push-ebx
17548
17549 (emit-indent *(ebp+8) *Curr-block-depth)
17550 (write-buffered *(ebp+8) "69/multiply")
17551
17552 8b/-> *(ebp+0xc) 1/r32/ecx
17553
17554 (lookup *(ecx+0xc) *(ecx+0x10))
17555 89/<- %ebx 0/r32/eax
17556 $translate-mu-compute-index-stmt:emit-index:
17557 (lookup *(ebx+8) *(ebx+0xc))
17558 (emit-subx-var-as-rm32 *(ebp+8) %eax)
17559 (write-buffered *(ebp+8) Space)
17560 $translate-mu-compute-index-stmt:emit-elem-size:
17561
17562 (lookup *ebx *(ebx+4))
17563 89/<- %ebx 0/r32/eax
17564
17565 (array-element-size %ebx *(ebp+0x10) *(ebp+0x14))
17566 (write-int32-hex-buffered *(ebp+8) %eax)
17567 (write-buffered *(ebp+8) "/imm32 ")
17568 $translate-mu-compute-index-stmt:emit-output:
17569
17570 (lookup *(ecx+0x14) *(ecx+0x18))
17571 (lookup *eax *(eax+4))
17572 (lookup *(eax+0x18) *(eax+0x1c))
17573 (get Mu-registers %eax 0xc "Mu-registers")
17574 (write-int32-hex-buffered *(ebp+8) *eax)
17575 (write-buffered *(ebp+8) "/r32\n")
17576 $translate-mu-compute-index-stmt:end:
17577
17578 5b/pop-to-ebx
17579 5a/pop-to-edx
17580 59/pop-to-ecx
17581 58/pop-to-eax
17582
17583 89/<- %esp 5/r32/ebp
17584 5d/pop-to-ebp
17585 c3/return
17586
17587 translate-mu-get-stmt:
17588
17589 55/push-ebp
17590 89/<- %ebp 4/r32/esp
17591
17592 50/push-eax
17593 51/push-ecx
17594 52/push-edx
17595
17596 (emit-indent *(ebp+8) *Curr-block-depth)
17597 (write-buffered *(ebp+8) "8d/copy-address ")
17598
17599 8b/-> *(ebp+0xc) 1/r32/ecx
17600
17601 (mu-get-offset %ecx)
17602 89/<- %edx 0/r32/eax
17603
17604 (lookup *(ecx+0xc) *(ecx+0x10))
17605 (lookup *eax *(eax+4))
17606
17607 81 7/subop/compare *(eax+0x18) 0/imm32
17608 {
17609 0f 84/jump-if-= break/disp32
17610 $translate-mu-get-stmt:emit-register-input:
17611
17612 (write-buffered *(ebp+8) "*(")
17613 (lookup *(eax+0x18) *(eax+0x1c))
17614 (write-buffered *(ebp+8) %eax)
17615 (write-buffered *(ebp+8) " + ")
17616 (write-int32-hex-buffered *(ebp+8) %edx)
17617 (write-buffered *(ebp+8) ") ")
17618 e9/jump $translate-mu-get-stmt:emit-output/disp32
17619 }
17620
17621 {
17622 $translate-mu-get-stmt:emit-stack-input:
17623
17624 (write-buffered *(ebp+8) "*(ebp+")
17625 03/add *(eax+0x14) 2/r32/edx
17626 (write-int32-hex-buffered *(ebp+8) %edx)
17627 (write-buffered *(ebp+8) ") ")
17628 eb/jump $translate-mu-get-stmt:emit-output/disp8
17629 }
17630 $translate-mu-get-stmt:emit-output:
17631
17632 (lookup *(ecx+0x14) *(ecx+0x18))
17633 (lookup *eax *(eax+4))
17634
17635 (lookup *(eax+0x18) *(eax+0x1c))
17636 (get Mu-registers %eax 0xc "Mu-registers")
17637 (write-int32-hex-buffered *(ebp+8) *eax)
17638 (write-buffered *(ebp+8) "/r32\n")
17639 $translate-mu-get-stmt:end:
17640
17641 5a/pop-to-edx
17642 59/pop-to-ecx
17643 58/pop-to-eax
17644
17645 89/<- %esp 5/r32/ebp
17646 5d/pop-to-ebp
17647 c3/return
17648
17649 translate-mu-copy-object-stmt:
17650
17651 55/push-ebp
17652 89/<- %ebp 4/r32/esp
17653
17654 50/push-eax
17655
17656 (emit-indent *(ebp+8) *Curr-block-depth)
17657 (write-buffered *(ebp+8) "(copy-bytes")
17658
17659 8b/-> *(ebp+0xc) 0/r32/eax
17660
17661 (lookup *(eax+0xc) *(eax+0x10))
17662 (emit-subx-call-operand *(ebp+8) %eax)
17663 (lookup *(eax+8) *(eax+0xc))
17664 (emit-subx-call-operand *(ebp+8) %eax)
17665 (write-buffered *(ebp+8) Space)
17666 (addr-payload-size %eax *(ebp+0x10) *(ebp+0x14))
17667 (write-int32-hex-buffered *(ebp+8) %eax)
17668 (write-buffered *(ebp+8) ")\n")
17669 $translate-mu-copy-object-stmt:end:
17670
17671 58/pop-to-eax
17672
17673 89/<- %esp 5/r32/ebp
17674 5d/pop-to-ebp
17675 c3/return
17676
17677 translate-mu-allocate-stmt:
17678
17679 55/push-ebp
17680 89/<- %ebp 4/r32/esp
17681
17682 50/push-eax
17683 56/push-esi
17684 57/push-edi
17685
17686 8b/-> *(ebp+0xc) 6/r32/esi
17687
17688 (lookup *(esi+0xc) *(esi+0x10))
17689 89/<- %edi 0/r32/eax
17690
17691 (emit-indent *(ebp+8) *Curr-block-depth)
17692 (write-buffered *(ebp+8) "(allocate Heap ")
17693 (addr-handle-payload-size %edi *(ebp+0x10) *(ebp+0x14))
17694 (write-int32-hex-buffered *(ebp+8) %eax)
17695 (emit-subx-call-operand *(ebp+8) %edi)
17696 (write-buffered *(ebp+8) ")\n")
17697 $translate-mu-allocate-stmt:end:
17698
17699 5f/pop-to-edi
17700 5e/pop-to-esi
17701 58/pop-to-eax
17702
17703 89/<- %esp 5/r32/ebp
17704 5d/pop-to-ebp
17705 c3/return
17706
17707 addr-handle-payload-size:
17708
17709 55/push-ebp
17710 89/<- %ebp 4/r32/esp
17711
17712 8b/-> *(ebp+8) 0/r32/eax
17713 (lookup *eax *(eax+4))
17714 (lookup *(eax+8) *(eax+0xc))
17715
17716
17717
17718
17719 $addr-handle-payload-size:skip-addr:
17720 (lookup *(eax+0xc) *(eax+0x10))
17721
17722
17723
17724
17725 $addr-handle-payload-size:skip-handle:
17726 (lookup *(eax+0xc) *(eax+0x10))
17727
17728
17729 81 7/subop/compare *eax 0/imm32/false
17730 {
17731 75/jump-if-!= break/disp8
17732 (lookup *(eax+4) *(eax+8))
17733 }
17734
17735
17736 (size-of-type-id *(eax+4))
17737 $addr-handle-payload-size:end:
17738
17739 89/<- %esp 5/r32/ebp
17740 5d/pop-to-ebp
17741 c3/return
17742
17743 addr-payload-size:
17744
17745 55/push-ebp
17746 89/<- %ebp 4/r32/esp
17747
17748 8b/-> *(ebp+8) 0/r32/eax
17749 (lookup *eax *(eax+4))
17750 (lookup *(eax+8) *(eax+0xc))
17751
17752
17753
17754
17755 $addr-payload-size:skip-addr:
17756 (lookup *(eax+0xc) *(eax+0x10))
17757
17758
17759 81 7/subop/compare *eax 0/imm32/false
17760 {
17761 75/jump-if-!= break/disp8
17762 (lookup *(eax+4) *(eax+8))
17763 }
17764
17765
17766 (size-of-type-id *(eax+4))
17767 $addr-payload-size:end:
17768
17769 89/<- %esp 5/r32/ebp
17770 5d/pop-to-ebp
17771 c3/return
17772
17773 translate-mu-populate-stmt:
17774
17775 55/push-ebp
17776 89/<- %ebp 4/r32/esp
17777
17778 50/push-eax
17779 51/push-ecx
17780 56/push-esi
17781 57/push-edi
17782
17783 8b/-> *(ebp+0xc) 6/r32/esi
17784
17785 (lookup *(esi+0xc) *(esi+0x10))
17786 89/<- %edi 0/r32/eax
17787
17788 (lookup *(edi+8) *(edi+0xc))
17789 89/<- %ecx 0/r32/eax
17790
17791 (emit-indent *(ebp+8) *Curr-block-depth)
17792 (write-buffered *(ebp+8) "(allocate-array2 Heap ")
17793 (addr-handle-array-payload-size %edi *(ebp+0x10) *(ebp+0x14))
17794 (write-int32-hex-buffered *(ebp+8) %eax)
17795 (emit-subx-call-operand *(ebp+8) %ecx)
17796 (emit-subx-call-operand *(ebp+8) %edi)
17797 (write-buffered *(ebp+8) ")\n")
17798 $translate-mu-populate-stmt:end:
17799
17800 5f/pop-to-edi
17801 5e/pop-to-esi
17802 59/pop-to-ecx
17803 58/pop-to-eax
17804
17805 89/<- %esp 5/r32/ebp
17806 5d/pop-to-ebp
17807 c3/return
17808
17809 translate-mu-populate-stream-stmt:
17810
17811 55/push-ebp
17812 89/<- %ebp 4/r32/esp
17813
17814 50/push-eax
17815 51/push-ecx
17816 56/push-esi
17817 57/push-edi
17818
17819 8b/-> *(ebp+0xc) 6/r32/esi
17820
17821 (lookup *(esi+0xc) *(esi+0x10))
17822 89/<- %edi 0/r32/eax
17823
17824 (lookup *(edi+8) *(edi+0xc))
17825 89/<- %ecx 0/r32/eax
17826
17827 (emit-indent *(ebp+8) *Curr-block-depth)
17828 (write-buffered *(ebp+8) "(new-stream Heap ")
17829 (addr-handle-stream-payload-size %edi *(ebp+0x10) *(ebp+0x14))
17830 (write-int32-hex-buffered *(ebp+8) %eax)
17831 (emit-subx-call-operand *(ebp+8) %ecx)
17832 (emit-subx-call-operand *(ebp+8) %edi)
17833 (write-buffered *(ebp+8) ")\n")
17834 $translate-mu-populate-stream-stmt:end:
17835
17836 5f/pop-to-edi
17837 5e/pop-to-esi
17838 59/pop-to-ecx
17839 58/pop-to-eax
17840
17841 89/<- %esp 5/r32/ebp
17842 5d/pop-to-ebp
17843 c3/return
17844
17845 translate-mu-read-from-stream-stmt:
17846
17847 55/push-ebp
17848 89/<- %ebp 4/r32/esp
17849
17850 50/push-eax
17851 51/push-ecx
17852 56/push-esi
17853 57/push-edi
17854
17855 8b/-> *(ebp+0xc) 6/r32/esi
17856
17857 (lookup *(esi+0xc) *(esi+0x10))
17858 89/<- %ecx 0/r32/eax
17859
17860 (lookup *(ecx+8) *(ecx+0xc))
17861 89/<- %edi 0/r32/eax
17862
17863 (emit-indent *(ebp+8) *Curr-block-depth)
17864 (write-buffered *(ebp+8) "(read-from-stream")
17865 (emit-subx-call-operand *(ebp+8) %ecx)
17866 (emit-subx-call-operand *(ebp+8) %edi)
17867 (write-buffered *(ebp+8) Space)
17868 (addr-payload-size %edi *(ebp+0x10) *(ebp+0x14))
17869 (write-int32-hex-buffered *(ebp+8) %eax)
17870 (write-buffered *(ebp+8) ")\n")
17871 $translate-mu-read-from-stream-stmt:end:
17872
17873 5f/pop-to-edi
17874 5e/pop-to-esi
17875 59/pop-to-ecx
17876 58/pop-to-eax
17877
17878 89/<- %esp 5/r32/ebp
17879 5d/pop-to-ebp
17880 c3/return
17881
17882 translate-mu-write-to-stream-stmt:
17883
17884 55/push-ebp
17885 89/<- %ebp 4/r32/esp
17886
17887 50/push-eax
17888 51/push-ecx
17889 56/push-esi
17890 57/push-edi
17891
17892 8b/-> *(ebp+0xc) 6/r32/esi
17893
17894 (lookup *(esi+0xc) *(esi+0x10))
17895 89/<- %ecx 0/r32/eax
17896
17897 (lookup *(ecx+8) *(ecx+0xc))
17898 89/<- %edi 0/r32/eax
17899
17900 (emit-indent *(ebp+8) *Curr-block-depth)
17901 (write-buffered *(ebp+8) "(write-to-stream")
17902 (emit-subx-call-operand *(ebp+8) %ecx)
17903 (flush *(ebp+8))
17904 (emit-subx-call-operand *(ebp+8) %edi)
17905 (flush *(ebp+8))
17906 (write-buffered *(ebp+8) Space)
17907 (flush *(ebp+8))
17908 (addr-payload-size %edi *(ebp+0x10) *(ebp+0x14))
17909 (write-int32-hex-buffered *(ebp+8) %eax)
17910 (write-buffered *(ebp+8) ")\n")
17911 $translate-mu-write-to-stream-stmt:end:
17912
17913 5f/pop-to-edi
17914 5e/pop-to-esi
17915 59/pop-to-ecx
17916 58/pop-to-eax
17917
17918 89/<- %esp 5/r32/ebp
17919 5d/pop-to-ebp
17920 c3/return
17921
17922 addr-handle-array-payload-size:
17923
17924 55/push-ebp
17925 89/<- %ebp 4/r32/esp
17926
17927 8b/-> *(ebp+8) 0/r32/eax
17928 (lookup *eax *(eax+4))
17929 (lookup *(eax+8) *(eax+0xc))
17930
17931
17932
17933
17934 $addr-handle-array-payload-size:skip-addr:
17935 (lookup *(eax+0xc) *(eax+0x10))
17936
17937
17938
17939
17940 $addr-handle-array-payload-size:skip-handle:
17941 (lookup *(eax+0xc) *(eax+0x10))
17942
17943
17944
17945
17946 $addr-handle-array-payload-size:skip-array:
17947 (lookup *(eax+0xc) *(eax+0x10))
17948
17949
17950 81 7/subop/compare *eax 0/imm32/false
17951 {
17952 75/jump-if-!= break/disp8
17953 (lookup *(eax+4) *(eax+8))
17954 }
17955 $addr-handle-array-payload-size:compute-size:
17956
17957
17958 (size-of-type-id-as-array-element *(eax+4))
17959 $addr-handle-array-payload-size:end:
17960
17961 89/<- %esp 5/r32/ebp
17962 5d/pop-to-ebp
17963 c3/return
17964
17965 addr-handle-stream-payload-size:
17966
17967 55/push-ebp
17968 89/<- %ebp 4/r32/esp
17969
17970 8b/-> *(ebp+8) 0/r32/eax
17971 (lookup *eax *(eax+4))
17972 (lookup *(eax+8) *(eax+0xc))
17973
17974
17975
17976
17977 $addr-handle-stream-payload-size:skip-addr:
17978 (lookup *(eax+0xc) *(eax+0x10))
17979
17980
17981
17982
17983 $addr-handle-stream-payload-size:skip-handle:
17984 (lookup *(eax+0xc) *(eax+0x10))
17985
17986
17987
17988
17989 $addr-handle-stream-payload-size:skip-stream:
17990 (lookup *(eax+0xc) *(eax+0x10))
17991
17992
17993 81 7/subop/compare *eax 0/imm32/false
17994 {
17995 75/jump-if-!= break/disp8
17996 (lookup *(eax+4) *(eax+8))
17997 }
17998 $addr-handle-stream-payload-size:compute-size:
17999
18000
18001 (size-of-type-id-as-array-element *(eax+4))
18002 $addr-handle-stream-payload-size:end:
18003
18004 89/<- %esp 5/r32/ebp
18005 5d/pop-to-ebp
18006 c3/return
18007
18008 power-of-2?:
18009
18010
18011 55/push-ebp
18012 89/<- %ebp 4/r32/esp
18013
18014 8b/-> *(ebp+8) 0/r32/eax
18015
18016 3d/compare-eax-with 0/imm32
18017 0f 8c/jump-if-< $power-of-2?:abort/disp32
18018
18019 48/decrement-eax
18020
18021 23/and-> *(ebp+8) 0/r32/eax
18022
18023 3d/compare-eax-and 0/imm32
18024 0f 94/set-byte-if-= %al
18025 81 4/subop/and %eax 0xff/imm32
18026 $power-of-2?:end:
18027
18028 89/<- %esp 5/r32/ebp
18029 5d/pop-to-ebp
18030 c3/return
18031
18032 $power-of-2?:abort:
18033 (write-buffered *(ebp+0xc) "power-of-2?: negative number\n")
18034 (flush *(ebp+0xc))
18035 (stop *(ebp+0x10) 1)
18036
18037
18038 num-shift-rights:
18039
18040
18041 55/push-ebp
18042 89/<- %ebp 4/r32/esp
18043
18044 51/push-ecx
18045
18046 8b/-> *(ebp+8) 1/r32/ecx
18047
18048 b8/copy-to-eax 0/imm32
18049 {
18050
18051 81 7/subop/compare %ecx 1/imm32
18052 7e/jump-if-<= break/disp8
18053 40/increment-eax
18054 c1/shift 5/subop/arithmetic-right %ecx 1/imm8
18055 eb/jump loop/disp8
18056 }
18057 $num-shift-rights:end:
18058
18059 59/pop-to-ecx
18060
18061 89/<- %esp 5/r32/ebp
18062 5d/pop-to-ebp
18063 c3/return
18064
18065 mu-get-offset:
18066
18067 55/push-ebp
18068 89/<- %ebp 4/r32/esp
18069
18070 8b/-> *(ebp+8) 0/r32/eax
18071 (lookup *(eax+0xc) *(eax+0x10))
18072 (lookup *(eax+8) *(eax+0xc))
18073
18074 (lookup *eax *(eax+4))
18075
18076
18077
18078
18079
18080
18081
18082
18083
18084
18085 8b/-> *(eax+0x14) 0/r32/eax
18086
18087
18088
18089
18090 $emit-get-offset:end:
18091
18092 89/<- %esp 5/r32/ebp
18093 5d/pop-to-ebp
18094 c3/return
18095
18096 emit-subx-block:
18097
18098 55/push-ebp
18099 89/<- %ebp 4/r32/esp
18100
18101 50/push-eax
18102 51/push-ecx
18103 56/push-esi
18104
18105 8b/-> *(ebp+0xc) 6/r32/esi
18106
18107 (lookup *(esi+0xc) *(esi+0x10))
18108 8b/-> *Curr-block-depth 1/r32/ecx
18109 89/<- *(eax+0x10) 1/r32/ecx
18110
18111 (lookup *(esi+4) *(esi+8))
18112
18113 {
18114 $emit-subx-block:check-empty:
18115 3d/compare-eax-and 0/imm32
18116 0f 84/jump-if-= break/disp32
18117 (emit-indent *(ebp+8) *Curr-block-depth)
18118 (write-buffered *(ebp+8) "{\n")
18119
18120 (lookup *(esi+0xc) *(esi+0x10))
18121 89/<- %ecx 0/r32/eax
18122
18123 (lookup *ecx *(ecx+4))
18124 (write-buffered *(ebp+8) %eax)
18125 (write-buffered *(ebp+8) ":loop:\n")
18126 ff 0/subop/increment *Curr-block-depth
18127 (push *(ebp+0x10) *(esi+0xc))
18128 (push *(ebp+0x10) *(esi+0x10))
18129 (push *(ebp+0x10) 0)
18130
18131 (lookup *(esi+4) *(esi+8))
18132 (emit-subx-stmt-list *(ebp+8) %eax *(ebp+0x10) *(ebp+0x14) *(ebp+0x18) *(ebp+0x1c))
18133 (pop *(ebp+0x10))
18134 (pop *(ebp+0x10))
18135 (pop *(ebp+0x10))
18136 ff 1/subop/decrement *Curr-block-depth
18137 (emit-indent *(ebp+8) *Curr-block-depth)
18138 (write-buffered *(ebp+8) "}\n")
18139 (lookup *ecx *(ecx+4))
18140 (write-buffered *(ebp+8) %eax)
18141 (write-buffered *(ebp+8) ":break:\n")
18142 }
18143 $emit-subx-block:end:
18144
18145 5e/pop-to-esi
18146 59/pop-to-ecx
18147 58/pop-to-eax
18148
18149 89/<- %esp 5/r32/ebp
18150 5d/pop-to-ebp
18151 c3/return
18152
18153
18154
18155
18156
18157
18158
18159
18160
18161
18162
18163
18164
18165
18166
18167
18168
18169
18170
18171
18172
18173
18174
18175
18176
18177
18178
18179
18180
18181
18182
18183
18184
18185
18186
18187
18188
18189
18190
18191
18192
18193
18194
18195
18196
18197
18198
18199
18200
18201
18202 == data
18203 Primitives:
18204
18205 _Primitive-increment-eax:
18206
18207 0x11/imm32/alloc-id:fake
18208 _string-increment/imm32/name
18209 0/imm32/no-inouts
18210 0/imm32/no-inouts
18211 0x11/imm32/alloc-id:fake
18212 Single-int-var-in-eax/imm32/outputs
18213 0x11/imm32/alloc-id:fake
18214 _string_40_increment_eax/imm32/subx-name
18215 0/imm32/no-rm32
18216 0/imm32/no-r32
18217 0/imm32/no-imm32
18218 0/imm32/no-imm8
18219 0/imm32/no-disp32
18220 0/imm32/no-xm32
18221 0/imm32/no-x32
18222 0x11/imm32/alloc-id:fake
18223 _Primitive-increment-ecx/imm32/next
18224 _Primitive-increment-ecx:
18225 0x11/imm32/alloc-id:fake:payload
18226
18227 0x11/imm32/alloc-id:fake
18228 _string-increment/imm32/name
18229 0/imm32/no-inouts
18230 0/imm32/no-inouts
18231 0x11/imm32/alloc-id:fake
18232 Single-int-var-in-ecx/imm32/outputs
18233 0x11/imm32/alloc-id:fake
18234 _string_41_increment_ecx/imm32/subx-name
18235 0/imm32/no-rm32
18236 0/imm32/no-r32
18237 0/imm32/no-imm32
18238 0/imm32/no-imm8
18239 0/imm32/no-disp32
18240 0/imm32/no-xm32
18241 0/imm32/no-x32
18242 0x11/imm32/alloc-id:fake
18243 _Primitive-increment-edx/imm32/next
18244 _Primitive-increment-edx:
18245 0x11/imm32/alloc-id:fake:payload
18246
18247 0x11/imm32/alloc-id:fake
18248 _string-increment/imm32/name
18249 0/imm32/no-inouts
18250 0/imm32/no-inouts
18251 0x11/imm32/alloc-id:fake
18252 Single-int-var-in-edx/imm32/outputs
18253 0x11/imm32/alloc-id:fake
18254 _string_42_increment_edx/imm32/subx-name
18255 0/imm32/no-rm32
18256 0/imm32/no-r32
18257 0/imm32/no-imm32
18258 0/imm32/no-imm8
18259 0/imm32/no-disp32
18260 0/imm32/no-xm32
18261 0/imm32/no-x32
18262 0x11/imm32/alloc-id:fake
18263 _Primitive-increment-ebx/imm32/next
18264 _Primitive-increment-ebx:
18265 0x11/imm32/alloc-id:fake:payload
18266
18267 0x11/imm32/alloc-id:fake
18268 _string-increment/imm32/name
18269 0/imm32/no-inouts
18270 0/imm32/no-inouts
18271 0x11/imm32/alloc-id:fake
18272 Single-int-var-in-ebx/imm32/outputs
18273 0x11/imm32/alloc-id:fake
18274 _string_43_increment_ebx/imm32/subx-name
18275 0/imm32/no-rm32
18276 0/imm32/no-r32
18277 0/imm32/no-imm32
18278 0/imm32/no-imm8
18279 0/imm32/no-disp32
18280 0/imm32/no-xm32
18281 0/imm32/no-x32
18282 0x11/imm32/alloc-id:fake
18283 _Primitive-increment-esi/imm32/next
18284 _Primitive-increment-esi:
18285 0x11/imm32/alloc-id:fake:payload
18286
18287 0x11/imm32/alloc-id:fake
18288 _string-increment/imm32/name
18289 0/imm32/no-inouts
18290 0/imm32/no-inouts
18291 0x11/imm32/alloc-id:fake
18292 Single-int-var-in-esi/imm32/outputs
18293 0x11/imm32/alloc-id:fake
18294 _string_46_increment_esi/imm32/subx-name
18295 0/imm32/no-rm32
18296 0/imm32/no-r32
18297 0/imm32/no-imm32
18298 0/imm32/no-imm8
18299 0/imm32/no-disp32
18300 0/imm32/no-xm32
18301 0/imm32/no-x32
18302 0x11/imm32/alloc-id:fake
18303 _Primitive-increment-edi/imm32/next
18304 _Primitive-increment-edi:
18305 0x11/imm32/alloc-id:fake:payload
18306
18307 0x11/imm32/alloc-id:fake
18308 _string-increment/imm32/name
18309 0/imm32/no-inouts
18310 0/imm32/no-inouts
18311 0x11/imm32/alloc-id:fake
18312 Single-int-var-in-edi/imm32/outputs
18313 0x11/imm32/alloc-id:fake
18314 _string_47_increment_edi/imm32/subx-name
18315 0/imm32/no-rm32
18316 0/imm32/no-r32
18317 0/imm32/no-imm32
18318 0/imm32/no-imm8
18319 0/imm32/no-disp32
18320 0/imm32/no-xm32
18321 0/imm32/no-x32
18322 0x11/imm32/alloc-id:fake
18323 _Primitive-decrement-eax/imm32/next
18324 _Primitive-decrement-eax:
18325 0x11/imm32/alloc-id:fake:payload
18326
18327 0x11/imm32/alloc-id:fake
18328 _string-decrement/imm32/name
18329 0/imm32/no-inouts
18330 0/imm32/no-inouts
18331 0x11/imm32/alloc-id:fake
18332 Single-int-var-in-eax/imm32/outputs
18333 0x11/imm32/alloc-id:fake
18334 _string_48_decrement_eax/imm32/subx-name
18335 0/imm32/no-rm32
18336 0/imm32/no-r32
18337 0/imm32/no-imm32
18338 0/imm32/no-imm8
18339 0/imm32/no-disp32
18340 0/imm32/no-xm32
18341 0/imm32/no-x32
18342 0x11/imm32/alloc-id:fake
18343 _Primitive-decrement-ecx/imm32/next
18344 _Primitive-decrement-ecx:
18345 0x11/imm32/alloc-id:fake:payload
18346
18347 0x11/imm32/alloc-id:fake
18348 _string-decrement/imm32/name
18349 0/imm32/no-inouts
18350 0/imm32/no-inouts
18351 0x11/imm32/alloc-id:fake
18352 Single-int-var-in-ecx/imm32/outputs
18353 0x11/imm32/alloc-id:fake
18354 _string_49_decrement_ecx/imm32/subx-name
18355 0/imm32/no-rm32
18356 0/imm32/no-r32
18357 0/imm32/no-imm32
18358 0/imm32/no-imm8
18359 0/imm32/no-disp32
18360 0/imm32/no-xm32
18361 0/imm32/no-x32
18362 0x11/imm32/alloc-id:fake
18363 _Primitive-decrement-edx/imm32/next
18364 _Primitive-decrement-edx:
18365 0x11/imm32/alloc-id:fake:payload
18366
18367 0x11/imm32/alloc-id:fake
18368 _string-decrement/imm32/name
18369 0/imm32/no-inouts
18370 0/imm32/no-inouts
18371 0x11/imm32/alloc-id:fake
18372 Single-int-var-in-edx/imm32/outputs
18373 0x11/imm32/alloc-id:fake
18374 _string_4a_decrement_edx/imm32/subx-name
18375 0/imm32/no-rm32
18376 0/imm32/no-r32
18377 0/imm32/no-imm32
18378 0/imm32/no-imm8
18379 0/imm32/no-disp32
18380 0/imm32/no-xm32
18381 0/imm32/no-x32
18382 0x11/imm32/alloc-id:fake
18383 _Primitive-decrement-ebx/imm32/next
18384 _Primitive-decrement-ebx:
18385 0x11/imm32/alloc-id:fake:payload
18386
18387 0x11/imm32/alloc-id:fake
18388 _string-decrement/imm32/name
18389 0/imm32/no-inouts
18390 0/imm32/no-inouts
18391 0x11/imm32/alloc-id:fake
18392 Single-int-var-in-ebx/imm32/outputs
18393 0x11/imm32/alloc-id:fake
18394 _string_4b_decrement_ebx/imm32/subx-name
18395 0/imm32/no-rm32
18396 0/imm32/no-r32
18397 0/imm32/no-imm32
18398 0/imm32/no-imm8
18399 0/imm32/no-disp32
18400 0/imm32/no-xm32
18401 0/imm32/no-x32
18402 0x11/imm32/alloc-id:fake
18403 _Primitive-decrement-esi/imm32/next
18404 _Primitive-decrement-esi:
18405 0x11/imm32/alloc-id:fake:payload
18406
18407 0x11/imm32/alloc-id:fake
18408 _string-decrement/imm32/name
18409 0/imm32/no-inouts
18410 0/imm32/no-inouts
18411 0x11/imm32/alloc-id:fake
18412 Single-int-var-in-esi/imm32/outputs
18413 0x11/imm32/alloc-id:fake
18414 _string_4e_decrement_esi/imm32/subx-name
18415 0/imm32/no-rm32
18416 0/imm32/no-r32
18417 0/imm32/no-imm32
18418 0/imm32/no-imm8
18419 0/imm32/no-disp32
18420 0/imm32/no-xm32
18421 0/imm32/no-x32
18422 0x11/imm32/alloc-id:fake
18423 _Primitive-decrement-edi/imm32/next
18424 _Primitive-decrement-edi:
18425 0x11/imm32/alloc-id:fake:payload
18426
18427 0x11/imm32/alloc-id:fake
18428 _string-decrement/imm32/name
18429 0/imm32/no-inouts
18430 0/imm32/no-inouts
18431 0x11/imm32/alloc-id:fake
18432 Single-int-var-in-edi/imm32/outputs
18433 0x11/imm32/alloc-id:fake
18434 _string_4f_decrement_edi/imm32/subx-name
18435 0/imm32/no-rm32
18436 0/imm32/no-r32
18437 0/imm32/no-imm32
18438 0/imm32/no-imm8
18439 0/imm32/no-disp32
18440 0/imm32/no-xm32
18441 0/imm32/no-x32
18442 0x11/imm32/alloc-id:fake
18443 _Primitive-increment-mem/imm32/next
18444 _Primitive-increment-mem:
18445 0x11/imm32/alloc-id:fake:payload
18446
18447 0x11/imm32/alloc-id:fake
18448 _string-increment/imm32/name
18449 0x11/imm32/alloc-id:fake
18450 Single-int-var-in-mem/imm32/inouts
18451 0/imm32/no-outputs
18452 0/imm32/no-outputs
18453 0x11/imm32/alloc-id:fake
18454 _string_ff_subop_increment/imm32/subx-name
18455 1/imm32/rm32-is-first-inout
18456 0/imm32/no-r32
18457 0/imm32/no-imm32
18458 0/imm32/no-imm8
18459 0/imm32/no-disp32
18460 0/imm32/no-xm32
18461 0/imm32/no-x32
18462 0x11/imm32/alloc-id:fake
18463 _Primitive-increment-reg/imm32/next
18464 _Primitive-increment-reg:
18465 0x11/imm32/alloc-id:fake:payload
18466
18467 0x11/imm32/alloc-id:fake
18468 _string-increment/imm32/name
18469 0/imm32/no-inouts
18470 0/imm32/no-inouts
18471 0x11/imm32/alloc-id:fake
18472 Single-int-var-in-some-register/imm32/outputs
18473 0x11/imm32/alloc-id:fake
18474 _string_ff_subop_increment/imm32/subx-name
18475 3/imm32/rm32-is-first-output
18476 0/imm32/no-r32
18477 0/imm32/no-imm32
18478 0/imm32/no-imm8
18479 0/imm32/no-disp32
18480 0/imm32/no-xm32
18481 0/imm32/no-x32
18482 0x11/imm32/alloc-id:fake
18483 _Primitive-decrement-mem/imm32/next
18484 _Primitive-decrement-mem:
18485 0x11/imm32/alloc-id:fake:payload
18486
18487 0x11/imm32/alloc-id:fake
18488 _string-decrement/imm32/name
18489 0x11/imm32/alloc-id:fake
18490 Single-int-var-in-mem/imm32/inouts
18491 0/imm32/no-outputs
18492 0/imm32/no-outputs
18493 0x11/imm32/alloc-id:fake
18494 _string_ff_subop_decrement/imm32/subx-name
18495 1/imm32/rm32-is-first-inout
18496 0/imm32/no-r32
18497 0/imm32/no-imm32
18498 0/imm32/no-imm8
18499 0/imm32/no-disp32
18500 0/imm32/no-xm32
18501 0/imm32/no-x32
18502 0x11/imm32/alloc-id:fake
18503 _Primitive-decrement-reg/imm32/next
18504 _Primitive-decrement-reg:
18505 0x11/imm32/alloc-id:fake:payload
18506
18507 0x11/imm32/alloc-id:fake
18508 _string-decrement/imm32/name
18509 0/imm32/no-inouts
18510 0/imm32/no-inouts
18511 0x11/imm32/alloc-id:fake
18512 Single-int-var-in-some-register/imm32/outputs
18513 0x11/imm32/alloc-id:fake
18514 _string_ff_subop_decrement/imm32/subx-name
18515 3/imm32/rm32-is-first-output
18516 0/imm32/no-r32
18517 0/imm32/no-imm32
18518 0/imm32/no-imm8
18519 0/imm32/no-disp32
18520 0/imm32/no-xm32
18521 0/imm32/no-x32
18522 0x11/imm32/alloc-id:fake
18523 _Primitive-add-to-eax/imm32/next
18524
18525 _Primitive-add-to-eax:
18526 0x11/imm32/alloc-id:fake:payload
18527
18528 0x11/imm32/alloc-id:fake
18529 _string-add/imm32/name
18530 0x11/imm32/alloc-id:fake
18531 Single-lit-var/imm32/inouts
18532 0x11/imm32/alloc-id:fake
18533 Single-int-var-in-eax/imm32/outputs
18534 0x11/imm32/alloc-id:fake
18535 _string_05_add_to_eax/imm32/subx-name
18536 0/imm32/no-rm32
18537 0/imm32/no-r32
18538 1/imm32/imm32-is-first-inout
18539 0/imm32/no-imm8
18540 0/imm32/no-disp32
18541 0/imm32/no-xm32
18542 0/imm32/no-x32
18543 0x11/imm32/alloc-id:fake
18544 _Primitive-add-reg-to-reg/imm32/next
18545 _Primitive-add-reg-to-reg:
18546 0x11/imm32/alloc-id:fake:payload
18547
18548 0x11/imm32/alloc-id:fake
18549 _string-add/imm32/name
18550 0x11/imm32/alloc-id:fake
18551 Single-int-var-in-some-register/imm32/inouts
18552 0x11/imm32/alloc-id:fake
18553 Single-int-var-in-some-register/imm32/outputs
18554 0x11/imm32/alloc-id:fake
18555 _string_01_add_to/imm32/subx-name
18556 3/imm32/rm32-is-first-output
18557 1/imm32/r32-is-first-inout
18558 0/imm32/no-imm32
18559 0/imm32/no-imm8
18560 0/imm32/no-disp32
18561 0/imm32/no-xm32
18562 0/imm32/no-x32
18563 0x11/imm32/alloc-id:fake
18564 _Primitive-add-reg-to-mem/imm32/next
18565 _Primitive-add-reg-to-mem:
18566 0x11/imm32/alloc-id:fake:payload
18567
18568 0x11/imm32/alloc-id:fake
18569 _string-add-to/imm32/name
18570 0x11/imm32/alloc-id:fake
18571 Two-args-int-stack-int-reg/imm32/inouts
18572 0/imm32/no-outputs
18573 0/imm32/no-outputs
18574 0x11/imm32/alloc-id:fake
18575 _string_01_add_to/imm32/subx-name
18576 1/imm32/rm32-is-first-inout
18577 2/imm32/r32-is-second-inout
18578 0/imm32/no-imm32
18579 0/imm32/no-imm8
18580 0/imm32/no-disp32
18581 0/imm32/no-xm32
18582 0/imm32/no-x32
18583 0x11/imm32/alloc-id:fake
18584 _Primitive-add-mem-to-reg/imm32/next
18585 _Primitive-add-mem-to-reg:
18586 0x11/imm32/alloc-id:fake:payload
18587
18588 0x11/imm32/alloc-id:fake
18589 _string-add/imm32/name
18590 0x11/imm32/alloc-id:fake
18591 Single-int-var-in-mem/imm32/inouts
18592 0x11/imm32/alloc-id:fake
18593 Single-int-var-in-some-register/imm32/outputs
18594 0x11/imm32/alloc-id:fake
18595 _string_03_add/imm32/subx-name
18596 1/imm32/rm32-is-first-inout
18597 3/imm32/r32-is-first-output
18598 0/imm32/no-imm32
18599 0/imm32/no-imm8
18600 0/imm32/no-disp32
18601 0/imm32/no-xm32
18602 0/imm32/no-x32
18603 0x11/imm32/alloc-id:fake
18604 _Primitive-add-lit-to-reg/imm32/next
18605 _Primitive-add-lit-to-reg:
18606 0x11/imm32/alloc-id:fake:payload
18607
18608 0x11/imm32/alloc-id:fake
18609 _string-add/imm32/name
18610 0x11/imm32/alloc-id:fake
18611 Single-lit-var/imm32/inouts
18612 0x11/imm32/alloc-id:fake
18613 Single-int-var-in-some-register/imm32/outputs
18614 0x11/imm32/alloc-id:fake
18615 _string_81_subop_add/imm32/subx-name
18616 3/imm32/rm32-is-first-output
18617 0/imm32/no-r32
18618 1/imm32/imm32-is-first-inout
18619 0/imm32/no-imm8
18620 0/imm32/no-disp32
18621 0/imm32/no-xm32
18622 0/imm32/no-x32
18623 0x11/imm32/alloc-id:fake
18624 _Primitive-add-lit-to-mem/imm32/next
18625 _Primitive-add-lit-to-mem:
18626 0x11/imm32/alloc-id:fake:payload
18627
18628 0x11/imm32/alloc-id:fake
18629 _string-add-to/imm32/name
18630 0x11/imm32/alloc-id:fake
18631 Int-var-and-literal/imm32/inouts
18632 0/imm32/no-outputs
18633 0/imm32/no-outputs
18634 0x11/imm32/alloc-id:fake
18635 _string_81_subop_add/imm32/subx-name
18636 1/imm32/rm32-is-first-inout
18637 0/imm32/no-r32
18638 2/imm32/imm32-is-second-inout
18639 0/imm32/no-imm8
18640 0/imm32/no-disp32
18641 0/imm32/no-xm32
18642 0/imm32/no-x32
18643 0x11/imm32/alloc-id:fake
18644 _Primitive-subtract-from-eax/imm32/next
18645
18646 _Primitive-subtract-from-eax:
18647 0x11/imm32/alloc-id:fake:payload
18648
18649 0x11/imm32/alloc-id:fake
18650 _string-subtract/imm32/name
18651 0x11/imm32/alloc-id:fake
18652 Single-lit-var/imm32/inouts
18653 0x11/imm32/alloc-id:fake
18654 Single-int-var-in-eax/imm32/outputs
18655 0x11/imm32/alloc-id:fake
18656 _string_2d_subtract_from_eax/imm32/subx-name
18657 0/imm32/no-rm32
18658 0/imm32/no-r32
18659 1/imm32/imm32-is-first-inout
18660 0/imm32/no-imm8
18661 0/imm32/no-disp32
18662 0/imm32/no-xm32
18663 0/imm32/no-x32
18664 0x11/imm32/alloc-id:fake
18665 _Primitive-subtract-reg-from-reg/imm32/next
18666 _Primitive-subtract-reg-from-reg:
18667 0x11/imm32/alloc-id:fake:payload
18668
18669 0x11/imm32/alloc-id:fake
18670 _string-subtract/imm32/name
18671 0x11/imm32/alloc-id:fake
18672 Single-int-var-in-some-register/imm32/inouts
18673 0x11/imm32/alloc-id:fake
18674 Single-int-var-in-some-register/imm32/outputs
18675 0x11/imm32/alloc-id:fake
18676 _string_29_subtract_from/imm32/subx-name
18677 3/imm32/rm32-is-first-output
18678 1/imm32/r32-is-first-inout
18679 0/imm32/no-imm32
18680 0/imm32/no-imm8
18681 0/imm32/no-disp32
18682 0/imm32/no-xm32
18683 0/imm32/no-x32
18684 0x11/imm32/alloc-id:fake
18685 _Primitive-subtract-reg-from-mem/imm32/next
18686 _Primitive-subtract-reg-from-mem:
18687 0x11/imm32/alloc-id:fake:payload
18688
18689 0x11/imm32/alloc-id:fake
18690 _string-subtract-from/imm32/name
18691 0x11/imm32/alloc-id:fake
18692 Two-args-int-stack-int-reg/imm32/inouts
18693 0/imm32/no-outputs
18694 0/imm32/no-outputs
18695 0x11/imm32/alloc-id:fake
18696 _string_29_subtract_from/imm32/subx-name
18697 1/imm32/rm32-is-first-inout
18698 2/imm32/r32-is-second-inout
18699 0/imm32/no-imm32
18700 0/imm32/no-imm8
18701 0/imm32/no-disp32
18702 0/imm32/no-xm32
18703 0/imm32/no-x32
18704 0x11/imm32/alloc-id:fake
18705 _Primitive-subtract-mem-from-reg/imm32/next
18706 _Primitive-subtract-mem-from-reg:
18707 0x11/imm32/alloc-id:fake:payload
18708
18709 0x11/imm32/alloc-id:fake
18710 _string-subtract/imm32/name
18711 0x11/imm32/alloc-id:fake
18712 Single-int-var-in-mem/imm32/inouts
18713 0x11/imm32/alloc-id:fake
18714 Single-int-var-in-some-register/imm32/outputs
18715 0x11/imm32/alloc-id:fake
18716 _string_2b_subtract/imm32/subx-name
18717 1/imm32/rm32-is-first-inout
18718 3/imm32/r32-is-first-output
18719 0/imm32/no-imm32
18720 0/imm32/no-imm8
18721 0/imm32/no-disp32
18722 0/imm32/no-xm32
18723 0/imm32/no-x32
18724 0x11/imm32/alloc-id:fake
18725 _Primitive-subtract-lit-from-reg/imm32/next
18726 _Primitive-subtract-lit-from-reg:
18727 0x11/imm32/alloc-id:fake:payload
18728
18729 0x11/imm32/alloc-id:fake
18730 _string-subtract/imm32/name
18731 0x11/imm32/alloc-id:fake
18732 Single-lit-var/imm32/inouts
18733 0x11/imm32/alloc-id:fake
18734 Single-int-var-in-some-register/imm32/outputs
18735 0x11/imm32/alloc-id:fake
18736 _string_81_subop_subtract/imm32/subx-name
18737 3/imm32/rm32-is-first-output
18738 0/imm32/no-r32
18739 1/imm32/imm32-is-first-inout
18740 0/imm32/no-imm8
18741 0/imm32/no-disp32
18742 0/imm32/no-xm32
18743 0/imm32/no-x32
18744 0x11/imm32/alloc-id:fake
18745 _Primitive-subtract-lit-from-mem/imm32/next
18746 _Primitive-subtract-lit-from-mem:
18747 0x11/imm32/alloc-id:fake:payload
18748
18749 0x11/imm32/alloc-id:fake
18750 _string-subtract-from/imm32/name
18751 0x11/imm32/alloc-id:fake
18752 Int-var-and-literal/imm32/inouts
18753 0/imm32/no-outputs
18754 0/imm32/no-outputs
18755 0x11/imm32/alloc-id:fake
18756 _string_81_subop_subtract/imm32/subx-name
18757 1/imm32/rm32-is-first-inout
18758 0/imm32/no-r32
18759 2/imm32/imm32-is-second-inout
18760 0/imm32/no-imm8
18761 0/imm32/no-disp32
18762 0/imm32/no-xm32
18763 0/imm32/no-x32
18764 0x11/imm32/alloc-id:fake
18765 _Primitive-and-with-eax/imm32/next
18766
18767 _Primitive-and-with-eax:
18768 0x11/imm32/alloc-id:fake:payload
18769
18770 0x11/imm32/alloc-id:fake
18771 _string-and/imm32/name
18772 0x11/imm32/alloc-id:fake
18773 Single-lit-var/imm32/inouts
18774 0x11/imm32/alloc-id:fake
18775 Single-int-var-in-eax/imm32/outputs
18776 0x11/imm32/alloc-id:fake
18777 _string_25_and_with_eax/imm32/subx-name
18778 0/imm32/no-rm32
18779 0/imm32/no-r32
18780 1/imm32/imm32-is-first-inout
18781 0/imm32/no-imm8
18782 0/imm32/no-disp32
18783 0/imm32/no-xm32
18784 0/imm32/no-x32
18785 0x11/imm32/alloc-id:fake
18786 _Primitive-and-reg-with-reg/imm32/next
18787 _Primitive-and-reg-with-reg:
18788 0x11/imm32/alloc-id:fake:payload
18789
18790 0x11/imm32/alloc-id:fake
18791 _string-and/imm32/name
18792 0x11/imm32/alloc-id:fake
18793 Single-int-var-in-some-register/imm32/inouts
18794 0x11/imm32/alloc-id:fake
18795 Single-int-var-in-some-register/imm32/outputs
18796 0x11/imm32/alloc-id:fake
18797 _string_21_and_with/imm32/subx-name
18798 3/imm32/rm32-is-first-output
18799 1/imm32/r32-is-first-inout
18800 0/imm32/no-imm32
18801 0/imm32/no-imm8
18802 0/imm32/no-disp32
18803 0/imm32/no-xm32
18804 0/imm32/no-x32
18805 0x11/imm32/alloc-id:fake
18806 _Primitive-and-reg-with-mem/imm32/next
18807 _Primitive-and-reg-with-mem:
18808 0x11/imm32/alloc-id:fake:payload
18809
18810 0x11/imm32/alloc-id:fake
18811 _string-and-with/imm32/name
18812 0x11/imm32/alloc-id:fake
18813 Two-args-int-stack-int-reg/imm32/inouts
18814 0/imm32/no-outputs
18815 0/imm32/no-outputs
18816 0x11/imm32/alloc-id:fake
18817 _string_21_and_with/imm32/subx-name
18818 1/imm32/rm32-is-first-inout
18819 2/imm32/r32-is-second-inout
18820 0/imm32/no-imm32
18821 0/imm32/no-imm8
18822 0/imm32/no-disp32
18823 0/imm32/no-xm32
18824 0/imm32/no-x32
18825 0x11/imm32/alloc-id:fake
18826 _Primitive-and-mem-with-reg/imm32/next
18827 _Primitive-and-mem-with-reg:
18828 0x11/imm32/alloc-id:fake:payload
18829
18830 0x11/imm32/alloc-id:fake
18831 _string-and/imm32/name
18832 0x11/imm32/alloc-id:fake
18833 Single-int-var-in-mem/imm32/inouts
18834 0x11/imm32/alloc-id:fake
18835 Single-int-var-in-some-register/imm32/outputs
18836 0x11/imm32/alloc-id:fake
18837 _string_23_and/imm32/subx-name
18838 1/imm32/rm32-is-first-inout
18839 3/imm32/r32-is-first-output
18840 0/imm32/no-imm32
18841 0/imm32/no-imm8
18842 0/imm32/no-disp32
18843 0/imm32/no-xm32
18844 0/imm32/no-x32
18845 0x11/imm32/alloc-id:fake
18846 _Primitive-and-lit-with-reg/imm32/next
18847 _Primitive-and-lit-with-reg:
18848 0x11/imm32/alloc-id:fake:payload
18849
18850 0x11/imm32/alloc-id:fake
18851 _string-and/imm32/name
18852 0x11/imm32/alloc-id:fake
18853 Single-lit-var/imm32/inouts
18854 0x11/imm32/alloc-id:fake
18855 Single-int-var-in-some-register/imm32/outputs
18856 0x11/imm32/alloc-id:fake
18857 _string_81_subop_and/imm32/subx-name
18858 3/imm32/rm32-is-first-output
18859 0/imm32/no-r32
18860 1/imm32/imm32-is-first-inout
18861 0/imm32/no-imm8
18862 0/imm32/no-disp32
18863 0/imm32/no-xm32
18864 0/imm32/no-x32
18865 0x11/imm32/alloc-id:fake
18866 _Primitive-and-lit-with-mem/imm32/next
18867 _Primitive-and-lit-with-mem:
18868 0x11/imm32/alloc-id:fake:payload
18869
18870 0x11/imm32/alloc-id:fake
18871 _string-and-with/imm32/name
18872 0x11/imm32/alloc-id:fake
18873 Int-var-and-literal/imm32/inouts
18874 0/imm32/no-outputs
18875 0/imm32/no-outputs
18876 0x11/imm32/alloc-id:fake
18877 _string_81_subop_and/imm32/subx-name
18878 1/imm32/rm32-is-first-inout
18879 0/imm32/no-r32
18880 2/imm32/imm32-is-second-inout
18881 0/imm32/no-imm8
18882 0/imm32/no-disp32
18883 0/imm32/no-xm32
18884 0/imm32/no-x32
18885 0x11/imm32/alloc-id:fake
18886 _Primitive-or-with-eax/imm32/next
18887
18888 _Primitive-or-with-eax:
18889 0x11/imm32/alloc-id:fake:payload
18890
18891 0x11/imm32/alloc-id:fake
18892 _string-or/imm32/name
18893 0x11/imm32/alloc-id:fake
18894 Single-lit-var/imm32/inouts
18895 0x11/imm32/alloc-id:fake
18896 Single-int-var-in-eax/imm32/outputs
18897 0x11/imm32/alloc-id:fake
18898 _string_0d_or_with_eax/imm32/subx-name
18899 0/imm32/no-rm32
18900 0/imm32/no-r32
18901 1/imm32/imm32-is-first-inout
18902 0/imm32/no-imm8
18903 0/imm32/no-disp32
18904 0/imm32/no-xm32
18905 0/imm32/no-x32
18906 0x11/imm32/alloc-id:fake
18907 _Primitive-or-reg-with-reg/imm32/next
18908 _Primitive-or-reg-with-reg:
18909 0x11/imm32/alloc-id:fake:payload
18910
18911 0x11/imm32/alloc-id:fake
18912 _string-or/imm32/name
18913 0x11/imm32/alloc-id:fake
18914 Single-int-var-in-some-register/imm32/inouts
18915 0x11/imm32/alloc-id:fake
18916 Single-int-var-in-some-register/imm32/outputs
18917 0x11/imm32/alloc-id:fake
18918 _string_09_or_with/imm32/subx-name
18919 3/imm32/rm32-is-first-output
18920 1/imm32/r32-is-first-inout
18921 0/imm32/no-imm32
18922 0/imm32/no-imm8
18923 0/imm32/no-disp32
18924 0/imm32/no-xm32
18925 0/imm32/no-x32
18926 0x11/imm32/alloc-id:fake
18927 _Primitive-or-reg-with-mem/imm32/next
18928 _Primitive-or-reg-with-mem:
18929 0x11/imm32/alloc-id:fake:payload
18930
18931 0x11/imm32/alloc-id:fake
18932 _string-or-with/imm32/name
18933 0x11/imm32/alloc-id:fake
18934 Two-args-int-stack-int-reg/imm32/inouts
18935 0/imm32/no-outputs
18936 0/imm32/no-outputs
18937 0x11/imm32/alloc-id:fake
18938 _string_09_or_with/imm32/subx-name
18939 1/imm32/rm32-is-first-inout
18940 2/imm32/r32-is-second-inout
18941 0/imm32/no-imm32
18942 0/imm32/no-imm8
18943 0/imm32/no-disp32
18944 0/imm32/no-xm32
18945 0/imm32/no-x32
18946 0x11/imm32/alloc-id:fake
18947 _Primitive-or-mem-with-reg/imm32/next
18948 _Primitive-or-mem-with-reg:
18949 0x11/imm32/alloc-id:fake:payload
18950
18951 0x11/imm32/alloc-id:fake
18952 _string-or/imm32/name
18953 0x11/imm32/alloc-id:fake
18954 Single-int-var-in-mem/imm32/inouts
18955 0x11/imm32/alloc-id:fake
18956 Single-int-var-in-some-register/imm32/outputs
18957 0x11/imm32/alloc-id:fake
18958 _string_0b_or/imm32/subx-name
18959 1/imm32/rm32-is-first-inout
18960 3/imm32/r32-is-first-output
18961 0/imm32/no-imm32
18962 0/imm32/no-imm8
18963 0/imm32/no-disp32
18964 0/imm32/no-xm32
18965 0/imm32/no-x32
18966 0x11/imm32/alloc-id:fake
18967 _Primitive-or-lit-with-reg/imm32/next
18968 _Primitive-or-lit-with-reg:
18969 0x11/imm32/alloc-id:fake:payload
18970
18971 0x11/imm32/alloc-id:fake
18972 _string-or/imm32/name
18973 0x11/imm32/alloc-id:fake
18974 Single-lit-var/imm32/inouts
18975 0x11/imm32/alloc-id:fake
18976 Single-int-var-in-some-register/imm32/outputs
18977 0x11/imm32/alloc-id:fake
18978 _string_81_subop_or/imm32/subx-name
18979 3/imm32/rm32-is-first-output
18980 0/imm32/no-r32
18981 1/imm32/imm32-is-first-inout
18982 0/imm32/no-imm8
18983 0/imm32/no-disp32
18984 0/imm32/no-xm32
18985 0/imm32/no-x32
18986 0x11/imm32/alloc-id:fake
18987 _Primitive-or-lit-with-mem/imm32/next
18988 _Primitive-or-lit-with-mem:
18989 0x11/imm32/alloc-id:fake:payload
18990
18991 0x11/imm32/alloc-id:fake
18992 _string-or-with/imm32/name
18993 0x11/imm32/alloc-id:fake
18994 Int-var-and-literal/imm32/inouts
18995 0/imm32/no-outputs
18996 0/imm32/no-outputs
18997 0x11/imm32/alloc-id:fake
18998 _string_81_subop_or/imm32/subx-name
18999 1/imm32/rm32-is-first-inout
19000 0/imm32/no-r32
19001 2/imm32/imm32-is-second-inout
19002 0/imm32/no-imm8
19003 0/imm32/no-disp32
19004 0/imm32/no-xm32
19005 0/imm32/no-x32
19006 0x11/imm32/alloc-id:fake
19007 _Primitive-xor-with-eax/imm32/next
19008
19009 _Primitive-xor-with-eax:
19010 0x11/imm32/alloc-id:fake:payload
19011
19012 0x11/imm32/alloc-id:fake
19013 _string-xor/imm32/name
19014 0x11/imm32/alloc-id:fake
19015 Single-lit-var/imm32/inouts
19016 0x11/imm32/alloc-id:fake
19017 Single-int-var-in-eax/imm32/outputs
19018 0x11/imm32/alloc-id:fake
19019 _string_35_xor_with_eax/imm32/subx-name
19020 0/imm32/no-rm32
19021 0/imm32/no-r32
19022 1/imm32/imm32-is-first-inout
19023 0/imm32/no-imm8
19024 0/imm32/no-disp32
19025 0/imm32/no-xm32
19026 0/imm32/no-x32
19027 0x11/imm32/alloc-id:fake
19028 _Primitive-xor-reg-with-reg/imm32/next
19029 _Primitive-xor-reg-with-reg:
19030 0x11/imm32/alloc-id:fake:payload
19031
19032 0x11/imm32/alloc-id:fake
19033 _string-xor/imm32/name
19034 0x11/imm32/alloc-id:fake
19035 Single-int-var-in-some-register/imm32/inouts
19036 0x11/imm32/alloc-id:fake
19037 Single-int-var-in-some-register/imm32/outputs
19038 0x11/imm32/alloc-id:fake
19039 _string_31_xor_with/imm32/subx-name
19040 3/imm32/rm32-is-first-output
19041 1/imm32/r32-is-first-inout
19042 0/imm32/no-imm32
19043 0/imm32/no-imm8
19044 0/imm32/no-disp32
19045 0/imm32/no-xm32
19046 0/imm32/no-x32
19047 0x11/imm32/alloc-id:fake
19048 _Primitive-xor-reg-with-mem/imm32/next
19049 _Primitive-xor-reg-with-mem:
19050 0x11/imm32/alloc-id:fake:payload
19051
19052 0x11/imm32/alloc-id:fake
19053 _string-xor-with/imm32/name
19054 0x11/imm32/alloc-id:fake
19055 Two-args-int-stack-int-reg/imm32/inouts
19056 0/imm32/no-outputs
19057 0/imm32/no-outputs
19058 0x11/imm32/alloc-id:fake
19059 _string_31_xor_with/imm32/subx-name
19060 1/imm32/rm32-is-first-inout
19061 2/imm32/r32-is-second-inout
19062 0/imm32/no-imm32
19063 0/imm32/no-imm8
19064 0/imm32/no-disp32
19065 0/imm32/no-xm32
19066 0/imm32/no-x32
19067 0x11/imm32/alloc-id:fake
19068 _Primitive-xor-mem-with-reg/imm32/next
19069 _Primitive-xor-mem-with-reg:
19070 0x11/imm32/alloc-id:fake:payload
19071
19072 0x11/imm32/alloc-id:fake
19073 _string-xor/imm32/name
19074 0x11/imm32/alloc-id:fake
19075 Single-int-var-in-mem/imm32/inouts
19076 0x11/imm32/alloc-id:fake
19077 Single-int-var-in-some-register/imm32/outputs
19078 0x11/imm32/alloc-id:fake
19079 _string_33_xor/imm32/subx-name
19080 1/imm32/rm32-is-first-inout
19081 3/imm32/r32-is-first-output
19082 0/imm32/no-imm32
19083 0/imm32/no-imm8
19084 0/imm32/no-disp32
19085 0/imm32/no-xm32
19086 0/imm32/no-x32
19087 0x11/imm32/alloc-id:fake
19088 _Primitive-xor-lit-with-reg/imm32/next
19089 _Primitive-xor-lit-with-reg:
19090 0x11/imm32/alloc-id:fake:payload
19091
19092 0x11/imm32/alloc-id:fake
19093 _string-xor/imm32/name
19094 0x11/imm32/alloc-id:fake
19095 Single-lit-var/imm32/inouts
19096 0x11/imm32/alloc-id:fake
19097 Single-int-var-in-some-register/imm32/outputs
19098 0x11/imm32/alloc-id:fake
19099 _string_81_subop_xor/imm32/subx-name
19100 3/imm32/rm32-is-first-output
19101 0/imm32/no-r32
19102 1/imm32/imm32-is-first-inout
19103 0/imm32/no-imm8
19104 0/imm32/no-disp32
19105 0/imm32/no-xm32
19106 0/imm32/no-x32
19107 0x11/imm32/alloc-id:fake
19108 _Primitive-xor-lit-with-mem/imm32/next
19109 _Primitive-xor-lit-with-mem:
19110 0x11/imm32/alloc-id:fake:payload
19111
19112 0x11/imm32/alloc-id:fake
19113 _string-xor-with/imm32/name
19114 0x11/imm32/alloc-id:fake
19115 Int-var-and-literal/imm32/inouts
19116 0/imm32/no-outputs
19117 0/imm32/no-outputs
19118 0x11/imm32/alloc-id:fake
19119 _string_81_subop_xor/imm32/subx-name
19120 1/imm32/rm32-is-first-inout
19121 0/imm32/no-r32
19122 2/imm32/imm32-is-second-inout
19123 0/imm32/no-imm8
19124 0/imm32/no-disp32
19125 0/imm32/no-xm32
19126 0/imm32/no-x32
19127 0x11/imm32/alloc-id:fake
19128 _Primitive-shift-reg-left-by-lit/imm32/next
19129 _Primitive-shift-reg-left-by-lit:
19130 0x11/imm32/alloc-id:fake:payload
19131
19132 0x11/imm32/alloc-id:fake
19133 _string-shift-left/imm32/name
19134 0x11/imm32/alloc-id:fake
19135 Single-lit-var/imm32/inouts
19136 0x11/imm32/alloc-id:fake
19137 Single-int-var-in-some-register/imm32/outputs
19138 0x11/imm32/alloc-id:fake
19139 _string_c1_subop_shift_left/imm32/subx-name
19140 3/imm32/rm32-is-first-output
19141 0/imm32/no-r32
19142 0/imm32/no-imm32
19143 1/imm32/imm8-is-first-inout
19144 0/imm32/no-disp32
19145 0/imm32/no-xm32
19146 0/imm32/no-x32
19147 0x11/imm32/alloc-id:fake
19148 _Primitive-shift-reg-right-by-lit/imm32/next
19149 _Primitive-shift-reg-right-by-lit:
19150 0x11/imm32/alloc-id:fake:payload
19151
19152 0x11/imm32/alloc-id:fake
19153 _string-shift-right/imm32/name
19154 0x11/imm32/alloc-id:fake
19155 Single-lit-var/imm32/inouts
19156 0x11/imm32/alloc-id:fake
19157 Single-int-var-in-some-register/imm32/outputs
19158 0x11/imm32/alloc-id:fake
19159 _string_c1_subop_shift_right_padding_zeroes/imm32/subx-name
19160 3/imm32/rm32-is-first-output
19161 0/imm32/no-r32
19162 0/imm32/no-imm32
19163 1/imm32/imm8-is-first-inout
19164 0/imm32/no-disp32
19165 0/imm32/no-xm32
19166 0/imm32/no-x32
19167 0x11/imm32/alloc-id:fake
19168 _Primitive-shift-reg-right-signed-by-lit/imm32/next
19169 _Primitive-shift-reg-right-signed-by-lit:
19170 0x11/imm32/alloc-id:fake:payload
19171
19172 0x11/imm32/alloc-id:fake
19173 _string-shift-right-signed/imm32/name
19174 0x11/imm32/alloc-id:fake
19175 Single-lit-var/imm32/inouts
19176 0x11/imm32/alloc-id:fake
19177 Single-int-var-in-some-register/imm32/outputs
19178 0x11/imm32/alloc-id:fake
19179 _string_c1_subop_shift_right_preserving_sign/imm32/subx-name
19180 3/imm32/rm32-is-first-output
19181 0/imm32/no-r32
19182 0/imm32/no-imm32
19183 1/imm32/imm8-is-first-inout
19184 0/imm32/no-disp32
19185 0/imm32/no-xm32
19186 0/imm32/no-x32
19187 0x11/imm32/alloc-id:fake
19188 _Primitive-shift-mem-left-by-lit/imm32/next
19189 _Primitive-shift-mem-left-by-lit:
19190 0x11/imm32/alloc-id:fake:payload
19191
19192 0x11/imm32/alloc-id:fake
19193 _string-shift-left/imm32/name
19194 0x11/imm32/alloc-id:fake
19195 Int-var-and-literal/imm32/inouts
19196 0/imm32/no-outputs
19197 0/imm32/no-outputs
19198 0x11/imm32/alloc-id:fake
19199 _string_c1_subop_shift_left/imm32/subx-name
19200 1/imm32/rm32-is-first-inout
19201 0/imm32/no-r32
19202 0/imm32/no-imm32
19203 2/imm32/imm8-is-second-inout
19204 0/imm32/no-disp32
19205 0/imm32/no-xm32
19206 0/imm32/no-x32
19207 0x11/imm32/alloc-id:fake
19208 _Primitive-shift-mem-right-by-lit/imm32/next
19209 _Primitive-shift-mem-right-by-lit:
19210 0x11/imm32/alloc-id:fake:payload
19211
19212 0x11/imm32/alloc-id:fake
19213 _string-shift-right/imm32/name
19214 0x11/imm32/alloc-id:fake
19215 Int-var-and-literal/imm32/inouts
19216 0/imm32/no-outputs
19217 0/imm32/no-outputs
19218 0x11/imm32/alloc-id:fake
19219 _string_c1_subop_shift_right_padding_zeroes/imm32/subx-name
19220 1/imm32/rm32-is-first-inout
19221 0/imm32/no-r32
19222 0/imm32/no-imm32
19223 2/imm32/imm8-is-second-inout
19224 0/imm32/no-disp32
19225 0/imm32/no-xm32
19226 0/imm32/no-x32
19227 0x11/imm32/alloc-id:fake
19228 _Primitive-shift-mem-right-signed-by-lit/imm32/next
19229 _Primitive-shift-mem-right-signed-by-lit:
19230 0x11/imm32/alloc-id:fake:payload
19231
19232 0x11/imm32/alloc-id:fake
19233 _string-shift-right-signed/imm32/name
19234 0x11/imm32/alloc-id:fake
19235 Int-var-and-literal/imm32/inouts
19236 0/imm32/no-outputs
19237 0/imm32/no-outputs
19238 0x11/imm32/alloc-id:fake
19239 _string_c1_subop_shift_right_preserving_sign/imm32/subx-name
19240 1/imm32/rm32-is-first-inout
19241 0/imm32/no-r32
19242 0/imm32/no-imm32
19243 2/imm32/imm8-is-second-inout
19244 0/imm32/no-disp32
19245 0/imm32/no-xm32
19246 0/imm32/no-x32
19247 0x11/imm32/alloc-id:fake
19248 _Primitive-copy-to-eax/imm32/next
19249
19250 _Primitive-copy-to-eax:
19251 0x11/imm32/alloc-id:fake:payload
19252
19253 0x11/imm32/alloc-id:fake
19254 _string-copy/imm32/name
19255 0x11/imm32/alloc-id:fake
19256 Single-lit-var/imm32/inouts
19257 0x11/imm32/alloc-id:fake
19258 Single-int-var-in-eax/imm32/outputs
19259 0x11/imm32/alloc-id:fake
19260 _string_b8_copy_to_eax/imm32/subx-name
19261 0/imm32/no-rm32
19262 0/imm32/no-r32
19263 1/imm32/imm32-is-first-inout
19264 0/imm32/no-imm8
19265 0/imm32/no-disp32
19266 0/imm32/no-xm32
19267 0/imm32/no-x32
19268 0x11/imm32/alloc-id:fake
19269 _Primitive-copy-to-ecx/imm32/next
19270 _Primitive-copy-to-ecx:
19271 0x11/imm32/alloc-id:fake:payload
19272
19273 0x11/imm32/alloc-id:fake
19274 _string-copy/imm32/name
19275 0x11/imm32/alloc-id:fake
19276 Single-lit-var/imm32/inouts
19277 0x11/imm32/alloc-id:fake
19278 Single-int-var-in-ecx/imm32/outputs
19279 0x11/imm32/alloc-id:fake
19280 _string_b9_copy_to_ecx/imm32/subx-name
19281 0/imm32/no-rm32
19282 0/imm32/no-r32
19283 1/imm32/imm32-is-first-inout
19284 0/imm32/no-imm8
19285 0/imm32/no-disp32
19286 0/imm32/no-xm32
19287 0/imm32/no-x32
19288 0x11/imm32/alloc-id:fake
19289 _Primitive-copy-to-edx/imm32/next
19290 _Primitive-copy-to-edx:
19291 0x11/imm32/alloc-id:fake:payload
19292
19293 0x11/imm32/alloc-id:fake
19294 _string-copy/imm32/name
19295 0x11/imm32/alloc-id:fake
19296 Single-lit-var/imm32/inouts
19297 0x11/imm32/alloc-id:fake
19298 Single-int-var-in-edx/imm32/outputs
19299 0x11/imm32/alloc-id:fake
19300 _string_ba_copy_to_edx/imm32/subx-name
19301 0/imm32/no-rm32
19302 0/imm32/no-r32
19303 1/imm32/imm32-is-first-inout
19304 0/imm32/no-imm8
19305 0/imm32/no-disp32
19306 0/imm32/no-xm32
19307 0/imm32/no-x32
19308 0x11/imm32/alloc-id:fake
19309 _Primitive-copy-to-ebx/imm32/next
19310 _Primitive-copy-to-ebx:
19311 0x11/imm32/alloc-id:fake:payload
19312
19313 0x11/imm32/alloc-id:fake
19314 _string-copy/imm32/name
19315 0x11/imm32/alloc-id:fake
19316 Single-lit-var/imm32/inouts
19317 0x11/imm32/alloc-id:fake
19318 Single-int-var-in-ebx/imm32/outputs
19319 0x11/imm32/alloc-id:fake
19320 _string_bb_copy_to_ebx/imm32/subx-name
19321 0/imm32/no-rm32
19322 0/imm32/no-r32
19323 1/imm32/imm32-is-first-inout
19324 0/imm32/no-imm8
19325 0/imm32/no-disp32
19326 0/imm32/no-xm32
19327 0/imm32/no-x32
19328 0x11/imm32/alloc-id:fake
19329 _Primitive-copy-to-esi/imm32/next
19330 _Primitive-copy-to-esi:
19331 0x11/imm32/alloc-id:fake:payload
19332
19333 0x11/imm32/alloc-id:fake
19334 _string-copy/imm32/name
19335 0x11/imm32/alloc-id:fake
19336 Single-lit-var/imm32/inouts
19337 0x11/imm32/alloc-id:fake
19338 Single-int-var-in-esi/imm32/outputs
19339 0x11/imm32/alloc-id:fake
19340 _string_be_copy_to_esi/imm32/subx-name
19341 0/imm32/no-rm32
19342 0/imm32/no-r32
19343 1/imm32/imm32-is-first-inout
19344 0/imm32/no-imm8
19345 0/imm32/no-disp32
19346 0/imm32/no-xm32
19347 0/imm32/no-x32
19348 0x11/imm32/alloc-id:fake
19349 _Primitive-copy-to-edi/imm32/next
19350 _Primitive-copy-to-edi:
19351 0x11/imm32/alloc-id:fake:payload
19352
19353 0x11/imm32/alloc-id:fake
19354 _string-copy/imm32/name
19355 0x11/imm32/alloc-id:fake
19356 Single-lit-var/imm32/inouts
19357 0x11/imm32/alloc-id:fake
19358 Single-int-var-in-edi/imm32/outputs
19359 0x11/imm32/alloc-id:fake
19360 _string_bf_copy_to_edi/imm32/subx-name
19361 0/imm32/no-rm32
19362 0/imm32/no-r32
19363 1/imm32/imm32-is-first-inout
19364 0/imm32/no-imm8
19365 0/imm32/no-disp32
19366 0/imm32/no-xm32
19367 0/imm32/no-x32
19368 0x11/imm32/alloc-id:fake
19369 _Primitive-copy-reg-to-reg/imm32/next
19370 _Primitive-copy-reg-to-reg:
19371 0x11/imm32/alloc-id:fake:payload
19372
19373 0x11/imm32/alloc-id:fake
19374 _string-copy/imm32/name
19375 0x11/imm32/alloc-id:fake
19376 Single-int-var-in-some-register/imm32/inouts
19377 0x11/imm32/alloc-id:fake
19378 Single-int-var-in-some-register/imm32/outputs
19379 0x11/imm32/alloc-id:fake
19380 _string_89_<-/imm32/subx-name
19381 3/imm32/rm32-is-first-output
19382 1/imm32/r32-is-first-inout
19383 0/imm32/no-imm32
19384 0/imm32/no-imm8
19385 0/imm32/no-disp32
19386 0/imm32/no-xm32
19387 0/imm32/no-x32
19388 0x11/imm32/alloc-id:fake
19389 _Primitive-copy-reg-to-mem/imm32/next
19390 _Primitive-copy-reg-to-mem:
19391 0x11/imm32/alloc-id:fake:payload
19392
19393 0x11/imm32/alloc-id:fake
19394 _string-copy-to/imm32/name
19395 0x11/imm32/alloc-id:fake
19396 Two-args-int-stack-int-reg/imm32/inouts
19397 0/imm32/no-outputs
19398 0/imm32/no-outputs
19399 0x11/imm32/alloc-id:fake
19400 _string_89_<-/imm32/subx-name
19401 1/imm32/rm32-is-first-inout
19402 2/imm32/r32-is-second-inout
19403 0/imm32/no-imm32
19404 0/imm32/no-imm8
19405 0/imm32/no-disp32
19406 0/imm32/no-xm32
19407 0/imm32/no-x32
19408 0x11/imm32/alloc-id:fake
19409 _Primitive-copy-mem-to-reg/imm32/next
19410 _Primitive-copy-mem-to-reg:
19411 0x11/imm32/alloc-id:fake:payload
19412
19413 0x11/imm32/alloc-id:fake
19414 _string-copy/imm32/name
19415 0x11/imm32/alloc-id:fake
19416 Single-int-var-in-mem/imm32/inouts
19417 0x11/imm32/alloc-id:fake
19418 Single-int-var-in-some-register/imm32/outputs
19419 0x11/imm32/alloc-id:fake
19420 _string_8b_->/imm32/subx-name
19421 1/imm32/rm32-is-first-inout
19422 3/imm32/r32-is-first-output
19423 0/imm32/no-imm32
19424 0/imm32/no-imm8
19425 0/imm32/no-disp32
19426 0/imm32/no-xm32
19427 0/imm32/no-x32
19428 0x11/imm32/alloc-id:fake
19429 _Primitive-copy-lit-to-reg/imm32/next
19430 _Primitive-copy-lit-to-reg:
19431 0x11/imm32/alloc-id:fake:payload
19432
19433 0x11/imm32/alloc-id:fake
19434 _string-copy/imm32/name
19435 0x11/imm32/alloc-id:fake
19436 Single-lit-var/imm32/inouts
19437 0x11/imm32/alloc-id:fake
19438 Single-int-var-in-some-register/imm32/outputs
19439 0x11/imm32/alloc-id:fake
19440 _string_c7_subop_copy/imm32/subx-name
19441 3/imm32/rm32-is-first-output
19442 0/imm32/no-r32
19443 1/imm32/imm32-is-first-inout
19444 0/imm32/no-imm8
19445 0/imm32/no-disp32
19446 0/imm32/no-xm32
19447 0/imm32/no-x32
19448 0x11/imm32/alloc-id:fake
19449 _Primitive-copy-lit-to-mem/imm32/next
19450 _Primitive-copy-lit-to-mem:
19451 0x11/imm32/alloc-id:fake:payload
19452
19453 0x11/imm32/alloc-id:fake
19454 _string-copy-to/imm32/name
19455 0x11/imm32/alloc-id:fake
19456 Int-var-and-literal/imm32/inouts
19457 0/imm32/no-outputs
19458 0/imm32/no-outputs
19459 0x11/imm32/alloc-id:fake
19460 _string_c7_subop_copy/imm32/subx-name
19461 1/imm32/rm32-is-first-inout
19462 0/imm32/no-r32
19463 2/imm32/imm32-is-second-inout
19464 0/imm32/no-imm8
19465 0/imm32/no-disp32
19466 0/imm32/no-xm32
19467 0/imm32/no-x32
19468 0x11/imm32/alloc-id:fake
19469 _Primitive-copy-byte-from-reg/imm32/next
19470
19471 _Primitive-copy-byte-from-reg:
19472 0x11/imm32/alloc-id:fake:payload
19473
19474 0x11/imm32/alloc-id:fake
19475 _string-copy-byte/imm32/name
19476 0x11/imm32/alloc-id:fake
19477 Single-byte-var-in-some-register/imm32/inouts
19478 0x11/imm32/alloc-id:fake
19479 Single-byte-var-in-some-register/imm32/outputs
19480 0x11/imm32/alloc-id:fake
19481 _string_8a_copy_byte/imm32/subx-name
19482 1/imm32/rm32-is-first-inout
19483 3/imm32/r32-is-first-output
19484 0/imm32/no-imm32
19485 0/imm32/no-imm8
19486 0/imm32/no-disp32
19487 0/imm32/no-xm32
19488 0/imm32/no-x32
19489 0x11/imm32/alloc-id:fake
19490 _Primitive-copy-byte-from-mem/imm32/next
19491 _Primitive-copy-byte-from-mem:
19492 0x11/imm32/alloc-id:fake:payload
19493
19494 0x11/imm32/alloc-id:fake
19495 _string-copy-byte/imm32/name
19496 0x11/imm32/alloc-id:fake
19497 Single-byte-var-in-mem/imm32/inouts
19498 0x11/imm32/alloc-id:fake
19499 Single-byte-var-in-some-register/imm32/outputs
19500 0x11/imm32/alloc-id:fake
19501 _string_8a_copy_byte/imm32/subx-name
19502 1/imm32/rm32-is-first-inout
19503 3/imm32/r32-is-first-output
19504 0/imm32/no-imm32
19505 0/imm32/no-imm8
19506 0/imm32/no-disp32
19507 0/imm32/no-xm32
19508 0/imm32/no-x32
19509 0x11/imm32/alloc-id:fake
19510 _Primitive-copy-byte-to-mem/imm32/next
19511 _Primitive-copy-byte-to-mem:
19512 0x11/imm32/alloc-id:fake:payload
19513
19514 0x11/imm32/alloc-id:fake
19515 _string-copy-byte-to/imm32/name
19516 0x11/imm32/alloc-id:fake
19517 Two-args-byte-stack-byte-reg/imm32/inouts
19518 0/imm32/no-outputs
19519 0/imm32/no-outputs
19520 0x11/imm32/alloc-id:fake
19521 _string_88_copy_byte/imm32/subx-name
19522 1/imm32/rm32-is-first-inout
19523 2/imm32/r32-is-second-inout
19524 0/imm32/no-imm32
19525 0/imm32/no-imm8
19526 0/imm32/no-disp32
19527 0/imm32/no-xm32
19528 0/imm32/no-x32
19529 0x11/imm32/alloc-id:fake
19530 _Primitive-address/imm32/next
19531
19532 _Primitive-address:
19533 0x11/imm32/alloc-id:fake:payload
19534
19535 0x11/imm32/alloc-id:fake
19536 _string-address/imm32/name
19537 0x11/imm32/alloc-id:fake
19538 Single-int-var-in-mem/imm32/inouts
19539 0x11/imm32/alloc-id:fake
19540 Single-addr-var-in-some-register/imm32/outputs
19541 0x11/imm32/alloc-id:fake
19542 _string_8d_copy_address/imm32/subx-name
19543 1/imm32/rm32-is-first-inout
19544 3/imm32/r32-is-first-output
19545 0/imm32/no-imm32
19546 0/imm32/no-imm8
19547 0/imm32/no-disp32
19548 0/imm32/no-xm32
19549 0/imm32/no-x32
19550 0x11/imm32/alloc-id:fake
19551 _Primitive-compare-reg-with-reg/imm32/next
19552
19553 _Primitive-compare-reg-with-reg:
19554 0x11/imm32/alloc-id:fake:payload
19555
19556 0x11/imm32/alloc-id:fake
19557 _string-compare/imm32/name
19558 0x11/imm32/alloc-id:fake
19559 Two-int-args-in-regs/imm32/inouts
19560 0/imm32/no-outputs
19561 0/imm32/no-outputs
19562 0x11/imm32/alloc-id:fake
19563 _string_39_compare->/imm32/subx-name
19564 1/imm32/rm32-is-first-inout
19565 2/imm32/r32-is-second-inout
19566 0/imm32/no-imm32
19567 0/imm32/no-imm8
19568 0/imm32/no-disp32
19569 0/imm32/no-xm32
19570 0/imm32/no-x32
19571 0x11/imm32/alloc-id:fake
19572 _Primitive-compare-mem-with-reg/imm32/next
19573 _Primitive-compare-mem-with-reg:
19574 0x11/imm32/alloc-id:fake:payload
19575
19576 0x11/imm32/alloc-id:fake
19577 _string-compare/imm32/name
19578 0x11/imm32/alloc-id:fake
19579 Two-args-int-stack-int-reg/imm32/inouts
19580 0/imm32/no-outputs
19581 0/imm32/no-outputs
19582 0x11/imm32/alloc-id:fake
19583 _string_39_compare->/imm32/subx-name
19584 1/imm32/rm32-is-first-inout
19585 2/imm32/r32-is-second-inout
19586 0/imm32/no-imm32
19587 0/imm32/no-imm8
19588 0/imm32/no-disp32
19589 0/imm32/no-xm32
19590 0/imm32/no-x32
19591 0x11/imm32/alloc-id:fake
19592 _Primitive-compare-reg-with-mem/imm32/next
19593 _Primitive-compare-reg-with-mem:
19594 0x11/imm32/alloc-id:fake:payload
19595
19596 0x11/imm32/alloc-id:fake
19597 _string-compare/imm32/name
19598 0x11/imm32/alloc-id:fake
19599 Two-args-int-reg-int-stack/imm32/inouts
19600 0/imm32/no-outputs
19601 0/imm32/no-outputs
19602 0x11/imm32/alloc-id:fake
19603 _string_3b_compare<-/imm32/subx-name
19604 2/imm32/rm32-is-second-inout
19605 1/imm32/r32-is-first-inout
19606 0/imm32/no-imm32
19607 0/imm32/no-imm8
19608 0/imm32/no-disp32
19609 0/imm32/no-xm32
19610 0/imm32/no-x32
19611 0x11/imm32/alloc-id:fake
19612 _Primitive-compare-eax-with-literal/imm32/next
19613 _Primitive-compare-eax-with-literal:
19614 0x11/imm32/alloc-id:fake:payload
19615
19616 0x11/imm32/alloc-id:fake
19617 _string-compare/imm32/name
19618 0x11/imm32/alloc-id:fake
19619 Two-args-int-eax-int-literal/imm32/inouts
19620 0/imm32/no-outputs
19621 0/imm32/no-outputs
19622 0x11/imm32/alloc-id:fake
19623 _string_3d_compare_eax_with/imm32/subx-name
19624 0/imm32/no-rm32
19625 0/imm32/no-r32
19626 2/imm32/imm32-is-second-inout
19627 0/imm32/no-imm8
19628 0/imm32/no-disp32
19629 0/imm32/no-xm32
19630 0/imm32/no-x32
19631 0x11/imm32/alloc-id:fake
19632 _Primitive-compare-reg-with-literal/imm32/next
19633 _Primitive-compare-reg-with-literal:
19634 0x11/imm32/alloc-id:fake:payload
19635
19636 0x11/imm32/alloc-id:fake
19637 _string-compare/imm32/name
19638 0x11/imm32/alloc-id:fake
19639 Int-var-in-register-and-literal/imm32/inouts
19640 0/imm32/no-outputs
19641 0/imm32/no-outputs
19642 0x11/imm32/alloc-id:fake
19643 _string_81_subop_compare/imm32/subx-name
19644 1/imm32/rm32-is-first-inout
19645 0/imm32/no-r32
19646 2/imm32/imm32-is-second-inout
19647 0/imm32/no-imm8
19648 0/imm32/no-disp32
19649 0/imm32/no-xm32
19650 0/imm32/no-x32
19651 0x11/imm32/alloc-id:fake
19652 _Primitive-compare-mem-with-literal/imm32/next
19653 _Primitive-compare-mem-with-literal:
19654 0x11/imm32/alloc-id:fake:payload
19655
19656 0x11/imm32/alloc-id:fake
19657 _string-compare/imm32/name
19658 0x11/imm32/alloc-id:fake
19659 Int-var-and-literal/imm32/inouts
19660 0/imm32/no-outputs
19661 0/imm32/no-outputs
19662 0x11/imm32/alloc-id:fake
19663 _string_81_subop_compare/imm32/subx-name
19664 1/imm32/rm32-is-first-inout
19665 0/imm32/no-r32
19666 2/imm32/imm32-is-second-inout
19667 0/imm32/no-imm8
19668 0/imm32/no-disp32
19669 0/imm32/no-xm32
19670 0/imm32/no-x32
19671 0x11/imm32/alloc-id:fake
19672 _Primitive-negate-reg/imm32/next
19673
19674 _Primitive-negate-reg:
19675 0x11/imm32/alloc-id:fake:payload
19676
19677 0x11/imm32/alloc-id:fake
19678 _string-negate/imm32/name
19679 0/imm32/no-inouts
19680 0/imm32/no-inouts
19681 0x11/imm32/alloc-id:fake
19682 Single-int-var-in-some-register/imm32/outputs
19683 0x11/imm32/alloc-id:fake
19684 _string_f7_subop_negate/imm32/subx-name
19685 3/imm32/rm32-is-first-output
19686 0/imm32/no-r32
19687 0/imm32/no-imm32
19688 0/imm32/no-imm8
19689 0/imm32/no-disp32
19690 0/imm32/no-xm32
19691 0/imm32/no-x32
19692 0x11/imm32/alloc-id:fake
19693 _Primitive-negate-mem/imm32/next
19694 _Primitive-negate-mem:
19695 0x11/imm32/alloc-id:fake:payload
19696
19697 0x11/imm32/alloc-id:fake
19698 _string-negate/imm32/name
19699 0x11/imm32/alloc-id:fake
19700 Single-int-var-in-mem/imm32/inouts
19701 0/imm32/no-outputs
19702 0/imm32/no-outputs
19703 0x11/imm32/alloc-id:fake
19704 _string_f7_subop_negate/imm32/subx-name
19705 1/imm32/rm32-is-first-inout
19706 0/imm32/no-r32
19707 0/imm32/no-imm32
19708 0/imm32/no-imm8
19709 0/imm32/no-disp32
19710 0/imm32/no-xm32
19711 0/imm32/no-x32
19712 0x11/imm32/alloc-id:fake
19713 _Primitive-multiply-reg-by-reg/imm32/next
19714
19715 _Primitive-multiply-reg-by-reg:
19716 0x11/imm32/alloc-id:fake:payload
19717
19718 0x11/imm32/alloc-id:fake
19719 _string-multiply/imm32/name
19720 0x11/imm32/alloc-id:fake
19721 Single-int-var-in-some-register/imm32/inouts
19722 0x11/imm32/alloc-id:fake
19723 Single-int-var-in-some-register/imm32/outputs
19724 0x11/imm32/alloc-id:fake
19725 _string_0f_af_multiply/imm32/subx-name
19726 1/imm32/rm32-is-first-inout
19727 3/imm32/r32-is-first-output
19728 0/imm32/no-imm32
19729 0/imm32/no-imm8
19730 0/imm32/no-disp32
19731 0/imm32/no-xm32
19732 0/imm32/no-x32
19733 0x11/imm32/alloc-id:fake
19734 _Primitive-multiply-reg-by-mem/imm32/next
19735 _Primitive-multiply-reg-by-mem:
19736 0x11/imm32/alloc-id:fake:payload
19737
19738 0x11/imm32/alloc-id:fake
19739 _string-multiply/imm32/name
19740 0x11/imm32/alloc-id:fake
19741 Single-int-var-in-mem/imm32/inouts
19742 0x11/imm32/alloc-id:fake
19743 Single-int-var-in-some-register/imm32/outputs
19744 0x11/imm32/alloc-id:fake
19745 _string_0f_af_multiply/imm32/subx-name
19746 1/imm32/rm32-is-first-inout
19747 3/imm32/r32-is-first-output
19748 0/imm32/no-imm32
19749 0/imm32/no-imm8
19750 0/imm32/no-disp32
19751 0/imm32/no-xm32
19752 0/imm32/no-x32
19753 0x11/imm32/alloc-id:fake
19754 _Primitive-convert-mem-to-xreg/imm32/next
19755
19756 _Primitive-convert-mem-to-xreg:
19757 0x11/imm32/alloc-id:fake:payload
19758
19759 0x11/imm32/alloc-id:fake
19760 _string-convert/imm32/name
19761 0x11/imm32/alloc-id:fake
19762 Single-int-var-in-mem/imm32/inouts
19763 0x11/imm32/alloc-id:fake
19764 Single-float-var-in-some-register/imm32/outputs
19765 0x11/imm32/alloc-id:fake
19766 _string_f3_0f_2a_convert_to_float/imm32/subx-name
19767 1/imm32/rm32-is-first-inout
19768 0/imm32/no-r32
19769 0/imm32/no-imm32
19770 0/imm32/no-imm8
19771 0/imm32/no-disp32
19772 0/imm32/no-xm32
19773 3/imm32/x32-is-first-output
19774 0x11/imm32/alloc-id:fake
19775 _Primitive-convert-reg-to-xreg/imm32/next
19776 _Primitive-convert-reg-to-xreg:
19777 0x11/imm32/alloc-id:fake:payload
19778
19779 0x11/imm32/alloc-id:fake
19780 _string-convert/imm32/name
19781 0x11/imm32/alloc-id:fake
19782 Single-int-var-in-some-register/imm32/inouts
19783 0x11/imm32/alloc-id:fake
19784 Single-float-var-in-some-register/imm32/outputs
19785 0x11/imm32/alloc-id:fake
19786 _string_f3_0f_2a_convert_to_float/imm32/subx-name
19787 1/imm32/rm32-is-first-inout
19788 0/imm32/no-r32
19789 0/imm32/no-imm32
19790 0/imm32/no-imm8
19791 0/imm32/no-disp32
19792 0/imm32/no-xm32
19793 3/imm32/x32-is-first-output
19794 0x11/imm32/alloc-id:fake
19795 _Primitive-convert-xmem-to-reg/imm32/next
19796
19797 _Primitive-convert-xmem-to-reg:
19798 0x11/imm32/alloc-id:fake:payload
19799
19800 0x11/imm32/alloc-id:fake
19801 _string-convert/imm32/name
19802 0x11/imm32/alloc-id:fake
19803 Single-float-var-in-mem/imm32/inouts
19804 0x11/imm32/alloc-id:fake
19805 Single-int-var-in-some-register/imm32/outputs
19806 0x11/imm32/alloc-id:fake
19807 _string_f3_0f_2d_convert_to_int/imm32/subx-name
19808 0/imm32/no-rm32
19809 3/imm32/r32-is-first-output
19810 0/imm32/no-imm32
19811 0/imm32/no-imm8
19812 0/imm32/no-disp32
19813 1/imm32/xm32-is-first-inout
19814 0/imm32/no-x32
19815 0x11/imm32/alloc-id:fake
19816 _Primitive-convert-xreg-to-reg/imm32/next
19817 _Primitive-convert-xreg-to-reg:
19818 0x11/imm32/alloc-id:fake:payload
19819
19820 0x11/imm32/alloc-id:fake
19821 _string-convert/imm32/name
19822 0x11/imm32/alloc-id:fake
19823 Single-float-var-in-some-register/imm32/inouts
19824 0x11/imm32/alloc-id:fake
19825 Single-int-var-in-some-register/imm32/outputs
19826 0x11/imm32/alloc-id:fake
19827 _string_f3_0f_2d_convert_to_int/imm32/subx-name
19828 0/imm32/no-rm32
19829 3/imm32/r32-is-first-output
19830 0/imm32/no-imm32
19831 0/imm32/no-imm8
19832 0/imm32/no-disp32
19833 1/imm32/xm32-is-first-inout
19834 0/imm32/no-x32
19835 0x11/imm32/alloc-id:fake
19836 _Primitive-truncate-xmem-to-reg/imm32/next
19837 _Primitive-truncate-xmem-to-reg:
19838 0x11/imm32/alloc-id:fake:payload
19839
19840 0x11/imm32/alloc-id:fake
19841 _string-truncate/imm32/name
19842 0x11/imm32/alloc-id:fake
19843 Single-float-var-in-mem/imm32/inouts
19844 0x11/imm32/alloc-id:fake
19845 Single-int-var-in-some-register/imm32/outputs
19846 0x11/imm32/alloc-id:fake
19847 _string_f3_0f_2c_truncate_to_int/imm32/subx-name
19848 0/imm32/no-rm32
19849 3/imm32/r32-is-first-output
19850 0/imm32/no-imm32
19851 0/imm32/no-imm8
19852 0/imm32/no-disp32
19853 1/imm32/xm32-is-first-inout
19854 0/imm32/no-x32
19855 0x11/imm32/alloc-id:fake
19856 _Primitive-truncate-xreg-to-reg/imm32/next
19857 _Primitive-truncate-xreg-to-reg:
19858 0x11/imm32/alloc-id:fake:payload
19859
19860 0x11/imm32/alloc-id:fake
19861 _string-truncate/imm32/name
19862 0x11/imm32/alloc-id:fake
19863 Single-float-var-in-some-register/imm32/inouts
19864 0x11/imm32/alloc-id:fake
19865 Single-int-var-in-some-register/imm32/outputs
19866 0x11/imm32/alloc-id:fake
19867 _string_f3_0f_2c_truncate_to_int/imm32/subx-name
19868 0/imm32/no-rm32
19869 3/imm32/r32-is-first-output
19870 0/imm32/no-imm32
19871 0/imm32/no-imm8
19872 0/imm32/no-disp32
19873 1/imm32/xm32-is-first-inout
19874 0/imm32/no-x32
19875 0x11/imm32/alloc-id:fake
19876 _Primitive-reinterpret-xmem-as-reg/imm32/next
19877
19878 _Primitive-reinterpret-xmem-as-reg:
19879 0x11/imm32/alloc-id:fake:payload
19880
19881 0x11/imm32/alloc-id:fake
19882 _string-reinterpret/imm32/name
19883 0x11/imm32/alloc-id:fake
19884 Single-float-var-in-mem/imm32/inouts
19885 0x11/imm32/alloc-id:fake
19886 Single-int-var-in-some-register/imm32/outputs
19887 0x11/imm32/alloc-id:fake
19888 _string_8b_->/imm32/subx-name
19889 0/imm32/no-rm32
19890 3/imm32/r32-is-first-output
19891 0/imm32/no-imm32
19892 0/imm32/no-imm8
19893 0/imm32/no-disp32
19894 1/imm32/xm32-is-first-inout
19895 0/imm32/no-x32
19896 0x11/imm32/alloc-id:fake
19897 _Primitive-reinterpret-mem-as-xreg/imm32/next
19898 _Primitive-reinterpret-mem-as-xreg:
19899 0x11/imm32/alloc-id:fake:payload
19900
19901 0x11/imm32/alloc-id:fake
19902 _string-reinterpret/imm32/name
19903 0x11/imm32/alloc-id:fake
19904 Single-int-var-in-mem/imm32/inouts
19905 0x11/imm32/alloc-id:fake
19906 Single-float-var-in-some-register/imm32/outputs
19907 0x11/imm32/alloc-id:fake
19908 _string_f3_0f_10_copy/imm32/subx-name
19909 1/imm32/rm32-is-first-inout
19910 0/imm32/no-r32
19911 0/imm32/no-imm32
19912 0/imm32/no-imm8
19913 0/imm32/no-disp32
19914 0/imm32/no-xm32
19915 3/imm32/x32-is-first-output
19916 0x11/imm32/alloc-id:fake
19917 _Primitive-copy-xreg-to-xreg/imm32/next
19918
19919 _Primitive-copy-xreg-to-xreg:
19920 0x11/imm32/alloc-id:fake:payload
19921
19922 0x11/imm32/alloc-id:fake
19923 _string-copy/imm32/name
19924 0x11/imm32/alloc-id:fake
19925 Single-float-var-in-some-register/imm32/inouts
19926 0x11/imm32/alloc-id:fake
19927 Single-float-var-in-some-register/imm32/outputs
19928 0x11/imm32/alloc-id:fake
19929 _string_f3_0f_11_copy/imm32/subx-name
19930 0/imm32/no-rm32
19931 0/imm32/no-r32
19932 0/imm32/no-imm32
19933 0/imm32/no-imm8
19934 0/imm32/no-disp32
19935 3/imm32/xm32-is-first-output
19936 1/imm32/x32-is-first-inout
19937 0x11/imm32/alloc-id:fake
19938 _Primitive-copy-xreg-to-mem/imm32/next
19939 _Primitive-copy-xreg-to-mem:
19940 0x11/imm32/alloc-id:fake:payload
19941
19942 0x11/imm32/alloc-id:fake
19943 _string-copy-to/imm32/name
19944 0x11/imm32/alloc-id:fake
19945 Two-args-float-stack-float-reg/imm32/inouts
19946 0/imm32/no-outputs
19947 0/imm32/no-outputs
19948 0x11/imm32/alloc-id:fake
19949 _string_f3_0f_11_copy/imm32/subx-name
19950 0/imm32/no-rm32
19951 0/imm32/no-r32
19952 0/imm32/no-imm32
19953 0/imm32/no-imm8
19954 0/imm32/no-disp32
19955 1/imm32/xm32-is-first-inout
19956 2/imm32/x32-is-second-inout
19957 0x11/imm32/alloc-id:fake
19958 _Primitive-copy-mem-to-xreg/imm32/next
19959 _Primitive-copy-mem-to-xreg:
19960 0x11/imm32/alloc-id:fake:payload
19961
19962 0x11/imm32/alloc-id:fake
19963 _string-copy/imm32/name
19964 0x11/imm32/alloc-id:fake
19965 Single-float-var-in-mem/imm32/inouts
19966 0x11/imm32/alloc-id:fake
19967 Single-float-var-in-some-register/imm32/outputs
19968 0x11/imm32/alloc-id:fake
19969 _string_f3_0f_10_copy/imm32/subx-name
19970 0/imm32/no-rm32
19971 0/imm32/no-r32
19972 0/imm32/no-imm32
19973 0/imm32/no-imm8
19974 0/imm32/no-disp32
19975 1/imm32/xm32-is-first-inout
19976 3/imm32/x32-is-first-output
19977 0x11/imm32/alloc-id:fake
19978 _Primitive-address-of-xmem/imm32/next
19979
19980 _Primitive-address-of-xmem:
19981 0x11/imm32/alloc-id:fake:payload
19982
19983 0x11/imm32/alloc-id:fake
19984 _string-address/imm32/name
19985 0x11/imm32/alloc-id:fake
19986 Single-float-var-in-mem/imm32/inouts
19987 0x11/imm32/alloc-id:fake
19988 Single-addr-var-in-some-register/imm32/outputs
19989 0x11/imm32/alloc-id:fake
19990 _string_8d_copy_address/imm32/subx-name
19991 1/imm32/rm32-is-first-inout
19992 3/imm32/r32-is-first-output
19993 0/imm32/no-imm32
19994 0/imm32/no-imm8
19995 0/imm32/no-disp32
19996 0/imm32/no-xm32
19997 0/imm32/no-x32
19998 0x11/imm32/alloc-id:fake
19999 _Primitive-add-xreg-to-xreg/imm32/next
20000
20001 _Primitive-add-xreg-to-xreg:
20002 0x11/imm32/alloc-id:fake:payload
20003
20004 0x11/imm32/alloc-id:fake
20005 _string-add/imm32/name
20006 0x11/imm32/alloc-id:fake
20007 Single-float-var-in-some-register/imm32/inouts
20008 0x11/imm32/alloc-id:fake
20009 Single-float-var-in-some-register/imm32/outputs
20010 0x11/imm32/alloc-id:fake
20011 _string_f3_0f_58_add/imm32/subx-name
20012 0/imm32/no-rm32
20013 0/imm32/no-r32
20014 0/imm32/no-imm32
20015 0/imm32/no-imm8
20016 0/imm32/no-disp32
20017 1/imm32/xm32-is-first-inout
20018 3/imm32/x32-is-first-output
20019 0x11/imm32/alloc-id:fake
20020 _Primitive-add-mem-to-xreg/imm32/next
20021 _Primitive-add-mem-to-xreg:
20022 0x11/imm32/alloc-id:fake:payload
20023
20024 0x11/imm32/alloc-id:fake
20025 _string-add/imm32/name
20026 0x11/imm32/alloc-id:fake
20027 Single-float-var-in-mem/imm32/inouts
20028 0x11/imm32/alloc-id:fake
20029 Single-float-var-in-some-register/imm32/outputs
20030 0x11/imm32/alloc-id:fake
20031 _string_f3_0f_58_add/imm32/subx-name
20032 0/imm32/no-rm32
20033 0/imm32/no-r32
20034 0/imm32/no-imm32
20035 0/imm32/no-imm8
20036 0/imm32/no-disp32
20037 1/imm32/xm32-is-first-inout
20038 3/imm32/x32-is-first-output
20039 0x11/imm32/alloc-id:fake
20040 _Primitive-subtract-xreg-from-xreg/imm32/next
20041
20042 _Primitive-subtract-xreg-from-xreg:
20043 0x11/imm32/alloc-id:fake:payload
20044
20045 0x11/imm32/alloc-id:fake
20046 _string-subtract/imm32/name
20047 0x11/imm32/alloc-id:fake
20048 Single-float-var-in-some-register/imm32/inouts
20049 0x11/imm32/alloc-id:fake
20050 Single-float-var-in-some-register/imm32/outputs
20051 0x11/imm32/alloc-id:fake
20052 _string_f3_0f_5c_subtract/imm32/subx-name
20053 0/imm32/no-rm32
20054 0/imm32/no-r32
20055 0/imm32/no-imm32
20056 0/imm32/no-imm8
20057 0/imm32/no-disp32
20058 1/imm32/xm32-is-first-inout
20059 3/imm32/x32-is-first-output
20060 0x11/imm32/alloc-id:fake
20061 _Primitive-subtract-mem-from-xreg/imm32/next
20062 _Primitive-subtract-mem-from-xreg:
20063 0x11/imm32/alloc-id:fake:payload
20064
20065 0x11/imm32/alloc-id:fake
20066 _string-subtract/imm32/name
20067 0x11/imm32/alloc-id:fake
20068 Single-float-var-in-mem/imm32/inouts
20069 0x11/imm32/alloc-id:fake
20070 Single-float-var-in-some-register/imm32/outputs
20071 0x11/imm32/alloc-id:fake
20072 _string_f3_0f_5c_subtract/imm32/subx-name
20073 0/imm32/no-rm32
20074 0/imm32/no-r32
20075 0/imm32/no-imm32
20076 0/imm32/no-imm8
20077 0/imm32/no-disp32
20078 1/imm32/xm32-is-first-inout
20079 3/imm32/x32-is-first-output
20080 0x11/imm32/alloc-id:fake
20081 _Primitive-multiply-xreg-by-xreg/imm32/next
20082
20083 _Primitive-multiply-xreg-by-xreg:
20084 0x11/imm32/alloc-id:fake:payload
20085
20086 0x11/imm32/alloc-id:fake
20087 _string-multiply/imm32/name
20088 0x11/imm32/alloc-id:fake
20089 Single-float-var-in-some-register/imm32/inouts
20090 0x11/imm32/alloc-id:fake
20091 Single-float-var-in-some-register/imm32/outputs
20092 0x11/imm32/alloc-id:fake
20093 _string_f3_0f_59_multiply/imm32/subx-name
20094 0/imm32/no-rm32
20095 0/imm32/no-r32
20096 0/imm32/no-imm32
20097 0/imm32/no-imm8
20098 0/imm32/no-disp32
20099 1/imm32/xm32-is-first-inout
20100 3/imm32/x32-is-first-output
20101 0x11/imm32/alloc-id:fake
20102 _Primitive-multiply-xreg-by-mem/imm32/next
20103 _Primitive-multiply-xreg-by-mem:
20104 0x11/imm32/alloc-id:fake:payload
20105
20106 0x11/imm32/alloc-id:fake
20107 _string-multiply/imm32/name
20108 0x11/imm32/alloc-id:fake
20109 Single-float-var-in-mem/imm32/inouts
20110 0x11/imm32/alloc-id:fake
20111 Single-float-var-in-some-register/imm32/outputs
20112 0x11/imm32/alloc-id:fake
20113 _string_f3_0f_59_multiply/imm32/subx-name
20114 0/imm32/no-rm32
20115 0/imm32/no-r32
20116 0/imm32/no-imm32
20117 0/imm32/no-imm8
20118 0/imm32/no-disp32
20119 1/imm32/xm32-is-first-inout
20120 3/imm32/x32-is-first-output
20121 0x11/imm32/alloc-id:fake
20122 _Primitive-divide-xreg-by-xreg/imm32/next
20123
20124 _Primitive-divide-xreg-by-xreg:
20125 0x11/imm32/alloc-id:fake:payload
20126
20127 0x11/imm32/alloc-id:fake
20128 _string-divide/imm32/name
20129 0x11/imm32/alloc-id:fake
20130 Single-float-var-in-some-register/imm32/inouts
20131 0x11/imm32/alloc-id:fake
20132 Single-float-var-in-some-register/imm32/outputs
20133 0x11/imm32/alloc-id:fake
20134 _string_f3_0f_5e_divide/imm32/subx-name
20135 0/imm32/no-rm32
20136 0/imm32/no-r32
20137 0/imm32/no-imm32
20138 0/imm32/no-imm8
20139 0/imm32/no-disp32
20140 1/imm32/xm32-is-first-inout
20141 3/imm32/x32-is-first-output
20142 0x11/imm32/alloc-id:fake
20143 _Primitive-divide-xreg-by-mem/imm32/next
20144 _Primitive-divide-xreg-by-mem:
20145 0x11/imm32/alloc-id:fake:payload
20146
20147 0x11/imm32/alloc-id:fake
20148 _string-divide/imm32/name
20149 0x11/imm32/alloc-id:fake
20150 Single-float-var-in-mem/imm32/inouts
20151 0x11/imm32/alloc-id:fake
20152 Single-float-var-in-some-register/imm32/outputs
20153 0x11/imm32/alloc-id:fake
20154 _string_f3_0f_5e_divide/imm32/subx-name
20155 0/imm32/no-rm32
20156 0/imm32/no-r32
20157 0/imm32/no-imm32
20158 0/imm32/no-imm8
20159 0/imm32/no-disp32
20160 1/imm32/xm32-is-first-inout
20161 3/imm32/x32-is-first-output
20162 0x11/imm32/alloc-id:fake
20163 _Primitive-max-xreg-with-xreg/imm32/next
20164
20165 _Primitive-max-xreg-with-xreg:
20166 0x11/imm32/alloc-id:fake:payload
20167
20168 0x11/imm32/alloc-id:fake
20169 _string-max/imm32/name
20170 0x11/imm32/alloc-id:fake
20171 Single-float-var-in-some-register/imm32/inouts
20172 0x11/imm32/alloc-id:fake
20173 Single-float-var-in-some-register/imm32/outputs
20174 0x11/imm32/alloc-id:fake
20175 _string_f3_0f_5f_max/imm32/subx-name
20176 0/imm32/no-rm32
20177 0/imm32/no-r32
20178 0/imm32/no-imm32
20179 0/imm32/no-imm8
20180 0/imm32/no-disp32
20181 1/imm32/xm32-is-first-inout
20182 3/imm32/x32-is-first-output
20183 0x11/imm32/alloc-id:fake
20184 _Primitive-max-xreg-with-mem/imm32/next
20185 _Primitive-max-xreg-with-mem:
20186 0x11/imm32/alloc-id:fake:payload
20187
20188 0x11/imm32/alloc-id:fake
20189 _string-max/imm32/name
20190 0x11/imm32/alloc-id:fake
20191 Single-float-var-in-mem/imm32/inouts
20192 0x11/imm32/alloc-id:fake
20193 Single-float-var-in-some-register/imm32/outputs
20194 0x11/imm32/alloc-id:fake
20195 _string_f3_0f_5f_max/imm32/subx-name
20196 0/imm32/no-rm32
20197 0/imm32/no-r32
20198 0/imm32/no-imm32
20199 0/imm32/no-imm8
20200 0/imm32/no-disp32
20201 1/imm32/xm32-is-first-inout
20202 3/imm32/x32-is-first-output
20203 0x11/imm32/alloc-id:fake
20204 _Primitive-min-xreg-with-xreg/imm32/next
20205
20206 _Primitive-min-xreg-with-xreg:
20207 0x11/imm32/alloc-id:fake:payload
20208
20209 0x11/imm32/alloc-id:fake
20210 _string-min/imm32/name
20211 0x11/imm32/alloc-id:fake
20212 Single-float-var-in-some-register/imm32/inouts
20213 0x11/imm32/alloc-id:fake
20214 Single-float-var-in-some-register/imm32/outputs
20215 0x11/imm32/alloc-id:fake
20216 _string_f3_0f_5d_min/imm32/subx-name
20217 0/imm32/no-rm32
20218 0/imm32/no-r32
20219 0/imm32/no-imm32
20220 0/imm32/no-imm8
20221 0/imm32/no-disp32
20222 1/imm32/xm32-is-first-inout
20223 3/imm32/x32-is-first-output
20224 0x11/imm32/alloc-id:fake
20225 _Primitive-min-xreg-with-mem/imm32/next
20226 _Primitive-min-xreg-with-mem:
20227 0x11/imm32/alloc-id:fake:payload
20228
20229 0x11/imm32/alloc-id:fake
20230 _string-min/imm32/name
20231 0x11/imm32/alloc-id:fake
20232 Single-float-var-in-mem/imm32/inouts
20233 0x11/imm32/alloc-id:fake
20234 Single-float-var-in-some-register/imm32/outputs
20235 0x11/imm32/alloc-id:fake
20236 _string_f3_0f_5d_min/imm32/subx-name
20237 0/imm32/no-rm32
20238 0/imm32/no-r32
20239 0/imm32/no-imm32
20240 0/imm32/no-imm8
20241 0/imm32/no-disp32
20242 1/imm32/xm32-is-first-inout
20243 3/imm32/x32-is-first-output
20244 0x11/imm32/alloc-id:fake
20245 _Primitive-reciprocal-xreg-to-xreg/imm32/next
20246
20247 _Primitive-reciprocal-xreg-to-xreg:
20248 0x11/imm32/alloc-id:fake:payload
20249
20250 0x11/imm32/alloc-id:fake
20251 _string-reciprocal/imm32/name
20252 0x11/imm32/alloc-id:fake
20253 Single-float-var-in-some-register/imm32/inouts
20254 0x11/imm32/alloc-id:fake
20255 Single-float-var-in-some-register/imm32/outputs
20256 0x11/imm32/alloc-id:fake
20257 _string_f3_0f_53_reciprocal/imm32/subx-name
20258 0/imm32/no-rm32
20259 0/imm32/no-r32
20260 0/imm32/no-imm32
20261 0/imm32/no-imm8
20262 0/imm32/no-disp32
20263 1/imm32/xm32-is-first-inout
20264 3/imm32/x32-is-first-output
20265 0x11/imm32/alloc-id:fake
20266 _Primitive-reciprocal-mem-to-xreg/imm32/next
20267 _Primitive-reciprocal-mem-to-xreg:
20268 0x11/imm32/alloc-id:fake:payload
20269
20270 0x11/imm32/alloc-id:fake
20271 _string-reciprocal/imm32/name
20272 0x11/imm32/alloc-id:fake
20273 Single-float-var-in-mem/imm32/inouts
20274 0x11/imm32/alloc-id:fake
20275 Single-float-var-in-some-register/imm32/outputs
20276 0x11/imm32/alloc-id:fake
20277 _string_f3_0f_53_reciprocal/imm32/subx-name
20278 0/imm32/no-rm32
20279 0/imm32/no-r32
20280 0/imm32/no-imm32
20281 0/imm32/no-imm8
20282 0/imm32/no-disp32
20283 1/imm32/xm32-is-first-inout
20284 3/imm32/x32-is-first-output
20285 0x11/imm32/alloc-id:fake
20286 _Primitive-square-root-xreg-to-xreg/imm32/next
20287
20288 _Primitive-square-root-xreg-to-xreg:
20289 0x11/imm32/alloc-id:fake:payload
20290
20291 0x11/imm32/alloc-id:fake
20292 _string-square-root/imm32/name
20293 0x11/imm32/alloc-id:fake
20294 Single-float-var-in-some-register/imm32/inouts
20295 0x11/imm32/alloc-id:fake
20296 Single-float-var-in-some-register/imm32/outputs
20297 0x11/imm32/alloc-id:fake
20298 _string_f3_0f_51_square_root/imm32/subx-name
20299 0/imm32/no-rm32
20300 0/imm32/no-r32
20301 0/imm32/no-imm32
20302 0/imm32/no-imm8
20303 0/imm32/no-disp32
20304 1/imm32/xm32-is-first-inout
20305 3/imm32/x32-is-first-output
20306 0x11/imm32/alloc-id:fake
20307 _Primitive-square-root-mem-to-xreg/imm32/next
20308 _Primitive-square-root-mem-to-xreg:
20309 0x11/imm32/alloc-id:fake:payload
20310
20311 0x11/imm32/alloc-id:fake
20312 _string-square-root/imm32/name
20313 0x11/imm32/alloc-id:fake
20314 Single-float-var-in-mem/imm32/inouts
20315 0x11/imm32/alloc-id:fake
20316 Single-float-var-in-some-register/imm32/outputs
20317 0x11/imm32/alloc-id:fake
20318 _string_f3_0f_51_square_root/imm32/subx-name
20319 0/imm32/no-rm32
20320 0/imm32/no-r32
20321 0/imm32/no-imm32
20322 0/imm32/no-imm8
20323 0/imm32/no-disp32
20324 1/imm32/xm32-is-first-inout
20325 3/imm32/x32-is-first-output
20326 0x11/imm32/alloc-id:fake
20327 _Primitive-inverse-square-root-xreg-to-xreg/imm32/next
20328
20329 _Primitive-inverse-square-root-xreg-to-xreg:
20330 0x11/imm32/alloc-id:fake:payload
20331
20332 0x11/imm32/alloc-id:fake
20333 _string-inverse-square-root/imm32/name
20334 0x11/imm32/alloc-id:fake
20335 Single-float-var-in-some-register/imm32/inouts
20336 0x11/imm32/alloc-id:fake
20337 Single-float-var-in-some-register/imm32/outputs
20338 0x11/imm32/alloc-id:fake
20339 _string_f3_0f_52_inverse_square_root/imm32/subx-name
20340 0/imm32/no-rm32
20341 0/imm32/no-r32
20342 0/imm32/no-imm32
20343 0/imm32/no-imm8
20344 0/imm32/no-disp32
20345 1/imm32/xm32-is-first-inout
20346 3/imm32/x32-is-first-output
20347 0x11/imm32/alloc-id:fake
20348 _Primitive-inverse-square-root-mem-to-xreg/imm32/next
20349 _Primitive-inverse-square-root-mem-to-xreg:
20350 0x11/imm32/alloc-id:fake:payload
20351
20352 0x11/imm32/alloc-id:fake
20353 _string-inverse-square-root/imm32/name
20354 0x11/imm32/alloc-id:fake
20355 Single-float-var-in-mem/imm32/inouts
20356 0x11/imm32/alloc-id:fake
20357 Single-float-var-in-some-register/imm32/outputs
20358 0x11/imm32/alloc-id:fake
20359 _string_f3_0f_52_inverse_square_root/imm32/subx-name
20360 0/imm32/no-rm32
20361 0/imm32/no-r32
20362 0/imm32/no-imm32
20363 0/imm32/no-imm8
20364 0/imm32/no-disp32
20365 1/imm32/xm32-is-first-inout
20366 3/imm32/x32-is-first-output
20367 0x11/imm32/alloc-id:fake
20368 _Primitive-compare-xreg-with-xreg/imm32/next
20369
20370 _Primitive-compare-xreg-with-xreg:
20371 0x11/imm32/alloc-id:fake:payload
20372
20373 0x11/imm32/alloc-id:fake
20374 _string-compare/imm32/name
20375 0x11/imm32/alloc-id:fake
20376 Two-float-args-in-regs/imm32/inouts
20377 0/imm32/no-outputs
20378 0/imm32/no-outputs
20379 0x11/imm32/alloc-id:fake
20380 _string_0f_2f_compare/imm32/subx-name
20381 0/imm32/no-rm32
20382 0/imm32/no-r32
20383 0/imm32/no-imm32
20384 0/imm32/no-imm8
20385 0/imm32/no-disp32
20386 1/imm32/xm32-is-first-inout
20387 2/imm32/x32-is-second-inout
20388 0x11/imm32/alloc-id:fake
20389 _Primitive-compare-xreg-with-mem/imm32/next
20390 _Primitive-compare-xreg-with-mem:
20391 0x11/imm32/alloc-id:fake:payload
20392
20393 0x11/imm32/alloc-id:fake
20394 _string-compare/imm32/name
20395 0x11/imm32/alloc-id:fake
20396 Two-args-float-reg-float-stack/imm32/inouts
20397 0/imm32/no-outputs
20398 0/imm32/no-outputs
20399 0x11/imm32/alloc-id:fake
20400 _string_0f_2f_compare/imm32/subx-name
20401 0/imm32/no-rm32
20402 0/imm32/no-r32
20403 0/imm32/no-imm32
20404 0/imm32/no-imm8
20405 0/imm32/no-disp32
20406 2/imm32/xm32-is-second-inout
20407 1/imm32/x32-is-first-inout
20408 0x11/imm32/alloc-id:fake
20409 _Primitive-break-if-addr</imm32/next
20410
20411 _Primitive-break-if-addr<:
20412 0x11/imm32/alloc-id:fake:payload
20413 0x11/imm32/alloc-id:fake
20414 _string-break-if-addr</imm32/name
20415 0/imm32/no-inouts
20416 0/imm32/no-inouts
20417 0/imm32/no-outputs
20418 0/imm32/no-outputs
20419 0x11/imm32/alloc-id:fake
20420 _string_0f_82_jump_break/imm32/subx-name
20421 0/imm32/no-rm32
20422 0/imm32/no-r32
20423 0/imm32/no-imm32
20424 0/imm32/no-imm8
20425 0/imm32/no-disp32
20426 0/imm32/no-xm32
20427 0/imm32/no-x32
20428 0x11/imm32/alloc-id:fake
20429 _Primitive-break-if-addr>=/imm32/next
20430 _Primitive-break-if-addr>=:
20431 0x11/imm32/alloc-id:fake:payload
20432 0x11/imm32/alloc-id:fake
20433 _string-break-if-addr>=/imm32/name
20434 0/imm32/no-inouts
20435 0/imm32/no-inouts
20436 0/imm32/no-outputs
20437 0/imm32/no-outputs
20438 0x11/imm32/alloc-id:fake
20439 _string_0f_83_jump_break/imm32/subx-name
20440 0/imm32/no-rm32
20441 0/imm32/no-r32
20442 0/imm32/no-imm32
20443 0/imm32/no-imm8
20444 0/imm32/no-disp32
20445 0/imm32/no-xm32
20446 0/imm32/no-x32
20447 0x11/imm32/alloc-id:fake
20448 _Primitive-break-if-=/imm32/next
20449 _Primitive-break-if-=:
20450 0x11/imm32/alloc-id:fake:payload
20451 0x11/imm32/alloc-id:fake
20452 _string-break-if-=/imm32/name
20453 0/imm32/no-inouts
20454 0/imm32/no-inouts
20455 0/imm32/no-outputs
20456 0/imm32/no-outputs
20457 0x11/imm32/alloc-id:fake
20458 _string_0f_84_jump_break/imm32/subx-name
20459 0/imm32/no-rm32
20460 0/imm32/no-r32
20461 0/imm32/no-imm32
20462 0/imm32/no-imm8
20463 0/imm32/no-disp32
20464 0/imm32/no-xm32
20465 0/imm32/no-x32
20466 0x11/imm32/alloc-id:fake
20467 _Primitive-break-if-!=/imm32/next
20468 _Primitive-break-if-!=:
20469 0x11/imm32/alloc-id:fake:payload
20470 0x11/imm32/alloc-id:fake
20471 _string-break-if-!=/imm32/name
20472 0/imm32/no-inouts
20473 0/imm32/no-inouts
20474 0/imm32/no-outputs
20475 0/imm32/no-outputs
20476 0x11/imm32/alloc-id:fake
20477 _string_0f_85_jump_break/imm32/subx-name
20478 0/imm32/no-rm32
20479 0/imm32/no-r32
20480 0/imm32/no-imm32
20481 0/imm32/no-imm8
20482 0/imm32/no-disp32
20483 0/imm32/no-xm32
20484 0/imm32/no-x32
20485 0x11/imm32/alloc-id:fake
20486 _Primitive-break-if-addr<=/imm32/next
20487 _Primitive-break-if-addr<=:
20488 0x11/imm32/alloc-id:fake:payload
20489 0x11/imm32/alloc-id:fake
20490 _string-break-if-addr<=/imm32/name
20491 0/imm32/no-inouts
20492 0/imm32/no-inouts
20493 0/imm32/no-outputs
20494 0/imm32/no-outputs
20495 0x11/imm32/alloc-id:fake
20496 _string_0f_86_jump_break/imm32/subx-name
20497 0/imm32/no-rm32
20498 0/imm32/no-r32
20499 0/imm32/no-imm32
20500 0/imm32/no-imm8
20501 0/imm32/no-disp32
20502 0/imm32/no-xm32
20503 0/imm32/no-x32
20504 0x11/imm32/alloc-id:fake
20505 _Primitive-break-if-addr>/imm32/next
20506 _Primitive-break-if-addr>:
20507 0x11/imm32/alloc-id:fake:payload
20508 0x11/imm32/alloc-id:fake
20509 _string-break-if-addr>/imm32/name
20510 0/imm32/no-inouts
20511 0/imm32/no-inouts
20512 0/imm32/no-outputs
20513 0/imm32/no-outputs
20514 0x11/imm32/alloc-id:fake
20515 _string_0f_87_jump_break/imm32/subx-name
20516 0/imm32/no-rm32
20517 0/imm32/no-r32
20518 0/imm32/no-imm32
20519 0/imm32/no-imm8
20520 0/imm32/no-disp32
20521 0/imm32/no-xm32
20522 0/imm32/no-x32
20523 0x11/imm32/alloc-id:fake
20524 _Primitive-break-if-</imm32/next
20525 _Primitive-break-if-<:
20526 0x11/imm32/alloc-id:fake:payload
20527 0x11/imm32/alloc-id:fake
20528 _string-break-if-</imm32/name
20529 0/imm32/no-inouts
20530 0/imm32/no-inouts
20531 0/imm32/no-outputs
20532 0/imm32/no-outputs
20533 0x11/imm32/alloc-id:fake
20534 _string_0f_8c_jump_break/imm32/subx-name
20535 0/imm32/no-rm32
20536 0/imm32/no-r32
20537 0/imm32/no-imm32
20538 0/imm32/no-imm8
20539 0/imm32/no-disp32
20540 0/imm32/no-xm32
20541 0/imm32/no-x32
20542 0x11/imm32/alloc-id:fake
20543 _Primitive-break-if->=/imm32/next
20544 _Primitive-break-if->=:
20545 0x11/imm32/alloc-id:fake:payload
20546 0x11/imm32/alloc-id:fake
20547 _string-break-if->=/imm32/name
20548 0/imm32/no-inouts
20549 0/imm32/no-inouts
20550 0/imm32/no-outputs
20551 0/imm32/no-outputs
20552 0x11/imm32/alloc-id:fake
20553 _string_0f_8d_jump_break/imm32/subx-name
20554 0/imm32/no-rm32
20555 0/imm32/no-r32
20556 0/imm32/no-imm32
20557 0/imm32/no-imm8
20558 0/imm32/no-disp32
20559 0/imm32/no-xm32
20560 0/imm32/no-x32
20561 0x11/imm32/alloc-id:fake
20562 _Primitive-break-if-<=/imm32/next
20563 _Primitive-break-if-<=:
20564 0x11/imm32/alloc-id:fake:payload
20565 0x11/imm32/alloc-id:fake
20566 _string-break-if-<=/imm32/name
20567 0/imm32/no-inouts
20568 0/imm32/no-inouts
20569 0/imm32/no-outputs
20570 0/imm32/no-outputs
20571 0x11/imm32/alloc-id:fake
20572 _string_0f_8e_jump_break/imm32/subx-name
20573 0/imm32/no-rm32
20574 0/imm32/no-r32
20575 0/imm32/no-imm32
20576 0/imm32/no-imm8
20577 0/imm32/no-disp32
20578 0/imm32/no-xm32
20579 0/imm32/no-x32
20580 0x11/imm32/alloc-id:fake
20581 _Primitive-break-if->/imm32/next
20582 _Primitive-break-if->:
20583 0x11/imm32/alloc-id:fake:payload
20584 0x11/imm32/alloc-id:fake
20585 _string-break-if->/imm32/name
20586 0/imm32/no-inouts
20587 0/imm32/no-inouts
20588 0/imm32/no-outputs
20589 0/imm32/no-outputs
20590 0x11/imm32/alloc-id:fake
20591 _string_0f_8f_jump_break/imm32/subx-name
20592 0/imm32/no-rm32
20593 0/imm32/no-r32
20594 0/imm32/no-imm32
20595 0/imm32/no-imm8
20596 0/imm32/no-disp32
20597 0/imm32/no-xm32
20598 0/imm32/no-x32
20599 0x11/imm32/alloc-id:fake
20600 _Primitive-break/imm32/next
20601 _Primitive-break:
20602 0x11/imm32/alloc-id:fake:payload
20603 0x11/imm32/alloc-id:fake
20604 _string-break/imm32/name
20605 0/imm32/no-inouts
20606 0/imm32/no-inouts
20607 0/imm32/no-outputs
20608 0/imm32/no-outputs
20609 0x11/imm32/alloc-id:fake
20610 _string_e9_jump_break/imm32/subx-name
20611 0/imm32/no-rm32
20612 0/imm32/no-r32
20613 0/imm32/no-imm32
20614 0/imm32/no-imm8
20615 0/imm32/no-disp32
20616 0/imm32/no-xm32
20617 0/imm32/no-x32
20618 0x11/imm32/alloc-id:fake
20619 _Primitive-loop-if-addr</imm32/next
20620 _Primitive-loop-if-addr<:
20621 0x11/imm32/alloc-id:fake:payload
20622 0x11/imm32/alloc-id:fake
20623 _string-loop-if-addr</imm32/name
20624 0/imm32/no-inouts
20625 0/imm32/no-inouts
20626 0/imm32/no-outputs
20627 0/imm32/no-outputs
20628 0x11/imm32/alloc-id:fake
20629 _string_0f_82_jump_loop/imm32/subx-name
20630 0/imm32/no-rm32
20631 0/imm32/no-r32
20632 0/imm32/no-imm32
20633 0/imm32/no-imm8
20634 0/imm32/no-disp32
20635 0/imm32/no-xm32
20636 0/imm32/no-x32
20637 0x11/imm32/alloc-id:fake
20638 _Primitive-loop-if-addr>=/imm32/next
20639 _Primitive-loop-if-addr>=:
20640 0x11/imm32/alloc-id:fake:payload
20641 0x11/imm32/alloc-id:fake
20642 _string-loop-if-addr>=/imm32/name
20643 0/imm32/no-inouts
20644 0/imm32/no-inouts
20645 0/imm32/no-outputs
20646 0/imm32/no-outputs
20647 0x11/imm32/alloc-id:fake
20648 _string_0f_83_jump_loop/imm32/subx-name
20649 0/imm32/no-rm32
20650 0/imm32/no-r32
20651 0/imm32/no-imm32
20652 0/imm32/no-imm8
20653 0/imm32/no-disp32
20654 0/imm32/no-xm32
20655 0/imm32/no-x32
20656 0x11/imm32/alloc-id:fake
20657 _Primitive-loop-if-=/imm32/next
20658 _Primitive-loop-if-=:
20659 0x11/imm32/alloc-id:fake:payload
20660 0x11/imm32/alloc-id:fake
20661 _string-loop-if-=/imm32/name
20662 0/imm32/no-inouts
20663 0/imm32/no-inouts
20664 0/imm32/no-outputs
20665 0/imm32/no-outputs
20666 0x11/imm32/alloc-id:fake
20667 _string_0f_84_jump_loop/imm32/subx-name
20668 0/imm32/no-rm32
20669 0/imm32/no-r32
20670 0/imm32/no-imm32
20671 0/imm32/no-imm8
20672 0/imm32/no-disp32
20673 0/imm32/no-xm32
20674 0/imm32/no-x32
20675 0x11/imm32/alloc-id:fake
20676 _Primitive-loop-if-!=/imm32/next
20677 _Primitive-loop-if-!=:
20678 0x11/imm32/alloc-id:fake:payload
20679 0x11/imm32/alloc-id:fake
20680 _string-loop-if-!=/imm32/name
20681 0/imm32/no-inouts
20682 0/imm32/no-inouts
20683 0/imm32/no-outputs
20684 0/imm32/no-outputs
20685 0x11/imm32/alloc-id:fake
20686 _string_0f_85_jump_loop/imm32/subx-name
20687 0/imm32/no-rm32
20688 0/imm32/no-r32
20689 0/imm32/no-imm32
20690 0/imm32/no-imm8
20691 0/imm32/no-disp32
20692 0/imm32/no-xm32
20693 0/imm32/no-x32
20694 0x11/imm32/alloc-id:fake
20695 _Primitive-loop-if-addr<=/imm32/next
20696 _Primitive-loop-if-addr<=:
20697 0x11/imm32/alloc-id:fake:payload
20698 0x11/imm32/alloc-id:fake
20699 _string-loop-if-addr<=/imm32/name
20700 0/imm32/no-inouts
20701 0/imm32/no-inouts
20702 0/imm32/no-outputs
20703 0/imm32/no-outputs
20704 0x11/imm32/alloc-id:fake
20705 _string_0f_86_jump_loop/imm32/subx-name
20706 0/imm32/no-rm32
20707 0/imm32/no-r32
20708 0/imm32/no-imm32
20709 0/imm32/no-imm8
20710 0/imm32/no-disp32
20711 0/imm32/no-xm32
20712 0/imm32/no-x32
20713 0x11/imm32/alloc-id:fake
20714 _Primitive-loop-if-addr>/imm32/next
20715 _Primitive-loop-if-addr>:
20716 0x11/imm32/alloc-id:fake:payload
20717 0x11/imm32/alloc-id:fake
20718 _string-loop-if-addr>/imm32/name
20719 0/imm32/no-inouts
20720 0/imm32/no-inouts
20721 0/imm32/no-outputs
20722 0/imm32/no-outputs
20723 0x11/imm32/alloc-id:fake
20724 _string_0f_87_jump_loop/imm32/subx-name
20725 0/imm32/no-rm32
20726 0/imm32/no-r32
20727 0/imm32/no-imm32
20728 0/imm32/no-imm8
20729 0/imm32/no-disp32
20730 0/imm32/no-xm32
20731 0/imm32/no-x32
20732 0x11/imm32/alloc-id:fake
20733 _Primitive-loop-if-</imm32/next
20734 _Primitive-loop-if-<:
20735 0x11/imm32/alloc-id:fake:payload
20736 0x11/imm32/alloc-id:fake
20737 _string-loop-if-</imm32/name
20738 0/imm32/no-inouts
20739 0/imm32/no-inouts
20740 0/imm32/no-outputs
20741 0/imm32/no-outputs
20742 0x11/imm32/alloc-id:fake
20743 _string_0f_8c_jump_loop/imm32/subx-name
20744 0/imm32/no-rm32
20745 0/imm32/no-r32
20746 0/imm32/no-imm32
20747 0/imm32/no-imm8
20748 0/imm32/no-disp32
20749 0/imm32/no-xm32
20750 0/imm32/no-x32
20751 0x11/imm32/alloc-id:fake
20752 _Primitive-loop-if->=/imm32/next
20753 _Primitive-loop-if->=:
20754 0x11/imm32/alloc-id:fake:payload
20755 0x11/imm32/alloc-id:fake
20756 _string-loop-if->=/imm32/name
20757 0/imm32/no-inouts
20758 0/imm32/no-inouts
20759 0/imm32/no-outputs
20760 0/imm32/no-outputs
20761 0x11/imm32/alloc-id:fake
20762 _string_0f_8d_jump_loop/imm32/subx-name
20763 0/imm32/no-rm32
20764 0/imm32/no-r32
20765 0/imm32/no-imm32
20766 0/imm32/no-imm8
20767 0/imm32/no-disp32
20768 0/imm32/no-xm32
20769 0/imm32/no-x32
20770 0x11/imm32/alloc-id:fake
20771 _Primitive-loop-if-<=/imm32/next
20772 _Primitive-loop-if-<=:
20773 0x11/imm32/alloc-id:fake:payload
20774 0x11/imm32/alloc-id:fake
20775 _string-loop-if-<=/imm32/name
20776 0/imm32/no-inouts
20777 0/imm32/no-inouts
20778 0/imm32/no-outputs
20779 0/imm32/no-outputs
20780 0x11/imm32/alloc-id:fake
20781 _string_0f_8e_jump_loop/imm32/subx-name
20782 0/imm32/no-rm32
20783 0/imm32/no-r32
20784 0/imm32/no-imm32
20785 0/imm32/no-imm8
20786 0/imm32/no-disp32
20787 0/imm32/no-xm32
20788 0/imm32/no-x32
20789 0x11/imm32/alloc-id:fake
20790 _Primitive-loop-if->/imm32/next
20791 _Primitive-loop-if->:
20792 0x11/imm32/alloc-id:fake:payload
20793 0x11/imm32/alloc-id:fake
20794 _string-loop-if->/imm32/name
20795 0/imm32/no-inouts
20796 0/imm32/no-inouts
20797 0/imm32/no-outputs
20798 0/imm32/no-outputs
20799 0x11/imm32/alloc-id:fake
20800 _string_0f_8f_jump_loop/imm32/subx-name
20801 0/imm32/no-rm32
20802 0/imm32/no-r32
20803 0/imm32/no-imm32
20804 0/imm32/no-imm8
20805 0/imm32/no-disp32
20806 0/imm32/no-xm32
20807 0/imm32/no-x32
20808 0x11/imm32/alloc-id:fake
20809 _Primitive-loop/imm32/next
20810 _Primitive-loop:
20811 0x11/imm32/alloc-id:fake:payload
20812 0x11/imm32/alloc-id:fake
20813 _string-loop/imm32/name
20814 0/imm32/no-inouts
20815 0/imm32/no-inouts
20816 0/imm32/no-outputs
20817 0/imm32/no-outputs
20818 0x11/imm32/alloc-id:fake
20819 _string_e9_jump_loop/imm32/subx-name
20820 0/imm32/no-rm32
20821 0/imm32/no-r32
20822 0/imm32/no-imm32
20823 0/imm32/no-imm8
20824 0/imm32/no-disp32
20825 0/imm32/no-xm32
20826 0/imm32/no-x32
20827 0x11/imm32/alloc-id:fake
20828 _Primitive-break-if-addr<-named/imm32/next
20829
20830 _Primitive-break-if-addr<-named:
20831 0x11/imm32/alloc-id:fake:payload
20832 0x11/imm32/alloc-id:fake
20833 _string-break-if-addr</imm32/name
20834 0x11/imm32/alloc-id:fake
20835 Single-lit-var/imm32/inouts
20836 0/imm32/no-outputs
20837 0/imm32/no-outputs
20838 0x11/imm32/alloc-id:fake
20839 _string_0f_82_jump_label/imm32/subx-name
20840 0/imm32/no-rm32
20841 0/imm32/no-r32
20842 0/imm32/no-imm32
20843 0/imm32/no-imm8
20844 1/imm32/disp32-is-first-inout
20845 0/imm32/no-xm32
20846 0/imm32/no-x32
20847 0x11/imm32/alloc-id:fake
20848 _Primitive-break-if-addr>=-named/imm32/next
20849 _Primitive-break-if-addr>=-named:
20850 0x11/imm32/alloc-id:fake:payload
20851 0x11/imm32/alloc-id:fake
20852 _string-break-if-addr>=/imm32/name
20853 0x11/imm32/alloc-id:fake
20854 Single-lit-var/imm32/inouts
20855 0/imm32/no-outputs
20856 0/imm32/no-outputs
20857 0x11/imm32/alloc-id:fake
20858 _string_0f_83_jump_label/imm32/subx-name
20859 0/imm32/no-rm32
20860 0/imm32/no-r32
20861 0/imm32/no-imm32
20862 0/imm32/no-imm8
20863 1/imm32/disp32-is-first-inout
20864 0/imm32/no-xm32
20865 0/imm32/no-x32
20866 0x11/imm32/alloc-id:fake
20867 _Primitive-break-if-=-named/imm32/next
20868 _Primitive-break-if-=-named:
20869 0x11/imm32/alloc-id:fake:payload
20870 0x11/imm32/alloc-id:fake
20871 _string-break-if-=/imm32/name
20872 0x11/imm32/alloc-id:fake
20873 Single-lit-var/imm32/inouts
20874 0/imm32/no-outputs
20875 0/imm32/no-outputs
20876 0x11/imm32/alloc-id:fake
20877 _string_0f_84_jump_label/imm32/subx-name
20878 0/imm32/no-rm32
20879 0/imm32/no-r32
20880 0/imm32/no-imm32
20881 0/imm32/no-imm8
20882 1/imm32/disp32-is-first-inout
20883 0/imm32/no-xm32
20884 0/imm32/no-x32
20885 0x11/imm32/alloc-id:fake
20886 _Primitive-break-if-!=-named/imm32/next
20887 _Primitive-break-if-!=-named:
20888 0x11/imm32/alloc-id:fake:payload
20889 0x11/imm32/alloc-id:fake
20890 _string-break-if-!=/imm32/name
20891 0x11/imm32/alloc-id:fake
20892 Single-lit-var/imm32/inouts
20893 0/imm32/no-outputs
20894 0/imm32/no-outputs
20895 0x11/imm32/alloc-id:fake
20896 _string_0f_85_jump_label/imm32/subx-name
20897 0/imm32/no-rm32
20898 0/imm32/no-r32
20899 0/imm32/no-imm32
20900 0/imm32/no-imm8
20901 1/imm32/disp32-is-first-inout
20902 0/imm32/no-xm32
20903 0/imm32/no-x32
20904 0x11/imm32/alloc-id:fake
20905 _Primitive-break-if-addr<=-named/imm32/next
20906 _Primitive-break-if-addr<=-named:
20907 0x11/imm32/alloc-id:fake:payload
20908 0x11/imm32/alloc-id:fake
20909 _string-break-if-addr<=/imm32/name
20910 0x11/imm32/alloc-id:fake
20911 Single-lit-var/imm32/inouts
20912 0/imm32/no-outputs
20913 0/imm32/no-outputs
20914 0x11/imm32/alloc-id:fake
20915 _string_0f_86_jump_label/imm32/subx-name
20916 0/imm32/no-rm32
20917 0/imm32/no-r32
20918 0/imm32/no-imm32
20919 0/imm32/no-imm8
20920 1/imm32/disp32-is-first-inout
20921 0/imm32/no-xm32
20922 0/imm32/no-x32
20923 0x11/imm32/alloc-id:fake
20924 _Primitive-break-if-addr>-named/imm32/next
20925 _Primitive-break-if-addr>-named:
20926 0x11/imm32/alloc-id:fake:payload
20927 0x11/imm32/alloc-id:fake
20928 _string-break-if-addr>/imm32/name
20929 0x11/imm32/alloc-id:fake
20930 Single-lit-var/imm32/inouts
20931 0/imm32/no-outputs
20932 0/imm32/no-outputs
20933 0x11/imm32/alloc-id:fake
20934 _string_0f_87_jump_label/imm32/subx-name
20935 0/imm32/no-rm32
20936 0/imm32/no-r32
20937 0/imm32/no-imm32
20938 0/imm32/no-imm8
20939 1/imm32/disp32-is-first-inout
20940 0/imm32/no-xm32
20941 0/imm32/no-x32
20942 0x11/imm32/alloc-id:fake
20943 _Primitive-break-if-<-named/imm32/next
20944 _Primitive-break-if-<-named:
20945 0x11/imm32/alloc-id:fake:payload
20946 0x11/imm32/alloc-id:fake
20947 _string-break-if-</imm32/name
20948 0x11/imm32/alloc-id:fake
20949 Single-lit-var/imm32/inouts
20950 0/imm32/no-outputs
20951 0/imm32/no-outputs
20952 0x11/imm32/alloc-id:fake
20953 _string_0f_8c_jump_label/imm32/subx-name
20954 0/imm32/no-rm32
20955 0/imm32/no-r32
20956 0/imm32/no-imm32
20957 0/imm32/no-imm8
20958 1/imm32/disp32-is-first-inout
20959 0/imm32/no-xm32
20960 0/imm32/no-x32
20961 0x11/imm32/alloc-id:fake
20962 _Primitive-break-if->=-named/imm32/next
20963 _Primitive-break-if->=-named:
20964 0x11/imm32/alloc-id:fake:payload
20965 0x11/imm32/alloc-id:fake
20966 _string-break-if->=/imm32/name
20967 0x11/imm32/alloc-id:fake
20968 Single-lit-var/imm32/inouts
20969 0/imm32/no-outputs
20970 0/imm32/no-outputs
20971 0x11/imm32/alloc-id:fake
20972 _string_0f_8d_jump_label/imm32/subx-name
20973 0/imm32/no-rm32
20974 0/imm32/no-r32
20975 0/imm32/no-imm32
20976 0/imm32/no-imm8
20977 1/imm32/disp32-is-first-inout
20978 0/imm32/no-xm32
20979 0/imm32/no-x32
20980 0x11/imm32/alloc-id:fake
20981 _Primitive-break-if-<=-named/imm32/next
20982 _Primitive-break-if-<=-named:
20983 0x11/imm32/alloc-id:fake:payload
20984 0x11/imm32/alloc-id:fake
20985 _string-break-if-<=/imm32/name
20986 0x11/imm32/alloc-id:fake
20987 Single-lit-var/imm32/inouts
20988 0/imm32/no-outputs
20989 0/imm32/no-outputs
20990 0x11/imm32/alloc-id:fake
20991 _string_0f_8e_jump_label/imm32/subx-name
20992 0/imm32/no-rm32
20993 0/imm32/no-r32
20994 0/imm32/no-imm32
20995 0/imm32/no-imm8
20996 1/imm32/disp32-is-first-inout
20997 0/imm32/no-xm32
20998 0/imm32/no-x32
20999 0x11/imm32/alloc-id:fake
21000 _Primitive-break-if->-named/imm32/next
21001 _Primitive-break-if->-named:
21002 0x11/imm32/alloc-id:fake:payload
21003 0x11/imm32/alloc-id:fake
21004 _string-break-if->/imm32/name
21005 0x11/imm32/alloc-id:fake
21006 Single-lit-var/imm32/inouts
21007 0/imm32/no-outputs
21008 0/imm32/no-outputs
21009 0x11/imm32/alloc-id:fake
21010 _string_0f_8f_jump_label/imm32/subx-name
21011 0/imm32/no-rm32
21012 0/imm32/no-r32
21013 0/imm32/no-imm32
21014 0/imm32/no-imm8
21015 1/imm32/disp32-is-first-inout
21016 0/imm32/no-xm32
21017 0/imm32/no-x32
21018 0x11/imm32/alloc-id:fake
21019 _Primitive-break-named/imm32/next
21020 _Primitive-break-named:
21021 0x11/imm32/alloc-id:fake:payload
21022 0x11/imm32/alloc-id:fake
21023 _string-break/imm32/name
21024 0x11/imm32/alloc-id:fake
21025 Single-lit-var/imm32/inouts
21026 0/imm32/no-outputs
21027 0/imm32/no-outputs
21028 0x11/imm32/alloc-id:fake
21029 _string_e9_jump_label/imm32/subx-name
21030 0/imm32/no-rm32
21031 0/imm32/no-r32
21032 0/imm32/no-imm32
21033 0/imm32/no-imm8
21034 1/imm32/disp32-is-first-inout
21035 0/imm32/no-xm32
21036 0/imm32/no-x32
21037 0x11/imm32/alloc-id:fake
21038 _Primitive-loop-if-addr<-named/imm32/next
21039 _Primitive-loop-if-addr<-named:
21040 0x11/imm32/alloc-id:fake:payload
21041 0x11/imm32/alloc-id:fake
21042 _string-loop-if-addr</imm32/name
21043 0x11/imm32/alloc-id:fake
21044 Single-lit-var/imm32/inouts
21045 0/imm32/no-outputs
21046 0/imm32/no-outputs
21047 0x11/imm32/alloc-id:fake
21048 _string_0f_82_jump_label/imm32/subx-name
21049 0/imm32/no-rm32
21050 0/imm32/no-r32
21051 0/imm32/no-imm32
21052 0/imm32/no-imm8
21053 1/imm32/disp32-is-first-inout
21054 0/imm32/no-xm32
21055 0/imm32/no-x32
21056 0x11/imm32/alloc-id:fake
21057 _Primitive-loop-if-addr>=-named/imm32/next
21058 _Primitive-loop-if-addr>=-named:
21059 0x11/imm32/alloc-id:fake:payload
21060 0x11/imm32/alloc-id:fake
21061 _string-loop-if-addr>=/imm32/name
21062 0x11/imm32/alloc-id:fake
21063 Single-lit-var/imm32/inouts
21064 0/imm32/no-outputs
21065 0/imm32/no-outputs
21066 0x11/imm32/alloc-id:fake
21067 _string_0f_83_jump_label/imm32/subx-name
21068 0/imm32/no-rm32
21069 0/imm32/no-r32
21070 0/imm32/no-imm32
21071 0/imm32/no-imm8
21072 1/imm32/disp32-is-first-inout
21073 0/imm32/no-xm32
21074 0/imm32/no-x32
21075 0x11/imm32/alloc-id:fake
21076 _Primitive-loop-if-=-named/imm32/next
21077 _Primitive-loop-if-=-named:
21078 0x11/imm32/alloc-id:fake:payload
21079 0x11/imm32/alloc-id:fake
21080 _string-loop-if-=/imm32/name
21081 0x11/imm32/alloc-id:fake
21082 Single-lit-var/imm32/inouts
21083 0/imm32/no-outputs
21084 0/imm32/no-outputs
21085 0x11/imm32/alloc-id:fake
21086 _string_0f_84_jump_label/imm32/subx-name
21087 0/imm32/no-rm32
21088 0/imm32/no-r32
21089 0/imm32/no-imm32
21090 0/imm32/no-imm8
21091 1/imm32/disp32-is-first-inout
21092 0/imm32/no-xm32
21093 0/imm32/no-x32
21094 0x11/imm32/alloc-id:fake
21095 _Primitive-loop-if-!=-named/imm32/next
21096 _Primitive-loop-if-!=-named:
21097 0x11/imm32/alloc-id:fake:payload
21098 0x11/imm32/alloc-id:fake
21099 _string-loop-if-!=/imm32/name
21100 0x11/imm32/alloc-id:fake
21101 Single-lit-var/imm32/inouts
21102 0/imm32/no-outputs
21103 0/imm32/no-outputs
21104 0x11/imm32/alloc-id:fake
21105 _string_0f_85_jump_label/imm32/subx-name
21106 0/imm32/no-rm32
21107 0/imm32/no-r32
21108 0/imm32/no-imm32
21109 0/imm32/no-imm8
21110 1/imm32/disp32-is-first-inout
21111 0/imm32/no-xm32
21112 0/imm32/no-x32
21113 0x11/imm32/alloc-id:fake
21114 _Primitive-loop-if-addr<=-named/imm32/next
21115 _Primitive-loop-if-addr<=-named:
21116 0x11/imm32/alloc-id:fake:payload
21117 0x11/imm32/alloc-id:fake
21118 _string-loop-if-addr<=/imm32/name
21119 0x11/imm32/alloc-id:fake
21120 Single-lit-var/imm32/inouts
21121 0/imm32/no-outputs
21122 0/imm32/no-outputs
21123 0x11/imm32/alloc-id:fake
21124 _string_0f_86_jump_label/imm32/subx-name
21125 0/imm32/no-rm32
21126 0/imm32/no-r32
21127 0/imm32/no-imm32
21128 0/imm32/no-imm8
21129 1/imm32/disp32-is-first-inout
21130 0/imm32/no-xm32
21131 0/imm32/no-x32
21132 0x11/imm32/alloc-id:fake
21133 _Primitive-loop-if-addr>-named/imm32/next
21134 _Primitive-loop-if-addr>-named:
21135 0x11/imm32/alloc-id:fake:payload
21136 0x11/imm32/alloc-id:fake
21137 _string-loop-if-addr>/imm32/name
21138 0x11/imm32/alloc-id:fake
21139 Single-lit-var/imm32/inouts
21140 0/imm32/no-outputs
21141 0/imm32/no-outputs
21142 0x11/imm32/alloc-id:fake
21143 _string_0f_87_jump_label/imm32/subx-name
21144 0/imm32/no-rm32
21145 0/imm32/no-r32
21146 0/imm32/no-imm32
21147 0/imm32/no-imm8
21148 1/imm32/disp32-is-first-inout
21149 0/imm32/no-xm32
21150 0/imm32/no-x32
21151 0x11/imm32/alloc-id:fake
21152 _Primitive-loop-if-<-named/imm32/next
21153 _Primitive-loop-if-<-named:
21154 0x11/imm32/alloc-id:fake:payload
21155 0x11/imm32/alloc-id:fake
21156 _string-loop-if-</imm32/name
21157 0x11/imm32/alloc-id:fake
21158 Single-lit-var/imm32/inouts
21159 0/imm32/no-outputs
21160 0/imm32/no-outputs
21161 0x11/imm32/alloc-id:fake
21162 _string_0f_8c_jump_label/imm32/subx-name
21163 0/imm32/no-rm32
21164 0/imm32/no-r32
21165 0/imm32/no-imm32
21166 0/imm32/no-imm8
21167 1/imm32/disp32-is-first-inout
21168 0/imm32/no-xm32
21169 0/imm32/no-x32
21170 0x11/imm32/alloc-id:fake
21171 _Primitive-loop-if->=-named/imm32/next
21172 _Primitive-loop-if->=-named:
21173 0x11/imm32/alloc-id:fake:payload
21174 0x11/imm32/alloc-id:fake
21175 _string-loop-if->=/imm32/name
21176 0x11/imm32/alloc-id:fake
21177 Single-lit-var/imm32/inouts
21178 0/imm32/no-outputs
21179 0/imm32/no-outputs
21180 0x11/imm32/alloc-id:fake
21181 _string_0f_8d_jump_label/imm32/subx-name
21182 0/imm32/no-rm32
21183 0/imm32/no-r32
21184 0/imm32/no-imm32
21185 0/imm32/no-imm8
21186 1/imm32/disp32-is-first-inout
21187 0/imm32/no-xm32
21188 0/imm32/no-x32
21189 0x11/imm32/alloc-id:fake
21190 _Primitive-loop-if-<=-named/imm32/next
21191 _Primitive-loop-if-<=-named:
21192 0x11/imm32/alloc-id:fake:payload
21193 0x11/imm32/alloc-id:fake
21194 _string-loop-if-<=/imm32/name
21195 0x11/imm32/alloc-id:fake
21196 Single-lit-var/imm32/inouts
21197 0/imm32/no-outputs
21198 0/imm32/no-outputs
21199 0x11/imm32/alloc-id:fake
21200 _string_0f_8e_jump_label/imm32/subx-name
21201 0/imm32/no-rm32
21202 0/imm32/no-r32
21203 0/imm32/no-imm32
21204 0/imm32/no-imm8
21205 1/imm32/disp32-is-first-inout
21206 0/imm32/no-xm32
21207 0/imm32/no-x32
21208 0x11/imm32/alloc-id:fake
21209 _Primitive-loop-if->-named/imm32/next
21210 _Primitive-loop-if->-named:
21211 0x11/imm32/alloc-id:fake:payload
21212 0x11/imm32/alloc-id:fake
21213 _string-loop-if->/imm32/name
21214 0x11/imm32/alloc-id:fake
21215 Single-lit-var/imm32/inouts
21216 0/imm32/no-outputs
21217 0/imm32/no-outputs
21218 0x11/imm32/alloc-id:fake
21219 _string_0f_8f_jump_label/imm32/subx-name
21220 0/imm32/no-rm32
21221 0/imm32/no-r32
21222 0/imm32/no-imm32
21223 0/imm32/no-imm8
21224 1/imm32/disp32-is-first-inout
21225 0/imm32/no-xm32
21226 0/imm32/no-x32
21227 0x11/imm32/alloc-id:fake
21228 _Primitive-loop-named/imm32/next
21229 _Primitive-loop-named:
21230 0x11/imm32/alloc-id:fake:payload
21231 0x11/imm32/alloc-id:fake
21232 _string-loop/imm32/name
21233 0x11/imm32/alloc-id:fake
21234 Single-lit-var/imm32/inouts
21235 0/imm32/no-outputs
21236 0/imm32/no-outputs
21237 0x11/imm32/alloc-id:fake
21238 _string_e9_jump_label/imm32/subx-name
21239 0/imm32/no-rm32
21240 0/imm32/no-r32
21241 0/imm32/no-imm32
21242 0/imm32/no-imm8
21243 1/imm32/disp32-is-first-inout
21244 0/imm32/no-xm32
21245 0/imm32/no-x32
21246 0x11/imm32/alloc-id:fake
21247 _Primitive-break-if-float</imm32/next
21248
21249 _Primitive-break-if-float<:
21250 0x11/imm32/alloc-id:fake:payload
21251 0x11/imm32/alloc-id:fake
21252 _string-break-if-float</imm32/name
21253 0/imm32/no-inouts
21254 0/imm32/no-inouts
21255 0/imm32/no-outputs
21256 0/imm32/no-outputs
21257 0x11/imm32/alloc-id:fake
21258 _string_0f_82_jump_break/imm32/subx-name
21259 0/imm32/no-rm32
21260 0/imm32/no-r32
21261 0/imm32/no-imm32
21262 0/imm32/no-imm8
21263 0/imm32/no-disp32
21264 0/imm32/no-xm32
21265 0/imm32/no-x32
21266 0x11/imm32/alloc-id:fake
21267 _Primitive-break-if-float>=/imm32/next
21268 _Primitive-break-if-float>=:
21269 0x11/imm32/alloc-id:fake:payload
21270 0x11/imm32/alloc-id:fake
21271 _string-break-if-float>=/imm32/name
21272 0/imm32/no-inouts
21273 0/imm32/no-inouts
21274 0/imm32/no-outputs
21275 0/imm32/no-outputs
21276 0x11/imm32/alloc-id:fake
21277 _string_0f_83_jump_break/imm32/subx-name
21278 0/imm32/no-rm32
21279 0/imm32/no-r32
21280 0/imm32/no-imm32
21281 0/imm32/no-imm8
21282 0/imm32/no-disp32
21283 0/imm32/no-xm32
21284 0/imm32/no-x32
21285 0x11/imm32/alloc-id:fake
21286 _Primitive-break-if-float<=/imm32/next
21287 _Primitive-break-if-float<=:
21288 0x11/imm32/alloc-id:fake:payload
21289 0x11/imm32/alloc-id:fake
21290 _string-break-if-float<=/imm32/name
21291 0/imm32/no-inouts
21292 0/imm32/no-inouts
21293 0/imm32/no-outputs
21294 0/imm32/no-outputs
21295 0x11/imm32/alloc-id:fake
21296 _string_0f_86_jump_break/imm32/subx-name
21297 0/imm32/no-rm32
21298 0/imm32/no-r32
21299 0/imm32/no-imm32
21300 0/imm32/no-imm8
21301 0/imm32/no-disp32
21302 0/imm32/no-xm32
21303 0/imm32/no-x32
21304 0x11/imm32/alloc-id:fake
21305 _Primitive-break-if-float>/imm32/next
21306 _Primitive-break-if-float>:
21307 0x11/imm32/alloc-id:fake:payload
21308 0x11/imm32/alloc-id:fake
21309 _string-break-if-float>/imm32/name
21310 0/imm32/no-inouts
21311 0/imm32/no-inouts
21312 0/imm32/no-outputs
21313 0/imm32/no-outputs
21314 0x11/imm32/alloc-id:fake
21315 _string_0f_87_jump_break/imm32/subx-name
21316 0/imm32/no-rm32
21317 0/imm32/no-r32
21318 0/imm32/no-imm32
21319 0/imm32/no-imm8
21320 0/imm32/no-disp32
21321 0/imm32/no-xm32
21322 0/imm32/no-x32
21323 0x11/imm32/alloc-id:fake
21324 _Primitive-loop-if-float</imm32/next
21325 _Primitive-loop-if-float<:
21326 0x11/imm32/alloc-id:fake:payload
21327 0x11/imm32/alloc-id:fake
21328 _string-loop-if-float</imm32/name
21329 0/imm32/no-inouts
21330 0/imm32/no-inouts
21331 0/imm32/no-outputs
21332 0/imm32/no-outputs
21333 0x11/imm32/alloc-id:fake
21334 _string_0f_82_jump_loop/imm32/subx-name
21335 0/imm32/no-rm32
21336 0/imm32/no-r32
21337 0/imm32/no-imm32
21338 0/imm32/no-imm8
21339 0/imm32/no-disp32
21340 0/imm32/no-xm32
21341 0/imm32/no-x32
21342 0x11/imm32/alloc-id:fake
21343 _Primitive-loop-if-float>=/imm32/next
21344 _Primitive-loop-if-float>=:
21345 0x11/imm32/alloc-id:fake:payload
21346 0x11/imm32/alloc-id:fake
21347 _string-loop-if-float>=/imm32/name
21348 0/imm32/no-inouts
21349 0/imm32/no-inouts
21350 0/imm32/no-outputs
21351 0/imm32/no-outputs
21352 0x11/imm32/alloc-id:fake
21353 _string_0f_83_jump_loop/imm32/subx-name
21354 0/imm32/no-rm32
21355 0/imm32/no-r32
21356 0/imm32/no-imm32
21357 0/imm32/no-imm8
21358 0/imm32/no-disp32
21359 0/imm32/no-xm32
21360 0/imm32/no-x32
21361 0x11/imm32/alloc-id:fake
21362 _Primitive-loop-if-float<=/imm32/next
21363 _Primitive-loop-if-float<=:
21364 0x11/imm32/alloc-id:fake:payload
21365 0x11/imm32/alloc-id:fake
21366 _string-loop-if-float<=/imm32/name
21367 0/imm32/no-inouts
21368 0/imm32/no-inouts
21369 0/imm32/no-outputs
21370 0/imm32/no-outputs
21371 0x11/imm32/alloc-id:fake
21372 _string_0f_86_jump_loop/imm32/subx-name
21373 0/imm32/no-rm32
21374 0/imm32/no-r32
21375 0/imm32/no-imm32
21376 0/imm32/no-imm8
21377 0/imm32/no-disp32
21378 0/imm32/no-xm32
21379 0/imm32/no-x32
21380 0x11/imm32/alloc-id:fake
21381 _Primitive-loop-if-float>/imm32/next
21382 _Primitive-loop-if-float>:
21383 0x11/imm32/alloc-id:fake:payload
21384 0x11/imm32/alloc-id:fake
21385 _string-loop-if-float>/imm32/name
21386 0/imm32/no-inouts
21387 0/imm32/no-inouts
21388 0/imm32/no-outputs
21389 0/imm32/no-outputs
21390 0x11/imm32/alloc-id:fake
21391 _string_0f_87_jump_loop/imm32/subx-name
21392 0/imm32/no-rm32
21393 0/imm32/no-r32
21394 0/imm32/no-imm32
21395 0/imm32/no-imm8
21396 0/imm32/no-disp32
21397 0/imm32/no-xm32
21398 0/imm32/no-x32
21399 0x11/imm32/alloc-id:fake
21400 _Primitive-break-if-float<-named/imm32/next
21401 _Primitive-break-if-float<-named:
21402 0x11/imm32/alloc-id:fake:payload
21403 0x11/imm32/alloc-id:fake
21404 _string-break-if-float</imm32/name
21405 0x11/imm32/alloc-id:fake
21406 Single-lit-var/imm32/inouts
21407 0/imm32/no-outputs
21408 0/imm32/no-outputs
21409 0x11/imm32/alloc-id:fake
21410 _string_0f_82_jump_label/imm32/subx-name
21411 0/imm32/no-rm32
21412 0/imm32/no-r32
21413 0/imm32/no-imm32
21414 0/imm32/no-imm8
21415 1/imm32/disp32-is-first-inout
21416 0/imm32/no-xm32
21417 0/imm32/no-x32
21418 0x11/imm32/alloc-id:fake
21419 _Primitive-break-if-float>=-named/imm32/next
21420 _Primitive-break-if-float>=-named:
21421 0x11/imm32/alloc-id:fake:payload
21422 0x11/imm32/alloc-id:fake
21423 _string-break-if-float>=/imm32/name
21424 0x11/imm32/alloc-id:fake
21425 Single-lit-var/imm32/inouts
21426 0/imm32/no-outputs
21427 0/imm32/no-outputs
21428 0x11/imm32/alloc-id:fake
21429 _string_0f_83_jump_label/imm32/subx-name
21430 0/imm32/no-rm32
21431 0/imm32/no-r32
21432 0/imm32/no-imm32
21433 0/imm32/no-imm8
21434 1/imm32/disp32-is-first-inout
21435 0/imm32/no-xm32
21436 0/imm32/no-x32
21437 0x11/imm32/alloc-id:fake
21438 _Primitive-break-if-float<=-named/imm32/next
21439 _Primitive-break-if-float<=-named:
21440 0x11/imm32/alloc-id:fake:payload
21441 0x11/imm32/alloc-id:fake
21442 _string-break-if-float<=/imm32/name
21443 0x11/imm32/alloc-id:fake
21444 Single-lit-var/imm32/inouts
21445 0/imm32/no-outputs
21446 0/imm32/no-outputs
21447 0x11/imm32/alloc-id:fake
21448 _string_0f_86_jump_label/imm32/subx-name
21449 0/imm32/no-rm32
21450 0/imm32/no-r32
21451 0/imm32/no-imm32
21452 0/imm32/no-imm8
21453 1/imm32/disp32-is-first-inout
21454 0/imm32/no-xm32
21455 0/imm32/no-x32
21456 0x11/imm32/alloc-id:fake
21457 _Primitive-break-if-float>-named/imm32/next
21458 _Primitive-break-if-float>-named:
21459 0x11/imm32/alloc-id:fake:payload
21460 0x11/imm32/alloc-id:fake
21461 _string-break-if-float>/imm32/name
21462 0x11/imm32/alloc-id:fake
21463 Single-lit-var/imm32/inouts
21464 0/imm32/no-outputs
21465 0/imm32/no-outputs
21466 0x11/imm32/alloc-id:fake
21467 _string_0f_87_jump_label/imm32/subx-name
21468 0/imm32/no-rm32
21469 0/imm32/no-r32
21470 0/imm32/no-imm32
21471 0/imm32/no-imm8
21472 1/imm32/disp32-is-first-inout
21473 0/imm32/no-xm32
21474 0/imm32/no-x32
21475 0x11/imm32/alloc-id:fake
21476 _Primitive-loop-if-float<-named/imm32/next
21477 _Primitive-loop-if-float<-named:
21478 0x11/imm32/alloc-id:fake:payload
21479 0x11/imm32/alloc-id:fake
21480 _string-loop-if-float</imm32/name
21481 0x11/imm32/alloc-id:fake
21482 Single-lit-var/imm32/inouts
21483 0/imm32/no-outputs
21484 0/imm32/no-outputs
21485 0x11/imm32/alloc-id:fake
21486 _string_0f_82_jump_label/imm32/subx-name
21487 0/imm32/no-rm32
21488 0/imm32/no-r32
21489 0/imm32/no-imm32
21490 0/imm32/no-imm8
21491 1/imm32/disp32-is-first-inout
21492 0/imm32/no-xm32
21493 0/imm32/no-x32
21494 0x11/imm32/alloc-id:fake
21495 _Primitive-loop-if-float>=-named/imm32/next
21496 _Primitive-loop-if-float>=-named:
21497 0x11/imm32/alloc-id:fake:payload
21498 0x11/imm32/alloc-id:fake
21499 _string-loop-if-float>=/imm32/name
21500 0x11/imm32/alloc-id:fake
21501 Single-lit-var/imm32/inouts
21502 0/imm32/no-outputs
21503 0/imm32/no-outputs
21504 0x11/imm32/alloc-id:fake
21505 _string_0f_83_jump_label/imm32/subx-name
21506 0/imm32/no-rm32
21507 0/imm32/no-r32
21508 0/imm32/no-imm32
21509 0/imm32/no-imm8
21510 1/imm32/disp32-is-first-inout
21511 0/imm32/no-xm32
21512 0/imm32/no-x32
21513 0x11/imm32/alloc-id:fake
21514 _Primitive-loop-if-float<=-named/imm32/next
21515 _Primitive-loop-if-float<=-named:
21516 0x11/imm32/alloc-id:fake:payload
21517 0x11/imm32/alloc-id:fake
21518 _string-loop-if-float<=/imm32/name
21519 0x11/imm32/alloc-id:fake
21520 Single-lit-var/imm32/inouts
21521 0/imm32/no-outputs
21522 0/imm32/no-outputs
21523 0x11/imm32/alloc-id:fake
21524 _string_0f_86_jump_label/imm32/subx-name
21525 0/imm32/no-rm32
21526 0/imm32/no-r32
21527 0/imm32/no-imm32
21528 0/imm32/no-imm8
21529 1/imm32/disp32-is-first-inout
21530 0/imm32/no-xm32
21531 0/imm32/no-x32
21532 0x11/imm32/alloc-id:fake
21533 _Primitive-loop-if-float>-named/imm32/next
21534 _Primitive-loop-if-float>-named:
21535 0x11/imm32/alloc-id:fake:payload
21536 0x11/imm32/alloc-id:fake
21537 _string-loop-if-float>/imm32/name
21538 0x11/imm32/alloc-id:fake
21539 Single-lit-var/imm32/inouts
21540 0/imm32/no-outputs
21541 0/imm32/no-outputs
21542 0x11/imm32/alloc-id:fake
21543 _string_0f_87_jump_label/imm32/subx-name
21544 0/imm32/no-rm32
21545 0/imm32/no-r32
21546 0/imm32/no-imm32
21547 0/imm32/no-imm8
21548 1/imm32/disp32-is-first-inout
21549 0/imm32/no-xm32
21550 0/imm32/no-x32
21551 0/imm32/next
21552 0/imm32/next
21553
21554
21555 _string-add:
21556 0x11/imm32/alloc-id:fake:payload
21557
21558 0x3/imm32/size
21559 0x61/a 0x64/d 0x64/d
21560 _string-address:
21561 0x11/imm32/alloc-id:fake:payload
21562
21563 0x7/imm32/size
21564 0x61/a 0x64/d 0x64/d 0x72/r 0x65/e 0x73/s 0x73/s
21565 _string-add-to:
21566 0x11/imm32/alloc-id:fake:payload
21567
21568 0x6/imm32/size
21569 0x61/a 0x64/d 0x64/d 0x2d/dash 0x74/t 0x6f/o
21570 _string-and:
21571 0x11/imm32/alloc-id:fake:payload
21572
21573 0x3/imm32/size
21574 0x61/a 0x6e/n 0x64/d
21575 _string-and-with:
21576 0x11/imm32/alloc-id:fake:payload
21577
21578 0x8/imm32/size
21579 0x61/a 0x6e/n 0x64/d 0x2d/dash 0x77/w 0x69/i 0x74/t 0x68/h
21580 _string-break:
21581 0x11/imm32/alloc-id:fake:payload
21582
21583 0x5/imm32/size
21584 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k
21585 _string-break-if-<:
21586 0x11/imm32/alloc-id:fake:payload
21587
21588 0xa/imm32/size
21589 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3c/<
21590 _string-break-if-<=:
21591 0x11/imm32/alloc-id:fake:payload
21592
21593 0xb/imm32/size
21594 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3c/< 0x3d/=
21595 _string-break-if-=:
21596 0x11/imm32/alloc-id:fake:payload
21597
21598 0xa/imm32/size
21599 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3d/=
21600 _string-break-if->:
21601 0x11/imm32/alloc-id:fake:payload
21602
21603 0xa/imm32/size
21604 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3e/>
21605 _string-break-if->=:
21606 0x11/imm32/alloc-id:fake:payload
21607
21608 0xb/imm32/size
21609 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3e/> 0x3d/=
21610 _string-break-if-!=:
21611 0x11/imm32/alloc-id:fake:payload
21612
21613 0xb/imm32/size
21614 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x21/! 0x3d/=
21615 _string-break-if-addr<:
21616 0x11/imm32/alloc-id:fake:payload
21617
21618 0xe/imm32/size
21619 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3c/<
21620 _string-break-if-addr<=:
21621 0x11/imm32/alloc-id:fake:payload
21622
21623 0xf/imm32/size
21624 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3c/< 0x3d/=
21625 _string-break-if-addr>:
21626 0x11/imm32/alloc-id:fake:payload
21627
21628 0xe/imm32/size
21629 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3e/>
21630 _string-break-if-addr>=:
21631 0x11/imm32/alloc-id:fake:payload
21632
21633 0xf/imm32/size
21634 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3e/> 0x3d/=
21635 _string-break-if-float<:
21636 0x11/imm32/alloc-id:fake:payload
21637
21638 0xf/imm32/size
21639 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x66/f 0x6c/l 0x6f/o 0x61/a 0x74/t 0x3c/<
21640 _string-break-if-float<=:
21641 0x11/imm32/alloc-id:fake:payload
21642
21643 0x10/imm32/size
21644 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x66/f 0x6c/l 0x6f/o 0x61/a 0x74/t 0x3c/< 0x3d/=
21645 _string-break-if-float>:
21646 0x11/imm32/alloc-id:fake:payload
21647
21648 0xf/imm32/size
21649 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x66/f 0x6c/l 0x6f/o 0x61/a 0x74/t 0x3e/>
21650 _string-break-if-float>=:
21651 0x11/imm32/alloc-id:fake:payload
21652
21653 0x10/imm32/size
21654 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x66/f 0x6c/l 0x6f/o 0x61/a 0x74/t 0x3e/> 0x3d/=
21655 _string-compare:
21656 0x11/imm32/alloc-id:fake:payload
21657
21658 0x7/imm32/size
21659 0x63/c 0x6f/o 0x6d/m 0x70/p 0x61/a 0x72/r 0x65/e
21660 _string-copy:
21661 0x11/imm32/alloc-id:fake:payload
21662
21663 0x4/imm32/size
21664 0x63/c 0x6f/o 0x70/p 0x79/y
21665 _string-copy-to:
21666 0x11/imm32/alloc-id:fake:payload
21667
21668 0x7/imm32/size
21669 0x63/c 0x6f/o 0x70/p 0x79/y 0x2d/dash 0x74/t 0x6f/o
21670 _string-copy-byte:
21671 0x11/imm32/alloc-id:fake:payload
21672
21673 0x9/imm32/size
21674 0x63/c 0x6f/o 0x70/p 0x79/y 0x2d/- 0x62/b 0x79/y 0x74/t 0x65/e
21675 _string-copy-byte-to:
21676 0x11/imm32/alloc-id:fake:payload
21677
21678 0xc/imm32/size
21679 0x63/c 0x6f/o 0x70/p 0x79/y 0x2d/- 0x62/b 0x79/y 0x74/t 0x65/e 0x2d/- 0x74/t 0x6f/o
21680 _string-decrement:
21681 0x11/imm32/alloc-id:fake:payload
21682
21683 0x9/imm32/size
21684 0x64/d 0x65/e 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t
21685 _string-increment:
21686 0x11/imm32/alloc-id:fake:payload
21687
21688 0x9/imm32/size
21689 0x69/i 0x6e/n 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t
21690 _string-loop:
21691 0x11/imm32/alloc-id:fake:payload
21692
21693 0x4/imm32/size
21694 0x6c/l 0x6f/o 0x6f/o 0x70/p
21695 _string-loop-if-<:
21696 0x11/imm32/alloc-id:fake:payload
21697
21698 0x9/imm32/size
21699 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3c/<
21700 _string-loop-if-<=:
21701 0x11/imm32/alloc-id:fake:payload
21702
21703 0xa/imm32/size
21704 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3c/< 0x3d/=
21705 _string-loop-if-=:
21706 0x11/imm32/alloc-id:fake:payload
21707
21708 0x9/imm32/size
21709 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3d/=
21710 _string-loop-if->:
21711 0x11/imm32/alloc-id:fake:payload
21712
21713 0x9/imm32/size
21714 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3e/>
21715 _string-loop-if->=:
21716 0x11/imm32/alloc-id:fake:payload
21717
21718 0xa/imm32/size
21719 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3e/> 0x3d/=
21720 _string-loop-if-!=:
21721 0x11/imm32/alloc-id:fake:payload
21722
21723 0xa/imm32/size
21724 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x21/! 0x3d/=
21725 _string-loop-if-addr<:
21726 0x11/imm32/alloc-id:fake:payload
21727
21728 0xd/imm32/size
21729 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3c/<
21730 _string-loop-if-addr<=:
21731 0x11/imm32/alloc-id:fake:payload
21732
21733 0xe/imm32/size
21734 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3c/< 0x3d/=
21735 _string-loop-if-addr>:
21736 0x11/imm32/alloc-id:fake:payload
21737
21738 0xd/imm32/size
21739 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3e/>
21740 _string-loop-if-addr>=:
21741 0x11/imm32/alloc-id:fake:payload
21742
21743 0xe/imm32/size
21744 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3e/> 0x3d/=
21745 _string-loop-if-float<:
21746 0x11/imm32/alloc-id:fake:payload
21747
21748 0xe/imm32/size
21749 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x66/f 0x6c/l 0x6f/o 0x61/a 0x74/t 0x3c/<
21750 _string-loop-if-float<=:
21751 0x11/imm32/alloc-id:fake:payload
21752
21753 0xf/imm32/size
21754 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x66/f 0x6c/l 0x6f/o 0x61/a 0x74/t 0x3c/< 0x3d/=
21755 _string-loop-if-float>:
21756 0x11/imm32/alloc-id:fake:payload
21757
21758 0xe/imm32/size
21759 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x66/f 0x6c/l 0x6f/o 0x61/a 0x74/t 0x3e/>
21760 _string-loop-if-float>=:
21761 0x11/imm32/alloc-id:fake:payload
21762
21763 0xf/imm32/size
21764 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x66/f 0x6c/l 0x6f/o 0x61/a 0x74/t 0x3e/> 0x3d/=
21765 _string-multiply:
21766 0x11/imm32/alloc-id:fake:payload
21767
21768 0x8/imm32/size
21769 0x6d/m 0x75/u 0x6c/l 0x74/t 0x69/i 0x70/p 0x6c/l 0x79/y
21770 _string-convert:
21771 0x11/imm32/alloc-id:fake:payload
21772
21773 0x7/imm32/size
21774 0x63/c 0x6f/o 0x6e/n 0x76/v 0x65/e 0x72/r 0x74/t
21775 _string-truncate:
21776 0x11/imm32/alloc-id:fake:payload
21777
21778 0x8/imm32/size
21779 0x74/t 0x72/r 0x75/u 0x6e/n 0x63/c 0x61/a 0x74/t 0x65/e
21780 _string-reinterpret:
21781 0x11/imm32/alloc-id:fake:payload
21782
21783 0xb/imm32/size
21784 0x72/r 0x65/e 0x69/i 0x6e/n 0x74/t 0x65/e 0x72/r 0x70/p 0x72/r 0x65/e 0x74/t
21785 _string-divide:
21786 0x11/imm32/alloc-id:fake:payload
21787
21788 0x6/imm32/size
21789 0x64/d 0x69/i 0x76/v 0x69/i 0x64/d 0x65/e
21790 _string-max:
21791 0x11/imm32/alloc-id:fake:payload
21792
21793 0x3/imm32/size
21794 0x6d/m 0x61/a 0x78/x
21795 _string-min:
21796 0x11/imm32/alloc-id:fake:payload
21797
21798 0x3/imm32/size
21799 0x6d/m 0x69/i 0x6e/n
21800 _string-reciprocal:
21801 0x11/imm32/alloc-id:fake:payload
21802
21803 0xa/imm32/size
21804 0x72/r 0x65/e 0x63/c 0x69/i 0x70/p 0x72/r 0x6f/o 0x63/c 0x61/a 0x6c/l
21805 _string-square-root:
21806 0x11/imm32/alloc-id:fake:payload
21807
21808 0xb/imm32/size
21809 0x73/s 0x71/q 0x75/u 0x61/a 0x72/r 0x65/e 0x2d/- 0x72/r 0x6f/o 0x6f/o 0x74/t
21810 _string-inverse-square-root:
21811 0x11/imm32/alloc-id:fake:payload
21812
21813 0x13/imm32/size
21814 0x69/i 0x6e/n 0x76/v 0x65/e 0x72/r 0x73/s 0x65/e 0x2d/- 0x73/s 0x71/q 0x75/u 0x61/a 0x72/r 0x65/e 0x2d/- 0x72/r 0x6f/o 0x6f/o 0x74/t
21815 _string-negate:
21816 0x11/imm32/alloc-id:fake:payload
21817
21818 0x6/imm32/size
21819 0x6e/n 0x65/e 0x67/g 0x61/a 0x74/t 0x65/e
21820 _string-or:
21821 0x11/imm32/alloc-id:fake:payload
21822
21823 0x2/imm32/size
21824 0x6f/o 0x72/r
21825 _string-or-with:
21826 0x11/imm32/alloc-id:fake:payload
21827
21828 0x7/imm32/size
21829 0x6f/o 0x72/r 0x2d/dash 0x77/w 0x69/i 0x74/t 0x68/h
21830 _string-subtract:
21831 0x11/imm32/alloc-id:fake:payload
21832
21833 0x8/imm32/size
21834 0x73/s 0x75/u 0x62/b 0x74/t 0x72/r 0x61/a 0x63/c 0x74/t
21835 _string-subtract-from:
21836 0x11/imm32/alloc-id:fake:payload
21837
21838 0xd/imm32/size
21839 0x73/s 0x75/u 0x62/b 0x74/t 0x72/r 0x61/a 0x63/c 0x74/t 0x2d/dash 0x66/f 0x72/r 0x6f/o 0x6d/m
21840 _string-xor:
21841 0x11/imm32/alloc-id:fake:payload
21842
21843 0x3/imm32/size
21844 0x78/x 0x6f/o 0x72/r
21845 _string-xor-with:
21846 0x11/imm32/alloc-id:fake:payload
21847
21848 0x8/imm32/size
21849 0x78/x 0x6f/o 0x72/r 0x2d/dash 0x77/w 0x69/i 0x74/t 0x68/h
21850 _string-shift-left:
21851 0x11/imm32/alloc-id:fake:payload
21852
21853 0xa/imm32/size
21854 0x73/s 0x68/h 0x69/i 0x66/f 0x74/t 0x2d/dash 0x6c/l 0x65/e 0x66/f 0x74/t
21855 _string-shift-right:
21856 0x11/imm32/alloc-id:fake:payload
21857
21858 0xb/imm32/size
21859 0x73/s 0x68/h 0x69/i 0x66/f 0x74/t 0x2d/dash 0x72/r 0x69/i 0x67/g 0x68/h 0x74/t
21860 _string-shift-right-signed:
21861 0x11/imm32/alloc-id:fake:payload
21862
21863 0x12/imm32/size
21864 0x73/s 0x68/h 0x69/i 0x66/f 0x74/t 0x2d/dash 0x72/r 0x69/i 0x67/g 0x68/h 0x74/t 0x2d/dash 0x73/s 0x69/i 0x67/g 0x6e/n 0x65/e 0x64/d
21865
21866
21867 _string_01_add_to:
21868 0x11/imm32/alloc-id:fake:payload
21869
21870 0x9/imm32/size
21871 0x30/0 0x31/1 0x2f/slash 0x61/a 0x64/d 0x64/d 0x2d/dash 0x74/t 0x6f/o
21872 _string_03_add:
21873 0x11/imm32/alloc-id:fake:payload
21874
21875 0x6/imm32/size
21876 0x30/0 0x33/3 0x2f/slash 0x61/a 0x64/d 0x64/d
21877 _string_05_add_to_eax:
21878 0x11/imm32/alloc-id:fake:payload
21879
21880 0xd/imm32/size
21881 0x30/0 0x35/5 0x2f/slash 0x61/a 0x64/d 0x64/d 0x2d/dash 0x74/t 0x6f/o 0x2d/dash 0x65/e 0x61/a 0x78/x
21882 _string_09_or_with:
21883 0x11/imm32/alloc-id:fake:payload
21884
21885 0xa/imm32/size
21886 0x30/0 0x39/9 0x2f/slash 0x6f/o 0x72/r 0x2d/dash 0x77/w 0x69/i 0x74/t 0x68/h
21887 _string_0b_or:
21888 0x11/imm32/alloc-id:fake:payload
21889
21890 0x5/imm32/size
21891 0x30/0 0x62/b 0x2f/slash 0x6f/o 0x72/r
21892 _string_0d_or_with_eax:
21893 0x11/imm32/alloc-id:fake:payload
21894
21895 0xe/imm32/size
21896 0x30/0 0x64/d 0x2f/slash 0x6f/o 0x72/r 0x2d/dash 0x77/w 0x69/i 0x74/t 0x68/h 0x2d/dash 0x65/e 0x61/a 0x78/x
21897 _string_0f_82_jump_label:
21898 0x11/imm32/alloc-id:fake:payload
21899
21900 0x13/imm32/size
21901 0x30/0 0x66/f 0x20/space 0x38/8 0x32/2 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3c/<
21902 _string_0f_82_jump_break:
21903 0x11/imm32/alloc-id:fake:payload
21904
21905 0x20/imm32/size
21906 0x30/0 0x66/f 0x20/space 0x38/8 0x32/2 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3c/< 0x20/space 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21907 _string_0f_82_jump_loop:
21908 0x11/imm32/alloc-id:fake:payload
21909
21910 0x1f/imm32/size
21911 0x30/0 0x66/f 0x20/space 0x38/8 0x32/2 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3c/< 0x20/space 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21912 _string_0f_83_jump_label:
21913 0x11/imm32/alloc-id:fake:payload
21914
21915 0x14/imm32/size
21916 0x30/0 0x66/f 0x20/space 0x38/8 0x33/3 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3e/> 0x3d/=
21917 _string_0f_83_jump_break:
21918 0x11/imm32/alloc-id:fake:payload
21919
21920 0x21/imm32/size
21921 0x30/0 0x66/f 0x20/space 0x38/8 0x33/3 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3e/> 0x3d/= 0x20/space 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21922 _string_0f_83_jump_loop:
21923 0x11/imm32/alloc-id:fake:payload
21924
21925 0x20/imm32/size
21926 0x30/0 0x66/f 0x20/space 0x38/8 0x33/3 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3e/> 0x3d/= 0x20/space 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21927 _string_0f_84_jump_label:
21928 0x11/imm32/alloc-id:fake:payload
21929
21930 0xf/imm32/size
21931 0x30/0 0x66/f 0x20/space 0x38/8 0x34/4 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3d/=
21932 _string_0f_84_jump_break:
21933 0x11/imm32/alloc-id:fake:payload
21934
21935 0x1c/imm32/size
21936 0x30/0 0x66/f 0x20/space 0x38/8 0x34/4 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3d/= 0x20/space 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21937 _string_0f_84_jump_loop:
21938 0x11/imm32/alloc-id:fake:payload
21939
21940 0x1b/imm32/size
21941 0x30/0 0x66/f 0x20/space 0x38/8 0x34/4 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3d/= 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21942 _string_0f_85_jump_label:
21943 0x11/imm32/alloc-id:fake:payload
21944
21945 0x10/imm32/size
21946 0x30/0 0x66/f 0x20/space 0x38/8 0x35/5 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x21/! 0x3d/=
21947 _string_0f_85_jump_break:
21948 0x11/imm32/alloc-id:fake:payload
21949
21950 0x1d/imm32/size
21951 0x30/0 0x66/f 0x20/space 0x38/8 0x35/5 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x21/! 0x3d/= 0x20/space 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21952 _string_0f_85_jump_loop:
21953 0x11/imm32/alloc-id:fake:payload
21954
21955 0x1c/imm32/size
21956 0x30/0 0x66/f 0x20/space 0x38/8 0x35/5 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x21/! 0x3d/= 0x20/space 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21957 _string_0f_86_jump_label:
21958 0x11/imm32/alloc-id:fake:payload
21959
21960 0x14/imm32/size
21961 0x30/0 0x66/f 0x20/space 0x38/8 0x36/6 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3c/< 0x3d/=
21962 _string_0f_86_jump_break:
21963 0x11/imm32/alloc-id:fake:payload
21964
21965 0x21/imm32/size
21966 0x30/0 0x66/f 0x20/space 0x38/8 0x36/6 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3c/< 0x3d/= 0x20/space 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21967 _string_0f_86_jump_loop:
21968 0x11/imm32/alloc-id:fake:payload
21969
21970 0x20/imm32/size
21971 0x30/0 0x66/f 0x20/space 0x38/8 0x36/6 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3c/< 0x3d/= 0x20/space 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21972 _string_0f_87_jump_label:
21973 0x11/imm32/alloc-id:fake:payload
21974
21975 0x13/imm32/size
21976 0x30/0 0x66/f 0x20/space 0x38/8 0x37/7 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3e/>
21977 _string_0f_87_jump_break:
21978 0x11/imm32/alloc-id:fake:payload
21979
21980 0x20/imm32/size
21981 0x30/0 0x66/f 0x20/space 0x38/8 0x37/7 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3e/> 0x20/space 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21982 _string_0f_87_jump_loop:
21983 0x11/imm32/alloc-id:fake:payload
21984
21985 0x1f/imm32/size
21986 0x30/0 0x66/f 0x20/space 0x38/8 0x37/7 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x3e/> 0x20/space 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21987 _string_0f_8c_jump_label:
21988 0x11/imm32/alloc-id:fake:payload
21989
21990 0xf/imm32/size
21991 0x30/0 0x66/f 0x20/space 0x38/8 0x63/c 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3c/<
21992 _string_0f_8c_jump_break:
21993 0x11/imm32/alloc-id:fake:payload
21994
21995 0x1c/imm32/size
21996 0x30/0 0x66/f 0x20/space 0x38/8 0x63/c 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3c/< 0x20/space 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
21997 _string_0f_8c_jump_loop:
21998 0x11/imm32/alloc-id:fake:payload
21999
22000 0x1b/imm32/size
22001 0x30/0 0x66/f 0x20/space 0x38/8 0x63/c 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3c/< 0x20/space 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
22002 _string_0f_8d_jump_label:
22003 0x11/imm32/alloc-id:fake:payload
22004
22005 0x10/imm32/size
22006 0x30/0 0x66/f 0x20/space 0x38/8 0x64/d 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3e/> 0x3d/=
22007 _string_0f_8d_jump_break:
22008 0x11/imm32/alloc-id:fake:payload
22009
22010 0x1d/imm32/size
22011 0x30/0 0x66/f 0x20/space 0x38/8 0x64/d 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3e/> 0x3d/= 0x20/space 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
22012 _string_0f_8d_jump_loop:
22013 0x11/imm32/alloc-id:fake:payload
22014
22015 0x1c/imm32/size
22016 0x30/0 0x66/f 0x20/space 0x38/8 0x64/d 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3e/> 0x3d/= 0x20/space 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
22017 _string_0f_8e_jump_label:
22018 0x11/imm32/alloc-id:fake:payload
22019
22020 0x10/imm32/size
22021 0x30/0 0x66/f 0x20/space 0x38/8 0x65/e 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3c/< 0x3d/=
22022 _string_0f_8e_jump_break:
22023 0x11/imm32/alloc-id:fake:payload
22024
22025 0x1d/imm32/size
22026 0x30/0 0x66/f 0x20/space 0x38/8 0x65/e 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3c/< 0x3d/= 0x20/space 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
22027 _string_0f_8e_jump_loop:
22028 0x11/imm32/alloc-id:fake:payload
22029
22030 0x1c/imm32/size
22031 0x30/0 0x66/f 0x20/space 0x38/8 0x65/e 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3c/< 0x3d/= 0x20/space 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
22032 _string_0f_8f_jump_label:
22033 0x11/imm32/alloc-id:fake:payload
22034
22035 0xf/imm32/size
22036 0x30/0 0x66/f 0x20/space 0x38/8 0x66/f 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3e/>
22037 _string_0f_8f_jump_break:
22038 0x11/imm32/alloc-id:fake:payload
22039
22040 0x1c/imm32/size
22041 0x30/0 0x66/f 0x20/space 0x38/8 0x66/f 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3e/> 0x20/space 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
22042 _string_0f_8f_jump_loop:
22043 0x11/imm32/alloc-id:fake:payload
22044
22045 0x1b/imm32/size
22046 0x30/0 0x66/f 0x20/space 0x38/8 0x66/f 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x2d/dash 0x69/i 0x66/f 0x2d/dash 0x3e/> 0x20/space 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
22047 _string_0f_af_multiply:
22048 0x11/imm32/alloc-id:fake:payload
22049
22050 0xe/imm32/size
22051 0x30/0 0x66/f 0x20/space 0x61/a 0x66/f 0x2f/slash 0x6d/m 0x75/u 0x6c/l 0x74/t 0x69/i 0x70/p 0x6c/l 0x79/y
22052 _string_f3_0f_2a_convert_to_float:
22053 0x11/imm32/alloc-id:fake:payload
22054
22055 0x19/imm32/size
22056 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x32/2 0x61/a 0x2f/slash 0x63/c 0x6f/o 0x6e/n 0x76/v 0x65/e 0x72/r 0x74/t 0x2d/dash 0x74/t 0x6f/o 0x2d/dash 0x66/f 0x6c/l 0x6f/o 0x61/a 0x74/t
22057 _string_f3_0f_2d_convert_to_int:
22058 0x11/imm32/alloc-id:fake:payload
22059
22060 0x17/imm32/size
22061 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x32/2 0x64/d 0x2f/slash 0x63/c 0x6f/o 0x6e/n 0x76/v 0x65/e 0x72/r 0x74/t 0x2d/dash 0x74/t 0x6f/o 0x2d/dash 0x69/i 0x6e/n 0x74/t
22062 _string_f3_0f_2c_truncate_to_int:
22063 0x11/imm32/alloc-id:fake:payload
22064
22065 0x18/imm32/size
22066 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x32/2 0x63/c 0x2f/slash 0x74/t 0x72/r 0x75/u 0x6e/n 0x63/c 0x61/a 0x74/t 0x65/e 0x2d/dash 0x74/t 0x6f/o 0x2d/dash 0x69/i 0x6e/n 0x74/t
22067 _string_f3_0f_58_add:
22068 0x11/imm32/alloc-id:fake:payload
22069
22070 0xc/imm32/size
22071 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x35/5 0x38/8 0x2f/slash 0x61/a 0x64/d 0x64/d
22072 _string_f3_0f_5c_subtract:
22073 0x11/imm32/alloc-id:fake:payload
22074
22075 0x11/imm32/size
22076 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x35/5 0x63/c 0x2f/slash 0x73/s 0x75/u 0x62/b 0x74/t 0x72/r 0x61/a 0x63/c 0x74/t
22077 _string_f3_0f_59_multiply:
22078 0x11/imm32/alloc-id:fake:payload
22079
22080 0x11/imm32/size
22081 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x35/5 0x39/9 0x2f/slash 0x6d/m 0x75/u 0x6c/l 0x74/t 0x69/i 0x70/p 0x6c/l 0x79/y
22082 _string_f3_0f_5e_divide:
22083 0x11/imm32/alloc-id:fake:payload
22084
22085 0xf/imm32/size
22086 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x35/5 0x65/e 0x2f/slash 0x64/d 0x69/i 0x76/v 0x69/i 0x64/d 0x65/e
22087 _string_f3_0f_53_reciprocal:
22088 0x11/imm32/alloc-id:fake:payload
22089
22090 0x13/imm32/size
22091 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x35/5 0x33/3 0x2f/slash 0x72/r 0x65/e 0x63/c 0x69/i 0x70/p 0x72/r 0x6f/o 0x63/c 0x61/a 0x6c/l
22092 _string_f3_0f_51_square_root:
22093 0x11/imm32/alloc-id:fake:payload
22094
22095 0x14/imm32/size
22096 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x35/5 0x31/1 0x2f/slash 0x73/s 0x71/q 0x75/u 0x61/a 0x72/r 0x65/e 0x2d/dash 0x72/r 0x6f/o 0x6f/o 0x74/t
22097 _string_f3_0f_52_inverse_square_root:
22098 0x11/imm32/alloc-id:fake:payload
22099
22100 0x1c/imm32/size
22101 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x35/5 0x32/2 0x2f/slash 0x69/i 0x6e/n 0x76/v 0x65/e 0x72/r 0x73/s 0x65/e 0x2d/dash 0x73/s 0x71/q 0x75/u 0x61/a 0x72/r 0x65/e 0x2d/dash 0x72/r 0x6f/o 0x6f/o 0x74/t
22102 _string_f3_0f_5d_min:
22103 0x11/imm32/alloc-id:fake:payload
22104
22105 0xc/imm32/size
22106 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x35/5 0x64/d 0x2f/slash 0x6d/m 0x69/i 0x6e/n
22107 _string_f3_0f_5f_max:
22108 0x11/imm32/alloc-id:fake:payload
22109
22110 0xc/imm32/size
22111 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x35/5 0x66/f 0x2f/slash 0x6d/m 0x61/a 0x78/x
22112 _string_f3_0f_10_copy:
22113 0x11/imm32/alloc-id:fake:payload
22114
22115 0xd/imm32/size
22116 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x31/1 0x30/0 0x2f/slash 0x63/c 0x6f/o 0x70/p 0x79/y
22117 _string_f3_0f_11_copy:
22118 0x11/imm32/alloc-id:fake:payload
22119
22120 0xd/imm32/size
22121 0x66/f 0x33/3 0x20/space 0x30/0 0x66/f 0x20/space 0x31/1 0x31/1 0x2f/slash 0x63/c 0x6f/o 0x70/p 0x79/y
22122 _string_0f_2f_compare:
22123 0x11/imm32/alloc-id:fake:payload
22124
22125 0xd/imm32/size
22126 0x30/0 0x66/f 0x20/space 0x32/2 0x66/f 0x2f/slash 0x63/c 0x6f/o 0x6d/m 0x70/p 0x61/a 0x72/r 0x65/e
22127 _string_21_and_with:
22128 0x11/imm32/alloc-id:fake:payload
22129
22130 0xb/imm32/size
22131 0x32/2 0x31/1 0x2f/slash 0x61/a 0x6e/n 0x64/d 0x2d/dash 0x77/w 0x69/i 0x74/t 0x68/h
22132 _string_23_and:
22133 0x11/imm32/alloc-id:fake:payload
22134
22135 0x6/imm32/size
22136 0x32/2 0x33/3 0x2f/slash 0x61/a 0x6e/n 0x64/d
22137 _string_25_and_with_eax:
22138 0x11/imm32/alloc-id:fake:payload
22139
22140 0xf/imm32/size
22141 0x32/2 0x35/5 0x2f/slash 0x61/a 0x6e/n 0x64/d 0x2d/dash 0x77/w 0x69/i 0x74/t 0x68/h 0x2d/dash 0x65/e 0x61/a 0x78/x
22142 _string_29_subtract_from:
22143 0x11/imm32/alloc-id:fake:payload
22144
22145 0x10/imm32/size
22146 0x32/2 0x39/9 0x2f/slash 0x73/s 0x75/u 0x62/b 0x74/t 0x72/r 0x61/a 0x63/c 0x74/t 0x2d/dash 0x66/f 0x72/r 0x6f/o 0x6d/m
22147 _string_2b_subtract:
22148 0x11/imm32/alloc-id:fake:payload
22149
22150 0xb/imm32/size
22151 0x32/2 0x62/b 0x2f/slash 0x73/s 0x75/u 0x62/b 0x74/t 0x72/r 0x61/a 0x63/c 0x74/t
22152 _string_2d_subtract_from_eax:
22153 0x11/imm32/alloc-id:fake:payload
22154
22155 0x14/imm32/size
22156 0x32/2 0x64/d 0x2f/slash 0x73/s 0x75/u 0x62/b 0x74/t 0x72/r 0x61/a 0x63/c 0x74/t 0x2d/dash 0x66/f 0x72/r 0x6f/o 0x6d/m 0x2d/dash 0x65/e 0x61/a 0x78/x
22157 _string_31_xor_with:
22158 0x11/imm32/alloc-id:fake:payload
22159
22160 0xb/imm32/size
22161 0x33/3 0x31/1 0x2f/slash 0x78/x 0x6f/o 0x72/r 0x2d/dash 0x77/w 0x69/i 0x74/t 0x68/h
22162 _string_33_xor:
22163 0x11/imm32/alloc-id:fake:payload
22164
22165 0x6/imm32/size
22166 0x33/3 0x33/3 0x2f/slash 0x78/x 0x6f/o 0x72/r
22167 _string_35_xor_with_eax:
22168 0x11/imm32/alloc-id:fake:payload
22169
22170 0xf/imm32/size
22171 0x33/3 0x35/5 0x2f/slash 0x78/x 0x6f/o 0x72/r 0x2d/dash 0x77/w 0x69/i 0x74/t 0x68/h 0x2d/dash 0x65/e 0x61/a 0x78/x
22172 _string_39_compare->:
22173 0x11/imm32/alloc-id:fake:payload
22174
22175 0xc/imm32/size
22176 0x33/3 0x39/9 0x2f/slash 0x63/c 0x6f/o 0x6d/m 0x70/p 0x61/a 0x72/r 0x65/e 0x2d/dash 0x3e/>
22177 _string_3b_compare<-:
22178 0x11/imm32/alloc-id:fake:payload
22179
22180 0xc/imm32/size
22181 0x33/3 0x62/b 0x2f/slash 0x63/c 0x6f/o 0x6d/m 0x70/p 0x61/a 0x72/r 0x65/e 0x3c/< 0x2d/dash
22182 _string_3d_compare_eax_with:
22183 0x11/imm32/alloc-id:fake:payload
22184
22185 0x13/imm32/size
22186 0x33/3 0x64/d 0x2f/slash 0x63/c 0x6f/o 0x6d/m 0x70/p 0x61/a 0x72/r 0x65/e 0x2d/dash 0x65/e 0x61/a 0x78/x 0x2d/dash 0x77/w 0x69/i 0x74/t 0x68/h
22187 _string_40_increment_eax:
22188 0x11/imm32/alloc-id:fake:payload
22189
22190 0x10/imm32/size
22191 0x34/4 0x30/0 0x2f/slash 0x69/i 0x6e/n 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x61/a 0x78/x
22192 _string_41_increment_ecx:
22193 0x11/imm32/alloc-id:fake:payload
22194
22195 0x10/imm32/size
22196 0x34/4 0x31/1 0x2f/slash 0x69/i 0x6e/n 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x63/c 0x78/x
22197 _string_42_increment_edx:
22198 0x11/imm32/alloc-id:fake:payload
22199
22200 0x10/imm32/size
22201 0x34/4 0x32/2 0x2f/slash 0x69/i 0x6e/n 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x64/d 0x78/x
22202 _string_43_increment_ebx:
22203 0x11/imm32/alloc-id:fake:payload
22204
22205 0x10/imm32/size
22206 0x34/4 0x33/3 0x2f/slash 0x69/i 0x6e/n 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x62/b 0x78/x
22207 _string_46_increment_esi:
22208 0x11/imm32/alloc-id:fake:payload
22209
22210 0x10/imm32/size
22211 0x34/4 0x36/6 0x2f/slash 0x69/i 0x6e/n 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x73/s 0x69/i
22212 _string_47_increment_edi:
22213 0x11/imm32/alloc-id:fake:payload
22214
22215 0x10/imm32/size
22216 0x34/4 0x37/7 0x2f/slash 0x69/i 0x6e/n 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x64/d 0x69/i
22217 _string_48_decrement_eax:
22218 0x11/imm32/alloc-id:fake:payload
22219
22220 0x10/imm32/size
22221 0x34/4 0x38/8 0x2f/slash 0x64/d 0x65/e 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x61/a 0x78/x
22222 _string_49_decrement_ecx:
22223 0x11/imm32/alloc-id:fake:payload
22224
22225 0x10/imm32/size
22226 0x34/4 0x39/9 0x2f/slash 0x64/d 0x65/e 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x63/c 0x78/x
22227 _string_4a_decrement_edx:
22228 0x11/imm32/alloc-id:fake:payload
22229
22230 0x10/imm32/size
22231 0x34/4 0x61/a 0x2f/slash 0x64/d 0x65/e 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x64/d 0x78/x
22232 _string_4b_decrement_ebx:
22233 0x11/imm32/alloc-id:fake:payload
22234
22235 0x10/imm32/size
22236 0x34/4 0x62/b 0x2f/slash 0x64/d 0x65/e 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x62/b 0x78/x
22237 _string_4e_decrement_esi:
22238 0x11/imm32/alloc-id:fake:payload
22239
22240 0x10/imm32/size
22241 0x34/4 0x65/e 0x2f/slash 0x64/d 0x65/e 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x73/s 0x69/i
22242 _string_4f_decrement_edi:
22243 0x11/imm32/alloc-id:fake:payload
22244
22245 0x10/imm32/size
22246 0x34/4 0x66/f 0x2f/slash 0x64/d 0x65/e 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t 0x2d/dash 0x65/e 0x64/d 0x69/i
22247 _string_81_subop_add:
22248 0x11/imm32/alloc-id:fake:payload
22249
22250 0xe/imm32/size
22251 0x38/8 0x31/1 0x20/space 0x30/0 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x61/a 0x64/d 0x64/d
22252 _string_81_subop_or:
22253 0x11/imm32/alloc-id:fake:payload
22254
22255 0xd/imm32/size
22256 0x38/8 0x31/1 0x20/space 0x31/1 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x6f/o 0x72/r
22257 _string_81_subop_and:
22258 0x11/imm32/alloc-id:fake:payload
22259
22260 0xe/imm32/size
22261 0x38/8 0x31/1 0x20/space 0x34/4 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x61/a 0x6e/n 0x64/d
22262 _string_81_subop_subtract:
22263 0x11/imm32/alloc-id:fake:payload
22264
22265 0x13/imm32/size
22266 0x38/8 0x31/1 0x20/space 0x35/5 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x73/s 0x75/u 0x62/b 0x74/t 0x72/r 0x61/a 0x63/c 0x74/t
22267 _string_81_subop_xor:
22268 0x11/imm32/alloc-id:fake:payload
22269
22270 0xe/imm32/size
22271 0x38/8 0x31/1 0x20/space 0x36/6 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x78/x 0x6f/o 0x72/r
22272 _string_81_subop_compare:
22273 0x11/imm32/alloc-id:fake:payload
22274
22275 0x12/imm32/size
22276 0x38/8 0x31/1 0x20/space 0x37/7 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x63/c 0x6f/o 0x6d/m 0x70/p 0x61/a 0x72/r 0x65/e
22277 _string_89_<-:
22278 0x11/imm32/alloc-id:fake:payload
22279
22280 0x5/imm32/size
22281 0x38/8 0x39/9 0x2f/slash 0x3c/< 0x2d/dash
22282 _string_8b_->:
22283 0x11/imm32/alloc-id:fake:payload
22284
22285 0x5/imm32/size
22286 0x38/8 0x62/b 0x2f/slash 0x2d/dash 0x3e/>
22287 _string_8a_copy_byte:
22288 0x11/imm32/alloc-id:fake:payload
22289
22290 0x9/imm32/size
22291 0x38/8 0x61/a 0x2f// 0x62/b 0x79/y 0x74/t 0x65/e 0x2d/- 0x3e/>
22292 _string_88_copy_byte:
22293 0x11/imm32/alloc-id:fake:payload
22294
22295 0x9/imm32/size
22296 0x38/8 0x38/8 0x2f// 0x62/b 0x79/y 0x74/t 0x65/e 0x3c/< 0x2d/-
22297 _string_8d_copy_address:
22298 0x11/imm32/alloc-id:fake:payload
22299
22300 0xf/imm32/size
22301 0x38/8 0x64/d 0x2f/slash 0x63/c 0x6f/o 0x70/p 0x79/y 0x2d/dash 0x61/a 0x64/d 0x64/d 0x72/r 0x65/e 0x73/s 0x73/s
22302 _string_b8_copy_to_eax:
22303 0x11/imm32/alloc-id:fake:payload
22304
22305 0xe/imm32/size
22306 0x62/b 0x38/8 0x2f/slash 0x63/c 0x6f/o 0x70/p 0x79/y 0x2d/dash 0x74/t 0x6f/o 0x2d/dash 0x65/e 0x61/a 0x78/x
22307 _string_b9_copy_to_ecx:
22308 0x11/imm32/alloc-id:fake:payload
22309
22310 0xe/imm32/size
22311 0x62/b 0x39/9 0x2f/slash 0x63/c 0x6f/o 0x70/p 0x79/y 0x2d/dash 0x74/t 0x6f/o 0x2d/dash 0x65/e 0x63/c 0x78/x
22312 _string_ba_copy_to_edx:
22313 0x11/imm32/alloc-id:fake:payload
22314
22315 0xe/imm32/size
22316 0x62/b 0x61/a 0x2f/slash 0x63/c 0x6f/o 0x70/p 0x79/y 0x2d/dash 0x74/t 0x6f/o 0x2d/dash 0x65/e 0x64/d 0x78/x
22317 _string_bb_copy_to_ebx:
22318 0x11/imm32/alloc-id:fake:payload
22319
22320 0xe/imm32/size
22321 0x62/b 0x62/b 0x2f/slash 0x63/c 0x6f/o 0x70/p 0x79/y 0x2d/dash 0x74/t 0x6f/o 0x2d/dash 0x65/e 0x62/b 0x78/x
22322 _string_be_copy_to_esi:
22323 0x11/imm32/alloc-id:fake:payload
22324
22325 0xe/imm32/size
22326 0x62/b 0x65/e 0x2f/slash 0x63/c 0x6f/o 0x70/p 0x79/y 0x2d/dash 0x74/t 0x6f/o 0x2d/dash 0x65/e 0x73/s 0x69/i
22327 _string_bf_copy_to_edi:
22328 0x11/imm32/alloc-id:fake:payload
22329
22330 0xe/imm32/size
22331 0x62/b 0x66/f 0x2f/slash 0x63/c 0x6f/o 0x70/p 0x79/y 0x2d/dash 0x74/t 0x6f/o 0x2d/dash 0x65/e 0x64/d 0x69/i
22332 _string_c7_subop_copy:
22333 0x11/imm32/alloc-id:fake:payload
22334
22335 0xf/imm32/size
22336 0x63/c 0x37/7 0x20/space 0x30/0 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x63/c 0x6f/o 0x70/p 0x79/y
22337 _string_e9_jump_label:
22338 0x11/imm32/alloc-id:fake:payload
22339
22340 0x7/imm32/size
22341 0x65/e 0x39/9 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p
22342 _string_e9_jump_break:
22343 0x11/imm32/alloc-id:fake:payload
22344
22345 0x14/imm32/size
22346 0x65/e 0x39/9 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x20/space 0x62/b 0x72/r 0x65/e 0x61/a 0x6b/k 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
22347 _string_e9_jump_loop:
22348 0x11/imm32/alloc-id:fake:payload
22349
22350 0x13/imm32/size
22351 0x65/e 0x39/9 0x2f/slash 0x6a/j 0x75/u 0x6d/m 0x70/p 0x20/space 0x6c/l 0x6f/o 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x69/i 0x73/s 0x70/p 0x33/3 0x32/2
22352 _string_f7_subop_negate:
22353 0x11/imm32/alloc-id:fake:payload
22354
22355 0x11/imm32/size
22356 0x66/f 0x37/7 0x20/space 0x33/3 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x6e/n 0x65/e 0x67/g 0x61/a 0x74/t 0x65/e
22357 _string_ff_subop_increment:
22358 0x11/imm32/alloc-id:fake:payload
22359
22360 0x14/imm32/size
22361 0x66/f 0x66/f 0x20/space 0x30/0 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x69/i 0x6e/n 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t
22362 _string_ff_subop_decrement:
22363 0x11/imm32/alloc-id:fake:payload
22364
22365 0x14/imm32/size
22366 0x66/f 0x66/f 0x20/space 0x31/1 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x64/d 0x65/e 0x63/c 0x72/r 0x65/e 0x6d/m 0x65/e 0x6e/n 0x74/t
22367 _string_c1_subop_shift_left:
22368 0x11/imm32/alloc-id:fake:payload
22369
22370 0x15/imm32/size
22371 0x63/c 0x31/1 0x2f/slash 0x73/s 0x68/h 0x69/i 0x66/f 0x74/t 0x20/space 0x34/4 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x6c/l 0x65/e 0x66/f 0x74/t
22372 _string_c1_subop_shift_right_padding_zeroes:
22373 0x11/imm32/alloc-id:fake:payload
22374
22375 0x25/imm32/size
22376 0x63/c 0x31/1 0x2f/slash 0x73/s 0x68/h 0x69/i 0x66/f 0x74/t 0x20/space 0x35/5 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x72/r 0x69/i 0x67/g 0x68/h 0x74/t 0x2d/dash 0x70/p 0x61/a 0x64/d 0x64/d 0x69/i 0x6e/n 0x67/g 0x2d/dash 0x7a/z 0x65/e 0x72/r 0x6f/o 0x65/e 0x73/s
22377 _string_c1_subop_shift_right_preserving_sign:
22378 0x11/imm32/alloc-id:fake:payload
22379
22380 0x26/imm32/size
22381 0x63/c 0x31/1 0x2f/slash 0x73/s 0x68/h 0x69/i 0x66/f 0x74/t 0x20/space 0x37/7 0x2f/slash 0x73/s 0x75/u 0x62/b 0x6f/o 0x70/p 0x2f/slash 0x72/r 0x69/i 0x67/g 0x68/h 0x74/t 0x2d/dash 0x70/p 0x72/r 0x65/e 0x73/s 0x65/e 0x72/r 0x76/v 0x69/i 0x6e/n 0x67/g 0x2d/dash 0x73/s 0x69/i 0x67/g 0x6e/n
22382
22383 Single-int-var-in-mem:
22384 0x11/imm32/alloc-id:fake:payload
22385 0x11/imm32/alloc-id:fake
22386 Int-var-in-mem/imm32
22387 0/imm32/next
22388 0/imm32/next
22389
22390 Int-var-in-mem:
22391 0x11/imm32/alloc-id:fake:payload
22392 0/imm32/name
22393 0/imm32/name
22394 0x11/imm32/alloc-id:fake
22395 Type-int/imm32
22396 1/imm32/some-block-depth
22397 1/imm32/some-stack-offset
22398 0/imm32/no-register
22399 0/imm32/no-register
22400
22401
22402 Single-byte-var-in-mem:
22403 0x11/imm32/alloc-id:fake:payload
22404 0x11/imm32/alloc-id:fake
22405 Byte-var-in-mem/imm32
22406 0/imm32/next
22407 0/imm32/next
22408
22409
22410 Byte-var-in-mem:
22411 0x11/imm32/alloc-id:fake:payload
22412 0/imm32/name
22413 0/imm32/name
22414 0x11/imm32/alloc-id:fake
22415 Type-byte/imm32
22416 1/imm32/some-block-depth
22417 1/imm32/some-stack-offset
22418 0/imm32/no-register
22419 0/imm32/no-register
22420
22421 Two-args-int-stack-int-reg:
22422 0x11/imm32/alloc-id:fake:payload
22423 0x11/imm32/alloc-id:fake
22424 Int-var-in-mem/imm32
22425 0x11/imm32/alloc-id:fake
22426 Single-int-var-in-some-register/imm32/next
22427
22428 Two-int-args-in-regs:
22429 0x11/imm32/alloc-id:fake:payload
22430 0x11/imm32/alloc-id:fake
22431 Int-var-in-some-register/imm32
22432 0x11/imm32/alloc-id:fake
22433 Single-int-var-in-some-register/imm32/next
22434
22435
22436 Two-args-byte-stack-byte-reg:
22437 0x11/imm32/alloc-id:fake:payload
22438 0x11/imm32/alloc-id:fake
22439 Byte-var-in-mem/imm32
22440 0x11/imm32/alloc-id:fake
22441 Single-byte-var-in-some-register/imm32/next
22442
22443 Two-args-int-reg-int-stack:
22444 0x11/imm32/alloc-id:fake:payload
22445 0x11/imm32/alloc-id:fake
22446 Int-var-in-some-register/imm32
22447 0x11/imm32/alloc-id:fake
22448 Single-int-var-in-mem/imm32/next
22449
22450 Two-args-int-eax-int-literal:
22451 0x11/imm32/alloc-id:fake:payload
22452 0x11/imm32/alloc-id:fake
22453 Int-var-in-eax/imm32
22454 0x11/imm32/alloc-id:fake
22455 Single-lit-var/imm32/next
22456
22457 Int-var-and-literal:
22458 0x11/imm32/alloc-id:fake:payload
22459 0x11/imm32/alloc-id:fake
22460 Int-var-in-mem/imm32
22461 0x11/imm32/alloc-id:fake
22462 Single-lit-var/imm32/next
22463
22464 Int-var-in-register-and-literal:
22465 0x11/imm32/alloc-id:fake:payload
22466 0x11/imm32/alloc-id:fake
22467 Int-var-in-some-register/imm32
22468 0x11/imm32/alloc-id:fake
22469 Single-lit-var/imm32/next
22470
22471 Two-float-args-in-regs:
22472 0x11/imm32/alloc-id:fake:payload
22473 0x11/imm32/alloc-id:fake
22474 Float-var-in-some-register/imm32
22475 0x11/imm32/alloc-id:fake
22476 Single-float-var-in-some-register/imm32/next
22477
22478 Two-args-float-reg-float-stack:
22479 0x11/imm32/alloc-id:fake:payload
22480 0x11/imm32/alloc-id:fake
22481 Float-var-in-some-register/imm32
22482 0x11/imm32/alloc-id:fake
22483 Single-float-var-in-mem/imm32/next
22484
22485 Two-args-float-stack-float-reg:
22486 0x11/imm32/alloc-id:fake:payload
22487 0x11/imm32/alloc-id:fake
22488 Float-var-in-mem/imm32
22489 0x11/imm32/alloc-id:fake
22490 Single-float-var-in-some-register/imm32/next
22491
22492 Single-int-var-in-some-register:
22493 0x11/imm32/alloc-id:fake:payload
22494 0x11/imm32/alloc-id:fake
22495 Int-var-in-some-register/imm32
22496 0/imm32/next
22497 0/imm32/next
22498
22499 Single-addr-var-in-some-register:
22500 0x11/imm32/alloc-id:fake:payload
22501 0x11/imm32/alloc-id:fake
22502 Addr-var-in-some-register/imm32
22503 0/imm32/next
22504 0/imm32/next
22505
22506 Single-byte-var-in-some-register:
22507 0x11/imm32/alloc-id:fake:payload
22508 0x11/imm32/alloc-id:fake
22509 Byte-var-in-some-register/imm32
22510 0/imm32/next
22511 0/imm32/next
22512
22513 Int-var-in-some-register:
22514 0x11/imm32/alloc-id:fake:payload
22515 0/imm32/name
22516 0/imm32/name
22517 0x11/imm32/alloc-id:fake
22518 Type-int/imm32
22519 1/imm32/some-block-depth
22520 0/imm32/no-stack-offset
22521 0x11/imm32/alloc-id:fake
22522 Any-register/imm32
22523
22524 Any-register:
22525 0x11/imm32/alloc-id:fake:payload
22526 1/imm32/size
22527
22528 2a/asterisk
22529
22530 Addr-var-in-some-register:
22531 0x11/imm32/alloc-id:fake:payload
22532 0/imm32/name
22533 0/imm32/name
22534 0x11/imm32/alloc-id:fake
22535 Type-addr/imm32
22536 1/imm32/some-block-depth
22537 0/imm32/no-stack-offset
22538 0x11/imm32/alloc-id:fake
22539 Any-register/imm32
22540
22541 Byte-var-in-some-register:
22542 0x11/imm32/alloc-id:fake:payload
22543 0/imm32/name
22544 0/imm32/name
22545 0x11/imm32/alloc-id:fake
22546 Type-byte/imm32
22547 1/imm32/some-block-depth
22548 0/imm32/no-stack-offset
22549 0x11/imm32/alloc-id:fake
22550 Any-register/imm32
22551
22552 Single-int-var-in-eax:
22553 0x11/imm32/alloc-id:fake:payload
22554 0x11/imm32/alloc-id:fake
22555 Int-var-in-eax/imm32
22556 0/imm32/next
22557 0/imm32/next
22558
22559 Int-var-in-eax:
22560 0x11/imm32/alloc-id:fake:payload
22561 0/imm32/name
22562 0/imm32/name
22563 0x11/imm32/alloc-id:fake
22564 Type-int/imm32
22565 1/imm32/some-block-depth
22566 0/imm32/no-stack-offset
22567 0x11/imm32/alloc-id:fake
22568 $Register-eax/imm32
22569
22570 Single-int-var-in-ecx:
22571 0x11/imm32/alloc-id:fake:payload
22572 0x11/imm32/alloc-id:fake
22573 Int-var-in-ecx/imm32
22574 0/imm32/next
22575 0/imm32/next
22576
22577 Int-var-in-ecx:
22578 0x11/imm32/alloc-id:fake:payload
22579 0/imm32/name
22580 0/imm32/name
22581 0x11/imm32/alloc-id:fake
22582 Type-int/imm32
22583 1/imm32/some-block-depth
22584 0/imm32/no-stack-offset
22585 0x11/imm32/alloc-id:fake
22586 $Register-ecx/imm32/register
22587
22588 Single-int-var-in-edx:
22589 0x11/imm32/alloc-id:fake:payload
22590 0x11/imm32/alloc-id:fake
22591 Int-var-in-edx/imm32
22592 0/imm32/next
22593 0/imm32/next
22594
22595 Int-var-in-edx:
22596 0x11/imm32/alloc-id:fake:payload
22597 0/imm32/name
22598 0/imm32/name
22599 0x11/imm32/alloc-id:fake
22600 Type-int/imm32
22601 1/imm32/some-block-depth
22602 0/imm32/no-stack-offset
22603 0x11/imm32/alloc-id:fake
22604 $Register-edx/imm32/register
22605
22606 Single-int-var-in-ebx:
22607 0x11/imm32/alloc-id:fake:payload
22608 0x11/imm32/alloc-id:fake
22609 Int-var-in-ebx/imm32
22610 0/imm32/next
22611 0/imm32/next
22612
22613 Int-var-in-ebx:
22614 0x11/imm32/alloc-id:fake:payload
22615 0/imm32/name
22616 0/imm32/name
22617 0x11/imm32/alloc-id:fake
22618 Type-int/imm32
22619 1/imm32/some-block-depth
22620 0/imm32/no-stack-offset
22621 0x11/imm32/alloc-id:fake
22622 $Register-ebx/imm32/register
22623
22624 Single-int-var-in-esi:
22625 0x11/imm32/alloc-id:fake:payload
22626 0x11/imm32/alloc-id:fake
22627 Int-var-in-esi/imm32
22628 0/imm32/next
22629 0/imm32/next
22630
22631 Int-var-in-esi:
22632 0x11/imm32/alloc-id:fake:payload
22633 0/imm32/name
22634 0/imm32/name
22635 0x11/imm32/alloc-id:fake
22636 Type-int/imm32
22637 1/imm32/some-block-depth
22638 0/imm32/no-stack-offset
22639 0x11/imm32/alloc-id:fake
22640 $Register-esi/imm32/register
22641
22642 Single-int-var-in-edi:
22643 0x11/imm32/alloc-id:fake:payload
22644 0x11/imm32/alloc-id:fake
22645 Int-var-in-edi/imm32
22646 0/imm32/next
22647 0/imm32/next
22648
22649 Int-var-in-edi:
22650 0x11/imm32/alloc-id:fake:payload
22651 0/imm32/name
22652 0/imm32/name
22653 0x11/imm32/alloc-id:fake
22654 Type-int/imm32
22655 1/imm32/some-block-depth
22656 0/imm32/no-stack-offset
22657 0x11/imm32/alloc-id:fake
22658 $Register-edi/imm32/register
22659
22660 Single-lit-var:
22661 0x11/imm32/alloc-id:fake:payload
22662 0x11/imm32/alloc-id:fake
22663 Lit-var/imm32
22664 0/imm32/next
22665 0/imm32/next
22666
22667 Lit-var:
22668 0x11/imm32/alloc-id:fake:payload
22669 0/imm32/name
22670 0/imm32/name
22671 0x11/imm32/alloc-id:fake
22672 Type-literal/imm32
22673 1/imm32/some-block-depth
22674 0/imm32/no-stack-offset
22675 0/imm32/no-register
22676 0/imm32/no-register
22677
22678 Single-float-var-in-mem:
22679 0x11/imm32/alloc-id:fake:payload
22680 0x11/imm32/alloc-id:fake
22681 Float-var-in-mem/imm32
22682 0/imm32/next
22683 0/imm32/next
22684
22685 Float-var-in-mem:
22686 0x11/imm32/alloc-id:fake:payload
22687 0/imm32/name
22688 0/imm32/name
22689 0x11/imm32/alloc-id:fake
22690 Type-float/imm32
22691 1/imm32/some-block-depth
22692 1/imm32/some-stack-offset
22693 0/imm32/no-register
22694 0/imm32/no-register
22695
22696 Single-float-var-in-some-register:
22697 0x11/imm32/alloc-id:fake:payload
22698 0x11/imm32/alloc-id:fake
22699 Float-var-in-some-register/imm32
22700 0/imm32/next
22701 0/imm32/next
22702
22703 Float-var-in-some-register:
22704 0x11/imm32/alloc-id:fake:payload
22705 0/imm32/name
22706 0/imm32/name
22707 0x11/imm32/alloc-id:fake
22708 Type-float/imm32
22709 1/imm32/some-block-depth
22710 0/imm32/no-stack-offset
22711 0x11/imm32/alloc-id:fake
22712 Any-register/imm32
22713
22714 Type-int:
22715 0x11/imm32/alloc-id:fake:payload
22716 1/imm32/is-atom
22717 1/imm32/value:int
22718 0/imm32/left:unused
22719 0/imm32/right:null
22720 0/imm32/right:null
22721
22722 Type-literal:
22723 0x11/imm32/alloc-id:fake:payload
22724 1/imm32/is-atom
22725 0/imm32/value:literal
22726 0/imm32/left:unused
22727 0/imm32/right:null
22728 0/imm32/right:null
22729
22730 Type-addr:
22731 0x11/imm32/alloc-id:fake:payload
22732 1/imm32/is-atom
22733 2/imm32/value:addr
22734 0/imm32/left:unused
22735 0/imm32/right:null
22736 0/imm32/right:null
22737
22738 Type-byte:
22739 0x11/imm32/alloc-id:fake:payload
22740 1/imm32/is-atom
22741 8/imm32/value:byte
22742 0/imm32/left:unused
22743 0/imm32/right:null
22744 0/imm32/right:null
22745
22746 Type-float:
22747 0x11/imm32/alloc-id:fake:payload
22748 1/imm32/is-atom
22749 0xf/imm32/value:float
22750 0/imm32/left:unused
22751 0/imm32/right:null
22752 0/imm32/right:null
22753
22754 == code
22755 emit-subx-primitive:
22756
22757 55/push-ebp
22758 89/<- %ebp 4/r32/esp
22759
22760 50/push-eax
22761 51/push-ecx
22762
22763 8b/-> *(ebp+0x10) 1/r32/ecx
22764
22765 (emit-indent *(ebp+8) *Curr-block-depth)
22766 (lookup *(ecx+0x18) *(ecx+0x1c))
22767 (write-buffered *(ebp+8) %eax)
22768
22769 (emit-subx-rm32 *(ebp+8) *(ecx+0x20) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
22770
22771 (emit-subx-rm32 *(ebp+8) *(ecx+0x34) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
22772
22773 (emit-subx-r32 *(ebp+8) *(ecx+0x24) *(ebp+0xc))
22774
22775 (emit-subx-x32 *(ebp+8) *(ecx+0x38) *(ebp+0xc))
22776
22777 (emit-subx-imm32 *(ebp+8) *(ecx+0x28) *(ebp+0xc))
22778
22779 (emit-subx-imm8 *(ebp+8) *(ecx+0x2c) *(ebp+0xc))
22780
22781 (emit-subx-disp32 *(ebp+8) *(ecx+0x30) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
22782 (write-buffered *(ebp+8) Newline)
22783 $emit-subx-primitive:end:
22784
22785 59/pop-to-ecx
22786 58/pop-to-eax
22787
22788 89/<- %esp 5/r32/ebp
22789 5d/pop-to-ebp
22790 c3/return
22791
22792 emit-subx-rm32:
22793
22794 55/push-ebp
22795 89/<- %ebp 4/r32/esp
22796
22797 50/push-eax
22798
22799 81 7/subop/compare *(ebp+0xc) 0/imm32
22800 74/jump-if-= $emit-subx-rm32:end/disp8
22801
22802 (get-stmt-operand-from-arg-location *(ebp+0x10) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
22803 (emit-subx-var-as-rm32 *(ebp+8) %eax)
22804 $emit-subx-rm32:end:
22805
22806 58/pop-to-eax
22807
22808 89/<- %esp 5/r32/ebp
22809 5d/pop-to-ebp
22810 c3/return
22811
22812 get-stmt-operand-from-arg-location:
22813
22814 55/push-ebp
22815 89/<- %ebp 4/r32/esp
22816
22817 51/push-ecx
22818
22819 8b/-> *(ebp+0xc) 0/r32/eax
22820
22821 8b/-> *(ebp+8) 1/r32/ecx
22822
22823 {
22824 3d/compare-eax-and 1/imm32
22825 75/jump-if-!= break/disp8
22826 $get-stmt-operand-from-arg-location:1:
22827 (lookup *(ecx+0xc) *(ecx+0x10))
22828 eb/jump $get-stmt-operand-from-arg-location:end/disp8
22829 }
22830
22831 {
22832 3d/compare-eax-and 2/imm32
22833 75/jump-if-!= break/disp8
22834 $get-stmt-operand-from-arg-location:2:
22835 (lookup *(ecx+0xc) *(ecx+0x10))
22836 (lookup *(eax+8) *(eax+0xc))
22837 eb/jump $get-stmt-operand-from-arg-location:end/disp8
22838 }
22839
22840 {
22841 3d/compare-eax-and 3/imm32
22842 75/jump-if-!= break/disp8
22843 $get-stmt-operand-from-arg-location:3:
22844 (lookup *(ecx+0x14) *(ecx+0x18))
22845 eb/jump $get-stmt-operand-from-arg-location:end/disp8
22846 }
22847
22848 e9/jump $get-stmt-operand-from-arg-location:abort/disp32
22849 $get-stmt-operand-from-arg-location:end:
22850
22851 59/pop-to-ecx
22852
22853 89/<- %esp 5/r32/ebp
22854 5d/pop-to-ebp
22855 c3/return
22856
22857 $get-stmt-operand-from-arg-location:abort:
22858
22859 (write-buffered *(ebp+0x10) "invalid arg-location ")
22860 (write-int32-hex-buffered *(ebp+0x10) %eax)
22861 (write-buffered *(ebp+0x10) Newline)
22862 (flush *(ebp+0x10))
22863 (stop *(ebp+0x14) 1)
22864
22865
22866 emit-subx-r32:
22867
22868 55/push-ebp
22869 89/<- %ebp 4/r32/esp
22870
22871 50/push-eax
22872 51/push-ecx
22873
22874 81 7/subop/compare *(ebp+0xc) 0/imm32
22875 0f 84/jump-if-= $emit-subx-r32:end/disp32
22876
22877 (get-stmt-operand-from-arg-location *(ebp+0x10) *(ebp+0xc))
22878 (lookup *eax *(eax+4))
22879 (lookup *(eax+0x18) *(eax+0x1c))
22880
22881
22882
22883
22884 (maybe-get Mu-registers %eax 0xc)
22885 (write-buffered *(ebp+8) Space)
22886 (write-int32-hex-buffered *(ebp+8) *eax)
22887 (write-buffered *(ebp+8) "/r32")
22888 $emit-subx-r32:end:
22889
22890 59/pop-to-ecx
22891 58/pop-to-eax
22892
22893 89/<- %esp 5/r32/ebp
22894 5d/pop-to-ebp
22895 c3/return
22896
22897 emit-subx-x32:
22898
22899 55/push-ebp
22900 89/<- %ebp 4/r32/esp
22901
22902 50/push-eax
22903 51/push-ecx
22904
22905 81 7/subop/compare *(ebp+0xc) 0/imm32
22906 0f 84/jump-if-= $emit-subx-x32:end/disp32
22907
22908 (get-stmt-operand-from-arg-location *(ebp+0x10) *(ebp+0xc))
22909 (lookup *eax *(eax+4))
22910 (lookup *(eax+0x18) *(eax+0x1c))
22911
22912
22913
22914
22915 (maybe-get Mu-registers %eax 0xc)
22916 (write-buffered *(ebp+8) Space)
22917 (write-int32-hex-buffered *(ebp+8) *eax)
22918 (write-buffered *(ebp+8) "/x32")
22919 $emit-subx-x32:end:
22920
22921 59/pop-to-ecx
22922 58/pop-to-eax
22923
22924 89/<- %esp 5/r32/ebp
22925 5d/pop-to-ebp
22926 c3/return
22927
22928 emit-subx-imm32:
22929
22930 55/push-ebp
22931 89/<- %ebp 4/r32/esp
22932
22933 50/push-eax
22934 51/push-ecx
22935
22936 81 7/subop/compare *(ebp+0xc) 0/imm32
22937 0f 84/jump-if-= $emit-subx-imm32:end/disp32
22938
22939 (get-stmt-operand-from-arg-location *(ebp+0x10) *(ebp+0xc))
22940 (lookup *eax *(eax+4))
22941 (lookup *eax *(eax+4))
22942 (write-buffered *(ebp+8) Space)
22943 (write-buffered *(ebp+8) %eax)
22944 (write-buffered *(ebp+8) "/imm32")
22945 $emit-subx-imm32:end:
22946
22947 59/pop-to-ecx
22948 58/pop-to-eax
22949
22950 89/<- %esp 5/r32/ebp
22951 5d/pop-to-ebp
22952 c3/return
22953
22954 emit-subx-imm8:
22955
22956 55/push-ebp
22957 89/<- %ebp 4/r32/esp
22958
22959 50/push-eax
22960 51/push-ecx
22961
22962 81 7/subop/compare *(ebp+0xc) 0/imm32
22963 0f 84/jump-if-= $emit-subx-imm32:end/disp32
22964
22965 (get-stmt-operand-from-arg-location *(ebp+0x10) *(ebp+0xc))
22966 (lookup *eax *(eax+4))
22967 (lookup *eax *(eax+4))
22968 (write-buffered *(ebp+8) Space)
22969 (write-buffered *(ebp+8) %eax)
22970 (write-buffered *(ebp+8) "/imm8")
22971 $emit-subx-imm8:end:
22972
22973 59/pop-to-ecx
22974 58/pop-to-eax
22975
22976 89/<- %esp 5/r32/ebp
22977 5d/pop-to-ebp
22978 c3/return
22979
22980 emit-subx-disp32:
22981
22982 55/push-ebp
22983 89/<- %ebp 4/r32/esp
22984
22985 50/push-eax
22986 51/push-ecx
22987
22988 81 7/subop/compare *(ebp+0xc) 0/imm32
22989 0f 84/jump-if-= $emit-subx-disp32:end/disp32
22990
22991 (get-stmt-operand-from-arg-location *(ebp+0x10) *(ebp+0xc) *(ebp+0x14) *(ebp+0x18))
22992 (lookup *eax *(eax+4))
22993 (lookup *eax *(eax+4))
22994 (write-buffered *(ebp+8) Space)
22995 (write-buffered *(ebp+8) %eax)
22996
22997
22998 8b/-> *(ebp+0x10) 0/r32/eax
22999 (lookup *(eax+4) *(eax+8))
23000 89/<- %ecx 0/r32/eax
23001 {
23002 (string-starts-with? %ecx "break")
23003 3d/compare-eax-and 0/imm32/false
23004 74/jump-if-= break/disp8
23005 (write-buffered *(ebp+8) ":break")
23006 }
23007
23008 {
23009 (string-starts-with? %ecx "loop")
23010 3d/compare-eax-and 0/imm32/false
23011 74/jump-if-= break/disp8
23012 (write-buffered *(ebp+8) ":loop")
23013 }
23014 (write-buffered *(ebp+8) "/disp32")
23015 $emit-subx-disp32:end:
23016
23017 59/pop-to-ecx
23018 58/pop-to-eax
23019
23020 89/<- %esp 5/r32/ebp
23021 5d/pop-to-ebp
23022 c3/return
23023
23024 emit-call:
23025
23026 55/push-ebp
23027 89/<- %ebp 4/r32/esp
23028
23029 50/push-eax
23030 51/push-ecx
23031
23032 (emit-indent *(ebp+8) *Curr-block-depth)
23033 (write-buffered *(ebp+8) "(")
23034
23035 8b/-> *(ebp+0xc) 1/r32/ecx
23036
23037 (lookup *(ecx+4) *(ecx+8))
23038 (write-buffered *(ebp+8) %eax)
23039
23040
23041 (lookup *(ecx+0xc) *(ecx+0x10))
23042 {
23043
23044 3d/compare-eax-and 0/imm32
23045 74/jump-if-= break/disp8
23046
23047 (emit-subx-call-operand *(ebp+8) %eax)
23048
23049 (lookup *(eax+8) *(eax+0xc))
23050 eb/jump loop/disp8
23051 }
23052
23053 (write-buffered *(ebp+8) ")\n")
23054 $emit-call:end:
23055
23056 59/pop-to-ecx
23057 58/pop-to-eax
23058
23059 89/<- %esp 5/r32/ebp
23060 5d/pop-to-ebp
23061 c3/return
23062
23063 emit-subx-call-operand:
23064
23065
23066 55/push-ebp
23067 89/<- %ebp 4/r32/esp
23068
23069 50/push-eax
23070 51/push-ecx
23071 56/push-esi
23072
23073 8b/-> *(ebp+0xc) 1/r32/ecx
23074
23075 (lookup *ecx *(ecx+4))
23076 89/<- %esi 0/r32/eax
23077
23078 {
23079 $emit-subx-call-operand:check-for-register-direct:
23080 81 7/subop/compare *(esi+0x18) 0/imm32
23081 74/jump-if-= break/disp8
23082 81 7/subop/compare *(ecx+0x10) 0/imm32/false
23083 75/jump-if-!= break/disp8
23084 $emit-subx-call-operand:register-direct:
23085 (write-buffered *(ebp+8) " %")
23086 (lookup *(esi+0x18) *(esi+0x1c))
23087 (write-buffered *(ebp+8) %eax)
23088 e9/jump $emit-subx-call-operand:end/disp32
23089 }
23090
23091 {
23092 $emit-subx-call-operand:check-for-register-indirect:
23093 81 7/subop/compare *(esi+0x18) 0/imm32
23094 74/jump-if-= break/disp8
23095 81 7/subop/compare *(ecx+0x10) 0/imm32/false
23096 74/jump-if-= break/disp8
23097 $emit-subx-call-operand:register-indirect:
23098 (emit-subx-call-operand-register-indirect *(ebp+8) %esi)
23099 e9/jump $emit-subx-call-operand:end/disp32
23100 }
23101
23102 {
23103 81 7/subop/compare *(esi+0x14) 0/imm32
23104 74/jump-if-= break/disp8
23105 $emit-subx-call-operand:stack:
23106 (emit-subx-call-operand-stack *(ebp+8) %esi)
23107 e9/jump $emit-subx-call-operand:end/disp32
23108 }
23109
23110 {
23111 (lookup *(esi+8) *(esi+0xc))
23112 81 7/subop/compare *(eax+4) 0/imm32
23113 75/jump-if-!= break/disp8
23114 $emit-subx-call-operand:literal:
23115 (write-buffered *(ebp+8) Space)
23116 (lookup *esi *(esi+4))
23117 (write-buffered *(ebp+8) %eax)
23118 }
23119 $emit-subx-call-operand:end:
23120
23121 5e/pop-to-esi
23122 59/pop-to-ecx
23123 58/pop-to-eax
23124
23125 89/<- %esp 5/r32/ebp
23126 5d/pop-to-ebp
23127 c3/return
23128
23129 emit-subx-call-operand-register-indirect:
23130
23131 55/push-ebp
23132 89/<- %ebp 4/r32/esp
23133
23134 50/push-eax
23135 51/push-ecx
23136 56/push-esi
23137
23138 8b/-> *(ebp+0xc) 6/r32/esi
23139
23140 (size-of-deref %esi)
23141 89/<- %ecx 0/r32/eax
23142
23143 (lookup *(esi+0x18) *(esi+0x1c))
23144 89/<- %esi 0/r32/eax
23145
23146
23147 b8/copy-to-eax 0/imm32
23148 {
23149 $emit-subx-call-operand-register-indirect:loop:
23150
23151 39/compare %eax 1/r32/ecx
23152 7d/jump-if->= break/disp8
23153
23154 (write-buffered *(ebp+8) " *(")
23155 (write-buffered *(ebp+8) %esi)
23156 (write-buffered *(ebp+8) "+")
23157 (write-int32-hex-buffered *(ebp+8) %eax)
23158 (write-buffered *(ebp+8) ")")
23159
23160 05/add-to-eax 4/imm32
23161
23162 eb/jump loop/disp8
23163 }
23164 $emit-subx-call-operand-register-indirect:end:
23165
23166 5e/pop-to-esi
23167 59/pop-to-ecx
23168 58/pop-to-eax
23169
23170 89/<- %esp 5/r32/ebp
23171 5d/pop-to-ebp
23172 c3/return
23173
23174 emit-subx-call-operand-stack:
23175
23176 55/push-ebp
23177 89/<- %ebp 4/r32/esp
23178
23179 50/push-eax
23180 51/push-ecx
23181 56/push-esi
23182
23183 8b/-> *(ebp+0xc) 6/r32/esi
23184
23185 8b/-> *(esi+0x14) 1/r32/ecx
23186
23187 (size-of %esi)
23188
23189 01/add-to %eax 1/r32/ecx
23190 {
23191 $emit-subx-call-operand-stack:loop:
23192
23193 39/compare %ecx 0/r32/eax
23194 7d/jump-if->= break/disp8
23195
23196 (write-buffered *(ebp+8) " *(ebp+")
23197 (write-int32-hex-buffered *(ebp+8) %ecx)
23198 (write-buffered *(ebp+8) ")")
23199
23200 81 0/subop/add %ecx 4/imm32
23201
23202 eb/jump loop/disp8
23203 }
23204 $emit-subx-call-operand-stack:end:
23205
23206 5e/pop-to-esi
23207 59/pop-to-ecx
23208 58/pop-to-eax
23209
23210 89/<- %esp 5/r32/ebp
23211 5d/pop-to-ebp
23212 c3/return
23213
23214 emit-subx-var-as-rm32:
23215
23216 55/push-ebp
23217 89/<- %ebp 4/r32/esp
23218
23219 50/push-eax
23220 51/push-ecx
23221 56/push-esi
23222
23223 8b/-> *(ebp+0xc) 1/r32/ecx
23224
23225 (lookup *ecx *(ecx+4))
23226 89/<- %esi 0/r32/eax
23227
23228 {
23229 $emit-subx-var-as-rm32:check-for-register-indirect:
23230 81 7/subop/compare *(esi+0x18) 0/imm32
23231 74/jump-if-= break/disp8
23232 81 7/subop/compare *(ecx+0x10) 0/imm32/false
23233 74/jump-if-= break/disp8
23234 $emit-subx-var-as-rm32:register-indirect:
23235 (write-buffered *(ebp+8) " *")
23236 (lookup *(esi+0x18) *(esi+0x1c))
23237 (write-buffered *(ebp+8) %eax)
23238 e9/jump $emit-subx-var-as-rm32:end/disp32
23239 }
23240
23241 {
23242 $emit-subx-var-as-rm32:check-for-register-direct:
23243 81 7/subop/compare *(esi+0x18) 0/imm32
23244 74/jump-if-= break/disp8
23245 81 7/subop/compare *(ecx+0x10) 0/imm32/false
23246 75/jump-if-!= break/disp8
23247 $emit-subx-var-as-rm32:register-direct:
23248 (write-buffered *(ebp+8) " %")
23249 (lookup *(esi+0x18) *(esi+0x1c))
23250 (write-buffered *(ebp+8) %eax)
23251 e9/jump $emit-subx-var-as-rm32:end/disp32
23252 }
23253
23254 {
23255 81 7/subop/compare *(esi+0x14) 0/imm32
23256 74/jump-if-= break/disp8
23257 $emit-subx-var-as-rm32:stack:
23258 (write-buffered *(ebp+8) Space)
23259 (write-buffered *(ebp+8) "*(ebp+")
23260 (write-int32-hex-buffered *(ebp+8) *(esi+0x14))
23261 (write-buffered *(ebp+8) ")")
23262 }
23263 $emit-subx-var-as-rm32:end:
23264
23265 5e/pop-to-esi
23266 59/pop-to-ecx
23267 58/pop-to-eax
23268
23269 89/<- %esp 5/r32/ebp
23270 5d/pop-to-ebp
23271 c3/return
23272
23273 find-matching-primitive:
23274
23275 55/push-ebp
23276 89/<- %ebp 4/r32/esp
23277
23278 51/push-ecx
23279
23280 8b/-> *(ebp+8) 1/r32/ecx
23281 {
23282 $find-matching-primitive:loop:
23283
23284 81 7/subop/compare %ecx 0/imm32
23285 74/jump-if-= break/disp8
23286
23287 {
23288 (mu-stmt-matches-primitive? *(ebp+0xc) %ecx)
23289 3d/compare-eax-and 0/imm32/false
23290 74/jump-if-= break/disp8
23291 89/<- %eax 1/r32/ecx
23292 eb/jump $find-matching-primitive:end/disp8
23293 }
23294 $find-matching-primitive:next-primitive:
23295
23296 (lookup *(ecx+0x3c) *(ecx+0x40))
23297 89/<- %ecx 0/r32/eax
23298
23299 e9/jump loop/disp32
23300 }
23301
23302 b8/copy-to-eax 0/imm32
23303 $find-matching-primitive:end:
23304
23305 59/pop-to-ecx
23306
23307 89/<- %esp 5/r32/ebp
23308 5d/pop-to-ebp
23309 c3/return
23310
23311 mu-stmt-matches-primitive?:
23312
23313
23314
23315
23316
23317
23318 55/push-ebp
23319 89/<- %ebp 4/r32/esp
23320
23321 51/push-ecx
23322 52/push-edx
23323 53/push-ebx
23324 56/push-esi
23325 57/push-edi
23326
23327 8b/-> *(ebp+8) 1/r32/ecx
23328
23329 8b/-> *(ebp+0xc) 2/r32/edx
23330 {
23331 $mu-stmt-matches-primitive?:check-name:
23332
23333
23334 (lookup *(ecx+4) *(ecx+8))
23335 89/<- %esi 0/r32/eax
23336
23337 (lookup *edx *(edx+4))
23338
23339
23340
23341 89/<- %edi 0/r32/eax
23342 (string-equal? %esi %edi)
23343 3d/compare-eax-and 0/imm32/false
23344 75/jump-if-!= break/disp8
23345 b8/copy-to-eax 0/imm32
23346 e9/jump $mu-stmt-matches-primitive?:end/disp32
23347 }
23348
23349 (lookup *(ecx+0xc) *(ecx+0x10))
23350 89/<- %esi 0/r32/eax
23351
23352 (lookup *(edx+8) *(edx+0xc))
23353 89/<- %edi 0/r32/eax
23354 {
23355 $mu-stmt-matches-primitive?:inouts-loop:
23356
23357 {
23358 $mu-stmt-matches-primitive?:check-both-inouts-null:
23359 81 7/subop/compare %esi 0/imm32
23360 75/jump-if-!= break/disp8
23361 $mu-stmt-matches-primitive?:stmt-inout-null:
23362 81 7/subop/compare %edi 0/imm32
23363 0f 84/jump-if-= $mu-stmt-matches-primitive?:check-outputs/disp32
23364 $mu-stmt-matches-primitive?:stmt-inout-null-and-prim-inout-not-null:
23365
23366 b8/copy-to-eax 0/imm32/false
23367 e9/jump $mu-stmt-matches-primitive?:end/disp32
23368 }
23369
23370 {
23371 $mu-stmt-matches-primitive?:check-prim-inout-null:
23372 81 7/subop/compare %edi 0/imm32
23373 75/jump-if-!= break/disp8
23374 $mu-stmt-matches-primitive?:prim-inout-null:
23375 b8/copy-to-eax 0/imm32/false
23376 e9/jump $mu-stmt-matches-primitive?:end/disp32
23377 }
23378
23379 {
23380 $mu-stmt-matches-primitive?:check-inouts-match:
23381 (lookup *edi *(edi+4))
23382 (operand-matches-primitive? %esi %eax)
23383 3d/compare-eax-and 0/imm32/false
23384 75/jump-if-!= break/disp8
23385 $mu-stmt-matches-primitive?:inouts-match:
23386 b8/copy-to-eax 0/imm32/false
23387 e9/jump $mu-stmt-matches-primitive?:end/disp32
23388 }
23389 $mu-stmt-matches-primitive?:next-inout:
23390
23391 (lookup *(esi+8) *(esi+0xc))
23392 89/<- %esi 0/r32/eax
23393
23394 (lookup *(edi+8) *(edi+0xc))
23395 89/<- %edi 0/r32/eax
23396
23397 e9/jump loop/disp32
23398 }
23399 $mu-stmt-matches-primitive?:check-outputs:
23400
23401 (lookup *(ecx+0x14) *(ecx+0x18))
23402 89/<- %esi 0/r32/eax
23403
23404 (lookup *(edx+0x10) *(edx+0x14))
23405 89/<- %edi 0/r32/eax
23406 {
23407 $mu-stmt-matches-primitive?:outputs-loop:
23408
23409 {
23410 $mu-stmt-matches-primitive?:check-both-outputs-null:
23411 81 7/subop/compare %esi 0/imm32
23412 75/jump-if-!= break/disp8
23413 {
23414 $mu-stmt-matches-primitive?:stmt-output-null:
23415 81 7/subop/compare %edi 0/imm32
23416 75/jump-if-!= break/disp8
23417 $mu-stmt-matches-primitive?:both-outputs-null:
23418
23419 b8/copy-to-eax 1/imm32
23420 e9/jump $mu-stmt-matches-primitive?:end/disp32
23421 }
23422 $mu-stmt-matches-primitive?:stmt-output-null-and-prim-output-not-null:
23423
23424 b8/copy-to-eax 0/imm32
23425 e9/jump $mu-stmt-matches-primitive?:end/disp32
23426 }
23427
23428 {
23429 $mu-stmt-matches-primitive?:check-prim-output-null:
23430 81 7/subop/compare %edi 0/imm32
23431 75/jump-if-!= break/disp8
23432 $mu-stmt-matches-primitive?:prim-output-is-null:
23433 b8/copy-to-eax 0/imm32
23434 e9/jump $mu-stmt-matches-primitive?:end/disp32
23435 }
23436
23437 {
23438 $mu-stmt-matches-primitive?:check-outputs-match:
23439 (lookup *edi *(edi+4))
23440 (operand-matches-primitive? %esi %eax)
23441 3d/compare-eax-and 0/imm32/false
23442 75/jump-if-!= break/disp8
23443 $mu-stmt-matches-primitive?:outputs-match:
23444 b8/copy-to-eax 0/imm32
23445 e9/jump $mu-stmt-matches-primitive?:end/disp32
23446 }
23447 $mu-stmt-matches-primitive?:next-output:
23448
23449 (lookup *(esi+8) *(esi+0xc))
23450 89/<- %esi 0/r32/eax
23451
23452 (lookup *(edi+8) *(edi+0xc))
23453 89/<- %edi 0/r32/eax
23454
23455 e9/jump loop/disp32
23456 }
23457 $mu-stmt-matches-primitive?:return-true:
23458 b8/copy-to-eax 1/imm32
23459 $mu-stmt-matches-primitive?:end:
23460
23461 5f/pop-to-edi
23462 5e/pop-to-esi
23463 5b/pop-to-ebx
23464 5a/pop-to-edx
23465 59/pop-to-ecx
23466
23467 89/<- %esp 5/r32/ebp
23468 5d/pop-to-ebp
23469 c3/return
23470
23471 operand-matches-primitive?:
23472
23473 55/push-ebp
23474 89/<- %ebp 4/r32/esp
23475
23476 51/push-ecx
23477 52/push-edx
23478 53/push-ebx
23479 56/push-esi
23480 57/push-edi
23481
23482 8b/-> *(ebp+8) 1/r32/ecx
23483
23484 (lookup *ecx *(ecx+4))
23485 89/<- %esi 0/r32/eax
23486
23487 8b/-> *(ebp+0xc) 7/r32/edi
23488 $operand-matches-primitive?:check-type:
23489
23490
23491 (lookup *(esi+8) *(esi+0xc))
23492 89/<- %ebx 0/r32/eax
23493
23494 {
23495 81 7/subop/compare *(ecx+0x10) 0/imm32/false
23496 74/jump-if-= break/disp8
23497 $operand-matches-primitive?:is-deref:
23498
23499 (lookup *(ebx+0xc) *(ebx+0x10))
23500
23501 81 7/subop/compare *eax 0/imm32/false
23502 {
23503 75/jump-if-!= break/disp8
23504 (lookup *(eax+4) *(eax+8))
23505 }
23506
23507 89/<- %ebx 0/r32/eax
23508 }
23509
23510 (lookup *(edi+8) *(edi+0xc))
23511 (subx-type-category-match? %ebx %eax)
23512 3d/compare-eax-and 0/imm32/false
23513 0f 84/jump-if-= $operand-matches-primitive?:return-false/disp32
23514 {
23515 $operand-matches-primitive?:check-register:
23516
23517 {
23518 81 7/subop/compare *(edi+0x18) 0/imm32
23519 0f 85/jump-if-!= break/disp32
23520 81 7/subop/compare *(esi+0x18) 0/imm32
23521 74/jump-if-= break/disp8
23522 81 7/subop/compare *(ecx+0x10) 0/imm32/false
23523 74/jump-if-= break/disp8
23524 $operand-matches-primitive?:var-deref-match:
23525 e9/jump $operand-matches-primitive?:return-true/disp32
23526 }
23527
23528 {
23529 81 7/subop/compare *(edi+0x18) 0/imm32
23530 0f 84/jump-if-= break/disp32
23531 81 7/subop/compare *(esi+0x18) 0/imm32
23532 0f 84/jump-if-= break/disp32
23533 81 7/subop/compare *(ecx+0x10) 0/imm32/false
23534 74/jump-if-= break/disp8
23535 $operand-matches-primitive?:var-deref-no-match:
23536 e9/jump $operand-matches-primitive?:return-false/disp32
23537 }
23538
23539 {
23540
23541
23542 (lookup *(esi+0x18) *(esi+0x1c))
23543 89/<- %ebx 0/r32/eax
23544
23545 (lookup *(edi+0x18) *(edi+0x1c))
23546 89/<- %ecx 0/r32/eax
23547
23548 39/compare %ecx 3/r32/ebx
23549 74/jump-if-= break/disp8
23550 $operand-matches-primitive?:var-register-no-match:
23551
23552 81 7/subop/compare %ebx 0/imm32
23553 74/jump-if-= $operand-matches-primitive?:return-false/disp8
23554 81 7/subop/compare %ecx 0/imm32
23555 74/jump-if-= $operand-matches-primitive?:return-false/disp8
23556
23557 (string-equal? %ecx "*")
23558 3d/compare-eax-and 0/imm32/false
23559 75/jump-if-!= break/disp8
23560 $operand-matches-primitive?:wildcard-no-match:
23561
23562 (string-equal? %ecx %ebx)
23563 3d/compare-eax-and 0/imm32/false
23564 74/jump-if-= $operand-matches-primitive?:return-false/disp8
23565 }
23566 }
23567 $operand-matches-primitive?:return-true:
23568 b8/copy-to-eax 1/imm32/true
23569 eb/jump $operand-matches-primitive?:end/disp8
23570 $operand-matches-primitive?:return-false:
23571 b8/copy-to-eax 0/imm32/false
23572 $operand-matches-primitive?:end:
23573
23574 5f/pop-to-edi
23575 5e/pop-to-esi
23576 5b/pop-to-ebx
23577 5a/pop-to-edx
23578 59/pop-to-ecx
23579
23580 89/<- %esp 5/r32/ebp
23581 5d/pop-to-ebp
23582 c3/return
23583
23584 find-matching-function:
23585
23586 55/push-ebp
23587 89/<- %ebp 4/r32/esp
23588
23589 51/push-ecx
23590
23591 8b/-> *(ebp+8) 1/r32/ecx
23592 {
23593
23594 81 7/subop/compare %ecx 0/imm32
23595 74/jump-if-= break/disp8
23596
23597
23598
23599 {
23600 (mu-stmt-matches-function? *(ebp+0xc) %ecx)
23601 3d/compare-eax-and 0/imm32/false
23602 74/jump-if-= break/disp8
23603 89/<- %eax 1/r32/ecx
23604 eb/jump $find-matching-function:end/disp8
23605 }
23606
23607 (lookup *(ecx+0x20) *(ecx+0x24))
23608 89/<- %ecx 0/r32/eax
23609
23610 eb/jump loop/disp8
23611 }
23612
23613 b8/copy-to-eax 0/imm32
23614 $find-matching-function:end:
23615
23616 59/pop-to-ecx
23617
23618 89/<- %esp 5/r32/ebp
23619 5d/pop-to-ebp
23620 c3/return
23621
23622
23623 mu-stmt-matches-function?:
23624
23625 55/push-ebp
23626 89/<- %ebp 4/r32/esp
23627
23628 51/push-ecx
23629
23630
23631 8b/-> *(ebp+8) 0/r32/eax
23632 (lookup *(eax+4) *(eax+8))
23633 89/<- %ecx 0/r32/eax
23634
23635 8b/-> *(ebp+0xc) 0/r32/eax
23636 (lookup *eax *(eax+4))
23637 (string-equal? %eax %ecx)
23638 $mu-stmt-matches-function?:end:
23639
23640 59/pop-to-ecx
23641
23642 89/<- %esp 5/r32/ebp
23643 5d/pop-to-ebp
23644 c3/return
23645
23646
23647
23648 subx-type-category-match?:
23649
23650 55/push-ebp
23651 89/<- %ebp 4/r32/esp
23652
23653 51/push-ecx
23654
23655 (type-category *(ebp+8))
23656 89/<- %ecx 0/r32/eax
23657
23658 (type-category *(ebp+0xc))
23659
23660 39/compare %eax 1/r32/ecx
23661 0f 94/set-byte-if-= %al
23662 81 4/subop/and %eax 0xff/imm32
23663 $subx-type-category-match?:end:
23664
23665 59/pop-to-ecx
23666
23667 89/<- %esp 5/r32/ebp
23668 5d/pop-to-ebp
23669 c3/return
23670
23671 type-category:
23672
23673 55/push-ebp
23674 89/<- %ebp 4/r32/esp
23675
23676 51/push-ecx
23677
23678 (is-simple-mu-type? *(ebp+8) 0)
23679 89/<- %ecx 0/r32/eax
23680
23681 (is-simple-mu-type? *(ebp+8) 0xf)
23682
23683 c1/shift 4/subop/left %ecx 1/imm8
23684 09/or %eax 1/r32/ecx
23685 $type-category:end:
23686
23687 59/pop-to-ecx
23688
23689 89/<- %esp 5/r32/ebp
23690 5d/pop-to-ebp
23691 c3/return
23692
23693 is-simple-mu-type?:
23694
23695 55/push-ebp
23696 89/<- %ebp 4/r32/esp
23697
23698 51/push-ecx
23699
23700 8b/-> *(ebp+0xc) 1/r32/ecx
23701
23702 8b/-> *(ebp+8) 0/r32/eax
23703 39/compare *(eax+4) 1/r32/ecx
23704 0f 94/set-byte-if-= %al
23705 81 4/subop/and %eax 0xff/imm32
23706 $is-simple-mu-type?:end:
23707
23708 59/pop-to-ecx
23709
23710 89/<- %esp 5/r32/ebp
23711 5d/pop-to-ebp
23712 c3/return
23713
23714 is-mu-addr-type?:
23715
23716 55/push-ebp
23717 89/<- %ebp 4/r32/esp
23718
23719 8b/-> *(ebp+8) 0/r32/eax
23720
23721 81 7/subop/compare *eax 0/imm32/false
23722 {
23723 75/jump-if-!= break/disp8
23724 (lookup *(eax+4) *(eax+8))
23725 }
23726
23727 81 7/subop/compare *(eax+4) 2/imm32/addr
23728 0f 94/set-byte-if-= %al
23729 81 4/subop/and %eax 0xff/imm32
23730 $is-mu-addr-type?:end:
23731
23732 89/<- %esp 5/r32/ebp
23733 5d/pop-to-ebp
23734 c3/return
23735
23736 is-mu-array-type?:
23737
23738 55/push-ebp
23739 89/<- %ebp 4/r32/esp
23740
23741 8b/-> *(ebp+8) 0/r32/eax
23742
23743 81 7/subop/compare *eax 0/imm32/false
23744 {
23745 75/jump-if-!= break/disp8
23746 (lookup *(eax+4) *(eax+8))
23747 }
23748
23749 81 7/subop/compare *(eax+4) 3/imm32/array
23750 0f 94/set-byte-if-= %al
23751 81 4/subop/and %eax 0xff/imm32
23752 $is-mu-array-type?:end:
23753
23754 89/<- %esp 5/r32/ebp
23755 5d/pop-to-ebp
23756 c3/return
23757
23758 is-mu-stream-type?:
23759
23760 55/push-ebp
23761 89/<- %ebp 4/r32/esp
23762
23763 8b/-> *(ebp+8) 0/r32/eax
23764
23765 81 7/subop/compare *eax 0/imm32/false
23766 {
23767 75/jump-if-!= break/disp8
23768 (lookup *(eax+4) *(eax+8))
23769 }
23770
23771 81 7/subop/compare *(eax+4) 0xb/imm32/stream
23772 0f 94/set-byte-if-= %al
23773 81 4/subop/and %eax 0xff/imm32
23774 $is-mu-stream-type?:end:
23775
23776 89/<- %esp 5/r32/ebp
23777 5d/pop-to-ebp
23778 c3/return
23779
23780 test-emit-subx-stmt-primitive:
23781
23782
23783
23784
23785
23786
23787
23788
23789
23790
23791
23792
23793
23794
23795
23796
23797 55/push-ebp
23798 89/<- %ebp 4/r32/esp
23799
23800 (clear-stream _test-output-stream)
23801 (clear-stream $_test-output-buffered-file->buffer)
23802
23803 $test-emit-subx-stmt-primitive:initialize-type:
23804
23805 68/push 0/imm32/right:null
23806 68/push 0/imm32/right:null
23807 68/push 0/imm32/left:unused
23808 68/push 1/imm32/value:int
23809 68/push 1/imm32/is-atom?:true
23810 68/push 0x11/imm32/alloc-id:fake:payload
23811 89/<- %ecx 4/r32/esp
23812 $test-emit-subx-stmt-primitive:initialize-var:
23813
23814 68/push 0/imm32/no-register
23815 68/push 0/imm32/no-register
23816 68/push -8/imm32/stack-offset
23817 68/push 1/imm32/block-depth
23818 51/push-ecx/type
23819 68/push 0x11/imm32/alloc-id:fake
23820 68/push 0/imm32/name
23821 68/push 0/imm32/name
23822 68/push 0x11/imm32/alloc-id:fake:payload
23823 89/<- %ecx 4/r32/esp
23824 $test-emit-subx-stmt-primitive:initialize-var-name:
23825
23826 8d/copy-address *(ecx+4) 0/r32/eax
23827 (copy-array Heap "foo" %eax)
23828 $test-emit-subx-stmt-primitive:initialize-stmt-var:
23829
23830 68/push 0/imm32/is-deref:false
23831 68/push 0/imm32/next
23832 68/push 0/imm32/next
23833 51/push-ecx/var-foo
23834 68/push 0x11/imm32/alloc-id:fake
23835 68/push 0x11/imm32/alloc-id:fake:payload
23836 89/<- %ebx 4/r32/esp
23837 $test-emit-subx-stmt-primitive:initialize-stmt:
23838
23839 68/push 0/imm32/no-outputs
23840 68/push 0/imm32/no-outputs
23841 53/push-ebx/inouts
23842 68/push 0x11/imm32/alloc-id:fake
23843 68/push 0/imm32/operation
23844 68/push 0/imm32/operation
23845 68/push 1/imm32/tag
23846 89/<- %esi 4/r32/esp
23847 $test-emit-subx-stmt-primitive:initialize-stmt-operation:
23848
23849 8d/copy-address *(esi+4) 0/r32/eax
23850 (copy-array Heap "increment" %eax)
23851 $test-emit-subx-stmt-primitive:initialize-primitive:
23852
23853 68/push 0/imm32/next
23854 68/push 0/imm32/next
23855 68/push 0/imm32/no-x32
23856 68/push 0/imm32/no-xm32
23857 68/push 0/imm32/no-disp32
23858 68/push 0/imm32/no-imm8
23859 68/push 0/imm32/no-imm32
23860 68/push 0/imm32/no-r32
23861 68/push 1/imm32/rm32-is-first-inout
23862 68/push 0/imm32/subx-name
23863 68/push 0/imm32/subx-name
23864 68/push 0/imm32/no-outputs
23865 68/push 0/imm32/no-outputs
23866 53/push-ebx/inouts
23867 68/push 0x11/imm32/alloc-id:fake
23868 68/push 0/imm32/name
23869 68/push 0/imm32/name
23870 89/<- %ebx 4/r32/esp
23871 $test-emit-subx-stmt-primitive:initialize-primitive-name:
23872
23873 (copy-array Heap "increment" %ebx)
23874 $test-emit-subx-stmt-primitive:initialize-primitive-subx-name:
23875
23876 8d/copy-address *(ebx+0x18) 0/r32/eax
23877 (copy-array Heap "ff 0/subop/increment" %eax)
23878
23879 c7 0/subop/copy *Curr-block-depth 0/imm32
23880 (emit-subx-stmt _test-output-buffered-file %esi %ebx Stderr 0)
23881 (flush _test-output-buffered-file)
23882 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
23888
23889 (check-next-stream-line-equal _test-output-stream "ff 0/subop/increment *(ebp+0xfffffff8)" "F - test-emit-subx-stmt-primitive")
23890
23891 89/<- %esp 5/r32/ebp
23892 5d/pop-to-ebp
23893 c3/return
23894
23895 test-emit-subx-stmt-primitive-register:
23896
23897
23898
23899
23900
23901
23902
23903
23904
23905
23906
23907
23908
23909
23910
23911
23912 55/push-ebp
23913 89/<- %ebp 4/r32/esp
23914
23915 (clear-stream _test-output-stream)
23916 (clear-stream $_test-output-buffered-file->buffer)
23917 $test-emit-subx-stmt-primitive-register:initialize-type:
23918
23919 68/push 0/imm32/right:null
23920 68/push 0/imm32/right:null
23921 68/push 0/imm32/left:unused
23922 68/push 1/imm32/value:int
23923 68/push 1/imm32/is-atom?:true
23924 68/push 0x11/imm32/alloc-id:fake:payload
23925 89/<- %ecx 4/r32/esp
23926 $test-emit-subx-stmt-primitive-register:initialize-var:
23927
23928 68/push 0/imm32/register
23929 68/push 0/imm32/register
23930 68/push 0/imm32/no-stack-offset
23931 68/push 1/imm32/block-depth
23932 51/push-ecx
23933 68/push 0x11/imm32/alloc-id:fake
23934 68/push 0/imm32/name
23935 68/push 0/imm32/name
23936 68/push 0x11/imm32/alloc-id:fake:payload
23937 89/<- %ecx 4/r32/esp
23938 $test-emit-subx-stmt-primitive-register:initialize-var-name:
23939
23940 8d/copy-address *(ecx+4) 0/r32/eax
23941 (copy-array Heap "foo" %eax)
23942 $test-emit-subx-stmt-primitive-register:initialize-var-register:
23943
23944 8d/copy-address *(ecx+0x1c) 0/r32/eax
23945 (copy-array Heap "eax" %eax)
23946 $test-emit-subx-stmt-primitive-register:initialize-stmt-var:
23947
23948 68/push 0/imm32/is-deref:false
23949 68/push 0/imm32/next
23950 68/push 0/imm32/next
23951 51/push-ecx/var-foo
23952 68/push 0x11/imm32/alloc-id:fake
23953 68/push 0x11/imm32/alloc-id:fake:payload
23954 89/<- %ebx 4/r32/esp
23955 $test-emit-subx-stmt-primitive-register:initialize-stmt:
23956
23957 53/push-ebx/outputs
23958 68/push 0x11/imm32/alloc-id:fake
23959 68/push 0/imm32/no-inouts
23960 68/push 0/imm32/no-inouts
23961 68/push 0/imm32/operation
23962 68/push 0/imm32/operation
23963 68/push 1/imm32
23964 89/<- %esi 4/r32/esp
23965 $test-emit-subx-stmt-primitive-register:initialize-stmt-operation:
23966
23967 8d/copy-address *(esi+4) 0/r32/eax
23968 (copy-array Heap "increment" %eax)
23969 $test-emit-subx-stmt-primitive-register:initialize-formal-var:
23970
23971 68/push 0/imm32/register
23972 68/push 0/imm32/register
23973 68/push 0/imm32/no-stack-offset
23974 68/push 1/imm32/block-depth
23975 ff 6/subop/push *(ecx+0x10)
23976 68/push 0x11/imm32/alloc-id:fake
23977 68/push 0/imm32/name
23978 68/push 0/imm32/name
23979 68/push 0x11/imm32/alloc-id:fake:payload
23980 89/<- %ebx 4/r32/esp
23981 $test-emit-subx-stmt-primitive-register:initialize-formal-var-name:
23982
23983 8d/copy-address *(ebx+4) 0/r32/eax
23984 (copy-array Heap "dummy" %eax)
23985 $test-emit-subx-stmt-primitive-register:initialize-formal-register:
23986
23987 8d/copy-address *(ebx+0x1c) 0/r32/eax
23988 (copy-array Heap "*" %eax)
23989 $test-emit-subx-stmt-primitive-register:initialize-var-list:
23990
23991 68/push 0/imm32/next
23992 68/push 0/imm32/next
23993 53/push-ebx/formal-var
23994 68/push 0x11/imm32/alloc-id:fake
23995 68/push 0x11/imm32/alloc-id:fake:payload
23996 89/<- %ebx 4/r32/esp
23997 $test-emit-subx-stmt-primitive-register:initialize-primitive:
23998
23999 68/push 0/imm32/next
24000 68/push 0/imm32/next
24001 68/push 0/imm32/no-x32
24002 68/push 0/imm32/no-xm32
24003 68/push 0/imm32/no-disp32
24004 68/push 0/imm32/no-imm8
24005 68/push 0/imm32/no-imm32
24006 68/push 0/imm32/no-r32
24007 68/push 3/imm32/rm32-is-first-output
24008 68/push 0/imm32/subx-name
24009 68/push 0/imm32/subx-name
24010 53/push-ebx/outputs
24011 68/push 0x11/imm32/alloc-id:fake
24012 68/push 0/imm32/no-inouts
24013 68/push 0/imm32/no-inouts
24014 68/push 0/imm32/name
24015 68/push 0/imm32/name
24016 89/<- %ebx 4/r32/esp
24017 $test-emit-subx-stmt-primitive-register:initialize-primitive-name:
24018
24019 (copy-array Heap "increment" %ebx)
24020 $test-emit-subx-stmt-primitive-register:initialize-primitive-subx-name:
24021
24022 8d/copy-address *(ebx+0x18) 0/r32/eax
24023 (copy-array Heap "ff 0/subop/increment" %eax)
24024
24025 c7 0/subop/copy *Curr-block-depth 0/imm32
24026 (emit-subx-stmt _test-output-buffered-file %esi %ebx Stderr 0)
24027 (flush _test-output-buffered-file)
24028 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
24034
24035 (check-next-stream-line-equal _test-output-stream "ff 0/subop/increment %eax" "F - test-emit-subx-stmt-primitive-register")
24036
24037 89/<- %esp 5/r32/ebp
24038 5d/pop-to-ebp
24039 c3/return
24040
24041 test-emit-subx-stmt-select-primitive:
24042
24043
24044
24045
24046
24047
24048
24049
24050
24051
24052
24053
24054
24055
24056
24057
24058
24059
24060
24061 55/push-ebp
24062 89/<- %ebp 4/r32/esp
24063
24064 (clear-stream _test-output-stream)
24065 (clear-stream $_test-output-buffered-file->buffer)
24066 $test-emit-subx-stmt-select-primitive:initialize-type:
24067
24068 68/push 0/imm32/right:null
24069 68/push 0/imm32/right:null
24070 68/push 0/imm32/left:unused
24071 68/push 1/imm32/value:int
24072 68/push 1/imm32/is-atom?:true
24073 68/push 0x11/imm32/alloc-id:fake:payload
24074 89/<- %ecx 4/r32/esp
24075 $test-emit-subx-stmt-select-primitive:initialize-var:
24076
24077 68/push 0/imm32/register
24078 68/push 0/imm32/register
24079 68/push 0/imm32/no-stack-offset
24080 68/push 1/imm32/block-depth
24081 51/push-ecx
24082 68/push 0x11/imm32/alloc-id:fake
24083 68/push 0/imm32/name
24084 68/push 0/imm32/name
24085 68/push 0x11/imm32/alloc-id:fake:payload
24086 89/<- %ecx 4/r32/esp
24087 $test-emit-subx-stmt-select-primitive:initialize-var-name:
24088
24089 8d/copy-address *(ecx+4) 0/r32/eax
24090 (copy-array Heap "foo" %eax)
24091 $test-emit-subx-stmt-select-primitive:initialize-var-register:
24092
24093 8d/copy-address *(ecx+0x1c) 0/r32/eax
24094 (copy-array Heap "eax" %eax)
24095 $test-emit-subx-stmt-select-primitive:initialize-stmt-var:
24096
24097 68/push 0/imm32/is-deref:false
24098 68/push 0/imm32/next
24099 68/push 0/imm32/next
24100 51/push-ecx/var-foo
24101 68/push 0x11/imm32/alloc-id:fake
24102 68/push 0x11/imm32/alloc-id:fake:payload
24103 89/<- %ebx 4/r32/esp
24104 $test-emit-subx-stmt-select-primitive:initialize-stmt:
24105
24106 53/push-ebx/outputs
24107 68/push 0x11/imm32/alloc-id:fake
24108 68/push 0/imm32/no-inouts
24109 68/push 0/imm32/no-inouts
24110 68/push 0/imm32/operation
24111 68/push 0/imm32/operation
24112 68/push 1/imm32
24113 89/<- %esi 4/r32/esp
24114 $test-emit-subx-stmt-select-primitive:initialize-stmt-operation:
24115
24116 8d/copy-address *(esi+4) 0/r32/eax
24117 (copy-array Heap "increment" %eax)
24118 $test-emit-subx-stmt-select-primitive:initialize-formal-var:
24119
24120 68/push 0/imm32/register
24121 68/push 0/imm32/register
24122 68/push 0/imm32/no-stack-offset
24123 68/push 1/imm32/block-depth
24124 ff 6/subop/push *(ecx+0x10)
24125 68/push 0x11/imm32/alloc-id:fake
24126 68/push 0/imm32/name
24127 68/push 0/imm32/name
24128 68/push 0x11/imm32/alloc-id:fake:payload
24129 89/<- %ebx 4/r32/esp
24130 $test-emit-subx-stmt-select-primitive:initialize-formal-var-name:
24131
24132 8d/copy-address *(ebx+4) 0/r32/eax
24133 (copy-array Heap "dummy" %eax)
24134 $test-emit-subx-stmt-select-primitive:initialize-formal-register:
24135
24136 8d/copy-address *(ebx+0x1c) 0/r32/eax
24137 (copy-array Heap "*" %eax)
24138 $test-emit-subx-stmt-select-primitive:initialize-var-list:
24139
24140 68/push 0/imm32/next
24141 68/push 0/imm32/next
24142 53/push-ebx/formal-var
24143 68/push 0x11/imm32/alloc-id:fake
24144 68/push 0x11/imm32/alloc-id:fake:payload
24145 89/<- %ebx 4/r32/esp
24146 $test-emit-subx-stmt-select-primitive:initialize-primitive2:
24147
24148 68/push 0/imm32/next
24149 68/push 0/imm32/next
24150 68/push 0/imm32/no-x32
24151 68/push 0/imm32/no-xm32
24152 68/push 0/imm32/no-disp32
24153 68/push 0/imm32/no-imm8
24154 68/push 0/imm32/no-imm32
24155 68/push 0/imm32/no-r32
24156 68/push 3/imm32/rm32-is-first-output
24157 68/push 0/imm32/subx-name
24158 68/push 0/imm32/subx-name
24159 53/push-ebx/outputs
24160 68/push 0x11/imm32/alloc-id:fake
24161 68/push 0/imm32/no-inouts
24162 68/push 0/imm32/no-inouts
24163 68/push 0/imm32/name
24164 68/push 0/imm32/name
24165 68/push 0x11/imm32/alloc-id:fake:payload
24166 89/<- %edi 4/r32/esp
24167 $test-emit-subx-stmt-select-primitive:initialize-primitive2-name:
24168
24169 8d/copy-address *(edi+4) 0/r32/eax
24170 (copy-array Heap "increment" %eax)
24171 $test-emit-subx-stmt-select-primitive:initialize-primitive2-subx-name:
24172
24173 8d/copy-address *(edi+0x1c) 0/r32/eax
24174 (copy-array Heap "ff 0/subop/increment" %eax)
24175 $test-emit-subx-stmt-select-primitive:initialize-primitive:
24176
24177 57/push-edi
24178 68/push 0x11/imm32/alloc-id:fake
24179 68/push 0/imm32/no-x32
24180 68/push 0/imm32/no-xm32
24181 68/push 0/imm32/no-disp32
24182 68/push 0/imm32/no-imm8
24183 68/push 0/imm32/no-imm32
24184 68/push 0/imm32/no-r32
24185 68/push 1/imm32/rm32-is-first-inout
24186 68/push 0/imm32/subx-name
24187 68/push 0/imm32/subx-name
24188 68/push 0/imm32/no-outputs
24189 68/push 0/imm32/no-outputs
24190 53/push-ebx/inouts
24191 68/push 0x11/imm32/alloc-id:fake
24192 68/push 0/imm32/name
24193 68/push 0/imm32/name
24194 89/<- %ebx 4/r32/esp
24195 $test-emit-subx-stmt-select-primitive:initialize-primitive-name:
24196
24197 (copy-array Heap "increment" %ebx)
24198 $test-emit-subx-stmt-select-primitive:initialize-primitive-subx-name:
24199
24200 8d/copy-address *(ebx+0x18) 0/r32/eax
24201 (copy-array Heap "ff 0/subop/increment" %eax)
24202
24203 c7 0/subop/copy *Curr-block-depth 0/imm32
24204 (emit-subx-stmt _test-output-buffered-file %esi %ebx Stderr 0)
24205 (flush _test-output-buffered-file)
24206 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
24212
24213 (check-next-stream-line-equal _test-output-stream "ff 0/subop/increment %eax" "F - test-emit-subx-stmt-select-primitive")
24214
24215 89/<- %esp 5/r32/ebp
24216 5d/pop-to-ebp
24217 c3/return
24218
24219 test-emit-subx-stmt-select-primitive-2:
24220
24221
24222
24223
24224
24225
24226
24227
24228
24229
24230
24231
24232
24233
24234
24235
24236
24237
24238
24239 55/push-ebp
24240 89/<- %ebp 4/r32/esp
24241
24242 (clear-stream _test-output-stream)
24243 (clear-stream $_test-output-buffered-file->buffer)
24244 $test-emit-subx-stmt-select-primitive-2:initialize-type:
24245
24246 68/push 0/imm32/right:null
24247 68/push 0/imm32/right:null
24248 68/push 0/imm32/left:unused
24249 68/push 1/imm32/value:int
24250 68/push 1/imm32/is-atom?:true
24251 68/push 0x11/imm32/alloc-id:fake:payload
24252 89/<- %ecx 4/r32/esp
24253 $test-emit-subx-stmt-select-primitive-2:initialize-var:
24254
24255 68/push 0/imm32/register
24256 68/push 0/imm32/register
24257 68/push 0/imm32/no-stack-offset
24258 68/push 1/imm32/block-depth
24259 51/push-ecx
24260 68/push 0x11/imm32/alloc-id:fake
24261 68/push 0/imm32/name
24262 68/push 0/imm32/name
24263 68/push 0x11/imm32/alloc-id:fake:payload
24264 89/<- %ecx 4/r32/esp
24265 $test-emit-subx-stmt-select-primitive-2:initialize-var-name:
24266
24267 8d/copy-address *(ecx+4) 0/r32/eax
24268 (copy-array Heap "foo" %eax)
24269 $test-emit-subx-stmt-select-primitive-2:initialize-var-register:
24270
24271 8d/copy-address *(ecx+0x1c) 0/r32/eax
24272 (copy-array Heap "eax" %eax)
24273 $test-emit-subx-stmt-select-primitive-2:initialize-stmt-var:
24274
24275 68/push 0/imm32/is-deref:false
24276 68/push 0/imm32/next
24277 68/push 0/imm32/next
24278 51/push-ecx/var-foo
24279 68/push 0x11/imm32/alloc-id:fake
24280 68/push 0x11/imm32/alloc-id:fake:payload
24281 89/<- %ebx 4/r32/esp
24282 $test-emit-subx-stmt-select-primitive-2:initialize-stmt:
24283
24284 68/push 0/imm32/no-outputs
24285 68/push 0/imm32/no-outputs
24286 53/push-ebx/inouts
24287 68/push 0x11/imm32/alloc-id:fake
24288 68/push 0/imm32/operation
24289 68/push 0/imm32/operation
24290 68/push 1/imm32
24291 89/<- %esi 4/r32/esp
24292 $test-emit-subx-stmt-select-primitive-2:initialize-stmt-operation:
24293
24294 8d/copy-address *(esi+4) 0/r32/eax
24295 (copy-array Heap "increment" %eax)
24296 $test-emit-subx-stmt-select-primitive-2:initialize-formal-var:
24297
24298 68/push 0/imm32/register
24299 68/push 0/imm32/register
24300 68/push 0/imm32/no-stack-offset
24301 68/push 1/imm32/block-depth
24302 ff 6/subop/push *(ecx+0x10)
24303 68/push 0x11/imm32/alloc-id:fake
24304 68/push 0/imm32/name
24305 68/push 0/imm32/name
24306 68/push 0x11/imm32/alloc-id:fake:payload
24307 89/<- %ebx 4/r32/esp
24308 $test-emit-subx-stmt-select-primitive-2:initialize-formal-var-name:
24309
24310 8d/copy-address *(ebx+4) 0/r32/eax
24311 (copy-array Heap "dummy" %eax)
24312 $test-emit-subx-stmt-select-primitive-2:initialize-formal-register:
24313
24314 8d/copy-address *(ebx+0x1c) 0/r32/eax
24315 (copy-array Heap "*" %eax)
24316 $test-emit-subx-stmt-select-primitive-2:initialize-var-list:
24317
24318 68/push 0/imm32/next
24319 68/push 0/imm32/next
24320 53/push-ebx/formal-var
24321 68/push 0x11/imm32/alloc-id:fake
24322 68/push 0x11/imm32/alloc-id:fake:payload
24323 89/<- %ebx 4/r32/esp
24324 $test-emit-subx-stmt-select-primitive-2:initialize-primitive2:
24325
24326 68/push 0/imm32/next
24327 68/push 0/imm32/next
24328 68/push 0/imm32/no-x32
24329 68/push 0/imm32/no-xm32
24330 68/push 0/imm32/no-disp32
24331 68/push 0/imm32/no-imm8
24332 68/push 0/imm32/no-imm32
24333 68/push 0/imm32/no-r32
24334 68/push 3/imm32/rm32-is-first-output
24335 68/push 0/imm32/subx-name
24336 68/push 0/imm32/subx-name
24337 53/push-ebx/outputs
24338 68/push 0x11/imm32/alloc-id:fake
24339 68/push 0/imm32/no-inouts
24340 68/push 0/imm32/no-inouts
24341 68/push 0/imm32/name
24342 68/push 0/imm32/name
24343 68/push 0x11/imm32/alloc-id:fake:payload
24344 89/<- %edi 4/r32/esp
24345 $test-emit-subx-stmt-select-primitive-2:initialize-primitive2-name:
24346
24347 8d/copy-address *(edi+4) 0/r32/eax
24348 (copy-array Heap "increment" %eax)
24349 $test-emit-subx-stmt-select-primitive-2:initialize-primitive2-subx-name:
24350
24351 8d/copy-address *(edi+0x1c) 0/r32/eax
24352 (copy-array Heap "ff 0/subop/increment" %eax)
24353 $test-emit-subx-stmt-select-primitive-2:initialize-primitive:
24354
24355 57/push-edi
24356 68/push 0x11/imm32/alloc-id:fake
24357 68/push 0/imm32/no-x32
24358 68/push 0/imm32/no-xm32
24359 68/push 0/imm32/no-disp32
24360 68/push 0/imm32/no-imm8
24361 68/push 0/imm32/no-imm32
24362 68/push 0/imm32/no-r32
24363 68/push 1/imm32/rm32-is-first-inout
24364 68/push 0/imm32/subx-name
24365 68/push 0/imm32/subx-name
24366 68/push 0/imm32/no-outputs
24367 68/push 0/imm32/no-outputs
24368 53/push-ebx/inouts
24369 68/push 0x11/imm32/alloc-id:fake
24370 68/push 0/imm32/name
24371 68/push 0/imm32/name
24372 89/<- %ebx 4/r32/esp
24373 $test-emit-subx-stmt-select-primitive-2:initialize-primitive-name:
24374
24375 (copy-array Heap "increment" %ebx)
24376 $test-emit-subx-stmt-select-primitive-2:initialize-primitive-subx-name:
24377
24378 8d/copy-address *(ebx+0x18) 0/r32/eax
24379 (copy-array Heap "ff 0/subop/increment" %eax)
24380
24381 c7 0/subop/copy *Curr-block-depth 0/imm32
24382 (emit-subx-stmt _test-output-buffered-file %esi %ebx Stderr 0)
24383 (flush _test-output-buffered-file)
24384 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
24390
24391 (check-next-stream-line-equal _test-output-stream "ff 0/subop/increment %eax" "F - test-emit-subx-stmt-select-primitive-2")
24392
24393 89/<- %esp 5/r32/ebp
24394 5d/pop-to-ebp
24395 c3/return
24396
24397 test-increment-register:
24398
24399
24400
24401
24402
24403
24404
24405
24406
24407
24408
24409
24410
24411 55/push-ebp
24412 89/<- %ebp 4/r32/esp
24413
24414 (clear-stream _test-output-stream)
24415 (clear-stream $_test-output-buffered-file->buffer)
24416 $test-increment-register:initialize-type:
24417
24418 68/push 0/imm32/right:null
24419 68/push 0/imm32/right:null
24420 68/push 0/imm32/left:unused
24421 68/push 1/imm32/value:int
24422 68/push 1/imm32/is-atom?:true
24423 68/push 0x11/imm32/alloc-id:fake:payload
24424 89/<- %ecx 4/r32/esp
24425 $test-increment-register:initialize-var:
24426
24427 68/push 0/imm32/register
24428 68/push 0/imm32/register
24429 68/push 0/imm32/no-stack-offset
24430 68/push 1/imm32/block-depth
24431 51/push-ecx
24432 68/push 0x11/imm32/alloc-id:fake
24433 68/push 0/imm32/name
24434 68/push 0/imm32/name
24435 68/push 0x11/imm32/alloc-id:fake:payload
24436 89/<- %ecx 4/r32/esp
24437 $test-increment-register:initialize-var-name:
24438
24439 8d/copy-address *(ecx+4) 0/r32/eax
24440 (copy-array Heap "foo" %eax)
24441 $test-increment-register:initialize-var-register:
24442
24443 8d/copy-address *(ecx+0x1c) 0/r32/eax
24444 (copy-array Heap "eax" %eax)
24445 $test-increment-register:initialize-stmt-var:
24446
24447 68/push 0/imm32/is-deref:false
24448 68/push 0/imm32/next
24449 68/push 0/imm32/next
24450 51/push-ecx/var-foo
24451 68/push 0x11/imm32/alloc-id:fake
24452 68/push 0x11/imm32/alloc-id:fake:payload
24453 89/<- %ebx 4/r32/esp
24454 $test-increment-register:initialize-stmt:
24455
24456 53/push-ebx/outputs
24457 68/push 0x11/imm32/alloc-id:fake
24458 68/push 0/imm32/no-inouts
24459 68/push 0/imm32/no-inouts
24460 68/push 0/imm32/operation
24461 68/push 0/imm32/operation
24462 68/push 1/imm32
24463 89/<- %esi 4/r32/esp
24464 $test-increment-register:initialize-stmt-operation:
24465
24466 8d/copy-address *(esi+4) 0/r32/eax
24467 (copy-array Heap "increment" %eax)
24468
24469 c7 0/subop/copy *Curr-block-depth 0/imm32
24470 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
24471 (flush _test-output-buffered-file)
24472 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
24478
24479 (check-next-stream-line-equal _test-output-stream "40/increment-eax" "F - test-increment-register")
24480
24481 89/<- %esp 5/r32/ebp
24482 5d/pop-to-ebp
24483 c3/return
24484
24485 test-add-reg-to-reg:
24486
24487
24488
24489
24490
24491 55/push-ebp
24492 89/<- %ebp 4/r32/esp
24493
24494 (clear-stream _test-output-stream)
24495 (clear-stream $_test-output-buffered-file->buffer)
24496 $test-add-reg-to-reg:initialize-type:
24497
24498 68/push 0/imm32/right:null
24499 68/push 0/imm32/right:null
24500 68/push 0/imm32/left:unused
24501 68/push 1/imm32/value:int
24502 68/push 1/imm32/is-atom?:true
24503 68/push 0x11/imm32/alloc-id:fake:payload
24504 89/<- %ecx 4/r32/esp
24505 $test-add-reg-to-reg:initialize-var1:
24506
24507 68/push 0/imm32/register
24508 68/push 0/imm32/register
24509 68/push 0/imm32/no-stack-offset
24510 68/push 1/imm32/block-depth
24511 51/push-ecx
24512 68/push 0x11/imm32/alloc-id:fake
24513 68/push 0/imm32/name
24514 68/push 0/imm32/name
24515 68/push 0x11/imm32/alloc-id:fake:payload
24516 89/<- %ecx 4/r32/esp
24517 $test-add-reg-to-reg:initialize-var1-name:
24518
24519 8d/copy-address *(ecx+4) 0/r32/eax
24520 (copy-array Heap "var1" %eax)
24521 $test-add-reg-to-reg:initialize-var1-register:
24522
24523 8d/copy-address *(ecx+0x1c) 0/r32/eax
24524 (copy-array Heap "eax" %eax)
24525 $test-add-reg-to-reg:initialize-var2:
24526
24527 68/push 0/imm32/register
24528 68/push 0/imm32/register
24529 68/push 0/imm32/no-stack-offset
24530 68/push 1/imm32/block-depth
24531 ff 6/subop/push *(ecx+0x10)
24532 68/push 0x11/imm32/alloc-id:fake
24533 68/push 0/imm32/name
24534 68/push 0/imm32/name
24535 68/push 0x11/imm32/alloc-id:fake:payload
24536 89/<- %edx 4/r32/esp
24537 $test-add-reg-to-reg:initialize-var2-name:
24538
24539 8d/copy-address *(edx+4) 0/r32/eax
24540 (copy-array Heap "var2" %eax)
24541 $test-add-reg-to-reg:initialize-var2-register:
24542
24543 8d/copy-address *(edx+0x1c) 0/r32/eax
24544 (copy-array Heap "ecx" %eax)
24545 $test-add-reg-to-reg:initialize-inouts:
24546
24547 68/push 0/imm32/is-deref:false
24548 68/push 0/imm32/next
24549 68/push 0/imm32/next
24550 52/push-edx/var2
24551 68/push 0x11/imm32/alloc-id:fake
24552 68/push 0x11/imm32/alloc-id:fake:payload
24553 89/<- %esi 4/r32/esp
24554 $test-add-reg-to-reg:initialize-outputs:
24555
24556 68/push 0/imm32/is-deref:false
24557 68/push 0/imm32/next
24558 68/push 0/imm32/next
24559 51/push-ecx/var1
24560 68/push 0x11/imm32/alloc-id:fake
24561 68/push 0x11/imm32/alloc-id:fake:payload
24562 89/<- %edi 4/r32/esp
24563 $test-add-reg-to-reg:initialize-stmt:
24564
24565 68/push 0/imm32/next
24566 68/push 0/imm32/next
24567 57/push-edi/outputs
24568 68/push 0x11/imm32/alloc-id:fake
24569 56/push-esi/inouts
24570 68/push 0x11/imm32/alloc-id:fake
24571 68/push 0/imm32/operation
24572 68/push 0/imm32/operation
24573 68/push 1/imm32/tag:stmt1
24574 89/<- %esi 4/r32/esp
24575 $test-add-reg-to-reg:initialize-stmt-operation:
24576
24577 8d/copy-address *(esi+4) 0/r32/eax
24578 (copy-array Heap "add" %eax)
24579
24580 c7 0/subop/copy *Curr-block-depth 0/imm32
24581 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
24582 (flush _test-output-buffered-file)
24583 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
24589
24590 (check-next-stream-line-equal _test-output-stream "01/add-to %eax 0x00000001/r32" "F - test-add-reg-to-reg")
24591
24592 89/<- %esp 5/r32/ebp
24593 5d/pop-to-ebp
24594 c3/return
24595
24596 test-add-reg-to-mem:
24597
24598
24599
24600
24601
24602 55/push-ebp
24603 89/<- %ebp 4/r32/esp
24604
24605 (clear-stream _test-output-stream)
24606 (clear-stream $_test-output-buffered-file->buffer)
24607 $test-add-reg-to-mem:initialize-type:
24608
24609 68/push 0/imm32/right:null
24610 68/push 0/imm32/right:null
24611 68/push 0/imm32/left:unused
24612 68/push 1/imm32/value:int
24613 68/push 1/imm32/is-atom?:true
24614 68/push 0x11/imm32/alloc-id:fake:payload
24615 89/<- %ecx 4/r32/esp
24616 $test-add-reg-to-mem:initialize-var1:
24617
24618 68/push 0/imm32/register
24619 68/push 0/imm32/register
24620 68/push 8/imm32/stack-offset
24621 68/push 1/imm32/block-depth
24622 51/push-ecx
24623 68/push 0x11/imm32/alloc-id:fake
24624 68/push 0/imm32/name
24625 68/push 0/imm32/name
24626 68/push 0x11/imm32/alloc-id:fake:payload
24627 89/<- %ecx 4/r32/esp
24628 $test-add-reg-to-mem:initialize-var1-name:
24629
24630 8d/copy-address *(ecx+4) 0/r32/eax
24631 (copy-array Heap "var1" %eax)
24632 $test-add-reg-to-mem:initialize-var2:
24633
24634 68/push 0/imm32/register
24635 68/push 0/imm32/register
24636 68/push 0/imm32/no-stack-offset
24637 68/push 1/imm32/block-depth
24638 ff 6/subop/push *(ecx+0x10)
24639 68/push 0x11/imm32/alloc-id:fake
24640 68/push 0/imm32/name
24641 68/push 0/imm32/name
24642 68/push 0x11/imm32/alloc-id:fake:payload
24643 89/<- %edx 4/r32/esp
24644 $test-add-reg-to-mem:initialize-var2-name:
24645
24646 8d/copy-address *(edx+4) 0/r32/eax
24647 (copy-array Heap "var2" %eax)
24648 $test-add-reg-to-mem:initialize-var2-register:
24649
24650 8d/copy-address *(edx+0x1c) 0/r32/eax
24651 (copy-array Heap "ecx" %eax)
24652 $test-add-reg-to-mem:initialize-inouts:
24653
24654 68/push 0/imm32/is-deref:false
24655 68/push 0/imm32/next
24656 68/push 0/imm32/next
24657 52/push-edx/var2
24658 68/push 0x11/imm32/alloc-id:fake
24659 68/push 0x11/imm32/alloc-id:fake:payload
24660 89/<- %esi 4/r32/esp
24661
24662 68/push 0/imm32/is-deref:false
24663 56/push-esi/next
24664 68/push 0x11/imm32/alloc-id:fake
24665 51/push-ecx/var1
24666 68/push 0x11/imm32/alloc-id:fake
24667 68/push 0x11/imm32/alloc-id:fake:payload
24668 89/<- %esi 4/r32/esp
24669 $test-add-reg-to-mem:initialize-stmt:
24670
24671 68/push 0/imm32/next
24672 68/push 0/imm32/next
24673 68/push 0/imm32/outputs
24674 68/push 0/imm32/outputs
24675 56/push-esi/inouts
24676 68/push 0x11/imm32/alloc-id:fake
24677 68/push 0/imm32/operation
24678 68/push 0/imm32/operation
24679 68/push 1/imm32/tag:stmt1
24680 89/<- %esi 4/r32/esp
24681 $test-add-reg-to-mem:initialize-stmt-operation:
24682
24683 8d/copy-address *(esi+4) 0/r32/eax
24684 (copy-array Heap "add-to" %eax)
24685
24686 c7 0/subop/copy *Curr-block-depth 0/imm32
24687 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
24688 (flush _test-output-buffered-file)
24689 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
24695
24696 (check-next-stream-line-equal _test-output-stream "01/add-to *(ebp+0x00000008) 0x00000001/r32" "F - test-add-reg-to-mem")
24697
24698 89/<- %esp 5/r32/ebp
24699 5d/pop-to-ebp
24700 c3/return
24701
24702 test-add-mem-to-reg:
24703
24704
24705
24706
24707
24708 55/push-ebp
24709 89/<- %ebp 4/r32/esp
24710
24711 (clear-stream _test-output-stream)
24712 (clear-stream $_test-output-buffered-file->buffer)
24713 $test-add-mem-to-reg:initialize-type:
24714
24715 68/push 0/imm32/right:null
24716 68/push 0/imm32/right:null
24717 68/push 0/imm32/left:unused
24718 68/push 1/imm32/value:int
24719 68/push 1/imm32/is-atom?:true
24720 68/push 0x11/imm32/alloc-id:fake:payload
24721 89/<- %ecx 4/r32/esp
24722 $test-add-mem-to-reg:initialize-var:
24723
24724 68/push 0/imm32/register
24725 68/push 0/imm32/register
24726 68/push 0/imm32/no-stack-offset
24727 68/push 1/imm32/block-depth
24728 51/push-ecx
24729 68/push 0x11/imm32/alloc-id:fake
24730 68/push 0/imm32/name
24731 68/push 0/imm32/name
24732 68/push 0x11/imm32/alloc-id:fake:payload
24733 89/<- %ecx 4/r32/esp
24734 $test-add-mem-to-reg:initialize-var-name:
24735
24736 8d/copy-address *(ecx+4) 0/r32/eax
24737 (copy-array Heap "var1" %eax)
24738 $test-add-mem-to-reg:initialize-var-register:
24739
24740 8d/copy-address *(ecx+0x1c) 0/r32/eax
24741 (copy-array Heap "eax" %eax)
24742 $test-add-mem-to-reg:initialize-var2:
24743
24744 68/push 0/imm32/register
24745 68/push 0/imm32/register
24746 68/push 8/imm32/stack-offset
24747 68/push 1/imm32/block-depth
24748 ff 6/subop/push *(ecx+0x10)
24749 68/push 0x11/imm32/alloc-id:fake
24750 68/push 0/imm32/name
24751 68/push 0/imm32/name
24752 68/push 0x11/imm32/alloc-id:fake:payload
24753 89/<- %edx 4/r32/esp
24754 $test-add-mem-to-reg:initialize-var2-name:
24755
24756 8d/copy-address *(edx+4) 0/r32/eax
24757 (copy-array Heap "var2" %eax)
24758 $test-add-mem-to-reg:initialize-inouts:
24759
24760 68/push 0/imm32/is-deref:false
24761 68/push 0/imm32/next
24762 68/push 0/imm32/next
24763 52/push-edx/var2
24764 68/push 0x11/imm32/alloc-id:fake
24765 68/push 0x11/imm32/alloc-id:fake:payload
24766 89/<- %esi 4/r32/esp
24767 $test-add-mem-to-reg:initialize-outputs:
24768
24769 68/push 0/imm32/is-deref:false
24770 68/push 0/imm32/next
24771 68/push 0/imm32/next
24772 51/push-ecx/var1
24773 68/push 0x11/imm32/alloc-id:fake
24774 68/push 0x11/imm32/alloc-id:fake:payload
24775 89/<- %edi 4/r32/esp
24776 $test-add-mem-to-reg:initialize-stmt:
24777
24778 68/push 0/imm32/next
24779 68/push 0/imm32/next
24780 57/push-edi/outputs
24781 68/push 0x11/imm32/alloc-id:fake
24782 56/push-esi/inouts
24783 68/push 0x11/imm32/alloc-id:fake
24784 68/push 0/imm32/operation
24785 68/push 0/imm32/operation
24786 68/push 1/imm32/tag:stmt1
24787 89/<- %esi 4/r32/esp
24788 $test-add-mem-to-reg:initialize-stmt-operation:
24789
24790 8d/copy-address *(esi+4) 0/r32/eax
24791 (copy-array Heap "add" %eax)
24792
24793 c7 0/subop/copy *Curr-block-depth 0/imm32
24794 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
24795 (flush _test-output-buffered-file)
24796 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
24802
24803 (check-next-stream-line-equal _test-output-stream "03/add *(ebp+0x00000008) 0x00000000/r32" "F - test-add-mem-to-reg")
24804
24805 89/<- %esp 5/r32/ebp
24806 5d/pop-to-ebp
24807 c3/return
24808
24809 test-add-literal-to-eax:
24810
24811
24812
24813
24814
24815 55/push-ebp
24816 89/<- %ebp 4/r32/esp
24817
24818 (clear-stream _test-output-stream)
24819 (clear-stream $_test-output-buffered-file->buffer)
24820 $test-add-literal-to-eax:initialize-var-type:
24821
24822 68/push 0/imm32/right:null
24823 68/push 0/imm32/right:null
24824 68/push 0/imm32/left:unused
24825 68/push 1/imm32/value:int
24826 68/push 1/imm32/is-atom?:true
24827 68/push 0x11/imm32/alloc-id:fake:payload
24828 89/<- %ecx 4/r32/esp
24829 $test-add-literal-to-eax:initialize-var:
24830
24831 68/push 0/imm32/register
24832 68/push 0/imm32/register
24833 68/push 0/imm32/no-stack-offset
24834 68/push 1/imm32/block-depth
24835 51/push-ecx
24836 68/push 0x11/imm32/alloc-id:fake
24837 68/push 0/imm32/name
24838 68/push 0/imm32/name
24839 68/push 0x11/imm32/alloc-id:fake:payload
24840 89/<- %ecx 4/r32/esp
24841 $test-add-literal-to-eax:initialize-var-name:
24842
24843 8d/copy-address *(ecx+4) 0/r32/eax
24844 (copy-array Heap "v" %eax)
24845 $test-add-literal-to-eax:initialize-var-register:
24846
24847 8d/copy-address *(ecx+0x1c) 0/r32/eax
24848 (copy-array Heap "eax" %eax)
24849 $test-add-literal-to-eax:initialize-literal-type:
24850
24851 68/push 0/imm32/right:null
24852 68/push 0/imm32/right:null
24853 68/push 0/imm32/left:unused
24854 68/push 0/imm32/value:literal
24855 68/push 1/imm32/is-atom?:true
24856 68/push 0x11/imm32/alloc-id:fake:payload
24857 89/<- %edx 4/r32/esp
24858 $test-add-literal-to-eax:initialize-literal:
24859
24860 68/push 0/imm32/register
24861 68/push 0/imm32/register
24862 68/push 0/imm32/no-stack-offset
24863 68/push 1/imm32/block-depth
24864 52/push-edx
24865 68/push 0x11/imm32/alloc-id:fake
24866 68/push 0/imm32/name
24867 68/push 0/imm32/name
24868 68/push 0x11/imm32/alloc-id:fake:payload
24869 89/<- %edx 4/r32/esp
24870 $test-add-literal-to-eax:initialize-literal-value:
24871
24872 8d/copy-address *(edx+4) 0/r32/eax
24873 (copy-array Heap "0x34" %eax)
24874 $test-add-literal-to-eax:initialize-inouts:
24875
24876 68/push 0/imm32/is-deref:false
24877 68/push 0/imm32/next
24878 68/push 0/imm32/next
24879 52/push-edx/l
24880 68/push 0x11/imm32/alloc-id:fake
24881 68/push 0x11/imm32/alloc-id:fake:payload
24882 89/<- %esi 4/r32/esp
24883 $test-add-literal-to-eax:initialize-outputs:
24884
24885 68/push 0/imm32/is-deref:false
24886 68/push 0/imm32/next
24887 68/push 0/imm32/next
24888 51/push-ecx/v
24889 68/push 0x11/imm32/alloc-id:fake
24890 68/push 0x11/imm32/alloc-id:fake:payload
24891 89/<- %edi 4/r32/esp
24892 $test-add-literal-to-eax:initialize-stmt:
24893
24894 68/push 0/imm32/next
24895 68/push 0/imm32/next
24896 57/push-edi/outputs
24897 68/push 0x11/imm32/alloc-id:fake
24898 56/push-esi/inouts
24899 68/push 0x11/imm32/alloc-id:fake
24900 68/push 0/imm32/operation
24901 68/push 0/imm32/operation
24902 68/push 1/imm32/tag:stmt1
24903 89/<- %esi 4/r32/esp
24904 $test-add-literal-to-eax:initialize-stmt-operation:
24905
24906 8d/copy-address *(esi+4) 0/r32/eax
24907 (copy-array Heap "add" %eax)
24908
24909 c7 0/subop/copy *Curr-block-depth 0/imm32
24910 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
24911 (flush _test-output-buffered-file)
24912 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
24918
24919 (check-next-stream-line-equal _test-output-stream "05/add-to-eax 0x34/imm32" "F - test-add-literal-to-eax")
24920
24921 89/<- %esp 5/r32/ebp
24922 5d/pop-to-ebp
24923 c3/return
24924
24925 test-add-literal-to-reg:
24926
24927
24928
24929
24930
24931 55/push-ebp
24932 89/<- %ebp 4/r32/esp
24933
24934 (clear-stream _test-output-stream)
24935 (clear-stream $_test-output-buffered-file->buffer)
24936 $test-add-literal-to-reg:initialize-var-type:
24937
24938 68/push 0/imm32/right:null
24939 68/push 0/imm32/right:null
24940 68/push 0/imm32/left:unused
24941 68/push 1/imm32/value:int
24942 68/push 1/imm32/is-atom?:true
24943 68/push 0x11/imm32/alloc-id:fake:payload
24944 89/<- %ecx 4/r32/esp
24945 $test-add-literal-to-reg:initialize-var:
24946
24947 68/push 0/imm32/register
24948 68/push 0/imm32/register
24949 68/push 0/imm32/no-stack-offset
24950 68/push 1/imm32/block-depth
24951 51/push-ecx
24952 68/push 0x11/imm32/alloc-id:fake
24953 68/push 0/imm32/name
24954 68/push 0/imm32/name
24955 68/push 0x11/imm32/alloc-id:fake:payload
24956 89/<- %ecx 4/r32/esp
24957 $test-add-literal-to-reg:initialize-var-name:
24958
24959 8d/copy-address *(ecx+4) 0/r32/eax
24960 (copy-array Heap "v" %eax)
24961 $test-add-literal-to-reg:initialize-var-register:
24962
24963 8d/copy-address *(ecx+0x1c) 0/r32/eax
24964 (copy-array Heap "ecx" %eax)
24965 $test-add-literal-to-reg:initialize-literal-type:
24966
24967 68/push 0/imm32/right:null
24968 68/push 0/imm32/right:null
24969 68/push 0/imm32/left:unused
24970 68/push 0/imm32/value:literal
24971 68/push 1/imm32/is-atom?:true
24972 68/push 0x11/imm32/alloc-id:fake:payload
24973 89/<- %edx 4/r32/esp
24974 $test-add-literal-to-reg:initialize-literal:
24975
24976 68/push 0/imm32/register
24977 68/push 0/imm32/register
24978 68/push 0/imm32/no-stack-offset
24979 68/push 1/imm32/block-depth
24980 52/push-edx
24981 68/push 0x11/imm32/alloc-id:fake
24982 68/push 0/imm32/name
24983 68/push 0/imm32/name
24984 68/push 0x11/imm32/alloc-id:fake:payload
24985 89/<- %edx 4/r32/esp
24986 $test-add-literal-to-reg:initialize-literal-value:
24987
24988 8d/copy-address *(edx+4) 0/r32/eax
24989 (copy-array Heap "0x34" %eax)
24990 $test-add-literal-to-reg:initialize-inouts:
24991
24992 68/push 0/imm32/is-deref:false
24993 68/push 0/imm32/next
24994 68/push 0/imm32/next
24995 52/push-edx/l
24996 68/push 0x11/imm32/alloc-id:fake
24997 68/push 0x11/imm32/alloc-id:fake:payload
24998 89/<- %esi 4/r32/esp
24999 $test-add-literal-to-reg:initialize-outputs:
25000
25001 68/push 0/imm32/is-deref:false
25002 68/push 0/imm32/next
25003 68/push 0/imm32/next
25004 51/push-ecx/v
25005 68/push 0x11/imm32/alloc-id:fake
25006 68/push 0x11/imm32/alloc-id:fake:payload
25007 89/<- %edi 4/r32/esp
25008 $test-add-literal-to-reg:initialize-stmt:
25009
25010 68/push 0/imm32/next
25011 68/push 0/imm32/next
25012 57/push-edi/outputs
25013 68/push 0x11/imm32/alloc-id:fake
25014 56/push-esi/inouts
25015 68/push 0x11/imm32/alloc-id:fake
25016 68/push 0/imm32/operation
25017 68/push 0/imm32/operation
25018 68/push 1/imm32/tag:stmt1
25019 89/<- %esi 4/r32/esp
25020 $test-add-literal-to-reg:initialize-stmt-operation:
25021
25022 8d/copy-address *(esi+4) 0/r32/eax
25023 (copy-array Heap "add" %eax)
25024
25025 c7 0/subop/copy *Curr-block-depth 0/imm32
25026 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
25027 (flush _test-output-buffered-file)
25028 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
25034
25035 (check-next-stream-line-equal _test-output-stream "81 0/subop/add %ecx 0x34/imm32" "F - test-add-literal-to-reg")
25036
25037 89/<- %esp 5/r32/ebp
25038 5d/pop-to-ebp
25039 c3/return
25040
25041 test-add-literal-to-mem:
25042
25043
25044
25045
25046
25047 55/push-ebp
25048 89/<- %ebp 4/r32/esp
25049
25050 (clear-stream _test-output-stream)
25051 (clear-stream $_test-output-buffered-file->buffer)
25052 $test-add-literal-to-mem:initialize-type:
25053
25054 68/push 0/imm32/right:null
25055 68/push 0/imm32/right:null
25056 68/push 0/imm32/left:unused
25057 68/push 1/imm32/value:int
25058 68/push 1/imm32/is-atom?:true
25059 68/push 0x11/imm32/alloc-id:fake:payload
25060 89/<- %ecx 4/r32/esp
25061 $test-add-literal-to-mem:initialize-var1:
25062
25063 68/push 0/imm32/register
25064 68/push 0/imm32/register
25065 68/push 8/imm32/stack-offset
25066 68/push 1/imm32/block-depth
25067 51/push-ecx
25068 68/push 0x11/imm32/alloc-id:fake
25069 68/push 0/imm32/name
25070 68/push 0/imm32/name
25071 68/push 0x11/imm32/alloc-id:fake:payload
25072 89/<- %ecx 4/r32/esp
25073 $test-add-literal-to-mem:initialize-var1-name:
25074
25075 8d/copy-address *(ecx+4) 0/r32/eax
25076 (copy-array Heap "var1" %eax)
25077 $test-add-literal-to-mem:initialize-literal-type:
25078
25079 68/push 0/imm32/right:null
25080 68/push 0/imm32/right:null
25081 68/push 0/imm32/left:unused
25082 68/push 0/imm32/value:literal
25083 68/push 1/imm32/is-atom?:true
25084 68/push 0x11/imm32/alloc-id:fake:payload
25085 89/<- %edx 4/r32/esp
25086 $test-add-literal-to-mem:initialize-literal:
25087
25088 68/push 0/imm32/register
25089 68/push 0/imm32/register
25090 68/push 0/imm32/no-stack-offset
25091 68/push 1/imm32/block-depth
25092 52/push-edx
25093 68/push 0x11/imm32/alloc-id:fake
25094 68/push 0/imm32/name
25095 68/push 0/imm32/name
25096 68/push 0x11/imm32/alloc-id:fake:payload
25097 89/<- %edx 4/r32/esp
25098 $test-add-literal-to-mem:initialize-literal-value:
25099
25100 8d/copy-address *(edx+4) 0/r32/eax
25101 (copy-array Heap "0x34" %eax)
25102 $test-add-literal-to-mem:initialize-inouts:
25103
25104 68/push 0/imm32/is-deref:false
25105 68/push 0/imm32/next
25106 68/push 0/imm32/next
25107 52/push-edx/l
25108 68/push 0x11/imm32/alloc-id:fake
25109 68/push 0x11/imm32/alloc-id:fake:payload
25110 89/<- %esi 4/r32/esp
25111
25112 68/push 0/imm32/is-deref:false
25113 56/push-esi/next
25114 68/push 0x11/imm32/alloc-id:fake
25115 51/push-ecx/var1
25116 68/push 0x11/imm32/alloc-id:fake
25117 68/push 0x11/imm32/alloc-id:fake:payload
25118 89/<- %esi 4/r32/esp
25119 $test-add-literal-to-mem:initialize-stmt:
25120
25121 68/push 0/imm32/next
25122 68/push 0/imm32/next
25123 68/push 0/imm32/outputs
25124 68/push 0/imm32/outputs
25125 56/push-esi/inouts
25126 68/push 0x11/imm32/alloc-id:fake
25127 68/push 0/imm32/operation
25128 68/push 0/imm32/operation
25129 68/push 1/imm32/tag:stmt1
25130 89/<- %esi 4/r32/esp
25131 $test-add-literal-to-mem:initialize-stmt-operation:
25132
25133 8d/copy-address *(esi+4) 0/r32/eax
25134 (copy-array Heap "add-to" %eax)
25135
25136 c7 0/subop/copy *Curr-block-depth 0/imm32
25137 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
25138 (flush _test-output-buffered-file)
25139 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
25145
25146 (check-next-stream-line-equal _test-output-stream "81 0/subop/add *(ebp+0x00000008) 0x34/imm32" "F - test-add-literal-to-mem")
25147
25148 89/<- %esp 5/r32/ebp
25149 5d/pop-to-ebp
25150 c3/return
25151
25152 test-shift-reg-by-literal:
25153
25154
25155
25156
25157
25158 55/push-ebp
25159 89/<- %ebp 4/r32/esp
25160
25161 (clear-stream _test-output-stream)
25162 (clear-stream $_test-output-buffered-file->buffer)
25163 $test-shift-reg-by-literal:initialize-var-type:
25164
25165 68/push 0/imm32/right:null
25166 68/push 0/imm32/right:null
25167 68/push 0/imm32/left:unused
25168 68/push 1/imm32/value:int
25169 68/push 1/imm32/is-atom?:true
25170 68/push 0x11/imm32/alloc-id:fake:payload
25171 89/<- %ecx 4/r32/esp
25172 $test-shift-reg-by-literal:initialize-var:
25173
25174 68/push 0/imm32/register
25175 68/push 0/imm32/register
25176 68/push 0/imm32/no-stack-offset
25177 68/push 1/imm32/block-depth
25178 51/push-ecx
25179 68/push 0x11/imm32/alloc-id:fake
25180 68/push 0/imm32/name
25181 68/push 0/imm32/name
25182 68/push 0x11/imm32/alloc-id:fake:payload
25183 89/<- %ecx 4/r32/esp
25184 $test-shift-reg-by-literal:initialize-var-name:
25185
25186 8d/copy-address *(ecx+4) 0/r32/eax
25187 (copy-array Heap "v" %eax)
25188 $test-shift-reg-by-literal:initialize-var-register:
25189
25190 8d/copy-address *(ecx+0x1c) 0/r32/eax
25191 (copy-array Heap "ecx" %eax)
25192 $test-shift-reg-by-literal:initialize-literal-type:
25193
25194 68/push 0/imm32/right:null
25195 68/push 0/imm32/right:null
25196 68/push 0/imm32/left:unused
25197 68/push 0/imm32/value:literal
25198 68/push 1/imm32/is-atom?:true
25199 68/push 0x11/imm32/alloc-id:fake:payload
25200 89/<- %edx 4/r32/esp
25201 $test-shift-reg-by-literal:initialize-literal:
25202
25203 68/push 0/imm32/register
25204 68/push 0/imm32/register
25205 68/push 0/imm32/no-stack-offset
25206 68/push 1/imm32/block-depth
25207 52/push-edx
25208 68/push 0x11/imm32/alloc-id:fake
25209 68/push 0/imm32/name
25210 68/push 0/imm32/name
25211 68/push 0x11/imm32/alloc-id:fake:payload
25212 89/<- %edx 4/r32/esp
25213 $test-shift-reg-by-literal:initialize-literal-value:
25214
25215 8d/copy-address *(edx+4) 0/r32/eax
25216 (copy-array Heap "2" %eax)
25217 $test-shift-reg-by-literal:initialize-inouts:
25218
25219 68/push 0/imm32/is-deref:false
25220 68/push 0/imm32/next
25221 68/push 0/imm32/next
25222 52/push-edx/l
25223 68/push 0x11/imm32/alloc-id:fake
25224 68/push 0x11/imm32/alloc-id:fake:payload
25225 89/<- %esi 4/r32/esp
25226 $test-shift-reg-by-literal:initialize-outputs:
25227
25228 68/push 0/imm32/is-deref:false
25229 68/push 0/imm32/next
25230 68/push 0/imm32/next
25231 51/push-ecx/v
25232 68/push 0x11/imm32/alloc-id:fake
25233 68/push 0x11/imm32/alloc-id:fake:payload
25234 89/<- %edi 4/r32/esp
25235 $test-shift-reg-by-literal:initialize-stmt:
25236
25237 68/push 0/imm32/next
25238 68/push 0/imm32/next
25239 57/push-edi/outputs
25240 68/push 0x11/imm32/alloc-id:fake
25241 56/push-esi/inouts
25242 68/push 0x11/imm32/alloc-id:fake
25243 68/push 0/imm32/operation
25244 68/push 0/imm32/operation
25245 68/push 1/imm32/tag:stmt1
25246 89/<- %esi 4/r32/esp
25247 $test-shift-reg-by-literal:initialize-stmt-operation:
25248
25249 8d/copy-address *(esi+4) 0/r32/eax
25250 (copy-array Heap "shift-left" %eax)
25251
25252 c7 0/subop/copy *Curr-block-depth 0/imm32
25253 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
25254 (flush _test-output-buffered-file)
25255 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
25261
25262 (check-next-stream-line-equal _test-output-stream "c1/shift 4/subop/left %ecx 2/imm8" "F - test-shift-reg-by-literal")
25263
25264 89/<- %esp 5/r32/ebp
25265 5d/pop-to-ebp
25266 c3/return
25267
25268 test-shift-mem-by-literal:
25269
25270
25271
25272
25273
25274 55/push-ebp
25275 89/<- %ebp 4/r32/esp
25276
25277 (clear-stream _test-output-stream)
25278 (clear-stream $_test-output-buffered-file->buffer)
25279 $test-shift-mem-by-literal:initialize-type:
25280
25281 68/push 0/imm32/right:null
25282 68/push 0/imm32/right:null
25283 68/push 0/imm32/left:unused
25284 68/push 1/imm32/value:int
25285 68/push 1/imm32/is-atom?:true
25286 68/push 0x11/imm32/alloc-id:fake:payload
25287 89/<- %ecx 4/r32/esp
25288 $test-shift-mem-by-literal:initialize-var1:
25289
25290 68/push 0/imm32/register
25291 68/push 0/imm32/register
25292 68/push 8/imm32/stack-offset
25293 68/push 1/imm32/block-depth
25294 51/push-ecx
25295 68/push 0x11/imm32/alloc-id:fake
25296 68/push 0/imm32/name
25297 68/push 0/imm32/name
25298 68/push 0x11/imm32/alloc-id:fake:payload
25299 89/<- %ecx 4/r32/esp
25300 $test-shift-mem-by-literal:initialize-var1-name:
25301
25302 8d/copy-address *(ecx+4) 0/r32/eax
25303 (copy-array Heap "var1" %eax)
25304 $test-shift-mem-by-literal:initialize-literal-type:
25305
25306 68/push 0/imm32/right:null
25307 68/push 0/imm32/right:null
25308 68/push 0/imm32/left:unused
25309 68/push 0/imm32/value:literal
25310 68/push 1/imm32/is-atom?:true
25311 68/push 0x11/imm32/alloc-id:fake:payload
25312 89/<- %edx 4/r32/esp
25313 $test-shift-mem-by-literal:initialize-literal:
25314
25315 68/push 0/imm32/register
25316 68/push 0/imm32/register
25317 68/push 0/imm32/no-stack-offset
25318 68/push 1/imm32/block-depth
25319 52/push-edx
25320 68/push 0x11/imm32/alloc-id:fake
25321 68/push 0/imm32/name
25322 68/push 0/imm32/name
25323 68/push 0x11/imm32/alloc-id:fake:payload
25324 89/<- %edx 4/r32/esp
25325 $test-shift-mem-by-literal:initialize-literal-value:
25326
25327 8d/copy-address *(edx+4) 0/r32/eax
25328 (copy-array Heap "3" %eax)
25329 $test-shift-mem-by-literal:initialize-inouts:
25330
25331 68/push 0/imm32/is-deref:false
25332 68/push 0/imm32/next
25333 68/push 0/imm32/next
25334 52/push-edx/l
25335 68/push 0x11/imm32/alloc-id:fake
25336 68/push 0x11/imm32/alloc-id:fake:payload
25337 89/<- %esi 4/r32/esp
25338
25339 68/push 0/imm32/is-deref:false
25340 56/push-esi/next
25341 68/push 0x11/imm32/alloc-id:fake
25342 51/push-ecx/var1
25343 68/push 0x11/imm32/alloc-id:fake
25344 68/push 0x11/imm32/alloc-id:fake:payload
25345 89/<- %esi 4/r32/esp
25346 $test-shift-mem-by-literal:initialize-stmt:
25347
25348 68/push 0/imm32/next
25349 68/push 0/imm32/next
25350 68/push 0/imm32/outputs
25351 68/push 0/imm32/outputs
25352 56/push-esi/inouts
25353 68/push 0x11/imm32/alloc-id:fake
25354 68/push 0/imm32/operation
25355 68/push 0/imm32/operation
25356 68/push 1/imm32/tag:stmt1
25357 89/<- %esi 4/r32/esp
25358 $test-shift-mem-by-literal:initialize-stmt-operation:
25359
25360 8d/copy-address *(esi+4) 0/r32/eax
25361 (copy-array Heap "shift-left" %eax)
25362
25363 c7 0/subop/copy *Curr-block-depth 0/imm32
25364 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
25365 (flush _test-output-buffered-file)
25366 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
25372
25373 (check-next-stream-line-equal _test-output-stream "c1/shift 4/subop/left *(ebp+0x00000008) 3/imm8" "F - test-shift-mem-by-literal")
25374
25375 89/<- %esp 5/r32/ebp
25376 5d/pop-to-ebp
25377 c3/return
25378
25379 test-compare-reg-with-reg:
25380
25381
25382
25383
25384
25385 55/push-ebp
25386 89/<- %ebp 4/r32/esp
25387
25388 (clear-stream _test-output-stream)
25389 (clear-stream $_test-output-buffered-file->buffer)
25390 $test-compare-reg-with-reg:initialize-type:
25391
25392 68/push 0/imm32/right:null
25393 68/push 0/imm32/right:null
25394 68/push 0/imm32/left:unused
25395 68/push 1/imm32/value:int
25396 68/push 1/imm32/is-atom?:true
25397 68/push 0x11/imm32/alloc-id:fake:payload
25398 89/<- %ecx 4/r32/esp
25399 $test-compare-reg-with-reg:initialize-var1:
25400
25401 68/push 0/imm32/register
25402 68/push 0/imm32/register
25403 68/push 0/imm32/no-stack-offset
25404 68/push 1/imm32/block-depth
25405 51/push-ecx
25406 68/push 0x11/imm32/alloc-id:fake
25407 68/push 0/imm32/name
25408 68/push 0/imm32/name
25409 68/push 0x11/imm32/alloc-id:fake:payload
25410 89/<- %ecx 4/r32/esp
25411 $test-compare-reg-with-reg:initialize-var1-name:
25412
25413 8d/copy-address *(ecx+4) 0/r32/eax
25414 (copy-array Heap "var1" %eax)
25415 $test-compare-reg-with-reg:initialize-var1-register:
25416
25417 8d/copy-address *(ecx+0x1c) 0/r32/eax
25418 (copy-array Heap "ecx" %eax)
25419 $test-compare-reg-with-reg:initialize-var2:
25420
25421 68/push 0/imm32/register
25422 68/push 0/imm32/register
25423 68/push 0/imm32/no-stack-offset
25424 68/push 1/imm32/block-depth
25425 ff 6/subop/push *(ecx+0x10)
25426 68/push 0x11/imm32/alloc-id:fake
25427 68/push 0/imm32/name
25428 68/push 0/imm32/name
25429 68/push 0x11/imm32/alloc-id:fake:payload
25430 89/<- %edx 4/r32/esp
25431 $test-compare-reg-with-reg:initialize-var2-name:
25432
25433 8d/copy-address *(edx+4) 0/r32/eax
25434 (copy-array Heap "var2" %eax)
25435 $test-compare-reg-with-reg:initialize-var2-register:
25436
25437 8d/copy-address *(edx+0x1c) 0/r32/eax
25438 (copy-array Heap "eax" %eax)
25439 $test-compare-reg-with-reg:initialize-inouts:
25440
25441 68/push 0/imm32/is-deref:false
25442 68/push 0/imm32/next
25443 68/push 0/imm32/next
25444 52/push-edx/var2
25445 68/push 0x11/imm32/alloc-id:fake
25446 68/push 0x11/imm32/alloc-id:fake:payload
25447 89/<- %esi 4/r32/esp
25448
25449 68/push 0/imm32/is-deref:false
25450 56/push-esi/next
25451 68/push 0x11/imm32/alloc-id:fake
25452 51/push-ecx/var1
25453 68/push 0x11/imm32/alloc-id:fake
25454 68/push 0x11/imm32/alloc-id:fake:payload
25455 89/<- %esi 4/r32/esp
25456 $test-compare-reg-with-reg:initialize-stmt:
25457
25458 68/push 0/imm32/next
25459 68/push 0/imm32/next
25460 68/push 0/imm32/outputs
25461 68/push 0/imm32/outputs
25462 56/push-esi/inouts
25463 68/push 0x11/imm32/alloc-id:fake
25464 68/push 0/imm32/operation
25465 68/push 0/imm32/operation
25466 68/push 1/imm32/tag:stmt1
25467 89/<- %esi 4/r32/esp
25468 $test-compare-reg-with-reg:initialize-stmt-operation:
25469
25470 8d/copy-address *(esi+4) 0/r32/eax
25471 (copy-array Heap "compare" %eax)
25472
25473 c7 0/subop/copy *Curr-block-depth 0/imm32
25474 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
25475 (flush _test-output-buffered-file)
25476 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
25482
25483 (check-next-stream-line-equal _test-output-stream "39/compare-> %ecx 0x00000000/r32" "F - test-compare-reg-with-reg")
25484
25485 89/<- %esp 5/r32/ebp
25486 5d/pop-to-ebp
25487 c3/return
25488
25489 test-compare-mem-with-reg:
25490
25491
25492
25493
25494
25495 55/push-ebp
25496 89/<- %ebp 4/r32/esp
25497
25498 (clear-stream _test-output-stream)
25499 (clear-stream $_test-output-buffered-file->buffer)
25500 $test-compare-mem-with-reg:initialize-type:
25501
25502 68/push 0/imm32/right:null
25503 68/push 0/imm32/right:null
25504 68/push 0/imm32/left:unused
25505 68/push 1/imm32/value:int
25506 68/push 1/imm32/is-atom?:true
25507 68/push 0x11/imm32/alloc-id:fake:payload
25508 89/<- %ecx 4/r32/esp
25509 $test-compare-mem-with-reg:initialize-var1:
25510
25511 68/push 0/imm32/register
25512 68/push 0/imm32/register
25513 68/push 8/imm32/stack-offset
25514 68/push 1/imm32/block-depth
25515 51/push-ecx
25516 68/push 0x11/imm32/alloc-id:fake
25517 68/push 0/imm32/name
25518 68/push 0/imm32/name
25519 68/push 0x11/imm32/alloc-id:fake:payload
25520 89/<- %ecx 4/r32/esp
25521 $test-compare-mem-with-reg:initialize-var1-name:
25522
25523 8d/copy-address *(ecx+4) 0/r32/eax
25524 (copy-array Heap "var1" %eax)
25525 $test-compare-mem-with-reg:initialize-var2:
25526
25527 68/push 0/imm32/register
25528 68/push 0/imm32/register
25529 68/push 0/imm32/no-stack-offset
25530 68/push 1/imm32/block-depth
25531 ff 6/subop/push *(ecx+0x10)
25532 68/push 0x11/imm32/alloc-id:fake
25533 68/push 0/imm32/name
25534 68/push 0/imm32/name
25535 68/push 0x11/imm32/alloc-id:fake:payload
25536 89/<- %edx 4/r32/esp
25537 $test-compare-mem-with-reg:initialize-var2-name:
25538
25539 8d/copy-address *(edx+4) 0/r32/eax
25540 (copy-array Heap "var2" %eax)
25541 $test-compare-mem-with-reg:initialize-var2-register:
25542
25543 8d/copy-address *(edx+0x1c) 0/r32/eax
25544 (copy-array Heap "eax" %eax)
25545 $test-compare-mem-with-reg:initialize-inouts:
25546
25547 68/push 0/imm32/is-deref:false
25548 68/push 0/imm32/next
25549 68/push 0/imm32/next
25550 52/push-edx/var2
25551 68/push 0x11/imm32/alloc-id:fake
25552 68/push 0x11/imm32/alloc-id:fake:payload
25553 89/<- %esi 4/r32/esp
25554
25555 68/push 0/imm32/is-deref:false
25556 56/push-esi/next
25557 68/push 0x11/imm32/alloc-id:fake
25558 51/push-ecx/var1
25559 68/push 0x11/imm32/alloc-id:fake
25560 68/push 0x11/imm32/alloc-id:fake:payload
25561 89/<- %esi 4/r32/esp
25562 $test-compare-mem-with-reg:initialize-stmt:
25563
25564 68/push 0/imm32/next
25565 68/push 0/imm32/next
25566 68/push 0/imm32/outputs
25567 68/push 0/imm32/outputs
25568 56/push-esi/inouts
25569 68/push 0x11/imm32/alloc-id:fake
25570 68/push 0/imm32/operation
25571 68/push 0/imm32/operation
25572 68/push 1/imm32/tag:stmt1
25573 89/<- %esi 4/r32/esp
25574 $test-compare-mem-with-reg:initialize-stmt-operation:
25575
25576 8d/copy-address *(esi+4) 0/r32/eax
25577 (copy-array Heap "compare" %eax)
25578
25579 c7 0/subop/copy *Curr-block-depth 0/imm32
25580 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
25581 (flush _test-output-buffered-file)
25582 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
25588
25589 (check-next-stream-line-equal _test-output-stream "39/compare-> *(ebp+0x00000008) 0x00000000/r32" "F - test-compare-mem-with-reg")
25590
25591 89/<- %esp 5/r32/ebp
25592 5d/pop-to-ebp
25593 c3/return
25594
25595 test-compare-reg-with-mem:
25596
25597
25598
25599
25600
25601 55/push-ebp
25602 89/<- %ebp 4/r32/esp
25603
25604 (clear-stream _test-output-stream)
25605 (clear-stream $_test-output-buffered-file->buffer)
25606 $test-compare-reg-with-mem:initialize-type:
25607
25608 68/push 0/imm32/right:null
25609 68/push 0/imm32/right:null
25610 68/push 0/imm32/left:unused
25611 68/push 1/imm32/value:int
25612 68/push 1/imm32/is-atom?:true
25613 68/push 0x11/imm32/alloc-id:fake:payload
25614 89/<- %ecx 4/r32/esp
25615 $test-compare-reg-with-mem:initialize-var1:
25616
25617 68/push 0/imm32/register
25618 68/push 0/imm32/register
25619 68/push 0/imm32/no-stack-offset
25620 68/push 1/imm32/block-depth
25621 51/push-ecx
25622 68/push 0x11/imm32/alloc-id:fake
25623 68/push 0/imm32/name
25624 68/push 0/imm32/name
25625 68/push 0x11/imm32/alloc-id:fake:payload
25626 89/<- %ecx 4/r32/esp
25627 $test-compare-reg-with-mem:initialize-var1-name:
25628
25629 8d/copy-address *(ecx+4) 0/r32/eax
25630 (copy-array Heap "var1" %eax)
25631 $test-compare-reg-with-mem:initialize-var1-register:
25632
25633 8d/copy-address *(ecx+0x1c) 0/r32/eax
25634 (copy-array Heap "eax" %eax)
25635 $test-compare-reg-with-mem:initialize-var2:
25636
25637 68/push 0/imm32/register
25638 68/push 0/imm32/register
25639 68/push 8/imm32/stack-offset
25640 68/push 1/imm32/block-depth
25641 ff 6/subop/push *(ecx+0x10)
25642 68/push 0x11/imm32/alloc-id:fake
25643 68/push 0/imm32/name
25644 68/push 0/imm32/name
25645 68/push 0x11/imm32/alloc-id:fake:payload
25646 89/<- %edx 4/r32/esp
25647 $test-compare-reg-with-mem:initialize-var2-name:
25648
25649 8d/copy-address *(edx+4) 0/r32/eax
25650 (copy-array Heap "var2" %eax)
25651 $test-compare-reg-with-mem:initialize-inouts:
25652
25653 68/push 0/imm32/is-deref:false
25654 68/push 0/imm32/next
25655 68/push 0/imm32/next
25656 52/push-edx/var2
25657 68/push 0x11/imm32/alloc-id:fake
25658 68/push 0x11/imm32/alloc-id:fake:payload
25659 89/<- %esi 4/r32/esp
25660
25661 68/push 0/imm32/is-deref:false
25662 56/push-esi/next
25663 68/push 0x11/imm32/alloc-id:fake
25664 51/push-ecx/var1
25665 68/push 0x11/imm32/alloc-id:fake
25666 68/push 0x11/imm32/alloc-id:fake:payload
25667 89/<- %esi 4/r32/esp
25668 $test-compare-reg-with-mem:initialize-stmt:
25669
25670 68/push 0/imm32/next
25671 68/push 0/imm32/next
25672 68/push 0/imm32/outputs
25673 68/push 0/imm32/outputs
25674 56/push-esi/inouts
25675 68/push 0x11/imm32/alloc-id:fake
25676 68/push 0/imm32/operation
25677 68/push 0/imm32/operation
25678 68/push 1/imm32/tag:stmt1
25679 89/<- %esi 4/r32/esp
25680 $test-compare-reg-with-mem:initialize-stmt-operation:
25681
25682 8d/copy-address *(esi+4) 0/r32/eax
25683 (copy-array Heap "compare" %eax)
25684
25685 c7 0/subop/copy *Curr-block-depth 0/imm32
25686 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
25687 (flush _test-output-buffered-file)
25688 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
25694
25695 (check-next-stream-line-equal _test-output-stream "3b/compare<- *(ebp+0x00000008) 0x00000000/r32" "F - test-compare-reg-with-mem")
25696
25697 89/<- %esp 5/r32/ebp
25698 5d/pop-to-ebp
25699 c3/return
25700
25701 test-compare-mem-with-literal:
25702
25703
25704
25705
25706
25707 55/push-ebp
25708 89/<- %ebp 4/r32/esp
25709
25710 (clear-stream _test-output-stream)
25711 (clear-stream $_test-output-buffered-file->buffer)
25712 $test-compare-mem-with-literal:initialize-type:
25713
25714 68/push 0/imm32/right:null
25715 68/push 0/imm32/right:null
25716 68/push 0/imm32/left:unused
25717 68/push 1/imm32/value:int
25718 68/push 1/imm32/is-atom?:true
25719 68/push 0x11/imm32/alloc-id:fake:payload
25720 89/<- %ecx 4/r32/esp
25721 $test-compare-mem-with-literal:initialize-var1:
25722
25723 68/push 0/imm32/register
25724 68/push 0/imm32/register
25725 68/push 8/imm32/stack-offset
25726 68/push 1/imm32/block-depth
25727 51/push-ecx
25728 68/push 0x11/imm32/alloc-id:fake
25729 68/push 0/imm32/name
25730 68/push 0/imm32/name
25731 68/push 0x11/imm32/alloc-id:fake:payload
25732 89/<- %ecx 4/r32/esp
25733 $test-compare-mem-with-literal:initialize-var1-name:
25734
25735 8d/copy-address *(ecx+4) 0/r32/eax
25736 (copy-array Heap "var1" %eax)
25737 $test-compare-mem-with-literal:initialize-literal-type:
25738
25739 68/push 0/imm32/right:null
25740 68/push 0/imm32/right:null
25741 68/push 0/imm32/left:unused
25742 68/push 0/imm32/value:literal
25743 68/push 1/imm32/is-atom?:true
25744 68/push 0x11/imm32/alloc-id:fake:payload
25745 89/<- %edx 4/r32/esp
25746 $test-compare-mem-with-literal:initialize-literal:
25747
25748 68/push 0/imm32/register
25749 68/push 0/imm32/register
25750 68/push 0/imm32/no-stack-offset
25751 68/push 1/imm32/block-depth
25752 52/push-edx
25753 68/push 0x11/imm32/alloc-id:fake
25754 68/push 0/imm32/name
25755 68/push 0/imm32/name
25756 68/push 0x11/imm32/alloc-id:fake:payload
25757 89/<- %edx 4/r32/esp
25758 $test-compare-mem-with-literal:initialize-literal-value:
25759
25760 8d/copy-address *(edx+4) 0/r32/eax
25761 (copy-array Heap "0x34" %eax)
25762 $test-compare-mem-with-literal:initialize-inouts:
25763
25764 68/push 0/imm32/is-deref:false
25765 68/push 0/imm32/next
25766 68/push 0/imm32/next
25767 52/push-edx/l
25768 68/push 0x11/imm32/alloc-id:fake
25769 68/push 0x11/imm32/alloc-id:fake:payload
25770 89/<- %esi 4/r32/esp
25771
25772 68/push 0/imm32/is-deref:false
25773 56/push-esi/next
25774 68/push 0x11/imm32/alloc-id:fake
25775 51/push-ecx/var1
25776 68/push 0x11/imm32/alloc-id:fake
25777 68/push 0x11/imm32/alloc-id:fake:payload
25778 89/<- %esi 4/r32/esp
25779 $test-compare-mem-with-literal:initialize-stmt:
25780
25781 68/push 0/imm32/next
25782 68/push 0/imm32/next
25783 68/push 0/imm32/outputs
25784 68/push 0/imm32/outputs
25785 56/push-esi/inouts
25786 68/push 0x11/imm32/alloc-id:fake
25787 68/push 0/imm32/operation
25788 68/push 0/imm32/operation
25789 68/push 1/imm32/tag:stmt1
25790 89/<- %esi 4/r32/esp
25791 $test-compare-mem-with-literal:initialize-stmt-operation:
25792
25793 8d/copy-address *(esi+4) 0/r32/eax
25794 (copy-array Heap "compare" %eax)
25795
25796 c7 0/subop/copy *Curr-block-depth 0/imm32
25797 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
25798 (flush _test-output-buffered-file)
25799 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
25805
25806 (check-next-stream-line-equal _test-output-stream "81 7/subop/compare *(ebp+0x00000008) 0x34/imm32" "F - test-compare-mem-with-literal")
25807
25808 89/<- %esp 5/r32/ebp
25809 5d/pop-to-ebp
25810 c3/return
25811
25812 test-compare-eax-with-literal:
25813
25814
25815
25816
25817
25818 55/push-ebp
25819 89/<- %ebp 4/r32/esp
25820
25821 (clear-stream _test-output-stream)
25822 (clear-stream $_test-output-buffered-file->buffer)
25823 $test-compare-eax-with-literal:initialize-type:
25824
25825 68/push 0/imm32/right:null
25826 68/push 0/imm32/right:null
25827 68/push 0/imm32/left:unused
25828 68/push 1/imm32/value:int
25829 68/push 1/imm32/is-atom?:true
25830 68/push 0x11/imm32/alloc-id:fake:payload
25831 89/<- %ecx 4/r32/esp
25832 $test-compare-eax-with-literal:initialize-var1:
25833
25834 68/push 0/imm32/register
25835 68/push 0/imm32/register
25836 68/push 0/imm32/no-stack-offset
25837 68/push 1/imm32/block-depth
25838 51/push-ecx
25839 68/push 0x11/imm32/alloc-id:fake
25840 68/push 0/imm32/name
25841 68/push 0/imm32/name
25842 68/push 0x11/imm32/alloc-id:fake:payload
25843 89/<- %ecx 4/r32/esp
25844 $test-compare-eax-with-literal:initialize-var1-name:
25845
25846 8d/copy-address *(ecx+4) 0/r32/eax
25847 (copy-array Heap "var1" %eax)
25848 $test-compare-eax-with-literal:initialize-var1-register:
25849
25850 8d/copy-address *(ecx+0x1c) 0/r32/eax
25851 (copy-array Heap "eax" %eax)
25852 $test-compare-eax-with-literal:initialize-literal-type:
25853
25854 68/push 0/imm32/right:null
25855 68/push 0/imm32/right:null
25856 68/push 0/imm32/left:unused
25857 68/push 0/imm32/value:literal
25858 68/push 1/imm32/is-atom?:true
25859 68/push 0x11/imm32/alloc-id:fake:payload
25860 89/<- %edx 4/r32/esp
25861 $test-compare-eax-with-literal:initialize-literal:
25862
25863 68/push 0/imm32/register
25864 68/push 0/imm32/register
25865 68/push 0/imm32/no-stack-offset
25866 68/push 1/imm32/block-depth
25867 52/push-edx
25868 68/push 0x11/imm32/alloc-id:fake
25869 68/push 0/imm32/name
25870 68/push 0/imm32/name
25871 68/push 0x11/imm32/alloc-id:fake:payload
25872 89/<- %edx 4/r32/esp
25873 $test-compare-eax-with-literal:initialize-literal-value:
25874
25875 8d/copy-address *(edx+4) 0/r32/eax
25876 (copy-array Heap "0x34" %eax)
25877 $test-compare-eax-with-literal:initialize-inouts:
25878
25879 68/push 0/imm32/is-deref:false
25880 68/push 0/imm32/next
25881 68/push 0/imm32/next
25882 52/push-edx/l
25883 68/push 0x11/imm32/alloc-id:fake
25884 68/push 0x11/imm32/alloc-id:fake:payload
25885 89/<- %esi 4/r32/esp
25886
25887 68/push 0/imm32/is-deref:false
25888 56/push-esi/next
25889 68/push 0x11/imm32/alloc-id:fake
25890 51/push-ecx/var1
25891 68/push 0x11/imm32/alloc-id:fake
25892 68/push 0x11/imm32/alloc-id:fake:payload
25893 89/<- %esi 4/r32/esp
25894 $test-compare-eax-with-literal:initialize-stmt:
25895
25896 68/push 0/imm32/next
25897 68/push 0/imm32/next
25898 68/push 0/imm32/outputs
25899 68/push 0/imm32/outputs
25900 56/push-esi/inouts
25901 68/push 0x11/imm32/alloc-id:fake
25902 68/push 0/imm32/operation
25903 68/push 0/imm32/operation
25904 68/push 1/imm32/tag:stmt1
25905 89/<- %esi 4/r32/esp
25906 $test-compare-eax-with-literal:initialize-stmt-operation:
25907
25908 8d/copy-address *(esi+4) 0/r32/eax
25909 (copy-array Heap "compare" %eax)
25910
25911 c7 0/subop/copy *Curr-block-depth 0/imm32
25912 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
25913 (flush _test-output-buffered-file)
25914 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
25920
25921 (check-next-stream-line-equal _test-output-stream "3d/compare-eax-with 0x34/imm32" "F - test-compare-eax-with-literal")
25922
25923 89/<- %esp 5/r32/ebp
25924 5d/pop-to-ebp
25925 c3/return
25926
25927 test-compare-reg-with-literal:
25928
25929
25930
25931
25932
25933 55/push-ebp
25934 89/<- %ebp 4/r32/esp
25935
25936 (clear-stream _test-output-stream)
25937 (clear-stream $_test-output-buffered-file->buffer)
25938 $test-compare-reg-with-literal:initialize-type:
25939
25940 68/push 0/imm32/right:null
25941 68/push 0/imm32/right:null
25942 68/push 0/imm32/left:unused
25943 68/push 1/imm32/value:int
25944 68/push 1/imm32/is-atom?:true
25945 68/push 0x11/imm32/alloc-id:fake:payload
25946 89/<- %ecx 4/r32/esp
25947 $test-compare-reg-with-literal:initialize-var1:
25948
25949 68/push 0/imm32/register
25950 68/push 0/imm32/register
25951 68/push 0/imm32/no-stack-offset
25952 68/push 1/imm32/block-depth
25953 51/push-ecx
25954 68/push 0x11/imm32/alloc-id:fake
25955 68/push 0/imm32/name
25956 68/push 0/imm32/name
25957 68/push 0x11/imm32/alloc-id:fake:payload
25958 89/<- %ecx 4/r32/esp
25959 $test-compare-reg-with-literal:initialize-var1-name:
25960
25961 8d/copy-address *(ecx+4) 0/r32/eax
25962 (copy-array Heap "var1" %eax)
25963 $test-compare-reg-with-literal:initialize-var1-register:
25964
25965 8d/copy-address *(ecx+0x1c) 0/r32/eax
25966 (copy-array Heap "ecx" %eax)
25967 $test-compare-reg-with-literal:initialize-literal-type:
25968
25969 68/push 0/imm32/right:null
25970 68/push 0/imm32/right:null
25971 68/push 0/imm32/left:unused
25972 68/push 0/imm32/value:literal
25973 68/push 1/imm32/is-atom?:true
25974 68/push 0x11/imm32/alloc-id:fake:payload
25975 89/<- %edx 4/r32/esp
25976 $test-compare-reg-with-literal:initialize-literal:
25977
25978 68/push 0/imm32/register
25979 68/push 0/imm32/register
25980 68/push 0/imm32/no-stack-offset
25981 68/push 1/imm32/block-depth
25982 52/push-edx
25983 68/push 0x11/imm32/alloc-id:fake
25984 68/push 0/imm32/name
25985 68/push 0/imm32/name
25986 68/push 0x11/imm32/alloc-id:fake:payload
25987 89/<- %edx 4/r32/esp
25988 $test-compare-reg-with-literal:initialize-literal-value:
25989
25990 8d/copy-address *(edx+4) 0/r32/eax
25991 (copy-array Heap "0x34" %eax)
25992 $test-compare-reg-with-literal:initialize-inouts:
25993
25994 68/push 0/imm32/is-deref:false
25995 68/push 0/imm32/next
25996 68/push 0/imm32/next
25997 52/push-edx/l
25998 68/push 0x11/imm32/alloc-id:fake
25999 68/push 0x11/imm32/alloc-id:fake:payload
26000 89/<- %esi 4/r32/esp
26001
26002 68/push 0/imm32/is-deref:false
26003 56/push-esi/next
26004 68/push 0x11/imm32/alloc-id:fake
26005 51/push-ecx/var1
26006 68/push 0x11/imm32/alloc-id:fake
26007 68/push 0x11/imm32/alloc-id:fake:payload
26008 89/<- %esi 4/r32/esp
26009 $test-compare-reg-with-literal:initialize-stmt:
26010
26011 68/push 0/imm32/next
26012 68/push 0/imm32/next
26013 68/push 0/imm32/outputs
26014 68/push 0/imm32/outputs
26015 56/push-esi/inouts
26016 68/push 0x11/imm32/alloc-id:fake
26017 68/push 0/imm32/operation
26018 68/push 0/imm32/operation
26019 68/push 1/imm32/tag:stmt1
26020 89/<- %esi 4/r32/esp
26021 $test-compare-reg-with-literal:initialize-stmt-operation:
26022
26023 8d/copy-address *(esi+4) 0/r32/eax
26024 (copy-array Heap "compare" %eax)
26025
26026 c7 0/subop/copy *Curr-block-depth 0/imm32
26027 (emit-subx-stmt _test-output-buffered-file %esi Primitives Stderr 0)
26028 (flush _test-output-buffered-file)
26029 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
26035
26036 (check-next-stream-line-equal _test-output-stream "81 7/subop/compare %ecx 0x34/imm32" "F - test-compare-reg-with-literal")
26037
26038 89/<- %esp 5/r32/ebp
26039 5d/pop-to-ebp
26040 c3/return
26041
26042 test-emit-subx-stmt-function-call:
26043
26044
26045
26046
26047
26048
26049
26050
26051
26052
26053
26054
26055
26056
26057
26058
26059
26060 55/push-ebp
26061 89/<- %ebp 4/r32/esp
26062
26063 (clear-stream _test-output-stream)
26064 (clear-stream $_test-output-buffered-file->buffer)
26065 $test-emit-subx-function-call:initialize-type:
26066
26067 68/push 0/imm32/right:null
26068 68/push 0/imm32/right:null
26069 68/push 0/imm32/left:unused
26070 68/push 1/imm32/value:int
26071 68/push 1/imm32/is-atom?:true
26072 68/push 0x11/imm32/alloc-id:fake:payload
26073 89/<- %ecx 4/r32/esp
26074 $test-emit-subx-function-call:initialize-var:
26075
26076 68/push 0/imm32/no-register
26077 68/push 0/imm32/no-register
26078 68/push -8/imm32/stack-offset
26079 68/push 1/imm32/block-depth
26080 51/push-ecx/type
26081 68/push 0x11/imm32/alloc-id:fake
26082 68/push 0/imm32/name
26083 68/push 0/imm32/name
26084 68/push 0x11/imm32/alloc-id:fake:payload
26085 89/<- %ecx 4/r32/esp
26086 $test-emit-subx-function-call:initialize-var-name:
26087
26088 8d/copy-address *(ecx+4) 0/r32/eax
26089 (copy-array Heap "foo" %eax)
26090 $test-emit-subx-function-call:initialize-stmt-var:
26091
26092 68/push 0/imm32/is-deref:false
26093 68/push 0/imm32/next
26094 68/push 0/imm32/next
26095 51/push-ecx/var-foo
26096 68/push 0x11/imm32/alloc-id:fake
26097 68/push 0x11/imm32/alloc-id:fake:payload
26098 89/<- %ebx 4/r32/esp
26099 $test-emit-subx-function-call:initialize-stmt:
26100
26101 68/push 0/imm32/no-outputs
26102 68/push 0/imm32/no-outputs
26103 53/push-ebx/inouts
26104 68/push 0x11/imm32/alloc-id:fake
26105 68/push 0/imm32/operation
26106 68/push 0/imm32/operation
26107 68/push 1/imm32/tag
26108 89/<- %esi 4/r32/esp
26109 $test-emit-subx-function-call:initialize-stmt-operation:
26110
26111 8d/copy-address *(esi+4) 0/r32/eax
26112 (copy-array Heap "f" %eax)
26113
26114 c7 0/subop/copy *Curr-block-depth 0/imm32
26115 (emit-subx-stmt _test-output-buffered-file %esi 0 Stderr 0)
26116 (flush _test-output-buffered-file)
26117 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
26123
26124 (check-next-stream-line-equal _test-output-stream "(f *(ebp+0xfffffff8))" "F - test-emit-subx-stmt-function-call")
26125
26126 89/<- %esp 5/r32/ebp
26127 5d/pop-to-ebp
26128 c3/return
26129
26130 test-emit-subx-stmt-function-call-with-literal-arg:
26131
26132
26133
26134
26135
26136
26137 55/push-ebp
26138 89/<- %ebp 4/r32/esp
26139
26140 (clear-stream _test-output-stream)
26141 (clear-stream $_test-output-buffered-file->buffer)
26142 $test-emit-subx-function-call-with-literal-arg:initialize-type:
26143
26144 68/push 0/imm32/right:null
26145 68/push 0/imm32/right:null
26146 68/push 0/imm32/left:unused
26147 68/push 0/imm32/value:literal
26148 68/push 1/imm32/is-atom?:true
26149 68/push 0x11/imm32/alloc-id:fake:payload
26150 89/<- %ecx 4/r32/esp
26151 $test-emit-subx-function-call-with-literal-arg:initialize-var:
26152
26153 68/push 0/imm32/no-register
26154 68/push 0/imm32/no-register
26155 68/push 0/imm32/no-stack-offset
26156 68/push 1/imm32/block-depth
26157 51/push-ecx/type
26158 68/push 0x11/imm32/alloc-id:fake
26159 68/push 0/imm32/name
26160 68/push 0/imm32/name
26161 68/push 0x11/imm32/alloc-id:fake:payload
26162 89/<- %ecx 4/r32/esp
26163 $test-emit-subx-function-call-with-literal-arg:initialize-var-name:
26164
26165 8d/copy-address *(ecx+4) 0/r32/eax
26166 (copy-array Heap "0x34" %eax)
26167 $test-emit-subx-function-call-with-literal-arg:initialize-stmt-var:
26168
26169 68/push 0/imm32/is-deref:false
26170 68/push 0/imm32/next
26171 68/push 0/imm32/next
26172 51/push-ecx/var-foo
26173 68/push 0x11/imm32/alloc-id:fake
26174 68/push 0x11/imm32/alloc-id:fake:payload
26175 89/<- %ebx 4/r32/esp
26176 $test-emit-subx-function-call-with-literal-arg:initialize-stmt:
26177
26178 68/push 0/imm32/no-outputs
26179 68/push 0/imm32/no-outputs
26180 53/push-ebx/inouts
26181 68/push 0x11/imm32/alloc-id:fake
26182 68/push 0/imm32/operation
26183 68/push 0/imm32/operation
26184 68/push 1/imm32/tag
26185 89/<- %esi 4/r32/esp
26186 $test-emit-subx-function-call-with-literal-arg:initialize-stmt-operation:
26187
26188 8d/copy-address *(esi+4) 0/r32/eax
26189 (copy-array Heap "f" %eax)
26190
26191 c7 0/subop/copy *Curr-block-depth 0/imm32
26192 (emit-subx-stmt _test-output-buffered-file %esi 0 %ebx Stderr 0)
26193 (flush _test-output-buffered-file)
26194 +-- 6 lines: #? # dump _test-output-stream -----------------------------------------------------------------------------------------------------------------------------------------
26200
26201 (check-next-stream-line-equal _test-output-stream "(f 0x34)" "F - test-emit-subx-stmt-function-call-with-literal-arg")
26202
26203 89/<- %esp 5/r32/ebp
26204 5d/pop-to-ebp
26205 c3/return
26206
26207 emit-indent:
26208
26209 55/push-ebp
26210 89/<- %ebp 4/r32/esp
26211
26212 50/push-eax
26213
26214 8b/-> *(ebp+0xc) 0/r32/eax
26215 {
26216
26217 3d/compare-eax-with 0/imm32
26218 7e/jump-if-<= break/disp8
26219 (write-buffered *(ebp+8) " ")
26220 48/decrement-eax
26221 eb/jump loop/disp8
26222 }
26223 $emit-indent:end:
26224
26225 58/pop-to-eax
26226
26227 89/<- %esp 5/r32/ebp
26228 5d/pop-to-ebp
26229 c3/return
26230
26231 emit-subx-prologue:
26232
26233 55/push-ebp
26234 89/<- %ebp 4/r32/esp
26235
26236 (write-buffered *(ebp+8) " # . prologue\n")
26237 (write-buffered *(ebp+8) " 55/push-ebp\n")
26238 (write-buffered *(ebp+8) " 89/<- %ebp 4/r32/esp\n")
26239 $emit-subx-prologue:end:
26240
26241 89/<- %esp 5/r32/ebp
26242 5d/pop-to-ebp
26243 c3/return
26244
26245 emit-subx-epilogue:
26246
26247 55/push-ebp
26248 89/<- %ebp 4/r32/esp
26249
26250 (write-buffered *(ebp+8) " # . epilogue\n")
26251 (write-buffered *(ebp+8) " 89/<- %esp 5/r32/ebp\n")
26252 (write-buffered *(ebp+8) " 5d/pop-to-ebp\n")
26253 (write-buffered *(ebp+8) " c3/return\n")
26254 $emit-subx-epilogue:end:
26255
26256 89/<- %esp 5/r32/ebp
26257 5d/pop-to-ebp
26258 c3/return