Changeset f027f37 in rtems-tools


Ignore:
Timestamp:
Jan 4, 2016, 10:15:37 AM (4 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.10, master
Children:
606c08c
Parents:
a7951f2
git-author:
Sebastian Huber <sebastian.huber@…> (01/04/16 10:15:37)
git-committer:
Sebastian Huber <sebastian.huber@…> (01/05/16 06:05:52)
Message:

linkers: Fix for targets with a small-data area

On certain targets (e.g. PowerPC) global data below a certain threshold
(e.g. 8 bytes) may resided in a special memory area, the small-data
area. This allows more efficient load/store operations. Placing such
data into the wrong section (e.g. .rodata) leads to relocation errors
during link-time. See test program libtests/dl02 in the RTEMS
testsuite. Using an array of unspecified size prevents that the
compiler assumes that a certain variable is in the small-data area.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • linkers/rtems-syms.cpp

    ra7951f2 rf027f37  
    6161  "",
    6262  "extern const unsigned char rtems__rtl_base_globals[];",
    63   "extern const unsigned int rtems__rtl_base_globals_size;",
     63  "extern const unsigned int rtems__rtl_base_globals_size[];",
    6464  "",
    6565  "void rtems_rtl_base_sym_global_add (const unsigned char* , unsigned int );",
     
    106106  "{",
    107107  "  rtems_rtl_base_sym_global_add (&rtems__rtl_base_globals[0],",
    108   "                                 rtems__rtl_base_globals_size);",
     108  "                                 rtems__rtl_base_globals_size[0]);",
    109109  "}",
    110110  0
Note: See TracChangeset for help on using the changeset viewer.