This commit was generated by cvs2svn to track changes on a CVS vendor
[external/binutils.git] / gas / testsuite / gas / hppa / basic / imem.s
1         .SPACE $PRIVATE$
2         .SUBSPA $DATA$,QUAD=1,ALIGN=8,ACCESS=31
3         .SUBSPA $BSS$,QUAD=1,ALIGN=8,ACCESS=31,ZERO,SORT=82
4         .SPACE $TEXT$
5         .SUBSPA $LIT$,QUAD=0,ALIGN=8,ACCESS=44
6         .SUBSPA $CODE$,QUAD=0,ALIGN=8,ACCESS=44,CODE_ONLY
7
8         .SPACE $TEXT$
9         .SUBSPA $CODE$
10
11         .align 4
12         .EXPORT integer_memory_tests,CODE
13         .EXPORT integer_indexing_load,CODE
14         .EXPORT integer_load_short_memory,CODE
15         .EXPORT integer_store_short_memory,CODE
16         .EXPORT main,CODE
17         .EXPORT main,ENTRY,PRIV_LEV=3,RTNVAL=GR
18 ; Basic integer memory tests which also test the various 
19 ; addressing modes and completers.
20 ;
21 ; We could/should test some of the corner cases for register and 
22 ; immediate fields.  We should also check the assorted field
23 ; selectors to make sure they're handled correctly.
24
25 integer_memory_tests: 
26         ldw 0(%sr0,%r4),%r26
27         ldh 0(%sr0,%r4),%r26
28         ldb 0(%sr0,%r4),%r26
29         stw %r26,0(%sr0,%r4)
30         sth %r26,0(%sr0,%r4)
31         stb %r26,0(%sr0,%r4)
32
33 ; Should make sure pre/post modes are recognized correctly.
34         ldwm 0(%sr0,%r4),%r26
35         stwm %r26,0(%sr0,%r4)
36
37 integer_indexing_load: 
38         ldwx %r5(%sr0,%r4),%r26
39         ldwx,s %r5(%sr0,%r4),%r26
40         ldwx,m %r5(%sr0,%r4),%r26
41         ldwx,sm %r5(%sr0,%r4),%r26
42         ldhx %r5(%sr0,%r4),%r26
43         ldhx,s %r5(%sr0,%r4),%r26
44         ldhx,m %r5(%sr0,%r4),%r26
45         ldhx,sm %r5(%sr0,%r4),%r26
46         ldbx %r5(%sr0,%r4),%r26
47         ldbx,s %r5(%sr0,%r4),%r26
48         ldbx,m %r5(%sr0,%r4),%r26
49         ldbx,sm %r5(%sr0,%r4),%r26
50         ldwax %r5(%r4),%r26
51         ldwax,s %r5(%r4),%r26
52         ldwax,m %r5(%r4),%r26
53         ldwax,sm %r5(%r4),%r26
54         ldcwx %r5(%sr0,%r4),%r26
55         ldcwx,s %r5(%sr0,%r4),%r26
56         ldcwx,m %r5(%sr0,%r4),%r26
57         ldcwx,sm %r5(%sr0,%r4),%r26
58
59 integer_load_short_memory: 
60         ldws 0(%sr0,%r4),%r26
61         ldws,mb 0(%sr0,%r4),%r26
62         ldws,ma 0(%sr0,%r4),%r26
63         ldhs 0(%sr0,%r4),%r26
64         ldhs,mb 0(%sr0,%r4),%r26
65         ldhs,ma 0(%sr0,%r4),%r26
66         ldbs 0(%sr0,%r4),%r26
67         ldbs,mb 0(%sr0,%r4),%r26
68         ldbs,ma 0(%sr0,%r4),%r26
69         ldwas 0(%r4),%r26
70         ldwas,mb 0(%r4),%r26
71         ldwas,ma 0(%r4),%r26
72         ldcws 0(%sr0,%r4),%r26
73         ldcws,mb 0(%sr0,%r4),%r26
74         ldcws,ma 0(%sr0,%r4),%r26
75
76 integer_store_short_memory: 
77         stws %r26,0(%sr0,%r4)
78         stws,mb %r26,0(%sr0,%r4)
79         stws,ma %r26,0(%sr0,%r4)
80         sths %r26,0(%sr0,%r4)
81         sths,mb %r26,0(%sr0,%r4)
82         sths,ma %r26,0(%sr0,%r4)
83         stbs %r26,0(%sr0,%r4)
84         stbs,mb %r26,0(%sr0,%r4)
85         stbs,ma %r26,0(%sr0,%r4)
86         stwas %r26,0(%r4)
87         stwas,mb %r26,0(%r4)
88         stwas,ma %r26,0(%r4)
89         stbys %r26,0(%sr0,%r4)
90         stbys,b %r26,0(%sr0,%r4)
91         stbys,e %r26,0(%sr0,%r4)
92         stbys,b,m %r26,0(%sr0,%r4)
93         stbys,e,m %r26,0(%sr0,%r4)