* output.h (class Output_section_data): Remove inline definition
authorIan Lance Taylor <ian@airs.com>
Fri, 11 Apr 2008 22:55:13 +0000 (22:55 +0000)
committerIan Lance Taylor <ian@airs.com>
Fri, 11 Apr 2008 22:55:13 +0000 (22:55 +0000)
of set_addralign.
* output.cc (Output_section_data::set_addralign): New function.

gold/ChangeLog
gold/output.cc
gold/output.h

index cc05b97fdc484b3d5cd3be1eea8653e6fbc3e3ce..c022353bceef47fc9b98a478ab695565dd913afe 100644 (file)
@@ -1,3 +1,9 @@
+2008-04-11  Ian Lance Taylor  <iant@google.com>
+
+       * output.h (class Output_section_data): Remove inline definition
+       of set_addralign.
+       * output.cc (Output_section_data::set_addralign): New function.
+
 2008-04-11  Cary Coutant  <ccoutant@google.com>
 
        Add support for TLS descriptors for i386 and x86_64.
index 9ec14625abf8750cea72b757800abe3ec90a993e..48609a21eb7157f9b044b21745e95ba09d2c4727 100644 (file)
@@ -535,6 +535,18 @@ Output_section_data::do_out_shndx() const
   return this->output_section_->out_shndx();
 }
 
+// Set the alignment, which means we may need to update the alignment
+// of the output section.
+
+void
+Output_section_data::set_addralign(uint64_t addralign)
+{
+  this->addralign_ = addralign;
+  if (this->output_section_ != NULL
+      && this->output_section_->addralign() < addralign)
+    this->output_section_->set_addralign(addralign);
+}
+
 // Output_data_strtab methods.
 
 // Set the final data size.
index 126ec71e9984abed74106fb1713ccb1c701a7c5a..6221c6e5d7052b08b52214104285022d39f604aa 100644 (file)
@@ -595,8 +595,7 @@ class Output_section_data : public Output_data
 
   // Set the alignment.
   void
-  set_addralign(uint64_t addralign)
-  { this->addralign_ = addralign; }
+  set_addralign(uint64_t addralign);
 
  private:
   // The output section for this section.