RTEMS 6.1-rc6
Loading...
Searching...
No Matches
Files | Macros
Linker Sets

This group contains the linker sets API. More...

Files

file  linkersets.h
 This header file provides the linker sets API.
 

Macros

#define RTEMS_LINKER_SET_BEGIN(set)    _Linker_set_##set##_begin
 
#define RTEMS_LINKER_SET_END(set)    _Linker_set_##set##_end
 
#define RTEMS_LINKER_SET_ALIGN(type)    RTEMS_ALIGNED( RTEMS_ALIGNOF( type ) )
 
#define RTEMS_LINKER_ROSET_DECLARE(set, type)
 
#define RTEMS_LINKER_ROSET(set, type)
 
#define RTEMS_LINKER_ROSET_ITEM_ORDERED_DECLARE(set, type, item, order)
 
#define RTEMS_LINKER_ROSET_ITEM_DECLARE(set, type, item)
 
#define RTEMS_LINKER_ROSET_ITEM_REFERENCE(set, type, item)
 
#define RTEMS_LINKER_ROSET_ITEM_ORDERED(set, type, item, order)
 
#define RTEMS_LINKER_ROSET_ITEM(set, type, item)
 
#define RTEMS_LINKER_ROSET_CONTENT(set, decl)
 
#define RTEMS_LINKER_RWSET_DECLARE(set, type)
 
#define RTEMS_LINKER_RWSET(set, type)
 
#define RTEMS_LINKER_RWSET_ITEM_ORDERED_DECLARE(set, type, item, order)
 
#define RTEMS_LINKER_RWSET_ITEM_DECLARE(set, type, item)
 
#define RTEMS_LINKER_RWSET_ITEM_REFERENCE(set, type, item)
 
#define RTEMS_LINKER_RWSET_ITEM_ORDERED(set, type, item, order)
 
#define RTEMS_LINKER_RWSET_ITEM(set, type, item)
 
#define RTEMS_LINKER_RWSET_CONTENT(set, decl)
 
#define RTEMS_LINKER_SET_SIZE(set)
 
#define RTEMS_LINKER_SET_ITEM_COUNT(set)
 
#define RTEMS_LINKER_SET_IS_EMPTY(set)    ( RTEMS_LINKER_SET_SIZE( set ) == 0 )
 
#define RTEMS_LINKER_SET_FOREACH(set, item)
 

Detailed Description

This group contains the linker sets API.

Macro Definition Documentation

◆ RTEMS_LINKER_ROSET

#define RTEMS_LINKER_ROSET (   set,
  type 
)
Value:
RTEMS_LINKER_SET_ALIGN( type ) type const RTEMS_LINKER_SET_BEGIN( set )[ 0 ] \
RTEMS_SECTION( ".rtemsroset." #set ".begin" ) RTEMS_USED; \
RTEMS_LINKER_SET_ALIGN( type ) type const RTEMS_LINKER_SET_END( set )[ 0 ] \
RTEMS_SECTION( ".rtemsroset." #set ".end" ) RTEMS_USED
#define RTEMS_USED
Tells the compiler that the variable or function is used.
Definition: basedefs.h:924

◆ RTEMS_LINKER_ROSET_CONTENT

#define RTEMS_LINKER_ROSET_CONTENT (   set,
  decl 
)
Value:
decl \
RTEMS_SECTION( ".rtemsroset." #set ".content" )

◆ RTEMS_LINKER_ROSET_DECLARE

#define RTEMS_LINKER_ROSET_DECLARE (   set,
  type 
)
Value:
extern RTEMS_LINKER_SET_ALIGN( type ) type \
const RTEMS_LINKER_SET_BEGIN( set )[]; \
extern RTEMS_LINKER_SET_ALIGN( type ) type \
const RTEMS_LINKER_SET_END( set )[]

◆ RTEMS_LINKER_ROSET_ITEM

#define RTEMS_LINKER_ROSET_ITEM (   set,
  type,
  item 
)
Value:
RTEMS_LINKER_SET_ALIGN( type ) type const _Linker_set_##set##_##item \
RTEMS_SECTION( ".rtemsroset." #set ".content.1" ) RTEMS_USED

◆ RTEMS_LINKER_ROSET_ITEM_DECLARE

#define RTEMS_LINKER_ROSET_ITEM_DECLARE (   set,
  type,
  item 
)
Value:
extern RTEMS_LINKER_SET_ALIGN( type ) type const _Linker_set_##set##_##item \
RTEMS_SECTION( ".rtemsroset." #set ".content.1" )

◆ RTEMS_LINKER_ROSET_ITEM_ORDERED

#define RTEMS_LINKER_ROSET_ITEM_ORDERED (   set,
  type,
  item,
  order 
)
Value:
RTEMS_LINKER_SET_ALIGN( type ) type const _Linker_set_##set##_##item \
RTEMS_SECTION( ".rtemsroset." #set ".content.0." RTEMS_XSTRING( order ) ) \
#define RTEMS_XSTRING(...)
Stringifies the expansion of the arguments.
Definition: basedefs.h:987

◆ RTEMS_LINKER_ROSET_ITEM_ORDERED_DECLARE

#define RTEMS_LINKER_ROSET_ITEM_ORDERED_DECLARE (   set,
  type,
  item,
  order 
)
Value:
extern RTEMS_LINKER_SET_ALIGN( type ) type const _Linker_set_##set##_##item \
RTEMS_SECTION( ".rtemsroset." #set ".content.0." RTEMS_XSTRING( order ) )

◆ RTEMS_LINKER_ROSET_ITEM_REFERENCE

#define RTEMS_LINKER_ROSET_ITEM_REFERENCE (   set,
  type,
  item 
)
Value:
static RTEMS_LINKER_SET_ALIGN( type ) type \
const * const _Set_reference_##set##_##item \
RTEMS_SECTION( ".rtemsroset.reference" ) RTEMS_USED = \
&_Linker_set_##set##_##item

◆ RTEMS_LINKER_RWSET

#define RTEMS_LINKER_RWSET (   set,
  type 
)
Value:
RTEMS_LINKER_SET_ALIGN( type ) type RTEMS_LINKER_SET_BEGIN( set )[ 0 ] \
RTEMS_SECTION( ".rtemsrwset." #set ".begin" ) RTEMS_USED; \
RTEMS_LINKER_SET_ALIGN( type ) type RTEMS_LINKER_SET_END( set )[ 0 ] \
RTEMS_SECTION( ".rtemsrwset." #set ".end" ) RTEMS_USED

◆ RTEMS_LINKER_RWSET_CONTENT

#define RTEMS_LINKER_RWSET_CONTENT (   set,
  decl 
)
Value:
decl \
RTEMS_SECTION( ".rtemsrwset." #set ".content" )

◆ RTEMS_LINKER_RWSET_DECLARE

#define RTEMS_LINKER_RWSET_DECLARE (   set,
  type 
)
Value:
extern RTEMS_LINKER_SET_ALIGN( type ) type RTEMS_LINKER_SET_BEGIN( set )[]; \
extern RTEMS_LINKER_SET_ALIGN( type ) type RTEMS_LINKER_SET_END( set )[]

◆ RTEMS_LINKER_RWSET_ITEM

#define RTEMS_LINKER_RWSET_ITEM (   set,
  type,
  item 
)
Value:
RTEMS_LINKER_SET_ALIGN( type ) type _Linker_set_##set##_##item \
RTEMS_SECTION( ".rtemsrwset." #set ".content.1" ) RTEMS_USED

◆ RTEMS_LINKER_RWSET_ITEM_DECLARE

#define RTEMS_LINKER_RWSET_ITEM_DECLARE (   set,
  type,
  item 
)
Value:
extern RTEMS_LINKER_SET_ALIGN( type ) type _Linker_set_##set##_##item \
RTEMS_SECTION( ".rtemsrwset." #set ".content.1" )

◆ RTEMS_LINKER_RWSET_ITEM_ORDERED

#define RTEMS_LINKER_RWSET_ITEM_ORDERED (   set,
  type,
  item,
  order 
)
Value:
RTEMS_LINKER_SET_ALIGN( type ) type _Linker_set_##set##_##item \
RTEMS_SECTION( ".rtemsrwset." #set ".content.0." RTEMS_XSTRING( order ) ) \

◆ RTEMS_LINKER_RWSET_ITEM_ORDERED_DECLARE

#define RTEMS_LINKER_RWSET_ITEM_ORDERED_DECLARE (   set,
  type,
  item,
  order 
)
Value:
extern RTEMS_LINKER_SET_ALIGN( type ) type _Linker_set_##set##_##item \
RTEMS_SECTION( ".rtemsrwset." #set ".content.0." RTEMS_XSTRING( order ) )

◆ RTEMS_LINKER_RWSET_ITEM_REFERENCE

#define RTEMS_LINKER_RWSET_ITEM_REFERENCE (   set,
  type,
  item 
)
Value:
static RTEMS_LINKER_SET_ALIGN( type ) type \
* const _Set_reference_##set##_##item \
RTEMS_SECTION( ".rtemsroset.reference" ) RTEMS_USED = \
&_Linker_set_##set##_##item

◆ RTEMS_LINKER_SET_FOREACH

#define RTEMS_LINKER_SET_FOREACH (   set,
  item 
)
Value:
for ( \
item = (void *) _Linker_set_Obfuscate( RTEMS_LINKER_SET_BEGIN( set ) ) ; \
item != RTEMS_LINKER_SET_END( set ) ; \
++item \
)

◆ RTEMS_LINKER_SET_ITEM_COUNT

#define RTEMS_LINKER_SET_ITEM_COUNT (   set)
Value:
( RTEMS_LINKER_SET_SIZE( set ) \
/ sizeof( RTEMS_LINKER_SET_BEGIN( set )[ 0 ] ) )

◆ RTEMS_LINKER_SET_SIZE

#define RTEMS_LINKER_SET_SIZE (   set)
Value:
( _Linker_set_Obfuscate( RTEMS_LINKER_SET_END( set ) ) \
- _Linker_set_Obfuscate( RTEMS_LINKER_SET_BEGIN( set ) ) )