2 * Copyright (C) 1995 Advanced RISC Machines Limited. All rights reserved.
4 * This software may be freely used, copied, modified, and distributed
5 * provided that the above copyright notice is preserved in all copies of the
10 /*---------------------------------------------------------------------------*/
11 /* This header file is the main holder for the declarations and
12 * prototypes for the core Angel system. Some Angel concepts are
13 * described at the start of this file to ensure that a complete view
14 * of the Angel world can be derived purely from the source.
20 * NOTE: Currently the Angel source is designed to be simple,
21 * understandable and easy to port to new hardware platforms. However,
22 * this does not always yield the highest performing system. The
23 * current layered approach introduces an overhead to the performance
24 * of the system. In a true commercial target, this code should be
25 * re-designed to build a system where the Angel logical message
26 * system, device driver and hardware accesses are merged to provide
27 * the best performance.
29 /*---------------------------------------------------------------------------*/
32 ... some comments describing Angel ...
34 * Angel is designed as a kit-of-parts that can be used to provide
35 * run-time support for the development of ARM applications. The main
36 * core of Angel is in providing support for the "debug" message
37 * communication with a host system. These messages do not just cover
38 * debugging ARM processes, but also the process of downloading ARM
39 * programs or attaching to executing processes on the target.
41 * A stand-alone ROM based Angel world is the basic starting point for
42 * a system, since it will allow programs to be downloaded to the
43 * target. The ROM version of Angel will provide the generic debug
44 * support, but no system specific routines. The preferred method of
45 * using Angel is as a link library. This ensures that applications
46 * carry with them the Angel routines necessary to support debugging
47 * (and also ensure that the Angel version is up-to-date, independant
48 * of the version in the target ROM). Eventually, once a program has
49 * been fully debugged, a ROMmed version of the program can be
50 * generated with the Angel code being provided in the application.
54 * The standard Angel routines do *NOT* perform any dynamic memory
55 * allocation. To simplify the source, and aid the porting to a non C
56 * library world, memory is either pre-allocated (as build-time
57 * globals) or actually given to the particular Angel routine by the
58 * active run-time. This ensures that the interaction between Angel
59 * and the target O/S is minimised.
61 * Notes: We sub-include more header files to keep the source
62 * modular. Since Angel is a kit-of-parts alternative systems may need
63 * to change the prototypes of particular functions, whilst
64 * maintaining a fixed external interface. e.g. using the standard
65 * DEBUG messages, but with a different communications world.
67 /*---------------------------------------------------------------------------*/
72 /*---------------------------------------------------------------------------*/
73 /*-- Global Angel definitions and manifests ---------------------------------*/
74 /*---------------------------------------------------------------------------*/
75 /* When building Angel we may not include the standard library
76 * headers. However, it is useful coding using standard macro names
77 * since it makes the code easier to understand.
80 typedef unsigned int word
;
81 typedef unsigned char byte
;
83 /* The following typedefs can be used to access I/O registers: */
84 typedef volatile unsigned int vuword
;
85 typedef volatile unsigned char vubyte
;
88 * The following typedefs are used when defining objects that may also
89 * be created on a host system, where the word size is not
90 * 32bits. This ensures that the same data values are manipulated.
93 typedef unsigned int unsigned32
;
94 typedef signed int signed32
;
97 typedef unsigned short int unsigned16
;
98 typedef signed short int signed16
;
101 * yet another solution for the bool/boolean problem, this one is
102 * copied from Scott's modifications to clx/host.h
104 # ifdef IMPLEMENT_BOOL_AS_ENUM
105 enum _bool
{ _false
, _true
};
106 # define _bool enum _bool
107 # elif defined(IMPLEMENT_BOOL_AS_INT) || !defined(__cplusplus)
119 # define false _false
127 # undef TRUE /* some OSF headers define as 1 */
130 # undef FALSE /* some OSF headers define as 1 */
144 # define IGNORE(x) ((x)=(x))
147 /* The following typedef allows us to cast between integral and
148 * function pointers. This isn't allowed by direct casting when
149 * conforming to the ANSI spec.
151 typedef union ansibodge
163 /*---------------------------------------------------------------------------*/
165 /* The amount setup aside by the run-time system for stack overflow
166 * handlers to execute in. This must be at least 256bytes, since that
167 * value is assumed by the current ARM Ltd compiler.
168 * This space is _only_ kept for the USR stack, not any of the privileged
169 * mode stacks, as stack overflow on these is always fatal - there is
170 * no point attemptingto recover. In addition is is important that
171 * Angel should keep privileged stack space requirements to a minimum.
173 #define APCS_STACKGUARD 256
175 #endif /* __angel_h */
This page took 0.033082 seconds and 4 git commands to generate.