1 /* Copyright (C) 1990 Free Software Foundation, Inc.
3 This file is part of GDB.
5 GDB is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 1, or (at your option)
10 GDB is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with GDB; see the file COPYING. If not, write to
17 the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA. */
19 #if !defined (PARAM_H)
22 /* DO NOT #include "tm.h" -- a particular tm file has been inc'd by caller */
26 /* TARGET_BYTE_ORDER and HOST_BYTE_ORDER should be defined to one of these. */
27 #if !defined (BIG_ENDIAN)
28 #define BIG_ENDIAN 4321
31 #if !defined (LITTLE_ENDIAN)
32 #define LITTLE_ENDIAN 1234
35 /* The bit byte-order has to do just with numbering of bits in
36 debugging symbols and such. Conceptually, it's quite separate
37 from byte/word byte order. */
39 #if TARGET_BYTE_ORDER == BIG_ENDIAN
40 #define BITS_BIG_ENDIAN 1
43 #if TARGET_BYTE_ORDER == LITTLE_ENDIAN
44 /*#define BITS_BIG_ENDIAN */
47 /* Swap LEN bytes at BUFFER between target and host byte-order. */
48 #if TARGET_BYTE_ORDER == HOST_BYTE_ORDER
49 #define SWAP_TARGET_AND_HOST(buffer,len)
50 #else /* Target and host byte order differ. */
51 #define SWAP_TARGET_AND_HOST(buffer,len) \
54 char *p = (char *)(buffer); \
55 char *q = ((char *)(buffer)) + len - 1; \
56 for (; p < q; p++, q--) \
63 #endif /* Target and host byte order differ. */
65 /* On some machines there are bits in addresses which are not really
66 part of the address, but are used by the kernel, the hardware, etc.
67 for special purposes. ADDR_BITS_REMOVE takes out any such bits
68 so we get a "real" address such as one would find in a symbol
69 table. ADDR_BITS_SET sets those bits the way the system wants
71 #if !defined (ADDR_BITS_REMOVE)
72 #define ADDR_BITS_REMOVE(addr) (addr)
73 #define ADDR_BITS_SET(addr) (addr)
74 #endif /* No ADDR_BITS_REMOVE. */
76 #if !defined (SYS_SIGLIST_MISSING)
77 #define SYS_SIGLIST_MISSING defined (USG)
78 #endif /* No SYS_SIGLIST_MISSING */
80 #endif /* param.h not already included. */
This page took 0.031466 seconds and 5 git commands to generate.