Add qemu 2.4.0
[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 : l!-le  >r lbflip r> l! ;
21 : l@-le  l@ lbflip ;
22
23 : w!-le  >r wbflip r> w! ;
24 : w@-le  w@ wbflip ;
25
26 : rx!-le  >r xbflip r> rx! ;
27 : rx@-le  rx@ xbflip ;
28
29 : rl!-le  >r lbflip r> rl! ;
30 : rl@-le  rl@ lbflip ;
31
32 : rw!-le  >r wbflip r> rw! ;
33 : rw@-le  rw@ wbflip ;
34
35 : l!-be  l! ;
36 : l@-be  l@ ;
37
38 : w!-be  w! ;
39 : w@-be  w@ ;
40
41 : rl!-be  rl! ;
42 : rl@-be  rl@ ;
43
44 : rw!-be  rw! ;
45 : rw@-be  rw@ ;
46
47
48 [ELSE]
49
50 : l!-le  l! ;
51 : l@-le  l@ ;
52
53 : w!-le  w! ;
54 : w@-le  w@ ;
55
56 : rx!-le  rx! ;
57 : rx@-le  rx@ ;
58
59 : rl!-le  rl! ;
60 : rl@-le  rl@ ;
61
62 : rw!-le  rw! ;
63 : rw@-le  rw@ ;
64
65 : l!-be  >r lbflip r> l! ;
66 : l@-be  l@ lbflip ;
67
68 : w!-be  >r wbflip r> w! ;
69 : w@-be  w@ wbflip ;
70
71 : rl!-be  >r lbflip r> rl! ;
72 : rl@-be  rl@ lbflip ;
73
74 : rw!-be  >r wbflip r> rw! ;
75 : rw@-be  rw@ wbflip ;
76
77 [THEN]