mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-23 03:29:47 +08:00
* config/tc-hppa.c (pa_parse_space_stmt): Use the built-in
defaults for defined, private, and spnum fields for the $TEXT$ and $PRIVATE$ spaces. Do not clobber spnum. Do not reset the segment if just updating a space. (pa_spaces_begin): Set BFD section flags for all built-in subspaces.
This commit is contained in:
@ -1,3 +1,12 @@
|
|||||||
|
Mon Apr 18 14:28:22 1994 Jeffrey A. Law (law@snake.cs.utah.edu)
|
||||||
|
|
||||||
|
* config/tc-hppa.c (pa_parse_space_stmt): Use the built-in
|
||||||
|
defaults for defined, private, and spnum fields for the
|
||||||
|
$TEXT$ and $PRIVATE$ spaces. Do not clobber spnum. Do
|
||||||
|
not reset the segment if just updating a space.
|
||||||
|
(pa_spaces_begin): Set BFD section flags for all built-in
|
||||||
|
subspaces.
|
||||||
|
|
||||||
Fri Apr 15 10:51:51 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
|
Fri Apr 15 10:51:51 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
|
||||||
|
|
||||||
* ecoff.c (first_proc_ptr): New static variable.
|
* ecoff.c (first_proc_ptr): New static variable.
|
||||||
|
@ -5077,7 +5077,7 @@ pa_parse_space_stmt (space_name, create_flag)
|
|||||||
{
|
{
|
||||||
char *name, *ptemp, c;
|
char *name, *ptemp, c;
|
||||||
char loadable, defined, private, sort;
|
char loadable, defined, private, sort;
|
||||||
int spnum;
|
int spnum, temp;
|
||||||
asection *seg = NULL;
|
asection *seg = NULL;
|
||||||
sd_chain_struct *space;
|
sd_chain_struct *space;
|
||||||
|
|
||||||
@ -5090,12 +5090,18 @@ pa_parse_space_stmt (space_name, create_flag)
|
|||||||
if (strcmp (space_name, "$TEXT$") == 0)
|
if (strcmp (space_name, "$TEXT$") == 0)
|
||||||
{
|
{
|
||||||
seg = pa_def_spaces[0].segment;
|
seg = pa_def_spaces[0].segment;
|
||||||
|
defined = pa_def_spaces[0].defined;
|
||||||
|
private = pa_def_spaces[0].private;
|
||||||
sort = pa_def_spaces[0].sort;
|
sort = pa_def_spaces[0].sort;
|
||||||
|
spnum = pa_def_spaces[0].spnum;
|
||||||
}
|
}
|
||||||
else if (strcmp (space_name, "$PRIVATE$") == 0)
|
else if (strcmp (space_name, "$PRIVATE$") == 0)
|
||||||
{
|
{
|
||||||
seg = pa_def_spaces[1].segment;
|
seg = pa_def_spaces[1].segment;
|
||||||
|
defined = pa_def_spaces[1].defined;
|
||||||
|
private = pa_def_spaces[1].private;
|
||||||
sort = pa_def_spaces[1].sort;
|
sort = pa_def_spaces[1].sort;
|
||||||
|
spnum = pa_def_spaces[1].spnum;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!is_end_of_statement ())
|
if (!is_end_of_statement ())
|
||||||
@ -5105,8 +5111,12 @@ pa_parse_space_stmt (space_name, create_flag)
|
|||||||
/* First see if the space was specified as a number rather than
|
/* First see if the space was specified as a number rather than
|
||||||
as a name. According to the PA assembly manual the rest of
|
as a name. According to the PA assembly manual the rest of
|
||||||
the line should be ignored. */
|
the line should be ignored. */
|
||||||
if ((spnum = pa_parse_number (&ptemp, 0)) >= 0)
|
temp = pa_parse_number (&ptemp, 0);
|
||||||
|
if (temp >= 0)
|
||||||
|
{
|
||||||
|
spnum = temp;
|
||||||
input_line_pointer = ptemp;
|
input_line_pointer = ptemp;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
while (!is_end_of_statement ())
|
while (!is_end_of_statement ())
|
||||||
@ -5169,7 +5179,6 @@ pa_parse_space_stmt (space_name, create_flag)
|
|||||||
SPACE_SPNUM (space) = spnum;
|
SPACE_SPNUM (space) = spnum;
|
||||||
SPACE_DEFINED (space) = defined & 1;
|
SPACE_DEFINED (space) = defined & 1;
|
||||||
SPACE_USER_DEFINED (space) = 1;
|
SPACE_USER_DEFINED (space) = 1;
|
||||||
space->sd_seg = seg;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef obj_set_section_attributes
|
#ifdef obj_set_section_attributes
|
||||||
@ -5624,12 +5633,13 @@ pa_spaces_begin ()
|
|||||||
|
|
||||||
|
|
||||||
/* For SOM we want to replace the standard .text, .data, and .bss
|
/* For SOM we want to replace the standard .text, .data, and .bss
|
||||||
sections with our own. */
|
sections with our own. We also want to set BFD flags for
|
||||||
|
all the built-in subspaces. */
|
||||||
if (!strcmp (pa_def_subspaces[i].name, "$CODE$") && !USE_ALIASES)
|
if (!strcmp (pa_def_subspaces[i].name, "$CODE$") && !USE_ALIASES)
|
||||||
{
|
{
|
||||||
text_section = segment;
|
text_section = segment;
|
||||||
applicable = bfd_applicable_section_flags (stdoutput);
|
applicable = bfd_applicable_section_flags (stdoutput);
|
||||||
bfd_set_section_flags (stdoutput, text_section,
|
bfd_set_section_flags (stdoutput, segment,
|
||||||
applicable & (SEC_ALLOC | SEC_LOAD
|
applicable & (SEC_ALLOC | SEC_LOAD
|
||||||
| SEC_RELOC | SEC_CODE
|
| SEC_RELOC | SEC_CODE
|
||||||
| SEC_READONLY
|
| SEC_READONLY
|
||||||
@ -5639,7 +5649,7 @@ pa_spaces_begin ()
|
|||||||
{
|
{
|
||||||
data_section = segment;
|
data_section = segment;
|
||||||
applicable = bfd_applicable_section_flags (stdoutput);
|
applicable = bfd_applicable_section_flags (stdoutput);
|
||||||
bfd_set_section_flags (stdoutput, data_section,
|
bfd_set_section_flags (stdoutput, segment,
|
||||||
applicable & (SEC_ALLOC | SEC_LOAD
|
applicable & (SEC_ALLOC | SEC_LOAD
|
||||||
| SEC_RELOC
|
| SEC_RELOC
|
||||||
| SEC_HAS_CONTENTS));
|
| SEC_HAS_CONTENTS));
|
||||||
@ -5650,9 +5660,27 @@ pa_spaces_begin ()
|
|||||||
{
|
{
|
||||||
bss_section = segment;
|
bss_section = segment;
|
||||||
applicable = bfd_applicable_section_flags (stdoutput);
|
applicable = bfd_applicable_section_flags (stdoutput);
|
||||||
bfd_set_section_flags (stdoutput, bss_section,
|
bfd_set_section_flags (stdoutput, segment,
|
||||||
applicable & SEC_ALLOC);
|
applicable & SEC_ALLOC);
|
||||||
}
|
}
|
||||||
|
else if (!strcmp (pa_def_subspaces[i].name, "$LIT$") && !USE_ALIASES)
|
||||||
|
{
|
||||||
|
applicable = bfd_applicable_section_flags (stdoutput);
|
||||||
|
bfd_set_section_flags (stdoutput, segment,
|
||||||
|
applicable & (SEC_ALLOC | SEC_LOAD
|
||||||
|
| SEC_RELOC
|
||||||
|
| SEC_READONLY
|
||||||
|
| SEC_HAS_CONTENTS));
|
||||||
|
}
|
||||||
|
else if (!strcmp (pa_def_subspaces[i].name, "$UNWIND$") && !USE_ALIASES)
|
||||||
|
{
|
||||||
|
applicable = bfd_applicable_section_flags (stdoutput);
|
||||||
|
bfd_set_section_flags (stdoutput, segment,
|
||||||
|
applicable & (SEC_ALLOC | SEC_LOAD
|
||||||
|
| SEC_RELOC
|
||||||
|
| SEC_READONLY
|
||||||
|
| SEC_HAS_CONTENTS));
|
||||||
|
}
|
||||||
|
|
||||||
/* Find the space associated with this subspace. */
|
/* Find the space associated with this subspace. */
|
||||||
space = pa_segment_to_space (pa_def_spaces[pa_def_subspaces[i].
|
space = pa_segment_to_space (pa_def_spaces[pa_def_subspaces[i].
|
||||||
|
Reference in New Issue
Block a user