source: rtems/cpukit/include/rtems/rtl/rtl-trace.h @ 6c9f017

5
Last change on this file since 6c9f017 was 6c9f017, checked in by Chris Johns <chrisj@…>, on 02/02/19 at 04:09:53

libdl: Add powerpc large memory and small data support.

  • Add support for architecure sections that can be handled by the architecture back end.
  • Add trampoline/fixup support for PowerPC. This means the PowerPC now supports large memory loading of applications.
  • Add a bit allocator to manage small block based regions of memory.
  • Add small data (sdata/sbss) support for the PowerPC. The support makes the linker allocated small data region of memory a global resource available to libdl loaded object files.

Updates #3687
Updates #3685

  • Property mode set to 100644
File size: 3.0 KB
Line 
1/*
2 *  COPYRIGHT (c) 2012-2014 Chris Johns <chrisj@rtems.org>
3 *
4 *  The license and distribution terms for this file may be
5 *  found in the file LICENSE in this distribution or at
6 *  http://www.rtems.org/license/LICENSE.
7 */
8/**
9 * @file
10 *
11 * @ingroup rtems_rtl
12 *
13 * @brief RTEMS Run-Time Linker ELF Trace Support.
14 */
15
16#if !defined (_RTEMS_RTL_TRACE_H_)
17#define _RTEMS_RTL_TRACE_H_
18
19#ifdef __cplusplus
20extern "C" {
21#endif /* __cplusplus */
22
23#include <stdbool.h>
24#include <stdint.h>
25
26/**
27 * Set to 1 to build trace support in to the RTL code.
28 */
29#define RTEMS_RTL_TRACE 1
30
31/**
32 * The type of the mask.
33 */
34typedef uint32_t rtems_rtl_trace_mask;
35
36/**
37 * List of tracing bits for the various parts of the link editor.
38 */
39#define RTEMS_RTL_TRACE_DETAIL                 (1UL << 0)
40#define RTEMS_RTL_TRACE_WARNING                (1UL << 1)
41#define RTEMS_RTL_TRACE_LOAD                   (1UL << 2)
42#define RTEMS_RTL_TRACE_UNLOAD                 (1UL << 3)
43#define RTEMS_RTL_TRACE_SECTION                (1UL << 4)
44#define RTEMS_RTL_TRACE_SYMBOL                 (1UL << 5)
45#define RTEMS_RTL_TRACE_RELOC                  (1UL << 6)
46#define RTEMS_RTL_TRACE_GLOBAL_SYM             (1UL << 7)
47#define RTEMS_RTL_TRACE_LOAD_SECT              (1UL << 8)
48#define RTEMS_RTL_TRACE_ALLOCATOR              (1UL << 9)
49#define RTEMS_RTL_TRACE_UNRESOLVED             (1UL << 10)
50#define RTEMS_RTL_TRACE_CACHE                  (1UL << 11)
51#define RTEMS_RTL_TRACE_ARCHIVES               (1UL << 12)
52#define RTEMS_RTL_TRACE_ARCHIVE_SYMS           (1UL << 13)
53#define RTEMS_RTL_TRACE_DEPENDENCY             (1UL << 14)
54#define RTEMS_RTL_TRACE_BIT_ALLOC              (1UL << 15)
55#define RTEMS_RTL_TRACE_ALL                    (0xffffffffUL & ~(RTEMS_RTL_TRACE_CACHE | \
56                                                                 RTEMS_RTL_TRACE_GLOBAL_SYM | \
57                                                                 RTEMS_RTL_TRACE_ARCHIVE_SYMS))
58
59/**
60 * Call to check if this part is bring traced. If RTEMS_RTL_TRACE is defined to
61 * 0 the code is dead code elminiated when built with -Os, -O2, or higher.
62 *
63 * @param mask The part of the API to trace.
64 * @retval true Tracing is active for the mask.
65 * @retval false Do not trace.
66 */
67#if RTEMS_RTL_TRACE
68bool rtems_rtl_trace (rtems_rtl_trace_mask mask);
69#else
70#define rtems_rtl_trace(_m) (0)
71#endif
72
73/**
74 * Set the mask.
75 *
76 * @param mask The mask bits to set.
77 * @return The previous mask.
78 */
79#if RTEMS_RTL_TRACE
80rtems_rtl_trace_mask rtems_rtl_trace_set_mask (rtems_rtl_trace_mask mask);
81#else
82#define rtems_rtl_trace_set_mask(_m)
83#endif
84
85/**
86 * Clear the mask.
87 *
88 * @param mask The mask bits to clear.
89 * @return The previous mask.
90 */
91#if RTEMS_RTL_TRACE
92rtems_rtl_trace_mask rtems_rtl_trace_clear_mask (rtems_rtl_trace_mask mask);
93#else
94#define rtems_rtl_trace_clear_mask(_m)
95#endif
96
97/**
98 * Add shell trace shell command.
99 */
100#if RTEMS_RTL_TRACE
101int rtems_rtl_trace_shell_command (int argc, char *argv[]);
102#endif
103
104#ifdef __cplusplus
105}
106#endif /* __cplusplus */
107
108#endif
Note: See TracBrowser for help on using the repository browser.