diff options
author | Richard Henderson <rth@redhat.com> | 2005-06-04 12:23:53 -0700 |
---|---|---|
committer | Richard Henderson <rth@gcc.gnu.org> | 2005-06-04 12:23:53 -0700 |
commit | 0f1341c792afc09924b573f5228778dbdd33b805 (patch) | |
tree | 482d2e24acca50a4b052912454b62a18a6efd369 | |
parent | 833b3afe497cd2430838ddd8a9b1ab9c9b0ba4f2 (diff) | |
download | gcc-0f1341c792afc09924b573f5228778dbdd33b805.zip gcc-0f1341c792afc09924b573f5228778dbdd33b805.tar.gz gcc-0f1341c792afc09924b573f5228778dbdd33b805.tar.bz2 |
re PR target/21888 (bootstrap failure with linker relaxation enabled)
PR target/21888
* config/alpha/alpha.c (alpha_align_insns): Don't insert nops
until we've passed initial ldgp.
From-SVN: r100596
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/config/alpha/alpha.c | 8 |
2 files changed, 13 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index dbffb90..f6b093a 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2005-06-04 Richard Henderson <rth@redhat.com> + + PR target/21888 + * config/alpha/alpha.c (alpha_align_insns): Don't insert nops + until we've passed initial ldgp. + 2005-06-04 Daniel Berlin <dberlin@dberlin.org> * cfgexpand.c (expand_one_var): Use DECL_HAS_VALUE_EXPR_P. diff --git a/gcc/config/alpha/alpha.c b/gcc/config/alpha/alpha.c index 908165a..3f78c16 100644 --- a/gcc/config/alpha/alpha.c +++ b/gcc/config/alpha/alpha.c @@ -8974,7 +8974,7 @@ alpha_align_insns (unsigned int max_align, unsigned int align; /* OFS is the offset of the current insn in the insn group. */ int ofs; - int prev_in_use, in_use, len; + int prev_in_use, in_use, len, ldgp; rtx i, next; /* Let shorten branches care for assigning alignments to code labels. */ @@ -8992,6 +8992,8 @@ alpha_align_insns (unsigned int max_align, if (GET_CODE (i) == NOTE) i = next_nonnote_insn (i); + ldgp = alpha_function_needs_gp ? 8 : 0; + while (i) { next = (*next_group) (i, &in_use, &len); @@ -9047,6 +9049,10 @@ alpha_align_insns (unsigned int max_align, } } + /* We may not insert padding inside the initial ldgp sequence. */ + else if (ldgp > 0) + ldgp -= len; + /* If the group won't fit in the same INT16 as the previous, we need to add padding to keep the group together. Rather than simply leaving the insn filling to the assembler, we |