- .align 2
- .global write_nomemd_new
- .type write_nomemd_new, %function
-write_nomemd_new:
- str r3, [fp, #24]
- str lr, [fp, #28]
- bl do_invalidate
- ldr r2, [fp, #address-dynarec_local]
- add r12, fp, #memory_map-dynarec_local
- ldr lr, [fp, #28]
- lsr r0, r2, #12
- ldr r3, [fp, #24]
- ldr r12, [r12, r0, lsl #2]
- mov r1, #0xc
- lsls r12, #2
- bcs tlb_exception
- add r3, r2, #4
- ldr r0, [fp, #dword+4-dynarec_local]
- ldr r1, [fp, #dword-dynarec_local]
-/* strd r0, [r2, r12]*/
- str r0, [r2, r12]
- str r1, [r3, r12]
- mov pc, lr
- .size write_nomemd_new, .-write_nomemd_new
- .align 2
- .global tlb_exception
- .type tlb_exception, %function
-tlb_exception:
- /* r1 = cause */
- /* r2 = address */
- /* r3 = instr addr/flags */
- ldr r4, [fp, #reg_cop0+48-dynarec_local] /* Status */
- add r5, fp, #memory_map-dynarec_local
- lsr r6, r3, #12
- orr r1, r1, r3, lsl #31
- orr r4, r4, #2
- ldr r7, [r5, r6, lsl #2]
- bic r8, r3, #3
- str r4, [fp, #reg_cop0+48-dynarec_local] /* Status */
- mov r6, #0x6000000
- str r1, [fp, #reg_cop0+52-dynarec_local] /* Cause */
- orr r6, r6, #0x22
- ldr r0, [r8, r7, lsl #2]
- add r4, r8, r1, asr #29
- add r5, fp, #reg-dynarec_local
- str r4, [fp, #reg_cop0+56-dynarec_local] /* EPC */
- mov r7, #0xf8
- ldr r8, [fp, #reg_cop0+16-dynarec_local] /* Context */
- lsl r1, r0, #16
- lsr r4, r0, #26
- and r7, r7, r0, lsr #18
- mvn r9, #0xF000000F
- sub r2, r2, r1, asr #16
- bic r9, r9, #0x0F800000
- rors r6, r6, r4
- mov r0, #0x80000000
- ldrcs r2, [r5, r7]
- bic r8, r8, r9
- tst r3, #2
- str r2, [r5, r7]
- add r4, r2, r1, asr #16
- add r6, fp, #reg+4-dynarec_local
- asr r3, r2, #31
- str r4, [fp, #reg_cop0+32-dynarec_local] /* BadVAddr */
- add r0, r0, #0x180
- and r4, r9, r4, lsr #9
- strne r3, [r6, r7]
- orr r8, r8, r4
- str r8, [fp, #reg_cop0+16-dynarec_local] /* Context */
- bl get_addr_ht
- ldr r1, [fp, #next_interupt-dynarec_local]
- ldr r10, [fp, #reg_cop0+36-dynarec_local] /* Count */
- str r1, [fp, #last_count-dynarec_local]
- sub r10, r10, r1
- mov pc, r0
- .size tlb_exception, .-tlb_exception