* ldexp.c (fold_binary) [DATA_SEGMENT_ALIGN]: Adjust data segment
authorAndreas Schwab <schwab@linux-m68k.org>
Sun, 19 Sep 2004 17:09:23 +0000 (17:09 +0000)
committerAndreas Schwab <schwab@linux-m68k.org>
Sun, 19 Sep 2004 17:09:23 +0000 (17:09 +0000)
base so that relro end is suitably aligned.

ld/ChangeLog
ld/ldexp.c

index a267b23e9631f5efdb55e84b09f9c26e857596f2..2d4df31c6b056f15889d28404939be0bb9c99fc8 100644 (file)
@@ -1,3 +1,8 @@
+2004-09-19  Andreas Schwab  <schwab@suse.de>
+
+       * ldexp.c (fold_binary) [DATA_SEGMENT_ALIGN]: Adjust data segment
+       base so that relro end is suitably aligned.
+
 2004-09-17  Paul Brook  <paul@codesourcery.com>
 
        * ld.texinfo: Rename arm-specific section.  Document --target*
index 217a702edf21183dbf50eaa483deab35e94144ba..de239b225215c85fbfe3c2e5ac4dd13be08581ef 100644 (file)
@@ -425,12 +425,9 @@ fold_binary (etree_type *tree,
                    {
                      /* Attempt to align DATA_SEGMENT_RELRO_END at
                         a common page boundary.  */
-                     bfd_vma relro;
-
-                     result.value += dot & (maxpage - 1);
-                     relro = exp_data_seg.relro_end - exp_data_seg.base;
-                     result.value += -relro & (other.value - 1);
-                     exp_data_seg.base = result.value;
+                     exp_data_seg.base += (-exp_data_seg.relro_end
+                                           & (other.value - 1));
+                     result.value = exp_data_seg.base;
                    }
                  else if (exp_data_seg.phase != exp_dataseg_adjust)
                    {
This page took 0.027095 seconds and 4 git commands to generate.