Changeset 802 for soft/giet_vm/giet_kernel/giet.s
- Timestamp:
- Mar 14, 2016, 3:32:41 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
soft/giet_vm/giet_kernel/giet.s
r798 r802 43 43 addiu $26, $0, 0x20 44 44 beq $27, $26, do_jump /* jump if syscall */ 45 /* Other exception: saving registers for future display */ 45 46 /* 47 * exception: save registers into stack for future display by exception handler 48 */ 49 46 50 addiu $27, $29, -38*4 47 sw $29, (29*4)($27) 51 sw $29, (29*4)($27) /* save $29 */ 48 52 or $29, $27, $0 49 53 50 54 .set noat 51 sw $1, (1*4)($29) 55 sw $1, (1*4)($29) /* save $1 */ 52 56 .set at 53 sw $2, (2*4)($29) 54 sw $3, (3*4)($29) 55 sw $4, (4*4)($29) 56 sw $5, (5*4)($29) 57 sw $6, (6*4)($29) 58 sw $7, (7*4)($29) 59 sw $8, (8*4)($29) 60 sw $9, (9*4)($29) 61 sw $10, (10*4)($29) 62 sw $11, (11*4)($29) 63 sw $12, (12*4)($29) 64 sw $13, (13*4)($29) 65 sw $14, (14*4)($29) 66 sw $15, (15*4)($29) 67 sw $24, (24*4)($29) 68 sw $25, (25*4)($29) 69 sw $16, (16*4)($29) 70 mfc0 $16, $14 /* Read EPC */ 71 sw $17, (17*4)($29) 72 mfc0 $17, $13 /* read CR (used later) */ 73 sw $18, (18*4)($29) 74 mfc0 $18, $12 /* Read current SR (used later) */ 75 sw $19, (19*4)($29) 76 sw $20, (20*4)($29) 77 sw $21, (21*4)($29) 78 sw $22, (22*4)($29) 79 sw $23, (23*4)($29) 80 sw $30, (30*4)($29) 81 sw $28, (28*4)($29) 82 mflo $14 /* read LO */ 83 mfhi $15 /* read HI */ 84 sw $31, (31*4)($29) /* save RA */ 57 sw $2, (2*4)($29) /* save $2 */ 58 sw $3, (3*4)($29) /* save $3 */ 59 sw $4, (4*4)($29) /* save $4 */ 60 sw $5, (5*4)($29) /* save $5 */ 61 sw $6, (6*4)($29) /* save $6 */ 62 sw $7, (7*4)($29) /* save $7 */ 63 sw $8, (8*4)($29) /* save $8 */ 64 sw $9, (9*4)($29) /* save $9 */ 65 sw $10, (10*4)($29) /* save $10 */ 66 sw $11, (11*4)($29) /* save $11 */ 67 sw $12, (12*4)($29) /* save $12 */ 68 sw $13, (13*4)($29) /* save $13 */ 69 sw $14, (14*4)($29) /* save $14 */ 70 sw $15, (15*4)($29) /* save $15 */ 71 sw $16, (16*4)($29) /* save $16 */ 72 sw $17, (17*4)($29) /* save $17 */ 73 sw $18, (18*4)($29) /* save $18 */ 74 sw $19, (19*4)($29) /* save $19 */ 75 sw $20, (20*4)($29) /* save $20 */ 76 sw $21, (21*4)($29) /* save $21 */ 77 sw $22, (22*4)($29) /* save $22 */ 78 sw $23, (23*4)($29) /* save $23 */ 79 sw $24, (24*4)($29) /* save $24 */ 80 sw $25, (25*4)($29) /* save $25 */ 81 sw $28, (28*4)($29) /* save $28 */ 82 sw $30, (30*4)($29) /* save $30 */ 83 sw $31, (31*4)($29) /* save $31 */ 84 mflo $14 /* LO */ 85 mfhi $15 /* HI */ 86 mfc0 $16, $14 /* EPC */ 87 mfc0 $17, $13 /* CR */ 88 mfc0 $18, $12 /* SR */ 89 mfc0 $19, $8 /* BVAR */ 90 sw $14, (35*4)($29) /* save LO */ 91 sw $15, (36*4)($29) /* save HI */ 85 92 sw $16, (32*4)($29) /* Save EPC */ 86 93 sw $17, (33*4)($29) /* Save CR */ 87 94 sw $18, (34*4)($29) /* Save SR */ 88 sw $14, (35*4)($29) /* save LO */ 89 sw $15, (36*4)($29) /* save HI */ 90 or $4, $0, $27 91 95 sw $19, (37*4)($29) /* save BVAR */ 96 or $4, $0, $27 /* $4 <= regs_table */ 92 97 93 98 do_jump:
Note: See TracChangeset
for help on using the changeset viewer.