aboutsummaryrefslogtreecommitdiff
path: root/ld
diff options
context:
space:
mode:
authorTristan Gingold <gingold@adacore.com>2009-06-25 13:18:46 +0000
committerTristan Gingold <gingold@adacore.com>2009-06-25 13:18:46 +0000
commitd64703c6e89b6a4ad72cc40e7f9918f3e4e54e5b (patch)
tree7f1890dfb66fc7ab8f149d70004a448d95afd16b /ld
parentb32e07d7d744d2acc7fc04d96f2d67eef6f35b87 (diff)
downloadgdb-d64703c6e89b6a4ad72cc40e7f9918f3e4e54e5b.zip
gdb-d64703c6e89b6a4ad72cc40e7f9918f3e4e54e5b.tar.gz
gdb-d64703c6e89b6a4ad72cc40e7f9918f3e4e54e5b.tar.bz2
2009-06-25 Tristan Gingold <gingold@adacore.com>
* ldlang.c (print_input_section): Add is_discarded parameter. Adjust prototype. (lang_map): Print the size of discarded sections. (print_statement): Adjust call to print_input_section.
Diffstat (limited to 'ld')
-rw-r--r--ld/ChangeLog7
-rw-r--r--ld/ldlang.c11
2 files changed, 13 insertions, 5 deletions
diff --git a/ld/ChangeLog b/ld/ChangeLog
index b0a099e..7b65d0d 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,3 +1,10 @@
+2009-06-25 Tristan Gingold <gingold@adacore.com>
+
+ * ldlang.c (print_input_section): Add is_discarded parameter. Adjust
+ prototype.
+ (lang_map): Print the size of discarded sections.
+ (print_statement): Adjust call to print_input_section.
+
2009-06-18 Dave Korn <dave.korn.cygwin@gmail.com>
Merge cegcc and mingw32ce target name changes from CeGCC project:
diff --git a/ld/ldlang.c b/ld/ldlang.c
index 30d71aa..dda2f22 100644
--- a/ld/ldlang.c
+++ b/ld/ldlang.c
@@ -78,7 +78,7 @@ static void print_statement (lang_statement_union_type *,
static void print_statement_list (lang_statement_union_type *,
lang_output_section_statement_type *);
static void print_statements (void);
-static void print_input_section (asection *);
+static void print_input_section (asection *, bfd_boolean);
static bfd_boolean lang_one_common (struct bfd_link_hash_entry *, void *);
static void lang_record_phdrs (void);
static void lang_do_version_exports_section (void);
@@ -1917,7 +1917,7 @@ lang_map (void)
dis_header_printed = TRUE;
}
- print_input_section (s);
+ print_input_section (s, TRUE);
}
}
@@ -3957,7 +3957,7 @@ print_all_symbols (asection *sec)
/* Print information about an input section to the map file. */
static void
-print_input_section (asection *i)
+print_input_section (asection *i, bfd_boolean is_discarded)
{
bfd_size_type size = i->size;
int len;
@@ -3986,7 +3986,8 @@ print_input_section (asection *i)
else
{
addr = print_dot;
- size = 0;
+ if (!is_discarded)
+ size = 0;
}
minfo ("0x%V %W %B\n", addr, TO_ADDR (size), i->owner);
@@ -4281,7 +4282,7 @@ print_statement (lang_statement_union_type *s,
print_reloc_statement (&s->reloc_statement);
break;
case lang_input_section_enum:
- print_input_section (s->input_section.section);
+ print_input_section (s->input_section.section, FALSE);
break;
case lang_padding_statement_enum:
print_padding_statement (&s->padding_statement);