/[smarc]/smarc/src/smarcgui/src/test.asm
ViewVC logotype

Diff of /smarc/src/smarcgui/src/test.asm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1 by misto, Thu Jan 2 17:57:25 2003 UTC revision 1.2 by misto, Fri Jan 3 01:26:36 2003 UTC
# Line 11  slowa: .word   -1 Line 11  slowa: .word   -1
11    
12          .text          .text
13    
14  start:  main:
15          ldsb    [0], %l0          or %g0, %g0, %o0
16            sub %o0, 1, %i0
17          nop          nop
         sub     %l0, 10, %l0  
         add     %l0, 10, %l1  
   
         addcc   %l1, %l0, %l3  
         subcc   %l0, %l3, %o0  
           
         ldsh    [0], %l0  
         ldsh    [2], %l1  
   
         addcc   %l1, %l0, %l3  
         subcc   %l0, %l3, %o0  
   
18          nop          nop
19          nop          nop
20            save %sp, 96, %sp
21            call proc
22          nop          nop
         inc     %r2  
         dec     %r2  
         neg     %r9  
         mov     %r9, %r8  
         xorcc   %r8, %r4, %r20  
         bne start  
         call    ziew  
   
         ld      [1], %r4  
         ldub    [1], %r5  
         ldstub  [1], %r6  
         st      %r9, [4]  
         ld      [%r20 + 1000], %r9  
         stb     %r8, [%r19 -3]  
         swap    [%r12], %r13  
         ret  
23    
24  ziew:          ret
25            restore
26          nop          nop
27          be start  
28          call    start  proc:
29          jmpl    %r7 + 8, %g2          save %sp, 98, %sp
30          jmp     %r7 + 8          or %g0, 2, %i0
31            or %g0, 3, %o0
32            add %i0, %o0, %l0
33            ret
34            restore
35    
36    
37    !start:
38    !       call
39    !       ldsb    [0], %l0
40    !       nop
41    !       add     %l0, 10, %l1
42    !       and     %l1, 0xff, %l2
43    !
44    !       nop
45    !       nop
46    !       cmp     %l1, %l2
47    !       bge     ziew
48    !       inc     %l2
49    !koniec:
50    !       nop
51    !       nop
52    !       nop
53    !       ret
54    !
55    !ziew:
56    !       addcc   %l1, %l2, %i2
57    !       ba      koniec
58    !       nop
59    !

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26