aboutsummaryrefslogtreecommitdiff
path: root/gold/archive.cc
diff options
context:
space:
mode:
authorCary Coutant <ccoutant@google.com>2011-03-30 21:07:13 +0000
committerCary Coutant <ccoutant@google.com>2011-03-30 21:07:13 +0000
commitc7975edd9eba42c2bd59948060d8d5c715456517 (patch)
tree2648d7512cb58f600066d281834f1c4d4aa53398 /gold/archive.cc
parentef23e70580c5c6353e916d10f2f94eceba7a70cd (diff)
downloadgdb-c7975edd9eba42c2bd59948060d8d5c715456517.zip
gdb-c7975edd9eba42c2bd59948060d8d5c715456517.tar.gz
gdb-c7975edd9eba42c2bd59948060d8d5c715456517.tar.bz2
* archive.cc (Archive::include_member): Adjust call to report_object.
(Add_archive_symbols::run): Add script_info to call to report_archive_begin. (Lib_group::include_member): Adjust call to report_object. (Add_lib_group_symbols::run): Adjust call to report_object. * incremental-dump.cc (dump_incremental_inputs): Remove unnecessary blocks. Add object count for script input files. * incremental.cc (Incremental_inputs::report_archive_begin): Add script_info parameter; change all callers. (Incremental_inputs::report_object): Add script_info parameter; change all callers. (Incremental_inputs::report_script): Store backpointer to incremental info entry. (Output_section_incremental_inputs::set_final_data_size): Record additional information for scripts. (Output_section_incremental_inputs::write_info_blocks): Likewise. * incremental.h (Incremental_script_entry::add_object): New function. (Incremental_script_entry::get_object_count): New function. (Incremental_script_entry::get_object): New function. (Incremental_script_entry::objects_): New data member; adjust constructor. (Incremental_inputs::report_archive_begin): Add script_info parameter. (Incremental_inputs::report_object): Add script_info parameter. (Incremental_inputs_reader::get_object_count): New function. (Incremental_inputs_reader::get_object_offset): New function. * options.cc (Input_arguments::add_file): Return reference to new input argument. * options.h (Input_argument::set_script_info): New function. (Input_argument::script_info): New function. (Input_argument::script_info_): New data member; adjust all constructors. (Input_file_group::add_file): Return reference to new input argument. (Input_file_lib::add_file): Likewise. (Input_arguments::add_file): Likewise. * readsyms.cc (Add_symbols::run): Adjust call to report_object. * script.cc (Parser_closure::Parser_closure): Add script_info parameter; adjust all callers. (Parser_closure::script_info): New function. (Parser_closure::script_info_): New data member. (read_input_script): Report scripts earlier to incremental info. (script_add_file): Set script_info in Input_argument. (script_add_library): Likewise. * script.h (Script_options::Script_info): Rewrite class.
Diffstat (limited to 'gold/archive.cc')
-rw-r--r--gold/archive.cc9
1 files changed, 5 insertions, 4 deletions
diff --git a/gold/archive.cc b/gold/archive.cc
index 4aafb71..a689722 100644
--- a/gold/archive.cc
+++ b/gold/archive.cc
@@ -960,7 +960,7 @@ Archive::include_member(Symbol_table* symtab, Layout* layout,
{
{
if (layout->incremental_inputs() != NULL)
- layout->incremental_inputs()->report_object(obj, this);
+ layout->incremental_inputs()->report_object(obj, this, NULL);
Read_symbols_data sd;
obj->read_symbols(&sd);
obj->layout(symtab, layout, &sd);
@@ -1040,7 +1040,8 @@ Add_archive_symbols::run(Workqueue* workqueue)
// For an incremental link, begin recording layout information.
Incremental_inputs* incremental_inputs = this->layout_->incremental_inputs();
if (incremental_inputs != NULL)
- incremental_inputs->report_archive_begin(this->archive_);
+ incremental_inputs->report_archive_begin(this->archive_,
+ this->input_argument_->script_info());
bool added = this->archive_->add_symbols(this->symtab_, this->layout_,
this->input_objects_,
@@ -1196,7 +1197,7 @@ Lib_group::include_member(Symbol_table* symtab, Layout* layout,
if (input_objects->add_object(obj))
{
if (layout->incremental_inputs() != NULL)
- layout->incremental_inputs()->report_object(obj, this);
+ layout->incremental_inputs()->report_object(obj, this, NULL);
obj->layout(symtab, layout, sd);
obj->add_symbols(symtab, sd, layout);
}
@@ -1256,7 +1257,7 @@ Add_lib_group_symbols::run(Workqueue*)
// For an incremental link, begin recording layout information.
Incremental_inputs* incremental_inputs = this->layout_->incremental_inputs();
if (incremental_inputs != NULL)
- incremental_inputs->report_archive_begin(this->lib_);
+ incremental_inputs->report_archive_begin(this->lib_, NULL);
this->lib_->add_symbols(this->symtab_, this->layout_, this->input_objects_);