* Moved lcc and q3asm into code/tools
This commit is contained in:
parent
b1cef6352e
commit
ad118b9baf
452 changed files with 0 additions and 0 deletions
235
code/tools/lcc/mips/irix/tst/array.sbk
Normal file
235
code/tools/lcc/mips/irix/tst/array.sbk
Normal file
|
@ -0,0 +1,235 @@
|
|||
.set reorder
|
||||
.globl main
|
||||
.text
|
||||
.text
|
||||
.align 2
|
||||
.ent main
|
||||
main:
|
||||
.frame $sp,88,$31
|
||||
.set noreorder
|
||||
.cpload $25
|
||||
.set reorder
|
||||
addu $sp,$sp,-88
|
||||
.mask 0xc2c00000,-56
|
||||
sw $22,16($sp)
|
||||
sw $23,20($sp)
|
||||
.cprestore 24
|
||||
sw $30,28($sp)
|
||||
sw $31,32($sp)
|
||||
move $23,$0
|
||||
L.2:
|
||||
move $30,$0
|
||||
L.6:
|
||||
sll $24,$30,2
|
||||
sll $15,$23,4
|
||||
la $15,x($15)
|
||||
addu $24,$24,$15
|
||||
la $15,1000
|
||||
mul $15,$15,$23
|
||||
addu $15,$15,$30
|
||||
sw $15,($24)
|
||||
L.7:
|
||||
la $30,1($30)
|
||||
la $24,4
|
||||
blt $30,$24,L.6
|
||||
sll $24,$23,2
|
||||
sll $15,$23,4
|
||||
la $15,x($15)
|
||||
sw $15,y($24)
|
||||
L.3:
|
||||
la $23,1($23)
|
||||
la $24,3
|
||||
blt $23,$24,L.2
|
||||
jal f
|
||||
move $23,$0
|
||||
L.10:
|
||||
sll $24,$23,4
|
||||
la $15,-48+88($sp)
|
||||
addu $24,$24,$15
|
||||
move $22,$24
|
||||
sll $15,$23,2
|
||||
sw $24,y($15)
|
||||
move $30,$0
|
||||
L.14:
|
||||
sll $24,$30,2
|
||||
addu $15,$24,$22
|
||||
sll $14,$23,4
|
||||
la $14,x($14)
|
||||
addu $24,$24,$14
|
||||
lw $24,($24)
|
||||
sw $24,($15)
|
||||
L.15:
|
||||
la $30,1($30)
|
||||
la $24,4
|
||||
blt $30,$24,L.14
|
||||
L.11:
|
||||
la $23,1($23)
|
||||
la $24,3
|
||||
blt $23,$24,L.10
|
||||
la $4,-48+88($sp)
|
||||
la $5,y
|
||||
jal g
|
||||
move $2,$0
|
||||
L.1:
|
||||
lw $22,16($sp)
|
||||
lw $23,20($sp)
|
||||
lw $25,24($sp)
|
||||
lw $30,28($sp)
|
||||
lw $31,32($sp)
|
||||
addu $sp,$sp,88
|
||||
j $31
|
||||
.end main
|
||||
.globl f
|
||||
.text
|
||||
.align 2
|
||||
.ent f
|
||||
f:
|
||||
.frame $sp,32,$31
|
||||
.set noreorder
|
||||
.cpload $25
|
||||
.set reorder
|
||||
addu $sp,$sp,-32
|
||||
.mask 0xc2800000,-4
|
||||
sw $23,16($sp)
|
||||
.cprestore 20
|
||||
sw $30,24($sp)
|
||||
sw $31,28($sp)
|
||||
move $23,$0
|
||||
L.19:
|
||||
move $30,$0
|
||||
L.23:
|
||||
la $4,L.27
|
||||
sll $24,$30,2
|
||||
sll $15,$23,4
|
||||
la $15,x($15)
|
||||
addu $24,$24,$15
|
||||
lw $5,($24)
|
||||
jal printf
|
||||
L.24:
|
||||
la $30,1($30)
|
||||
la $24,4
|
||||
blt $30,$24,L.23
|
||||
L.20:
|
||||
la $23,1($23)
|
||||
la $24,3
|
||||
blt $23,$24,L.19
|
||||
la $4,L.28
|
||||
jal printf
|
||||
move $23,$0
|
||||
L.29:
|
||||
move $30,$0
|
||||
L.33:
|
||||
la $4,L.27
|
||||
sll $24,$30,2
|
||||
sll $15,$23,2
|
||||
lw $15,y($15)
|
||||
addu $24,$24,$15
|
||||
lw $5,($24)
|
||||
jal printf
|
||||
L.34:
|
||||
la $30,1($30)
|
||||
la $24,4
|
||||
blt $30,$24,L.33
|
||||
L.30:
|
||||
la $23,1($23)
|
||||
la $24,3
|
||||
blt $23,$24,L.29
|
||||
la $4,L.28
|
||||
jal printf
|
||||
move $2,$0
|
||||
L.18:
|
||||
lw $23,16($sp)
|
||||
lw $25,20($sp)
|
||||
lw $30,24($sp)
|
||||
lw $31,28($sp)
|
||||
addu $sp,$sp,32
|
||||
j $31
|
||||
.end f
|
||||
.globl g
|
||||
.text
|
||||
.align 2
|
||||
.ent g
|
||||
g:
|
||||
.frame $sp,40,$31
|
||||
.set noreorder
|
||||
.cpload $25
|
||||
.set reorder
|
||||
addu $sp,$sp,-40
|
||||
.mask 0xc2e00000,-4
|
||||
sw $21,16($sp)
|
||||
sw $22,20($sp)
|
||||
sw $23,24($sp)
|
||||
.cprestore 28
|
||||
sw $30,32($sp)
|
||||
sw $31,36($sp)
|
||||
move $30,$4
|
||||
move $23,$5
|
||||
move $21,$0
|
||||
L.38:
|
||||
move $22,$0
|
||||
L.42:
|
||||
la $4,L.27
|
||||
sll $24,$22,2
|
||||
sll $15,$21,4
|
||||
addu $15,$15,$30
|
||||
addu $24,$24,$15
|
||||
lw $5,($24)
|
||||
jal printf
|
||||
L.43:
|
||||
la $22,1($22)
|
||||
la $24,4
|
||||
blt $22,$24,L.42
|
||||
L.39:
|
||||
la $21,1($21)
|
||||
la $24,3
|
||||
blt $21,$24,L.38
|
||||
la $4,L.28
|
||||
jal printf
|
||||
move $21,$0
|
||||
L.46:
|
||||
move $22,$0
|
||||
L.50:
|
||||
la $4,L.27
|
||||
sll $24,$22,2
|
||||
sll $15,$21,2
|
||||
addu $15,$15,$23
|
||||
lw $15,($15)
|
||||
addu $24,$24,$15
|
||||
lw $5,($24)
|
||||
jal printf
|
||||
L.51:
|
||||
la $22,1($22)
|
||||
la $24,4
|
||||
blt $22,$24,L.50
|
||||
L.47:
|
||||
la $21,1($21)
|
||||
la $24,3
|
||||
blt $21,$24,L.46
|
||||
la $4,L.28
|
||||
jal printf
|
||||
move $2,$0
|
||||
L.37:
|
||||
lw $21,16($sp)
|
||||
lw $22,20($sp)
|
||||
lw $23,24($sp)
|
||||
lw $25,28($sp)
|
||||
lw $30,32($sp)
|
||||
lw $31,36($sp)
|
||||
addu $sp,$sp,40
|
||||
j $31
|
||||
.end g
|
||||
.globl y
|
||||
.comm y,12
|
||||
.globl x
|
||||
.comm x,48
|
||||
.rdata
|
||||
.align 0
|
||||
L.28:
|
||||
.byte 10
|
||||
.byte 0
|
||||
.align 0
|
||||
L.27:
|
||||
.byte 32
|
||||
.byte 37
|
||||
.byte 100
|
||||
.byte 0
|
Loading…
Add table
Add a link
Reference in a new issue