These changes are the raw update to qemu-2.6.
[kvmfornfv.git] / qemu / roms / SLOF / slof / fs / little-endian.fs
1 \ *****************************************************************************
2 \ * Copyright (c) 2004, 2011 IBM Corporation
3 \ * All rights reserved.
4 \ * This program and the accompanying materials
5 \ * are made available under the terms of the BSD License
6 \ * which accompanies this distribution, and is available at
7 \ * http://www.opensource.org/licenses/bsd-license.php
8 \ *
9 \ * Contributors:
10 \ *     IBM Corporation - initial implementation
11 \ ****************************************************************************/
12
13 deadbeef here l!
14 here c@ de = CONSTANT ?bigendian
15 here c@ ef = CONSTANT ?littleendian
16
17
18 ?bigendian [IF]
19
20 : x!-le >r xbflip r> x! ;
21 : x@-le x@ xbflip ;
22
23 : l!-le  >r lbflip r> l! ;
24 : l@-le  l@ lbflip ;
25
26 : w!-le  >r wbflip r> w! ;
27 : w@-le  w@ wbflip ;
28
29 : rx!-le  >r xbflip r> rx! ;
30 : rx@-le  rx@ xbflip ;
31
32 : rl!-le  >r lbflip r> rl! ;
33 : rl@-le  rl@ lbflip ;
34
35 : rw!-le  >r wbflip r> rw! ;
36 : rw@-le  rw@ wbflip ;
37
38 : l!-be  l! ;
39 : l@-be  l@ ;
40
41 : w!-be  w! ;
42 : w@-be  w@ ;
43
44 : rl!-be  rl! ;
45 : rl@-be  rl@ ;
46
47 : rw!-be  rw! ;
48 : rw@-be  rw@ ;
49
50
51 [ELSE]
52
53 : x!-le x! ;
54 : x@-le x@ ;
55
56 : l!-le  l! ;
57 : l@-le  l@ ;
58
59 : w!-le  w! ;
60 : w@-le  w@ ;
61
62 : rx!-le  rx! ;
63 : rx@-le  rx@ ;
64
65 : rl!-le  rl! ;
66 : rl@-le  rl@ ;
67
68 : rw!-le  rw! ;
69 : rw@-le  rw@ ;
70
71 : l!-be  >r lbflip r> l! ;
72 : l@-be  l@ lbflip ;
73
74 : w!-be  >r wbflip r> w! ;
75 : w@-be  w@ wbflip ;
76
77 : rl!-be  >r lbflip r> rl! ;
78 : rl@-be  rl@ lbflip ;
79
80 : rw!-be  >r wbflip r> rw! ;
81 : rw@-be  rw@ wbflip ;
82
83 [THEN]