OpenCores
URL https://opencores.org/ocsvn/lxp32/lxp32/trunk

Subversion Repositories lxp32

[/] [lxp32/] [trunk/] [verify/] [lxp32/] [src/] [firmware/] [test020.asm] - Blame information for rev 6

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 6 ring0_mipt
/*
2
 * Check that there are no pipeline hazards
3
 */
4
 
5
        lc r100, 0x10000000 // test result output pointer
6
        lcs r101, halt
7
        lcs r102, failure
8
        lcs r103, success
9
 
10
        add r0, 100, 50 // r0:=150
11
        add r1, r0, 3 // r1:=153, potential RAW hazard
12
        mul r2, r1, 109 // r2:=16677, potential RAW hazard
13
        mul r3, r2, r0 // r3:=2501550, potential RAW hazard
14
        sub r4, r3, 15 // r4:=2501535, potential RAW hazard
15
 
16
        mul r5, 50, 117 // r2:=5850
17
        sub r5, 100, 9 // r2:=91, overwrites previous result, potential WAW hazard
18
 
19
        lc r6, 1800
20
        mul r7, r6, 49 // r7:=88200, potential RAW hazard
21
        mov r6, 1 // r6:=1, potential WAR hazard
22
 
23
        lc r0, 2501535
24
        cjmpne r102, r4, r0 // failure
25
        cjmpne r102, r5, 91 // failure
26
        lcs r0, 88200
27
        cjmpne r102, r7, r0 // failure
28
        jmp r103 // success
29
 
30
failure:
31
        sw r100, 2
32
        jmp r101 // halt
33
 
34
success:
35
        sw r100, 1 // success
36
 
37
halt:
38
        hlt
39
        jmp r101 // halt

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.