summaryrefslogtreecommitdiff
path: root/rtl-allocator.h
diff options
context:
space:
mode:
authorChris Johns <chrisj@rtems.org>2012-07-16 15:07:54 +1000
committerChris Johns <chrisj@rtems.org>2012-07-16 15:07:54 +1000
commit5d126da01db7c0e140ca35389dfe8f7227f10622 (patch)
treeec501af328f2fd23a4ae7cdd53991fb8743b831d /rtl-allocator.h
parent8f06d01b2c6e051d9b6f733f6673b796490983f9 (diff)
Resolve unresolved externals when loading object files.
Object files that depend on each other will cause an unresolved external. The change lets object files load with unresolved externals and will resolve them when the object file with the external is loaded. A common table of symbol strings and relocation records is maintained. The symbol string is shared by each object file that is unresolved. Each relocation record that references the symbol is held. The table is a series of small blocks that compact as symbols are resolved. The number of symbols left unresolved is typically small this design avoids fragmentation of the heap memory.
Diffstat (limited to 'rtl-allocator.h')
-rw-r--r--rtl-allocator.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/rtl-allocator.h b/rtl-allocator.h
index 47e896f..8e90b7b 100644
--- a/rtl-allocator.h
+++ b/rtl-allocator.h
@@ -28,7 +28,7 @@ extern "C" {
* Define the types of allocation the loader requires.
*
* @note It is best to use the object tag for general memory allocation and to
- * leave the tags with specific access properties to the module data
+ * leave the tags with specific access properties to the module data
*/
enum rtems_rtl_alloc_tags_e {
RTEMS_RTL_ALLOC_OBJECT, /**< A generic memory object. */
@@ -96,7 +96,7 @@ void rtems_rtl_alloc_initialise (rtems_rtl_alloc_data_t* data);
* @param zero If true the memory is cleared.
* @return void* The memory address or NULL is not memory available.
*/
-void* rtems_rtl_alloc_new(rtems_rtl_alloc_tag_t tag, size_t size, bool zero);
+void* rtems_rtl_alloc_new (rtems_rtl_alloc_tag_t tag, size_t size, bool zero);
/**
* The Runtime Loader allocator delete deletes allocated memory.
@@ -104,7 +104,7 @@ void* rtems_rtl_alloc_new(rtems_rtl_alloc_tag_t tag, size_t size, bool zero);
* @param tag The type of allocation request.
* @param address The memory address to delete. A NULL is ignored.
*/
-void rtems_rtl_alloc_del(rtems_rtl_alloc_tag_t tag, void* address);
+void rtems_rtl_alloc_del (rtems_rtl_alloc_tag_t tag, void* address);
/**
* Hook the Runtime Loader allocatior. A handler can call the previous handler
@@ -115,7 +115,7 @@ void rtems_rtl_alloc_del(rtems_rtl_alloc_tag_t tag, void* address);
* @param handler The handler to use as the allocator.
* @return rtems_rtl_alloc_handler_t The previous handler.
*/
-rtems_rtl_allocator_t rtems_rtl_alloc_hook(rtems_rtl_allocator_t handler);
+rtems_rtl_allocator_t rtems_rtl_alloc_hook (rtems_rtl_allocator_t handler);
/**
* Allocate memory to an indirect handle.